lib: fix functionArgs for functors
`functionArgs` should give valid results on functions that have been identified with `lib.isFunction` instead of erroring out. (cherry picked from commit cf8e219b7e3c8933d6301175f2611990c5281ae9)
This commit is contained in:
committed by
github-actions[bot]
parent
2bd2119bf3
commit
e07870c95e
@@ -132,6 +132,16 @@ runTests {
|
||||
expected = [ 1 1 0 ];
|
||||
};
|
||||
|
||||
testFunctionArgsFunctor = {
|
||||
expr = functionArgs { __functor = self: { a, b }: null; };
|
||||
expected = { a = false; b = false; };
|
||||
};
|
||||
|
||||
testFunctionArgsSetFunctionArgs = {
|
||||
expr = functionArgs (setFunctionArgs (args: args.x) { x = false; });
|
||||
expected = { x = false; };
|
||||
};
|
||||
|
||||
# STRINGS
|
||||
|
||||
testConcatMapStrings = {
|
||||
|
||||
Reference in New Issue
Block a user