compile.c: private reader in op_assign

* compile.c (iseq_compile_each): allow to access private attribute
  reader in op_assign.  [ruby-core:63817] [Bug #10060]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46873 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2014-07-19 03:40:52 +00:00
parent f75b676cc4
commit bc45eed1e5
3 changed files with 12 additions and 6 deletions

View file

@ -106,9 +106,9 @@ class TestAssignment < Test::Unit::TestCase
o = Object.new
class << o
private
def foo; 42; end
def [](i); 42; end
private
def foo=(a); 42; end
def []=(i, a); 42; end
end