Commit 145764d 1 parent 16a0cda commit 145764d Copy full SHA for 145764d
File tree 1 file changed +31
-8
lines changed
cue/testdata/comprehensions
1 file changed +31
-8
lines changed Original file line number Diff line number Diff line change @@ -24,16 +24,22 @@ t: #C
24
24
}
25
25
}
26
26
t: p: "foo"
27
+
28
+ -- variant1.cue --
29
+ #V1: {
30
+ x: close({ f1: int })
31
+ x: f2: 2 // TODO: fail
32
+ }
27
33
-- out/eval/stats --
28
- Leaks: 2
29
- Freed: 12
30
- Reused: 8
31
- Allocs: 6
32
- Retain: 3
34
+ Leaks: 3
35
+ Freed: 16
36
+ Reused: 12
37
+ Allocs: 7
38
+ Retain: 4
33
39
34
- Unifications: 14
35
- Conjuncts: 25
36
- Disjuncts: 15
40
+ Unifications: 19
41
+ Conjuncts: 33
42
+ Disjuncts: 20
37
43
-- out/eval --
38
44
Errors:
39
45
z.x.f2: field not allowed:
@@ -70,6 +76,12 @@ Result:
70
76
#C: (#struct){
71
77
p: (_){ _ }
72
78
}
79
+ #V1: (#struct){
80
+ x: (#struct){
81
+ f1: (int){ int }
82
+ f2: (int){ 2 }
83
+ }
84
+ }
73
85
}
74
86
-- out/compile --
75
87
--- in.cue
@@ -98,3 +110,14 @@ Result:
98
110
p: "foo"
99
111
}
100
112
}
113
+ --- variant1.cue
114
+ {
115
+ #V1: {
116
+ x: close({
117
+ f1: int
118
+ })
119
+ x: {
120
+ f2: 2
121
+ }
122
+ }
123
+ }
You can’t perform that action at this time.
0 commit comments