gccrs: Handle `async` functions in traits
[official-gcc.git] / gcc / testsuite / rust / compile / issue-1773.rs
bloba4542aea00b080fef10c3615879529067850d2ad
1 #[lang = "sized"]
2 pub trait Sized {}
4 trait Foo<T> {
5     type A;
7     fn test(a: Self::A) -> Self::A {
8         a
9     }
12 struct Bar<T>(T);
13 impl<T> Foo<T> for Bar<i32> {
14     type A = T;
17 fn main() {
18     let a;
19     a = Bar(123);
21     let b;
22     b = Bar::test(a.0);