Rollup merge of #119595 - mbbill:patch-1, r=Mark-Simulacrum
Fixed ambiguity in hint.rs Needle and haystack are actually not the same, they remain constant.
This commit is contained in:
commit
cda0d08388
@ -287,7 +287,7 @@ pub fn spin_loop() {
|
||||
///
|
||||
/// The compiler could theoretically make optimizations like the following:
|
||||
///
|
||||
/// - `needle` and `haystack` are always the same, move the call to `contains` outside the loop and
|
||||
/// - The `needle` and `haystack` do not change, move the call to `contains` outside the loop and
|
||||
/// delete the loop
|
||||
/// - Inline `contains`
|
||||
/// - `needle` and `haystack` have values known at compile time, `contains` is always true. Remove
|
||||
|
Loading…
x
Reference in New Issue
Block a user