aboutsummaryrefslogtreecommitdiff
path: root/std/c
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2017-11-10 16:45:01 -0500
committerAndrew Kelley <superjoe30@gmail.com>2017-11-10 16:45:01 -0500
commitdf89291d1ca04a5891dd48ea5f6d1a99b6006bcb (patch)
tree83970de0fdaa7383c11f64efceff7f88d6fd9cd9 /std/c
parente9d7623e1f0300b1b652373f2e0e7b605eaf13d1 (diff)
parent019f18058bb74816f8754de63a219347597e06da (diff)
downloadzig-df89291d1ca04a5891dd48ea5f6d1a99b6006bcb.tar.gz
zig-df89291d1ca04a5891dd48ea5f6d1a99b6006bcb.zip
Merge remote-tracking branch 'origin/master' into llvm6
Diffstat (limited to 'std/c')
-rw-r--r--std/c/darwin.zig26
-rw-r--r--std/c/index.zig1
2 files changed, 15 insertions, 12 deletions
diff --git a/std/c/darwin.zig b/std/c/darwin.zig
index 7ce29b5076..433463fde9 100644
--- a/std/c/darwin.zig
+++ b/std/c/darwin.zig
@@ -6,26 +6,28 @@ pub const _errno = __error;
/// Renamed to Stat to not conflict with the stat function.
pub const Stat = extern struct {
- dev: u32,
+ dev: i32,
mode: u16,
nlink: u16,
ino: u64,
uid: u32,
gid: u32,
- rdev: u64,
-
- atim: timespec,
- mtim: timespec,
- ctim: timespec,
-
- size: u64,
- blocks: u64,
- blksize: u32,
+ rdev: i32,
+ atime: usize,
+ atimensec: usize,
+ mtime: usize,
+ mtimensec: usize,
+ ctime: usize,
+ ctimensec: usize,
+ birthtime: usize,
+ birthtimensec: usize,
+ size: i64,
+ blocks: i64,
+ blksize: i32,
flags: u32,
gen: u32,
lspare: i32,
- qspare: [2]u64,
-
+ qspare: [2]i64,
};
pub const timespec = extern struct {
diff --git a/std/c/index.zig b/std/c/index.zig
index 315ccc5292..2ac867ee71 100644
--- a/std/c/index.zig
+++ b/std/c/index.zig
@@ -14,6 +14,7 @@ pub extern "c" fn exit(code: c_int) -> noreturn;
pub extern "c" fn isatty(fd: c_int) -> c_int;
pub extern "c" fn close(fd: c_int) -> c_int;
pub extern "c" fn fstat(fd: c_int, buf: &Stat) -> c_int;
+pub extern "c" fn @"fstat$INODE64"(fd: c_int, buf: &Stat) -> c_int;
pub extern "c" fn lseek(fd: c_int, offset: isize, whence: c_int) -> isize;
pub extern "c" fn open(path: &const u8, oflag: c_int, ...) -> c_int;
pub extern "c" fn raise(sig: c_int) -> c_int;