Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use a compatibility function for method comparison
This is a rough attempt at building a compatibility function that allows us to detect whether an object defines its own __reduce__ or __reduce_ex__ on any interpreter. Some versions of PyPy 2.7 don't seem to return True with "is" comparisons, and instead require ==. I have arbitrarily chosen int as a builtin that derives from object and doesn't define its own __reduce__. I think this is fairly safe to do in 2.7-only code, since it is stable now.
- Loading branch information