about summary refs log tree commit diff
path: root/src/test/compile-fail/terr-in-field.rs
blob: 84cb3bc9ac58d70de61c766d05abc0afa52a9080 (plain)
1
2
3
4
5
6
7
8
9
type foo = {a: int, b: int};
type bar = {a: int, b: uint};

fn want_foo(f: foo) {}
fn have_bar(b: bar) {
    want_foo(b); //~ ERROR (in field `b`, int vs uint)
}

fn main() {}