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

The WrongOneOf check also fails with the new arrow-type switch expressions #2393

Open
jsannemo opened this issue Jun 12, 2021 · 0 comments · Fixed by openamiguel/error-prone#1

Comments

@jsannemo
Copy link

jsannemo commented Jun 12, 2021

ATTENTION! Please read and follow:

Description of the problem / feature request:

The WrongOneOf check also fails with the new arrow-type switch expressions.

Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

switch (proto.oneOfCase()) {
  case BLAH -> {...};
  default -> {...};
}

What version of Error Prone are you using?

2.6.0

Have you found anything relevant by searching the web?

Same fix required as #2371 and #2124 here

copybara-service bot pushed a commit that referenced this issue Aug 12, 2021
Fix for Issue #2393 (WrongOneof mishandles new style switch statement) based on PR #2371 and PR #2124.

Fixes #2470

COPYBARA_INTEGRATE_REVIEW=#2470 from openamiguel:master 148cf4d
PiperOrigin-RevId: 390456921
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 a pull request may close this issue.

1 participant