diff options
-rw-r--r-- | yants.nix | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/yants.nix b/yants.nix index c5fff0ea7d0f..e7b758f4b955 100644 --- a/yants.nix +++ b/yants.nix @@ -78,8 +78,9 @@ in (typeSet [ (typedef "bool" isBool) (typedef "float" isFloat) (typedef "string" isString) - (typedef "derivation" (ofType "derivation")) - + (typedef "derivation" (x: isAttrs x && x ? "type" && x.type == "derivation")) + (typedef "function" (x: isFunction x || (isAttrs x && x ? "__functor" + && isFunction x.__functor))) # Polymorphic types (poly "option" (t: v: (isNull v) || t.check v)) |