diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-12-22 13:15:58 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-12-22 13:15:58 +0000 |
commit | 366de1fccd77b78dfe7dc34b7283ab4100cc6b0e (patch) | |
tree | 23a6763c57b782d374aa8a02deba2a4a7aabd7f6 /internal.h | |
parent | 5db09062bbb5d0934a13ceebf01b49bc2527546e (diff) | |
download | ruby-366de1fccd77b78dfe7dc34b7283ab4100cc6b0e.tar.gz |
gc.c: do not expose internal singleton class
* gc.c (internal_object_p): should not expose singleton classes
without a metaclass. based on patches by ko1 and shugo.
[Bug #11740]
* class.c (rb_singleton_class_object_p): added.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53243 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'internal.h')
-rw-r--r-- | internal.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/internal.h b/internal.h index 142f14dc39..83a7d051ac 100644 --- a/internal.h +++ b/internal.h @@ -491,6 +491,7 @@ struct RClass { void rb_class_subclass_add(VALUE super, VALUE klass); void rb_class_remove_from_super_subclasses(VALUE); +int rb_singleton_class_internal_p(VALUE sklass); #define RCLASS_EXT(c) (RCLASS(c)->ptr) #define RCLASS_IV_TBL(c) (RCLASS_EXT(c)->iv_tbl) |