summaryrefslogtreecommitdiff
path: root/gcc/testsuite/rust/compile/torture/issue-893.rs
blob: d8245f3e0d851a734247e48afecac66f0b64a3ed (plain)
1
2
3
4
5
6
7
8
9
10
11
// { dg-additional-options "-w" }
struct Foo<T>(T);
impl<T> Foo<T> {
    fn new<Y>(a: T, b: Y) -> Self {
        Self(a)
    }
}

pub fn test() {
    let a = Foo::<i32>::new::<f32>(123, 456f32);
}