...
1# DO NOT EDIT; generated by go run testdata/gen.go
2#
3raw: true
4-- in.cue --
5{a: *"foo" | *"bar" | *string | int, b: a[2:3]}
6-- out/def --
7a: *string | int
8b: _|_ // cannot slice a (type string)
9-- out/compile --
10--- in.cue
11{
12 {
13 a: (*"foo"|*"bar"|*string|int)
14 b: ć0;ać[2:3]
15 }
16}
17-- out/eval/stats --
18Leaks: 0
19Freed: 7
20Reused: 1
21Allocs: 6
22Retain: 0
23
24Unifications: 3
25Conjuncts: 12
26Disjuncts: 7
27-- out/eval --
28(struct){
29 a: ((int|string)){ |(*(string){ "foo" }, *(string){ "bar" }, *(string){ string }, (int){ int }) }
30 b: (_|_){
31 // [incomplete] b: non-concrete slice subject a:
32 // ./in.cue:1:41
33 }
34}
View as plain text