We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a8dbad9 commit b2fb226Copy full SHA for b2fb226
cpp/src/arrow/compute/kernels/scalar_if_else.cc
@@ -1459,12 +1459,9 @@ struct CaseWhenFunction : ScalarFunction {
1459
DCHECK(std::all_of(types.begin() + 1, types.end(), [](const TypeHolder& type) {
1460
return is_decimal(type.id());
1461
}));
1462
- const auto& ty1 = checked_cast<const DecimalType&>(*types[1].type);
1463
return std::all_of(
1464
- types.begin() + 2, types.end(), [&ty1](const TypeHolder& type) {
1465
- const auto& ty = checked_cast<const DecimalType&>(*type.type);
1466
- return ty1.Equals(ty);
1467
- });
+ types.begin() + 2, types.end(),
+ [&types](const TypeHolder& type) { return type == types[1]; });
1468
});
1469
return constraint;
1470
}
0 commit comments