lix-releng-staging/tests/lang/eval-okay-callable-attrs.nix
Shea Levy 997defa166 Add functors (callable attribute sets).
With this, attribute sets with a `__functor` attribute can be applied
just like normal functions. This can be used to attach arbitrary
metadata to a function without callers needing to treat it specially.
2014-11-15 16:12:05 -05:00

2 lines
79 B
Nix

({ __functor = self: x: self.foo && x; foo = false; } // { foo = true; }) true