| # DO NOT EDIT; generated by go run testdata/gen.go |
| # |
| #name: excluded embedding from closing |
| #evalPartial |
| -- in.cue -- |
| #S: { |
| a: {c: int} |
| { |
| c: {d: int} |
| } |
| let B = {open: int} |
| b: B |
| } |
| V: #S & { |
| c: e: int |
| b: extra: int |
| } |
| -- out/def -- |
| #S: { |
| a: { |
| c: int |
| } |
| c: { |
| d: int |
| ... |
| } |
| b: { |
| open: int |
| ... |
| } |
| } |
| V: #S & { |
| c: { |
| e: int |
| } |
| b: { |
| extra: int |
| } |
| } |
| -- out/legacy-debug -- |
| <0>{#S: <1>C{a: <2>C{c: int}, c: <3>{d: int}, b: <4>{open: int}}, V: <5>C{a: <6>C{c: int}, c: <7>{d: int, e: int}, b: <8>{open: int, extra: int}}} |
| -- out/compile -- |
| --- in.cue |
| { |
| #S: { |
| a: { |
| c: int |
| } |
| { |
| c: { |
| d: int |
| } |
| } |
| b: 〈0;let B〉 |
| } |
| V: (〈0;#S〉 & { |
| c: { |
| e: int |
| } |
| b: { |
| extra: int |
| } |
| }) |
| } |
| -- out/eval -- |
| Errors: |
| V.b: field not allowed: extra: |
| ./in.cue:6:10 |
| ./in.cue:7:5 |
| ./in.cue:9:4 |
| ./in.cue:11:5 |
| V.c: field not allowed: e: |
| ./in.cue:3:2 |
| ./in.cue:4:6 |
| ./in.cue:9:4 |
| ./in.cue:10:5 |
| |
| Result: |
| (_|_){ |
| // [eval] |
| #S: (#struct){ |
| c: (#struct){ |
| d: (int){ int } |
| } |
| a: (#struct){ |
| c: (int){ int } |
| } |
| b: (#struct){ |
| open: (int){ int } |
| } |
| } |
| V: (_|_){ |
| // [eval] |
| c: (_|_){ |
| // [eval] |
| d: (int){ int } |
| e: (_|_){ |
| // [eval] V.c: field not allowed: e: |
| // ./in.cue:3:2 |
| // ./in.cue:4:6 |
| // ./in.cue:9:4 |
| // ./in.cue:10:5 |
| } |
| } |
| a: (#struct){ |
| c: (int){ int } |
| } |
| b: (_|_){ |
| // [eval] |
| open: (int){ int } |
| extra: (_|_){ |
| // [eval] V.b: field not allowed: extra: |
| // ./in.cue:6:10 |
| // ./in.cue:7:5 |
| // ./in.cue:9:4 |
| // ./in.cue:11:5 |
| } |
| } |
| } |
| } |