From f4c8cd82086a24527e60dd292624c506b4455638 Mon Sep 17 00:00:00 2001 From: Nao Pross Date: Sun, 10 Mar 2024 22:43:20 +0100 Subject: Fix PolyRingExpr.__neg__ --- mdpoly/algebra.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mdpoly/algebra.py b/mdpoly/algebra.py index 1e4b775..1fbabda 100644 --- a/mdpoly/algebra.py +++ b/mdpoly/algebra.py @@ -168,7 +168,8 @@ class PolyRingExpr(Expr): return PolyAdd(other, self) def __neg__(self): - return PolyMul(self._constant(-1), self) + # FIXME: Create PolyNeg? + return PolyMul(PolyConst(-1), self) def __mul__(self, other): self._assert_same_algebra(self, other) -- cgit v1.2.1