By merging the undo_log of all structures part of the snapshot the cost
of creating a snapshot becomes much cheaper. Since snapshots with no or
few changes are so frequent this ends up mattering more than the slight
overhead of dispatching on the variants that map to each field.
Update btree_map::VacantEntry::insert docs to actually call insert
It looks like they were copied from the `or_insert` docs. This change
makes the example more like the hash_map::VacantEntry::insert docs.
Correctly handle UEFI targets as Windows-like when emitting sections for LLVM bitcode
This handles UEFI handles when emitting inline assembly for sections containing LLVM bitcode. See details in #71880. I have locally confirmed that this change fixes compilation of projects using the `x86_64-unknown-uefi` target compiling with `cargo-xbuild`, but I am not very familiar with LLVM bitcode so this may not be the correct approach.
r? @alexcrichton as they wrote the initial LLVM bitcode emitting code?
Add remove_current_as_list to LinkedList's CursorMut
The `remove_current` method only returns the inner `T` and deallocates the list node. This is unnecessary for move operations, where the element is going to be linked back into this (or even a different) `LinkedList`. The `remove_current_as_list` method avoids this by returning the unlinked list node as a new single-element `LinkedList` structure.
(per https://github.com/rust-lang/rust/issues/58533#issuecomment-623010157)
Add const examples
I only added them to `std::f32` to get feedback on this approach before adding the other constants.
When looking at https://github.com/rust-lang/rust/pull/68952, I found the docs a little confusing. Unless you're intimately aware of what's going on here, I don't think it's super clear what is deprecated and what you're supposed to do instead. I think short examples really clarify what's meant here, so that's what I did.
Rollup of 5 pull requests
Successful merges:
- #71038 (forbid `dyn Trait` in patterns)
- #71697 (Added MIR constant propagation of Scalars into function call arguments)
- #71773 (doc: misc rustdoc things)
- #71810 (Do not try to find binop method on RHS `TyErr`)
- #71877 (Use f64 in f64 examples)
Failed merges:
r? @ghost