2023-08-04 16:46:08 +00:00
|
|
|
|
error: found both `s` and `s` as identifiers, which look alike
|
2021-04-03 10:35:11 +08:00
|
|
|
|
--> $DIR/lint-confusable-idents.rs:8:9
|
2020-04-25 09:38:31 +08:00
|
|
|
|
|
|
|
|
|
|
LL | const s: usize = 42;
|
2023-08-04 16:46:08 +00:00
|
|
|
|
| -- other identifier used here
|
2020-04-25 09:38:31 +08:00
|
|
|
|
...
|
|
|
|
|
LL | let s = "rust";
|
2023-08-04 16:46:08 +00:00
|
|
|
|
| ^ this identifier can be confused with `s`
|
2020-04-25 09:38:31 +08:00
|
|
|
|
|
|
|
|
|
|
note: the lint level is defined here
|
2021-04-03 10:35:11 +08:00
|
|
|
|
--> $DIR/lint-confusable-idents.rs:1:9
|
2020-04-25 09:38:31 +08:00
|
|
|
|
|
|
|
|
|
|
LL | #![deny(confusable_idents)]
|
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
2023-08-04 16:46:08 +00:00
|
|
|
|
error: found both `s_s` and `s_s` as identifiers, which look alike
|
2021-04-03 10:35:11 +08:00
|
|
|
|
--> $DIR/lint-confusable-idents.rs:9:9
|
2020-08-05 17:29:13 +10:00
|
|
|
|
|
|
|
|
|
|
LL | const s_s: usize = 42;
|
2023-08-04 16:46:08 +00:00
|
|
|
|
| --- other identifier used here
|
2020-08-05 17:29:13 +10:00
|
|
|
|
...
|
|
|
|
|
LL | let s_s = "rust2";
|
2023-08-04 16:46:08 +00:00
|
|
|
|
| ^^^^^ this identifier can be confused with `s_s`
|
2020-08-05 17:29:13 +10:00
|
|
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
2020-04-25 09:38:31 +08:00
|
|
|
|
|