summaryrefslogtreecommitdiff
path: root/include/ruby/win32.h
diff options
context:
space:
mode:
authorusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-08-15 05:32:02 +0000
committerusa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-08-15 05:32:02 +0000
commit866cee61626d6df0c41d02ff0e7ced8f940736f3 (patch)
treef291f7b00e706ea524e8f791fd1651e8886d535c /include/ruby/win32.h
parent3670ca436e55e227ab7ec4b912cf17200bd7fe22 (diff)
* include/ruby/win32.h, win32/Makefile.sub, win32/win32.c
(clock_gettime): [experimental] emulates clock_gettime(2) of posix. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include/ruby/win32.h')
-rw-r--r--include/ruby/win32.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/ruby/win32.h b/include/ruby/win32.h
index 809784d..b8c99b2 100644
--- a/include/ruby/win32.h
+++ b/include/ruby/win32.h
@@ -124,6 +124,10 @@ typedef unsigned int uintptr_t;
#define WNOHANG -1
+typedef int clockid_t;
+#define CLOCK_REALTIME 0
+#define CLOCK_MONOTINIC 1
+
#undef getc
#undef putc
#undef fgetc
@@ -312,6 +316,7 @@ extern int rb_w32_uchown(const char *, int, int);
extern int link(const char *, const char *);
extern int rb_w32_ulink(const char *, const char *);
extern int gettimeofday(struct timeval *, struct timezone *);
+extern int clock_gettime(clockid_t, struct timespec *);
extern rb_pid_t waitpid (rb_pid_t, int *, int);
extern rb_pid_t rb_w32_spawn(int, const char *, const char*);
extern rb_pid_t rb_w32_aspawn(int, const char *, char *const *);