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

Fix lifetime on LocalInternedString::get function #59227

Merged
merged 2 commits into from
Apr 12, 2019
Merged

Conversation

Zoxc
Copy link
Contributor

@Zoxc Zoxc commented Mar 16, 2019

panic!("`{:?}` is not a valid identifier", string)
}
if is_raw {
let normalized_sym = Symbol::intern(string);
let normalized_sym = sym.interned();
Copy link
Contributor

Choose a reason for hiding this comment

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

Re-interning here was intentional (to get rid of possible gensyms before checking).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hence the interned call.

@@ -2160,9 +2160,11 @@ impl<'a> Parser<'a> {
suffix,
) = self.token {
let suffix = suffix.and_then(|s| {
let s = s.as_str().get();
if ["f32", "f64"].contains(&s) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Hm, shouldn't this keep working with non-static lifetime?
Also, a typo "f64f64" below.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No, the LocalInternedString is dropped in the first statement here.

Copy link
Contributor

Choose a reason for hiding this comment

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

I assume this is going to ruin the fn ident_str API in #58899 then.
Treating an attribute name as &str (including matching on it, calling contains) is a common operation, so returning Option<LocalInternedString> instead and mapping on it every time would be a serious usability hit.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah. fn ident_str won't work. We should really use symbols for attribute names instead of comparing strings all the time.

Copy link
Contributor

Choose a reason for hiding this comment

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

True, the issue is just that a lot of existing code across rustc uses strings.

Copy link
Contributor

Choose a reason for hiding this comment

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

Addressed in #59256

@@ -515,7 +515,7 @@ impl LocalInternedString {
}
}

pub fn get(&self) -> &'static str {
pub fn get(&self) -> &str {
Copy link
Member

Choose a reason for hiding this comment

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

Please add a comment and maybe an ui-fulldeps test, to ensure this doesn't happen again?
And maybe self.string should be *const str instead.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I made this use unsafe code. That should prevent people from modifying this without reading comments.

@bors
Copy link
Contributor

bors commented Mar 17, 2019

☔ The latest upstream changes (presumably #58899) made this pull request unmergeable. Please resolve the merge conflicts.

@bors bors added the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Mar 17, 2019
@Centril
Copy link
Contributor

Centril commented Mar 17, 2019

r? @eddyb

@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-6.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
travis_time:end:08daefbe:start=1553076140374605868,finish=1553076142963748679,duration=2589142811
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#pull-requests-and-security-restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
$ export GCP_CACHE_BUCKET=rust-lang-ci-cache
Setting environment variables from .travis.yml
---
[00:07:02]    Compiling rustc_macros v0.1.0 (/checkout/src/librustc_macros)
[00:07:13] error[E0515]: cannot return value referencing temporary value
[00:07:13]   --> src/libsyntax/attr/mod.rs:93:33
[00:07:13]    |
[00:07:13] 93 |         self.ident().map(|name| name.as_str().get())
[00:07:13]    |                                 |
[00:07:13]    |                                 returns a value referencing data owned by the current function
[00:07:13]    |                                 temporary value created here
[00:07:13] 
[00:07:13] 
[00:07:13] error[E0515]: cannot return value referencing temporary value
[00:07:13]    --> src/libsyntax/attr/mod.rs:171:33
[00:07:13]     |
[00:07:13] 171 |         self.ident().map(|name| name.as_str().get())
[00:07:13]     |                                 |
[00:07:13]     |                                 returns a value referencing data owned by the current function
[00:07:13]     |                                 temporary value created here
[00:07:13] 
[00:07:13] 
[00:07:13] error[E0515]: cannot return value referencing temporary value
[00:07:13]    --> src/libsyntax/attr/mod.rs:209:33
[00:07:13]     |
[00:07:13] 209 |         self.ident().map(|name| name.as_str().get())
[00:07:13]     |                                 |
[00:07:13]     |                                 returns a value referencing data owned by the current function
[00:07:13]     |                                 temporary value created here
[00:07:13] 

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@nnethercote
Copy link
Contributor

Thanks for fixing this, @Zoxc. It's certainly an interesting lesson for me in the potential non-local effects of unsafe.

}
}

impl<T: std::ops::Deref<Target = str>> std::cmp::PartialEq<T> for LocalInternedString {
fn eq(&self, other: &T) -> bool {
self.string == other.deref()
self.get() == other.deref()
Copy link
Member

Choose a reason for hiding this comment

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

IMO one should write *other rather than .deref().

@@ -530,37 +536,37 @@ where
str: std::convert::AsRef<U>
{
fn as_ref(&self) -> &U {
self.string.as_ref()
self.get().as_ref()
}
}

impl<T: std::ops::Deref<Target = str>> std::cmp::PartialEq<T> for LocalInternedString {
Copy link
Member

Choose a reason for hiding this comment

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

Actually, isn't AsRef<str> common practice in these sort of situations?

}
}

impl std::cmp::PartialEq<LocalInternedString> for String {
fn eq(&self, other: &LocalInternedString) -> bool {
self == other.string
self == other.get()
}
}

impl<'a> std::cmp::PartialEq<LocalInternedString> for &'a String {
Copy link
Member

Choose a reason for hiding this comment

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

There are too many of these, maybe a macro should be used (which can do *other == *self, I think).

@eddyb
Copy link
Member

eddyb commented Mar 21, 2019

r=me with nits fixed (if at all, they're kind of inconsequential)

@@ -510,18 +510,24 @@ fn with_interner<T, F: FnOnce(&mut Interner) -> T>(f: F) -> T {
// by creating a new thread right after constructing the interner.
#[derive(Clone, Copy, Hash, PartialOrd, Eq, Ord)]
pub struct LocalInternedString {
string: &'static str,
string: *const str,
Copy link
Member

Choose a reason for hiding this comment

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

I just realized this should probably be NonNull<str>.

@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-6.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
travis_time:end:04c5f6e9:start=1553534370393592516,finish=1553534372674289101,duration=2280696585
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#pull-requests-and-security-restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
$ export GCP_CACHE_BUCKET=rust-lang-ci-cache
Setting environment variables from .travis.yml
---
[01:12:45] ..........................................i......................................................... 600/5488
[01:12:50] .................................................................................................... 700/5488
[01:12:54] .................................................................................................... 800/5488
[01:12:58] .................................................................................................... 900/5488
[01:13:03] .i...............i.................................................................................. 1000/5488
[01:13:06] ..................F.............iiiii............................................................... 1100/5488
[01:13:09] ...................................................................................F................ 1200/5488
[01:13:14] .................................................................................................... 1400/5488
[01:13:18] .................................................................................................... 1500/5488
[01:13:20] .................................................................................................... 1600/5488
[01:13:24] .........................................i.......................................................... 1700/5488
---
[01:13:41] .................................................................................................... 2200/5488
[01:13:45] .................................................................................................... 2300/5488
[01:13:50] .................................................................................................... 2400/5488
[01:13:55] .................................................................................................... 2500/5488
[01:13:58] .........................................................................................F.......... 2600/5488
[01:14:08] .................................................................................................... 2800/5488
[01:14:12] .................................................................................................... 2900/5488
[01:14:16] .................................................................................................... 3000/5488
[01:14:16] .................................................................................................... 3000/5488
[01:14:20] ..........................F......................................................................... 3100/5488
[01:14:28] .................................................................................................... 3300/5488
[01:14:31] .....i.............................................................................................. 3400/5488
[01:14:35] ...............................................................................ii...i..ii........... 3500/5488
[01:14:39] .................................................................................................... 3600/5488
---
[01:14:56] .................................................................................................... 4200/5488
[01:15:04] .................................................................................................... 4300/5488
[01:15:12] .................................................................................................... 4400/5488
[01:15:15] .................................................................................................... 4500/5488
[01:15:19] ..............................................................F..................................... 4600/5488
[01:15:31] .................................................................................................... 4800/5488
[01:15:34] .................................................................................................... 4900/5488
[01:15:38] .................................................................................................... 5000/5488
[01:15:43] .................................................................................................... 5100/5488
---
[01:15:56] 
[01:15:56] 5    |             ^^^^^^
[01:15:56] 6 help: try using one of the enum's variants
[01:15:56] 7    |
[01:15:56] - LL |     let x = std::prelude::v1::Option::None(1);
[01:15:56] -    |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[01:15:56] - LL |     let x = std::prelude::v1::Option::Some(1);
[01:15:56] + LL |     let x = std::option::Option::None(1);
[01:15:56] +    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
[01:15:56] + LL |     let x = std::option::Option::Some(1);
[01:15:56] +    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
[01:15:56] +    |             ^^^^^^^^^^^^^^^^^^^^^^^^^
[01:15:56] 12 
[01:15:56] 13 error[E0532]: expected tuple struct/variant, found enum `Option`
[01:15:56] 14   --> $DIR/issue-43871-enum-instead-of-variant.rs:21:12
[01:15:56] 
[01:15:56] 17    |            ^^^^^^
[01:15:56] 18 help: try using one of the enum's variants
[01:15:56] 19    |
[01:15:56] - LL |     if let std::prelude::v1::Option::None(_) = x {
[01:15:56] -    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[01:15:56] - LL |     if let std::prelude::v1::Option::Some(_) = x {
[01:15:56] -    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[01:15:56] + LL |     if let std::option::Option::None(_) = x {
[01:15:56] +    |            ^^^^^^^^^^^^^^^^^^^^^^^^^
[01:15:56] + LL |     if let std::option::Option::Some(_) = x {
[01:15:56] 24 
[01:15:56] 24 
[01:15:56] 25 error[E0532]: expected tuple struct/variant, found enum `Example`
[01:15:56] 
[01:15:56] 47    |             ^^^^^^^^^^^^
[01:15:56] 48 help: try using one of the enum's variants
[01:15:56] 49    |
[01:15:56] 49    |
[01:15:56] - LL |     let z = ManyVariants::Eight();
[01:15:56] + LL |     let z = ManyVariants::One();
[01:15:56] +    |             ^^^^^^^^^^^^^^^^^
[01:15:56] + LL |     let z = ManyVariants::Two();
[01:15:56] +    |             ^^^^^^^^^^^^^^^^^
[01:15:56] + LL |     let z = ManyVariants::Three();
[01:15:56] 51    |             ^^^^^^^^^^^^^^^^^^^
[01:15:56] - LL |     let z = ManyVariants::Five();
[01:15:56] -    |             ^^^^^^^^^^^^^^^^^^
[01:15:56] 54 LL |     let z = ManyVariants::Four();
[01:15:56] -    |             ^^^^^^^^^^^^^^^^^^
[01:15:56] - LL |     let z = ManyVariants::Nine();
[01:15:56] 58 and 6 other candidates
[01:15:56] 59 
[01:15:56] 
[01:15:56] 
[01:15:56] 
[01:15:56] The actual stderr differed from the expected stderr.
[01:15:56] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/did_you_mean/issue-43871-enum-instead-of-variant/issue-43871-enum-instead-of-variant.stderr
[01:15:56] To update references, rerun the tests and pass the `--bless` flag
[01:15:56] To only update this specific test, also pass `--test-args did_you_mean/issue-43871-enum-instead-of-variant.rs`
[01:15:56] error: 1 errors occurred comparing output.
[01:15:56] status: exit code: 1
[01:15:56] status: exit code: 1
[01:15:56] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/did_you_mean/issue-43871-enum-instead-of-variant/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/did_you_mean/issue-43871-enum-instead-of-variant/auxiliary" "-A" "unused"
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] stderr:
[01:15:56] stderr:
[01:15:56] ------------------------------------------
[01:15:56] {"message":"expected function, found enum `Option`","code":{"code":"E0423","explanation":"\nAn identifier was used like a function name or a value was expected and the\nidentifier exists but it belongs to a different namespace.\n\nFor (an erroneous) example, here a `struct` variant name were used as a\nfunction:\n\n```compile_fail,E0423\nstruct Foo { a: bool };\n\nlet f = Foo();\n// error: expected function, found `Foo`\n// `Foo` is a struct name, but this expression uses it like a function name\n```\n\nPlease verify you didn't misspell the name of what you actually wanted to use\nhere. Example:\n\n```\nfn Foo() -> u32 { 0 }\n\nlet f = Foo(); // ok!\n```\n\nIt is common to forget the trailing `!` on macro invocations, which would also\nyield this error:\n\n```compile_fail,E0423\nprintln(\"\");\n// error: expected function, found macro `println`\n// did you mean `println!(...)`? (notice the trailing `!`)\n```\n\nAnother case where this error is emitted is when a value is expected, but\nsomething else is found:\n\n```compile_fail,E0423\npub mod a {\n    pub const I: i32 = 1;\n}\n\nfn h1() -> i32 {\n    a.I\n    //~^ ERROR expected value, found module `a`\n    // did you mean `a::I`?\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":203,"byte_end":209,"line_start":19,"line_end":19,"column_start":13,"column_end":19,"is_primary":true,"text":[{"text":"    let x = Option(1); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":19}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"try using one of the enum's variants","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":203,"byte_end":209,"line_start":19,"line_end":19,"column_start":13,"column_end":19,"is_primary":true,"text":[{"text":"    let x = Option(1); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":19}],"label":null,"suggested_replacement":"std::option::Option::None","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":203,"byte_end":209,"line_start":19,"line_end":19,"column_start":13,"column_end":19,"is_primary":true,"text":[{"text":"    let x = Option(1); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":19}],"label":null,"suggested_replacement":"std::option::Option::Some","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0423]: expected function, found enum `Option`\n  --> /checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs:19:13\n   |\nLL |     let x = Option(1); //~ ERROR expected function, found enum\n   |             ^^^^^^\nhelp: try using one of the enum's variants\n   |\nLL |     let x = std::option::Option::None(1); //~ ERROR expected function, found enum\n   |             ^^^^^^^^^^^^^^^^^^^^^^^^^\nLL |     let x = std::option::Option::Some(1); //~ ERROR expected function, found enum\n   |             ^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[01:15:56] {"message":"expected tuple struct/variant, found enum `Option`","code":{"code":"E0532","explanation":"\nPattern arm did not match expected kind.\n\nErroneous code example:\n\n```compile_fail,E0532\nenum State {\n    Succeeded,\n    Failed(String),\n}\n\nfn print_on_failure(state: &State) {\n    match *state {\n        // error: expected unit struct/variant or constant, found tuple\n        //        variant `State::Failed`\n        State::Failed => println!(\"Failed\"),\n        _ => ()\n    }\n}\n```\n\nTo fix this error, ensure the match arm kind is the same as the expression\nmatched.\n\nFixed example:\n\n```\nenum State {\n    Succeeded,\n    Failed(String),\n}\n\nfn print_on_failure(state: &State) {\n    match *state {\n        State::Failed(ref msg) => println!(\"Failed with {}\", msg),\n        _ => ()\n    }\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":266,"byte_end":272,"line_start":21,"line_end":21,"column_start":12,"column_end":18,"is_primary":true,"text":[{"text":"    if let Option(_) = x { //~ ERROR expected tuple struct/variant, found enum","highlight_start":12,"highlight_end":18}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"try using one of the enum's variants","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":266,"byte_end":272,"line_start":21,"line_end":21,"column_start":12,"column_end":18,"is_primary":true,"text":[{"text":"    if let Option(_) = x { //~ ERROR expected tuple struct/variant, found enum","highlight_start":12,"highlight_end":18}],"label":null,"suggested_replacement":"std::option::Option::None","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":266,"byte_end":272,"line_start":21,"line_end":21,"column_start":12,"column_end":18,"is_primary":true,"text":[{"text":"    if let Option(_) = x { //~ ERROR expected tuple struct/variant, found enum","highlight_start":12,"highlight_end":18}],"label":null,"suggested_replacement":"std::option::Option::Some","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0532]: expected tuple struct/variant, found enum `Option`\n  --> /checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs:21:12\n   |\nLL |     if let Option(_) = x { //~ ERROR expected tuple struct/variant, found enum\n   |            ^^^^^^\nhelp: try using one of the enum's variants\n   |\nLL |     if let std::option::Option::None(_) = x { //~ ERROR expected tuple struct/variant, found enum\n   |            ^^^^^^^^^^^^^^^^^^^^^^^^^\nLL |     if let std::option::Option::Some(_) = x { //~ ERROR expected tuple struct/variant, found enum\n   |            ^^^^^^^^^^^^^^^^^^^^^^^^^\n\n"}
[01:15:56] {"message":"expected tuple struct/variant, found enum `Example`","code":{"code":"E0532","explanation":"\nPattern arm did not match expected kind.\n\nErroneous code example:\n\n```compile_fail,E0532\nenum State {\n    Succeeded,\n    Failed(String),\n}\n\nfn print_on_failure(state: &State) {\n    match *state {\n        // error: expected unit struct/variant or constant, found tuple\n        //        variant `State::Failed`\n        State::Failed => println!(\"Failed\"),\n        _ => ()\n    }\n}\n```\n\nTo fix this error, ensure the match arm kind is the same as the expression\nmatched.\n\nFixed example:\n\n```\nenum State {\n    Succeeded,\n    Failed(String),\n}\n\nfn print_on_failure(state: &State) {\n    match *state {\n        State::Failed(ref msg) => println!(\"Failed with {}\", msg),\n        _ => ()\n    }\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":431,"byte_end":438,"line_start":27,"line_end":27,"column_start":12,"column_end":19,"is_primary":true,"text":[{"text":"    if let Example(_) = y { //~ ERROR expected tuple struct/variant, found enum","highlight_start":12,"highlight_end":19}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"try using one of the enum's variants","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":431,"byte_end":438,"line_start":27,"line_end":27,"column_start":12,"column_end":19,"is_primary":true,"text":[{"text":"    if let Example(_) = y { //~ ERROR expected tuple struct/variant, found enum","highlight_start":12,"highlight_end":19}],"label":null,"suggested_replacement":"Example::Ex","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":431,"byte_end":438,"line_start":27,"line_end":27,"column_start":12,"column_end":19,"is_primary":true,"text":[{"text":"    if let Example(_) = y { //~ ERROR expected tuple struct/variant, found enum","highlight_start":12,"highlight_end":19}],"label":null,"suggested_replacement":"Example::NotEx","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0532]: expected tuple struct/variant, found enum `Example`\n  --> /checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs:27:12\n   |\nLL |     if let Example(_) = y { //~ ERROR expected tuple struct/variant, found enum\n   |            ^^^^^^^\nhelp: try using one of the enum's variants\n   |\nLL |     if let Example::Ex(_) = y { //~ ERROR expected tuple struct/variant, found enum\n   |            ^^^^^^^^^^^\nLL |     if let Example::NotEx(_) = y { //~ ERROR expected tuple struct/variant, found enum\n   |            ^^^^^^^^^^^^^^\n\n"}
[01:15:56] {"message":"expected function, found enum `Void`","code":{"code":"E0423","explanation":"\nAn identifier was used like a function name or a value was expected and the\nidentifier exists but it belongs to a different namespace.\n\nFor (an erroneous) example, here a `struct` variant name were used as a\nfunction:\n\n```compile_fail,E0423\nstruct Foo { a: bool };\n\nlet f = Foo();\n// error: expected function, found `Foo`\n// `Foo` is a struct name, but this expression uses it like a function name\n```\n\nPlease verify you didn't misspell the name of what you actually wanted to use\nhere. Example:\n\n```\nfn Foo() -> u32 { 0 }\n\nlet f = Foo(); // ok!\n```\n\nIt is common to forget the trailing `!` on macro invocations, which would also\nyield this error:\n\n```compile_fail,E0423\nprintln(\"\");\n// error: expected function, found macro `println`\n// did you mean `println!(...)`? (notice the trailing `!`)\n```\n\nAnother case where this error is emitted is when a value is expected, but\nsomething else is found:\n\n```compile_fail,E0423\npub mod a {\n    pub const I: i32 = 1;\n}\n\nfn h1() -> i32 {\n    a.I\n    //~^ ERROR expected value, found module `a`\n    // did you mean `a::I`?\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":550,"byte_end":554,"line_start":31,"line_end":31,"column_start":13,"column_end":17,"is_primary":true,"text":[{"text":"    let y = Void(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":17}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0423]: expected function, found enum `Void`\n  --> /checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs:31:13\n   |\nLL |     let y = Void(); //~ ERROR expected function, found enum\n   |             ^^^^\n\n"}
[01:15:56] {"message":"expected function, found enum `ManyVariants`","code":{"code":"E0423","explanation":"\nAn identifier was used like a function name or a value was expected and the\nidentifier exists but it belongs to a different namespace.\n\nFor (an erroneous) example, here a `struct` variant name were used as a\nfunction:\n\n```compile_fail,E0423\nstruct Foo { a: bool };\n\nlet f = Foo();\n// error: expected function, found `Foo`\n// `Foo` is a struct name, but this expression uses it like a function name\n```\n\nPlease verify you didn't misspell the name of what you actually wanted to use\nhere. Example:\n\n```\nfn Foo() -> u32 { 0 }\n\nlet f = Foo(); // ok!\n```\n\nIt is common to forget the trailing `!` on macro invocations, which would also\nyield this error:\n\n```compile_fail,E0423\nprintln(\"\");\n// error: expected function, found macro `println`\n// did you mean `println!(...)`? (notice the trailing `!`)\n```\n\nAnother case where this error is emitted is when a value is expected, but\nsomething else is found:\n\n```compile_fail,E0423\npub mod a {\n    pub const I: i32 = 1;\n}\n\nfn h1() -> i32 {\n    a.I\n    //~^ ERROR expected value, found module `a`\n    // did you mean `a::I`?\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"try using one of the enum's variants","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::One","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Two","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Three","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Four","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Five","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Six","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Seven","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Eight","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Nine","suggestion_applicability":"MaybeIncorrect","expansion":null},{"file_name":"/checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs","byte_start":611,"byte_end":623,"line_start":33,"line_end":33,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let z = ManyVariants(); //~ ERROR expected function, found enum","highlight_start":13,"highlight_end":25}],"label":null,"suggested_replacement":"ManyVariants::Ten","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0423]: expected function, found enum `ManyVariants`\n  --> /checkout/src/test/ui/did_you_mean/issue-43871-enum-instead-of-variant.rs:33:13\n   |\nLL |     let z = ManyVariants(); //~ ERROR expected function, found enum\n   |             ^^^^^^^^^^^^\nhelp: try using one of the enum's variants\n   |\nLL |     let z = ManyVariants::One(); //~ ERROR expected function, found enum\n   |             ^^^^^^^^^^^^^^^^^\nLL |     let z = ManyVariants::Two(); //~ ERROR expected function, found enum\n   |             ^^^^^^^^^^^^^^^^^\nLL |     let z = ManyVariants::Three(); //~ ERROR expected function, found enum\n   |             ^^^^^^^^^^^^^^^^^^^\nLL |     let z = ManyVariants::Four(); //~ ERROR expected function, found enum\n   |             ^^^^^^^^^^^^^^^^^^\nand 6 other candidates\n\n"}
[01:15:56] {"message":"aborting due to 5 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 5 previous errors\n\n"}
[01:15:56] {"message":"Some errors occurred: E0423, E0532.","code":null,"level":"","spans":[],"children":[],"rendered":"Some errors occurred: E0423, E0532.\n"}
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] thread '[ui] ui/did_you_mean/issue-43871-enum-instead-of-variant.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3369:9
[01:15:56] thread '[ui] ui/did_you_mean/issue-43871-enum-instead-of-variant.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3369:9
[01:15:56] note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
[01:15:56] 
[01:15:56] ---- [ui] ui/error-codes/E0063.rs stdout ----
[01:15:56] diff of stderr:
[01:15:56] 
[01:15:56] 10 LL |     let x = PluralFoo {x: 1};
[01:15:56] 11    |             ^^^^^^^^^ missing `y`, `z`
[01:15:56] 12 
[01:15:56] - error[E0063]: missing fields `a`, `b`, `y` and 1 other field in initializer of `TruncatedFoo`
[01:15:56] + error[E0063]: missing fields `y`, `z`, `a` and 1 other field in initializer of `TruncatedFoo`
[01:15:56] 14   --> $DIR/E0063.rs:36:13
[01:15:56] 15    |
[01:15:56] 16 LL |     let y = TruncatedFoo{x:1};
[01:15:56] 
[01:15:56] -    |             ^^^^^^^^^^^^ missing `a`, `b`, `y` and 1 other field
[01:15:56] +    |             ^^^^^^^^^^^^ missing `y`, `z`, `a` and 1 other field
[01:15:56] 18 
[01:15:56] - error[E0063]: missing fields `a`, `b`, `c` and 2 other fields in initializer of `TruncatedPluralFoo`
[01:15:56] + error[E0063]: missing fields `y`, `z`, `a` and 2 other fields in initializer of `TruncatedPluralFoo`
[01:15:56] 20   --> $DIR/E0063.rs:38:13
[01:15:56] 21    |
[01:15:56] 22 LL |     let z = TruncatedPluralFoo{x:1};
[01:15:56] 
[01:15:56] -    |             ^^^^^^^^^^^^^^^^^^ missing `a`, `b`, `c` and 2 other fields
[01:15:56] +    |             ^^^^^^^^^^^^^^^^^^ missing `y`, `z`, `a` and 2 other fields
[01:15:56] 25 error: aborting due to 4 previous errors
[01:15:56] 26 
[01:15:56] 
[01:15:56] 
[01:15:56] 
[01:15:56] The actual stderr differed from the expected stderr.
[01:15:56] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/error-codes/E0063/E0063.stderr
[01:15:56] To update references, rerun the tests and pass the `--bless` flag
[01:15:56] To only update this specific test, also pass `--test-args error-codes/E0063.rs`
[01:15:56] error: 1 errors occurred comparing output.
[01:15:56] status: exit code: 1
[01:15:56] status: exit code: 1
[01:15:56] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/error-codes/E0063.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/error-codes/E0063/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/error-codes/E0063/auxiliary" "-A" "unused"
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] stderr:
[01:15:56] stderr:
[01:15:56] ------------------------------------------
[01:15:56] {"message":"missing field `x` in initializer of `SingleFoo`","code":{"code":"E0063","explanation":"\nThis error indicates that during an attempt to build a struct or struct-like\nenum variant, one of the fields was not provided. Erroneous code example:\n\n```compile_fail,E0063\nstruct Foo {\n    x: i32,\n    y: i32,\n}\n\nfn main() {\n    let x = Foo { x: 0 }; // error: missing field: `y`\n}\n```\n\nEach field should be specified exactly once. Example:\n\n```\nstruct Foo {\n    x: i32,\n    y: i32,\n}\n\nfn main() {\n    let x = Foo { x: 0, y: 0 }; // ok!\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/error-codes/E0063.rs","byte_start":328,"byte_end":337,"line_start":32,"line_end":32,"column_start":13,"column_end":22,"is_primary":true,"text":[{"text":"    let w = SingleFoo { };","highlight_start":13,"highlight_end":22}],"label":"missing `x`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0063]: missing field `x` in initializer of `SingleFoo`\n  --> /checkout/src/test/ui/error-codes/E0063.rs:32:13\n   |\nLL |     let w = SingleFoo { };\n   |             ^^^^^^^^^ missing `x`\n\n"}
[01:15:56] {"message":"missing fields `y`, `z` in initializer of `PluralFoo`","code":{"code":"E0063","explanation":"\nThis error indicates that during an attempt to build a struct or struct-like\nenum variant, one of the fields was not provided. Erroneous code example:\n\n```compile_fail,E0063\nstruct Foo {\n    x: i32,\n    y: i32,\n}\n\nfn main() {\n    let x = Foo { x: 0 }; // error: missing field: `y`\n}\n```\n\nEach field should be specified exactly once. Example:\n\n```\nstruct Foo {\n    x: i32,\n    y: i32,\n}\n\nfn main() {\n    let x = Foo { x: 0, y: 0 }; // ok!\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/error-codes/E0063.rs","byte_start":418,"byte_end":427,"line_start":34,"line_end":34,"column_start":13,"column_end":22,"is_primary":true,"text":[{"text":"    let x = PluralFoo {x: 1};","highlight_start":13,"highlight_end":22}],"label":"missing `y`, `z`","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0063]: missing fields `y`, `z` in initializer of `PluralFoo`\n  --> /checkout/src/test/ui/error-codes/E0063.rs:34:13\n   |\nLL |     let x = PluralFoo {x: 1};\n   |             ^^^^^^^^^ missing `y`, `z`\n\n"}
[01:15:56] {"message":"missing fields `y`, `z`, `a` and 1 other field in initializer of `TruncatedFoo`","code":{"code":"E0063","explanation":"\nThis error indicates that during an attempt to build a struct or struct-like\nenum variant, one of the fields was not provided. Erroneous code example:\n\n```compile_fail,E0063\nstruct Foo {\n    x: i32,\n    y: i32,\n}\n\nfn main() {\n    let x = Foo { x: 0 }; // error: missing field: `y`\n}\n```\n\nEach field should be specified exactly once. Example:\n\n```\nstruct Foo {\n    x: i32,\n    y: i32,\n}\n\nfn main() {\n    let x = Foo { x: 0, y: 0 }; // ok!\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/error-codes/E0063.rs","byte_start":517,"byte_end":529,"line_start":36,"line_end":36,"column_start":13,"column_end":25,"is_primary":true,"text":[{"text":"    let y = TruncatedFoo{x:1};","highlight_start":13,"highlight_end":25}],"label":"missing `y`, `z`, `a` and 1 other field","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0063]: missing fields `y`, `z`, `a` and 1 other field in initializer of `TruncatedFoo`\n  --> /checkout/src/test/ui/error-codes/E0063.rs:36:13\n   |\nLL |     let y = TruncatedFoo{x:1};\n   |             ^^^^^^^^^^^^ missing `y`, `z`, `a` and 1 other field\n\n"}
[01:15:56] {"message":"missing fields `y`, `z`, `a` and 2 other fields in initializer of `TruncatedPluralFoo`","code":{"code":"E0063","explanation":"\nThis error indicates that during an attempt to build a struct or struct-like\nenum variant, one of the fields was not provided. Erroneous code example:\n\n```compile_fail,E0063\nstruct Foo {\n    x: i32,\n    y: i32,\n}\n\nfn main() {\n    let x = Foo { x: 0 }; // error: missing field: `y`\n}\n```\n\nEach field should be specified exactly once. Example:\n\n```\nstruct Foo {\n    x: i32,\n    y: i32,\n}\n\nfn main() {\n    let x = Foo { x: 0, y: 0 }; // ok!\n}\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/error-codes/E0063.rs","byte_start":637,"byte_end":655,"line_start":38,"line_end":38,"column_start":13,"column_end":31,"is_primary":true,"text":[{"text":"    let z = TruncatedPluralFoo{x:1};","highlight_start":13,"highlight_end":31}],"label":"missing `y`, `z`, `a` and 2 other fields","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0063]: missing fields `y`, `z`, `a` and 2 other fields in initializer of `TruncatedPluralFoo`\n  --> /checkout/src/test/ui/error-codes/E0063.rs:38:13\n   |\nLL |     let z = TruncatedPluralFoo{x:1};\n   |             ^^^^^^^^^^^^^^^^^^ missing `y`, `z`, `a` and 2 other fields\n\n"}
[01:15:56] {"message":"For more information about this error, try `rustc --explain E0063`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0063`.\n"}
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] 
---
[01:15:56] 
[01:15:56] 63    |             ^^^^
[01:15:56] 64    |             |
[01:15:56] 65    |             not a type
[01:15:56] -    |             help: try using the variant's enum: `Option`
[01:15:56] +    |             help: try using the variant's enum: `std::option::Option`
[01:15:56] 68 error: aborting due to 7 previous errors
[01:15:56] 69 
[01:15:56] 
[01:15:56] 
[01:15:56] 
[01:15:56] The actual stderr differed from the expected stderr.
[01:15:56] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-35675/issue-35675.stderr
[01:15:56] To update references, rerun the tests and pass the `--bless` flag
[01:15:56] To only update this specific test, also pass `--test-args issues/issue-35675.rs`
[01:15:56] error: 1 errors occurred comparing output.
[01:15:56] status: exit code: 1
[01:15:56] status: exit code: 1
[01:15:56] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/issues/issue-35675.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-35675/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-35675/auxiliary" "-A" "unused"
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] stderr:
[01:15:56] stderr:
[01:15:56] ------------------------------------------
[01:15:56] {"message":"cannot find type `Apple` in this scope","code":{"code":"E0412","explanation":"\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":167,"byte_end":172,"line_start":7,"line_end":7,"column_start":29,"column_end":34,"is_primary":true,"text":[{"text":"fn should_return_fruit() -> Apple {","highlight_start":29,"highlight_end":34}],"label":"not found in this scope","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"there is an enum variant `Fruit::Apple`; try using the variant's enum","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":167,"byte_end":172,"line_start":7,"line_end":7,"column_start":29,"column_end":34,"is_primary":true,"text":[{"text":"fn should_return_fruit() -> Apple {","highlight_start":29,"highlight_end":34}],"label":null,"suggested_replacement":"Fruit","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0412]: cannot find type `Apple` in this scope\n  --> /checkout/src/test/ui/issues/issue-35675.rs:7:29\n   |\nLL | fn should_return_fruit() -> Apple {\n   |                             ^^^^^ not found in this scope\nhelp: there is an enum variant `Fruit::Apple`; try using the variant's enum\n   |\nLL | fn should_return_fruit() -> Fruit {\n   |                             ^^^^^\n\n"}
[01:15:56] {"message":"cannot find function `Apple` in this scope","code":{"code":"E0425","explanation":"\nAn unresolved name was used.\n\nErroneous code examples:\n\n```compile_fail,E0425\nsomething_that_doesnt_exist::foo;\n// error: unresolved name `something_that_doesnt_exist::foo`\n\n// or:\n\ntrait Foo {\n    fn bar() {\n        Self; // error: unresolved name `Self`\n    }\n}\n\n// or:\n\nlet x = unknown_variable;  // error: unresolved name `unknown_variable`\n```\n\nPlease verify that the name wasn't misspelled and ensure that the\nidentifier being referred to is valid for the given situation. Example:\n\n```\nenum something_that_does_exist {\n    Foo,\n}\n```\n\nOr:\n\n```\nmod something_that_does_exist {\n    pub static foo : i32 = 0i32;\n}\n\nsomething_that_does_exist::foo; // ok!\n```\n\nOr:\n\n```\nlet unknown_variable = 12u32;\nlet x = unknown_variable; // ok!\n```\n\nIf the item is not defined in the current module, it must be imported using a\n`use` statement, like so:\n\n```\n# mod foo { pub fn bar() {} }\n# fn main() {\nuse foo::bar;\nbar();\n# }\n```\n\nIf the item you are importing is not defined in some super-module of the\ncurrent module, then it must also be declared as public (e.g., `pub fn`).\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":233,"byte_end":238,"line_start":9,"line_end":9,"column_start":5,"column_end":10,"is_primary":true,"text":[{"text":"    Apple(5)","highlight_start":5,"highlight_end":10}],"label":"not found in this scope","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"possible candidate is found in another module, you can import it into scope","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":90,"byte_end":90,"line_start":2,"line_end":2,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"enum Fruit {","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":"use Fruit::Apple;\n\n","suggestion_applicability":"Unspecified","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0425]: cannot find function `Apple` in this scope\n  --> /checkout/src/test/ui/issues/issue-35675.rs:9:5\n   |\nLL |     Apple(5)\n   |     ^^^^^ not found in this scope\nhelp: possible candidate is found in another module, you can import it into scope\n   |\nLL | use Fruit::Apple;\n   |\n\n"}
[01:15:56] {"message":"expected type, found variant `Fruit::Apple`","code":{"code":"E0573","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":335,"byte_end":347,"line_start":13,"line_end":13,"column_start":33,"column_end":45,"is_primary":true,"text":[{"text":"fn should_return_fruit_too() -> Fruit::Apple {","highlight_start":33,"highlight_end":45}],"label":"not a type","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"try using the variant's enum","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":335,"byte_end":347,"line_start":13,"line_end":13,"column_start":33,"column_end":45,"is_primary":true,"text":[{"text":"fn should_return_fruit_too() -> Fruit::Apple {","highlight_start":33,"highlight_end":45}],"label":null,"suggested_replacement":"Fruit","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0573]: expected type, found variant `Fruit::Apple`\n  --> /checkout/src/test/ui/issues/issue-35675.rs:13:33\n   |\nLL | fn should_return_fruit_too() -> Fruit::Apple {\n   |                                 ^^^^^^^^^^^^\n   |                                 |\n   |                                 not a type\n   |                                 help: try using the variant's enum: `Fruit`\n\n"}
[01:15:56] {"message":"cannot find function `Apple` in this scope","code":{"code":"E0425","explanation":"\nAn unresolved name was used.\n\nErroneous code examples:\n\n```compile_fail,E0425\nsomething_that_doesnt_exist::foo;\n// error: unresolved name `something_that_doesnt_exist::foo`\n\n// or:\n\ntrait Foo {\n    fn bar() {\n        Self; // error: unresolved name `Self`\n    }\n}\n\n// or:\n\nlet x = unknown_variable;  // error: unresolved name `unknown_variable`\n```\n\nPlease verify that the name wasn't misspelled and ensure that the\nidentifier being referred to is valid for the given situation. Example:\n\n```\nenum something_that_does_exist {\n    Foo,\n}\n```\n\nOr:\n\n```\nmod something_that_does_exist {\n    pub static foo : i32 = 0i32;\n}\n\nsomething_that_does_exist::foo; // ok!\n```\n\nOr:\n\n```\nlet unknown_variable = 12u32;\nlet x = unknown_variable; // ok!\n```\n\nIf the item is not defined in the current module, it must be imported using a\n`use` statement, like so:\n\n```\n# mod foo { pub fn bar() {} }\n# fn main() {\nuse foo::bar;\nbar();\n# }\n```\n\nIf the item you are importing is not defined in some super-module of the\ncurrent module, then it must also be declared as public (e.g., `pub fn`).\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":413,"byte_end":418,"line_start":15,"line_end":15,"column_start":5,"column_end":10,"is_primary":true,"text":[{"text":"    Apple(5)","highlight_start":5,"highlight_end":10}],"label":"not found in this scope","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"possible candidate is found in another module, you can import it into scope","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":90,"byte_end":90,"line_start":2,"line_end":2,"column_start":1,"column_end":1,"is_primary":true,"text":[{"text":"enum Fruit {","highlight_start":1,"highlight_end":1}],"label":null,"suggested_replacement":"use Fruit::Apple;\n\n","suggestion_applicability":"Unspecified","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0425]: cannot find function `Apple` in this scope\n  --> /checkout/src/test/ui/issues/issue-35675.rs:15:5\n   |\nLL |     Apple(5)\n   |     ^^^^^ not found in this scope\nhelp: possible candidate is found in another module, you can import it into scope\n   |\nLL | use Fruit::Apple;\n   |\n\n"}
[01:15:56] {"message":"expected type, found variant `Ok`","code":{"code":"E0573","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":495,"byte_end":497,"line_start":19,"line_end":19,"column_start":13,"column_end":15,"is_primary":true,"text":[{"text":"fn foo() -> Ok {","highlight_start":13,"highlight_end":15}],"label":"not a type","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"try using the variant's enum","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":495,"byte_end":497,"line_start":19,"line_end":19,"column_start":13,"column_end":15,"is_primary":true,"text":[{"text":"fn foo() -> Ok {","highlight_start":13,"highlight_end":15}],"label":null,"suggested_replacement":"std::result::Result","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0573]: expected type, found variant `Ok`\n  --> /checkout/src/test/ui/issues/issue-35675.rs:19:13\n   |\nLL | fn foo() -> Ok {\n   |             ^^\n   |             |\n   |             not a type\n   |             help: try using the variant's enum: `std::result::Result`\n\n"}
[01:15:56] {"message":"cannot find type `Variant3` in this scope","code":{"code":"E0412","explanation":"\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":575,"byte_end":583,"line_start":24,"line_end":24,"column_start":13,"column_end":21,"is_primary":true,"text":[{"text":"fn bar() -> Variant3 {","highlight_start":13,"highlight_end":21}],"label":"not found in this scope","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"there is an enum variant `x::Enum::Variant3`; try using the variant's enum","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":575,"byte_end":583,"line_start":24,"line_end":24,"column_start":13,"column_end":21,"is_primary":true,"text":[{"text":"fn bar() -> Variant3 {","highlight_start":13,"highlight_end":21}],"label":null,"suggested_replacement":"x::Enum","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0412]: cannot find type `Variant3` in this scope\n  --> /checkout/src/test/ui/issues/issue-35675.rs:24:13\n   |\nLL | fn bar() -> Variant3 {\n   |             ^^^^^^^^ not found in this scope\nhelp: there is an enum variant `x::Enum::Variant3`; try using the variant's enum\n   |\nLL | fn bar() -> x::Enum {\n   |             ^^^^^^^\n\n"}
[01:15:56] {"message":"expected type, found variant `Some`","code":{"code":"E0573","explanation":null},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":658,"byte_end":662,"line_start":28,"line_end":28,"column_start":13,"column_end":17,"is_primary":true,"text":[{"text":"fn qux() -> Some {","highlight_start":13,"highlight_end":17}],"label":"not a type","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"try using the variant's enum","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-35675.rs","byte_start":658,"byte_end":662,"line_start":28,"line_end":28,"column_start":13,"column_end":17,"is_primary":true,"text":[{"text":"fn qux() -> Some {","highlight_start":13,"highlight_end":17}],"label":null,"suggested_replacement":"std::option::Option","suggestion_applicability":"MachineApplicable","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0573]: expected type, found variant `Some`\n  --> /checkout/src/test/ui/issues/issue-35675.rs:28:13\n   |\nLL | fn qux() -> Some {\n   |             ^^^^\n   |             |\n   |             not a type\n   |             help: try using the variant's enum: `std::option::Option`\n\n"}
[01:15:56] {"message":"aborting due to 7 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 7 previous errors\n\n"}
[01:15:56] {"message":"Some errors occurred: E0412, E0425, E0573.","code":null,"level":"","spans":[],"children":[],"rendered":"Some errors occurred: E0412, E0425, E0573.\n"}
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] thread '[ui] ui/issues/issue-35675.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3369:9
[01:15:56] thread '[ui] ui/issues/issue-35675.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3369:9
[01:15:56] 
[01:15:56] ---- [ui] ui/issues/issue-7607-1.rs stdout ----
[01:15:56] diff of stderr:
[01:15:56] 
[01:15:56] 2   --> $DIR/issue-7607-1.rs:5:6
[01:15:56] 3    |
[01:15:56] 4 LL | impl Fo {
[01:15:56] -    |      ^^ help: a trait with a similar name exists: `Fn`
[01:15:56] +    |      ^^ help: a struct with a similar name exists: `Foo`
[01:15:56] 7 error: aborting due to previous error
[01:15:56] 8 
[01:15:56] 
[01:15:56] 
[01:15:56] 
[01:15:56] The actual stderr differed from the expected stderr.
[01:15:56] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-7607-1/issue-7607-1.stderr
[01:15:56] To update references, rerun the tests and pass the `--bless` flag
[01:15:56] To only update this specific test, also pass `--test-args issues/issue-7607-1.rs`
[01:15:56] error: 1 errors occurred comparing output.
[01:15:56] status: exit code: 1
[01:15:56] status: exit code: 1
[01:15:56] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/issues/issue-7607-1.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-7607-1/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/issues/issue-7607-1/auxiliary" "-A" "unused"
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] stderr:
[01:15:56] stderr:
[01:15:56] ------------------------------------------
[01:15:56] {"message":"cannot find type `Fo` in this scope","code":{"code":"E0412","explanation":"\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-7607-1.rs","byte_start":34,"byte_end":36,"line_start":5,"line_end":5,"column_start":6,"column_end":8,"is_primary":true,"text":[{"text":"impl Fo { //~ ERROR cannot find type `Fo` in this scope","highlight_start":6,"highlight_end":8}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"a struct with a similar name exists","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/issues/issue-7607-1.rs","byte_start":34,"byte_end":36,"line_start":5,"line_end":5,"column_start":6,"column_end":8,"is_primary":true,"text":[{"text":"impl Fo { //~ ERROR cannot find type `Fo` in this scope","highlight_start":6,"highlight_end":8}],"label":null,"suggested_replacement":"Foo","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0412]: cannot find type `Fo` in this scope\n  --> /checkout/src/test/ui/issues/issue-7607-1.rs:5:6\n   |\nLL | impl Fo { //~ ERROR cannot find type `Fo` in this scope\n   |      ^^ help: a struct with a similar name exists: `Foo`\n\n"}
[01:15:56] {"message":"For more information about this error, try `rustc --explain E0412`.","code":null,"level":"","spans":[],"children":[],"rendered":"For more information about this error, try `rustc --explain E0412`.\n"}
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] 
[01:15:56] thread '[ui] ui/issues/issue-7607-1.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3369:9
[01:15:56] 
[01:15:56] ---- [ui] ui/resolve/levenshtein.rs stdout ----
[01:15:56] diff of stderr:
[01:15:56] 
[01:15:56] 2   --> $DIR/levenshtein.rs:5:11
[01:15:56] 3    |
[01:15:56] 4 LL | fn foo(c: esize) {} // Misspelled primitive type name.
[01:15:56] -    |           ^^^^^ help: a primitive type with a similar name exists: `isize`
[01:15:56] +    |           ^^^^^ help: a primitive type with a similar name exists: `usize`
[01:15:56] 7 error[E0412]: cannot find type `Baz` in this scope
[01:15:56] 8   --> $DIR/levenshtein.rs:10:10
[01:15:56] 
[01:15:56] 
[01:15:56] 
[01:15:56] The actual stderr differed from the expected stderr.
[01:15:56] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/resolve/levenshtein/levenshtein.stderr
[01:15:56] To update references, rerun the tests and pass the `--bless` flag
[01:15:56] To only update this specific test, also pass `--test-args resolve/levenshtein.rs`
[01:15:56] error: 1 errors occurred comparing output.
[01:15:56] status: exit code: 1
[01:15:56] status: exit code: 1
[01:15:56] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/resolve/levenshtein.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/resolve/levenshtein/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/resolve/levenshtein/auxiliary" "-A" "unused"
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] stderr:
[01:15:56] stderr:
[01:15:56] ------------------------------------------
[01:15:56] {"message":"cannot find type `esize` in this scope","code":{"code":"E0412","explanation":"\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":56,"byte_end":61,"line_start":5,"line_end":5,"column_start":11,"column_end":16,"is_primary":true,"text":[{"text":"fn foo(c: esize) {} // Misspelled primitive type name.","highlight_start":11,"highlight_end":16}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"a primitive type with a similar name exists","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":56,"byte_end":61,"line_start":5,"line_end":5,"column_start":11,"column_end":16,"is_primary":true,"text":[{"text":"fn foo(c: esize) {} // Misspelled primitive type name.","highlight_start":11,"highlight_end":16}],"label":null,"suggested_replacement":"usize","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0412]: cannot find type `esize` in this scope\n  --> /checkout/src/test/ui/resolve/levenshtein.rs:5:11\n   |\nLL | fn foo(c: esize) {} // Misspelled primitive type name.\n   |           ^^^^^ help: a primitive type with a similar name exists: `usize`\n\n"}
[01:15:56] {"message":"cannot find type `Baz` in this scope","code":{"code":"E0412","explanation":"\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":148,"byte_end":151,"line_start":10,"line_end":10,"column_start":10,"column_end":13,"is_primary":true,"text":[{"text":"type A = Baz; // Misspelled type name.","highlight_start":10,"highlight_end":13}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"an enum with a similar name exists","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":148,"byte_end":151,"line_start":10,"line_end":10,"column_start":10,"column_end":13,"is_primary":true,"text":[{"text":"type A = Baz; // Misspelled type name.","highlight_start":10,"highlight_end":13}],"label":null,"suggested_replacement":"Bar","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0412]: cannot find type `Baz` in this scope\n  --> /checkout/src/test/ui/resolve/levenshtein.rs:10:10\n   |\nLL | type A = Baz; // Misspelled type name.\n   |          ^^^ help: an enum with a similar name exists: `Bar`\n\n"}
[01:15:56] {"message":"cannot find type `Opiton` in this scope","code":{"code":"E0412","explanation":"\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":210,"byte_end":216,"line_start":12,"line_end":12,"column_start":10,"column_end":16,"is_primary":true,"text":[{"text":"type B = Opiton<u8>; // Misspelled type name from the prelude.","highlight_start":10,"highlight_end":16}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"an enum with a similar name exists","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":210,"byte_end":216,"line_start":12,"line_end":12,"column_start":10,"column_end":16,"is_primary":true,"text":[{"text":"type B = Opiton<u8>; // Misspelled type name from the prelude.","highlight_start":10,"highlight_end":16}],"label":null,"suggested_replacement":"Option","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0412]: cannot find type `Opiton` in this scope\n  --> /checkout/src/test/ui/resolve/levenshtein.rs:12:10\n   |\nLL | type B = Opiton<u8>; // Misspelled type name from the prelude.\n   |          ^^^^^^ help: an enum with a similar name exists: `Option`\n\n"}
[01:15:56] {"message":"cannot find type `Baz` in this scope","code":{"code":"E0412","explanation":"\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":309,"byte_end":312,"line_start":16,"line_end":16,"column_start":14,"column_end":17,"is_primary":true,"text":[{"text":"    type A = Baz; // No suggestion here, Bar is not visible","highlight_start":14,"highlight_end":17}],"label":"not found in this scope","suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":"error[E0412]: cannot find type `Baz` in this scope\n  --> /checkout/src/test/ui/resolve/levenshtein.rs:16:14\n   |\nLL |     type A = Baz; // No suggestion here, Bar is not visible\n   |              ^^^ not found in this scope\n\n"}
[01:15:56] {"message":"cannot find value `MAXITEM` in this scope","code":{"code":"E0425","explanation":"\nAn unresolved name was used.\n\nErroneous code examples:\n\n```compile_fail,E0425\nsomething_that_doesnt_exist::foo;\n// error: unresolved name `something_that_doesnt_exist::foo`\n\n// or:\n\ntrait Foo {\n    fn bar() {\n        Self; // error: unresolved name `Self`\n    }\n}\n\n// or:\n\nlet x = unknown_variable;  // error: unresolved name `unknown_variable`\n```\n\nPlease verify that the name wasn't misspelled and ensure that the\nidentifier being referred to is valid for the given situation. Example:\n\n```\nenum something_that_does_exist {\n    Foo,\n}\n```\n\nOr:\n\n```\nmod something_that_does_exist {\n    pub static foo : i32 = 0i32;\n}\n\nsomething_that_does_exist::foo; // ok!\n```\n\nOr:\n\n```\nlet unknown_variable = 12u32;\nlet x = unknown_variable; // ok!\n```\n\nIf the item is not defined in the current module, it must be imported using a\n`use` statement, like so:\n\n```\n# mod foo { pub fn bar() {} }\n# fn main() {\nuse foo::bar;\nbar();\n# }\n```\n\nIf the item you are importing is not defined in some super-module of the\ncurrent module, then it must also be declared as public (e.g., `pub fn`).\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":463,"byte_end":470,"line_start":24,"line_end":24,"column_start":20,"column_end":27,"is_primary":true,"text":[{"text":"    let v = [0u32; MAXITEM]; // Misspelled constant name.","highlight_start":20,"highlight_end":27}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"a constant with a similar name exists","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":463,"byte_end":470,"line_start":24,"line_end":24,"column_start":20,"column_end":27,"is_primary":true,"text":[{"text":"    let v = [0u32; MAXITEM]; // Misspelled constant name.","highlight_start":20,"highlight_end":27}],"label":null,"suggested_replacement":"MAX_ITEM","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0425]: cannot find value `MAXITEM` in this scope\n  --> /checkout/src/test/ui/resolve/levenshtein.rs:24:20\n   |\nLL |     let v = [0u32; MAXITEM]; // Misspelled constant name.\n   |                    ^^^^^^^ help: a constant with a similar name exists: `MAX_ITEM`\n\n"}
[01:15:56] {"message":"cannot find function `foobar` in this scope","code":{"code":"E0425","explanation":"\nAn unresolved name was used.\n\nErroneous code examples:\n\n```compile_fail,E0425\nsomething_that_doesnt_exist::foo;\n// error: unresolved name `something_that_doesnt_exist::foo`\n\n// or:\n\ntrait Foo {\n    fn bar() {\n        Self; // error: unresolved name `Self`\n    }\n}\n\n// or:\n\nlet x = unknown_variable;  // error: unresolved name `unknown_variable`\n```\n\nPlease verify that the name wasn't misspelled and ensure that the\nidentifier being referred to is valid for the given situation. Example:\n\n```\nenum something_that_does_exist {\n    Foo,\n}\n```\n\nOr:\n\n```\nmod something_that_does_exist {\n    pub static foo : i32 = 0i32;\n}\n\nsomething_that_does_exist::foo; // ok!\n```\n\nOr:\n\n```\nlet unknown_variable = 12u32;\nlet x = unknown_variable; // ok!\n```\n\nIf the item is not defined in the current module, it must be imported using a\n`use` statement, like so:\n\n```\n# mod foo { pub fn bar() {} }\n# fn main() {\nuse foo::bar;\nbar();\n# }\n```\n\nIf the item you are importing is not defined in some super-module of the\ncurrent module, then it must also be declared as public (e.g., `pub fn`).\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":533,"byte_end":539,"line_start":26,"line_end":26,"column_start":5,"column_end":11,"is_primary":true,"text":[{"text":"    foobar(); // Misspelled function name.","highlight_start":5,"highlight_end":11}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"a function with a similar name exists","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":533,"byte_end":539,"line_start":26,"line_end":26,"column_start":5,"column_end":11,"is_primary":true,"text":[{"text":"    foobar(); // Misspelled function name.","highlight_start":5,"highlight_end":11}],"label":null,"suggested_replacement":"foo_bar","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0425]: cannot find function `foobar` in this scope\n  --> /checkout/src/test/ui/resolve/levenshtein.rs:26:5\n   |\nLL |     foobar(); // Misspelled function name.\n   |     ^^^^^^ help: a function with a similar name exists: `foo_bar`\n\n"}
[01:15:56] {"message":"cannot find type `first` in module `m`","code":{"code":"E0412","explanation":"\nThe type name used is not in scope.\n\nErroneous code examples:\n\n```compile_fail,E0412\nimpl Something {} // error: type name `Something` is not in scope\n\n// or:\n\ntrait Foo {\n    fn bar(N); // error: type name `N` is not in scope\n}\n\n// or:\n\nfn foo(x: T) {} // type name `T` is not in scope\n```\n\nTo fix this error, please verify you didn't misspell the type name, you did\ndeclare it or imported it into the scope. Examples:\n\n```\nstruct Something;\n\nimpl Something {} // ok!\n\n// or:\n\ntrait Foo {\n    type N;\n\n    fn bar(_: Self::N); // ok!\n}\n\n// or:\n\nfn foo<T>(x: T) {} // ok!\n```\n\nAnother case that causes this error is when a type is imported into a parent\nmodule. To fix this, you can follow the suggestion and use File directly or\n`use super::File;` which will import the types from the parent namespace. An\nexample that causes this error is below:\n\n```compile_fail,E0412\nuse std::fs::File;\n\nmod foo {\n    fn some_function(f: File) {}\n}\n```\n\n```\nuse std::fs::File;\n\nmod foo {\n    // either\n    use super::File;\n    // or\n    // use std::fs::File;\n    fn foo(f: File) {}\n}\n# fn main() {} // don't insert it for us; that'll break imports\n```\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":613,"byte_end":618,"line_start":28,"line_end":28,"column_start":15,"column_end":20,"is_primary":true,"text":[{"text":"    let b: m::first = m::second; // Misspelled item in module.","highlight_start":15,"highlight_end":20}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"a struct with a similar name exists","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":613,"byte_end":618,"line_start":28,"line_end":28,"column_start":15,"column_end":20,"is_primary":true,"text":[{"text":"    let b: m::first = m::second; // Misspelled item in module.","highlight_start":15,"highlight_end":20}],"label":null,"suggested_replacement":"First","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0412]: cannot find type `first` in module `m`\n  --> /checkout/src/test/ui/resolve/levenshtein.rs:28:15\n   |\nLL |     let b: m::first = m::second; // Misspelled item in module.\n   |               ^^^^^ help: a struct with a similar name exists: `First`\n\n"}
[01:15:56] {"message":"cannot find value `second` in module `m`","code":{"code":"E0425","explanation":"\nAn unresolved name was used.\n\nErroneous code examples:\n\n```compile_fail,E0425\nsomething_that_doesnt_exist::foo;\n// error: unresolved name `something_that_doesnt_exist::foo`\n\n// or:\n\ntrait Foo {\n    fn bar() {\n        Self; // error: unresolved name `Self`\n    }\n}\n\n// or:\n\nlet x = unknown_variable;  // error: unresolved name `unknown_variable`\n```\n\nPlease verify that the name wasn't misspelled and ensure that the\nidentifier being referred to is valid for the given situation. Example:\n\n```\nenum something_that_does_exist {\n    Foo,\n}\n```\n\nOr:\n\n```\nmod something_that_does_exist {\n    pub static foo : i32 = 0i32;\n}\n\nsomething_that_does_exist::foo; // ok!\n```\n\nOr:\n\n```\nlet unknown_variable = 12u32;\nlet x = unknown_variable; // ok!\n```\n\nIf the item is not defined in the current module, it must be imported using a\n`use` statement, like so:\n\n```\n# mod foo { pub fn bar() {} }\n# fn main() {\nuse foo::bar;\nbar();\n# }\n```\n\nIf the item you are importing is not defined in some super-module of the\ncurrent module, then it must also be declared as public (e.g., `pub fn`).\n"},"level":"error","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":624,"byte_end":630,"line_start":28,"line_end":28,"column_start":26,"column_end":32,"is_primary":true,"text":[{"text":"    let b: m::first = m::second; // Misspelled item in module.","highlight_start":26,"highlight_end":32}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"a unit struct with a similar name exists","code":null,"level":"help","spans":[{"file_name":"/checkout/src/test/ui/resolve/levenshtein.rs","byte_start":624,"byte_end":630,"line_start":28,"line_end":28,"column_start":26,"column_end":32,"is_primary":true,"text":[{"text":"    let b: m::first = m::second; // Misspelled item in module.","highlight_start":26,"highlight_end":32}],"label":null,"suggested_replacement":"Second","suggestion_applicability":"MaybeIncorrect","expansion":null}],"children":[],"rendered":null}],"rendered":"error[E0425]: cannot find value `second` in module `m`\n  --> /checkout/src/test/ui/resolve/levenshtein.rs:28:26\n   |\nLL |     let b: m::first = m::second; // Misspelled item in module.\n   |                          ^^^^^^ help: a unit struct with a similar name exists: `Second`\n\n"}
[01:15:56] {"message":"aborting due to 8 previous errors","code":null,"level":"error","spans":[],"children":[],"rendered":"error: aborting due to 8 previous errors\n\n"}
[01:15:56] {"message":"Some errors occurred: E0412, E0425.","code":null,"level":"","spans":[],"children":[],"rendered":"Some errors occurred: E0412, E0425.\n"}
[01:15:56] 
[01:15:56] ------------------------------------------
[01:15:56] 
[01:15:56] thread '[ui] ui/resolve/levenshtein.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3369:9
---
[01:15:56] 
[01:15:56] thread 'main' panicked at 'Some tests failed', src/tools/compiletest/src/main.rs:496:22
[01:15:56] 
[01:15:56] 
[01:15:56] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/compiletest" "--compile-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib" "--run-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib" "--rustc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "--src-base" "/checkout/src/test/ui" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "ui" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-6.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--target-rustcflags" "-Crpath -O -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--docck-python" "/usr/bin/python2.7" "--lldb-python" "/usr/bin/python2.7" "--gdb" "/usr/bin/gdb" "--quiet" "--llvm-version" "6.0.0\n" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
[01:15:56] 
[01:15:56] 
[01:15:56] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[01:15:56] Build completed unsuccessfully in 0:04:35
[01:15:56] Build completed unsuccessfully in 0:04:35
[01:15:56] Makefile:48: recipe for target 'check' failed
[01:15:56] make: *** [check] Error 1
The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:098c1000
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
Mon Mar 25 18:35:40 UTC 2019
---
travis_time:end:0484e65d:start=1553538942719020064,finish=1553538942724524339,duration=5504275
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:2c2b643e
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\033[31;1m%s\033[0m\n" "$CORE"; gdb --batch -q -c "$CORE" "$EXE" -iex 'set auto-load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:018c4113
travis_time:start:018c4113
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:198e6922
$ dmesg | grep -i kill

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@Centril
Copy link
Contributor

Centril commented Mar 30, 2019

Ping from triage, @Zoxc --bless?

@@ -514,18 +515,24 @@ fn with_interner<T, F: FnOnce(&mut Interner) -> T>(f: F) -> T {
// by creating a new thread right after constructing the interner.
#[derive(Clone, Copy, Hash, PartialOrd, Eq, Ord)]
Copy link
Member

Choose a reason for hiding this comment

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

Argh, all the derives are now wrong...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I just changed this back to &'static str.

@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-6.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
travis_time:end:007d25dc:start=1553992006979200145,finish=1553992009134979267,duration=2155779122
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#pull-requests-and-security-restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
$ export GCP_CACHE_BUCKET=rust-lang-ci-cache
Setting environment variables from .travis.yml
---
[00:07:58]    Compiling syntax_ext v0.0.0 (/checkout/src/libsyntax_ext)
[00:07:59] error[E0308]: mismatched types
[00:07:59]    --> src/libsyntax_ext/proc_macro_server.rs:343:44
[00:07:59]     |
[00:07:59] 343 |         if is_raw && !ast::Ident::from_str(string).can_be_raw() {
[00:07:59]     |                                            |
[00:07:59]     |                                            expected &str, found struct `syntax_pos::symbol::LocalInternedString`
[00:07:59]     |                                            help: consider borrowing here: `&string`
[00:07:59]     |
---
travis_time:end:0b328380:start=1553992869557888115,finish=1553992870100994015,duration=543105900
travis_fold:end:after_failure.1
travis_fold:start:after_failure.2
travis_time:start:1238db71
$ ls -lat $HOME/Library/Logs/Di/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:16e44d80
$ dmesg | grep -i kill

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@eddyb
Copy link
Member

eddyb commented Apr 10, 2019

@bors r+

@bors
Copy link
Contributor

bors commented Apr 10, 2019

📌 Commit 5ea959d has been approved by eddyb

@bors
Copy link
Contributor

bors commented Apr 10, 2019

🌲 The tree is currently closed for pull requests below priority 15, this pull request will be tested once the tree is reopened

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Apr 10, 2019
cramertj added a commit to cramertj/rust that referenced this pull request Apr 11, 2019
Fix lifetime on LocalInternedString::get function

cc @eddyb @nnethercote
@bors
Copy link
Contributor

bors commented Apr 11, 2019

⌛ Testing commit 5ea959d with merge cd8b437...

bors added a commit that referenced this pull request Apr 11, 2019
Fix lifetime on LocalInternedString::get function

cc @eddyb @nnethercote
@bors
Copy link
Contributor

bors commented Apr 12, 2019

☀️ Test successful - checks-travis, status-appveyor
Approved by: eddyb
Pushing cd8b437 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Apr 12, 2019
@bors bors merged commit 5ea959d into rust-lang:master Apr 12, 2019
@rust-highfive
Copy link
Collaborator

📣 Toolstate changed by #59227!

Tested on commit cd8b437.
Direct link to PR: #59227

💔 clippy-driver on windows: test-pass → build-fail (cc @Manishearth @llogiq @mcarton @oli-obk @phansch, @rust-lang/infra).
💔 clippy-driver on linux: test-pass → build-fail (cc @Manishearth @llogiq @mcarton @oli-obk @phansch, @rust-lang/infra).
💔 miri on windows: test-fail → build-fail (cc @oli-obk @RalfJung @eddyb, @rust-lang/infra).
💔 miri on linux: test-fail → build-fail (cc @oli-obk @RalfJung @eddyb, @rust-lang/infra).
💔 rls on windows: test-pass → build-fail (cc @nrc @Xanewok, @rust-lang/infra).
💔 rls on linux: test-pass → build-fail (cc @nrc @Xanewok, @rust-lang/infra).

rust-highfive added a commit to rust-lang-nursery/rust-toolstate that referenced this pull request Apr 12, 2019
Tested on commit rust-lang/rust@cd8b437.
Direct link to PR: <rust-lang/rust#59227>

💔 clippy-driver on windows: test-pass → build-fail (cc @Manishearth @llogiq @mcarton @oli-obk @phansch, @rust-lang/infra).
💔 clippy-driver on linux: test-pass → build-fail (cc @Manishearth @llogiq @mcarton @oli-obk @phansch, @rust-lang/infra).
💔 miri on windows: test-fail → build-fail (cc @oli-obk @RalfJung @eddyb, @rust-lang/infra).
💔 miri on linux: test-fail → build-fail (cc @oli-obk @RalfJung @eddyb, @rust-lang/infra).
💔 rls on windows: test-pass → build-fail (cc @nrc @Xanewok, @rust-lang/infra).
💔 rls on linux: test-pass → build-fail (cc @nrc @Xanewok, @rust-lang/infra).
@Zoxc Zoxc deleted the fix-get branch April 12, 2019 02:56
bors added a commit to rust-lang/rust-clippy that referenced this pull request Apr 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants