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

Export macros in a Rust 2018 friendly way #420

Open
alatiera opened this Issue Dec 31, 2018 · 1 comment

Comments

Projects
None yet
2 participants
@alatiera
Copy link
Contributor

alatiera commented Dec 31, 2018

Before macros were imported with the [macro_use] attribute above the extern crate declaration. With rust 2018 though, this is no longer needed and macros can be imported with just use. Currently you would need to import weird paths to do so, and the codebase is not does not handle the new module system well.

Not sure how other crates handle this, or if exporting them in the prelude it will be enough, but ideally it would be something simple to do so.

ex. use glib::prelude::glib_object_subclass

@sdroege

This comment has been minimized.

Copy link
Member

sdroege commented Dec 31, 2018

Alternatively one could probably also re-export them from lib.rs and then they can be accessed via glib::object_subclass!, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.