Closed
Description
Hey there!
I noticed the following behaviour, when using rightward assignment =>
inside a case ... when
:
puts SyntaxTree.format <<~RUBY
case [0]
when 0
{ a: 0 } => { a: }
puts a
end
RUBY
produces:
[0] =>
when 0
case { a: 0 }
a:
end
puts a
It seems like the rightward assignment is moved to the top... producing an invalid ruby syntax.
Do you know where this may come from?
Regards,
Metadata
Metadata
Assignees
Labels
No labels