This website requires JavaScript.
Explore
Help
Sign In
NixOS
/
nix
Watch
1
Star
0
Fork
You've already forked nix
0
mirror of
https://github.com/NixOS/nix
synced
2024-10-18 13:50:37 -04:00
Code
Activity
de1289229f
nix
/
tests
/
functional
/
lang
/
eval-okay-flatten.nix
9 lines
106 B
Nix
Raw
Normal View
History
Unescape
Escape
* Builtin function `add' to add integers. * Put common test functions in tests/lang/lib.nix.
2006-09-22 11:29:21 -04:00
with
import
./lib.nix
;
* Added a builtin function `isList' to test whether a value is a list. With this primitive, a list-flattening function can be implemented (NIX-55, example is in tests/lang/eval-okay-flatten.nix).
2006-09-22 10:55:19 -04:00
* Builtin function `add' to add integers. * Put common test functions in tests/lang/lib.nix.
2006-09-22 11:29:21 -04:00
let
{
* Added a builtin function `isList' to test whether a value is a list. With this primitive, a list-flattening function can be implemented (NIX-55, example is in tests/lang/eval-okay-flatten.nix).
2006-09-22 10:55:19 -04:00
l
=
[
"
1
"
"
2
"
[
"
3
"
[
"
4
"
]
[
"
5
"
"
6
"
]
]
"
7
"
]
;
body
=
concat
(
flatten
l
)
;
}
Copy permalink