Skip to content
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

Add __declspec(empty_bases) to derived structs for size optimization #128

Merged
merged 2 commits into from
Jan 3, 2022
Merged

Add __declspec(empty_bases) to derived structs for size optimization #128

merged 2 commits into from
Jan 3, 2022

Conversation

mathysie
Copy link
Contributor

This ensures for example that a strong type double inheriting floating_point_arithmetic remains having the same size as a double

This ensures for example that a strong type double inheriting floating_point_arithmetic remains having the same size as a double
@mathysie
Copy link
Contributor Author

Fixes issue #124

@foonathan
Copy link
Owner

This does not work on non-MSVC compilers, please wrap it in an appropriate macro.

@foonathan foonathan merged commit 2809f17 into foonathan:main Jan 3, 2022
@foonathan
Copy link
Owner

Thank you!

@mathysie mathysie deleted the add_declspec_empty_bases_to_structs branch January 3, 2022 08:23
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.

3 participants