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

Correctly generate glib::Error import #863

Merged
merged 1 commit into from Oct 23, 2019

Conversation

@GuillaumeGomez
Copy link
Member

GuillaumeGomez commented Oct 23, 2019

fn strip_crate_name<'a>(&self, name: &'a str) -> Option<&'a str> {
fn strip_crate_name<'a>(&self, mut name: &'a str) -> Option<&'a str> {
if name == "Error" && self.crate_name != "glib" {
name = "glib::Error";

This comment has been minimized.

Copy link
@sdroege

sdroege Oct 23, 2019

Member

This does not seem correct. Why does it even end up here without the glib:: prefix?

This comment has been minimized.

Copy link
@GuillaumeGomez

GuillaumeGomez Oct 23, 2019

Author Member

This is actually an excellent question. Since it's part of manual imports everytime, it *should* not be needed. This fix is therefore incomplete. I need to find what's going on.

@GuillaumeGomez GuillaumeGomez force-pushed the GuillaumeGomez:correct-error-import branch from 0a78a3c to 1321e31 Oct 23, 2019
@GuillaumeGomez

This comment has been minimized.

Copy link
Member Author

GuillaumeGomez commented Oct 23, 2019

I now extended the fix. Way cleaner, better, faster, etc. :)

@GuillaumeGomez GuillaumeGomez force-pushed the GuillaumeGomez:correct-error-import branch from 1321e31 to 03f218f Oct 23, 2019
@GuillaumeGomez

This comment has been minimized.

Copy link
Member Author

GuillaumeGomez commented Oct 23, 2019

And now with fixed formatting.

@GuillaumeGomez

This comment has been minimized.

Copy link
Member Author

GuillaumeGomez commented Oct 23, 2019

@EPashkin

This comment has been minimized.

Copy link
Member

EPashkin commented Oct 23, 2019

@GuillaumeGomez Thanks, I will wait for @sdroege just in case

@sdroege

This comment has been minimized.

Copy link
Member

sdroege commented Oct 23, 2019

👍

@EPashkin EPashkin merged commit 2bb6380 into gtk-rs:master Oct 23, 2019
2 checks passed
2 checks passed
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@GuillaumeGomez GuillaumeGomez deleted the GuillaumeGomez:correct-error-import branch Oct 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.