Debian Codegraph @

tools/trim/testdata/62.txtar

raw
1 Disjunctions. Even if the disjunction is within an explicit
2 unification, we need to discover the disjunction and make sure we
3 ignore all its content so that it cannot "win" over some discriminator
4 field. See also 63.
5
6 Note that v2 gets this wrong.
7
8 -- a.cue --
9 #a: x: int
10 #b: ({x: 5} | {x: 7}) & #a
11 out: #b & {x: 5}
12 -- out/trim-v3 --
13 == a.cue
14 #a: x: int
15 #b: ({x: 5} | {x: 7}) & #a
16 out: #b & {x: 5}
17 -- diff/-out/trim-v3<==>+out/trim --
18 diff old new
19 --- old
20 +++ new
21 @@ -1,4 +1,4 @@
22 == a.cue
23 #a: x: int
24 #b: ({x: 5} | {x: 7}) & #a
25 -out: #b & {}
26 +out: #b & {x: 5}
27 -- out/trim-v3-noshare --
28 == a.cue
29 #a: x: int
30 #b: ({x: 5} | {x: 7}) & #a
31 out: #b & {x: 5}
32 -- diff/-out/trim-v3-noshare<==>+out/trim --
33 diff old new
34 --- old
35 +++ new
36 @@ -1,4 +1,4 @@
37 == a.cue
38 #a: x: int
39 #b: ({x: 5} | {x: 7}) & #a
40 -out: #b & {}
41 +out: #b & {x: 5}
42 -- out/trim --
43 == a.cue
44 #a: x: int
45 #b: ({x: 5} | {x: 7}) & #a
46 out: #b & {}