Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ class CodegenContext extends Logging {
case udt: UserDefinedType[_] => genEqual(udt.sqlType, c1, c2)
case NullType => "false"
case _ =>
throw QueryExecutionErrors.cannotGenerateCodeForUncomparableTypeError(
throw QueryExecutionErrors.cannotGenerateCodeForIncomparableTypeError(
"equality", dataType)
}

Expand Down Expand Up @@ -719,7 +719,7 @@ class CodegenContext extends Logging {
case other if other.isInstanceOf[AtomicType] => s"$c1.compare($c2)"
case udt: UserDefinedType[_] => genComp(udt.sqlType, c1, c2)
case _ =>
throw QueryExecutionErrors.cannotGenerateCodeForUncomparableTypeError("compare", dataType)
throw QueryExecutionErrors.cannotGenerateCodeForIncomparableTypeError("compare", dataType)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't revert this, but, this is very pedantically techincally incorrect. "Incomparable" means "without peer, the best". "Uncomparable" isn't a word really, but, probably more accurate. Whatev

}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -369,10 +369,10 @@ private[sql] object QueryExecutionErrors extends QueryErrorsBase {
new IllegalArgumentException(s"$funcName is not matched at addNewFunction")
}

def cannotGenerateCodeForUncomparableTypeError(
def cannotGenerateCodeForIncomparableTypeError(
codeType: String, dataType: DataType): Throwable = {
new IllegalArgumentException(
s"cannot generate $codeType code for un-comparable type: ${dataType.catalogString}")
s"Cannot generate $codeType code for incomparable type: ${dataType.catalogString}")
}

def cannotGenerateCodeForUnsupportedTypeError(dataType: DataType): Throwable = {
Expand Down