vlsi commented on code in PR #5281:
URL: https://github.com/apache/calcite/pull/5281#discussion_r4079670258
##########
core/src/main/java/org/apache/calcite/sql/type/BasicSqlType.java:
##########
@@ -156,6 +157,9 @@ public BasicSqlType createWithNullability(boolean nullable)
{
BasicSqlType createWithCharsetAndCollation(Charset charset,
SqlCollation collation) {
checkArgument(SqlTypeUtil.inCharFamily(this));
+ if (collation == this.collation && Objects.equals(charset, getCharset())) {
Review Comment:
Note: it might be we should add something like
`SqlCollation#isSameAs(SqlCollation)` so we compare the collation instead of
"identity only" or add coercibility to equals/hashCode. Both changes require
analysis.
--
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]