aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/rust/compile/issue-2238.rs
blob: 6a43a13dfe7a266911c5eb995aa5fef7d8f524e0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#[lang = "sized"]
pub trait Sized {}

fn main() {
    struct Foo;

    trait Bar {
        fn foo(&self);
    }

    impl Bar for Foo {
        fn foo(&self) {}
    }

    let s = Foo;
    s.foo();
}