Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply Java migration: pattern variables #3750

Merged
merged 1 commit into from
Oct 24, 2023
Merged

Conversation

Baltoli
Copy link
Contributor

@Baltoli Baltoli commented Oct 24, 2023

This is a fully-mechanical PR that uses IntelliJ to migrate to using the new Java feature for pattern variables in instanceof checks. For example, this code:

            if (left instanceof KApply) {
                KApply kapp = (KApply) left;
                Production prod = production(kapp);

becomes:

            if (left instanceof KApply kapp) {
                Production prod = production(kapp);

which saves a lot of boilerplate code.

There are no manual changes or decisions in this PR; it's push-button only.

@Baltoli Baltoli force-pushed the java-pattern-variable branch from e9f1eae to 7c5ab18 Compare October 24, 2023 14:46
@Baltoli Baltoli marked this pull request as ready for review October 24, 2023 14:49
@rv-jenkins rv-jenkins merged commit 227b989 into develop Oct 24, 2023
10 of 16 checks passed
@rv-jenkins rv-jenkins deleted the java-pattern-variable branch October 24, 2023 15:26
@Baltoli Baltoli mentioned this pull request Dec 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants