Use more targeted suggestion when confusing i8 with std::i8
This commit is contained in:
parent
357bc27904
commit
8542dd02a8
3 changed files with 21 additions and 26 deletions
|
|
@ -7,7 +7,7 @@ LL | let pi = f32::consts::PI;
|
|||
help: you are looking for the module in `std`, not the primitive type
|
||||
|
|
||||
LL | let pi = std::f32::consts::PI;
|
||||
| ~~~~~~~~~~~~~~~~
|
||||
| +++++
|
||||
|
||||
error[E0599]: no function or associated item named `from_utf8` found for type `str` in the current scope
|
||||
--> $DIR/suggest-std-when-using-type.rs:5:14
|
||||
|
|
@ -18,7 +18,7 @@ LL | str::from_utf8(bytes)
|
|||
help: you are looking for the module in `std`, not the primitive type
|
||||
|
|
||||
LL | std::str::from_utf8(bytes)
|
||||
| ~~~~~~~~~~~~~~~~~~~
|
||||
| +++++
|
||||
|
||||
error: aborting due to 2 previous errors
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue