Ticket #688 (closed defect: fixed)
incorrect return values of optimised builtin functions/methods
| Reported by: | scoder | Owned by: | scoder |
|---|---|---|---|
| Priority: | major | Milestone: | 0.15 |
| Component: | Python Semantics | Keywords: | |
| Cc: |
Description (last modified by scoder) (diff)
In Python, calls to setattr() or some_list.sort() return None. When optimised in Cython, they return 0 on success or -1 on error instead. The 0 return value is visible to user code.
Plus, Cython currently fails to handle the return value in some cases, so using the return value as Python object can crash as the value may not even get coerced.
This was found in a CPython unit test which tests the return value.
Change History
Note: See
TracTickets for help on using
tickets.
