Skip to content

Commit bfbd48c

Browse files
author
elasticsearchmachine
committed
[CI] Auto commit changes from spotless
1 parent e3a5a98 commit bfbd48c

File tree

1 file changed

+19
-19
lines changed
  • x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/expression/function/scalar/math

1 file changed

+19
-19
lines changed

x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/expression/function/scalar/math/CopySign.java

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
import org.elasticsearch.xpack.esql.EsqlIllegalArgumentException;
1616
import org.elasticsearch.xpack.esql.core.expression.Expression;
1717
import org.elasticsearch.xpack.esql.core.expression.Expressions;
18-
import org.elasticsearch.xpack.esql.core.expression.TypeResolutions;
1918
import org.elasticsearch.xpack.esql.core.tree.NodeInfo;
2019
import org.elasticsearch.xpack.esql.core.tree.Source;
2120
import org.elasticsearch.xpack.esql.core.type.DataType;
@@ -129,24 +128,24 @@ public TypeResolution resolveType() {
129128
return new TypeResolution("Sign must be a numeric type");
130129
}
131130
dataType = EsqlDataTypeConverter.commonType(magnitude.dataType(), sign.dataType());
132-
// TypeResolution resolution = TypeResolutions.isType(
133-
// magnitude,
134-
// t -> t == commonType,
135-
// sourceText(),
136-
// TypeResolutions.ParamOrdinal.fromIndex(1),
137-
// magnitude.dataType().typeName()
138-
// );
139-
// if (resolution.unresolved()) {
140-
// throw new EsqlIllegalArgumentException(
141-
// "Magnitude [{}] is not compatible with sign [{}] for function [{}] - common type is [{}]",
142-
// magnitude.dataType(),
143-
// sign.dataType(),
144-
// NAME
145-
// ,commonType
146-
// );
147-
//// return resolution;
148-
// }
149-
// dataType = commonType;
131+
// TypeResolution resolution = TypeResolutions.isType(
132+
// magnitude,
133+
// t -> t == commonType,
134+
// sourceText(),
135+
// TypeResolutions.ParamOrdinal.fromIndex(1),
136+
// magnitude.dataType().typeName()
137+
// );
138+
// if (resolution.unresolved()) {
139+
// throw new EsqlIllegalArgumentException(
140+
// "Magnitude [{}] is not compatible with sign [{}] for function [{}] - common type is [{}]",
141+
// magnitude.dataType(),
142+
// sign.dataType(),
143+
// NAME
144+
// ,commonType
145+
// );
146+
//// return resolution;
147+
// }
148+
// dataType = commonType;
150149
return TypeResolution.TYPE_RESOLVED;
151150
}
152151

@@ -184,6 +183,7 @@ static long processLong(long magnitude, long sign) {
184183
return Math.abs(magnitude);
185184
}
186185
}
186+
187187
@Evaluator(extraName = "Integer")
188188
static int processInteger(int magnitude, int sign) {
189189
if (sign < 0) {

0 commit comments

Comments
 (0)