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 @@ -2463,17 +2463,15 @@ impl<R: Read> Iterator for Bytes<R> {
24632463 }
24642464 }
24652465
2466- default fn size_hint ( & self ) -> ( usize , Option < usize > ) {
2466+ fn size_hint ( & self ) -> ( usize , Option < usize > ) {
24672467 ( & self . inner as & dyn SizeHint ) . size_hint ( )
24682468 }
24692469}
24702470
24712471trait SizeHint {
24722472 fn lower_bound ( & self ) -> usize ;
24732473
2474- fn upper_bound ( & self ) -> Option < usize > {
2475- None
2476- }
2474+ fn upper_bound ( & self ) -> Option < usize > ;
24772475
24782476 fn size_hint ( & self ) -> ( usize , Option < usize > ) {
24792477 ( self . lower_bound ( ) , self . upper_bound ( ) )
@@ -2484,6 +2482,10 @@ impl<T> SizeHint for T {
24842482 default fn lower_bound ( & self ) -> usize {
24852483 0
24862484 }
2485+
2486+ default fn upper_bound ( & self ) -> Option < usize > {
2487+ None
2488+ }
24872489}
24882490
24892491impl < T > SizeHint for BufReader < T > {
You can’t perform that action at this time.
0 commit comments