Some `is_useful` cleanups #98582 was reverted because it was a perf regression. https://github.com/rust-lang/rust/pull/99806 reintroduces the changes, but this PR picks individual ones that have no regressions.
Some `is_useful` cleanups #98582 was reverted because it was a perf regression. https://github.com/rust-lang/rust/pull/99806 reintroduces the changes, but this PR picks individual ones that have no regressions.