]> git.lizzy.rs Git - rust.git/commit - src/tools/miri
Auto merge of #99232 - lcnr:no-bound-vars-check, r=jackh726
authorbors <bors@rust-lang.org>
Mon, 18 Jul 2022 13:59:05 +0000 (13:59 +0000)
committerbors <bors@rust-lang.org>
Mon, 18 Jul 2022 13:59:05 +0000 (13:59 +0000)
commit144227dae949fb98896a2ba077d8fe7f36c3238e
tree6e95287aa9fc1ea8fbf1b787f86b768e296932c6
parent9ed0bf9f2bd63933785fb8a380c177d2d70e88ec
parent864d2f35280aadeaf63f6e7efa483e173ebd62f6
Auto merge of #99232 - lcnr:no-bound-vars-check, r=jackh726

`replace_bound_vars` fast path: check predicates, don't check consts

split out from #98900

`ty::Const` doesn't have precomputed type flags, so
computing `has_vars_bound_at_or_above` for constants
requires us to visit the const and its contained types
and constants. A noop fold should be pretty much equally as
fast so removing it prevents us from walking the constant twice
in case it contains bound vars.

r? `@jackh726`