File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -135,7 +135,10 @@ pub trait FileDescription: std::fmt::Debug + FileDescriptionExt {
135135
136136 /// Reads as much as possible into the given buffer `ptr`.
137137 /// `len` indicates how many bytes we should try to read.
138- /// `dest` is where the return value should be stored: number of bytes read, or `-1` in case of error.
138+ ///
139+ /// When the read is done, `finish` will be called. Note that `read` itself may return before
140+ /// that happens! Everything that should happen "after" the `read` needs to happen inside
141+ /// `finish`.
139142 fn read < ' tcx > (
140143 self : FileDescriptionRef < Self > ,
141144 _communicate_allowed : bool ,
@@ -149,7 +152,10 @@ pub trait FileDescription: std::fmt::Debug + FileDescriptionExt {
149152
150153 /// Writes as much as possible from the given buffer `ptr`.
151154 /// `len` indicates how many bytes we should try to write.
152- /// `dest` is where the return value should be stored: number of bytes written, or `-1` in case of error.
155+ ///
156+ /// When the write is done, `finish` will be called. Note that `write` itself may return before
157+ /// that happens! Everything that should happen "after" the `write` needs to happen inside
158+ /// `finish`.
153159 fn write < ' tcx > (
154160 self : FileDescriptionRef < Self > ,
155161 _communicate_allowed : bool ,
You can’t perform that action at this time.
0 commit comments