diff --git a/core/src/main/scala-3/spire/std/double.scala b/core/src/main/scala-3/spire/std/double.scala index 1845bec4b..ec61f2ba1 100644 --- a/core/src/main/scala-3/spire/std/double.scala +++ b/core/src/main/scala-3/spire/std/double.scala @@ -31,9 +31,9 @@ trait DoubleIsField extends Field[Double] { override inline def times(a: Double, b: Double): Double = a * b inline def zero: Double = 0.0 - override inline def fromInt(n: Int): Double = n.toDouble + override def fromInt(n: Int): Double = n - override inline def fromDouble(n: Double): Double = n + override def fromDouble(n: Double): Double = n inline def div(a: Double, b: Double): Double = a / b } diff --git a/core/src/main/scala/spire/math/Numeric.scala b/core/src/main/scala/spire/math/Numeric.scala index 297652ea3..7928aaad0 100644 --- a/core/src/main/scala/spire/math/Numeric.scala +++ b/core/src/main/scala/spire/math/Numeric.scala @@ -185,6 +185,8 @@ private[math] class DoubleIsNumeric with ConvertableToDouble with DoubleIsReal with Serializable { + override def fromInt(n: Int): Double = n + override def fromDouble(n: Double): Double = n override def fromBigInt(n: BigInt): Double = n.toDouble override def toDouble(n: Double): Double = n.toDouble override def toRational(n: Double): Rational = super[DoubleIsReal].toRational(n)