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

Merge imports fix #3753

Merged
merged 2 commits into from Aug 27, 2019
Merged

Merge imports fix #3753

merged 2 commits into from Aug 27, 2019

Conversation

valff
Copy link
Contributor

@valff valff commented Aug 25, 2019

Fixes #3750

As per rust-lang/rust#60941 (comment), rustc works as intended. This PR solves the issue by avoiding self in path segments of depth past 2.

use self::foo; // it's fine
use foo::{self, bar}; // `foo` can't be a function/macro
// Intentional duplication of `vec` segment, because `vec` can be a function/macro
use alloc::{vec, vec::Vec};

@valff
Copy link
Contributor Author

valff commented Aug 25, 2019

@topecongiro topecongiro merged commit ef00f74 into rust-lang:master Aug 27, 2019
@topecongiro
Copy link
Contributor

Thanks!

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.

Formatting changes semantics of imports
2 participants