1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* gc.c (id2ref): skip ICLASS.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13583 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2007-10-01 06:57:56 +00:00
parent e5a15da799
commit 36585f17fb
2 changed files with 6 additions and 1 deletions

View file

@ -1,3 +1,7 @@
Mon Oct 1 15:57:49 2007 Nobuyoshi Nakada <nobu@ruby-lang.org>
* gc.c (id2ref): skip ICLASS.
Mon Oct 1 15:29:35 2007 Tanaka Akira <akr@fsij.org>
* bootstraptest/runner.rb (assert_normal_exit): use `` instead of

3
gc.c
View file

@ -2069,7 +2069,8 @@ id2ref(VALUE obj, VALUE objid)
return ID2SYM(symid);
}
if (!is_pointer_to_heap((void *)ptr) || BUILTIN_TYPE(ptr) >= T_VALUES) {
if (!is_pointer_to_heap((void *)ptr) ||
BUILTIN_TYPE(ptr) >= T_VALUES || BUILTIN_TYPE(ptr) == T_ICLASS) {
rb_raise(rb_eRangeError, "%p is not id value", p0);
}
if (BUILTIN_TYPE(ptr) == 0 || RBASIC(ptr)->klass == 0) {