Commit c48831512b

Andrew Kelley <andrew@ziglang.org>
2020-02-08 07:38:01
std lib typo fixups
1 parent eddca50
Changed files (3)
lib
lib/std/event/loop.zig
@@ -851,7 +851,7 @@ pub const Loop = struct {
 
     /// Performs an async `os.writev` using a separate thread.
     /// `fd` must block and not return EAGAIN.
-    pub fn writev(self: *Loop, fd: os.fd_t, iov: []const os.iovec_const) WriteError!void {
+    pub fn writev(self: *Loop, fd: os.fd_t, iov: []const os.iovec_const) os.WriteError!void {
         var req_node = Request.Node{
             .data = .{
                 .msg = .{
@@ -872,7 +872,7 @@ pub const Loop = struct {
 
     /// Performs an async `os.pwritev` using a separate thread.
     /// `fd` must block and not return EAGAIN.
-    pub fn pwritev(self: *Loop, fd: os.fd_t, iov: []const os.iovec_const, offset: u64) WriteError!void {
+    pub fn pwritev(self: *Loop, fd: os.fd_t, iov: []const os.iovec_const, offset: u64) os.WriteError!void {
         var req_node = Request.Node{
             .data = .{
                 .msg = .{
lib/std/fs.zig
@@ -706,6 +706,7 @@ pub const Dir = struct {
     }
 
     /// Opens a file for reading or writing, without attempting to create a new file.
+    /// To create a new file, see `createFile`.
     /// Call `File.close` to release the resource.
     /// Asserts that the path parameter has no null bytes.
     pub fn openFile(self: Dir, sub_path: []const u8, flags: File.OpenFlags) File.OpenError!File {
lib/std/net.zig
@@ -378,8 +378,8 @@ pub fn connectUnixSocket(path: []const u8) !fs.File {
     );
 
     return fs.File{
-        .handle = socket,
-        .is_blocking = std.io.mode,
+        .handle = sockfd,
+        .io_mode = std.io.mode,
     };
 }