|
32 | 32 | }
|
33 | 33 | }
|
34 | 34 | }
|
| 35 | + }, |
| 36 | + "b": true, |
| 37 | + "c": { |
| 38 | + "d": true |
35 | 39 | }
|
36 | 40 | },
|
37 | 41 | "cases": [
|
38 | 42 | {
|
39 | 43 | "comment": "simple field",
|
40 |
| - "expression": "a", |
| 44 | + "expression": "b", |
| 45 | + "result": true, |
41 | 46 | "bench": "full"
|
42 | 47 | },
|
43 | 48 | {
|
44 | 49 | "comment": "simple subexpression",
|
45 |
| - "expression": "a.b", |
| 50 | + "expression": "c.d", |
| 51 | + "result": true, |
46 | 52 | "bench": "full"
|
47 | 53 | },
|
48 | 54 | {
|
49 |
| - "comment": "deep field selection", |
| 55 | + "comment": "deep field selection no match", |
50 | 56 | "expression": "a.b.c.d.e.f.g.h.i.j.k.l.m.n.o.p.q.r.s",
|
| 57 | + "result": null, |
| 58 | + "bench": "full" |
| 59 | + }, |
| 60 | + { |
| 61 | + "comment": "deep field selection", |
| 62 | + "expression": "a.b.c.d.e.f.g.h.i.j.k.l.m.n.o.p", |
| 63 | + "result": true, |
51 | 64 | "bench": "full"
|
52 | 65 | },
|
53 | 66 | {
|
54 | 67 | "comment": "simple or",
|
55 |
| - "expression": "not_there || a", |
| 68 | + "expression": "not_there || b", |
| 69 | + "result": true, |
56 | 70 | "bench": "full"
|
57 | 71 | }
|
58 | 72 | ]
|
|
67 | 81 | {
|
68 | 82 | "comment": "deep ands",
|
69 | 83 | "expression": "a && b && c && d && e && f && g && h && i && j && k && l && m && n && o && p && q && r && s && t && u && v && w && x && y && z",
|
| 84 | + "result": 25, |
70 | 85 | "bench": "full"
|
71 | 86 | },
|
72 | 87 | {
|
73 | 88 | "comment": "deep ors",
|
74 | 89 | "expression": "z || y || x || w || v || u || t || s || r || q || p || o || n || m || l || k || j || i || h || g || f || e || d || c || b || a",
|
| 90 | + "result": 25, |
75 | 91 | "bench": "full"
|
76 | 92 | },
|
77 | 93 | {
|
78 | 94 | "comment": "lots of summing",
|
79 |
| - "expression": "sum(z, y, x, w, v, u, t, s, r, q, p, o, n, m, l, k, j, i, h, g, f, e, d, c, b, a)", |
| 95 | + "expression": "sum([z, y, x, w, v, u, t, s, r, q, p, o, n, m, l, k, j, i, h, g, f, e, d, c, b, a])", |
| 96 | + "result": 325, |
| 97 | + "bench": "full" |
| 98 | + }, |
| 99 | + { |
| 100 | + "comment": "lots of function application", |
| 101 | + "expression": "sum([z, sum([y, sum([x, sum([w, sum([v, sum([u, sum([t, sum([s, sum([r, sum([q, sum([p, sum([o, sum([n, sum([m, sum([l, sum([k, sum([j, sum([i, sum([h, sum([g, sum([f, sum([e, sum([d, sum([c, sum([b, a])])])])])])])])])])])])])])])])])])])])])])])])])", |
| 102 | + "result": 325, |
80 | 103 | "bench": "full"
|
81 | 104 | },
|
82 | 105 | {
|
83 | 106 | "comment": "lots of multi list",
|
84 | 107 | "expression": "[z, y, x, w, v, u, t, s, r, q, p, o, n, m, l, k, j, i, h, g, f, e, d, c, b, a]",
|
| 108 | + "result": [25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0], |
85 | 109 | "bench": "full"
|
86 | 110 | }
|
87 | 111 | ]
|
|
116 | 140 | },
|
117 | 141 | {
|
118 | 142 | "comment": "filter projection",
|
119 |
| - "expression": "foo[bar > baz][qux > baz]", |
| 143 | + "expression": "foo[?bar > baz][?qux > baz]", |
120 | 144 | "bench": "parse"
|
121 | 145 | }
|
122 | 146 | ]
|
|
0 commit comments