File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -131,7 +131,7 @@ impl NonCamelCaseTypes {
131
131
let cc = to_camel_case ( name) ;
132
132
// We cannot provide meaningful suggestions
133
133
// if the characters are in the category of "Lowercase Letter".
134
- if name. to_string ( ) != cc {
134
+ if * name != cc {
135
135
err. span_suggestion (
136
136
ident. span ,
137
137
"convert the identifier to upper camel case" ,
@@ -271,7 +271,7 @@ impl NonSnakeCase {
271
271
let mut err = lint. build ( & msg) ;
272
272
// We cannot provide meaningful suggestions
273
273
// if the characters are in the category of "Uppercase Letter".
274
- if name. to_string ( ) != sc {
274
+ if * name != sc {
275
275
// We have a valid span in almost all cases, but we don't have one when linting a crate
276
276
// name provided via the command line.
277
277
if !ident. span . is_dummy ( ) {
@@ -455,7 +455,7 @@ impl NonUpperCaseGlobals {
455
455
lint. build ( & format ! ( "{} `{}` should have an upper case name" , sort, name) ) ;
456
456
// We cannot provide meaningful suggestions
457
457
// if the characters are in the category of "Lowercase Letter".
458
- if name. to_string ( ) != uc {
458
+ if * name != uc {
459
459
err. span_suggestion (
460
460
ident. span ,
461
461
"convert the identifier to upper case" ,
You can’t perform that action at this time.
0 commit comments