diff --git a/README.md b/README.md index 7fea4b1e..d349c96b 100644 --- a/README.md +++ b/README.md @@ -104,16 +104,6 @@ Int256(4) / Int(4), UInt256(4) / UInt(4) Int256(5) % Int(5), UInt256(5) % UInt(5) ``` -> [!NOTE] -> The `Digit` type is `Int` when `Self` is signed, and `UInt` otherwise. - -### ⭐️ Feature: Swift.StaticBigInt - -`StaticBigInt` is disabled by default. You enable it in `Package.swift`. - -> [!NOTE] -> You can use `StaticString` until `StaticBigInt` becomes available. - ## [NBKFlexibleWidthKit][FLX/D] ([Sources][FLX/S], [Tests][FLX/T], [Benchmarks][FLX/B]) @@ -146,9 +136,9 @@ NBKFibonacciXL(10_000_000) // 2.3s on MacBook Pro, 13-inch, M1, 2020 But you can also step through it manually: ```swift -public mutating func increment() { ... } // index + 1 -public mutating func decrement() { ... } // index - 1 -public mutating func double() { ... } // index * 2 +mutating func increment() { ... } // index + 1 +mutating func decrement() { ... } // index - 1 +mutating func double() { ... } // index * 2 ``` diff --git a/Sources/NBKDoubleWidthKit/NBKDoubleWidth.swift b/Sources/NBKDoubleWidthKit/NBKDoubleWidth.swift index 612410f6..6a632a66 100644 --- a/Sources/NBKDoubleWidthKit/NBKDoubleWidth.swift +++ b/Sources/NBKDoubleWidthKit/NBKDoubleWidth.swift @@ -77,14 +77,6 @@ import NBKCoreKit /// Int256(5) % Int(5), UInt256(5) % UInt(5) /// ``` /// -/// - Note: The `Digit` type is `Int` when `Self` is signed, and `UInt` otherwise. -/// -/// ### ⭐️ Feature: StaticBigInt -/// -/// `StaticBigInt` is disabled by default. You enable it in `Package.swift`. -/// -/// - Note: You can use `StaticString` until `StaticBigInt` becomes available. -/// @frozen public struct NBKDoubleWidth: ExpressibleByStringLiteral, NBKFixedWidthInteger, MutableCollection, RandomAccessCollection where High: NBKFixedWidthInteger, High.Digit: NBKCoreInteger { diff --git a/Sources/Numberick/Documentation.docc/Documentation.md b/Sources/Numberick/Documentation.docc/Documentation.md index 46c64b13..17f64264 100644 --- a/Sources/Numberick/Documentation.docc/Documentation.md +++ b/Sources/Numberick/Documentation.docc/Documentation.md @@ -88,19 +88,11 @@ Int256(4) / Int(4), UInt256(4) / UInt(4) Int256(5) % Int(5), UInt256(5) % UInt(5) ``` -- Note: The `Digit` type is `Int` when `Self` is signed, and `UInt` otherwise. - -### ⭐️ Feature: StaticBigInt - -`StaticBigInt` is disabled by default. You enable it in `Package.swift`. - -- Note: You can use `StaticString` until `StaticBigInt` becomes available. +## NBKFlexibleWidthKit > [!IMPORTANT] > It's a work in progress. I may rework it at any time. -## NBKFlexibleWidthKit - ### Models - ``NBKFibonacciXL`` @@ -120,15 +112,15 @@ NBKFibonacciXL(5) // (index: 5, element: 5, next: 8) It uses a fast double-and-add algorithm: ```swift -NBKFibonacciXL(10_000_000) // 2.3s on M1 MacBook Pro +NBKFibonacciXL(10_000_000) // 2.3s on MacBook Pro, 13-inch, M1, 2020 ``` But you can also step through it manually: ```swift -public mutating func increment() { ... } // index + 1 -public mutating func decrement() { ... } // index - 1 -public mutating func double() { ... } // index * 2 +mutating func increment() { ... } // index + 1 +mutating func decrement() { ... } // index - 1 +mutating func double() { ... } // index * 2 ``` ## Topics