Github user davies commented on a diff in the pull request:
https://github.com/apache/spark/pull/6479#discussion_r31691377
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/codegen/CodeGenerator.scala
---
@@ -651,41 +677,58 @@ abstract class CodeGenerator[InType <: AnyRef,
OutType <: AnyRef] extends Loggin
sys.error(s"Code generation not support for hashset of type
$unsupportedType")
}
- protected def primitiveForType(dt: DataType) = dt match {
- case IntegerType => "Int"
+ protected def primitiveForType(dt: DataType): String = dt match {
+ case IntegerType => "int"
+ case LongType => "long"
+ case ShortType => "short"
+ case ByteType => "byte"
+ case DoubleType => "double"
+ case FloatType => "float"
+ case BooleanType => "boolean"
+ case dt @ DecimalType() => "org.apache.spark.sql.types.Decimal"
--- End diff --
I think it's the same, see DecimalType.unapply()
---
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]