]> git.lizzy.rs Git - rust.git/blob - src/test/ui/traits/default-method/xc-2.rs
Auto merge of #84959 - camsteffen:lint-suggest-group, r=estebank
[rust.git] / src / test / ui / traits / default-method / xc-2.rs
1 // run-pass
2 // aux-build:xc.rs
3 // aux-build:xc_2.rs
4
5
6
7 extern crate xc as aux;
8 extern crate xc_2 as aux2;
9 use aux::A;
10 use aux2::{a_struct, welp};
11
12
13 pub fn main () {
14
15     let a = a_struct { x: 0 };
16     let b = a_struct { x: 1 };
17
18     assert_eq!(0.g(), 10);
19     assert_eq!(a.g(), 10);
20     assert_eq!(a.h(), 11);
21     assert_eq!(b.g(), 10);
22     assert_eq!(b.h(), 11);
23     assert_eq!(A::lurr(&a, &b), 21);
24
25     welp(&0);
26 }