mirror of
https://github.com/ruby/ruby.git
synced 2025-09-24 04:54:01 +02:00
* vm_method.c (rb_alias): hooks are called from rb_add_method_def.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24868 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
d7feab06cc
commit
efa4ed8cce
3 changed files with 16 additions and 17 deletions
|
@ -769,9 +769,21 @@ class TestModule < Test::Unit::TestCase
|
|||
end
|
||||
def f
|
||||
end
|
||||
alias g f
|
||||
attr_reader :a
|
||||
attr_writer :a
|
||||
end
|
||||
assert_equal :f, memo.shift
|
||||
assert_equal mod.instance_methods(false), memo.shift
|
||||
assert_equal [:f], memo.shift, '[ruby-core:25536]'
|
||||
assert_equal mod.instance_method(:f), memo.shift
|
||||
assert_equal :g, memo.shift
|
||||
assert_equal [:f, :g], memo.shift
|
||||
assert_equal mod.instance_method(:f), memo.shift
|
||||
assert_equal :a, memo.shift
|
||||
assert_equal [:f, :g, :a], memo.shift
|
||||
assert_equal mod.instance_method(:a), memo.shift
|
||||
assert_equal :a=, memo.shift
|
||||
assert_equal [:f, :g, :a, :a=], memo.shift
|
||||
assert_equal mod.instance_method(:a=), memo.shift
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue