diff options
Diffstat (limited to 'include/ruby/ruby.h')
-rw-r--r-- | include/ruby/ruby.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h index 26bd2ee065..7b482ccb17 100644 --- a/include/ruby/ruby.h +++ b/include/ruby/ruby.h @@ -129,6 +129,16 @@ typedef char ruby_check_sizeof_voidp[SIZEOF_VOIDP == sizeof(void*) ? 1 : -1]; # define PRI_VALUE_PREFIX "" #endif +#ifndef PRI_TIMET_PREFIX +# if SIZEOF_TIME_T == SIZEOF_INT +# define PRI_TIMET_PREFIX +# elif SIZEOF_TIME_T == SIZEOF_LONG +# define PRI_TIMET_PREFIX "l" +# elif SIZEOF_TIME_T == SIZEOF_LONG_LONG +# define PRI_TIMET_PREFIX "ll" +# endif +#endif + #if defined PRIdPTR # define PRI_PTRDIFF_PREFIX "t" #elif SIZEOF_PTRDIFF_T == SIZEOF_INT |