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

Private enums and constants included in header file #1012

Open
lukasvrenner opened this issue Oct 16, 2024 · 0 comments
Open

Private enums and constants included in header file #1012

lukasvrenner opened this issue Oct 16, 2024 · 0 comments

Comments

@lukasvrenner
Copy link

lukasvrenner commented Oct 16, 2024

I have a bunch of repr(u8) or repr(u16) enums in my project. They are marked with pub, but aren't loaded with pub mod, only mod. Therefore, they're not part of the public API. For some of them (but not all!) cbindgen generates their definitions in the output header file, as well as a few locally public (but still private to the public API). Additionally, arbitrary unused headers are included (such as stdlib.h, stdarg.h, etc).

I have tried it using both the default config file found in the docs, as well as an empty config file, and both resulting in the dane weird quirk. Maybe I'm doing something wrong, but this seems like really strange default behavior.

Thank you for all of your hard work!

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

No branches or pull requests

1 participant