nix/tests/lang/eval-okay-xml.nix
Eelco Dolstra efe4b690ae * Refactoring: combine functions that take an attribute set and
functions that take a single argument (plain lambdas) into one AST
  node (Function) that contains a Pattern node describing the
  arguments.  Current patterns are single lazy arguments (VarPat) and
  matching against an attribute set (AttrsPat).

  This refactoring allows other kinds of patterns to be added easily,
  such as Haskell-style @-patterns, or list pattern matching.
2008-08-14 10:04:22 +00:00

16 lines
123 B
Nix

rec {
x = 123;
a = "foo";
b = "bar";
c = "foo" + "bar";
f = {z, x, y}: if y then x else z;
id = x: x;
}