diff options
Diffstat (limited to 'tests/ui/traits/new-solver/prefer-candidate-no-constraints.rs')
-rw-r--r-- | tests/ui/traits/new-solver/prefer-candidate-no-constraints.rs | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/tests/ui/traits/new-solver/prefer-candidate-no-constraints.rs b/tests/ui/traits/new-solver/prefer-candidate-no-constraints.rs deleted file mode 100644 index 6f8164f3a..000000000 --- a/tests/ui/traits/new-solver/prefer-candidate-no-constraints.rs +++ /dev/null @@ -1,22 +0,0 @@ -// compile-flags: -Ztrait-solver=next -// check-pass - -trait Foo {} - -impl<T> Foo for T {} - -trait Bar {} - -struct Wrapper<'a, T>(&'a T); - -impl<'a, T> Bar for Wrapper<'a, T> where &'a T: Foo {} -// We need to satisfy `&'a T: Foo` when checking that this impl is WF -// that can either be satisfied via the param-env, or via an impl. -// -// When satisfied via the param-env, since each lifetime is canonicalized -// separately, we end up getting extra region constraints. -// -// However, when satisfied via the impl, there are no region constraints, -// and we can short-circuit a response with no external constraints. - -fn main() {} |