Github user rxin commented on a diff in the pull request:
https://github.com/apache/spark/pull/5651#discussion_r28941734
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/codegen/CodeGenerator.scala
---
@@ -675,7 +676,18 @@ abstract class CodeGenerator[InType <: AnyRef, OutType
<: AnyRef] extends Loggin
}
protected def termForType(dt: DataType) = dt match {
- case n: NativeType => n.tag
+ case n: AtomicType => n.tag
case _ => typeTag[Any]
}
+
+ /**
+ * List of data types that have special accessors and setters in [[Row]].
+ */
+ protected val nativeTypes =
+ Seq(IntegerType, BooleanType, LongType, DoubleType, FloatType,
ShortType, ByteType, StringType)
+
+ /**
+ * Returns true if the data type has a special accessor and setter in
[[Row]].
+ */
+ protected def isNativeType(dt: DataType) = nativeTypes.contains(dt)
--- End diff --
this is specific in codegenerator, which i don't care as much.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]