Skip to content

Add ByteOrder enum#1293

Merged
tarcieri merged 1 commit into
masterfrom
byte-order-enum
Jun 16, 2026
Merged

Add ByteOrder enum#1293
tarcieri merged 1 commit into
masterfrom
byte-order-enum

Conversation

@tarcieri

Copy link
Copy Markdown
Member

Adds an enum with support for choosing endianness at runtime.

Two new Uint::from_slice and Uint::from_hex methods have been added that accept a ByteOrder as a runtime parameter.

Adds an enum with support for choosing endianness at runtime.

Two new `Uint::from_slice` and `Uint::from_hex` methods have been
added that accept a `ByteOrder` as a runtime parameter.
@codecov

codecov Bot commented Jun 16, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 58.33333% with 10 lines in your changes missing coverage. Please review.
✅ Project coverage is 91.22%. Comparing base (6a7935c) to head (06b96d1).

Files with missing lines Patch % Lines
src/uint/encoding.rs 58.33% 10 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1293      +/-   ##
==========================================
- Coverage   91.26%   91.22%   -0.05%     
==========================================
  Files         189      189              
  Lines       22390    22400      +10     
==========================================
  Hits        20434    20434              
- Misses       1956     1966      +10     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@tarcieri tarcieri merged commit 5199049 into master Jun 16, 2026
32 checks passed
@tarcieri tarcieri deleted the byte-order-enum branch June 16, 2026 13:16
@tarcieri tarcieri mentioned this pull request Jun 16, 2026
tarcieri added a commit that referenced this pull request Jun 16, 2026
## Added
- Extend LCM support to `BoxedUint` and add a supporting trait (#1240)
- Impl `ConstantTimeGreater`/`ConstantTimeLess` for `ConstMontyForm` (#1247)
- Support for exact division (#1256, #1271)
- Implement `Encoding` trait for `Int` serde support (#1286)
- `ByteOrder` enum (#1293)

## Changed
- Update multiword division to better match GMP paper (#1244)
- Faster `checked_sqrt`/`floor_sqrt` (#1258)

## Fixed
- Panic in `Int::div_rem_unsigned` with large divisors (#1250)
- Avoid incorrect creation of an `Odd<BoxedUint>` in `invert_mod2k` (#1257)
- `BoxedUint` bitor-assign with wider `rhs` (#1270)
- Enforce `UintRef` slice length checks in release builds (#1272)
- Clamp Montgomery exponent bit bounds (#1273)
- Reject oversized fixed-width DER integers (#1274)
- Update `CtEq` impl for `MontyParams` to match `PartialEq` (#1278)
- Canonicalize modulus-one residues (#1280)
- `nlimbs` overflow near `u32::MAX` (#1283)
- `UintRef` byte precision [#1290)
tarcieri added a commit to RustCrypto/elliptic-curves that referenced this pull request Jun 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant