blob: 63cecf21de18fe48d88fdd78ab431be65c827312 [file] [log] [blame]
-- in.cue --
#T: [_]: _
#T: close({"a": string})
x: #T
x: {
a: "hello"
b: "foo"
}
-- out/eval --
Errors:
x: field not allowed: b:
./in.cue:1:5
./in.cue:2:11
./in.cue:3:4
./in.cue:6:2
Result:
(_|_){
// [eval]
#T: (#struct){
a: (string){ string }
}
x: (_|_){
// [eval]
a: (string){ "hello" }
b: (_|_){
// [eval] x: field not allowed: b:
// ./in.cue:1:5
// ./in.cue:2:11
// ./in.cue:3:4
// ./in.cue:6:2
}
}
}
-- out/compile --
--- in.cue
{
#T: {
[_]: _
}
#T: close({
a: string
})
x: 0;#T
x: {
a: "hello"
b: "foo"
}
}