From 2363ae93a026845211a0463fb52c2a1d29d7501f Mon Sep 17 00:00:00 2001 From: dbaumgarten Date: Sat, 6 Nov 2021 18:13:45 +0100 Subject: [PATCH] Allow modulus with numbers >-1 <1 --- acid-tests | 2 +- pkg/number/number.go | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/acid-tests b/acid-tests index 0c31959..cd62f6e 160000 --- a/acid-tests +++ b/acid-tests @@ -1 +1 @@ -Subproject commit 0c3195909c82ffe7ca474409c26e6224de448060 +Subproject commit cd62f6e3262c6d214bb7eb23ce81b6af53ec18f7 diff --git a/pkg/number/number.go b/pkg/number/number.go index cf7248d..1273725 100644 --- a/pkg/number/number.go +++ b/pkg/number/number.go @@ -167,9 +167,6 @@ func (n Number) Mod(m Number) (Number, error) { if m == Zero { return Zero, fmt.Errorf("Division by 0") } - if m < One && m > MinusOne { - return Zero, fmt.Errorf("The ingame-implementation thinks this is a division by 0") - } return n % m, nil }