diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-10-01 06:57:56 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-10-01 06:57:56 +0000 |
commit | 36585f17fb8deb2042c36842c68637b740565811 (patch) | |
tree | 911831920c055e9c601f38d06b353098666dfa70 | |
parent | e5a15da7990e9bc98733b11cfae3180023e82ee3 (diff) | |
download | ruby-36585f17fb8deb2042c36842c68637b740565811.tar.gz |
* gc.c (id2ref): skip ICLASS.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13583 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | gc.c | 3 |
2 files changed, 6 insertions, 1 deletions
@@ -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 @@ -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) { |