summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEarlopain <14981592+Earlopain@users.noreply.github.com>2025-09-14 11:43:34 +0200
committerKevin Newton <kddnewton@gmail.com>2025-09-15 11:10:34 -0400
commitb08573c8150c97822b05b743d5ebb8c4fff5315f (patch)
treeccecba24370cd9ac9881ca55b6daa70aa2368c5d
parent6c34880111a0978407224fc353c35f2a3a0a981a (diff)
[ruby/prism] Fix back reference for ruby_parser on Ruby 2.7
Symbol#name is only a thing since Ruby 3.0 https://github.com/ruby/prism/commit/2de82b15fc
-rw-r--r--lib/prism/translation/ruby_parser.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/prism/translation/ruby_parser.rb b/lib/prism/translation/ruby_parser.rb
index ac538a2e97..2ca7da0bf2 100644
--- a/lib/prism/translation/ruby_parser.rb
+++ b/lib/prism/translation/ruby_parser.rb
@@ -152,7 +152,7 @@ module Prism
# ^^
# ```
def visit_back_reference_read_node(node)
- s(node, :back_ref, node.name.name.delete_prefix("$").to_sym)
+ s(node, :back_ref, node.name.to_s.delete_prefix("$").to_sym)
end
# ```