rust/library
Yuki Okushi 56ae3fb2f0
Rollup merge of #81706 - SkiFire13:document-binaryheap-unsafe, r=Mark-Simulacrum
Document BinaryHeap unsafe functions

`BinaryHeap` contains some private safe functions but that are actually unsafe to call. This PR marks them `unsafe` and documents all the `unsafe` function calls inside them.

While doing this I might also have found a bug: some "SAFETY" comments in `sift_down_range` and `sift_down_to_bottom` are valid only if you assume that `child` doesn't overflow. However it may overflow if `end > isize::MAX` which can be true for ZSTs (but I think only for them). I guess the easiest fix would be to skip any sifting if `mem::size_of::<T> == 0`.

Probably conflicts with #81127 but solving the eventual merge conflict should be pretty easy.
2021-02-21 15:26:40 +09:00
..
alloc Rollup merge of #81706 - SkiFire13:document-binaryheap-unsafe, r=Mark-Simulacrum 2021-02-21 15:26:40 +09:00
backtrace@af078ecc0b
core Auto merge of #81427 - klensy:eat-digits, r=m-ou-se 2021-02-20 07:31:43 +00:00
panic_abort
panic_unwind
proc_macro impl PartialEq<Punct> for char; symmetry for #78636 2021-02-19 17:28:19 -08:00
profiler_builtins
rtstartup
rustc-std-workspace-alloc
rustc-std-workspace-core
rustc-std-workspace-std
std Rollup merge of #82244 - pickfire:patch-6, r=dtolnay 2021-02-20 20:37:01 +01:00
stdarch@9c732a56f6
term
test Rollup merge of #82274 - andersk:test-unwrap, r=Mark-Simulacrum 2021-02-19 02:49:13 +01:00
unwind