From 218caa410aa38c29984be31a5229b9fa717560ee Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:19:13 +0200 Subject: Merging upstream version 1.68.2+dfsg1. Signed-off-by: Daniel Baumann --- .../normalize-under-binder/issue-90612.rs | 41 ---------------------- 1 file changed, 41 deletions(-) delete mode 100644 src/test/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90612.rs (limited to 'src/test/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90612.rs') diff --git a/src/test/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90612.rs b/src/test/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90612.rs deleted file mode 100644 index effc32945..000000000 --- a/src/test/ui/higher-rank-trait-bounds/normalize-under-binder/issue-90612.rs +++ /dev/null @@ -1,41 +0,0 @@ -// check-pass - -use std::marker::PhantomData; - -trait Family: Sized { - type Item<'a>; - - fn apply_all(&self, f: F) - where - F: FamilyItemFn { } -} - -struct Array(PhantomData); - -impl Family for Array { - type Item<'a> = &'a T; -} - -trait FamilyItemFn { - fn apply(&self, item: T::Item<'_>); -} - -impl FamilyItemFn for F -where - T: Family, - for<'a> F: Fn(T::Item<'a>) -{ - fn apply(&self, item: T::Item<'_>) { - (*self)(item); - } -} - -fn process(array: Array) { - // Works - array.apply_all(|x: &T| { }); - - // ICE: NoSolution - array.apply_all(|x: as Family>::Item<'_>| { }); -} - -fn main() {} -- cgit v1.2.3