The Wire · Showcase
RUST LANDS BINARY SEARCH IN CONST, CLOSES ANDROID WEAK SYMBOL GAP
By RepoJournal · Filed · About Rust
The standard library gained const-time binary search and Miri fixed a critical Android I/O gap that broke vectored file operations in testing.
Rust shipped a rollup [1] that merged six critical improvements to the compiler and standard library. The biggest win: `const_binary_search` is now stable [1], letting developers perform binary searches at compile time. In parallel, the Miri team resolved a longstanding Android compatibility issue [2] [3] where preadv/pwritev weak symbols weren't resolving under test, causing file operations to fail entirely on bionic. This fix un-skips Android filesystem tests that were previously broken. The same rollup [1] also added diagnostic improvements for macros [1] and simplified the unwind crate, both of which reduce compiler surface area. Cargo just landed a 29-commit submodule update [5] that refactors homedir normalization and syncs command metadata handling. Meanwhile, the compiler caught a subtle error case: trait bounds that require closures to return themselves (like `T: Fn() -> T`) now produce clear diagnostic messages [4] instead of confusing type errors.
Action items
- → Review the const_binary_search API in your search codepaths - you can now move this logic to compile time rust-lang/rust [plan]
- → If you test on Android, verify your I/O tests pass after this Miri update - they should now work rust-lang/miri [monitor]
- → Pull the latest Cargo submodule when you next sync - homedir handling is normalized rust-lang/rust [plan]
References
- [1] Rollup of 6 pull requests ↗ rust-lang/rust
- [2] Resolve preadv/pwritev as weak symbols on Android rust-lang/miri
- [3] Merge pull request #5212 from Joel-Wwalker/5080-android-fs rust-lang/miri
- [4] Detect when trait bound requires closure to return itself ↗ rust-lang/rust
- [5] Auto merge of #159475 - weihanglo:update-cargo, r=weihanglo rust-lang/rust