class Point { x: f64; y: f64; } fun test() { let one = new Point { x: 23 }; let two = new Point { y: 23 }; let three = new Point { y: 23, x: 123, z: "hello" }; let four = new Point { y: 23, x: "what" }; let five = new Point { y: 23, x }; let x = "now"; let six = new Point { y: 23, x }; } // @expect-errors: // | __test__:7:12: missing an initializer for field y // | __test__:8:12: missing an initializer for field x // | __test__:9:41: Point instance does not have a field named z // | __test__:10:32: field x is of type f64, but this expression generates a string // | __test__:12:32: cannot find value x here // | __test__:15:31: field x is of type f64, but this expression generates a string