From 520765abb9d296401d47570a96cb67fa1ae4ac8c Mon Sep 17 00:00:00 2001 From: Alexander Nozik Date: Sat, 25 Aug 2018 21:18:17 +0300 Subject: [PATCH] The same for minus --- .../src/main/kotlin/scientifik/kmath/operations/Algebra.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kmath-common/src/main/kotlin/scientifik/kmath/operations/Algebra.kt b/kmath-common/src/main/kotlin/scientifik/kmath/operations/Algebra.kt index 4613dda7c..9938f4856 100644 --- a/kmath-common/src/main/kotlin/scientifik/kmath/operations/Algebra.kt +++ b/kmath-common/src/main/kotlin/scientifik/kmath/operations/Algebra.kt @@ -104,6 +104,9 @@ interface Field : Ring { operator fun T.plus(b: Number) = this.plus(b * one) operator fun Number.plus(b: T) = b + this + + operator fun T.minus(b: Number) = this.minus(b * one) + operator fun Number.minus(b: T) = -b + this } /**