maedhroz commented on code in PR #2935:
URL: https://github.com/apache/cassandra/pull/2935#discussion_r1449249077


##########
src/java/org/apache/cassandra/index/sai/plan/FilterTree.java:
##########
@@ -96,22 +100,56 @@ private boolean localSatisfiedBy(DecoratedKey key, 
Unfiltered unfiltered, Row st
                 if (filter.getIndexTermType().isNonFrozenCollection())
                 {
                     Iterator<ByteBuffer> valueIterator = 
filter.getIndexTermType().valuesOf(row, now);
-                    result = op.apply(result, collectionMatch(valueIterator, 
filter));
+                    result = localOperator.apply(result, 
collectionMatch(valueIterator, filter));
                 }
                 else
                 {
                     ByteBuffer value = filter.getIndexTermType().valueOf(key, 
row, now);
-                    result = op.apply(result, singletonMatch(value, filter));
+                    result = localOperator.apply(result, singletonMatch(value, 
filter));
                 }
 
                 // If the operation is an AND then exit early if we get a 
single false
-                if (op == BooleanOperator.AND && !result)
+                if (localOperator == BooleanOperator.AND && !result)
                     return false;
+
+                // If the operation is an OR then exit early if we get a 
single true

Review Comment:
   Fun thing...it would be "...a union..." because "union" begins w/ a "y" 
sound, but usually "an" when the next word starts w/ a vowel. English is weird.
   
   
https://www.britannica.com/dictionary/eb/qa/how-do-you-know-whether-to-use-a-or-an#:~:text=Use%20a%20when%20the%20noun,the%20pronunciation%2C%20not%20the%20spelling.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to