Skip to content
Permalink
Browse files
BlockEnvironment::AsMethod#scope should return the scope of block_env
  • Loading branch information
tak1n committed Feb 6, 2016
1 parent 161a787 commit d59ca90e9841253235331ae557aa0d5de2552c3a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
@@ -104,7 +104,7 @@ def defined_line
end

def scope
nil
@block_env.scope
end
end

@@ -251,8 +251,10 @@ def for_define_method(name, klass)
be = @block.dup
be.change_name name

code = Rubinius::BlockEnvironment::AsMethod.new(be)
scope = code.block_env.scope
executable = Rubinius::BlockEnvironment::AsMethod.new(be)

code = executable
scope = executable.scope
end

[code, scope]

0 comments on commit d59ca90

Please sign in to comment.