Commit graph

304 commits

Author SHA1 Message Date
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
John Wiegley 8f24c7b645 Implement laziness, although without support for concurrency 2018-03-29 15:35:12 -07:00
John Wiegley c82dec901f Begin work to avoid buying thunks in m (NThunk m) 2018-03-29 12:32:16 -07:00
John Wiegley e06271d9ca Initial round of work on supporting first class thunks 2018-03-29 12:16:18 -07:00
John Wiegley 84918aa1d3 Remove the MonadFix requirement, it was not needed; fix NRecSet 2018-03-28 23:52:07 -07:00
John Wiegley 9a37da33f7 Fix recursive binding problem with NRecSet 2018-03-28 17:43:09 -07:00
John Wiegley abb2d8a98b Fix to .travis.yml 2018-03-28 16:32:28 -07:00
John Wiegley d77e52e9d4 Don't run the language tests (say, on Travis) unless LANGUAGE_TESTS=yes 2018-03-28 16:30:54 -07:00
John Wiegley dfee8cd2b8 Add checkExpr, which checks for errors in Nix expressions
This allows us to pass 10 more of the NixLanguageTests, so that after parsing
a file containing "x: y", we can report that y is undefined.
2018-03-28 16:27:35 -07:00
John Wiegley 2c188045cd Passing --debug to hnix when not evaluating dump the parse tree 2018-03-28 15:48:32 -07:00
John Wiegley b97378c581 Restore previous default.nix (mostly) 2018-03-28 15:13:02 -07:00
John Wiegley 4cce2adc1b Add Nix/Utils.hs 2018-03-28 15:00:28 -07:00
John Wiegley c68e508f83 Remove an unneeded import 2018-03-28 15:00:19 -07:00
John Wiegley 7affd66a25 Drop some dead code 2018-03-28 15:00:02 -07:00
John Wiegley cce4118452 Remove some debugging code 2018-03-28 14:51:40 -07:00
John Wiegley 39f772ef3c Restore monadic abstraction (to support importFile), fix attribute sets 2018-03-28 14:45:10 -07:00
John Wiegley 1974ace399 Remove some tracing code 2018-03-27 23:16:00 -07:00
John Wiegley 124530c9a9 Fix at-right patterns 2018-03-27 22:53:52 -07:00
John Wiegley dbc57423e7 Constrain exports from Nix.Eval 2018-03-27 22:34:56 -07:00
John Wiegley b923af49f4 Split off some utility functions into their own Nix.Utils module 2018-03-27 22:32:43 -07:00
John Wiegley 1ba29231af Clarify an error message 2018-03-27 22:28:53 -07:00
John Wiegley b5c0ccf6d5 Clarify a comment 2018-03-27 22:28:00 -07:00
John Wiegley f0f88edac7 Add support for import statements 2018-03-27 22:21:17 -07:00
John Wiegley 3a29249e43 Normalize import statements, add option parsing 2018-03-27 21:59:27 -07:00
John Wiegley 1e0e47d064 Remove monadic context from evalExpr: we weren't using it! 2018-03-27 19:07:08 -07:00
John Wiegley 278916a9ab Further work on argument evaluation 2018-03-27 18:42:31 -07:00
John Wiegley ecd18e3da3 Merge branch 'master' into fix-recursive-argument-set 2018-03-27 14:34:28 -07:00
John Wiegley 15651db78a
Merge pull request #99 from dmjio/patch-1
Bump deriving-compat upper bound
2018-03-27 14:11:16 -07:00
David Johnson 37e457367b
Bump deriving-compat upper bound 2018-03-27 12:34:56 -07:00
Georges Dubus 9cd901fc4b
Merge pull request #96 from madjar/default-args-in-atpattern
Fix a bug where defaultargs are absent from the atpattern argument
2018-03-11 12:16:01 +01:00
Georges Dubus 2e26bd75a5 Fix a bug where defaultargs are absent from the atpattern argument 2018-03-11 12:15:33 +01:00
Georges Dubus fe28701d1c
Merge pull request #95 from madjar/variadic-params
Add support for variadic parameters
2018-03-09 14:11:36 +01:00
Georges Dubus 0f7332636e Add support for variadic parameters
Everything was already in place, but not used for variadic parameters.

On the other hand fixed parameters sets are currently bugged, as they don't
reject extra arguments (they act like variadic parameters set). This commit adds
a TODO mentionning that.
2018-03-09 14:09:43 +01:00
John Wiegley 6bee6ecc91
Merge pull request #94 from deepfire/master
Fix #93: true/false being mis-parsed when part of an attribute name.
2018-03-05 20:19:06 -08:00
Kosyrev Serge 0693768550
Fix #93: true/false being mis-parsed when part of an attribute name. 2018-03-06 04:14:16 +03:00
John Wiegley 89305fedf0
Merge pull request #92 from madjar/fix-function-env
Use environment in evaluation of function definitions
2018-03-01 11:23:00 -08:00
Georges Dubus 6a8ae208b4 Use environment in evaluation of function definitions 2018-03-01 20:04:54 +01:00
John Wiegley edd12bbbbd
Merge pull request #91 from jwiegley/rm_shorthands_test
remove mkDots test, no longer necessary
2018-02-28 10:12:27 -08:00
Allen Nelson 46bb504ccc whack that mole 2018-02-28 11:45:34 -06:00
Allen Nelson e6be5e0096 rm mention of shorthandtests from cabal file 2018-02-28 11:34:50 -06:00
Allen Nelson cbee241685 remove mkDots test, no longer necessary 2018-02-28 10:59:53 -06:00
John Wiegley ac731ee4a0
Merge pull request #89 from madjar/set-to-string
Eval: coerce a set to a string if there is a __asString attribute
2018-02-27 10:28:26 -08:00