Commit graph

2145 commits

Author SHA1 Message Date
Ryan Trinkle da32b8fff8 Add 'map' builtin 2018-03-30 19:46:25 -04:00
Ryan Trinkle a9cc3644b2 Fix error message in attrNames 2018-03-30 19:46:16 -04:00
Ryan Trinkle d74c5506b1 Reindent 'substring' 2018-03-30 19:45:58 -04:00
Ryan Trinkle 1944316909 Add builtins.attrNames 2018-03-30 19:37:11 -04:00
Ryan Trinkle e0084cbbfa Add builtins.stringLength 2018-03-30 19:19:12 -04:00
Ryan Trinkle ce016b2dca Add builtins.substring 2018-03-30 19:16:58 -04:00
John Wiegley f9b5755642 Minor whitespace change 2018-03-30 15:15:31 -07:00
John Wiegley 77b7647c42 Add an arit2 helper 2018-03-30 15:14:55 -07:00
John Wiegley 94d4b5960c Fix a scoping bug introduced by 4cedcca9ad 2018-03-30 15:09:02 -07:00
John Wiegley 2672610fea Disable tracing 2018-03-30 14:57:03 -07:00
John Wiegley 19e88692a3 Fix an import in Main.hs 2018-03-30 14:56:41 -07:00
John Wiegley 4cedcca9ad Abstract the NScope type within MonadNix 2018-03-30 14:55:42 -07:00
Ryan Trinkle cac662f7dc Merge branch 'to-from-nix'
# Conflicts:
#	Nix/Builtins.hs
2018-03-30 17:52:38 -04:00
Ryan Trinkle 48c47eecdf Refactor sub primitive 2018-03-30 17:34:27 -04:00
Ryan Trinkle c15ee3d733 Merge remote-tracking branch 'origin/master' into to-from-nix
# Conflicts:
#	Nix/Builtins.hs
2018-03-30 17:34:12 -04:00
John Wiegley 74cc1a2ad5 Split MonadNix into evaluation and environmental effects 2018-03-30 14:25:03 -07:00
John Wiegley 9f6c2ba948 Move a lot of code around into new modules 2018-03-30 14:08:38 -07:00
Ryan Trinkle 3c109a150c Add ToNix, FromNix, and ToBuiltin 2018-03-30 16:52:45 -04:00
John Wiegley 35b0cc1c59 Use valueRef in Builtins.hs 2018-03-30 13:52:36 -07:00
John Wiegley b1620ffe49 Restore the valueRef method 2018-03-30 13:52:01 -07:00
John Wiegley 5effdda04b Move the scoping code into its own module 2018-03-30 13:30:28 -07:00
John Wiegley 0b812d5c94 Correctly support 'with' by distinguishing weak scopes from non-weak 2018-03-30 13:18:24 -07:00
John Wiegley 744c4fd388 Disable tracing again 2018-03-30 12:48:20 -07:00
John Wiegley cab2fe914e Add a missing import 2018-03-30 12:48:20 -07:00
Ryan Trinkle cb2d69c24a Bump nix to a fork where we have a new test: eval-okay-nested-with 2018-03-30 15:47:09 -04:00
John Wiegley a4a2fc0659 Move the linting code into its own module 2018-03-30 12:45:23 -07:00
John Wiegley 185ddf94e4 Add support for the inherit keyword 2018-03-30 12:37:11 -07:00
John Wiegley 92a030c707 Restore foldl' 2018-03-30 12:10:04 -07:00
John Wiegley 45d29178df Remove an unnecessary layer of indirection in the management of thunks 2018-03-30 12:05:38 -07:00
Ryan Trinkle 3d1bc0bb0b Fix compareVersions
Previously, it did not consider `pre` to be less than a missing version component
2018-03-30 13:21:02 -04:00
Ryan Trinkle 4c10e6333d Add some things to .gitignore 2018-03-30 13:07:40 -04:00
Ryan Trinkle 83335ec0f3 Add builtins.parseDrvName 2018-03-30 13:07:33 -04:00
Ryan Trinkle 5c509ab66a Add builtins.sub 2018-03-30 12:42:34 -04:00
Ryan Trinkle 6d9e5e1b4f Bump nix 2018-03-30 12:39:21 -04:00
Ryan Trinkle a63b908f99 Add builtins.splitVersion and builtins.compareVersions 2018-03-30 12:39:15 -04:00
Ryan Trinkle e763089786 Add builtins.tail 2018-03-30 12:00:31 -04:00
Ryan Trinkle d813c4d1e9 Add builtins.head 2018-03-30 11:58:05 -04:00
Ryan Trinkle b800c630a2 Make == and /= handle lists 2018-03-30 11:57:58 -04:00
Ryan Trinkle 4007498b2d Add foldl' builtin 2018-03-30 11:46:23 -04:00
John Wiegley 22924a591f Implement getEnv, set TEST_VAR=foo for the language tests 2018-03-30 02:16:52 -07:00
John Wiegley c234849fd6 Fix a few tests by making a small change to printNix 2018-03-30 02:07:08 -07:00
John Wiegley 8e944cc223 Fix the tests 2018-03-30 02:00:36 -07:00
John Wiegley 71b4bf5e8a Various fixes, and make imports local to their containing file 2018-03-30 01:50:19 -07:00
John Wiegley b456eba4d6 Add some test files 2018-03-30 01:14:06 -07:00
John Wiegley 4e698d76fa More fixes to lazy evaluation and scoping 2018-03-30 01:11:27 -07:00
John Wiegley 21b179b267 Change the precedence of 'with' bindings
Fixes #104
2018-03-29 18:14:20 -07:00
Ryan Trinkle 3f29f65477 Use nix-store --add to convert paths to strings
Fixes eval-fail-bad-antiquote-2
2018-03-29 20:23:22 -04:00
John Wiegley 6ada0e8861
Merge pull request #101 from ryantrinkle/eval-fail-undeclared-arg
Fix eval-fail-undeclared-arg
2018-03-29 17:02:14 -07:00
Ryan Trinkle 1080ad7b5e Fix eval-fail-undeclared-arg 2018-03-29 19:34:08 -04:00
John Wiegley 8a01f87d69 Fix one of the function-related tests 2018-03-29 16:00:06 -07:00