]> git.lizzy.rs Git - rust.git/blob - tests/ui-internal/unnecessary_symbol_str.rs
Fix FP in `wrong_self_convention` lint
[rust.git] / tests / ui-internal / unnecessary_symbol_str.rs
1 // run-rustfix
2 #![feature(rustc_private)]
3 #![deny(clippy::internal)]
4 #![allow(clippy::unnecessary_operation, unused_must_use)]
5
6 extern crate rustc_span;
7
8 use rustc_span::symbol::{Ident, Symbol};
9
10 fn main() {
11     Symbol::intern("foo").as_str() == "clippy";
12     Symbol::intern("foo").to_string() == "self";
13     Symbol::intern("foo").to_ident_string() != "Self";
14     &*Ident::invalid().as_str() == "clippy";
15     "clippy" == Ident::invalid().to_string();
16 }