dongjoon-hyun commented on a change in pull request #742:
URL: https://github.com/apache/orc/pull/742#discussion_r684719673
##########
File path: java/core/src/java/org/apache/orc/impl/ConvertTreeReaderFactory.java
##########
@@ -1239,18 +1241,21 @@ static Instant timestampToInstant(TimestampColumnVector
vector, int element) {
* Convert a decimal to an Instant using seconds & nanos.
* @param vector the decimal64 column vector
* @param element the element number to use
+ * @param reuse the writable container to reuse
* @return the timestamp instant
*/
- static Instant decimalToInstant(DecimalColumnVector vector, int element) {
- // copy the value so that we can mutate it
- HiveDecimalWritable value = new
HiveDecimalWritable(vector.vector[element]);
- long seconds = value.longValue();
+ static Instant decimalToInstant(DecimalColumnVector vector, int element,
HiveDecimalWritable reuse) {
+ final HiveDecimalWritable writable = vector.vector[element];
Review comment:
Could you keep the original name, `value`, instead of this new name
`writable`?
--
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]