Skip to content

Commit 6b98557

Browse files
committed
add assert
1 parent c37cb23 commit 6b98557

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Objects/longobject.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ static inline int
5252
/// Return 1 if the object is one of the immortal small ints
5353
_long_is_small_int(PyObject *op)
5454
{
55+
assert(PyLong_Check(op));
5556
PyLongObject *long_object = (PyLongObject *)op;
5657
int is_small_int = (long_object->long_value.lv_tag & IMMORTALITY_BIT_MASK) != 0;
5758
assert((!is_small_int) || PyLong_CheckExact(op));

0 commit comments

Comments
 (0)