-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Open
Description
Is your feature request related to a problem? Please describe.
Consider the following code
cpdef bint f(long x):
return bool(x)
this correctly returns True if x ≠ 0 and False otherwise, but needs to pass to Python.
On the other hand, this
cpdef bint f(long x):
return x
incorrectly returns False for 2**32.
Describe the solution you'd like.
Optimize the former.
Describe alternatives you've considered.
Currently return x != 0 works.
Additional context
No response