cuelang.org/go@v0.10.1/cue/testdata/fulleval/030_retain_references_with_interleaved_embedding.txtar (about) 1 # DO NOT EDIT; generated by go run testdata/gen.go 2 # 3 #name: retain references with interleaved embedding 4 #evalFull 5 -- in.cue -- 6 a: d: { 7 #base 8 #info: {...} 9 Y: #info.X 10 } 11 12 #base: { 13 #info: {...} 14 } 15 16 a: [Name=string]: {#info: { 17 X: "foo" 18 }} 19 -- out/def -- 20 a: { 21 {[Name=string]: { 22 #info: { 23 X: "foo" 24 } 25 }} 26 d: { 27 #info: { 28 ... 29 } 30 Y: #info.X 31 #base 32 } 33 } 34 #base: { 35 #info: { 36 ... 37 } 38 } 39 -- out/export -- 40 a: { 41 d: { 42 Y: "foo" 43 } 44 } 45 -- out/yaml -- 46 a: 47 d: 48 Y: foo 49 -- out/json -- 50 {"a":{"d":{"Y":"foo"}}} 51 -- out/legacy-debug -- 52 <0>{a: <1>{[]: <2>(Name: string)-><3>{#info: <4>C{X: "foo"}}, d: <5>C{#info: <6>C{X: "foo"}, Y: "foo"}}, #base: <7>C{#info: <8>{...}}} 53 -- out/compile -- 54 --- in.cue 55 { 56 a: { 57 d: { 58 〈2;#base〉 59 #info: { 60 ... 61 } 62 Y: 〈0;#info〉.X 63 } 64 } 65 #base: { 66 #info: { 67 ... 68 } 69 } 70 a: { 71 [string]: { 72 #info: { 73 X: "foo" 74 } 75 } 76 } 77 } 78 -- out/eval/stats -- 79 Leaks: 0 80 Freed: 8 81 Reused: 3 82 Allocs: 5 83 Retain: 1 84 85 Unifications: 8 86 Conjuncts: 19 87 Disjuncts: 9 88 -- out/eval -- 89 (struct){ 90 a: (struct){ 91 d: (#struct){ 92 #info: (#struct){ 93 X: (string){ "foo" } 94 } 95 Y: (string){ "foo" } 96 } 97 } 98 #base: (#struct){ 99 #info: (#struct){ 100 } 101 } 102 }