Commit Graph
12 Commits
Author SHA1 Message Date
Stephen Canon c124585c19 Skeleton of integer shift with rounding.
Fairly correct implementation of right-shift with rounding. Also fairly efficient, though I'm sure I'll find some cases where we're generating uncessary overflow checks upon further inspection. Nonetheless, a decent enough start.
2021-09-26 16:23:58 -04:00
Stephen Canon e22ff866a4 Add GCD files to CMake build. 2021-09-20 12:35:22 -04:00
Stephen Canon abb899865e resolve warnings in 5.5 tools build, add skeleton readme for integer utilities 2021-09-20 09:53:38 -04:00
Stephen Canon 9d84cefefa Merge pull request #189 from NevinBR/patch-6
GCD function for BinaryInteger
2021-09-10 11:04:07 -04:00
NevinBR 85264c808c Reworded doc comment for gcd 2021-09-09 23:05:45 -04:00
NevinBR 8552becf91 Documented overflow behavior of gcd 2021-08-31 11:19:22 -04:00
NevinBR 67af2fe0d9 Simplified gcd implementation 2021-08-30 17:32:03 -04:00
NevinBR b8f452189b Made gcd a free function 2021-08-30 17:28:44 -04:00
NevinBR 4fbcb11f03 Improved GCD documentation 2021-08-26 19:49:13 -04:00
Stephen Canon 996cf7f5b9 CMake build support for the IntegerUtilities module. 2021-08-26 15:18:40 -04:00
NevinBR 909a77c3d9 Create GCD.swift
Binary GCD algorithm
2021-08-26 14:51:05 -04:00
Stephen Canon 84474a3410 Initial setup of IntegerUtilities module.
Seeded with rotate(right:) and rotate(left:) on FixedWidthInteger. These implementations are basically sane, but need documentation written for users who are not already familiar with bitwise rotation.
2021-08-25 15:36:24 -04:00