diff options
| author | Jeroen van Rijn <Kelimion@users.noreply.github.com> | 2021-08-04 00:59:15 +0200 |
|---|---|---|
| committer | Jeroen van Rijn <Kelimion@users.noreply.github.com> | 2021-08-11 20:59:53 +0200 |
| commit | 47397a6a488ad9cae625e531e5236513b81660a0 (patch) | |
| tree | 45a83ca6c041674e9bb432488551ebd8015e0338 /core/math/big/helpers.odin | |
| parent | 2323ca16225066187958a003301be6fd3bc181fe (diff) | |
Add faster divison.
Diffstat (limited to 'core/math/big/helpers.odin')
| -rw-r--r-- | core/math/big/helpers.odin | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/math/big/helpers.odin b/core/math/big/helpers.odin index a326b960b..f0eeea96b 100644 --- a/core/math/big/helpers.odin +++ b/core/math/big/helpers.odin @@ -340,7 +340,7 @@ zero :: clear; Set the `Int` to 1 and optionally shrink it to the minimum backing size. */ int_one :: proc(a: ^Int, minimize := false, allocator := context.allocator) -> (err: Error) { - return copy(a, ONE, minimize, allocator); + return set(a, 1); } one :: proc { int_one, }; @@ -348,7 +348,7 @@ one :: proc { int_one, }; Set the `Int` to -1 and optionally shrink it to the minimum backing size. */ int_minus_one :: proc(a: ^Int, minimize := false, allocator := context.allocator) -> (err: Error) { - return copy(a, MINUS_ONE, minimize, allocator); + return set(a, -1); } minus_one :: proc { int_minus_one, }; |