instance method
Prism::Translation::Parser::Compiler#visit_singleton_class_node
visit_singleton_class_node(node)
lib/prism/translation/parser/compiler.rb
View on GitHub ↗
# File tmp/rubies/ruby-4.0.0/lib/prism/translation/parser/compiler.rb, line 1658
def visit_singleton_class_node(node)
builder.def_sclass(
token(node.class_keyword_loc),
token(node.operator_loc),
visit(node.expression),
node.body&.accept(copy_compiler(forwarding: [])),
token(node.end_keyword_loc)
)
end
class << self; end ^^^^^^^^^^^^^^^^^^