Skip to content

Commit c6594b2

Browse files
committed
using boxed
1 parent 7b7e6e3 commit c6594b2

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/SpecificMutableRow.scala

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -307,14 +307,7 @@ final class SpecificMutableRow(val values: Array[MutableValue]) extends MutableR
307307
values(i).asInstanceOf[MutableByte].value
308308
}
309309

310-
override def getAs[T](i: Int): T = values(i) match {
311-
case r: MutableInt => r.value.asInstanceOf[T]
312-
case r: MutableByte => r.value.asInstanceOf[T]
313-
case r: MutableFloat => r.value.asInstanceOf[T]
314-
case r: MutableShort => r.value.asInstanceOf[T]
315-
case r: MutableDouble => r.value.asInstanceOf[T]
316-
case r: MutableBoolean => r.value.asInstanceOf[T]
317-
case r: MutableLong => r.value.asInstanceOf[T]
318-
case r: MutableAny => r.value.asInstanceOf[T]
310+
override def getAs[T](i: Int): T = {
311+
values(i).boxed.asInstanceOf[T]
319312
}
320313
}

0 commit comments

Comments
 (0)