Debian Patches
Status for rust-byteorder-lite/0.1.0-1
| Patch | Description | Author | Forwarded | Bugs | Origin | Last update |
|---|---|---|---|---|---|---|
| 0001-port-to-quickcheck-1-rand-0.10.patch | Port test suite to quickcheck 1.x / rand 0.10 (Debian ships neither 0.9 nor 0.7) Mechanical API renames only, verified to compile and preserve behaviour: gen.gen::<T>() -> T::arbitrary(gen) (rand::Rng::gen replaced by recursing into quickcheck's own Arbitrary, which is how quickcheck 1.x expects primitives to be generated); Arbitrary::arbitrary<G: Gen>(gen: &mut G) -> arbitrary(gen: &mut Gen) (Gen changed from a generic trait to a concrete struct); StdGen::new(rng, size) -> Gen::new(size) (Gen now owns its RNG internally, no external rand::Rng needed). . Known remaining gap, NOT fixed by this patch: prop_uint_N/prop_int_N/ prop_u24/prop_i24/prop_u48/prop_i48 (in mod test) fail under quickcheck 1.x. In quickcheck 0.9, Gen::size() bounded the magnitude of arbitrary-generated primitive integers; qc_sized(prop, $max) relied on this to keep generated values within the $bytes-wide range these tests write/read. In quickcheck 1.x, primitive Arbitrary impls generate full-range values unconditionally (size no longer bounds magnitude, only collection lengths), so out-of-range values are generated and the truncating round-trip through $write/$read legitimately fails -- through no fault of the library code itself, which has zero runtime dependencies and is unaffected. . A correct fix requires re-deriving bounded-integer generation for each integer width exercised by the qc_byte_order! macro (used at ~130 call sites, some via the plain integer types u16/i16/u32/i32/u64/i64, others via the crate's own Wi128<u128>/Wi128<i128> wrapper, which already self-bounds via Gen::size() using a DIFFERENT convention -- for those calls Gen::size() is deliberately set to the target byte count itself, e.g. qc_byte_order!(prop_uint128_1, Wi128<u128>, 1, 1, ...) -- so a single uniform wrapper cannot be dropped in without either double-bounding the Wi128 cases or leaving the plain-integer cases unbounded. This is a test-suite redesign, not a packaging-scoped patch; marked test_is_broken in debian/rules instead (see debcargo.toml) pending an upstream fix. not-planned by upstream, unaddressed) diff --git a/Cargo.toml b/Cargo.toml index bf2800e..54c86ae 100644 |
Juan Manuel Méndez Rey <juan.mendezr@proton.me> | yes |
All known versions for source package 'rust-byteorder-lite'
- 0.1.0-1 (sid)
