hermanschaaf commented on issue #34657: URL: https://github.com/apache/arrow/issues/34657#issuecomment-1490116306
I'd like to add my two cents here: I've been looking at implementing `array.Diff` functionality for https://github.com/apache/arrow/issues/34790. To implement this, we need to compare values in the arrays. Right now the way to go would be to use `scalar.GetScalar`, but unfortunately because the `scalar.GetScalar` imports the `array` package, we cannot use it from `array` due to circular imports. This problem could be avoided if the `GetScalar(arr array.Array, i int)` function, and other scalar functions that deal with arrays, were placed inside the `array` package instead. So we'd have `array.GetScalar`, `array.MakeFromScalar`, etc. This also makes sense to me from a semantic point of view, since scalars are smaller building blocks for arrays, the imports should go from array -> scalar and not the other way round. -- 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]
