diff options
Diffstat (limited to 'spec/ruby/core/unboundmethod/fixtures/classes.rb')
-rw-r--r-- | spec/ruby/core/unboundmethod/fixtures/classes.rb | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/spec/ruby/core/unboundmethod/fixtures/classes.rb b/spec/ruby/core/unboundmethod/fixtures/classes.rb index 46b1c51669..28d8e0a965 100644 --- a/spec/ruby/core/unboundmethod/fixtures/classes.rb +++ b/spec/ruby/core/unboundmethod/fixtures/classes.rb @@ -22,6 +22,7 @@ module UnboundMethodSpecs module Mod def from_mod; end + def foo_super; super; end end class Methods @@ -53,10 +54,19 @@ module UnboundMethodSpecs def discard_1(); :discard; end def discard_2(); :discard; end + + def my_public_method; end + def my_protected_method; end + def my_private_method; end + protected :my_protected_method + private :my_private_method end class Parent def foo; end + def foo_super + true + end def self.class_method "I am #{name}" end @@ -84,4 +94,14 @@ module UnboundMethodSpecs class C < B def overridden; end end + + module HashSpecs + class SuperClass + def foo + end + end + + class SubClass < SuperClass + end + end end |