Skip to content

Commit

Permalink
Robust tests for Long. (#143)
Browse files Browse the repository at this point in the history
* Robust tests for `Long`.
* Implemented `Debug` for `Long`.
* `Long::from`: check argument before construction.
* Fixed arbitrary-precision addition!
  * In the previous version, there was a logical error in the implementation of addition.
  * If `self` had more digits than `other`, the carry (if there was one) would not be added to the next digit of `self`.
  * It would be placed to the front of `self`.
  • Loading branch information
tfpf authored Feb 23, 2024
1 parent e62e16c commit d8bcd09
Show file tree
Hide file tree
Showing 2 changed files with 1,056 additions and 22 deletions.
Loading

0 comments on commit d8bcd09

Please sign in to comment.