8000 Fix error in Rust 2018 + no_core environment by taiki-e · Pull Request #59462 · rust-lang/rust · GitHub
[go: up one dir, main page]

Skip to content

Fix error in Rust 2018 + no_core environment #59462

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

Merged
merged 2 commits into from
Mar 29, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix error in Rust 2018 + no_core environment
  • Loading branch information
taiki-e committed Mar 29, 2019
commit 362d2439bdd221b0efa4f0d28bb51bfde0ea9484
7 changes: 6 additions & 1 deletion src/librustc_resolve/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1697,7 +1697,12 @@ impl<'a> hir::lowering::Resolver for Resolver<'a> {
components: &[&str],
is_value: bool
) -> hir::Path {
let segments = iter::once(keywords::PathRoot.ident())
let root = if crate_root.is_some() {
keywords::PathRoot
} else {
keywords::Crate
};
let segments = iter::once(root.ident())
.chain(
crate_root.into_iter()
.chain(components.iter().cloned())
Expand Down
0