You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/05/23 05:55:20 UTC

[GitHub] [arrow-datafusion] jorgecarleitao commented on a change in pull request #392: refactor datafusion/scalar value to use more macro and avoid dup code

jorgecarleitao commented on a change in pull request #392:
URL: https://github.com/apache/arrow-datafusion/pull/392#discussion_r637491918



##########
File path: datafusion/src/scalar.rs
##########
@@ -17,28 +17,29 @@
 
 //! This module provides ScalarValue, an enum that can be used for storage of single elements
 
-use std::{convert::TryFrom, fmt, iter::repeat, sync::Arc};
-
-use arrow::datatypes::{ArrowDictionaryKeyType, DataType, Field, IntervalUnit, TimeUnit};
-use arrow::{
-    array::*,
-    datatypes::{
-        ArrowNativeType, Float32Type, Int16Type, Int32Type, Int64Type, Int8Type,
-        TimestampNanosecondType, UInt16Type, UInt32Type, UInt64Type, UInt8Type,
-    },
-};
+use crate::error::{DataFusionError, Result};
 use arrow::{
     array::{
-        ArrayRef, Int16Builder, Int32Builder, Int64Builder, Int8Builder, ListBuilder,
-        TimestampMicrosecondArray, TimestampMillisecondArray, TimestampNanosecondArray,
-        UInt16Builder, UInt32Builder, UInt64Builder, UInt8Builder,
+        new_null_array, Array, ArrayRef, BinaryArray, BooleanArray, BooleanBuilder,

Review comment:
       maybe at this point it could be more effective to use `use arrow::array::*` and `use arrow::datatypes::*`?
    




-- 
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org