@@ -1256,31 +1256,29 @@ protected Expression rule(Or or) {
12561256 if (found .isEmpty () == false ) {
12571257 // combine Equals alongside the existing ORs
12581258 final ZoneId finalZoneId = zoneId ;
1259- found .forEach (
1260- (k , v ) -> {
1261- if (v .size () == 1 ) {
1262- ors .add (createEquals (k , v .iterator ().next (), finalZoneId ));
1263- } else {
1264- In in = createIn (k , new ArrayList <>(v ), finalZoneId );
1265- // IN has its own particularities when it comes to type resolution and not all implementations
1266- // double check the validity of an internally created IN (like the one created here). EQL is one where the IN
1267- // implementation is like this mechanism here has been specifically created for it
1268- if (shouldValidateIn ()) {
1269- Expression .TypeResolution resolution = in .validateInTypes ();
1270- if (resolution .unresolved ()) {
1271- // if the internally created In is not valid, fall back to the original ORs
1272- assert originalOrs .containsKey (k );
1273- assert originalOrs .get (k ).isEmpty () == false ;
1274- ors .add (combineOr (originalOrs .get (k )));
1275- } else {
1276- ors .add (in );
1277- }
1259+ found .forEach ((k , v ) -> {
1260+ if (v .size () == 1 ) {
1261+ ors .add (createEquals (k , v .iterator ().next (), finalZoneId ));
1262+ } else {
1263+ In in = createIn (k , new ArrayList <>(v ), finalZoneId );
1264+ // IN has its own particularities when it comes to type resolution and not all implementations
1265+ // double check the validity of an internally created IN (like the one created here). EQL is one where the IN
1266+ // implementation is like this mechanism here has been specifically created for it
1267+ if (shouldValidateIn ()) {
1268+ Expression .TypeResolution resolution = in .validateInTypes ();
1269+ if (resolution .unresolved ()) {
1270+ // if the internally created In is not valid, fall back to the original ORs
1271+ assert originalOrs .containsKey (k );
1272+ assert originalOrs .get (k ).isEmpty () == false ;
1273+ ors .add (combineOr (originalOrs .get (k )));
12781274 } else {
12791275 ors .add (in );
12801276 }
1277+ } else {
1278+ ors .add (in );
12811279 }
12821280 }
1283- );
1281+ } );
12841282
12851283 Expression combineOr = combineOr (ors );
12861284 // check the result semantically since the result might different in order
0 commit comments