HHH-18353 ArrayConstructorFunction comparing argument types by reference causes FunctionArgumentException
This commit is contained in:
parent
a5b353b34b
commit
0105dfe57d
|
@ -109,13 +109,13 @@ public class ArrayConstructorFunction extends AbstractSqmSelfRenderingFunctionDe
|
||||||
if ( firstType == null ) {
|
if ( firstType == null ) {
|
||||||
firstType = argumentType;
|
firstType = argumentType;
|
||||||
}
|
}
|
||||||
else if ( firstType != argumentType ) {
|
else if ( firstType.getSingleJdbcMapping() != argumentType.getSingleJdbcMapping() ) {
|
||||||
throw new FunctionArgumentException(
|
throw new FunctionArgumentException(
|
||||||
String.format(
|
String.format(
|
||||||
"All array arguments must have a type compatible to the first argument type [%s], but argument %d has type '%s'",
|
"All array arguments must have a type compatible to the first argument type [%s], but argument %d has type '%s'",
|
||||||
firstType,
|
firstType.getSingleJdbcMapping(),
|
||||||
i + 1,
|
i + 1,
|
||||||
argumentType
|
argumentType.getSingleJdbcMapping()
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue