Community
Participate
Working Groups
While working on Bug 573947, Tried with the snippet: private static void foo4(Object o) { switch (o) { case Integer i && i > 10 : System.out.println("Greater than 10"+ i ); case null, default : System.out.println(o.toString() ); } } When evaluating - case Integer i && i > 10, it gives error Syntax error on token "&&", = expected.
Expect the changes in org.eclipse.jdt.internal.debug.eval.ast.engine.SourceBasedSourceGenerator.
This is a big change and will avoid delivering so close to the Java 17 GA.
New Gerrit change created: https://git.eclipse.org/r/c/jdt/eclipse.jdt.debug/+/186790
(In reply to Eclipse Genie from comment #3) > New Gerrit change created: > https://git.eclipse.org/r/c/jdt/eclipse.jdt.debug/+/186790 Even after setting the latest compliance and preview enabled option, Parser is still throwing the same error. I verified that Parser is getting the correct compliance and preview enabled options.
Created attachment 288284 [details] Patch for gerrit
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.