-
Notifications
You must be signed in to change notification settings - Fork 142
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
[20] Switch statement with record pattern illegally reported as non-exhaustive #1224
Comments
Since this is still a preview feature in 20 and a standard feature in 21, I would rather we fix this for 21 directly. Copying @mpalat |
jarthana
added a commit
to jarthana/eclipse.jdt.core
that referenced
this issue
Jul 12, 2023
This was referenced Jul 12, 2023
jarthana
added a commit
to jarthana/eclipse.jdt.core
that referenced
this issue
Jul 12, 2023
jarthana
added a commit
to jarthana/eclipse.jdt.core
that referenced
this issue
Jul 14, 2023
jarthana
added a commit
to jarthana/eclipse.jdt.core
that referenced
this issue
Jul 14, 2023
jarthana
added a commit
to jarthana/eclipse.jdt.core
that referenced
this issue
Jul 18, 2023
jarthana
added a commit
to jarthana/eclipse.jdt.core
that referenced
this issue
Jul 18, 2023
robstryker
pushed a commit
to robstryker/eclipse.jdt.core
that referenced
this issue
Jul 18, 2024
…xhaustive (eclipse-jdt#1228) Fixed issue eclipse-jdt#1224 Now, a total record pattern, which from now on called as a pattern that covers the expression type, can be mixed with an optional default case. The absence of such default should now be allowed.
datho7561
added a commit
to datho7561/eclipse.jdt.core
that referenced
this issue
Feb 6, 2025
Fixes eclipse-jdt#1224 Signed-off-by: David Thompson <davthomp@redhat.com>
datho7561
added a commit
to datho7561/eclipse.jdt.core
that referenced
this issue
Feb 7, 2025
Fixes eclipse-jdt#1224 Signed-off-by: David Thompson <davthomp@redhat.com>
mickaelistria
pushed a commit
to mickaelistria/eclipse.jdt.core
that referenced
this issue
Feb 7, 2025
Fixes eclipse-jdt#1224 Signed-off-by: David Thompson <davthomp@redhat.com>
robstryker
pushed a commit
to robstryker/eclipse.jdt.core
that referenced
this issue
Feb 7, 2025
Fixes eclipse-jdt#1224 Signed-off-by: David Thompson <davthomp@redhat.com>
robstryker
pushed a commit
to robstryker/eclipse.jdt.core
that referenced
this issue
Feb 7, 2025
Fixes eclipse-jdt#1224 Signed-off-by: David Thompson <davthomp@redhat.com>
mickaelistria
pushed a commit
to mickaelistria/eclipse.jdt.core
that referenced
this issue
Feb 10, 2025
Fixes eclipse-jdt#1224 Signed-off-by: David Thompson <davthomp@redhat.com>
mickaelistria
pushed a commit
to mickaelistria/eclipse.jdt.core
that referenced
this issue
Feb 10, 2025
Fixes eclipse-jdt#1224 Signed-off-by: David Thompson <davthomp@redhat.com>
robstryker
pushed a commit
to robstryker/eclipse.jdt.core
that referenced
this issue
Feb 13, 2025
Fixes eclipse-jdt#1224 Signed-off-by: David Thompson <davthomp@redhat.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The switch in the following code is rejected by ECJ as not exhaustive:
This is because, as per RecordPattern#isTotalForType() , it is considered to be always false. This method needs consider the record pattern's type as well as the nested patterns' types.
The text was updated successfully, but these errors were encountered: