From: "mame (Yusuke Endoh) via ruby-core" Date: 2026-03-16T06:33:00+00:00 Subject: [ruby-core:125010] [Ruby Bug#21934] Prism and parse.y inconsistency in command call used with pattern match Issue #21934 has been updated by mame (Yusuke Endoh). @kddnewton @tompng Can we close this ticket? ---------------------------------------- Bug #21934: Prism and parse.y inconsistency in command call used with pattern match https://bugs.ruby-lang.org/issues/21934#change-116705 * Author: tompng (tomoya ishida) * Status: Open * ruby -v: ruby 4.1.0dev (2026-03-03T16:19:28Z master e30b5a06dc) +PRISM [x86_64-linux] * Backport: 3.2: UNKNOWN, 3.3: UNKNOWN, 3.4: UNKNOWN, 4.0: UNKNOWN ---------------------------------------- These are syntax error in both parse.y and in Prism ~~~ruby a x in pattern a x: in pattern a &x in pattern a *x => pattern a x: => pattern a &x => pattern ~~~ These are all syntax error in parse.y, all syntax valid in Prism ~~~ruby a.b x in pattern a.b x: in pattern a.b &x in pattern a.b *x => pattern a.b x: => pattern a.b &x => pattern ~~~ I think this is related to https://github.com/ruby/prism/issues/3558, `A.print message:\nin 'BAR'` inside case-in was parsed as `(A.print message:) in 'BAR'`. -- https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.ruby-lang.org/