1
Fork 0

Improve wording for external crate resolution error

I think it reads better this way.
This commit is contained in:
Camelid 2020-09-30 15:52:13 -07:00
parent 867bd42c38
commit 2c5e2a6fc6
3 changed files with 3 additions and 3 deletions

View file

@ -1157,7 +1157,7 @@ impl<'a, 'b> ImportResolver<'a, 'b> {
} }
_ => { _ => {
if !ident.is_path_segment_keyword() { if !ident.is_path_segment_keyword() {
format!("no `{}` external crate", ident) format!("no external crate `{}`", ident)
} else { } else {
// HACK(eddyb) this shows up for `self` & `super`, which // HACK(eddyb) this shows up for `self` & `super`, which
// should work instead - for now keep the same error message. // should work instead - for now keep the same error message.

View file

@ -2,7 +2,7 @@ error[E0432]: unresolved import `ycrate`
--> $DIR/non-existent-3.rs:3:5 --> $DIR/non-existent-3.rs:3:5
| |
LL | use ycrate; LL | use ycrate;
| ^^^^^^ no `ycrate` external crate | ^^^^^^ no external crate `ycrate`
error: aborting due to previous error error: aborting due to previous error

View file

@ -2,7 +2,7 @@ error[E0432]: unresolved import `alloc`
--> $DIR/not-allowed.rs:5:5 --> $DIR/not-allowed.rs:5:5
| |
LL | use alloc; LL | use alloc;
| ^^^^^ no `alloc` external crate | ^^^^^ no external crate `alloc`
error: aborting due to previous error error: aborting due to previous error