@@ -1051,9 +1051,17 @@ where
1051
1051
for_both ! ( * self , ref mut inner => inner. read( buf) )
1052
1052
}
1053
1053
1054
+ fn read_exact ( & mut self , buf : & mut [ u8 ] ) -> io:: Result < ( ) > {
1055
+ for_both ! ( * self , ref mut inner => inner. read_exact( buf) )
1056
+ }
1057
+
1054
1058
fn read_to_end ( & mut self , buf : & mut std:: vec:: Vec < u8 > ) -> io:: Result < usize > {
1055
1059
for_both ! ( * self , ref mut inner => inner. read_to_end( buf) )
1056
1060
}
1061
+
1062
+ fn read_to_string ( & mut self , buf : & mut std:: string:: String ) -> io:: Result < usize > {
1063
+ for_both ! ( * self , ref mut inner => inner. read_to_string( buf) )
1064
+ }
1057
1065
}
1058
1066
1059
1067
#[ cfg( any( test, feature = "use_std" ) ) ]
@@ -1084,6 +1092,14 @@ where
1084
1092
fn consume ( & mut self , amt : usize ) {
1085
1093
for_both ! ( * self , ref mut inner => inner. consume( amt) )
1086
1094
}
1095
+
1096
+ fn read_until ( & mut self , byte : u8 , buf : & mut std:: vec:: Vec < u8 > ) -> io:: Result < usize > {
1097
+ for_both ! ( * self , ref mut inner => inner. read_until( byte, buf) )
1098
+ }
1099
+
1100
+ fn read_line ( & mut self , buf : & mut std:: string:: String ) -> io:: Result < usize > {
1101
+ for_both ! ( * self , ref mut inner => inner. read_line( buf) )
1102
+ }
1087
1103
}
1088
1104
1089
1105
#[ cfg( any( test, feature = "use_std" ) ) ]
@@ -1099,6 +1115,14 @@ where
1099
1115
for_both ! ( * self , ref mut inner => inner. write( buf) )
1100
1116
}
1101
1117
1118
+ fn write_all ( & mut self , buf : & [ u8 ] ) -> io:: Result < ( ) > {
1119
+ for_both ! ( * self , ref mut inner => inner. write_all( buf) )
1120
+ }
1121
+
1122
+ fn write_fmt ( & mut self , fmt : fmt:: Arguments < ' _ > ) -> io:: Result < ( ) > {
1123
+ for_both ! ( * self , ref mut inner => inner. write_fmt( fmt) )
1124
+ }
1125
+
1102
1126
fn flush ( & mut self ) -> io:: Result < ( ) > {
1103
1127
for_both ! ( * self , ref mut inner => inner. flush( ) )
1104
1128
}
0 commit comments