rust/tests/ui-internal/unnecessary_symbol_str.stderr

40 lines
1.7 KiB
Plaintext
Raw Normal View History

error: unnecessary `Symbol` to string conversion
2024-10-13 10:27:05 -05:00
--> tests/ui-internal/unnecessary_symbol_str.rs:16:5
|
LL | Symbol::intern("foo").as_str() == "clippy";
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Symbol::intern("foo") == rustc_span::sym::clippy`
|
note: the lint level is defined here
2024-02-17 06:16:29 -06:00
--> tests/ui-internal/unnecessary_symbol_str.rs:2:9
|
LL | #![deny(clippy::internal)]
| ^^^^^^^^^^^^^^^^
= note: `#[deny(clippy::unnecessary_symbol_str)]` implied by `#[deny(clippy::internal)]`
error: unnecessary `Symbol` to string conversion
2024-10-13 10:27:05 -05:00
--> tests/ui-internal/unnecessary_symbol_str.rs:17:5
|
LL | Symbol::intern("foo").to_string() == "self";
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Symbol::intern("foo") == rustc_span::symbol::kw::SelfLower`
error: unnecessary `Symbol` to string conversion
2024-10-13 10:27:05 -05:00
--> tests/ui-internal/unnecessary_symbol_str.rs:18:5
|
LL | Symbol::intern("foo").to_ident_string() != "Self";
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Symbol::intern("foo") != rustc_span::symbol::kw::SelfUpper`
error: unnecessary `Symbol` to string conversion
2024-10-13 10:27:05 -05:00
--> tests/ui-internal/unnecessary_symbol_str.rs:19:5
|
LL | &*Ident::empty().as_str() == "clippy";
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `Ident::empty().name == rustc_span::sym::clippy`
error: unnecessary `Symbol` to string conversion
2024-10-13 10:27:05 -05:00
--> tests/ui-internal/unnecessary_symbol_str.rs:20:5
|
LL | "clippy" == Ident::empty().to_string();
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `rustc_span::sym::clippy == Ident::empty().name`
error: aborting due to 5 previous errors
2020-12-30 15:52:15 -06:00