Skip to content

Fix incorrectly renaming pattern match variables#555

Merged
jaskarth merged 3 commits intoVineflower:develop/1.12.0from
coehlrich:fix-pattern-matching-renames
Mar 29, 2026
Merged

Fix incorrectly renaming pattern match variables#555
jaskarth merged 3 commits intoVineflower:develop/1.12.0from
coehlrich:fix-pattern-matching-renames

Conversation

@coehlrich
Copy link
Copy Markdown
Contributor

No description provided.

@jaskarth jaskarth added Priority: Medium Medium priority Subsystem: Variables Anything concerning variables, types, assignments, and casting bugfix Fixes a bug labels Mar 28, 2026
Copy link
Copy Markdown
Member

@jaskarth jaskarth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this work! The patch itself looks fine, but I would like to see some new tests to exercise the logic that's added for pattern matches, ternaries, and loops.

iterate = false;
// https://docs.oracle.com/javase/specs/jls/se25/html/jls-6.html#jls-6.3.1
switch (function.getFuncType()) {
case BOOLEAN_AND -> {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the VF codestyle, case statements are indented by 1.

Copy link
Copy Markdown
Member

@jaskarth jaskarth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the update!

@jaskarth jaskarth merged commit 960c98a into Vineflower:develop/1.12.0 Mar 29, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix Fixes a bug Priority: Medium Medium priority Subsystem: Variables Anything concerning variables, types, assignments, and casting

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants