Skip to content

[cppyy] Add converters and low-level views for fixed width integers #18492

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

aaronj0
Copy link
Contributor

@aaronj0 aaronj0 commented Apr 24, 2025

fixes: #17841

The support for the fixed-width types int16_t and int32_t indeed diverges from upstream cppyy and uses unsigned long which triggers the incorrect numpy view. Despite not having converters for the same, upstream relies on patches (or older behaviour) along the Cppyy::ResolveName -> TClassEdit::ResolveTypedef code path (see ResolveTypeDefImpl) that resolved fixed width integer types to their standard type counterparts (int16_t[][] to short[][] and int32_t[][] to int[][]) when creating converters. Trying to follow the same code branch in ROOT can have a large blast radius in the type system. Two non-intrusive ways to fix this issue are either aliasing to existing short and int converters, or adding the converters and low-level views for both types. This PR performs the latter

@aaronj0 aaronj0 requested review from guitargeek, dpiparo and vepadulano and removed request for dpiparo and vepadulano April 24, 2025 11:59
@aaronj0 aaronj0 self-assigned this Apr 24, 2025
@aaronj0 aaronj0 marked this pull request as draft April 24, 2025 12:13
Copy link

Test Results

    17 files      17 suites   3d 23h 32m 29s ⏱️
 2 731 tests  2 731 ✅ 0 💤 0 ❌
45 048 runs  45 048 ✅ 0 💤 0 ❌

Results for commit 9f88d46.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

PyROOT multidimenstional int16_t arrays stopped working in 6.34
1 participant