rust/library/core
bors cf8d98b227 Auto merge of #108623 - scottmcm:try-different-as-slice-impl, r=the8472
Move `Option::as_slice` to an always-sound implementation

This approach depends on CSE to not have any branches or selects when the guessed offset is correct -- which it always will be right now -- but to also be *sound* (just less efficient) if the layout algorithms change such that the guess is incorrect.

The codegen test confirms that CSE handles this as expected, leaving the optimal codegen.

cc JakobDegen #108545
2023-03-13 13:53:24 +00:00
..
benches Auto merge of #108157 - scottmcm:tuple-gt-via-partialcmp, r=dtolnay 2023-03-05 22:02:26 +00:00
primitive_docs
src Auto merge of #108623 - scottmcm:try-different-as-slice-impl, r=the8472 2023-03-13 13:53:24 +00:00
tests Match unmatched backticks in library/ 2023-03-03 03:03:29 +01:00
Cargo.toml Update rand in the stdlib tests, and remove the getrandom feature from it 2023-01-04 14:52:41 -08:00