summaryrefslogtreecommitdiffstats
path: root/ruby.h
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-12-26 08:08:50 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-12-26 08:08:50 +0000
commitb35585f1361707e83be7509e309bac3c6738a81b (patch)
treec068f2e637141759cd50649e15e86eaabafe9b36 /ruby.h
parentfcae2fd9b2eedc748432ad02f9aa5c72aa930c96 (diff)
downloadruby-b35585f1361707e83be7509e309bac3c6738a81b.tar.gz
ruby-b35585f1361707e83be7509e309bac3c6738a81b.tar.xz
ruby-b35585f1361707e83be7509e309bac3c6738a81b.zip
matz
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@1079 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ruby.h')
-rw-r--r--ruby.h28
1 files changed, 16 insertions, 12 deletions
diff --git a/ruby.h b/ruby.h
index ca97ee2c4..9784fc65d 100644
--- a/ruby.h
+++ b/ruby.h
@@ -541,12 +541,15 @@ EXTERN VALUE rb_eNameError;
EXTERN VALUE rb_eSyntaxError;
EXTERN VALUE rb_eLoadError;
-#if defined(__GNUC__) && __GNUC__ >= 2 && !defined(RUBY_NO_INLINE)
-extern __inline__ VALUE rb_class_of _((VALUE));
-extern __inline__ int rb_type _((VALUE));
-extern __inline__ int rb_special_const_p _((VALUE));
+extern INLINE VALUE rb_class_of _((VALUE));
+extern INLINE int rb_type _((VALUE));
+extern INLINE int rb_special_const_p _((VALUE));
-extern __inline__ VALUE
+#if defined(HAVE_INLINE) || defined(RUBY_NO_INLINE)
+#ifndef RUBY_NO_INLINE
+extern
+#endif
+INLINE VALUE
rb_class_of(VALUE obj)
{
if (FIXNUM_P(obj)) return rb_cFixnum;
@@ -558,7 +561,10 @@ rb_class_of(VALUE obj)
return RBASIC(obj)->klass;
}
-extern __inline__ int
+#ifndef RUBY_NO_INLINE
+extern
+#endif
+INLINE int
rb_type(VALUE obj)
{
if (FIXNUM_P(obj)) return T_FIXNUM;
@@ -570,17 +576,15 @@ rb_type(VALUE obj)
return BUILTIN_TYPE(obj);
}
-extern __inline__ int
+#ifndef RUBY_NO_INLINE
+extern
+#endif
+INLINE int
rb_special_const_p(VALUE obj)
{
if (SPECIAL_CONST_P(obj)) return Qtrue;
return Qfalse;
}
-
-#else
-VALUE rb_class_of _((VALUE));
-int rb_type _((VALUE));
-int rb_special_const_p _((VALUE));
#endif
#include "intern.h"
OSZAR »