Skip to content

Commit

Permalink
Allow modulus with numbers >-1 <1
Browse files Browse the repository at this point in the history
  • Loading branch information
dbaumgarten committed Nov 6, 2021
1 parent e38deb4 commit 2363ae9
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
2 changes: 1 addition & 1 deletion acid-tests
3 changes: 0 additions & 3 deletions pkg/number/number.go
Original file line number Diff line number Diff line change
Expand Up @@ -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
}

Expand Down

0 comments on commit 2363ae9

Please sign in to comment.