File tree Expand file tree Collapse file tree 2 files changed +29
-1
lines changed Expand file tree Collapse file tree 2 files changed +29
-1
lines changed Original file line number Diff line number Diff line change @@ -1850,6 +1850,34 @@ fn main() {}
18501850```
18511851"## ,
18521852
1853+ E0578 : r##"
1854+ A module cannot be found and therefore, the visibility cannot be determined.
1855+
1856+ Erroneous code example:
1857+
1858+ ```compile_fail,E0578,edition2018
1859+ foo!();
1860+
1861+ pub (in ::Sea) struct Shark; // error!
1862+
1863+ fn main() {}
1864+ ```
1865+
1866+ Because of the call to the `foo` macro, the compiler guesses that the missing
1867+ module could be inside it and fails because the macro definition cannot be
1868+ found.
1869+
1870+ To fix this error, please be sure that the module is in scope:
1871+
1872+ ```edition2018
1873+ pub mod Sea {
1874+ pub (in crate::Sea) struct Shark;
1875+ }
1876+
1877+ fn main() {}
1878+ ```
1879+ "## ,
1880+
18531881E0603 : r##"
18541882A private item was used outside its scope.
18551883
@@ -2017,5 +2045,4 @@ fn main() {}
20172045// E0427, merged into 530
20182046// E0467, removed
20192047// E0470, removed
2020- E0578 ,
20212048}
Original file line number Diff line number Diff line change @@ -12,3 +12,4 @@ LL | foo!();
1212
1313error: aborting due to 2 previous errors
1414
15+ For more information about this error, try `rustc --explain E0578`.
You can’t perform that action at this time.
0 commit comments