uros-db commented on code in PR #45421:
URL: https://github.com/apache/spark/pull/45421#discussion_r1519379776


##########
common/unsafe/src/main/java/org/apache/spark/unsafe/types/UTF8String.java:
##########
@@ -396,7 +389,18 @@ public boolean startsWith(final UTF8String prefix, int 
collationId) {
     if (collationId == CollationFactory.LOWERCASE_COLLATION_ID) {
       return this.toLowerCase().startsWith(prefix.toLowerCase());
     }
-    return matchAt(prefix, 0, collationId);
+    return collatedStartsWith(prefix, collationId);
+  }
+
+  private boolean collatedStartsWith(final UTF8String prefix, int collationId) 
{

Review Comment:
   I think we test these functions only in CollationSuite now, as they are only 
used in context of collations anyways. To remove clutter, we opted to remove 
unit tests from `UTF8StringSuite` and `StringExpressionSuite` because those in 
`CollationSuite` seem to do just fine



-- 
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