Skip to content

Fixes #7855. pattern assoc assigns should scope#7857

Merged
enebo merged 2 commits intojruby:masterfrom
enebo:fix_7855
Jul 14, 2023
Merged

Fixes #7855. pattern assoc assigns should scope#7857
enebo merged 2 commits intojruby:masterfrom
enebo:fix_7855

Conversation

@enebo
Copy link
Member

@enebo enebo commented Jul 14, 2023

assoc assigns in pattern matching was erroneously always creating
a new local variable in the current lexical scope vs looking for
it already existing in a higher scope.

enebo added 2 commits July 14, 2023 14:28
Any bound variables will scope to existing variables rather
than making a new variable within the pattern matching lexical
scope.
assoc assigns in pattern matching was erroneously always creating
a new local variable in the current lexical scope vs looking for
it already existing in a higher scope.
@enebo enebo added this to the JRuby 9.4.4.0 milestone Jul 14, 2023
@enebo enebo merged commit c0de12d into jruby:master Jul 14, 2023
@enebo enebo deleted the fix_7855 branch July 14, 2023 19:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant