1 An unresolved name was used.
3 Erroneous code examples:
6 something_that_doesnt_exist::foo;
7 // error: unresolved name `something_that_doesnt_exist::foo`
13 Self; // error: unresolved name `Self`
19 let x = unknown_variable; // error: unresolved name `unknown_variable`
22 Please verify that the name wasn't misspelled and ensure that the
23 identifier being referred to is valid for the given situation. Example:
26 enum something_that_does_exist {
34 mod something_that_does_exist {
35 pub static foo : i32 = 0i32;
38 something_that_does_exist::foo; // ok!
44 let unknown_variable = 12u32;
45 let x = unknown_variable; // ok!
48 If the item is not defined in the current module, it must be imported using a
49 `use` statement, like so:
52 # mod foo { pub fn bar() {} }
59 If the item you are importing is not defined in some super-module of the
60 current module, then it must also be declared as public (e.g., `pub fn`).