File tree Expand file tree Collapse file tree 5 files changed +9
-11
lines changed Expand file tree Collapse file tree 5 files changed +9
-11
lines changed Original file line number Diff line number Diff line change @@ -151,7 +151,7 @@ mod test {
151
151
let mut converter = ChannelCountConverter :: new ( input. iter ( ) . copied ( ) , from, to) ;
152
152
let count = converter. clone ( ) . count ( ) ;
153
153
for left_in_iter in ( 0 ..=count) . rev ( ) {
154
- println ! ( "left_in_iter = {}" , left_in_iter ) ;
154
+ println ! ( "left_in_iter = {left_in_iter}" ) ;
155
155
assert_eq ! ( converter. size_hint( ) , ( left_in_iter, Some ( left_in_iter) ) ) ;
156
156
converter. next ( ) ;
157
157
}
Original file line number Diff line number Diff line change @@ -352,7 +352,7 @@ impl FromStr for Mp4Type {
352
352
"m4r" => Ok ( Mp4Type :: M4r ) ,
353
353
"m4v" => Ok ( Mp4Type :: M4v ) ,
354
354
"mov" => Ok ( Mp4Type :: Mov ) ,
355
- _ => Err ( format ! ( "{} is not a valid mp4 extension" , input ) ) ,
355
+ _ => Err ( format ! ( "{input } is not a valid mp4 extension" ) ) ,
356
356
}
357
357
}
358
358
}
@@ -368,7 +368,7 @@ impl fmt::Display for Mp4Type {
368
368
Mp4Type :: M4v => "m4v" ,
369
369
Mp4Type :: Mov => "mov" ,
370
370
} ;
371
- write ! ( f, "{}" , text )
371
+ write ! ( f, "{text}" )
372
372
}
373
373
}
374
374
@@ -568,7 +568,7 @@ impl fmt::Display for DecoderError {
568
568
#[ cfg( feature = "symphonia" ) ]
569
569
DecoderError :: NoStreams => "No streams" ,
570
570
} ;
571
- write ! ( f, "{}" , text )
571
+ write ! ( f, "{text}" )
572
572
}
573
573
}
574
574
Original file line number Diff line number Diff line change 90
90
self . samples_read += 1 ;
91
91
i32_to_i16 ( value. unwrap_or ( 0 ) )
92
92
} ) ,
93
- ( sample_format, bits_per_sample) => panic ! (
94
- "Unimplemented wav spec: {:?}, {}" ,
95
- sample_format, bits_per_sample
96
- ) ,
93
+ ( sample_format, bits_per_sample) => {
94
+ panic ! ( "Unimplemented wav spec: {sample_format:?}, {bits_per_sample}" )
95
+ }
97
96
}
98
97
}
99
98
Original file line number Diff line number Diff line change @@ -208,7 +208,7 @@ impl CpalDeviceExt for cpal::Device {
208
208
let ( mixer_tx, mut mixer_rx) =
209
209
dynamic_mixer:: mixer :: < f32 > ( format. channels ( ) , format. sample_rate ( ) . 0 ) ;
210
210
211
- let error_callback = |err| eprintln ! ( "an error occurred on output stream: {}" , err ) ;
211
+ let error_callback = |err| eprintln ! ( "an error occurred on output stream: {err}" ) ;
212
212
213
213
match format. sample_format ( ) {
214
214
cpal:: SampleFormat :: F32 => self . build_output_stream :: < f32 , _ , _ > (
Original file line number Diff line number Diff line change @@ -17,8 +17,7 @@ fn test_flac_encodings() {
17
17
18
18
// 24 bit FLAC file exported from Audacity (2 channels, various compression levels)
19
19
for level in & [ 0 , 5 , 8 ] {
20
- let file =
21
- std:: fs:: File :: open ( format ! ( "assets/audacity24bit_level{}.flac" , level) ) . unwrap ( ) ;
20
+ let file = std:: fs:: File :: open ( format ! ( "assets/audacity24bit_level{level}.flac" ) ) . unwrap ( ) ;
22
21
let mut decoder = rodio:: Decoder :: new ( BufReader :: new ( file) ) . unwrap ( ) ;
23
22
assert ! ( decoder. any( |x| x != 0 ) ) ;
24
23
#[ cfg( all( feature = "flac" , not( feature = "symphonia-flac" ) ) ) ]
You can’t perform that action at this time.
0 commit comments