]>
Commit | Line | Data |
---|---|---|
b7449926 | 1 | // run-pass |
223e47cc | 2 | |
c34b1796 | 3 | |
223e47cc | 4 | trait Foo { |
1a4d82fc JJ |
5 | fn bar(&self) -> String { |
6 | format!("test") | |
223e47cc LB |
7 | } |
8 | } | |
9 | ||
10 | enum Baz { | |
11 | Quux | |
12 | } | |
13 | ||
14 | impl Foo for Baz { | |
15 | } | |
16 | ||
17 | pub fn main() { | |
1a4d82fc JJ |
18 | let q = Baz::Quux; |
19 | assert_eq!(q.bar(), "test".to_string()); | |
223e47cc | 20 | } |