summaryrefslogtreecommitdiff
path: root/ruby.h
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-07-26 09:16:37 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-07-26 09:16:37 +0000
commit3c456d3a5d259b37652c2ae20455c16fa02d2e8e (patch)
tree00be65e09dde68ee5faaf36f101ef6e3c21b5e33 /ruby.h
parent393197aa7f5d8d9c7afad804aa36be8c6b76d27d (diff)
* ruby.h: support LLP64 model. [ruby-talk:149524]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8838 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ruby.h')
-rw-r--r--ruby.h13
1 files changed, 10 insertions, 3 deletions
diff --git a/ruby.h b/ruby.h
index e1cbb94..91d01d5 100644
--- a/ruby.h
+++ b/ruby.h
@@ -70,11 +70,18 @@ extern "C" {
# define alloca __alloca
#endif
-#if SIZEOF_LONG != SIZEOF_VOIDP
-# error ---->> ruby requires sizeof(void*) == sizeof(long) to be compiled. <<----
-#endif
+#if SIZEOF_LONG == SIZEOF_VOIDP
typedef unsigned long VALUE;
typedef unsigned long ID;
+#elif SIZEOF_LONG_LONG == SIZEOF_VOIDP
+typedef unsigned long long VALUE;
+typedef unsigned long long ID;
+#elif SIZEOF___INT64 == SIZEOF_VOIDP
+typedef unsigned __int64 VALUE;
+typedef unsigned __int64 ID;
+#else
+# error ---->> ruby requires sizeof(void*) == sizeof(long) to be compiled. <<----
+#endif
#ifdef __STDC__
# include <limits.h>