-
Notifications
You must be signed in to change notification settings - Fork 142
Closed
Description
I was trying to build cffi wheel with GraalPy, but tests are failing on GraalPy because of an inconsistency with the CPython implementation. The code below raises an OverflowError with CPython but doesn't with GraalPy.
import pytest
import sys
from _cffi_backend import new_primitive_type, new_pointer_type, new_array_type
def test_graalpy_overflow_behavior_on_large_array_size():
"""
This test asserts that creating an array type with a size larger than
sys.maxsize raises an OverflowError.
Expected behavior:
- CPython: Should raise OverflowError. Test will PASS.
- GraalPy: Should NOT raise OverflowError. Test will FAIL.
"""
p = new_primitive_type("int")
pytest.raises(OverflowError, new_array_type, new_pointer_type(p), sys.maxsize + 1)
Metadata
Metadata
Assignees
Labels
No labels