New submission from Serhiy Storchaka <storchaka+cpyt...@gmail.com>:

The proposed PR adds two private helpers

#define _PyAnyInt_Check(op) (PyInt_Check(op) || PyLong_Check(op))
#define _PyAnyInt_CheckExact(op) (PyInt_CheckExact(op) || PyLong_CheckExact(op))

and make it used it in the code. This may help to avoid bugs like issue34229.

----------
components: Interpreter Core
messages: 322415
nosy: benjamin.peterson, serhiy.storchaka
priority: normal
severity: normal
status: open
title: Use _PyAnyInt_Check() and _PyAnyInt_CheckExact() in 2.7
versions: Python 2.7

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue34234>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to