Fix insignificant ubsan error in QueryAnalyzer::replaceNodesWithPositionalArguments()

This commit is contained in:
Michael Kolupaev 2024-05-14 08:37:25 +00:00
parent 0fd52c36c6
commit 710ceae903

View File

@ -2329,7 +2329,7 @@ void QueryAnalyzer::replaceNodesWithPositionalArguments(QueryTreeNodePtr & node_
pos = value;
else
{
if (static_cast<size_t>(std::abs(value)) > projection_nodes.size())
if (value < -static_cast<Int64>(projection_nodes.size()))
throw Exception(
ErrorCodes::BAD_ARGUMENTS,
"Negative positional argument number {} is out of bounds. Expected in range [-{}, -1]. In scope {}",