about summary refs log tree commit diff
path: root/tests/ui/proc-macro/attr-on-trait.rs
blob: 345653864f841ee76b86e51c8f5cab615fafa46e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
//@ run-pass
//@ proc-macro: attr-on-trait.rs
//@ ignore-backends: gcc

extern crate attr_on_trait;

use attr_on_trait::foo;

trait Foo {
    #[foo]
    fn foo() {}
}

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

fn main() {
    3i32.foo();
}