зеркало из https://github.com/github/ruby.git
* ruby.h: better inline function support.
* configure.in (NO_C_INLINE): check if inline is available for the C compiler. * marshal.c (r_object): len calculation patch was wrong for machines SIZEOF_BDIGITS == SIZEOF_SHORT. * gc.c: alloca prototype reorganized for C_ALLOCA machine. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1275 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
22198c30b1
Коммит
285cb99ba4
14
ChangeLog
14
ChangeLog
|
@ -1,3 +1,17 @@
|
|||
Thu Mar 22 17:43:44 2001 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||
|
||||
* ruby.h: better inline function support.
|
||||
|
||||
* configure.in (NO_C_INLINE): check if inline is available for the
|
||||
C compiler.
|
||||
|
||||
Mon Mar 19 11:03:10 2001 Koji Arai <JCA02266@nifty.ne.jp>
|
||||
|
||||
* marshal.c (r_object): len calculation patch was wrong for
|
||||
machines SIZEOF_BDIGITS == SIZEOF_SHORT.
|
||||
|
||||
* gc.c: alloca prototype reorganized for C_ALLOCA machine.
|
||||
|
||||
Wed Mar 21 23:07:45 2001 WATANABE Hirofumi <eban@ruby-lang.org>
|
||||
|
||||
* win32/win32.c (win32_stat): WinNT/2k "//host/share" support.
|
||||
|
|
|
@ -374,10 +374,13 @@ main()
|
|||
], rb_cv_func_strtod=yes, rb_cv_func_strtod=no, rb_cv_func_strtod=no)])
|
||||
test $rb_cv_func_strtod = no && LIBOBJS="$LIBOBJS strtod.o"
|
||||
|
||||
AC_C_INLINE
|
||||
AC_C_BIGENDIAN
|
||||
AC_C_CONST
|
||||
AC_C_CHAR_UNSIGNED
|
||||
AC_C_INLINE
|
||||
if test "$ac_cv_c_inline" = no; then
|
||||
AC_DEFINE(NO_C_INLINE)
|
||||
fi
|
||||
|
||||
AC_CACHE_CHECK(whether right shift preserve sign bit, rb_cv_rshift_sign,
|
||||
[AC_TRY_RUN([
|
||||
|
|
6
gc.c
6
gc.c
|
@ -50,12 +50,6 @@ void *alloca();
|
|||
#pragma alloca
|
||||
#endif
|
||||
|
||||
#ifdef C_ALLOCA
|
||||
#ifndef alloca
|
||||
void *alloca();
|
||||
#endif
|
||||
#endif
|
||||
|
||||
static void run_final();
|
||||
|
||||
#ifndef GC_MALLOC_LIMIT
|
||||
|
|
|
@ -824,7 +824,11 @@ r_object(arg)
|
|||
OBJSETUP(big, rb_cBignum, T_BIGNUM);
|
||||
big->sign = (r_byte(arg) == '+');
|
||||
len = r_long(arg);
|
||||
#if SIZEOF_BDIGITS == SIZEOF_SHORT
|
||||
big->len = len;
|
||||
#else
|
||||
big->len = (len + 1) * sizeof(short) / sizeof(BDIGIT);
|
||||
#endif
|
||||
big->digits = digits = ALLOC_N(BDIGIT, big->len);
|
||||
while (len > 0) {
|
||||
#if SIZEOF_BDIGITS > SIZEOF_SHORT
|
||||
|
|
26
ruby.h
26
ruby.h
|
@ -545,11 +545,10 @@ extern inline VALUE rb_class_of _((VALUE));
|
|||
extern inline int rb_type _((VALUE));
|
||||
extern inline int rb_special_const_p _((VALUE));
|
||||
|
||||
#ifndef RUBY_NO_INLINE
|
||||
extern inline
|
||||
#endif
|
||||
VALUE
|
||||
rb_class_of(VALUE obj)
|
||||
#if !defined(NO_C_INLINE) || defined(INLINE_DEFINE)
|
||||
extern inline VALUE
|
||||
rb_class_of(obj)
|
||||
VALUE obj;
|
||||
{
|
||||
if (FIXNUM_P(obj)) return rb_cFixnum;
|
||||
if (obj == Qnil) return rb_cNilClass;
|
||||
|
@ -560,11 +559,9 @@ rb_class_of(VALUE obj)
|
|||
return RBASIC(obj)->klass;
|
||||
}
|
||||
|
||||
#ifndef RUBY_NO_INLINE
|
||||
extern inline
|
||||
#endif
|
||||
int
|
||||
rb_type(VALUE obj)
|
||||
extern inline int
|
||||
rb_type(obj)
|
||||
VALUE obj;
|
||||
{
|
||||
if (FIXNUM_P(obj)) return T_FIXNUM;
|
||||
if (obj == Qnil) return T_NIL;
|
||||
|
@ -575,15 +572,14 @@ rb_type(VALUE obj)
|
|||
return BUILTIN_TYPE(obj);
|
||||
}
|
||||
|
||||
#ifndef RUBY_NO_INLINE
|
||||
extern inline
|
||||
#endif
|
||||
int
|
||||
rb_special_const_p(VALUE obj)
|
||||
extern inline int
|
||||
rb_special_const_p(obj)
|
||||
VALUE obj;
|
||||
{
|
||||
if (SPECIAL_CONST_P(obj)) return Qtrue;
|
||||
return Qfalse;
|
||||
}
|
||||
#endif
|
||||
|
||||
#include "intern.h"
|
||||
|
||||
|
|
2
util.c
2
util.c
|
@ -16,7 +16,7 @@
|
|||
#include "missing/file.h"
|
||||
#endif
|
||||
|
||||
#define RUBY_NO_INLINE
|
||||
#define INLINE_DEFINE
|
||||
#include "ruby.h"
|
||||
|
||||
#include "util.h"
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
#define RUBY_VERSION "1.7.0"
|
||||
#define RUBY_RELEASE_DATE "2001-03-21"
|
||||
#define RUBY_RELEASE_DATE "2001-03-22"
|
||||
#define RUBY_VERSION_CODE 170
|
||||
#define RUBY_RELEASE_CODE 20010321
|
||||
#define RUBY_RELEASE_CODE 20010322
|
||||
|
|
Загрузка…
Ссылка в новой задаче