]> git.lizzy.rs Git - rust.git/commit - src/tools/miri
Auto merge of #68772 - matthewjasper:relate-opt, r=davidtwco
authorbors <bors@rust-lang.org>
Mon, 3 Feb 2020 06:38:34 +0000 (06:38 +0000)
committerbors <bors@rust-lang.org>
Mon, 3 Feb 2020 06:38:34 +0000 (06:38 +0000)
commit0d34a8772251b3f9d4dd05c81d9531d455a14fc2
treea9ecdc8fb7df5fe588c6c78c2bb62d00d723018d
parenta2e80300cd83849dd4fa17af131e603623631bf6
parenta606ffdb174dd6a7d226d632994e6a885bf8a1ac
Auto merge of #68772 - matthewjasper:relate-opt, r=davidtwco

Avoid exponential behaviour when relating types

When equating bound types we check subtyping in both directions. Since closures are invariant in their substs, we end up comparing the two types an exponential number of times. If there are no bound variables this isn't needed.

Closes #68061