mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* class.c (rb_class_init_copy): raise a TypeError if the argument is
BasicObject. [ruby-core:27060] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26607 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
141179186b
commit
b09eabd430
3 changed files with 10 additions and 0 deletions
|
@ -181,6 +181,8 @@ class TestClass < Test::Unit::TestCase
|
|||
o = Object.new
|
||||
c = class << o; self; end
|
||||
assert_raise(TypeError) { c.dup }
|
||||
|
||||
assert_raise(TypeError) { BasicObject.dup }
|
||||
end
|
||||
|
||||
def test_singleton_class
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue