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

Allow tweaking visibility #1292

Merged
merged 10 commits into from Dec 30, 2021

Conversation

bilelmoussaoui
Copy link
Member

@bilelmoussaoui bilelmoussaoui commented Dec 26, 2021

This PR allows to tweak the visibility of functions/enums/flags & also objects/records. For global functions that are marked as non-public, they also have a #[allow(dead_code)] guard added to avoid any clippy complaints.

Fixes #1238
cc @lucab

@bilelmoussaoui
Copy link
Member Author

You can see the glib crate re-generated with the changes of this PR at gtk-rs/gtk-rs-core@27e611d

src/codegen/visibility.rs Outdated Show resolved Hide resolved
@bilelmoussaoui bilelmoussaoui force-pushed the bilelmoussaoui/func-visibility branch 24 times, most recently from d755fb0 to ff7d3f9 Compare December 27, 2021 13:51
Copy link
Member

@sdroege sdroege left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me otherwise

@bilelmoussaoui
Copy link
Member Author

Updated & added documentation to the book

@sdroege sdroege merged commit 8fcb6df into gtk-rs:master Dec 30, 2021
@bilelmoussaoui bilelmoussaoui deleted the bilelmoussaoui/func-visibility branch December 30, 2021 09:54
@lucab
Copy link
Contributor

lucab commented Jan 3, 2022

Thanks for landing this!

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.

Support custom visibility on generated functions
3 participants