Maintenance Ruby 3.4 gets fixes, but no new features. Switch to Ruby 4.0 →
instance method
Prism::Pattern#compile_constant_path_node
compile_constant_path_node(node)
lib/prism/pattern.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.4.1/lib/prism/pattern.rb, line 148
def compile_constant_path_node(node)
parent = node.parent
if parent.is_a?(ConstantReadNode) && parent.slice == "Prism"
name = node.name
raise CompilationError, node.inspect if name.nil?
compile_constant_name(node, name)
else
compile_error(node)
end
end
See also
#compile_constant_name
#compile_constant_read_node
#compile_array_pattern_node
#compile_error
also in
4.0 · 3.3