Skip to content

reduce FnArg::Regular variant size (#5039)#5787

Open
luxedo wants to merge 1 commit intoPyO3:mainfrom
luxedo:5039/reduce-fnarg-regular-variant-size
Open

reduce FnArg::Regular variant size (#5039)#5787
luxedo wants to merge 1 commit intoPyO3:mainfrom
luxedo:5039/reduce-fnarg-regular-variant-size

Conversation

@luxedo
Copy link

@luxedo luxedo commented Feb 9, 2026

Fixes #5039

I boxed the two fields @ngoldbaum suggested. New struct size:

print-type-size type: `method::RegularArg<'_>`: 56 bytes, alignment: 8 bytes
print-type-size     field `.from_py_with`: 8 bytes
print-type-size     field `.default_value`: 8 bytes
print-type-size     field `.option_wrapped_type`: 8 bytes
print-type-size     field `.ty`: 8 bytes
print-type-size     field `.name`: 24 bytes

@luxedo luxedo force-pushed the 5039/reduce-fnarg-regular-variant-size branch from 2593451 to c2ad7c3 Compare February 9, 2026 01:25
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.

Reduce the size of FnArg::Regular variant (macro-backends)

1 participant