diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-04-30 02:59:44 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-04-30 02:59:44 +0000 |
commit | 27a9df2a6ba505846f25aa9cd4cb2627e753e6de (patch) | |
tree | 9083cf2f24bbb51f84bd5e876cc6bdd9473b205f /ruby.h | |
parent | 6d69a240b86c10f128347a681c731c5cda972e22 (diff) | |
download | ruby-27a9df2a6ba505846f25aa9cd4cb2627e753e6de.tar.gz |
* configure.in (RUBY_FUNC_ATTRIBUTE): check for function attribute.
[ruby-dev:26109]
* eval.c, gc.c: moved noinline to configure.in.
* rubyio.h (DEPRECATED): moved to configure.in.
* ruby.h (DEPRECATED, NOINLINE): default definition.
* win{32,ce}/Makefile.sub (config.h): deprecated and noinline for
__declspec() are available for VC++7 or later.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@8394 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ruby.h')
-rw-r--r-- | ruby.h | 14 |
1 files changed, 10 insertions, 4 deletions
@@ -56,6 +56,12 @@ extern "C" { #ifndef NORETURN # define NORETURN(x) x #endif +#ifndef DEPRECATED +# define DEPRECATED(x) x +#endif +#ifndef NOINLINE +# define NOINLINE(x) x +#endif #if defined(HAVE_ALLOCA_H) #include <alloca.h> @@ -633,12 +639,12 @@ rb_class_of(obj) VALUE obj; #endif { - if(IMMEDIATE_P(obj)){ + if (IMMEDIATE_P(obj)) { if (FIXNUM_P(obj)) return rb_cFixnum; if (obj == Qtrue) return rb_cTrueClass; if (SYMBOL_P(obj)) return rb_cSymbol; } - else if(!RTEST(obj)){ + else if (!RTEST(obj)) { if (obj == Qnil) return rb_cNilClass; if (obj == Qfalse) return rb_cFalseClass; } @@ -653,13 +659,13 @@ rb_type(obj) VALUE obj; #endif { - if(IMMEDIATE_P(obj)){ + if (IMMEDIATE_P(obj)) { if (FIXNUM_P(obj)) return T_FIXNUM; if (obj == Qtrue) return T_TRUE; if (SYMBOL_P(obj)) return T_SYMBOL; if (obj == Qundef) return T_UNDEF; } - else if(!RTEST(obj)){ + else if (!RTEST(obj)) { if (obj == Qnil) return T_NIL; if (obj == Qfalse) return T_FALSE; } |