129 130 131 132 133 134 135 136
# File 'lib/duby/ast.rb', line 129 def scope @scope ||= begin scope = parent raise "No parent for #{self.class.name} at #{line_number}" if scope.nil? scope = scope.parent until scope.class.include?(Scope) scope end end