class Prism::Translation::Parser::Compiler

def visit_when_node(node)

^^^^^^^^^^^^^
case foo; when bar; end
def visit_when_node(node)
  builder.when(
    token(node.keyword_loc),
    visit_all(node.conditions),
    srange_find(node.conditions.last.location.end_offset, node.statements&.location&.start_offset || (node.conditions.last.location.end_offset + 1), [";", "then"]),
    visit(node.statements)
  )
end