diff --git a/typed_python/compiler/tests/any_all_compilation_test.py b/typed_python/compiler/tests/any_all_compilation_test.py index 366d14bd..57d770c0 100644 --- a/typed_python/compiler/tests/any_all_compilation_test.py +++ b/typed_python/compiler/tests/any_all_compilation_test.py @@ -32,3 +32,5 @@ def callAll(x): assert callAll(T([1, 2, 3])) == all(T([1, 2, 3])) assert callAny(T([0, 0, 0])) == any(T([0, 0, 0])) assert callAll(T([0, 0, 0])) == all(T([0, 0, 0])) + assert callAny(T([0, 1, 2])) == any(T([0, 1, 2])) + assert callAll(T([0, 1, 2])) == all(T([0, 1, 2])) diff --git a/typed_python/compiler/type_wrappers/all_any_wrapper.py b/typed_python/compiler/type_wrappers/all_any_wrapper.py index b19447fe..ba8ebb17 100644 --- a/typed_python/compiler/type_wrappers/all_any_wrapper.py +++ b/typed_python/compiler/type_wrappers/all_any_wrapper.py @@ -59,4 +59,4 @@ def getNativeLayoutType(self): return native_ast.Type.Struct() def convert_call(self, context, expr, args, kwargs): - return context.call_py_function(all, args, kwargs) + return context.call_py_function(any, args, kwargs)