File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -131,7 +131,7 @@ impl NonCamelCaseTypes {
131131 let cc = to_camel_case ( name) ;
132132 // We cannot provide meaningful suggestions
133133 // if the characters are in the category of "Lowercase Letter".
134- if name. to_string ( ) != cc {
134+ if * name != cc {
135135 err. span_suggestion (
136136 ident. span ,
137137 "convert the identifier to upper camel case" ,
@@ -271,7 +271,7 @@ impl NonSnakeCase {
271271 let mut err = lint. build ( & msg) ;
272272 // We cannot provide meaningful suggestions
273273 // if the characters are in the category of "Uppercase Letter".
274- if name. to_string ( ) != sc {
274+ if * name != sc {
275275 // We have a valid span in almost all cases, but we don't have one when linting a crate
276276 // name provided via the command line.
277277 if !ident. span . is_dummy ( ) {
@@ -455,7 +455,7 @@ impl NonUpperCaseGlobals {
455455 lint. build ( & format ! ( "{} `{}` should have an upper case name" , sort, name) ) ;
456456 // We cannot provide meaningful suggestions
457457 // if the characters are in the category of "Lowercase Letter".
458- if name. to_string ( ) != uc {
458+ if * name != uc {
459459 err. span_suggestion (
460460 ident. span ,
461461 "convert the identifier to upper case" ,
You can’t perform that action at this time.
0 commit comments