[
https://issues.apache.org/jira/browse/ARROW-14731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17451464#comment-17451464
]
Weston Pace commented on ARROW-14731:
-------------------------------------
Can this be closed? [~baksmj]
> [C++][Compute] Conversion to unsigned types can be problematic for negative
> numbers
> -----------------------------------------------------------------------------------
>
> Key: ARROW-14731
> URL: https://issues.apache.org/jira/browse/ARROW-14731
> Project: Apache Arrow
> Issue Type: Bug
> Components: C++
> Reporter: Benson Muite
> Assignee: Benson Muite
> Priority: Minor
> Labels: pull-request-available
> Time Spent: 2h
> Remaining Estimate: 0h
>
> On line 248 of
> https://github.com/apache/arrow/blob/master/cpp/src/arrow/compute/kernels/scalar_arithmetic.cc
> int16 type is converted to uint32 type because overflows are better handled
> in uint32 than in int32 This will be problematic if some of the numbers are
> negative. It may be better to use th default int32 and explicitly check for
> overflows if needed.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)