Folyd commented on code in PR #4420:
URL: https://github.com/apache/arrow-rs/pull/4420#discussion_r1232432307
##########
arrow-json/src/reader/schema.rs:
##########
@@ -442,7 +442,9 @@ fn collect_field_types_from_object(
// inferring
}
Value::Number(n) => {
- if n.is_i64() {
+ if n.is_u64() {
+ set_object_scalar_field_type(field_types, k,
DataType::UInt64)?;
+ } else if n.is_i64() {
set_object_scalar_field_type(field_types, k,
DataType::Int64)?;
Review Comment:
Yes, I prefer the unsigned one since `u64` has a wider positive-integer
range than `i64`. If the number is negative, we treat it as an `i64`. This is a
breaking change, would be allowed if we release the next major version?
--
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]