/src/test/compile-fail/rec-missing-fields.rs

http://github.com/jruderman/rust · Rust · 9 lines · 2 code · 4 blank · 3 comment · 0 complexity · ae6a7e60861108b049440fd988732cc7 MD5 · raw file

  1. // -*- rust -*-
  2. // error-pattern: mismatched types
  3. // Issue #51.
  4. type point = {x: int, y: int};
  5. fn main() { let p: point = {x: 10}; log(debug, p.y); }