[ 
https://issues.apache.org/jira/browse/SPARK-10074?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14701332#comment-14701332
 ] 

Ted Yu commented on SPARK-10074:
--------------------------------

I performed the following search in Spark codebase:

find . -name '*.scala' -exec grep 'MutablePair.*Double' {} \; -print

There is only one match:
{code}
case class MutablePair[@specialized(Int, Long, Double, Char, Boolean/* , AnyRef 
*/) T1,
./core/src/main/scala/org/apache/spark/util/MutablePair.scala
{code}
I think adding Float would provide parity with Double, potentially benefiting 
future use.

> Include Float in @specialized annotation
> ----------------------------------------
>
>                 Key: SPARK-10074
>                 URL: https://issues.apache.org/jira/browse/SPARK-10074
>             Project: Spark
>          Issue Type: Improvement
>          Components: Spark Core
>            Reporter: Ted Yu
>            Priority: Minor
>
> There're several places in Spark codebase where we use @specialized 
> annotation covering Long and Double.
> e.g. in OpenHashMap.scala :
> {code}
> class OpenHashMap[K : ClassTag, @specialized(Long, Int, Double) V: ClassTag](
>     initialCapacity: Int)
> {code}
> Float should be added to @specialized annotation as well.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to