Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Commit

Permalink
Added an implicit conversion from int--> float to support int operati…
Browse files Browse the repository at this point in the history
…ons in NDArrays. (These ops were already supported in the previous versions)
  • Loading branch information
piyushghai committed Jan 2, 2019
1 parent 996ead1 commit e113a24
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ object MX_PRIMITIVES {

implicit def MX_FloatToFloat(d: MX_FLOAT) : Float = d.data

implicit def IntToMX_Float(d: Int): MX_FLOAT = new MX_FLOAT(d.toFloat)

/**
* Mimics Double in Scala.
* @param data
Expand Down

0 comments on commit e113a24

Please sign in to comment.