Github user cloud-fan commented on a diff in the pull request: https://github.com/apache/spark/pull/21106#discussion_r186706306 --- Diff: sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/Projection.scala --- @@ -108,7 +108,31 @@ abstract class UnsafeProjection extends Projection { override def apply(row: InternalRow): UnsafeRow } -trait UnsafeProjectionCreator { +/** + * The factory object for `UnsafeProjection`. + */ +object UnsafeProjection extends CodegenObjectFactory[Seq[Expression], UnsafeProjection] { --- End diff -- I mean something like ``` abstract class CodegenObjectFactory[IN, OUT] { def mode: CodegenObjectFactoryMode def createObject(in: IN): OUT = { if (mode == ...) ... ... } } ```
--- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org