Anton-Latukha
10051fbfc1
clean-up: rm commented-out imports
...
M main/Main.hs
M src/Nix/Reduce.hs
M src/Nix/Type/Infer.hs
M tests/EvalTests.hs
2020-09-21 01:57:58 +03:00
Anton-Latukha
0cb3946ee7
clean-up: (return -> pure)
...
M main/Main.hs
M main/Repl.hs
M src/Nix/Builtins.hs
M src/Nix/Convert.hs
M src/Nix/Effects.hs
M src/Nix/Effects/Basic.hs
M src/Nix/Eval.hs
M src/Nix/Exec.hs
M src/Nix/Expr/Types.hs
M src/Nix/Json.hs
M src/Nix/Lint.hs
M src/Nix/Normal.hs
M src/Nix/Options/Parser.hs
M src/Nix/Parser.hs
M src/Nix/Scope.hs
M src/Nix/String.hs
M src/Nix/TH.hs
M src/Nix/Thunk/Basic.hs
M src/Nix/Utils.hs
M src/Nix/Value.hs
M src/Nix/Value/Equal.hs
M src/Nix/XML.hs
M tests/EvalTests.hs
M tests/Main.hs
M tests/NixLanguageTests.hs
M tests/ParserTests.hs
M tests/TestCommon.hs
2020-09-21 01:57:52 +03:00
Simon Jakobi
1a2d627a58
Use prettyprinter-1.7.0
...
Changelog:
http://hackage.haskell.org/package/prettyprinter-1.7.0/changelog
hnix is likely to be affected by this change:
> Use floor instead of round to compute ribbon width.
…due to its use of custom `LayoutOptions`.
2020-08-07 12:21:12 +03:00
Simon Jakobi
54030284fa
Update to data-fix-0.3
...
Changelog: http://hackage.haskell.org/package/data-fix-0.3.0/changelog
Context: https://github.com/commercialhaskell/stackage/issues/5535
2020-07-24 12:35:59 +03:00
Simon Jakobi
220209c090
Use neat-interpolation instead of interpolate ( #635 )
...
In addition to `interpolate`, this also removes the following
transitive dependencies:
- `haskell-src-exts`
- `haskell-src-meta`
- `safe`
- `th-expand-syns`
- `th-lift`
- `th-lift-instances`
- `th-orphans`
- `th-reify-many`
Since `neat-interpolation`'s `text` quasiquoter trims more whitespace
than `interpolate`'s `i`, the expected output of some tests for
`unsafeGetAttrPos` had to be updated.
This also improves the test failure output of the `constantEqual`
helper.
Fixes #634 .
2020-06-27 10:43:50 +02:00
Simon Jakobi
f0532b86f6
Silence redundant import warnings for Control.Monad.Fail ( #633 )
...
Also address mysterious redundant import warnings in the testsuite
This allows us to enable `buildStrictly=true` for GHC 8.8.
Fixes #613 .
2020-06-19 02:21:06 +02:00
Richard Marko
9c93e89331
tests: port loop, remove hardcoded paths
2020-05-15 17:49:57 -07:00
John Wiegley
0ca6613d4b
Fixes for building with GHC 8.6.5 under Nix
2020-01-13 17:55:16 -08:00
Guillaume Maudoux
975d6dea93
Refactor execBinaryOp to demand values where needed.
...
This spliste execBinaryOp in two parts where the second conatains all
the logic that relies on the assumption that values are already in
"demanded".
2019-11-27 17:16:43 -08:00
Guillaume Maudoux
4ded48a789
Add proper default 'nix' prefix to search paths
...
The search path of Nix contains by default the "nix" prefix that points
to $datadir/nix/corepkgs, where $datadir defaults to $prefix/lib at
installation time, but can be overriden by NIX_DATA_DIR.
We implemented it using `Paths.hnix.getDataDir` and `NIX_DATA_DIR` to
follow Nix behaviour as closely as possible.
A small discrepancy is that we do the lookup on each invocation, where
Nix caches the searchPath at context creation.
2019-11-26 14:32:29 -07:00
Guillaume Maudoux
21c3c9c938
Fix compound attributes in let bindings
...
Fix an issue where compound attributes would discard previous bindings
in a let statement.
`let a=1; b.b=2; c=3; in a` would fail, where
`let a=1; b.b=2; c=3; in c` would work as expected.
2019-11-25 15:22:39 -07:00
Anton-Latukha
c03a40acea
upd texts of more messages
...
Heterogeneous: consisting of dissimilar elements.
Heterogenous:
1. not originating within the body;
(ex: "You are NOT of the body!" by Dr. Leonard "Bones" McCoy)
2. of foreign origin;
3. heterogeneous.
2019-08-04 15:00:57 -07:00
Silvan Mosberger
82b2d8af7f
Use NSet for both recursive and non-recursive sets
...
Simplifies the AST
2019-07-25 14:10:44 -07:00
Félix Baylac-Jacqué
cacbfdbd6d
Builtins: add builtins.concatMap
...
Fixes #448
2019-04-01 15:45:27 -07:00
Félix Baylac-Jacqué
3acc67ba66
Fix eval-okay-builtins-add.
...
Nix omits the trailing .0 when displaying a Float. Aligning current
hnix pretty printer with this behaviour.
Fixes #447 .
2019-03-27 21:16:54 -07:00
John Wiegley
4607639774
Remove the NValueNF type, as it provides little utility
2019-03-27 21:16:01 -07:00
John Wiegley
04cf8be650
Move StdIdT out of the StandardT transformer
2019-03-23 00:56:40 -07:00
John Wiegley
77c52fd43c
Revise Nix.Standard
2019-03-23 00:49:03 -07:00
John Wiegley
29c48fa8e3
Run Brittany again
2019-03-17 22:46:15 -07:00
John Wiegley
18c49f6a0d
Reorganize code in Nix.Value, creating new Nix.Value.Equal
2019-03-17 22:44:22 -07:00
John Wiegley
a006769124
Factor some common patterns back into Standard
2019-03-17 21:58:35 -07:00
John Wiegley
7b5d134d22
Factor out FreshIdT from Standard
2019-03-17 19:04:38 -07:00
John Wiegley
015ced236e
Simplify Standard by splitting off Cited.Basic
2019-03-17 18:43:23 -07:00
John Wiegley
082a6ddcef
Comment out appendContext test, as it is presently failing
2019-03-17 15:45:47 -07:00
John Wiegley
895f4e721f
Merge remote-tracking branch 'origin/vs-context-primops'
2019-03-17 15:44:05 -07:00
John Wiegley
aa66560bf7
Get rid of implicit conversions to and from thunks
2019-03-17 15:30:20 -07:00
John Wiegley
94e0be3882
Reformat all sources with Brittany, to restore consistency
2019-03-17 14:47:38 -07:00
John Wiegley
5c10be3e3b
More cleanup, get rid of the Eq and Ord instances for NValue'
...
They had dubious semantics anyway; there is now only valueEqM and valueNFEq.
2019-03-16 23:35:16 -07:00
John Wiegley
9405074cd8
Fix hnix-tests
2019-03-16 14:41:25 -07:00
John Wiegley
6ae5764221
All type checks, but many instance definitions are still missing
2019-03-16 01:10:47 -07:00
John Wiegley
145e69c9a4
Further work on Standard.hs
2019-03-15 22:54:29 -07:00
John Wiegley
e9236aa55c
Now down to Main.hs and the tests
2019-03-15 17:20:10 -07:00
John Wiegley
bda79c984b
Merge branch 'master' into vs-context-primops
2019-03-11 08:41:42 -07:00
John Wiegley
dc12cdf92e
Add a test to ensure that we report infinite recursion
2019-03-10 14:19:15 -07:00
Emmanuel Denloye-Ito
af9f69d517
fromJSON tests are now working. Yeah!
2019-03-10 14:14:14 -07:00
Emmanuel Denloye-Ito
5e0617a952
spelling error
2019-03-10 14:14:14 -07:00
Emmanuel Denloye-Ito
7a9b70f139
Found failing case: "stringed" numbers as key
2019-03-10 14:14:14 -07:00
John Wiegley
7bb233cb2b
Merge branch 'master' into vs-context-primops
2019-03-10 13:54:43 -07:00
Ken Micklas
468dc493bd
Ignore hash in appendContext test
2019-03-10 16:44:09 -04:00
Ken Micklas
a25c01b218
Fix path name in appendContext test
2019-03-10 16:21:21 -04:00
Ken Micklas
616cb998c6
Ignore output hash in getContext test
2019-03-10 16:02:15 -04:00
hsloan
f2033c0694
change test directory
2019-03-10 11:38:41 -07:00
hsloan
e384945867
add eval-compare test
2019-03-10 11:38:41 -07:00
Emmanuel Denloye-Ito
c51d966d44
Add tests for mapAttrs and changed hackyMakeNixStringWithoutContext to principledMakeNixStringWithoutContext in Builtins.hs
2019-03-10 11:17:36 -07:00
Emmanuel Denloye-Ito
586f1de62d
Less than test ( #461 )
...
References issue #438
Co-authored-by: John Wiegley <johnw@newartisans.com>
2019-03-10 11:16:36 -07:00
Ken Micklas
345f2d817f
Add trailing newlines to context primop tests
2019-03-10 13:54:24 -04:00
Ken Micklas
718c94e0bb
Merge branch 'master' into vs-context-primops
2019-03-10 13:48:58 -04:00
Emily Pillmore
f3970d49b9
Add principled 'fetchurl' + tests
...
Tests are masked until store work is done
2019-03-10 10:07:03 -07:00
Doug Beardsley
048638f6a1
Add tests for getContext and appendContext
2019-03-10 12:59:00 -04:00
Ken Micklas
4d45ef67ff
Fix typo in test name
2019-03-09 22:02:28 -05:00