Socket
Socket
Sign inDemoInstall

jora

Package Overview
Dependencies
Maintainers
1
Versions
26
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jora - npm Package Compare versions

Comparing version 1.0.0-beta.1 to 1.0.0-beta.2

4

CHANGELOG.md

@@ -0,1 +1,5 @@

## 1.0.0-beta.2 (May 17, 2020)
- Fixed parse error handling
## 1.0.0-beta.1 (May 14, 2020)

@@ -2,0 +6,0 @@

2

dist/jora.min.js

@@ -1,1 +0,1 @@

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).jora=t()}(this,(function(){"use strict";var e={version:"1.0.0-beta.1"},t=Object.freeze({__proto__:null,version:"1.0.0-beta.1",default:e}),r=function(){var e=function(e,t,r,n){for(r=r||{},n=e.length;n--;r[e[n]]=t);return r},t=[2,5],r=[1,13],n=[1,38],i=[1,18],a=[1,7],s=[1,8],o=[1,10],l=[1,11],u=[1,12],c=[1,19],p=[1,20],h=[1,21],y=[1,22],g=[1,23],d=[1,24],f=[1,25],m=[1,28],b=[1,31],v=[1,32],k=[1,33],_=[1,34],$=[1,35],O=[1,36],S=[1,37],N=[5,18,55,58],w=[1,42],E=[1,50],A=[1,49],x=[1,43],R=[1,44],I=[1,45],P=[1,46],C=[1,47],T=[1,48],q=[1,51],j=[1,52],M=[1,53],D=[1,54],F=[1,55],L=[1,56],U=[1,57],B=[1,58],G=[1,59],Y=[1,60],z=[1,61],H=[5,9,14,15,17,18,19,22,23,24,44,45,46,47,48,49,50,53,55,57,58,59,60,61,62,63,66],J=[5,10,11,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,55,58,65,67],Z=[1,62],Q=[1,63],V=[1,64],X=[1,65],W=[1,66],K=[1,67],ee=[1,68],te=[1,71],re=[5,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,53,55,58,59,60,61,62,63,65,67,74],ne=[2,46],ie=[2,48],ae=[1,81],se=[5,10,11,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,53,55,58,59,60,61,62,63,65,67,74],oe=[5,10,11,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,53,55,57,58,59,60,61,62,63,65,67,74],le=[1,88],ue=[1,89],ce=[1,90],pe=[1,105],he=[1,107],ye=[1,108],ge=[1,109],de=[1,110],fe=[1,111],me=[5,10,11,18,21,55,58,65,67],be=[5,10,11,18,21,29,30,41,55,58,65,67],ve=[5,10,11,18,21,23,24,25,26,27,28,29,30,34,35,36,37,38,39,40,41,55,58,65,67],ke=[55,65],_e=[2,99],$e=[11,55],Oe=[65,67],Se=[5,10,11,18,21,25,26,27,28,29,30,41,55,58,65,67],Ne=[5,10,11,18,21,25,26,27,28,29,30,34,35,40,41,55,58,65,67],we=[5,10,11,18,21,25,26,27,28,29,30,34,35,36,37,38,39,40,41,55,58,65,67],Ee=[1,183],Ae=[58,65],xe={trace:function(){},yy:{},symbols_:{error:2,root:3,block:4,EOF:5,definitions:6,e:7,def:8,$:9,";":10,":":11,$ident:12,ident:13,IDENT:14,$IDENT:15,query:16,FUNCTION_START:17,FUNCTION_END:18,FUNCTION:19,sortingCompareList:20,"|":21,NOT:22,"-":23,"+":24,IN:25,HAS:26,NOTIN:27,HASNO:28,AND:29,OR:30,"*":31,"/":32,"%":33,"=":34,"!=":35,"<":36,"<=":37,">":38,">=":39,"~=":40,"?":41,queryRoot:42,relativePath:43,"@":44,"#":45,$$:46,STRING:47,NUMBER:48,REGEXP:49,LITERAL:50,object:51,array:52,"[":53,sliceNotation:54,"]":55,"method()":56,"(":57,")":58,".":59,".(":60,".[":61,"..":62,"..(":63,arguments:64,",":65,"{":66,"}":67,properties:68,property:69,"...":70,arrayElements:71,arrayElement:72,sortingCompare:73,ORDER:74,sliceNotationComponent:75,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",9:"$",10:";",11:":",14:"IDENT",15:"$IDENT",17:"FUNCTION_START",18:"FUNCTION_END",19:"FUNCTION",21:"|",22:"NOT",23:"-",24:"+",25:"IN",26:"HAS",27:"NOTIN",28:"HASNO",29:"AND",30:"OR",31:"*",32:"/",33:"%",34:"=",35:"!=",36:"<",37:"<=",38:">",39:">=",40:"~=",41:"?",44:"@",45:"#",46:"$$",47:"STRING",48:"NUMBER",49:"REGEXP",50:"LITERAL",53:"[",55:"]",57:"(",58:")",59:".",60:".(",61:".[",62:"..",63:"..(",65:",",66:"{",67:"}",70:"...",74:"ORDER"},productions_:[0,[3,2],[4,2],[4,1],[4,1],[4,0],[6,1],[6,2],[8,2],[8,4],[8,2],[8,4],[13,1],[12,1],[7,1],[7,3],[7,2],[7,1],[7,3],[7,4],[7,2],[7,2],[7,2],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,5],[16,1],[16,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,3],[42,1],[42,1],[42,3],[42,4],[42,2],[42,2],[42,3],[42,3],[42,2],[42,2],[42,3],[43,3],[43,4],[43,4],[43,3],[43,3],[43,4],[43,4],[43,3],[43,3],[43,4],[56,3],[56,4],[56,3],[56,4],[64,1],[64,3],[51,2],[51,3],[68,1],[68,3],[69,1],[69,1],[69,1],[69,3],[69,3],[69,3],[69,3],[69,5],[69,1],[69,2],[71,1],[71,3],[72,1],[72,1],[72,2],[52,2],[52,3],[20,1],[20,3],[73,2],[54,1],[54,2],[54,2],[54,3],[75,1],[75,2]],performAction:function(e,t,r,n,i,a,s){var o=a.length-1;switch(i){case 1:return n.buildResult(a[o-1]);case 2:this.$={type:"Block",definitions:a[o-1],body:a[o],range:this._$.range};break;case 3:this.$={type:"Block",definitions:a[o],body:null,range:this._$.range};break;case 4:this.$={type:"Block",definitions:[],body:a[o],range:this._$.range};break;case 5:this.$={type:"Block",definitions:[],body:null,range:this._$.range};break;case 6:case 81:case 85:case 97:case 104:this.$=[a[o]];break;case 7:a[o-1].push(a[o]);break;case 8:this.$={type:"Definition",declarator:{type:"Declarator",name:null,range:s[o-1].range},value:null,range:this._$.range};break;case 9:this.$={type:"Definition",declarator:{type:"Declarator",name:null,range:s[o-3].range},value:a[o-1],range:this._$.range};break;case 10:this.$={type:"Definition",declarator:{type:"Declarator",name:a[o-1].name,range:s[o-1].range},value:null,range:this._$.range};break;case 11:this.$={type:"Definition",declarator:{type:"Declarator",name:a[o-3].name,range:s[o-3].range},value:a[o-1],range:this._$.range};break;case 12:case 13:this.$={type:"Identifier",name:a[o],range:this._$.range};break;case 14:case 42:case 43:case 53:case 54:case 99:break;case 15:this.$={type:"Function",arguments:[],body:a[o-1],legacy:!0,range:this._$.range};break;case 16:this.$={type:"Function",arguments:[],body:a[o],legacy:!1,range:this._$.range};break;case 17:this.$={type:"SortingFunction",compares:a[o],range:this._$.range};break;case 18:this.$={type:"Pipeline",left:a[o-2],right:a[o],range:this._$.range};break;case 19:this.$={type:"Pipeline",left:a[o-3],right:{type:"Block",definitions:a[o-1],body:a[o]},range:this._$.range};break;case 20:case 21:case 22:this.$={type:"Unary",operator:a[o-1],argument:a[o],range:this._$.range};break;case 23:case 24:case 25:case 26:case 27:case 28:case 29:case 30:case 31:case 32:case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:this.$={type:"Binary",operator:a[o-1],left:a[o-2],right:a[o],range:this._$.range};break;case 41:this.$={type:"Conditional",test:a[o-4],consequent:a[o-2],alternate:a[o],range:this._$.range};break;case 44:this.$={type:"Data",range:this._$.range};break;case 45:this.$={type:"Context",range:this._$.range};break;case 46:this.$={type:"Current",range:this._$.range};break;case 47:this.$={type:"Arg1",range:this._$.range};break;case 48:this.$={type:"Reference",name:a[o],range:this._$.range};break;case 49:case 50:case 51:case 52:this.$={type:"Literal",value:a[o],range:this._$.range};break;case 55:this.$={type:"SliceNotation",value:null,arguments:a[o-1],range:this._$.range};break;case 56:case 60:this.$={type:"GetProperty",value:null,property:a[o],range:this._$.range};break;case 57:case 61:this.$={type:"MethodCall",value:null,method:a[o],range:this._$.range};break;case 58:this.$={type:"Parentheses",body:a[o-1],range:this._$.range};break;case 59:this.$={type:"Parentheses",body:{type:"Block",definitions:a[o-2],body:a[o-1]},range:this._$.range};break;case 62:this.$={type:"Map",value:null,query:a[o-1],range:this._$.range};break;case 63:this.$={type:"Filter",value:null,query:a[o-1],range:this._$.range};break;case 64:this.$={type:"Recursive",value:null,query:{type:"GetProperty",value:null,property:a[o]},range:this._$.range};break;case 65:this.$={type:"Recursive",value:null,query:{type:"MethodCall",value:null,method:a[o]},range:this._$.range};break;case 66:this.$={type:"Recursive",value:null,query:a[o-1],range:this._$.range};break;case 67:this.$={type:"Pick",value:a[o-2],getter:null,range:this._$.range};break;case 68:this.$={type:"Pick",value:a[o-3],getter:a[o-1],range:this._$.range};break;case 69:this.$={type:"SliceNotation",value:a[o-3],arguments:a[o-1],range:this._$.range};break;case 70:this.$={type:"GetProperty",value:a[o-2],property:a[o],range:this._$.range};break;case 71:this.$={type:"MethodCall",value:a[o-2],method:a[o],range:this._$.range};break;case 72:this.$={type:"Map",value:a[o-3],query:a[o-1],range:this._$.range};break;case 73:this.$={type:"Filter",value:a[o-3],query:a[o-1],range:this._$.range};break;case 74:this.$={type:"Recursive",value:a[o-2],query:{type:"GetProperty",value:null,property:a[o]},range:this._$.range};break;case 75:this.$={type:"Recursive",value:a[o-2],query:{type:"MethodCall",value:null,method:a[o]},range:this._$.range};break;case 76:this.$={type:"Recursive",value:a[o-3],query:a[o-1],range:this._$.range};break;case 77:this.$={type:"Method",reference:a[o-2],arguments:[],range:this._$.range};break;case 78:this.$={type:"Method",reference:a[o-3],arguments:a[o-1],range:this._$.range};break;case 79:this.$={type:"Method",reference:{type:"Reference",name:a[o-2]},arguments:[],range:this._$.range};break;case 80:this.$={type:"Method",reference:{type:"Reference",name:a[o-3]},arguments:a[o-1],range:this._$.range};break;case 82:case 86:case 98:case 105:a[o-2].push(a[o]);break;case 83:this.$={type:"Object",properties:[],range:this._$.range};break;case 84:this.$={type:"Object",properties:a[o-1],range:this._$.range};break;case 87:this.$={type:"Property",key:a[o],value:null,range:this._$.range};break;case 88:this.$={type:"Property",key:{type:"Current"},value:null,range:this._$.range};break;case 89:this.$={type:"Property",key:{type:"Reference",name:a[o]},value:null,range:this._$.range};break;case 90:this.$={type:"Property",key:a[o-2],value:a[o],range:this._$.range};break;case 91:case 92:case 93:this.$={type:"Property",key:{type:"Literal",value:a[o-2]},value:a[o],range:this._$.range};break;case 94:this.$={type:"Property",key:a[o-3],value:a[o],range:this._$.range};break;case 95:this.$={type:"Spread",query:null,array:!1,range:this._$.range};break;case 96:this.$={type:"Spread",query:a[o],array:!1,range:this._$.range};break;case 100:this.$={type:"Spread",query:null,array:!0,range:this._$.range};break;case 101:this.$={type:"Spread",query:a[o],array:!0,range:this._$.range};break;case 102:this.$={type:"Array",elements:[],range:this._$.range};break;case 103:this.$={type:"Array",elements:a[o-1],range:this._$.range};break;case 106:this.$={type:"Compare",query:a[o-1],order:a[o],range:this._$.range};break;case 107:this.$=[null,a[o]];break;case 108:this.$=[null,a[o-1],a[o]];break;case 109:this.$=[a[o-1],a[o]];break;case 110:this.$=[a[o-2],a[o-1],a[o]];break;case 111:this.$=null;break;case 112:this.$=a[o]}},table:[{3:1,4:2,5:t,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{1:[3]},{5:[1,39]},e(N,[2,3],{16:6,20:9,12:14,42:15,43:16,73:17,51:26,52:27,13:29,56:30,7:40,8:41,9:r,14:n,15:i,17:a,19:s,22:o,23:l,24:u,44:c,45:p,46:h,47:y,48:g,49:d,50:f,53:m,57:b,59:v,60:k,61:_,62:$,63:O,66:S}),e(N,[2,4],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(H,[2,6]),e(J,[2,14],{53:Z,59:Q,60:V,61:X,62:W,63:K,74:ee}),{4:69,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,18:t,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:70,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e([5,10,11,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,55,58,67],[2,17],{65:[1,73]}),{7:74,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:75,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:76,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(re,ne,{10:[1,77],11:[1,78]}),e(re,ie,{10:[1,79],11:[1,80],57:ae}),e(se,[2,42]),e(se,[2,43]),e(J,[2,104]),e(oe,[2,13]),e(se,[2,44]),e(se,[2,45]),e(se,[2,47]),e(se,[2,49]),e(se,[2,50]),e(se,[2,51]),e(se,[2,52]),e(se,[2,53]),e(se,[2,54]),{7:86,9:te,11:le,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,54:82,55:[1,83],56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,70:ue,71:84,72:87,73:17,75:85},e(se,[2,56],{57:ce}),e(se,[2,57]),{6:92,7:91,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{12:95,13:93,14:n,15:i,56:94},{4:96,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:t,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{4:97,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,55:t,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{12:95,13:98,14:n,15:i,56:99},{4:100,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:t,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{9:pe,12:106,13:104,14:n,15:i,47:he,48:ye,50:ge,53:de,67:[1,101],68:102,69:103,70:fe},e(oe,[2,12]),{1:[2,1]},e(N,[2,2],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(H,[2,7]),{6:113,7:112,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:114,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:115,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:116,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:117,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:118,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:119,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:120,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:121,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:122,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:123,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:124,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:125,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:126,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:127,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:128,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:129,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:130,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:131,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:132,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:134,9:te,11:le,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,54:135,55:[1,133],56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17,75:85},{12:95,13:136,14:n,15:i,56:137},{4:138,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:t,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{4:139,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,55:t,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{12:95,13:140,14:n,15:i,56:141},{4:142,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:t,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(J,[2,106]),{18:[1,143]},e(me,[2,16],{23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(se,ne),e(se,ie,{57:ae}),{9:te,12:72,13:29,14:n,15:i,16:145,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:144},e(be,[2,20],{23:E,24:A,25:x,26:R,27:I,28:P,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(ve,[2,21],{31:q,32:j,33:M}),e(ve,[2,22],{31:q,32:j,33:M}),e(H,[2,8]),{7:146,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(H,[2,10]),{7:147,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:150,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:[1,148],59:v,60:k,61:_,62:$,63:O,64:149,66:S,73:17},{55:[1,151]},e(se,[2,102]),{55:[1,152],65:[1,153]},{11:le,55:[2,107],75:154},e(ke,_e,{75:155,11:le,21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(ke,[2,97]),e($e,[2,111],{16:6,20:9,42:15,43:16,73:17,51:26,52:27,13:29,56:30,12:72,7:156,9:te,14:n,15:i,17:a,19:s,22:o,23:l,24:u,44:c,45:p,46:h,47:y,48:g,49:d,50:f,53:m,57:b,59:v,60:k,61:_,62:$,63:O,66:S}),e(ke,[2,100],{16:6,20:9,42:15,43:16,73:17,51:26,52:27,13:29,56:30,12:72,7:157,9:te,14:n,15:i,17:a,19:s,22:o,23:l,24:u,44:c,45:p,46:h,47:y,48:g,49:d,50:f,53:m,57:b,59:v,60:k,61:_,62:$,63:O,66:S}),{7:150,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:[1,158],59:v,60:k,61:_,62:$,63:O,64:159,66:S,73:17},{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z,58:[1,160]},{7:161,8:41,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(se,[2,60],{57:ce}),e(se,[2,61]),{57:ae},{58:[1,162]},{55:[1,163]},e(se,[2,64],{57:ce}),e(se,[2,65]),{58:[1,164]},e(se,[2,83]),{65:[1,166],67:[1,165]},e(Oe,[2,85]),e(Oe,[2,87],{11:[1,167]}),e(Oe,[2,88]),e(Oe,[2,89]),{11:[1,168]},{11:[1,169]},{11:[1,170]},{7:171,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(Oe,[2,95],{42:15,43:16,51:26,52:27,13:29,56:30,12:72,16:172,9:te,14:n,15:i,44:c,45:p,46:h,47:y,48:g,49:d,50:f,53:m,57:b,59:v,60:k,61:_,62:$,63:O,66:S}),e(me,[2,18],{23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{7:173,8:41,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(Se,[2,23],{23:E,24:A,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(Se,[2,24],{23:E,24:A,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(Se,[2,25],{23:E,24:A,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(Se,[2,26],{23:E,24:A,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(be,[2,27],{23:E,24:A,25:x,26:R,27:I,28:P,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e([5,10,11,18,21,30,41,55,58,65,67],[2,28],{23:E,24:A,25:x,26:R,27:I,28:P,29:C,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(ve,[2,29],{31:q,32:j,33:M}),e(ve,[2,30],{31:q,32:j,33:M}),e(J,[2,31]),e(J,[2,32]),e(J,[2,33]),e(Ne,[2,34],{23:E,24:A,31:q,32:j,33:M,36:L,37:U,38:B,39:G}),e(Ne,[2,35],{23:E,24:A,31:q,32:j,33:M,36:L,37:U,38:B,39:G}),e(we,[2,36],{23:E,24:A,31:q,32:j,33:M}),e(we,[2,37],{23:E,24:A,31:q,32:j,33:M}),e(we,[2,38],{23:E,24:A,31:q,32:j,33:M}),e(we,[2,39],{23:E,24:A,31:q,32:j,33:M}),e(Ne,[2,40],{23:E,24:A,31:q,32:j,33:M,36:L,37:U,38:B,39:G}),{11:[1,174],21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z},e(se,[2,67]),{11:le,21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z,55:[1,175],75:155},{55:[1,176]},e(se,[2,70],{57:ce}),e(se,[2,71]),{58:[1,177]},{55:[1,178]},e(se,[2,74],{57:ce}),e(se,[2,75]),{58:[1,179]},e(J,[2,15]),e(J,[2,105]),{53:Z,59:Q,60:V,61:X,62:W,63:K,74:ee},{10:[1,180],21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z},{10:[1,181],21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z},e(se,[2,79]),{58:[1,182],65:Ee},e(Ae,[2,81],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(se,[2,55]),e(se,[2,103]),{7:185,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,70:ue,72:184,73:17},{55:[2,108]},{11:le,55:[2,109],75:186},e($e,[2,112],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(ke,[2,101],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(se,[2,77]),{58:[1,187],65:Ee},e(se,[2,58]),{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z,58:[1,188]},e(se,[2,62]),e(se,[2,63]),e(se,[2,66]),e(se,[2,84]),{9:pe,12:106,13:104,14:n,15:i,47:he,48:ye,50:ge,53:de,69:189,70:fe},{7:190,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:191,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:192,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:193,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z,55:[1,194]},e(Oe,[2,96],{53:Z,59:Q,60:V,61:X,62:W,63:K}),e(me,[2,19],{23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{7:195,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(se,[2,68]),e(se,[2,69]),e(se,[2,72]),e(se,[2,73]),e(se,[2,76]),e(H,[2,9]),e(H,[2,11]),e(se,[2,80]),{7:196,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(ke,[2,98]),e(ke,_e,{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{55:[2,110]},e(se,[2,78]),e(se,[2,59]),e(Oe,[2,86]),e(Oe,[2,90],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(Oe,[2,91],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(Oe,[2,92],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(Oe,[2,93],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{11:[1,197]},e(me,[2,41],{23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(Ae,[2,82],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{7:198,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(Oe,[2,94],{21:w,23:E,24:A,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z})],defaultActions:{39:[2,1],154:[2,108],186:[2,110]},parseError:function(e,t){if(!t.recoverable){var r=new Error(e);throw r.hash=t,r}this.trace(e)},parse:function(e){var t=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,l=0,u=2,c=1,p=i.slice.call(arguments,1),h=Object.create(this.lexer),y={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(y.yy[g]=this.yy[g]);h.setInput(e,y.yy),y.yy.lexer=h,y.yy.parser=this,void 0===h.yylloc&&(h.yylloc={});var d=h.yylloc;i.push(d);var f=h.options&&h.options.ranges;"function"==typeof y.yy.parseError?this.parseError=y.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var m,b,v,k,_,$,O,S,N=function(){var e;return"number"!=typeof(e=h.lex()||c)&&(e=t.symbols_[e]||e),e},w={};;){if(b=r[r.length-1],this.defaultActions[b]?v=this.defaultActions[b]:(null==m&&(m=N()),v=a[b]&&a[b][m]),void 0===v||!v.length||!v[0]){var E="";for(_ in S=[],a[b])this.terminals_[_]&&_>u&&S.push("'"+this.terminals_[_]+"'");E=h.showPosition?"Parse error on line "+(o+1)+":\n"+h.showPosition()+"\nExpecting "+S.join(", ")+", got '"+(this.terminals_[m]||m)+"'":"Parse error on line "+(o+1)+": Unexpected "+(m==c?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(E,{text:h.match,token:this.terminals_[m]||m,line:h.yylineno,loc:d,expected:S})}if(v[0]instanceof Array&&v.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+m);switch(v[0]){case 1:r.push(m),n.push(h.yytext),i.push(h.yylloc),r.push(v[1]),m=null,l=h.yyleng,s=h.yytext,o=h.yylineno,d=h.yylloc;break;case 2:if($=this.productions_[v[1]][1],w.$=n[n.length-$],w._$={first_line:i[i.length-($||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-($||1)].first_column,last_column:i[i.length-1].last_column},f&&(w._$.range=[i[i.length-($||1)].range[0],i[i.length-1].range[1]]),void 0!==(k=this.performAction.apply(w,[s,l,o,y.yy,v[1],n,i].concat(p))))return k;$&&(r=r.slice(0,-1*$*2),n=n.slice(0,-1*$),i=i.slice(0,-1*$)),r.push(this.productions_[v[1]][0]),n.push(w.$),i.push(w._$),O=a[r[r.length-2]][r[r.length-1]],r.push(O);break;case 3:return!0}}return!0}},Re={EOF:1,parseError:function(e,t){if(!this.yy.parser)throw new Error(e);this.yy.parser.parseError(e,t)},setInput:function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},unput:function(e){var t=e.length,r=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var n=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),r.length-1&&(this.yylineno-=r.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:r?(r.length===n.length?this.yylloc.first_column:0)+n[n.length-r.length].length-r[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(e){this.unput(this.match.slice(e))},pastInput:function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=new Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},test_match:function(e,t){var r,n,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(n=e[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=n.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:n?n[n.length-1].length-n[n.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],r=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),r)return r;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var e,t,r,n;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((r=this._input.match(this.rules[i[a]]))&&(!t||r[0].length>t[0].length)){if(t=r,n=a,this.options.backtrack_lexer){if(!1!==(e=this.test_match(r,i[a])))return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?!1!==(e=this.test_match(t,i[n]))&&e:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var e=this.next();return e||this.lex()},begin:function(e){this.conditionStack.push(e)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(e){return(e=this.conditionStack.length-1-Math.abs(e||0))>=0?this.conditionStack[e]:"INITIAL"},pushState:function(e){this.begin(e)},stateStackSize:function(){return this.conditionStack.length},options:{ranges:!0},performAction:function(e,t,r,n){switch(r){case 0:e.commentRanges.push(t.yylloc.range);break;case 1:break;case 2:return this.popState(),"/";case 3:return this.popState(),"<";case 4:this.done=!1,this.popState();break;case 5:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,"(";case 6:return this.fnOpened=this.fnOpenedStack.pop()||0,this._input&&this.begin("preventPrimitive"),")";case 7:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,"[";case 8:return this.fnOpened=this.fnOpenedStack.pop()||0,this._input&&this.begin("preventPrimitive"),"]";case 9:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,"{";case 10:return this.fnOpened=this.fnOpenedStack.pop()||0,this._input&&this.begin("preventPrimitive"),"}";case 11:return t.yytext=this.toLiteral(t.yytext),"LITERAL";case 12:return"AND";case 13:return"OR";case 14:return"HASNO";case 15:return"HAS";case 16:return"IN";case 17:return"NOTIN";case 18:return"NOT";case 19:return"ORDER";case 20:return this._input&&this.begin("preventPrimitive"),t.yytext=Number(t.yytext),"NUMBER";case 21:case 22:return this._input&&this.begin("preventPrimitive"),t.yytext=this.toStringLiteral(t.yytext),"STRING";case 23:return this._input&&this.begin("preventPrimitive"),t.yytext=this.toRegExp(t.yytext),"REGEXP";case 24:return this._input&&this.begin("preventPrimitive"),"IDENT";case 25:return this._input&&this.begin("preventPrimitive"),t.yytext=t.yytext.slice(1),"$IDENT";case 26:return this._input&&this.begin("preventPrimitive"),"@";case 27:return this._input&&this.begin("preventPrimitive"),"#";case 28:return this._input&&this.begin("preventPrimitive"),"$$";case 29:return this._input&&this.begin("preventPrimitive"),"$";case 30:return"FUNCTION";case 31:return this.fnOpened++,"FUNCTION_START";case 32:return"=";case 33:return"!=";case 34:return"~=";case 35:return">=";case 36:return"<=";case 37:return"<";case 38:return this.fnOpened?(this.fnOpened--,"FUNCTION_END"):">";case 39:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,"..(";case 40:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,".(";case 41:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,".[";case 42:return"...";case 43:return this._input&&this.begin("preventPrimitive"),"..";case 44:return this._input&&this.begin("preventPrimitive"),".";case 45:return"?";case 46:return",";case 47:return":";case 48:return";";case 49:return"-";case 50:return"+";case 51:return"*";case 52:return"/";case 53:return"%";case 54:return"|";case 55:return"EOF"}},rules:[/^(?:(\/\/.*?(\r|\n|$)))/,/^(?:(\s+))/,/^(?:\/)/,/^(?:<(?!=))/,/^(?:)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:(true|false|null|undefined)(\b))/,/^(?:and(\b))/,/^(?:or(\b))/,/^(?:has(\s+)no(\b))/,/^(?:has(\b))/,/^(?:in(\b))/,/^(?:not(\s+)in(\b))/,/^(?:not?(\b))/,/^(?:(asc|desc)(\b))/,/^(?:(\d+\.|\.)?\d+([eE][-+]?\d+)?(\b))/,/^(?:"(?:\\.|[^"])*")/,/^(?:'(?:\\.|[^'])*')/,/^(?:(\/(?:\\.|[^/])+\/i?))/,/^(?:([a-zA-Z_][a-zA-Z_$0-9]*))/,/^(?:\$([a-zA-Z_][a-zA-Z_$0-9]*))/,/^(?:@)/,/^(?:#)/,/^(?:\${2})/,/^(?:\$)/,/^(?:=>)/,/^(?:<(?!=))/,/^(?:=)/,/^(?:!=)/,/^(?:~=)/,/^(?:>=)/,/^(?:<=)/,/^(?:<)/,/^(?:>)/,/^(?:\.\.\()/,/^(?:\.\()/,/^(?:\.\[)/,/^(?:\.\.\.)/,/^(?:\.\.)/,/^(?:\.)/,/^(?:\?)/,/^(?:,)/,/^(?::)/,/^(?:;)/,/^(?:\-)/,/^(?:\+)/,/^(?:\*)/,/^(?:\/)/,/^(?:\%)/,/^(?:\|)/,/^(?:$)/],conditions:{preventPrimitive:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55],inclusive:!0},INITIAL:{rules:[0,1,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55],inclusive:!0}}};function Ie(){this.yy={}}return xe.lexer=Re,Ie.prototype=xe,xe.Parser=Ie,function e(t){function r(e,t){Object.entries(t).forEach(([t,r])=>e[t]=r(e[t]))}const n=new Map([["EOF",["<end of input>"]],["IDENT",["ident"]],["$IDENT",["$ident"]],["FUNCTION_START",["'<'"]],["FUNCTION_END",["'>'"]],["FUNCTION",["'=>'"]],["NOT",["'not'"]],["IN",["'in'"]],["HAS",["'has'"]],["NOTIN",["'not in'"]],["HASNO",["'has no'"]],["AND",["'and'"]],["OR",["'or'"]],["STRING",["string"]],["NUMBER",["number"]],["REGEXP",["regexp"]],["LITERAL",["'true'","'false'","'null'","'undefined'"]],["ORDER",["'asc'","'desc'"]]]),i=e=>n.get(e)||`'${e}'`,a=function(e,t,r){if(!t.recoverable){const e=r.lexer.yylloc,n=[].concat(...t.expected.map(e=>i(e.slice(1,-1)))),a=new SyntaxError(["Parse error on line "+(e.first_line+1)+":","",r.lexer.showPosition(),"","Expecting "+n.join(", ")+" got "+i(t.token)].join("\n"));throw a.details={text:t.text,token:t.token,expected:n,loc:{range:e.range,start:{line:e.first_line,column:e.first_column,offset:e.range[0]},end:{line:e.last_line,column:e.last_column,offset:e.range[1]}}},a}this.trace(e)};Object.assign(t.lexer,{toLiteral:e=>"null"===e?null:"false"!==e&&("true"===e||void 0),toStringLiteral:e=>JSON.parse("'"===e[0]?e.replace(/\\?"/g,'\\"').replace(/\\([^"uU])/g,"$1").replace(/^\'|\'$/g,'"'):e),toRegExp:e=>new RegExp(e.substr(1,e.lastIndexOf("/")-1),e.substr(e.lastIndexOf("/")+1))}),r(t.lexer,{setInput:e=>function(t,r){const n=[];return r.commentRanges=n,r.buildResult=e=>({ast:e,commentRanges:n}),r.parseError=function(...e){return a.call(this,...e,r)},this.fnOpened=0,this.fnOpenedStack=[],this.prevToken=null,this.prevYylloc={first_line:1,last_line:1,first_column:0,last_column:0,range:[0,0]},e.call(this,t,r)}});const s=new t.Parser;s.lexer={...t.lexer},s.yy={...t.yy};const o=["AND","OR","IN","NOTIN","HAS","HASNO"],l=[...o,"NOT","ORDER"],u=["+","-","*","/","%","=","!=","~=",">=","<=","<",">"],c=[null,":",";",",",".","..","FUNCTION",...u,...o,"NOT"],p=new Set([",","?",":",";","EOF","]",")","}",...u,...o,"ORDER"]),h=new Map(c.map(e=>[e,p]));return h.set("{",new Set([","])),h.set("[",new Set([","])),h.set("(",new Set([","])),r(s.lexer,{lex:e=>function t(){this.lex=e;const r=this._input,n=this.lex(this);if(this.lex=t,h.has(this.prevToken)&&h.get(this.prevToken).has(n)){const e={first_line:this.prevYylloc.last_line,last_line:this.yylloc.first_line,first_column:this.prevYylloc.last_column,last_column:this.yylloc.first_column,range:[this.prevYylloc.range[1],this.yylloc.range[0]]};if(this.unput(this.yytext),this.pushState("preventPrimitive"),this.done=!1,this.yytext="_",this.yylloc=this.prevYylloc=e,r!==this._input&&l.includes(n)){const t=r.length-this._input.length-1;switch(r[t]){case" ":case"\t":e.last_column--,e.range[1]--;break;case"\n":{const n=r.lastIndexOf("\n",t-1);e.last_line--,e.last_column=-1===n?e.last_column-1:t-n,e.range[1]--;break}}}return this.prevToken="IDENT"}if(this.prevYylloc=this.yylloc,l.includes(n))switch(this._input[0]){case" ":case"\t":this.prevYylloc={...this.prevYylloc,last_column:this.prevYylloc.last_column+1,range:[this.prevYylloc.range[0],this.prevYylloc.range[1]+1]};break;case"\n":this.prevYylloc={...this.prevYylloc,last_line:this.prevYylloc.last_line+1,last_column:0,range:[this.prevYylloc.range[0],this.prevYylloc.range[1]+1]}}return this.prevToken=n}}),Object.assign((function(e,r){return r?s.parse(e):t.parse(e)}),{generateModule:()=>t.generateModule({moduleName:"module.exports"}).replace("new Parser","("+e+")(new Parser)")})}(new Ie)}(),n={build:()=>({type:"Arg1"}),compile(e,t){t.put(t.scope.arg1?"arguments[1]":"undefined")},walk(){},stringify(e,t){t.put("$$")}},i={build:e=>({type:"Array",elements:e}),suggest(e,t){0===e.elements.length&&t.queryRoot(e.range[0]+1,e.range[1]-1)},compile(e,t){t.put("["),t.list(e.elements,","),t.put("]")},walk(e,t){t.list(e.elements)},stringify(e,t){t.put("["),t.list(e.elements,","),t.put("]")}};const a={in:"in","not in":"in",has:"-","has no":"-",and:"and",or:"or","+":"add","-":"sub","*":"mul","/":"div","%":"mod","=":"eq","!=":"ne","<":"lt","<=":"lte",">":"gt",">=":"gte","~=":"match"};function s(e,t,r){if("Array"===r.type){0===r.elements.length&&e.range([r.range[0]+1,r.range[1]-1],"value-subset",t,r);for(const{type:n,range:i,value:a}of r.elements)i&&("Literal"===n||"Identifier"===n||"GetProperty"===n&&null===a)&&e.range(i,"value-subset",t,r)}}var o={build:(e,t,r)=>({type:"Binary",operator:e,left:t,right:r}),suggest(e,t){switch(e.operator){case"in":t.range(e.left.range,"in-value",e.right,null),s(t,e.left,e.right);break;case"not in":s(t,e.left,e.right);break;case"has":t.range(e.right.range,"in-value",e.left,null),s(t,e.right,e.left);break;case"has no":s(t,e.right,e.left);break;case"=":case"!=":t.range(e.right.range,"value",e.left,null)}},compile(e,t){if(e.operator in a!=!1)switch("and"!==e.operator&&"not in"!==e.operator&&"has no"!==e.operator||t.put("!"),e.operator){case"or":case"and":{const r=t.allocateVar();t.put(`f.bool(${r}=`),t.node(e.left),t.put(`)?${r}:`),t.scope.captureCurrent.disabled=!0,t.node(e.right),t.scope.captureCurrent.disabled=!1;break}case"has":case"has no":t.put("f.in("),t.node(e.right),t.put(","),t.node(e.left),t.put(")");break;default:t.put("f."),t.put(a[e.operator]),t.put("("),t.node(e.left),t.put(","),t.node(e.right),t.put(")")}else t.error('Unknown operator "'+e.operator+'"',e)},walk(e,t){t.node(e.left),t.node(e.right)},stringify(e,t){t.node(e.left),/^[a-z]/i.test(e.operator)?(t.put(" "),t.put(e.operator),t.put(" ")):t.put(e.operator),t.node(e.right)}},l={build:(e,t)=>({type:"Block",definitions:e,body:t}),suggest(e,t){null===e.body&&t.queryRoot(e.range[1])},compile(e,t){e.definitions.length?t.createScope(()=>{t.put("(()=>{"),t.list(e.definitions),t.put("return "),t.nodeOrCurrent(e.body),t.put("})()")},(e,t)=>e+t+";"):e.body&&"Object"===e.body.type?(t.put("("),t.nodeOrCurrent(e.body),t.put(")")):t.nodeOrCurrent(e.body)},walk(e,t){t.list(e.definitions),t.nodeOrNothing(e.body)},stringify(e,t){t.list(e.definitions),t.nodeOrNothing(e.body)}},u={build:(e,t)=>({type:"Compare",query:e,order:t}),compile(e,t){"desc"===e.order&&t.put("-"),t.createScope(()=>{t.put("f.cmp((_q=current=>("),t.node(e.query),t.put("))(a),_q(b))")},(e,t)=>e+t+",")},walk(e,t){t.node(e.query)},stringify(e,t){t.node(e.query),t.put(" "),t.put(e.order)}},c={build:(e,t,r)=>({type:"Conditional",test:e,consequent:t,alternate:r}),compile(e,t){t.put("f.bool("),t.node(e.test),t.scope.captureCurrent.disabled=!0,t.put(")?"),t.node(e.consequent),t.put(":"),t.node(e.alternate),t.scope.captureCurrent.disabled=!1},walk(e,t){t.node(e.test),t.node(e.consequent),t.node(e.alternate)},stringify(e,t){t.node(e.test),t.put("?"),t.node(e.consequent),t.put(":"),t.node(e.alternate)}},p={build:()=>({type:"Context"}),compile(e,t){t.put("context")},walk(){},stringify(e,t){t.put("#")}},h={build:()=>({type:"Current"}),suggest(e,t){e.range&&t.range(e.range,"var")},compile(e,t){t.put("current")},walk(){},stringify(e,t){t.put("$")}},y={build:()=>({type:"Data"}),compile(e,t){t.put("data")},walk(){},stringify(e,t){t.put("@")}},g={build:e=>({type:"Declarator",name:e}),compile(e,t){e.name&&t.put("$"+e.name)},walk(){},stringify(e,t){t.put(e.name?"$"+e.name:"$")}},d={build:(e,t)=>({type:"GetProperty",value:e,property:t}),suggest(e,t){t.range(e.property.range,"path",e.value||void 0,!e.value),null===e.value&&t.range(e.property.range,"var"),e.range&&null===e.value&&e.property.range[0]!==e.range[0]&&t.queryRoot(e.range[0])},compile(e,t){t.put("f.map("),t.nodeOrCurrent(e.value),t.put(","),"Identifier"===e.property.type?t.put(JSON.stringify(e.property.name)):t.node(e.property),t.put(")")},walk(e,t){t.nodeOrNothing(e.value),t.node(e.property)},stringify(e,t){"Identifier"===e.property.type?(t.nodeOrNothing(e.value)&&t.put("."),t.node(e.property)):(t.node(e.value),t.put("["),t.node(e.property),t.put("]"))}},f={build:e=>({type:"Identifier",name:e}),compile(e,t){t.put(e.name)},walk(){},stringify(e,t){t.put(e.name)}};const m=d.build,b=f.build,v=["data","context","ctx","array","idx","index"];var k={build:(e,t)=>({type:"Definition",declarator:e,value:t}),suggest(e,t){null===e.value&&t.range(e.declarator.range,"path")},compile(e,t){if(null===e.declarator.name)return t.node(e.declarator),t.nodeOrCurrent(e.value),void t.put(";");t.scope.own.includes(e.declarator.name)?t.error(`Identifier "$${e.declarator.name}" has already been declared`,e.declarator):v.includes(e.declarator.name)?t.error(`Identifier "$${e.declarator.name}" is reserved for future use`,e.declarator):(t.put("const "),t.node(e.declarator),t.put("="),t.node(e.value||m(null,b(e.declarator.name))),t.put(";"),t.scope.push(e.declarator.name),t.scope.own.push(e.declarator.name))},walk(e,t){t.node(e.declarator),t.nodeOrNothing(e.value)},stringify(e,t){t.node(e.declarator),null!==e.value&&(t.put(":"),t.node(e.value)),t.put(";")}},_={build:(e,t)=>({type:"Filter",value:e,query:t}),compile(e,t){t.put("f.filter("),t.nodeOrCurrent(e.value),t.createScope(()=>{t.put(",current=>"),t.node(e.query)},(e,r)=>(t.put(")"),e+"("+r+",")),t.put(")")},walk(e,t){t.nodeOrNothing(e.value),t.node(e.query)},stringify(e,t){t.nodeOrNothing(e.value),t.put(".["),t.node(e.query),t.put("]")}},$={build:(e,t,r)=>({type:"Function",arguments:e,body:t,legacy:Boolean(r)}),compile(e,t){t.createScope(()=>{t.scope.arg1=!0,t.put("function(current){return "),t.node(e.body),t.put("}")},(e,t)=>e+t+",")},walk(e,t){t.node(e.body)},stringify(e,t){e.legacy?(t.put("<"),t.node(e.body),t.put(">")):(t.put("=>"),t.node(e.body))}},O={build:e=>({type:"Literal",value:e}),compile(e,t){t.put("string"==typeof e.value?JSON.stringify(e.value):String(e.value))},walk(){},stringify(e,t){t.put("string"==typeof e.value?JSON.stringify(e.value):String(e.value))}},S={build:(e,t)=>({type:"Map",value:e,query:t}),compile(e,t){t.put("f.map("),t.nodeOrCurrent(e.value),t.createScope(()=>{t.put(",current=>"),t.node(e.query)},(e,r)=>(t.put(")"),e+"("+r+",")),t.put(")")},walk(e,t){t.nodeOrNothing(e.value),t.node(e.query)},stringify(e,t){t.nodeOrNothing(e.value),t.put(".("),t.node(e.query),t.put(")")}},N={build:(e,t)=>({type:"Method",reference:e,arguments:t}),suggest(e,t){0===e.arguments.length&&t.queryRoot(e.range[1]-1)},compile(e,t,r){t.tolerant&&t.put("(typeof "),"Identifier"===e.reference.type&&t.put("m."),t.node(e.reference),t.tolerant&&(t.put('==="function"?'),"Identifier"===e.reference.type&&t.put("m."),t.node(e.reference)),t.put("("),t.nodeOrCurrent(r),e.arguments.length&&(t.put(","),t.list(e.arguments,",")),t.put(")"),t.tolerant&&t.put(":undefined)")},walk(e,t){t.node(e.reference),t.list(e.arguments)},stringify(e,t){t.node(e.reference),t.put("("),t.list(e.arguments,","),t.put(")")}},w={build:(e,t)=>({type:"MethodCall",value:e,method:t}),compile(e,t){t.node(e.method,e.value)},walk(e,t){t.nodeOrNothing(e.value),t.node(e.method)},stringify(e,t){t.nodeOrNothing(e.value)&&t.put("."),t.node(e.method)}},E={build:e=>({type:"Object",properties:e}),suggest(e,t){0===e.properties.length&&t.queryRoot(e.range[0]+1,e.range[1]-1)},compile(e,t){t.put("{"),t.list(e.properties,","),t.put("}")},walk(e,t){t.list(e.properties)},stringify(e,t){t.put("{"),t.list(e.properties,","),t.put("}")}},A={build:e=>({type:"Parentheses",body:e}),compile(e,t){t.put("("),t.node(e.body),t.put(")")},walk(e,t){t.node(e.body)},stringify(e,t){t.put("("),t.node(e.body),t.put(")")}},x={build:(e,t)=>({type:"Pick",value:e,getter:t}),suggest(e,t){null===e.getter&&t.queryRoot(e.range[1]-1)},compile(e,t){t.put("f.pick("),t.node(e.value),e.getter&&(t.put(","),t.node(e.getter)),t.put(")")},walk(e,t){t.node(e.value),null!==e.getter&&t.node(e.getter)},stringify(e,t){t.node(e.value),t.put("["),null!==e.getter&&t.node(e.getter),t.put("]")}},R={build:(e,t)=>({type:"Pipeline",left:e,right:t}),compile(e,t){t.put("(current=>("),t.node(e.right),t.put("))("),t.node(e.left),t.put(")")},walk(e,t){t.node(e.left),t.node(e.right)},stringify(e,t){t.node(e.left),t.put("|"),t.node(e.right)}};const I=d.build,P=f.build,C=new Set(["Literal","Identifier","Reference","Current"]);const T={Arg1:n,Array:i,Binary:o,Block:l,Compare:u,Conditional:c,Context:p,Current:h,Data:y,Declarator:g,Definition:k,Filter:_,Function:$,GetProperty:d,Identifier:f,Literal:O,Map:S,Method:N,MethodCall:w,Object:E,Parentheses:A,Pick:x,Pipeline:R,Property:{build:(e,t)=>({type:"Property",key:e,value:t}),suggest(e,t){if(null===e.value)switch(e.key.type){case"Identifier":t.range(e.range,"path"),t.range(e.range,"var");break;case"Current":case"Reference":t.range(e.range,"var")}},compile(e,t){let r=e.value;switch(e.key.type){case"Current":return;case"Literal":t.node(e.key);break;case"Identifier":t.node(e.key),r=r||I(null,P(e.key.name));break;case"Reference":t.node(e.key.name),r=r||e.key;break;default:t.put("["),t.node(e.key),t.put("]")}t.put(":"),t.node(r)},walk(e,t){t.node(e.key),t.nodeOrNothing(e.value)},stringify(e,t){if(C.has(e.key.type)){if(t.node(e.key),null===e.value)return}else t.put("["),t.node(e.key),t.put("]");t.put(":"),t.node(e.value)}},Recursive:{build:(e,t)=>({type:"Recursive",value:e,query:t}),compile(e,t){t.put("f.mapRecursive("),t.nodeOrCurrent(e.value),t.createScope(()=>{t.put(",current=>"),t.node(e.query)},(e,r)=>(t.put(")"),e+"("+r+",")),t.put(")")},walk(e,t){t.nodeOrNothing(e.value),t.node(e.query)},stringify(e,t){t.nodeOrNothing(e.value),t.put(".."),t.isSimpleGetPropertyQuery(e.query)||t.isSimpleMethodCallQuery(e.query)?t.node(e.query):(t.put("("),t.node(e.query),t.put(")"))}},Reference:{build:e=>({type:"Reference",name:e}),suggest(e,t){e.range&&t.range(e.range,"var")},compile(e,t){if(!t.scope.includes(e.name.name)&&t.tolerant)return t.put("(typeof $"),t.node(e.name),t.put('!=="undefined"?$'),t.node(e.name),void t.put(":undefined)");t.put("$"),t.node(e.name)},walk(e,t){t.node(e.name)},stringify(e,t){t.put("$"),t.node(e.name)}},SliceNotation:{build:(e,t)=>({type:"SliceNotation",value:e,arguments:t}),compile(e,t){t.put("f.slice("),t.nodeOrCurrent(e.value),e.arguments.slice(0,3).forEach(e=>{t.put(","),e?t.node(e):t.put("undefined")}),t.put(")")},walk(e,t){t.nodeOrNothing(e.value);for(const r of e.arguments.slice(0,3))r&&t.node(r)},stringify(e,t){const[r,n,i]=e.arguments;t.nodeOrNothing(e.value),t.put("["),r&&t.node(r),t.put(":"),n&&t.node(n),i&&(t.put(":"),t.node(i)),t.put("]")}},SortingFunction:{build:e=>({type:"SortingFunction",compares:e}),compile(e,t){t.put("(a, b)=>{let _q;return "),t.list(e.compares,"||"),t.put("||0}")},walk(e,t){t.list(e.compares)},stringify(e,t){t.list(e.compares,",")}},Spread:{build:(e,t=!1)=>({type:"Spread",query:e,array:t}),suggest(e,t){null===e.query&&t.queryRoot(e.range[1])},compile(e,t){if(e.array)return t.put("...f.ensureArray("),t.nodeOrCurrent(e.query),void t.put(")");t.put("..."),t.nodeOrCurrent(e.query)},walk(e,t){t.nodeOrNothing(e.query)},stringify(e,t){t.put("..."),t.nodeOrNothing(e.query)}},Unary:{build:(e,t)=>({type:"Unary",operator:e,argument:t}),compile(e,t){switch(e.operator){case"no":case"not":t.put("!f.bool("),t.node(e.argument),t.put(")");break;case"+":case"-":t.put(e.operator),t.node(e.argument);break;default:t.error('Unknown operator "'+e.operator+'"',e)}},walk(e,t){t.node(e.argument)},stringify(e,t){t.put(e.operator),"-"!==e.operator&&"+"!==e.operator&&t.put(" "),t.node(e.argument)}}},q=e=>new Map(Object.entries(T).map(([t,r])=>[t,r[e]]).filter(([,e])=>"function"==typeof e));var j={nodes:T,build:Object.fromEntries([...q("build").entries()]),compile:q("compile"),walk:q("walk"),stringify:q("stringify"),suggest:q("suggest")};const M=j.walk;var D=function(e,t){function r(e){if(!M.has(e.type))throw new Error("Unknown node type `"+e.type+"`");i(e),M.get(e.type)(e,n),a(e)}const n={node:r,nodeOrNothing(e){null!==e&&r(e)},list(e){e.forEach(r)}};let i=()=>{},a=()=>{};"function"==typeof t&&(t={enter:t}),t&&("function"==typeof t.enter&&(i=t.enter),"function"==typeof t.leave&&(a=t.leave)),r(e)};const F=j.suggest;function L(e,t){return t>=0&&t<e.length&&/[a-zA-Z_$0-9]/.test(e[t])}function U(e,t){const r=e.charCodeAt(t);return 9===r||10===r||13===r||32===r}function B(e,t,r){for(;t<r;t++)if(!U(e,t))return!1;return!0}function G(e,t,r,n,i){const a=[];for(let r=0;r<n.length;r++){const[i,s]=n[r];if(i>=t)break;i<e||(i===e?a.push(e,e):a.push(e,i),e=s)}return e===r.length&&i||a.push(e,t),a}function Y(e,t,r,n){const i=[];for(let a=0;a<e.length;a++){let[s,o,l,u]=e[a];if(B(t,s,o)){for(;s>=0&&U(t,s-1);)s--;for(;o<t.length&&U(t,o);)o++;if(L(t,s-1)){if(s===o)continue;s++}if(L(t,o)){if(s===o)continue;o--}}const c=G(s,o,t,r,n);for(let e=0;e<c.length;e+=2)i.push([c[e],c[e+1],l,u])}return i}var z=function(e,t,r){const n=function(e){let t=null;const r=new Map,n=(e,t)=>{r.has(e)?r.get(e).push(t):r.set(e,[t])},i={range(e,r,i=t,a=!0){n(i,[...e,r,a]),a&&!0!==a&&n(a,[])},queryRoot(e,r=e){n(t,[e,r,"var",!0]),n(t,[e,r,"path",!0])}};return D(e,e=>{if(F.has(e.type)){const r=t;t=e,F.get(e.type)(e,i),t=r}}),r}(e),i=r.length&&r[r.length-1][1]===t.length&&!/[\r\n]$/.test(t);for(const[e,a]of n)n.set(e,Y(a,t,r,i));return n};const H=j.stringify;function J(e){return"GetProperty"===e.type&&((!e.value||"Current"===e.value.type)&&"Identifier"===e.property.type)}function Z(e){return"MethodCall"===e.type&&(!e.value||"Current"===e.value.type)}function Q(e,t){return"Identifier"===t.type&&("Reference"===e.type&&"Identifier"===e.name.type&&t.name===e.name.name)}function V(e,t){return!!J(e)&&e.property.name===t}var X=function(e){function t(e){if(!H.has(e.type))throw new Error("Unknown node type `"+e.type+"`");H.get(e.type)(e,n)}const r=[],n={isSimpleGetPropertyQuery:J,isSimpleMethodCallQuery:Z,isSameIdentifierAndReference:Q,isGetProperty:V,put(e){r.push(e)},node:t,nodeOrNothing(e){if(null!==e)return t(e),!0},list(e,r){r?e.forEach((e,i)=>{i>0&&n.put(r),t(e)}):e.forEach(t)}};return t(e),r.join("")};const W=j.compile;var K=function(e,t=!1,r=null){function n(e){let t;return l.has(e)?t=l.get(e):(o.push(t="s"+o.length),l.set(e,t)),t}function i(e,t,r,n,i){let a=[e,t,JSON.stringify(r)];if("var"===r){if(!h.scope.length)return;a.push(JSON.stringify(h.scope))}else n||o.push(n="s"+o.length),a.push(n),i&&a.push(i);return c.push(a),n}function a(e,t){const r=h.scope,n=p.length;if(h.scope=h.scope.slice(),h.scope.own=[],h.scope.firstCurrent=null,h.scope.captureCurrent=[],h.scope.arg1=r.arg1||!1,e(),h.scope.captureCurrent.length){const e="stat("+h.scope.captureCurrent.reduce((e,t)=>i(...t,e),void 0)+",current)";h.scope.firstCurrent?p[h.scope.firstCurrent]=e:p[n]=t(p[n],e)}h.scope=r}function s(e,t){let a=!1;if(null!==r){if(r.has(e))for(const[t,s,o,l]of r.get(e))"var"===o?i(t,s,o):!0===l?h.scope.captureCurrent.push([t,s,o]):(a||(a=n(e),p.push("stat("+a+",")),o&&i(t,s,o,a,l&&n(l)));"Current"===e.type&&null===h.scope.firstCurrent&&!0!==h.scope.captureCurrent.disabled&&(h.scope.firstCurrent=p.length)}if(!W.has(e.type))throw new Error("Unknown node type `"+e.type+"`");W.get(e.type)(e,h,t),a&&p.push(")")}const o=[],l=new WeakMap,u=[],c=[],p=["const current=data;",{toString:()=>u.length>0?"let "+u+";\n":""},{toString:()=>0===o.length?"":["const stat=(s,v)=>(s.add(v),v);\n","const "+o.map(e=>e+"=new Set()")+";\n"].join("")},"return "],h={tolerant:t,scope:[],createScope:a,error:(e,r)=>{const n=new SyntaxError(e);if(r&&r.range&&(n.details={loc:{range:r.range}}),!t)throw n},allocateVar(){const e="tmp"+u.length;return u.push(e),e},put:e=>p.push(e),node:s,nodeOrNothing(e,t){e&&s(e,t)},nodeOrCurrent(e,t){s(e||{type:"Current"},t)},list(e,t,r){e.forEach((e,n)=>{n>0&&p.push(t),s(e,r)})}};a(()=>s(e),(e,t)=>(p.push(")"),"("+t+","+e)),null!==r&&p.push("\n,["+c.map(e=>"["+e+"]")+"]");try{return new Function("f","m","data","context",p.join(""))}catch(e){const t=p.join(""),r=function(e,t){const r=Object.create(SyntaxError.prototype),n=new Error;return r.name=e,r.message=t,Object.defineProperty(r,"stack",{get:function(){return(n.stack||"").replace(/^(.+\n){1,3}/,e+": "+t+"\n")}}),r}("SyntaxError","Jora query compilation error");throw r.compiledSource=t,r}};const ee=Object.hasOwnProperty,te=Object.prototype.toString;var re={addToSet:function(e,t){return void 0!==t&&(Array.isArray(t)?t.forEach(t=>e.add(t)):e.add(t)),e},getPropertyValue:function(e,t){return e&&ee.call(e,t)?e[t]:void 0},isPlainObject:function(e){return null!==e&&"object"==typeof e&&e.constructor===Object},isRegExp:function(e){return"[object RegExp]"===te.call(e)},isArrayLike:function(e){return e&&ee.call(e,"length")}};const{addToSet:ne,getPropertyValue:ie,isPlainObject:ae,isRegExp:se,isArrayLike:oe}=re;var le=Object.freeze({ensureArray:e=>Array.isArray(e)?e:[e],bool(e){if(Array.isArray(e))return e.length>0;if(ae(e)){for(const t in e)if(hasOwnProperty.call(e,t))return!0;return!1}return Boolean(e)},add:(e,t)=>Array.isArray(e)||Array.isArray(t)?[...new Set([].concat(e,t))]:e+t,sub(e,t){if(Array.isArray(e)){const r=new Set(e);return Array.isArray(t)?t.forEach(e=>r.delete(e)):r.delete(t),[...r]}return e-t},mul:(e,t)=>e*t,div:(e,t)=>e/t,mod:(e,t)=>e%t,eq:(e,t)=>Object.is(e,t),ne:(e,t)=>!Object.is(e,t),lt:(e,t)=>e<t,lte:(e,t)=>e<=t,gt:(e,t)=>e>t,gte:(e,t)=>e>=t,in:(e,t)=>ae(t)?hasOwnProperty.call(t,e):!(!t||"function"!=typeof t.indexOf)&&-1!==t.indexOf(e),cmp:(e,t)=>e>t?1:e<t?-1:0,match(e,t){return"function"==typeof t?this.some(e,t):se(t)?this.some(e,t.test.bind(t)):null==t},pick(e,t=(()=>!0)){if(e){if("function"!=typeof t)return Array.isArray(e)||"string"==typeof e?isFinite(t)?e[t<0?e.length+Number(t):Number(t)||0]:void 0:hasOwnProperty.call(e,t)?e[t]:void 0;if(Array.isArray(e)||"string"==typeof e)for(let r=0;r<e.length;r++)if(t(e[r],r))return e[r];for(const r in e)if(hasOwnProperty.call(e,r)&&t(e[r],r))return e[r]}},map(e,t){const r="function"==typeof t?t:e=>ie(e,t);return Array.isArray(e)?[...e.reduce((e,t)=>ne(e,r(t)),new Set)]:void 0!==e?r(e):e},mapRecursive(e,t){const r=new Set;return ne(r,this.map(e,t)),r.forEach(e=>ne(r,this.map(e,t))),[...r]},some(e,t){return Array.isArray(e)?e.some(e=>this.bool(t(e))):this.bool(t(e))},filter(e,t){return Array.isArray(e)?e.filter(e=>this.bool(t(e))):this.bool(t(e))?e:void 0},slice(e,t=0,r=e&&e.length,n=1){if(!oe(e))return[];if(t=parseInt(t,10)||0,r=parseInt(r,10)||e.length,1!==(n=parseInt(n,10)||1)){const i=[];t=t<0?Math.max(0,e.length+t):Math.min(e.length,t),r=r<0?Math.max(0,e.length+r):Math.min(e.length,r);for(let a=n>0?t:r-1;a>=t&&a<r;a+=n)i.push(e[a]);return i}return"string"==typeof e?e.slice(t,r):Array.prototype.slice.call(e,t,r)}});const{addToSet:ue,isPlainObject:ce}=re;function pe(){}function he(e){return e}function ye(e){return{matched:e.slice(),start:e.index,end:e.index+e[0].length,input:e.input,groups:e.groups||null}}var ge=Object.freeze({bool:le.bool,filter:le.filter,map:le.map,pick:le.pick,keys:e=>Object.keys(e||{}),values(e){const t=new Set;for(const r in e)hasOwnProperty.call(e,r)&&ue(t,e[r]);return[...t]},entries(e){const t=[];for(const r in e)hasOwnProperty.call(e,r)&&t.push({key:r,value:e[r]});return t},fromEntries(e){const t={};return Array.isArray(e)&&e.forEach(e=>{e&&(t[e.key]=e.value)}),t},size:e=>ce(e)?Object.keys(e).length:e&&e.length||0,sort(e,t){let r;return Array.isArray(e)?("function"==typeof t&&(r=2===t.length?t:(e,r)=>{if(e=t(e),r=t(r),Array.isArray(e)&&Array.isArray(r)){if(e.length!==r.length)return e.length<r.length?-1:1;for(let t=0;t<e.length;t++){if(e[t]<r[t])return-1;if(e[t]>r[t])return 1}return 0}return e<r?-1:e>r}),e.slice().sort(r)):e},reverse:e=>Array.isArray(e)?e.slice().reverse():e,slice:(e,t,r)=>le.slice(e,t,r),group(e,t,r){"function"!=typeof t&&(t=pe),"function"!=typeof r&&(r=he),Array.isArray(e)||(e=[e]);const n=new Map,i=[];return e.forEach(e=>{let i=t(e);Array.isArray(i)||(i=[i]),i.forEach(t=>{n.has(t)?n.get(t).add(r(e)):n.set(t,new Set([r(e)]))})}),n.forEach((e,t)=>i.push({key:t,value:[...e]})),i},split:(e,t)=>String(e).split(t),join:(e,t)=>Array.isArray(e)?e.join(t):String(e),match(e,t,r){const n=String(e);if(r){const e=[];let r,i=new RegExp(t,t.flags+"g");for(;r=i.exec(n);)e.push(ye(r));return e}const i=String(e).match(t);return i&&ye(i)},reduce:(e,t,r)=>Array.isArray(e)?void 0!==r?e.reduce((e,r)=>t(r,e),r):e.reduce((e,r)=>t(r,e)):t(e,r)});const{addToSet:de,isPlainObject:fe}=re,me={path:"property",value:"value","in-value":"value","value-subset":"value",var:"variable"};function be(e,t,r,n){const i=[];for(let[a,s,o,l,u=null]of r)if(t>=a&&t<=s&&(n||l.size||l.length)){let r=e.substring(a,s);/\S/.test(r)||(r="",a=s=t),i.push({context:o,current:r,from:a,to:s,values:l,related:u})}return i}var ve=(e,t)=>({stat(r,n){const i=be(e,r,t,n);return i.forEach(e=>{e.values=[...e.values]}),i.length?i:null},suggestion(r,n){const i=be(e,r,t,n),a=[];return i.forEach(e=>{const{context:t,current:r,from:n,to:i,values:s,related:o}=e;a.push(...function(e,t,r){const n=new Set,i=e=>{switch(typeof e){case"string":n.add(JSON.stringify(e));break;case"number":n.add(String(e))}};switch(e){case"":case"path":t.forEach(e=>{Array.isArray(e)?e.forEach(e=>{fe(e)&&de(n,Object.keys(e))}):fe(e)&&de(n,Object.keys(e))});break;case"value":t.forEach(e=>{Array.isArray(e)?e.forEach(i):i(e)});break;case"in-value":t.forEach(e=>{Array.isArray(e)?e.forEach(i):fe(e)?Object.keys(e).forEach(i):i(e)});break;case"var":t.forEach(e=>{n.add("$"+e)});break;case"value-subset":t.forEach(e=>{Array.isArray(e)?e.forEach(i):i(e)}),r.forEach(e=>{e.forEach(e=>{"string"!=typeof e&&"number"!=typeof e||n.delete(JSON.stringify(e))})})}return[...n]}(t,s,o).map(e=>({current:r,type:me[t],value:e,from:n,to:i})))}),a.length?a:null}});var ke,_e=(ke=t)&&ke.default||ke;const{version:$e}=_e,Oe=new Map,Se=new Map,Ne=new Map,we=new Map;function Ee(e,t){console.log(`[${e}]`),"string"==typeof t?console.log(t):void 0!==t&&console.dir(t,{depth:null}),console.log()}return Object.assign((function(e,t){t=t||{};const n=Boolean(t.stat),i=Boolean(t.tolerant),a=t.methods?{...ge,...t.methods}:ge,s=n?i?we:Se:i?Ne:Oe;let o;return e=String(e),s.has(e)&&!t.debug?o=s.get(e):(o=function(e,t,n,i){(i="function"==typeof i?i:!!Boolean(i)&&Ee)&&(i("========================="),i("Compile query from source",e));const a=r(e,n);i&&(i("AST",a.ast),i("Restored source",X(a.ast)));const s=t?z(a.ast,e,a.commentRanges):null;if(i&&s){const t=e=>JSON.stringify(e).slice(1,-1),r=[].concat(...[...s.entries()].map(([e,t])=>t.map(t=>[e,...t])));let n=[],a=null;i("Suggest ranges",r.sort((e,t)=>e[1]-t[1]).map(([r,...i])=>{const[s,o,l,u]=i;let c;if(l){if(s===n[0]&&o===n[1])c=" ".repeat(a.length);else{const r=t(e.slice(0,s)).length,l=t(e.substring(s,o)).length;n=i,a=" ".repeat(r)+(l?"~".repeat(l):"\\")+" "+s+":"+o,c=t(e)+"\n"+a}return c+" ["+l+"] on "+r.type+(!0===u?" (current)":u?" & "+u.type:"")}}).join("\n"))}const o=K(a.ast,n,s);return i&&i("Compiled code",o.toString()),o}(e,n,i,t.debug),s.set(e,o)),n?(t,r)=>ve(e,o(le,a,t,r)):(e,t)=>o(le,a,e,t)}),{version:$e,buildin:le,methods:ge,syntax:{parse:r,walk:D,stringify:X,compile:K}})}));
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).jora=t()}(this,(function(){"use strict";var e={version:"1.0.0-beta.2"},t=Object.freeze({__proto__:null,version:"1.0.0-beta.2",default:e}),r=function(){var e=function(e,t,r,n){for(r=r||{},n=e.length;n--;r[e[n]]=t);return r},t=[2,5],r=[1,13],n=[1,38],i=[1,18],a=[1,7],s=[1,8],o=[1,10],l=[1,11],u=[1,12],c=[1,19],p=[1,20],h=[1,21],y=[1,22],g=[1,23],d=[1,24],f=[1,25],m=[1,28],b=[1,31],v=[1,32],k=[1,33],_=[1,34],$=[1,35],O=[1,36],S=[1,37],N=[5,18,55,58],w=[1,42],A=[1,50],E=[1,49],x=[1,43],R=[1,44],I=[1,45],P=[1,46],C=[1,47],T=[1,48],q=[1,51],j=[1,52],M=[1,53],D=[1,54],F=[1,55],L=[1,56],U=[1,57],B=[1,58],G=[1,59],Y=[1,60],z=[1,61],H=[5,9,14,15,17,18,19,22,23,24,44,45,46,47,48,49,50,53,55,57,58,59,60,61,62,63,66],J=[5,10,11,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,55,58,65,67],Z=[1,62],Q=[1,63],V=[1,64],X=[1,65],W=[1,66],K=[1,67],ee=[1,68],te=[1,71],re=[5,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,53,55,58,59,60,61,62,63,65,67,74],ne=[2,46],ie=[2,48],ae=[1,81],se=[5,10,11,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,53,55,58,59,60,61,62,63,65,67,74],oe=[5,10,11,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,53,55,57,58,59,60,61,62,63,65,67,74],le=[1,88],ue=[1,89],ce=[1,90],pe=[1,105],he=[1,107],ye=[1,108],ge=[1,109],de=[1,110],fe=[1,111],me=[5,10,11,18,21,55,58,65,67],be=[5,10,11,18,21,29,30,41,55,58,65,67],ve=[5,10,11,18,21,23,24,25,26,27,28,29,30,34,35,36,37,38,39,40,41,55,58,65,67],ke=[55,65],_e=[2,99],$e=[11,55],Oe=[65,67],Se=[5,10,11,18,21,25,26,27,28,29,30,41,55,58,65,67],Ne=[5,10,11,18,21,25,26,27,28,29,30,34,35,40,41,55,58,65,67],we=[5,10,11,18,21,25,26,27,28,29,30,34,35,36,37,38,39,40,41,55,58,65,67],Ae=[1,183],Ee=[58,65],xe={trace:function(){},yy:{},symbols_:{error:2,root:3,block:4,EOF:5,definitions:6,e:7,def:8,$:9,";":10,":":11,$ident:12,ident:13,IDENT:14,$IDENT:15,query:16,FUNCTION_START:17,FUNCTION_END:18,FUNCTION:19,sortingCompareList:20,"|":21,NOT:22,"-":23,"+":24,IN:25,HAS:26,NOTIN:27,HASNO:28,AND:29,OR:30,"*":31,"/":32,"%":33,"=":34,"!=":35,"<":36,"<=":37,">":38,">=":39,"~=":40,"?":41,queryRoot:42,relativePath:43,"@":44,"#":45,$$:46,STRING:47,NUMBER:48,REGEXP:49,LITERAL:50,object:51,array:52,"[":53,sliceNotation:54,"]":55,"method()":56,"(":57,")":58,".":59,".(":60,".[":61,"..":62,"..(":63,arguments:64,",":65,"{":66,"}":67,properties:68,property:69,"...":70,arrayElements:71,arrayElement:72,sortingCompare:73,ORDER:74,sliceNotationComponent:75,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",9:"$",10:";",11:":",14:"IDENT",15:"$IDENT",17:"FUNCTION_START",18:"FUNCTION_END",19:"FUNCTION",21:"|",22:"NOT",23:"-",24:"+",25:"IN",26:"HAS",27:"NOTIN",28:"HASNO",29:"AND",30:"OR",31:"*",32:"/",33:"%",34:"=",35:"!=",36:"<",37:"<=",38:">",39:">=",40:"~=",41:"?",44:"@",45:"#",46:"$$",47:"STRING",48:"NUMBER",49:"REGEXP",50:"LITERAL",53:"[",55:"]",57:"(",58:")",59:".",60:".(",61:".[",62:"..",63:"..(",65:",",66:"{",67:"}",70:"...",74:"ORDER"},productions_:[0,[3,2],[4,2],[4,1],[4,1],[4,0],[6,1],[6,2],[8,2],[8,4],[8,2],[8,4],[13,1],[12,1],[7,1],[7,3],[7,2],[7,1],[7,3],[7,4],[7,2],[7,2],[7,2],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,3],[7,5],[16,1],[16,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,1],[42,3],[42,1],[42,1],[42,3],[42,4],[42,2],[42,2],[42,3],[42,3],[42,2],[42,2],[42,3],[43,3],[43,4],[43,4],[43,3],[43,3],[43,4],[43,4],[43,3],[43,3],[43,4],[56,3],[56,4],[56,3],[56,4],[64,1],[64,3],[51,2],[51,3],[68,1],[68,3],[69,1],[69,1],[69,1],[69,3],[69,3],[69,3],[69,3],[69,5],[69,1],[69,2],[71,1],[71,3],[72,1],[72,1],[72,2],[52,2],[52,3],[20,1],[20,3],[73,2],[54,1],[54,2],[54,2],[54,3],[75,1],[75,2]],performAction:function(e,t,r,n,i,a,s){var o=a.length-1;switch(i){case 1:return n.buildResult(a[o-1]);case 2:this.$={type:"Block",definitions:a[o-1],body:a[o],range:this._$.range};break;case 3:this.$={type:"Block",definitions:a[o],body:null,range:this._$.range};break;case 4:this.$={type:"Block",definitions:[],body:a[o],range:this._$.range};break;case 5:this.$={type:"Block",definitions:[],body:null,range:this._$.range};break;case 6:case 81:case 85:case 97:case 104:this.$=[a[o]];break;case 7:a[o-1].push(a[o]);break;case 8:this.$={type:"Definition",declarator:{type:"Declarator",name:null,range:s[o-1].range},value:null,range:this._$.range};break;case 9:this.$={type:"Definition",declarator:{type:"Declarator",name:null,range:s[o-3].range},value:a[o-1],range:this._$.range};break;case 10:this.$={type:"Definition",declarator:{type:"Declarator",name:a[o-1].name,range:s[o-1].range},value:null,range:this._$.range};break;case 11:this.$={type:"Definition",declarator:{type:"Declarator",name:a[o-3].name,range:s[o-3].range},value:a[o-1],range:this._$.range};break;case 12:case 13:this.$={type:"Identifier",name:a[o],range:this._$.range};break;case 14:case 42:case 43:case 53:case 54:case 99:break;case 15:this.$={type:"Function",arguments:[],body:a[o-1],legacy:!0,range:this._$.range};break;case 16:this.$={type:"Function",arguments:[],body:a[o],legacy:!1,range:this._$.range};break;case 17:this.$={type:"SortingFunction",compares:a[o],range:this._$.range};break;case 18:this.$={type:"Pipeline",left:a[o-2],right:a[o],range:this._$.range};break;case 19:this.$={type:"Pipeline",left:a[o-3],right:{type:"Block",definitions:a[o-1],body:a[o]},range:this._$.range};break;case 20:case 21:case 22:this.$={type:"Unary",operator:a[o-1],argument:a[o],range:this._$.range};break;case 23:case 24:case 25:case 26:case 27:case 28:case 29:case 30:case 31:case 32:case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:this.$={type:"Binary",operator:a[o-1],left:a[o-2],right:a[o],range:this._$.range};break;case 41:this.$={type:"Conditional",test:a[o-4],consequent:a[o-2],alternate:a[o],range:this._$.range};break;case 44:this.$={type:"Data",range:this._$.range};break;case 45:this.$={type:"Context",range:this._$.range};break;case 46:this.$={type:"Current",range:this._$.range};break;case 47:this.$={type:"Arg1",range:this._$.range};break;case 48:this.$={type:"Reference",name:a[o],range:this._$.range};break;case 49:case 50:case 51:case 52:this.$={type:"Literal",value:a[o],range:this._$.range};break;case 55:this.$={type:"SliceNotation",value:null,arguments:a[o-1],range:this._$.range};break;case 56:case 60:this.$={type:"GetProperty",value:null,property:a[o],range:this._$.range};break;case 57:case 61:this.$={type:"MethodCall",value:null,method:a[o],range:this._$.range};break;case 58:this.$={type:"Parentheses",body:a[o-1],range:this._$.range};break;case 59:this.$={type:"Parentheses",body:{type:"Block",definitions:a[o-2],body:a[o-1]},range:this._$.range};break;case 62:this.$={type:"Map",value:null,query:a[o-1],range:this._$.range};break;case 63:this.$={type:"Filter",value:null,query:a[o-1],range:this._$.range};break;case 64:this.$={type:"Recursive",value:null,query:{type:"GetProperty",value:null,property:a[o]},range:this._$.range};break;case 65:this.$={type:"Recursive",value:null,query:{type:"MethodCall",value:null,method:a[o]},range:this._$.range};break;case 66:this.$={type:"Recursive",value:null,query:a[o-1],range:this._$.range};break;case 67:this.$={type:"Pick",value:a[o-2],getter:null,range:this._$.range};break;case 68:this.$={type:"Pick",value:a[o-3],getter:a[o-1],range:this._$.range};break;case 69:this.$={type:"SliceNotation",value:a[o-3],arguments:a[o-1],range:this._$.range};break;case 70:this.$={type:"GetProperty",value:a[o-2],property:a[o],range:this._$.range};break;case 71:this.$={type:"MethodCall",value:a[o-2],method:a[o],range:this._$.range};break;case 72:this.$={type:"Map",value:a[o-3],query:a[o-1],range:this._$.range};break;case 73:this.$={type:"Filter",value:a[o-3],query:a[o-1],range:this._$.range};break;case 74:this.$={type:"Recursive",value:a[o-2],query:{type:"GetProperty",value:null,property:a[o]},range:this._$.range};break;case 75:this.$={type:"Recursive",value:a[o-2],query:{type:"MethodCall",value:null,method:a[o]},range:this._$.range};break;case 76:this.$={type:"Recursive",value:a[o-3],query:a[o-1],range:this._$.range};break;case 77:this.$={type:"Method",reference:a[o-2],arguments:[],range:this._$.range};break;case 78:this.$={type:"Method",reference:a[o-3],arguments:a[o-1],range:this._$.range};break;case 79:this.$={type:"Method",reference:{type:"Reference",name:a[o-2]},arguments:[],range:this._$.range};break;case 80:this.$={type:"Method",reference:{type:"Reference",name:a[o-3]},arguments:a[o-1],range:this._$.range};break;case 82:case 86:case 98:case 105:a[o-2].push(a[o]);break;case 83:this.$={type:"Object",properties:[],range:this._$.range};break;case 84:this.$={type:"Object",properties:a[o-1],range:this._$.range};break;case 87:this.$={type:"Property",key:a[o],value:null,range:this._$.range};break;case 88:this.$={type:"Property",key:{type:"Current"},value:null,range:this._$.range};break;case 89:this.$={type:"Property",key:{type:"Reference",name:a[o]},value:null,range:this._$.range};break;case 90:this.$={type:"Property",key:a[o-2],value:a[o],range:this._$.range};break;case 91:case 92:case 93:this.$={type:"Property",key:{type:"Literal",value:a[o-2]},value:a[o],range:this._$.range};break;case 94:this.$={type:"Property",key:a[o-3],value:a[o],range:this._$.range};break;case 95:this.$={type:"Spread",query:null,array:!1,range:this._$.range};break;case 96:this.$={type:"Spread",query:a[o],array:!1,range:this._$.range};break;case 100:this.$={type:"Spread",query:null,array:!0,range:this._$.range};break;case 101:this.$={type:"Spread",query:a[o],array:!0,range:this._$.range};break;case 102:this.$={type:"Array",elements:[],range:this._$.range};break;case 103:this.$={type:"Array",elements:a[o-1],range:this._$.range};break;case 106:this.$={type:"Compare",query:a[o-1],order:a[o],range:this._$.range};break;case 107:this.$=[null,a[o]];break;case 108:this.$=[null,a[o-1],a[o]];break;case 109:this.$=[a[o-1],a[o]];break;case 110:this.$=[a[o-2],a[o-1],a[o]];break;case 111:this.$=null;break;case 112:this.$=a[o]}},table:[{3:1,4:2,5:t,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{1:[3]},{5:[1,39]},e(N,[2,3],{16:6,20:9,12:14,42:15,43:16,73:17,51:26,52:27,13:29,56:30,7:40,8:41,9:r,14:n,15:i,17:a,19:s,22:o,23:l,24:u,44:c,45:p,46:h,47:y,48:g,49:d,50:f,53:m,57:b,59:v,60:k,61:_,62:$,63:O,66:S}),e(N,[2,4],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(H,[2,6]),e(J,[2,14],{53:Z,59:Q,60:V,61:X,62:W,63:K,74:ee}),{4:69,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,18:t,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:70,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e([5,10,11,18,21,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,55,58,67],[2,17],{65:[1,73]}),{7:74,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:75,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:76,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(re,ne,{10:[1,77],11:[1,78]}),e(re,ie,{10:[1,79],11:[1,80],57:ae}),e(se,[2,42]),e(se,[2,43]),e(J,[2,104]),e(oe,[2,13]),e(se,[2,44]),e(se,[2,45]),e(se,[2,47]),e(se,[2,49]),e(se,[2,50]),e(se,[2,51]),e(se,[2,52]),e(se,[2,53]),e(se,[2,54]),{7:86,9:te,11:le,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,54:82,55:[1,83],56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,70:ue,71:84,72:87,73:17,75:85},e(se,[2,56],{57:ce}),e(se,[2,57]),{6:92,7:91,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{12:95,13:93,14:n,15:i,56:94},{4:96,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:t,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{4:97,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,55:t,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{12:95,13:98,14:n,15:i,56:99},{4:100,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:t,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{9:pe,12:106,13:104,14:n,15:i,47:he,48:ye,50:ge,53:de,67:[1,101],68:102,69:103,70:fe},e(oe,[2,12]),{1:[2,1]},e(N,[2,2],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(H,[2,7]),{6:113,7:112,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:114,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:115,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:116,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:117,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:118,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:119,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:120,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:121,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:122,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:123,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:124,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:125,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:126,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:127,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:128,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:129,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:130,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:131,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:132,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:134,9:te,11:le,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,54:135,55:[1,133],56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17,75:85},{12:95,13:136,14:n,15:i,56:137},{4:138,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:t,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{4:139,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,55:t,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{12:95,13:140,14:n,15:i,56:141},{4:142,6:3,7:4,8:5,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:t,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(J,[2,106]),{18:[1,143]},e(me,[2,16],{23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(se,ne),e(se,ie,{57:ae}),{9:te,12:72,13:29,14:n,15:i,16:145,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:144},e(be,[2,20],{23:A,24:E,25:x,26:R,27:I,28:P,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(ve,[2,21],{31:q,32:j,33:M}),e(ve,[2,22],{31:q,32:j,33:M}),e(H,[2,8]),{7:146,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(H,[2,10]),{7:147,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:150,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:[1,148],59:v,60:k,61:_,62:$,63:O,64:149,66:S,73:17},{55:[1,151]},e(se,[2,102]),{55:[1,152],65:[1,153]},{11:le,55:[2,107],75:154},e(ke,_e,{75:155,11:le,21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(ke,[2,97]),e($e,[2,111],{16:6,20:9,42:15,43:16,73:17,51:26,52:27,13:29,56:30,12:72,7:156,9:te,14:n,15:i,17:a,19:s,22:o,23:l,24:u,44:c,45:p,46:h,47:y,48:g,49:d,50:f,53:m,57:b,59:v,60:k,61:_,62:$,63:O,66:S}),e(ke,[2,100],{16:6,20:9,42:15,43:16,73:17,51:26,52:27,13:29,56:30,12:72,7:157,9:te,14:n,15:i,17:a,19:s,22:o,23:l,24:u,44:c,45:p,46:h,47:y,48:g,49:d,50:f,53:m,57:b,59:v,60:k,61:_,62:$,63:O,66:S}),{7:150,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,58:[1,158],59:v,60:k,61:_,62:$,63:O,64:159,66:S,73:17},{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z,58:[1,160]},{7:161,8:41,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(se,[2,60],{57:ce}),e(se,[2,61]),{57:ae},{58:[1,162]},{55:[1,163]},e(se,[2,64],{57:ce}),e(se,[2,65]),{58:[1,164]},e(se,[2,83]),{65:[1,166],67:[1,165]},e(Oe,[2,85]),e(Oe,[2,87],{11:[1,167]}),e(Oe,[2,88]),e(Oe,[2,89]),{11:[1,168]},{11:[1,169]},{11:[1,170]},{7:171,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(Oe,[2,95],{42:15,43:16,51:26,52:27,13:29,56:30,12:72,16:172,9:te,14:n,15:i,44:c,45:p,46:h,47:y,48:g,49:d,50:f,53:m,57:b,59:v,60:k,61:_,62:$,63:O,66:S}),e(me,[2,18],{23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{7:173,8:41,9:r,12:14,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(Se,[2,23],{23:A,24:E,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(Se,[2,24],{23:A,24:E,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(Se,[2,25],{23:A,24:E,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(Se,[2,26],{23:A,24:E,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(be,[2,27],{23:A,24:E,25:x,26:R,27:I,28:P,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e([5,10,11,18,21,30,41,55,58,65,67],[2,28],{23:A,24:E,25:x,26:R,27:I,28:P,29:C,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y}),e(ve,[2,29],{31:q,32:j,33:M}),e(ve,[2,30],{31:q,32:j,33:M}),e(J,[2,31]),e(J,[2,32]),e(J,[2,33]),e(Ne,[2,34],{23:A,24:E,31:q,32:j,33:M,36:L,37:U,38:B,39:G}),e(Ne,[2,35],{23:A,24:E,31:q,32:j,33:M,36:L,37:U,38:B,39:G}),e(we,[2,36],{23:A,24:E,31:q,32:j,33:M}),e(we,[2,37],{23:A,24:E,31:q,32:j,33:M}),e(we,[2,38],{23:A,24:E,31:q,32:j,33:M}),e(we,[2,39],{23:A,24:E,31:q,32:j,33:M}),e(Ne,[2,40],{23:A,24:E,31:q,32:j,33:M,36:L,37:U,38:B,39:G}),{11:[1,174],21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z},e(se,[2,67]),{11:le,21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z,55:[1,175],75:155},{55:[1,176]},e(se,[2,70],{57:ce}),e(se,[2,71]),{58:[1,177]},{55:[1,178]},e(se,[2,74],{57:ce}),e(se,[2,75]),{58:[1,179]},e(J,[2,15]),e(J,[2,105]),{53:Z,59:Q,60:V,61:X,62:W,63:K,74:ee},{10:[1,180],21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z},{10:[1,181],21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z},e(se,[2,79]),{58:[1,182],65:Ae},e(Ee,[2,81],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(se,[2,55]),e(se,[2,103]),{7:185,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,70:ue,72:184,73:17},{55:[2,108]},{11:le,55:[2,109],75:186},e($e,[2,112],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(ke,[2,101],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(se,[2,77]),{58:[1,187],65:Ae},e(se,[2,58]),{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z,58:[1,188]},e(se,[2,62]),e(se,[2,63]),e(se,[2,66]),e(se,[2,84]),{9:pe,12:106,13:104,14:n,15:i,47:he,48:ye,50:ge,53:de,69:189,70:fe},{7:190,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:191,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:192,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{7:193,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z,55:[1,194]},e(Oe,[2,96],{53:Z,59:Q,60:V,61:X,62:W,63:K}),e(me,[2,19],{23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{7:195,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(se,[2,68]),e(se,[2,69]),e(se,[2,72]),e(se,[2,73]),e(se,[2,76]),e(H,[2,9]),e(H,[2,11]),e(se,[2,80]),{7:196,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(ke,[2,98]),e(ke,_e,{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{55:[2,110]},e(se,[2,78]),e(se,[2,59]),e(Oe,[2,86]),e(Oe,[2,90],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(Oe,[2,91],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(Oe,[2,92],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(Oe,[2,93],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{11:[1,197]},e(me,[2,41],{23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),e(Ee,[2,82],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z}),{7:198,9:te,12:72,13:29,14:n,15:i,16:6,17:a,19:s,20:9,22:o,23:l,24:u,42:15,43:16,44:c,45:p,46:h,47:y,48:g,49:d,50:f,51:26,52:27,53:m,56:30,57:b,59:v,60:k,61:_,62:$,63:O,66:S,73:17},e(Oe,[2,94],{21:w,23:A,24:E,25:x,26:R,27:I,28:P,29:C,30:T,31:q,32:j,33:M,34:D,35:F,36:L,37:U,38:B,39:G,40:Y,41:z})],defaultActions:{39:[2,1],154:[2,108],186:[2,110]},parseError:function(e,t){if(!t.recoverable){var r=new Error(e);throw r.hash=t,r}this.trace(e)},parse:function(e){var t=this,r=[0],n=[null],i=[],a=this.table,s="",o=0,l=0,u=2,c=1,p=i.slice.call(arguments,1),h=Object.create(this.lexer),y={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(y.yy[g]=this.yy[g]);h.setInput(e,y.yy),y.yy.lexer=h,y.yy.parser=this,void 0===h.yylloc&&(h.yylloc={});var d=h.yylloc;i.push(d);var f=h.options&&h.options.ranges;"function"==typeof y.yy.parseError?this.parseError=y.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var m,b,v,k,_,$,O,S,N=function(){var e;return"number"!=typeof(e=h.lex()||c)&&(e=t.symbols_[e]||e),e},w={};;){if(b=r[r.length-1],this.defaultActions[b]?v=this.defaultActions[b]:(null==m&&(m=N()),v=a[b]&&a[b][m]),void 0===v||!v.length||!v[0]){var A="";for(_ in S=[],a[b])this.terminals_[_]&&_>u&&S.push("'"+this.terminals_[_]+"'");A=h.showPosition?"Parse error on line "+(o+1)+":\n"+h.showPosition()+"\nExpecting "+S.join(", ")+", got '"+(this.terminals_[m]||m)+"'":"Parse error on line "+(o+1)+": Unexpected "+(m==c?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(A,{text:h.match,token:this.terminals_[m]||m,line:h.yylineno,loc:d,expected:S})}if(v[0]instanceof Array&&v.length>1)throw new Error("Parse Error: multiple actions possible at state: "+b+", token: "+m);switch(v[0]){case 1:r.push(m),n.push(h.yytext),i.push(h.yylloc),r.push(v[1]),m=null,l=h.yyleng,s=h.yytext,o=h.yylineno,d=h.yylloc;break;case 2:if($=this.productions_[v[1]][1],w.$=n[n.length-$],w._$={first_line:i[i.length-($||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-($||1)].first_column,last_column:i[i.length-1].last_column},f&&(w._$.range=[i[i.length-($||1)].range[0],i[i.length-1].range[1]]),void 0!==(k=this.performAction.apply(w,[s,l,o,y.yy,v[1],n,i].concat(p))))return k;$&&(r=r.slice(0,-1*$*2),n=n.slice(0,-1*$),i=i.slice(0,-1*$)),r.push(this.productions_[v[1]][0]),n.push(w.$),i.push(w._$),O=a[r[r.length-2]][r[r.length-1]],r.push(O);break;case 3:return!0}}return!0}},Re={EOF:1,parseError:function(e,t){if(!this.yy.parser)throw new Error(e);this.yy.parser.parseError(e,t)},setInput:function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},unput:function(e){var t=e.length,r=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var n=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),r.length-1&&(this.yylineno-=r.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:r?(r.length===n.length?this.yylloc.first_column:0)+n[n.length-r.length].length-r[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(e){this.unput(this.match.slice(e))},pastInput:function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=new Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},test_match:function(e,t){var r,n,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(n=e[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=n.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:n?n[n.length-1].length-n[n.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],r=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),r)return r;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var e,t,r,n;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((r=this._input.match(this.rules[i[a]]))&&(!t||r[0].length>t[0].length)){if(t=r,n=a,this.options.backtrack_lexer){if(!1!==(e=this.test_match(r,i[a])))return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?!1!==(e=this.test_match(t,i[n]))&&e:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var e=this.next();return e||this.lex()},begin:function(e){this.conditionStack.push(e)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(e){return(e=this.conditionStack.length-1-Math.abs(e||0))>=0?this.conditionStack[e]:"INITIAL"},pushState:function(e){this.begin(e)},stateStackSize:function(){return this.conditionStack.length},options:{ranges:!0},performAction:function(e,t,r,n){switch(r){case 0:e.commentRanges.push(t.yylloc.range);break;case 1:break;case 2:return this.popState(),"/";case 3:return this.popState(),"<";case 4:this.done=!1,this.popState();break;case 5:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,"(";case 6:return this.fnOpened=this.fnOpenedStack.pop()||0,this._input&&this.begin("preventPrimitive"),")";case 7:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,"[";case 8:return this.fnOpened=this.fnOpenedStack.pop()||0,this._input&&this.begin("preventPrimitive"),"]";case 9:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,"{";case 10:return this.fnOpened=this.fnOpenedStack.pop()||0,this._input&&this.begin("preventPrimitive"),"}";case 11:return t.yytext=this.toLiteral(t.yytext),"LITERAL";case 12:return"AND";case 13:return"OR";case 14:return"HASNO";case 15:return"HAS";case 16:return"IN";case 17:return"NOTIN";case 18:return"NOT";case 19:return"ORDER";case 20:return this._input&&this.begin("preventPrimitive"),t.yytext=Number(t.yytext),"NUMBER";case 21:case 22:return this._input&&this.begin("preventPrimitive"),t.yytext=this.toStringLiteral(t.yytext),"STRING";case 23:return this._input&&this.begin("preventPrimitive"),t.yytext=this.toRegExp(t.yytext),"REGEXP";case 24:return this._input&&this.begin("preventPrimitive"),"IDENT";case 25:return this._input&&this.begin("preventPrimitive"),t.yytext=t.yytext.slice(1),"$IDENT";case 26:return this._input&&this.begin("preventPrimitive"),"@";case 27:return this._input&&this.begin("preventPrimitive"),"#";case 28:return this._input&&this.begin("preventPrimitive"),"$$";case 29:return this._input&&this.begin("preventPrimitive"),"$";case 30:return"FUNCTION";case 31:return this.fnOpened++,"FUNCTION_START";case 32:return"=";case 33:return"!=";case 34:return"~=";case 35:return">=";case 36:return"<=";case 37:return"<";case 38:return this.fnOpened?(this.fnOpened--,"FUNCTION_END"):">";case 39:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,"..(";case 40:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,".(";case 41:return this.fnOpenedStack.push(this.fnOpened),this.fnOpened=0,".[";case 42:return"...";case 43:return this._input&&this.begin("preventPrimitive"),"..";case 44:return this._input&&this.begin("preventPrimitive"),".";case 45:return"?";case 46:return",";case 47:return":";case 48:return";";case 49:return"-";case 50:return"+";case 51:return"*";case 52:return"/";case 53:return"%";case 54:return"|";case 55:return"EOF"}},rules:[/^(?:(\/\/.*?(\r|\n|$)))/,/^(?:(\s+))/,/^(?:\/)/,/^(?:<(?!=))/,/^(?:)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:(true|false|null|undefined)(\b))/,/^(?:and(\b))/,/^(?:or(\b))/,/^(?:has(\s+)no(\b))/,/^(?:has(\b))/,/^(?:in(\b))/,/^(?:not(\s+)in(\b))/,/^(?:not?(\b))/,/^(?:(asc|desc)(\b))/,/^(?:(\d+\.|\.)?\d+([eE][-+]?\d+)?(\b))/,/^(?:"(?:\\.|[^"])*")/,/^(?:'(?:\\.|[^'])*')/,/^(?:(\/(?:\\.|[^/])+\/i?))/,/^(?:([a-zA-Z_][a-zA-Z_$0-9]*))/,/^(?:\$([a-zA-Z_][a-zA-Z_$0-9]*))/,/^(?:@)/,/^(?:#)/,/^(?:\${2})/,/^(?:\$)/,/^(?:=>)/,/^(?:<(?!=))/,/^(?:=)/,/^(?:!=)/,/^(?:~=)/,/^(?:>=)/,/^(?:<=)/,/^(?:<)/,/^(?:>)/,/^(?:\.\.\()/,/^(?:\.\()/,/^(?:\.\[)/,/^(?:\.\.\.)/,/^(?:\.\.)/,/^(?:\.)/,/^(?:\?)/,/^(?:,)/,/^(?::)/,/^(?:;)/,/^(?:\-)/,/^(?:\+)/,/^(?:\*)/,/^(?:\/)/,/^(?:\%)/,/^(?:\|)/,/^(?:$)/],conditions:{preventPrimitive:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55],inclusive:!0},INITIAL:{rules:[0,1,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55],inclusive:!0}}};function Ie(){this.yy={}}return xe.lexer=Re,Ie.prototype=xe,xe.Parser=Ie,function e(t){function r(e,t){Object.entries(t).forEach(([t,r])=>e[t]=r(e[t]))}const n=new Map([["EOF",["<end of input>"]],["IDENT",["ident"]],["$IDENT",["$ident"]],["FUNCTION_START",["'<'"]],["FUNCTION_END",["'>'"]],["FUNCTION",["'=>'"]],["NOT",["'not'"]],["IN",["'in'"]],["HAS",["'has'"]],["NOTIN",["'not in'"]],["HASNO",["'has no'"]],["AND",["'and'"]],["OR",["'or'"]],["STRING",["string"]],["NUMBER",["number"]],["REGEXP",["regexp"]],["LITERAL",["'true'","'false'","'null'","'undefined'"]],["ORDER",["'asc'","'desc'"]]]),i=e=>n.get(e)||`'${e}'`,a=function(e,t,r){if(!t.recoverable){const n=r.lexer.yylloc,a=[e.split(/\n/)[0],"",r.lexer.showPosition()],s=Array.isArray(t.expected)?[].concat(...t.expected.map(e=>i(e.slice(1,-1)))):null;s&&a.push("","Expecting "+s.join(", ")+" got "+i(t.token));const o=new SyntaxError(a.join("\n"));throw o.details={rawMessage:e,text:t.text,token:t.token,expected:s,loc:{range:n.range,start:{line:n.first_line,column:n.first_column,offset:n.range[0]},end:{line:n.last_line,column:n.last_column,offset:n.range[1]}}},o}this.trace(e)};Object.assign(t.lexer,{toLiteral:e=>"null"===e?null:"false"!==e&&("true"===e||void 0),toStringLiteral:e=>JSON.parse("'"===e[0]?e.replace(/\\?"/g,'\\"').replace(/\\([^"uU])/g,"$1").replace(/^\'|\'$/g,'"'):e),toRegExp:e=>new RegExp(e.substr(1,e.lastIndexOf("/")-1),e.substr(e.lastIndexOf("/")+1))}),r(t.lexer,{setInput:e=>function(t,r){const n=[];return r.commentRanges=n,r.buildResult=e=>({ast:e,commentRanges:n}),r.parseError=function(...e){return a.call(this,...e,r)},this.fnOpened=0,this.fnOpenedStack=[],this.prevToken=null,this.prevYylloc={first_line:1,last_line:1,first_column:0,last_column:0,range:[0,0]},e.call(this,t,r)}});const s=new t.Parser;s.lexer={...t.lexer},s.yy={...t.yy};const o=["AND","OR","IN","NOTIN","HAS","HASNO"],l=[...o,"NOT","ORDER"],u=["+","-","*","/","%","=","!=","~=",">=","<=","<",">"],c=[null,":",";",",",".","..","FUNCTION",...u,...o,"NOT"],p=new Set([",","?",":",";","EOF","]",")","}",...u,...o,"ORDER"]),h=new Map(c.map(e=>[e,p]));return h.set("{",new Set([","])),h.set("[",new Set([","])),h.set("(",new Set([","])),r(s.lexer,{lex:e=>function t(){this.lex=e;const r=this._input,n=this.lex(this);if(this.lex=t,h.has(this.prevToken)&&h.get(this.prevToken).has(n)){const e={first_line:this.prevYylloc.last_line,last_line:this.yylloc.first_line,first_column:this.prevYylloc.last_column,last_column:this.yylloc.first_column,range:[this.prevYylloc.range[1],this.yylloc.range[0]]};if(this.unput(this.yytext),this.pushState("preventPrimitive"),this.done=!1,this.yytext="_",this.yylloc=this.prevYylloc=e,r!==this._input&&l.includes(n)){const t=r.length-this._input.length-1;switch(r[t]){case" ":case"\t":e.last_column--,e.range[1]--;break;case"\n":{const n=r.lastIndexOf("\n",t-1);e.last_line--,e.last_column=-1===n?e.last_column-1:t-n,e.range[1]--;break}}}return this.prevToken="IDENT"}if(this.prevYylloc=this.yylloc,l.includes(n))switch(this._input[0]){case" ":case"\t":this.prevYylloc={...this.prevYylloc,last_column:this.prevYylloc.last_column+1,range:[this.prevYylloc.range[0],this.prevYylloc.range[1]+1]};break;case"\n":this.prevYylloc={...this.prevYylloc,last_line:this.prevYylloc.last_line+1,last_column:0,range:[this.prevYylloc.range[0],this.prevYylloc.range[1]+1]}}return this.prevToken=n}}),Object.assign((function(e,r){return r?s.parse(e):t.parse(e)}),{generateModule:()=>t.generateModule({moduleName:"module.exports"}).replace("new Parser","("+e+")(new Parser)")})}(new Ie)}(),n={build:()=>({type:"Arg1"}),compile(e,t){t.put(t.scope.arg1?"arguments[1]":"undefined")},walk(){},stringify(e,t){t.put("$$")}},i={build:e=>({type:"Array",elements:e}),suggest(e,t){0===e.elements.length&&t.queryRoot(e.range[0]+1,e.range[1]-1)},compile(e,t){t.put("["),t.list(e.elements,","),t.put("]")},walk(e,t){t.list(e.elements)},stringify(e,t){t.put("["),t.list(e.elements,","),t.put("]")}};const a={in:"in","not in":"in",has:"-","has no":"-",and:"and",or:"or","+":"add","-":"sub","*":"mul","/":"div","%":"mod","=":"eq","!=":"ne","<":"lt","<=":"lte",">":"gt",">=":"gte","~=":"match"};function s(e,t,r){if("Array"===r.type){0===r.elements.length&&e.range([r.range[0]+1,r.range[1]-1],"value-subset",t,r);for(const{type:n,range:i,value:a}of r.elements)i&&("Literal"===n||"Identifier"===n||"GetProperty"===n&&null===a)&&e.range(i,"value-subset",t,r)}}var o={build:(e,t,r)=>({type:"Binary",operator:e,left:t,right:r}),suggest(e,t){switch(e.operator){case"in":t.range(e.left.range,"in-value",e.right,null),s(t,e.left,e.right);break;case"not in":s(t,e.left,e.right);break;case"has":t.range(e.right.range,"in-value",e.left,null),s(t,e.right,e.left);break;case"has no":s(t,e.right,e.left);break;case"=":case"!=":t.range(e.right.range,"value",e.left,null)}},compile(e,t){if(e.operator in a!=!1)switch("and"!==e.operator&&"not in"!==e.operator&&"has no"!==e.operator||t.put("!"),e.operator){case"or":case"and":{const r=t.allocateVar();t.put(`f.bool(${r}=`),t.node(e.left),t.put(`)?${r}:`),t.scope.captureCurrent.disabled=!0,t.node(e.right),t.scope.captureCurrent.disabled=!1;break}case"has":case"has no":t.put("f.in("),t.node(e.right),t.put(","),t.node(e.left),t.put(")");break;default:t.put("f."),t.put(a[e.operator]),t.put("("),t.node(e.left),t.put(","),t.node(e.right),t.put(")")}else t.error('Unknown operator "'+e.operator+'"',e)},walk(e,t){t.node(e.left),t.node(e.right)},stringify(e,t){t.node(e.left),/^[a-z]/i.test(e.operator)?(t.put(" "),t.put(e.operator),t.put(" ")):t.put(e.operator),t.node(e.right)}},l={build:(e,t)=>({type:"Block",definitions:e,body:t}),suggest(e,t){null===e.body&&t.queryRoot(e.range[1])},compile(e,t){e.definitions.length?t.createScope(()=>{t.put("(()=>{"),t.list(e.definitions),t.put("return "),t.nodeOrCurrent(e.body),t.put("})()")},(e,t)=>e+t+";"):e.body&&"Object"===e.body.type?(t.put("("),t.nodeOrCurrent(e.body),t.put(")")):t.nodeOrCurrent(e.body)},walk(e,t){t.list(e.definitions),t.nodeOrNothing(e.body)},stringify(e,t){t.list(e.definitions),t.nodeOrNothing(e.body)}},u={build:(e,t)=>({type:"Compare",query:e,order:t}),compile(e,t){"desc"===e.order&&t.put("-"),t.createScope(()=>{t.put("f.cmp((_q=current=>("),t.node(e.query),t.put("))(a),_q(b))")},(e,t)=>e+t+",")},walk(e,t){t.node(e.query)},stringify(e,t){t.node(e.query),t.put(" "),t.put(e.order)}},c={build:(e,t,r)=>({type:"Conditional",test:e,consequent:t,alternate:r}),compile(e,t){t.put("f.bool("),t.node(e.test),t.scope.captureCurrent.disabled=!0,t.put(")?"),t.node(e.consequent),t.put(":"),t.node(e.alternate),t.scope.captureCurrent.disabled=!1},walk(e,t){t.node(e.test),t.node(e.consequent),t.node(e.alternate)},stringify(e,t){t.node(e.test),t.put("?"),t.node(e.consequent),t.put(":"),t.node(e.alternate)}},p={build:()=>({type:"Context"}),compile(e,t){t.put("context")},walk(){},stringify(e,t){t.put("#")}},h={build:()=>({type:"Current"}),suggest(e,t){e.range&&t.range(e.range,"var")},compile(e,t){t.put("current")},walk(){},stringify(e,t){t.put("$")}},y={build:()=>({type:"Data"}),compile(e,t){t.put("data")},walk(){},stringify(e,t){t.put("@")}},g={build:e=>({type:"Declarator",name:e}),compile(e,t){e.name&&t.put("$"+e.name)},walk(){},stringify(e,t){t.put(e.name?"$"+e.name:"$")}},d={build:(e,t)=>({type:"GetProperty",value:e,property:t}),suggest(e,t){t.range(e.property.range,"path",e.value||void 0,!e.value),null===e.value&&t.range(e.property.range,"var"),e.range&&null===e.value&&e.property.range[0]!==e.range[0]&&t.queryRoot(e.range[0])},compile(e,t){t.put("f.map("),t.nodeOrCurrent(e.value),t.put(","),"Identifier"===e.property.type?t.put(JSON.stringify(e.property.name)):t.node(e.property),t.put(")")},walk(e,t){t.nodeOrNothing(e.value),t.node(e.property)},stringify(e,t){"Identifier"===e.property.type?(t.nodeOrNothing(e.value)&&t.put("."),t.node(e.property)):(t.node(e.value),t.put("["),t.node(e.property),t.put("]"))}},f={build:e=>({type:"Identifier",name:e}),compile(e,t){t.put(e.name)},walk(){},stringify(e,t){t.put(e.name)}};const m=d.build,b=f.build,v=["data","context","ctx","array","idx","index"];var k={build:(e,t)=>({type:"Definition",declarator:e,value:t}),suggest(e,t){null===e.value&&t.range(e.declarator.range,"path")},compile(e,t){if(null===e.declarator.name)return t.node(e.declarator),t.nodeOrCurrent(e.value),void t.put(";");t.scope.own.includes(e.declarator.name)?t.error(`Identifier "$${e.declarator.name}" has already been declared`,e.declarator):v.includes(e.declarator.name)?t.error(`Identifier "$${e.declarator.name}" is reserved for future use`,e.declarator):(t.put("const "),t.node(e.declarator),t.put("="),t.node(e.value||m(null,b(e.declarator.name))),t.put(";"),t.scope.push(e.declarator.name),t.scope.own.push(e.declarator.name))},walk(e,t){t.node(e.declarator),t.nodeOrNothing(e.value)},stringify(e,t){t.node(e.declarator),null!==e.value&&(t.put(":"),t.node(e.value)),t.put(";")}},_={build:(e,t)=>({type:"Filter",value:e,query:t}),compile(e,t){t.put("f.filter("),t.nodeOrCurrent(e.value),t.createScope(()=>{t.put(",current=>"),t.node(e.query)},(e,r)=>(t.put(")"),e+"("+r+",")),t.put(")")},walk(e,t){t.nodeOrNothing(e.value),t.node(e.query)},stringify(e,t){t.nodeOrNothing(e.value),t.put(".["),t.node(e.query),t.put("]")}},$={build:(e,t,r)=>({type:"Function",arguments:e,body:t,legacy:Boolean(r)}),compile(e,t){t.createScope(()=>{t.scope.arg1=!0,t.put("function(current){return "),t.node(e.body),t.put("}")},(e,t)=>e+t+",")},walk(e,t){t.node(e.body)},stringify(e,t){e.legacy?(t.put("<"),t.node(e.body),t.put(">")):(t.put("=>"),t.node(e.body))}},O={build:e=>({type:"Literal",value:e}),compile(e,t){t.put("string"==typeof e.value?JSON.stringify(e.value):String(e.value))},walk(){},stringify(e,t){t.put("string"==typeof e.value?JSON.stringify(e.value):String(e.value))}},S={build:(e,t)=>({type:"Map",value:e,query:t}),compile(e,t){t.put("f.map("),t.nodeOrCurrent(e.value),t.createScope(()=>{t.put(",current=>"),t.node(e.query)},(e,r)=>(t.put(")"),e+"("+r+",")),t.put(")")},walk(e,t){t.nodeOrNothing(e.value),t.node(e.query)},stringify(e,t){t.nodeOrNothing(e.value),t.put(".("),t.node(e.query),t.put(")")}},N={build:(e,t)=>({type:"Method",reference:e,arguments:t}),suggest(e,t){0===e.arguments.length&&t.queryRoot(e.range[1]-1)},compile(e,t,r){t.tolerant&&t.put("(typeof "),"Identifier"===e.reference.type&&t.put("m."),t.node(e.reference),t.tolerant&&(t.put('==="function"?'),"Identifier"===e.reference.type&&t.put("m."),t.node(e.reference)),t.put("("),t.nodeOrCurrent(r),e.arguments.length&&(t.put(","),t.list(e.arguments,",")),t.put(")"),t.tolerant&&t.put(":undefined)")},walk(e,t){t.node(e.reference),t.list(e.arguments)},stringify(e,t){t.node(e.reference),t.put("("),t.list(e.arguments,","),t.put(")")}},w={build:(e,t)=>({type:"MethodCall",value:e,method:t}),compile(e,t){t.node(e.method,e.value)},walk(e,t){t.nodeOrNothing(e.value),t.node(e.method)},stringify(e,t){t.nodeOrNothing(e.value)&&t.put("."),t.node(e.method)}},A={build:e=>({type:"Object",properties:e}),suggest(e,t){0===e.properties.length&&t.queryRoot(e.range[0]+1,e.range[1]-1)},compile(e,t){t.put("{"),t.list(e.properties,","),t.put("}")},walk(e,t){t.list(e.properties)},stringify(e,t){t.put("{"),t.list(e.properties,","),t.put("}")}},E={build:e=>({type:"Parentheses",body:e}),compile(e,t){t.put("("),t.node(e.body),t.put(")")},walk(e,t){t.node(e.body)},stringify(e,t){t.put("("),t.node(e.body),t.put(")")}},x={build:(e,t)=>({type:"Pick",value:e,getter:t}),suggest(e,t){null===e.getter&&t.queryRoot(e.range[1]-1)},compile(e,t){t.put("f.pick("),t.node(e.value),e.getter&&(t.put(","),t.node(e.getter)),t.put(")")},walk(e,t){t.node(e.value),null!==e.getter&&t.node(e.getter)},stringify(e,t){t.node(e.value),t.put("["),null!==e.getter&&t.node(e.getter),t.put("]")}},R={build:(e,t)=>({type:"Pipeline",left:e,right:t}),compile(e,t){t.put("(current=>("),t.node(e.right),t.put("))("),t.node(e.left),t.put(")")},walk(e,t){t.node(e.left),t.node(e.right)},stringify(e,t){t.node(e.left),t.put("|"),t.node(e.right)}};const I=d.build,P=f.build,C=new Set(["Literal","Identifier","Reference","Current"]);const T={Arg1:n,Array:i,Binary:o,Block:l,Compare:u,Conditional:c,Context:p,Current:h,Data:y,Declarator:g,Definition:k,Filter:_,Function:$,GetProperty:d,Identifier:f,Literal:O,Map:S,Method:N,MethodCall:w,Object:A,Parentheses:E,Pick:x,Pipeline:R,Property:{build:(e,t)=>({type:"Property",key:e,value:t}),suggest(e,t){if(null===e.value)switch(e.key.type){case"Identifier":t.range(e.range,"path"),t.range(e.range,"var");break;case"Current":case"Reference":t.range(e.range,"var")}},compile(e,t){let r=e.value;switch(e.key.type){case"Current":return;case"Literal":t.node(e.key);break;case"Identifier":t.node(e.key),r=r||I(null,P(e.key.name));break;case"Reference":t.node(e.key.name),r=r||e.key;break;default:t.put("["),t.node(e.key),t.put("]")}t.put(":"),t.node(r)},walk(e,t){t.node(e.key),t.nodeOrNothing(e.value)},stringify(e,t){if(C.has(e.key.type)){if(t.node(e.key),null===e.value)return}else t.put("["),t.node(e.key),t.put("]");t.put(":"),t.node(e.value)}},Recursive:{build:(e,t)=>({type:"Recursive",value:e,query:t}),compile(e,t){t.put("f.mapRecursive("),t.nodeOrCurrent(e.value),t.createScope(()=>{t.put(",current=>"),t.node(e.query)},(e,r)=>(t.put(")"),e+"("+r+",")),t.put(")")},walk(e,t){t.nodeOrNothing(e.value),t.node(e.query)},stringify(e,t){t.nodeOrNothing(e.value),t.put(".."),t.isSimpleGetPropertyQuery(e.query)||t.isSimpleMethodCallQuery(e.query)?t.node(e.query):(t.put("("),t.node(e.query),t.put(")"))}},Reference:{build:e=>({type:"Reference",name:e}),suggest(e,t){e.range&&t.range(e.range,"var")},compile(e,t){if(!t.scope.includes(e.name.name)&&t.tolerant)return t.put("(typeof $"),t.node(e.name),t.put('!=="undefined"?$'),t.node(e.name),void t.put(":undefined)");t.put("$"),t.node(e.name)},walk(e,t){t.node(e.name)},stringify(e,t){t.put("$"),t.node(e.name)}},SliceNotation:{build:(e,t)=>({type:"SliceNotation",value:e,arguments:t}),compile(e,t){t.put("f.slice("),t.nodeOrCurrent(e.value),e.arguments.slice(0,3).forEach(e=>{t.put(","),e?t.node(e):t.put("undefined")}),t.put(")")},walk(e,t){t.nodeOrNothing(e.value);for(const r of e.arguments.slice(0,3))r&&t.node(r)},stringify(e,t){const[r,n,i]=e.arguments;t.nodeOrNothing(e.value),t.put("["),r&&t.node(r),t.put(":"),n&&t.node(n),i&&(t.put(":"),t.node(i)),t.put("]")}},SortingFunction:{build:e=>({type:"SortingFunction",compares:e}),compile(e,t){t.put("(a, b)=>{let _q;return "),t.list(e.compares,"||"),t.put("||0}")},walk(e,t){t.list(e.compares)},stringify(e,t){t.list(e.compares,",")}},Spread:{build:(e,t=!1)=>({type:"Spread",query:e,array:t}),suggest(e,t){null===e.query&&t.queryRoot(e.range[1])},compile(e,t){if(e.array)return t.put("...f.ensureArray("),t.nodeOrCurrent(e.query),void t.put(")");t.put("..."),t.nodeOrCurrent(e.query)},walk(e,t){t.nodeOrNothing(e.query)},stringify(e,t){t.put("..."),t.nodeOrNothing(e.query)}},Unary:{build:(e,t)=>({type:"Unary",operator:e,argument:t}),compile(e,t){switch(e.operator){case"no":case"not":t.put("!f.bool("),t.node(e.argument),t.put(")");break;case"+":case"-":t.put(e.operator),t.node(e.argument);break;default:t.error('Unknown operator "'+e.operator+'"',e)}},walk(e,t){t.node(e.argument)},stringify(e,t){t.put(e.operator),"-"!==e.operator&&"+"!==e.operator&&t.put(" "),t.node(e.argument)}}},q=e=>new Map(Object.entries(T).map(([t,r])=>[t,r[e]]).filter(([,e])=>"function"==typeof e));var j={nodes:T,build:Object.fromEntries([...q("build").entries()]),compile:q("compile"),walk:q("walk"),stringify:q("stringify"),suggest:q("suggest")};const M=j.walk;var D=function(e,t){function r(e){if(!M.has(e.type))throw new Error("Unknown node type `"+e.type+"`");i(e),M.get(e.type)(e,n),a(e)}const n={node:r,nodeOrNothing(e){null!==e&&r(e)},list(e){e.forEach(r)}};let i=()=>{},a=()=>{};"function"==typeof t&&(t={enter:t}),t&&("function"==typeof t.enter&&(i=t.enter),"function"==typeof t.leave&&(a=t.leave)),r(e)};const F=j.suggest;function L(e,t){return t>=0&&t<e.length&&/[a-zA-Z_$0-9]/.test(e[t])}function U(e,t){const r=e.charCodeAt(t);return 9===r||10===r||13===r||32===r}function B(e,t,r){for(;t<r;t++)if(!U(e,t))return!1;return!0}function G(e,t,r,n,i){const a=[];for(let r=0;r<n.length;r++){const[i,s]=n[r];if(i>=t)break;i<e||(i===e?a.push(e,e):a.push(e,i),e=s)}return e===r.length&&i||a.push(e,t),a}function Y(e,t,r,n){const i=[];for(let a=0;a<e.length;a++){let[s,o,l,u]=e[a];if(B(t,s,o)){for(;s>=0&&U(t,s-1);)s--;for(;o<t.length&&U(t,o);)o++;if(L(t,s-1)){if(s===o)continue;s++}if(L(t,o)){if(s===o)continue;o--}}const c=G(s,o,t,r,n);for(let e=0;e<c.length;e+=2)i.push([c[e],c[e+1],l,u])}return i}var z=function(e,t,r){const n=function(e){let t=null;const r=new Map,n=(e,t)=>{r.has(e)?r.get(e).push(t):r.set(e,[t])},i={range(e,r,i=t,a=!0){n(i,[...e,r,a]),a&&!0!==a&&n(a,[])},queryRoot(e,r=e){n(t,[e,r,"var",!0]),n(t,[e,r,"path",!0])}};return D(e,e=>{if(F.has(e.type)){const r=t;t=e,F.get(e.type)(e,i),t=r}}),r}(e),i=r.length&&r[r.length-1][1]===t.length&&!/[\r\n]$/.test(t);for(const[e,a]of n)n.set(e,Y(a,t,r,i));return n};const H=j.stringify;function J(e){return"GetProperty"===e.type&&((!e.value||"Current"===e.value.type)&&"Identifier"===e.property.type)}function Z(e){return"MethodCall"===e.type&&(!e.value||"Current"===e.value.type)}function Q(e,t){return"Identifier"===t.type&&("Reference"===e.type&&"Identifier"===e.name.type&&t.name===e.name.name)}function V(e,t){return!!J(e)&&e.property.name===t}var X=function(e){function t(e){if(!H.has(e.type))throw new Error("Unknown node type `"+e.type+"`");H.get(e.type)(e,n)}const r=[],n={isSimpleGetPropertyQuery:J,isSimpleMethodCallQuery:Z,isSameIdentifierAndReference:Q,isGetProperty:V,put(e){r.push(e)},node:t,nodeOrNothing(e){if(null!==e)return t(e),!0},list(e,r){r?e.forEach((e,i)=>{i>0&&n.put(r),t(e)}):e.forEach(t)}};return t(e),r.join("")};const W=j.compile;var K=function(e,t=!1,r=null){function n(e){let t;return l.has(e)?t=l.get(e):(o.push(t="s"+o.length),l.set(e,t)),t}function i(e,t,r,n,i){let a=[e,t,JSON.stringify(r)];if("var"===r){if(!h.scope.length)return;a.push(JSON.stringify(h.scope))}else n||o.push(n="s"+o.length),a.push(n),i&&a.push(i);return c.push(a),n}function a(e,t){const r=h.scope,n=p.length;if(h.scope=h.scope.slice(),h.scope.own=[],h.scope.firstCurrent=null,h.scope.captureCurrent=[],h.scope.arg1=r.arg1||!1,e(),h.scope.captureCurrent.length){const e="stat("+h.scope.captureCurrent.reduce((e,t)=>i(...t,e),void 0)+",current)";h.scope.firstCurrent?p[h.scope.firstCurrent]=e:p[n]=t(p[n],e)}h.scope=r}function s(e,t){let a=!1;if(null!==r){if(r.has(e))for(const[t,s,o,l]of r.get(e))"var"===o?i(t,s,o):!0===l?h.scope.captureCurrent.push([t,s,o]):(a||(a=n(e),p.push("stat("+a+",")),o&&i(t,s,o,a,l&&n(l)));"Current"===e.type&&null===h.scope.firstCurrent&&!0!==h.scope.captureCurrent.disabled&&(h.scope.firstCurrent=p.length)}if(!W.has(e.type))throw new Error("Unknown node type `"+e.type+"`");W.get(e.type)(e,h,t),a&&p.push(")")}const o=[],l=new WeakMap,u=[],c=[],p=["const current=data;",{toString:()=>u.length>0?"let "+u+";\n":""},{toString:()=>0===o.length?"":["const stat=(s,v)=>(s.add(v),v);\n","const "+o.map(e=>e+"=new Set()")+";\n"].join("")},"return "],h={tolerant:t,scope:[],createScope:a,error:(e,r)=>{const n=new SyntaxError(e);if(r&&r.range&&(n.details={loc:{range:r.range}}),!t)throw n},allocateVar(){const e="tmp"+u.length;return u.push(e),e},put:e=>p.push(e),node:s,nodeOrNothing(e,t){e&&s(e,t)},nodeOrCurrent(e,t){s(e||{type:"Current"},t)},list(e,t,r){e.forEach((e,n)=>{n>0&&p.push(t),s(e,r)})}};a(()=>s(e),(e,t)=>(p.push(")"),"("+t+","+e)),null!==r&&p.push("\n,["+c.map(e=>"["+e+"]")+"]");try{return new Function("f","m","data","context",p.join(""))}catch(e){const t=p.join(""),r=function(e,t){const r=Object.create(SyntaxError.prototype),n=new Error;return r.name=e,r.message=t,Object.defineProperty(r,"stack",{get:function(){return(n.stack||"").replace(/^(.+\n){1,3}/,e+": "+t+"\n")}}),r}("SyntaxError","Jora query compilation error");throw r.compiledSource=t,r}};const ee=Object.hasOwnProperty,te=Object.prototype.toString;var re={addToSet:function(e,t){return void 0!==t&&(Array.isArray(t)?t.forEach(t=>e.add(t)):e.add(t)),e},getPropertyValue:function(e,t){return e&&ee.call(e,t)?e[t]:void 0},isPlainObject:function(e){return null!==e&&"object"==typeof e&&e.constructor===Object},isRegExp:function(e){return"[object RegExp]"===te.call(e)},isArrayLike:function(e){return e&&ee.call(e,"length")}};const{addToSet:ne,getPropertyValue:ie,isPlainObject:ae,isRegExp:se,isArrayLike:oe}=re;var le=Object.freeze({ensureArray:e=>Array.isArray(e)?e:[e],bool(e){if(Array.isArray(e))return e.length>0;if(ae(e)){for(const t in e)if(hasOwnProperty.call(e,t))return!0;return!1}return Boolean(e)},add:(e,t)=>Array.isArray(e)||Array.isArray(t)?[...new Set([].concat(e,t))]:e+t,sub(e,t){if(Array.isArray(e)){const r=new Set(e);return Array.isArray(t)?t.forEach(e=>r.delete(e)):r.delete(t),[...r]}return e-t},mul:(e,t)=>e*t,div:(e,t)=>e/t,mod:(e,t)=>e%t,eq:(e,t)=>Object.is(e,t),ne:(e,t)=>!Object.is(e,t),lt:(e,t)=>e<t,lte:(e,t)=>e<=t,gt:(e,t)=>e>t,gte:(e,t)=>e>=t,in:(e,t)=>ae(t)?hasOwnProperty.call(t,e):!(!t||"function"!=typeof t.indexOf)&&-1!==t.indexOf(e),cmp:(e,t)=>e>t?1:e<t?-1:0,match(e,t){return"function"==typeof t?this.some(e,t):se(t)?this.some(e,t.test.bind(t)):null==t},pick(e,t=(()=>!0)){if(e){if("function"!=typeof t)return Array.isArray(e)||"string"==typeof e?isFinite(t)?e[t<0?e.length+Number(t):Number(t)||0]:void 0:hasOwnProperty.call(e,t)?e[t]:void 0;if(Array.isArray(e)||"string"==typeof e)for(let r=0;r<e.length;r++)if(t(e[r],r))return e[r];for(const r in e)if(hasOwnProperty.call(e,r)&&t(e[r],r))return e[r]}},map(e,t){const r="function"==typeof t?t:e=>ie(e,t);return Array.isArray(e)?[...e.reduce((e,t)=>ne(e,r(t)),new Set)]:void 0!==e?r(e):e},mapRecursive(e,t){const r=new Set;return ne(r,this.map(e,t)),r.forEach(e=>ne(r,this.map(e,t))),[...r]},some(e,t){return Array.isArray(e)?e.some(e=>this.bool(t(e))):this.bool(t(e))},filter(e,t){return Array.isArray(e)?e.filter(e=>this.bool(t(e))):this.bool(t(e))?e:void 0},slice(e,t=0,r=e&&e.length,n=1){if(!oe(e))return[];if(t=parseInt(t,10)||0,r=parseInt(r,10)||e.length,1!==(n=parseInt(n,10)||1)){const i=[];t=t<0?Math.max(0,e.length+t):Math.min(e.length,t),r=r<0?Math.max(0,e.length+r):Math.min(e.length,r);for(let a=n>0?t:r-1;a>=t&&a<r;a+=n)i.push(e[a]);return i}return"string"==typeof e?e.slice(t,r):Array.prototype.slice.call(e,t,r)}});const{addToSet:ue,isPlainObject:ce}=re;function pe(){}function he(e){return e}function ye(e){return{matched:e.slice(),start:e.index,end:e.index+e[0].length,input:e.input,groups:e.groups||null}}var ge=Object.freeze({bool:le.bool,filter:le.filter,map:le.map,pick:le.pick,keys:e=>Object.keys(e||{}),values(e){const t=new Set;for(const r in e)hasOwnProperty.call(e,r)&&ue(t,e[r]);return[...t]},entries(e){const t=[];for(const r in e)hasOwnProperty.call(e,r)&&t.push({key:r,value:e[r]});return t},fromEntries(e){const t={};return Array.isArray(e)&&e.forEach(e=>{e&&(t[e.key]=e.value)}),t},size:e=>ce(e)?Object.keys(e).length:e&&e.length||0,sort(e,t){let r;return Array.isArray(e)?("function"==typeof t&&(r=2===t.length?t:(e,r)=>{if(e=t(e),r=t(r),Array.isArray(e)&&Array.isArray(r)){if(e.length!==r.length)return e.length<r.length?-1:1;for(let t=0;t<e.length;t++){if(e[t]<r[t])return-1;if(e[t]>r[t])return 1}return 0}return e<r?-1:e>r}),e.slice().sort(r)):e},reverse:e=>Array.isArray(e)?e.slice().reverse():e,slice:(e,t,r)=>le.slice(e,t,r),group(e,t,r){"function"!=typeof t&&(t=pe),"function"!=typeof r&&(r=he),Array.isArray(e)||(e=[e]);const n=new Map,i=[];return e.forEach(e=>{let i=t(e);Array.isArray(i)||(i=[i]),i.forEach(t=>{n.has(t)?n.get(t).add(r(e)):n.set(t,new Set([r(e)]))})}),n.forEach((e,t)=>i.push({key:t,value:[...e]})),i},split:(e,t)=>String(e).split(t),join:(e,t)=>Array.isArray(e)?e.join(t):String(e),match(e,t,r){const n=String(e);if(r){const e=[];let r,i=new RegExp(t,t.flags+"g");for(;r=i.exec(n);)e.push(ye(r));return e}const i=String(e).match(t);return i&&ye(i)},reduce:(e,t,r)=>Array.isArray(e)?void 0!==r?e.reduce((e,r)=>t(r,e),r):e.reduce((e,r)=>t(r,e)):t(e,r)});const{addToSet:de,isPlainObject:fe}=re,me={path:"property",value:"value","in-value":"value","value-subset":"value",var:"variable"};function be(e,t,r,n){const i=[];for(let[a,s,o,l,u=null]of r)if(t>=a&&t<=s&&(n||l.size||l.length)){let r=e.substring(a,s);/\S/.test(r)||(r="",a=s=t),i.push({context:o,current:r,from:a,to:s,values:l,related:u})}return i}var ve=(e,t)=>({stat(r,n){const i=be(e,r,t,n);return i.forEach(e=>{e.values=[...e.values]}),i.length?i:null},suggestion(r,n){const i=be(e,r,t,n),a=[];return i.forEach(e=>{const{context:t,current:r,from:n,to:i,values:s,related:o}=e;a.push(...function(e,t,r){const n=new Set,i=e=>{switch(typeof e){case"string":n.add(JSON.stringify(e));break;case"number":n.add(String(e))}};switch(e){case"":case"path":t.forEach(e=>{Array.isArray(e)?e.forEach(e=>{fe(e)&&de(n,Object.keys(e))}):fe(e)&&de(n,Object.keys(e))});break;case"value":t.forEach(e=>{Array.isArray(e)?e.forEach(i):i(e)});break;case"in-value":t.forEach(e=>{Array.isArray(e)?e.forEach(i):fe(e)?Object.keys(e).forEach(i):i(e)});break;case"var":t.forEach(e=>{n.add("$"+e)});break;case"value-subset":t.forEach(e=>{Array.isArray(e)?e.forEach(i):i(e)}),r.forEach(e=>{e.forEach(e=>{"string"!=typeof e&&"number"!=typeof e||n.delete(JSON.stringify(e))})})}return[...n]}(t,s,o).map(e=>({current:r,type:me[t],value:e,from:n,to:i})))}),a.length?a:null}});var ke,_e=(ke=t)&&ke.default||ke;const{version:$e}=_e,Oe=new Map,Se=new Map,Ne=new Map,we=new Map;function Ae(e,t){console.log(`[${e}]`),"string"==typeof t?console.log(t):void 0!==t&&console.dir(t,{depth:null}),console.log()}return Object.assign((function(e,t){t=t||{};const n=Boolean(t.stat),i=Boolean(t.tolerant),a=t.methods?{...ge,...t.methods}:ge,s=n?i?we:Se:i?Ne:Oe;let o;return e=String(e),s.has(e)&&!t.debug?o=s.get(e):(o=function(e,t,n,i){(i="function"==typeof i?i:!!Boolean(i)&&Ae)&&(i("========================="),i("Compile query from source",e));const a=r(e,n);i&&(i("AST",a.ast),i("Restored source",X(a.ast)));const s=t?z(a.ast,e,a.commentRanges):null;if(i&&s){const t=e=>JSON.stringify(e).slice(1,-1),r=[].concat(...[...s.entries()].map(([e,t])=>t.map(t=>[e,...t])));let n=[],a=null;i("Suggest ranges",r.sort((e,t)=>e[1]-t[1]).map(([r,...i])=>{const[s,o,l,u]=i;let c;if(l){if(s===n[0]&&o===n[1])c=" ".repeat(a.length);else{const r=t(e.slice(0,s)).length,l=t(e.substring(s,o)).length;n=i,a=" ".repeat(r)+(l?"~".repeat(l):"\\")+" "+s+":"+o,c=t(e)+"\n"+a}return c+" ["+l+"] on "+r.type+(!0===u?" (current)":u?" & "+u.type:"")}}).join("\n"))}const o=K(a.ast,n,s);return i&&i("Compiled code",o.toString()),o}(e,n,i,t.debug),s.set(e,o)),n?(t,r)=>ve(e,o(le,a,t,r)):(e,t)=>o(le,a,e,t)}),{version:$e,buildin:le,methods:ge,syntax:{parse:r,walk:D,stringify:X,compile:K}})}));
{
"name": "jora",
"version": "1.0.0-beta.1",
"version": "1.0.0-beta.2",
"description": "JavaScript object query engine",

@@ -5,0 +5,0 @@ "author": "Roman Dvornov <rdvornov@gmail.com> (https://github.com/lahmatiy)",

@@ -942,22 +942,30 @@ /* parser generated by jison 0.4.18 */

const tokenForHumans = token => humanTokens.get(token) || `'${token}'`;
const parseError = function(message, details, yy) {
const parseError = function(rawMessage, details, yy) {
if (details.recoverable) {
this.trace(message);
this.trace(rawMessage);
} else {
const yylloc = yy.lexer.yylloc;
const expected = [].concat(
const message = [
rawMessage.split(/\n/)[0],
'',
yy.lexer.showPosition()
];
const expected = !Array.isArray(details.expected) ? null : [].concat(
...details.expected.map(token => tokenForHumans(token.slice(1, -1)))
);
const error = new SyntaxError([
'Parse error on line ' + (yylloc.first_line + 1) + ':',
'',
yy.lexer.showPosition(),
'',
'Expecting ' + expected.join(', ') + ' got ' + tokenForHumans(details.token)
].join('\n'));
if (expected) {
message.push(
'',
'Expecting ' + expected.join(', ') + ' got ' + tokenForHumans(details.token)
);
}
const error = new SyntaxError(message.join('\n'));
error.details = {
rawMessage: rawMessage,
text: details.text,
token: details.token,
expected: expected,
expected,
loc: {

@@ -964,0 +972,0 @@ range: yylloc.range,

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc