]> git.proxmox.com Git - rustc.git/blame - src/test/ui/associated-types/issue-24204.rs
Update unsuspicious file list
[rustc.git] / src / test / ui / associated-types / issue-24204.rs
CommitLineData
29967ef6
XL
1// check-pass
2
9e0c209e 3#![allow(dead_code)]
1a4d82fc 4
9e0c209e
SL
5trait MultiDispatch<T> {
6 type O;
a7813a04 7}
223e47cc 8
9e0c209e
SL
9trait Trait: Sized {
10 type A: MultiDispatch<Self::B, O = Self>;
11 type B;
12
29967ef6
XL
13 fn new<U>(u: U) -> <Self::A as MultiDispatch<U>>::O
14 where
15 Self::A: MultiDispatch<U>;
223e47cc
LB
16}
17
29967ef6
XL
18fn test<T: Trait<B = i32>>(b: i32) -> T
19where
20 T::A: MultiDispatch<i32>,
21{
22 T::new(b)
23}
a7813a04 24
9e0c209e 25fn main() {}