]> git.lizzy.rs Git - rust.git/blob - tests/ui/suggestions/suggest-std-when-using-type.stderr
Rollup merge of #106321 - compiler-errors:delayed-bug-backtrace, r=Nilstrieb
[rust.git] / tests / ui / suggestions / suggest-std-when-using-type.stderr
1 error[E0223]: ambiguous associated type
2   --> $DIR/suggest-std-when-using-type.rs:3:14
3    |
4 LL |     let pi = f32::consts::PI;
5    |              ^^^^^^^^^^^
6    |
7 help: you are looking for the module in `std`, not the primitive type
8    |
9 LL |     let pi = std::f32::consts::PI;
10    |              +++++
11
12 error[E0599]: no function or associated item named `from_utf8` found for type `str` in the current scope
13   --> $DIR/suggest-std-when-using-type.rs:5:23
14    |
15 LL |     let string = str::from_utf8(bytes).unwrap();
16    |                       ^^^^^^^^^ function or associated item not found in `str`
17    |
18 help: you are looking for the module in `std`, not the primitive type
19    |
20 LL |     let string = std::str::from_utf8(bytes).unwrap();
21    |                  +++++
22
23 error: aborting due to 2 previous errors
24
25 Some errors have detailed explanations: E0223, E0599.
26 For more information about an error, try `rustc --explain E0223`.