summaryrefslogtreecommitdiff
path: root/spec/ruby/core/kernel/fixtures/classes.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/core/kernel/fixtures/classes.rb')
-rw-r--r--spec/ruby/core/kernel/fixtures/classes.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/spec/ruby/core/kernel/fixtures/classes.rb b/spec/ruby/core/kernel/fixtures/classes.rb
index 8de1407b92..541a4c075e 100644
--- a/spec/ruby/core/kernel/fixtures/classes.rb
+++ b/spec/ruby/core/kernel/fixtures/classes.rb
@@ -281,9 +281,14 @@ module KernelSpecs
@two = two
end
- def initialize_copy(other)
+ def initialize_copy(other, **kw)
ScratchPad.record object_id
end
+
+ # define to support calling #clone with optional :freeze keyword argument
+ def initialize_clone(other, **kw)
+ super(other) # to call #initialize_copy
+ end
end
class Clone