| author | |
| committer | |
| log | 7e83e7d9a8c77e875090174b167fd2d376574087 |
| tree | e4e515147466d09069e11fed93ebd6417a215ab8 |
| parent | bec85117283998c1e8cefa7a448c9c18b02236f9 |
Minor changes as per 7680c5330cb mostly about pipe2() flags.
closes #189277 files changed, 9 insertions(+), 9 deletions(-)
lib/std/c/dragonfly.zig+1-1| ... | ... | @@ -12,7 +12,7 @@ pub fn _errno() *c_int { |
| 12 | 12 | pub extern "c" fn getdents(fd: c_int, buf_ptr: [*]u8, nbytes: usize) c_int; |
| 13 | 13 | pub extern "c" fn sigaltstack(ss: ?*stack_t, old_ss: ?*stack_t) c_int; |
| 14 | 14 | pub extern "c" fn getrandom(buf_ptr: [*]u8, buf_len: usize, flags: c_uint) isize; |
| 15 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: u32) c_int; | |
| 15 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: std.c.O) c_int; | |
| 16 | 16 | pub extern "c" fn arc4random_buf(buf: [*]u8, len: usize) void; |
| 17 | 17 | |
| 18 | 18 | pub const dl_iterate_phdr_callback = *const fn (info: *dl_phdr_info, size: usize, data: ?*anyopaque) callconv(.C) c_int; |
lib/std/c/emscripten.zig+1-1| ... | ... | @@ -147,7 +147,7 @@ pub const pwritev64 = std.c.pwritev; |
| 147 | 147 | pub const setrlimit64 = std.c.setrlimit; |
| 148 | 148 | |
| 149 | 149 | pub extern "c" fn sigaltstack(ss: ?*stack_t, old_ss: ?*stack_t) c_int; |
| 150 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: u32) c_int; | |
| 150 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: std.c.O) c_int; | |
| 151 | 151 | pub extern "c" fn getentropy(buffer: [*]u8, size: usize) c_int; |
| 152 | 152 | |
| 153 | 153 | pub const pthread_attr_t = extern struct { |
lib/std/c/freebsd.zig+1-1| ... | ... | @@ -15,7 +15,7 @@ pub extern "c" fn getrandom(buf_ptr: [*]u8, buf_len: usize, flags: c_uint) isize |
| 15 | 15 | pub extern "c" fn pthread_getthreadid_np() c_int; |
| 16 | 16 | pub extern "c" fn pthread_set_name_np(thread: std.c.pthread_t, name: [*:0]const u8) void; |
| 17 | 17 | pub extern "c" fn pthread_get_name_np(thread: std.c.pthread_t, name: [*:0]u8, len: usize) void; |
| 18 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: u32) c_int; | |
| 18 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: std.c.O) c_int; | |
| 19 | 19 | pub extern "c" fn arc4random_buf(buf: [*]u8, len: usize) void; |
| 20 | 20 | |
| 21 | 21 | pub extern "c" fn posix_memalign(memptr: *?*anyopaque, alignment: usize, size: usize) c_int; |
lib/std/c/netbsd.zig+3-3| ... | ... | @@ -15,7 +15,7 @@ pub extern "c" fn dl_iterate_phdr(callback: dl_iterate_phdr_callback, data: ?*an |
| 15 | 15 | |
| 16 | 16 | pub extern "c" fn _lwp_self() lwpid_t; |
| 17 | 17 | |
| 18 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: u32) c_int; | |
| 18 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: std.c.O) c_int; | |
| 19 | 19 | pub extern "c" fn arc4random_buf(buf: [*]u8, len: usize) void; |
| 20 | 20 | |
| 21 | 21 | pub extern "c" fn __stat50(path: [*:0]const u8, buf: *Stat) c_int; |
| ... | ... | @@ -59,7 +59,7 @@ pub extern "c" fn posix_memalign(memptr: *?*anyopaque, alignment: usize, size: u |
| 59 | 59 | pub extern "c" fn __msync13(addr: *align(std.mem.page_size) const anyopaque, len: usize, flags: c_int) c_int; |
| 60 | 60 | pub const msync = __msync13; |
| 61 | 61 | |
| 62 | const pthread_spin_t = switch (builtin.cpu.arch) { | |
| 62 | pub const pthread_spin_t = switch (builtin.cpu.arch) { | |
| 63 | 63 | .aarch64, .aarch64_be, .aarch64_32 => u8, |
| 64 | 64 | .mips, .mipsel, .mips64, .mips64el => u32, |
| 65 | 65 | .powerpc, .powerpc64, .powerpc64le => i32, |
| ... | ... | @@ -70,7 +70,7 @@ const pthread_spin_t = switch (builtin.cpu.arch) { |
| 70 | 70 | else => @compileError("undefined pthread_spin_t for this arch"), |
| 71 | 71 | }; |
| 72 | 72 | |
| 73 | const padded_pthread_spin_t = switch (builtin.cpu.arch) { | |
| 73 | pub const padded_pthread_spin_t = switch (builtin.cpu.arch) { | |
| 74 | 74 | .x86, .x86_64 => u32, |
| 75 | 75 | .sparc, .sparcel, .sparc64 => u32, |
| 76 | 76 | else => pthread_spin_t, |
lib/std/c/openbsd.zig+1-1| ... | ... | @@ -14,7 +14,7 @@ pub extern "c" fn dl_iterate_phdr(callback: dl_iterate_phdr_callback, data: ?*an |
| 14 | 14 | pub extern "c" fn arc4random_buf(buf: [*]u8, len: usize) void; |
| 15 | 15 | |
| 16 | 16 | pub extern "c" fn getthrid() pid_t; |
| 17 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: u32) c_int; | |
| 17 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: std.c.O) c_int; | |
| 18 | 18 | |
| 19 | 19 | pub extern "c" fn getdents(fd: c_int, buf_ptr: [*]u8, nbytes: usize) c_int; |
| 20 | 20 | pub extern "c" fn sigaltstack(ss: ?*stack_t, old_ss: ?*stack_t) c_int; |
lib/std/c/solaris.zig+1-1| ... | ... | @@ -14,7 +14,7 @@ pub extern "c" fn dl_iterate_phdr(callback: dl_iterate_phdr_callback, data: ?*an |
| 14 | 14 | |
| 15 | 15 | pub extern "c" fn getdents(fd: c_int, buf_ptr: [*]u8, nbytes: usize) usize; |
| 16 | 16 | pub extern "c" fn sigaltstack(ss: ?*stack_t, old_ss: ?*stack_t) c_int; |
| 17 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: u32) c_int; | |
| 17 | pub extern "c" fn pipe2(fds: *[2]fd_t, flags: std.c.O) c_int; | |
| 18 | 18 | pub extern "c" fn arc4random_buf(buf: [*]u8, len: usize) void; |
| 19 | 19 | pub extern "c" fn posix_memalign(memptr: *?*anyopaque, alignment: usize, size: usize) c_int; |
| 20 | 20 | pub extern "c" fn sysconf(sc: c_int) i64; |
lib/std/fs/Dir.zig+1-1| ... | ... | @@ -174,7 +174,7 @@ pub const Iterator = switch (builtin.os.tag) { |
| 174 | 174 | self.end_index = @as(usize, @intCast(rc)); |
| 175 | 175 | } |
| 176 | 176 | const bsd_entry = @as(*align(1) posix.system.dirent, @ptrCast(&self.buf[self.index])); |
| 177 | const next_index = self.index + bsd_entry.reclen; | |
| 177 | const next_index = self.index + if (@hasDecl(posix.system.dirent, "reclen")) bsd_entry.reclen() else bsd_entry.reclen; | |
| 178 | 178 | self.index = next_index; |
| 179 | 179 | |
| 180 | 180 | const name = @as([*]u8, @ptrCast(&bsd_entry.name))[0..bsd_entry.namlen]; |