...
1# DO NOT EDIT; generated by go run testdata/gen.go
2#
3#name: comparison
4#evalPartial
5-- in.cue --
6lss: 1 < 2
7leq: 1 <= 1.0
8leq: 2.0 <= 3
9eql: 1 == 1.0
10neq: 1.0 == 1
11gtr: !(2 > 3)
12geq: 2.0 >= 2
13seq: "a"+"b" == "ab"
14err: 2 == "s"
15-- out/def --
16lss: true
17leq: true
18eql: true
19neq: true
20gtr: true
21geq: true
22seq: true
23err: _|_ // invalid operation 2 == "s" (mismatched types int and string)
24-- out/legacy-debug --
25<0>{lss: true, leq: true, eql: true, neq: true, gtr: true, geq: true, seq: true, err: _|_((2 == "s"):invalid operation 2 == "s" (mismatched types int and string))}
26-- out/compile --
27--- in.cue
28{
29 lss: (1 < 2)
30 leq: (1 <= 1.0)
31 leq: (2.0 <= 3)
32 eql: (1 == 1.0)
33 neq: (1.0 == 1)
34 gtr: !(2 > 3)
35 geq: (2.0 >= 2)
36 seq: (("a" + "b") == "ab")
37 err: (2 == "s")
38}
39-- out/eval/stats --
40Leaks: 0
41Freed: 9
42Reused: 7
43Allocs: 2
44Retain: 0
45
46Unifications: 9
47Conjuncts: 10
48Disjuncts: 9
49-- out/eval --
50Errors:
51err: invalid operands 2 and "s" to '==' (type int and string):
52 ./in.cue:9:6
53 ./in.cue:9:11
54
55Result:
56(_|_){
57 // [eval]
58 lss: (bool){ true }
59 leq: (bool){ true }
60 eql: (bool){ true }
61 neq: (bool){ true }
62 gtr: (bool){ true }
63 geq: (bool){ true }
64 seq: (bool){ true }
65 err: (_|_){
66 // [eval] err: invalid operands 2 and "s" to '==' (type int and string):
67 // ./in.cue:9:6
68 // ./in.cue:9:11
69 }
70}
View as plain text