Skip to content

Commit ea9b38c

Browse files
xtianandrewrk
authored andcommitted
fs/file.zig: Update reader to use type alias
This is a minor cosmetic change which updates `reader` and `inStream` to match `writer` and `outStream` below.
1 parent 13b8c63 commit ea9b38c

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/std/fs/file.zig

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -740,14 +740,16 @@ pub const File = struct {
740740
}
741741

742742
pub const Reader = io.Reader(File, ReadError, read);
743+
743744
/// Deprecated: use `Reader`
744745
pub const InStream = Reader;
745746

746-
pub fn reader(file: File) io.Reader(File, ReadError, read) {
747+
pub fn reader(file: File) Reader {
747748
return .{ .context = file };
748749
}
750+
749751
/// Deprecated: use `reader`
750-
pub fn inStream(file: File) io.InStream(File, ReadError, read) {
752+
pub fn inStream(file: File) Reader {
751753
return .{ .context = file };
752754
}
753755

0 commit comments

Comments
 (0)