File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -2466,17 +2466,15 @@ impl<R: Read> Iterator for Bytes<R> {
24662466 }
24672467 }
24682468
2469- default fn size_hint ( & self ) -> ( usize , Option < usize > ) {
2469+ fn size_hint ( & self ) -> ( usize , Option < usize > ) {
24702470 ( & self . inner as & dyn SizeHint ) . size_hint ( )
24712471 }
24722472}
24732473
24742474trait SizeHint {
24752475 fn lower_bound ( & self ) -> usize ;
24762476
2477- fn upper_bound ( & self ) -> Option < usize > {
2478- None
2479- }
2477+ fn upper_bound ( & self ) -> Option < usize > ;
24802478
24812479 fn size_hint ( & self ) -> ( usize , Option < usize > ) {
24822480 ( self . lower_bound ( ) , self . upper_bound ( ) )
@@ -2487,6 +2485,10 @@ impl<T> SizeHint for T {
24872485 default fn lower_bound ( & self ) -> usize {
24882486 0
24892487 }
2488+
2489+ default fn upper_bound ( & self ) -> Option < usize > {
2490+ None
2491+ }
24902492}
24912493
24922494impl < T > SizeHint for BufReader < T > {
You can’t perform that action at this time.
0 commit comments