himadripal commented on code in PR #7021:
URL: https://github.com/apache/arrow-rs/pull/7021#discussion_r1950402313
##########
arrow-cast/src/cast/decimal.rs:
##########
@@ -99,10 +100,24 @@ where
I::Native: DecimalCast + ArrowNativeTypeOp,
O::Native: DecimalCast + ArrowNativeTypeOp,
{
+ validate_decimal_precision_and_scale::<O>(output_precision, output_scale)?;
Review Comment:
Having the validation inside `is_infallible_cast` branch, sounds like a good
idea, but that would mean then all 3 branches will have validation now. Is the
performance benchmark is still better than previous code?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]