Skip to content

v0.8.0

Compare
Choose a tag to compare
@oscbyspro oscbyspro released this 06 Aug 08:59
· 540 commits to main since this release

Some additions in preparation for big integers.

GitHub

  • #47 Req. nonzero bit width
  • #43 Req. additional bit counts
  • #34 Recoverable unsigned subtraction

New NBKBinaryInteger APIs

bitWidth >= 1
var nonzeroBitCount:     Int { get }
var leadingZeroBitCount: Int { get }
var mostSignificantBit: Bool { get }

New NBKUnsignedInteger APIs

func subtractingReportingOverflow(_ other: Self) -> PVO<Self>
mutating func subtractReportingOverflow(_ other: Self) -> Bool

func subtractingReportingOverflow(_ other: Digit) -> PVO<Self>
mutating func subtractReportingOverflow(_ other: Digit) -> Bool