File tree Expand file tree Collapse file tree 2 files changed +7
-7
lines changed Expand file tree Collapse file tree 2 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -41,9 +41,9 @@ trait ProtobufOptions {
4141impl < ' a > ProtobufOptions for & ' a [ model:: ProtobufOption ] {
4242 fn by_name ( & self , name : & str ) -> Option < & model:: ProtobufConstant > {
4343 let option_name = name;
44- for & model:: ProtobufOption {
45- ref name,
46- ref value,
44+ for model:: ProtobufOption {
45+ name,
46+ value,
4747 } in * self
4848 {
4949 if name == option_name {
@@ -224,7 +224,7 @@ impl AbsolutePath {
224224 } else {
225225 assert ! ( !path. starts_with( '.' ) ) ;
226226 assert ! ( !path. ends_with( '.' ) ) ;
227- AbsolutePath :: new ( format ! ( ".{}" , path ) )
227+ AbsolutePath :: new ( format ! ( ".{path}" ) )
228228 }
229229 }
230230
@@ -396,7 +396,7 @@ struct Resolver<'a> {
396396
397397impl < ' a > Resolver < ' a > {
398398 fn map_entry_name_for_field_name ( field_name : & str ) -> String {
399- format ! ( "{}_MapEntry" , field_name )
399+ format ! ( "{field_name }_MapEntry" )
400400 }
401401
402402 fn map_entry_field (
@@ -964,7 +964,7 @@ impl<'a> Resolver<'a> {
964964 v. map_err ( |( ) | {
965965 ConvertError :: UnsupportedExtensionType (
966966 option_name. to_owned ( ) ,
967- format ! ( "{:?}" , field_type ) ,
967+ format ! ( "{field_type :?}" ) ,
968968 )
969969 } )
970970 }
Original file line number Diff line number Diff line change @@ -912,7 +912,7 @@ impl<'a> Parser<'a> {
912912
913913 fn next_ident_if_in ( & mut self , idents : & [ & str ] ) -> ParserResult < Option < String > > {
914914 let v = match self . lookahead ( ) ? {
915- Some ( & Token :: Ident ( ref next) ) => {
915+ Some ( Token :: Ident ( next) ) => {
916916 if idents. iter ( ) . any ( |i| i == next) {
917917 next. clone ( )
918918 } else {
You can’t perform that action at this time.
0 commit comments