@adaptabletools/adaptable-cjs 17.0.0-canary.4 → 18.0.0-canary.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (288) hide show
  1. package/base.css +62 -14
  2. package/base.css.map +1 -1
  3. package/index.css +267 -165
  4. package/index.css.map +1 -1
  5. package/package.json +5 -4
  6. package/src/AdaptableInterfaces/IAdaptable.d.ts +3 -0
  7. package/src/AdaptableOptions/AdaptableOptions.d.ts +5 -0
  8. package/src/AdaptableOptions/AlertOptions.d.ts +7 -7
  9. package/src/AdaptableOptions/ColumnFilterOptions.d.ts +9 -9
  10. package/src/AdaptableOptions/CommentsOptions.d.ts +28 -0
  11. package/src/AdaptableOptions/EditOptions.d.ts +6 -6
  12. package/src/AdaptableOptions/GridFilterOptions.d.ts +13 -8
  13. package/src/AdaptableOptions/GroupingOptions.d.ts +9 -9
  14. package/src/AdaptableOptions/InteropioPluginOptions.d.ts +10 -0
  15. package/src/AdaptableOptions/MenuOptions.d.ts +18 -4
  16. package/src/AdaptableOptions/MenuOptions.js +14 -6
  17. package/src/AdaptableOptions/NotesOptions.d.ts +2 -9
  18. package/src/Api/AdaptableApi.d.ts +6 -1
  19. package/src/Api/CommentApi.d.ts +58 -0
  20. package/src/Api/EventApi.d.ts +48 -12
  21. package/src/Api/Events/CalculatedColumnChanged.d.ts +19 -0
  22. package/src/Api/Events/CellSelectionChanged.d.ts +11 -0
  23. package/src/Api/Events/CommentsChangedInfo.d.ts +5 -0
  24. package/src/Api/Events/LiveDataChanged.d.ts +3 -3
  25. package/src/Api/Events/RowSelectionChanged.d.ts +11 -0
  26. package/src/Api/GridApi.d.ts +0 -6
  27. package/src/Api/GridFilterApi.d.ts +2 -2
  28. package/src/Api/Implementation/AdaptableApiImpl.d.ts +6 -6
  29. package/src/Api/Implementation/AdaptableApiImpl.js +2 -0
  30. package/src/Api/Implementation/CommentsApiImpl.d.ts +15 -0
  31. package/src/Api/Implementation/CommentsApiImpl.js +46 -0
  32. package/src/Api/Implementation/ExpressionApiImpl.d.ts +1 -1
  33. package/src/Api/Implementation/ExpressionApiImpl.js +3 -4
  34. package/src/Api/Implementation/GridApiImpl.d.ts +0 -1
  35. package/src/Api/Implementation/GridApiImpl.js +0 -4
  36. package/src/Api/Implementation/GridFilterApiImpl.d.ts +1 -1
  37. package/src/Api/Implementation/GridFilterApiImpl.js +1 -1
  38. package/src/Api/Implementation/NotesApiImpl.d.ts +3 -7
  39. package/src/Api/Implementation/NotesApiImpl.js +1 -15
  40. package/src/Api/Implementation/OptionsApiImpl.d.ts +2 -0
  41. package/src/Api/Implementation/OptionsApiImpl.js +3 -0
  42. package/src/Api/Implementation/PluginsApiImpl.d.ts +2 -6
  43. package/src/Api/Implementation/PluginsApiImpl.js +3 -15
  44. package/src/Api/Implementation/ScheduleApiImpl.d.ts +1 -12
  45. package/src/Api/Implementation/ScheduleApiImpl.js +0 -36
  46. package/src/Api/Implementation/ThemeApiImpl.d.ts +1 -0
  47. package/src/Api/Implementation/ThemeApiImpl.js +3 -0
  48. package/src/Api/Internal/ActionRowInternalApi.js +1 -1
  49. package/src/Api/Internal/AdaptableInternalApi.d.ts +2 -0
  50. package/src/Api/Internal/AdaptableInternalApi.js +3 -0
  51. package/src/Api/Internal/CalculatedColumnInternalApi.d.ts +2 -0
  52. package/src/Api/Internal/CalculatedColumnInternalApi.js +16 -0
  53. package/src/Api/Internal/DashboardInternalApi.d.ts +1 -0
  54. package/src/Api/Internal/DashboardInternalApi.js +5 -0
  55. package/src/Api/Internal/DataImportInternalApi.js +2 -0
  56. package/src/Api/Internal/DataSetInternalApi.js +2 -1
  57. package/src/Api/Internal/GridInternalApi.d.ts +3 -1
  58. package/src/Api/Internal/GridInternalApi.js +32 -9
  59. package/src/Api/Internal/LayoutInternalApi.d.ts +2 -2
  60. package/src/Api/Internal/LayoutInternalApi.js +11 -11
  61. package/src/Api/InteropioPluginApi.d.ts +10 -0
  62. package/src/Api/{NotesAPi.d.ts → NotesApi.d.ts} +19 -21
  63. package/src/Api/OptionsApi.d.ts +5 -0
  64. package/src/Api/PluginsApi.d.ts +3 -13
  65. package/src/Api/ScheduleApi.d.ts +1 -48
  66. package/src/Api/ThemeApi.d.ts +5 -0
  67. package/src/PredefinedConfig/AdaptableState.d.ts +4 -2
  68. package/src/PredefinedConfig/CellAddress.d.ts +13 -0
  69. package/src/PredefinedConfig/CellAddress.js +5 -0
  70. package/src/PredefinedConfig/CommentState.d.ts +48 -0
  71. package/src/PredefinedConfig/CommentState.js +2 -0
  72. package/src/PredefinedConfig/Common/AdaptableIcon.d.ts +1 -1
  73. package/src/PredefinedConfig/Common/AdaptablePredicate.js +2 -1
  74. package/src/PredefinedConfig/Common/Enums.d.ts +0 -1
  75. package/src/PredefinedConfig/Common/Enums.js +0 -1
  76. package/src/PredefinedConfig/Common/Schedule.d.ts +1 -1
  77. package/src/PredefinedConfig/Common/Types.d.ts +5 -5
  78. package/src/PredefinedConfig/Common/Types.js +0 -2
  79. package/src/PredefinedConfig/NotesState.d.ts +0 -13
  80. package/src/PredefinedConfig/PredefinedConfig.d.ts +3 -0
  81. package/src/PredefinedConfig/ScheduleState.d.ts +0 -5
  82. package/src/PredefinedConfig/SystemState.d.ts +5 -6
  83. package/src/PredefinedConfig/ThemeState.d.ts +1 -1
  84. package/src/Redux/ActionsReducers/CommentsRedux.d.ts +79 -0
  85. package/src/Redux/ActionsReducers/CommentsRedux.js +189 -0
  86. package/src/Redux/ActionsReducers/NotesRedux.d.ts +1 -1
  87. package/src/Redux/ActionsReducers/NotesRedux.js +4 -5
  88. package/src/Redux/ActionsReducers/PluginsRedux.d.ts +0 -48
  89. package/src/Redux/ActionsReducers/PluginsRedux.js +1 -49
  90. package/src/Redux/ActionsReducers/PlusMinusRedux.d.ts +16 -0
  91. package/src/Redux/ActionsReducers/PlusMinusRedux.js +47 -1
  92. package/src/Redux/ActionsReducers/ScheduleRedux.d.ts +0 -53
  93. package/src/Redux/ActionsReducers/ScheduleRedux.js +2 -90
  94. package/src/Redux/ActionsReducers/SystemRedux.d.ts +23 -12
  95. package/src/Redux/ActionsReducers/SystemRedux.js +55 -23
  96. package/src/Redux/Store/AdaptableStore.d.ts +2 -2
  97. package/src/Redux/Store/AdaptableStore.js +107 -46
  98. package/src/Strategy/CommentsModule.d.ts +16 -0
  99. package/src/Strategy/CommentsModule.js +82 -0
  100. package/src/Strategy/LayoutModule.d.ts +12 -4
  101. package/src/Strategy/LayoutModule.js +19 -14
  102. package/src/Strategy/NotesModule.d.ts +0 -13
  103. package/src/Strategy/NotesModule.js +9 -88
  104. package/src/Strategy/PlusMinusModule.js +2 -0
  105. package/src/Strategy/ScheduleModule.js +0 -23
  106. package/src/Strategy/Utilities/Export/getExportRowsViewItems.d.ts +2 -1
  107. package/src/Strategy/Utilities/Export/getExportRowsViewItems.js +14 -5
  108. package/src/Strategy/Utilities/getExpressionViewItems.js +8 -2
  109. package/src/Utilities/Constants/ConfigConstants.d.ts +1 -0
  110. package/src/Utilities/Constants/ConfigConstants.js +2 -1
  111. package/src/Utilities/Constants/GeneralConstants.d.ts +1 -0
  112. package/src/Utilities/Constants/GeneralConstants.js +8 -3
  113. package/src/Utilities/Constants/ModuleConstants.d.ts +3 -3
  114. package/src/Utilities/Constants/ModuleConstants.js +4 -4
  115. package/src/Utilities/Defaults/DefaultAdaptableOptions.js +3 -3
  116. package/src/Utilities/Defaults/DefaultSettingsPanel.js +1 -0
  117. package/src/Utilities/ExpressionFunctions/aggregatedBooleanExpressionFunctions.js +7 -1
  118. package/src/Utilities/ExpressionFunctions/booleanExpressionFunctions.js +6 -0
  119. package/src/Utilities/ExpressionFunctions/dateUtils.d.ts +1 -0
  120. package/src/Utilities/ExpressionFunctions/dateUtils.js +18 -1
  121. package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.d.ts +1 -1
  122. package/src/Utilities/ExpressionFunctions/scalarExpressionFunctions.js +12 -12
  123. package/src/Utilities/Extensions/ArrayExtensions.d.ts +2 -0
  124. package/src/Utilities/Extensions/ArrayExtensions.js +8 -1
  125. package/src/Utilities/Helpers/PreviewHelper.js +5 -2
  126. package/src/Utilities/ObjectFactory.d.ts +19 -22
  127. package/src/Utilities/ObjectFactory.js +51 -60
  128. package/src/Utilities/Services/CellPopupService.d.ts +23 -0
  129. package/src/Utilities/Services/CellPopupService.js +138 -0
  130. package/src/Utilities/Services/Interface/IReportService.d.ts +1 -1
  131. package/src/Utilities/Services/Interface/IThemeService.d.ts +8 -0
  132. package/src/Utilities/Services/ModuleService.js +1 -3
  133. package/src/Utilities/Services/ReportService.d.ts +1 -1
  134. package/src/Utilities/Services/ThemeService.d.ts +3 -0
  135. package/src/Utilities/Services/ThemeService.js +33 -1
  136. package/src/Utilities/Services/ValidationService.js +11 -11
  137. package/src/View/AdaptableView.js +3 -3
  138. package/src/View/AdaptableViewFactory.js +4 -2
  139. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/ColumnsList.js +2 -2
  140. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/EntitlementsForm.js +1 -1
  141. package/src/View/AdaptableWizardView/AdaptableConfigurationDialog/FinanceForm/FinanceForm.js +1 -1
  142. package/src/View/Alert/Wizard/AlertButtonsEditor.js +2 -2
  143. package/src/View/Alert/Wizard/AlertRulesWizardSection.d.ts +1 -1
  144. package/src/View/Alert/Wizard/AlertRulesWizardSection.js +4 -3
  145. package/src/View/CalculatedColumn/Wizard/CalculatedColumnExpressionWizardSection.js +1 -1
  146. package/src/View/CalculatedColumn/Wizard/CalculatedColumnWizard.js +1 -1
  147. package/src/View/Charting/useChartingElements.js +8 -3
  148. package/src/View/Comments/CommentsEditor.d.ts +7 -0
  149. package/src/View/Comments/CommentsEditor.js +100 -0
  150. package/src/View/Comments/CommentsPopup.d.ts +2 -0
  151. package/src/View/Comments/CommentsPopup.js +87 -0
  152. package/src/View/Components/AdaptableObjectList/AdaptableObjectList.js +2 -1
  153. package/src/View/Components/CellPopup/index.js +1 -1
  154. package/src/View/Components/FilterForm/FilterForm.js +8 -2
  155. package/src/View/Components/FilterForm/ListBoxFilterForm.js +1 -3
  156. package/src/View/Components/FilterForm/QuickFilterForm.js +5 -4
  157. package/src/View/Components/FilterForm/QuickFilterValues.d.ts +2 -2
  158. package/src/View/Components/FilterForm/QuickFilterValues.js +4 -3
  159. package/src/View/Components/Popups/GridCellPopup/GridCellPopup.d.ts +5 -0
  160. package/src/View/Components/Popups/GridCellPopup/GridCellPopup.js +67 -0
  161. package/src/View/Components/Popups/GridCellPopup/index.d.ts +1 -0
  162. package/src/View/Components/Popups/GridCellPopup/index.js +5 -0
  163. package/src/View/Components/Selectors/ColumnSelector.d.ts +1 -0
  164. package/src/View/Components/Selectors/ColumnSelector.js +2 -1
  165. package/src/View/Components/Selectors/PermittedValuesSelector.d.ts +5 -4
  166. package/src/View/Components/Selectors/PermittedValuesSelector.js +25 -3
  167. package/src/View/Components/ToolPanel/ToolPanelWrapper.js +1 -4
  168. package/src/View/Dashboard/ModuleToolbarWrapper.js +1 -1
  169. package/src/View/Dashboard/PinnedDashboard.js +2 -1
  170. package/src/View/DataImport/DataImportWizard/sections/DataPreview.js +2 -2
  171. package/src/View/Export/Wizard/ReportRowsWizardSection.js +3 -1
  172. package/src/View/GridFilter/GridFilterExpressionEditor.js +1 -1
  173. package/src/View/GridFilter/GridFilterPopup.js +10 -8
  174. package/src/View/GridFilter/GridFilterViewPanel.js +51 -14
  175. package/src/View/GridFilter/NamedQuerySelector.js +1 -1
  176. package/src/View/GridFilter/useGridFilterExpressionEditor.d.ts +3 -0
  177. package/src/View/GridFilter/useGridFilterExpressionEditor.js +17 -6
  178. package/src/View/GridFilter/useGridFilterOptionsForExpressionEditor.js +5 -23
  179. package/src/View/GridInfo/GridInfoPopup/GridInfoPopup.js +3 -2
  180. package/src/View/Layout/Wizard/getGridFilterPreview.d.ts +6 -0
  181. package/src/View/Layout/Wizard/getGridFilterPreview.js +16 -0
  182. package/src/View/Layout/Wizard/sections/FilterSection.js +1 -1
  183. package/src/View/Layout/Wizard/sections/GridFilterSection.js +4 -4
  184. package/src/View/NamedQuery/EditCurrentQueryButton.js +1 -1
  185. package/src/View/NamedQuery/Wizard/NamedQueryExpressionWizardSection.js +1 -1
  186. package/src/View/Notes/NoteEditor.d.ts +8 -0
  187. package/src/View/Notes/NoteEditor.js +33 -0
  188. package/src/View/Notes/NotesPopup.d.ts +2 -2
  189. package/src/View/Notes/NotesPopup.js +78 -55
  190. package/src/View/PlusMinus/MovePlusMinus.d.ts +7 -0
  191. package/src/View/PlusMinus/MovePlusMinus.js +27 -0
  192. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsSummary.js +0 -9
  193. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsWizard.js +0 -4
  194. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/isSettingsValid.js +2 -8
  195. package/src/View/Schedule/Wizard/ScheduleWizard.js +0 -8
  196. package/src/View/StyledColumn/Wizard/StyledColumnBadgeSection.js +3 -1
  197. package/src/View/StyledColumn/Wizard/StyledColumnWizard.js +1 -2
  198. package/src/agGrid/Adaptable.d.ts +7 -0
  199. package/src/agGrid/Adaptable.js +49 -35
  200. package/src/agGrid/BadgeRenderer.js +9 -5
  201. package/src/agGrid/agGridHelper.d.ts +2 -1
  202. package/src/agGrid/agGridHelper.js +15 -3
  203. package/src/agGrid/agGridMenuHelper.d.ts +2 -0
  204. package/src/agGrid/agGridMenuHelper.js +73 -25
  205. package/src/components/Datepicker/index.js +4 -4
  206. package/src/components/ExpressionEditor/ExpressionPreview.d.ts +7 -0
  207. package/src/components/ExpressionEditor/ExpressionPreview.js +25 -0
  208. package/src/components/ExpressionEditor/QueryBuilder/QueryBuilder.js +2 -2
  209. package/src/components/ExpressionEditor/QueryBuilder/QueryBuilderInputs.d.ts +6 -0
  210. package/src/components/ExpressionEditor/QueryBuilder/QueryBuilderInputs.js +40 -11
  211. package/src/components/ExpressionEditor/QueryBuilder/QueryPredicateBuilder.js +14 -2
  212. package/src/components/ExpressionEditor/QueryBuilder/booleanExpressions.js +1 -0
  213. package/src/components/ExpressionEditor/QueryBuilder/utils.js +1 -1
  214. package/src/components/ExpressionEditor/index.js +4 -7
  215. package/src/components/InputGroup/InputGroup.d.ts +7 -0
  216. package/src/components/InputGroup/InputGroup.js +12 -0
  217. package/src/components/InputGroup/index.d.ts +1 -0
  218. package/src/components/InputGroup/index.js +4 -0
  219. package/src/components/OverlayTrigger/index.js +7 -2
  220. package/src/components/Select/Select.d.ts +1 -2
  221. package/src/components/Select/Select.js +63 -23
  222. package/src/components/Textarea/index.d.ts +9 -0
  223. package/src/components/Textarea/index.js +50 -2
  224. package/src/components/Toastify/index.d.ts +2 -2
  225. package/src/components/Toastify/index.js +1 -1
  226. package/src/components/icons/comments.d.ts +3 -0
  227. package/src/components/icons/comments.js +7 -0
  228. package/src/components/icons/index.js +3 -1
  229. package/src/env.d.ts +3 -1
  230. package/src/env.js +3 -1
  231. package/src/metamodel/adaptable.metamodel.d.ts +72 -158
  232. package/src/metamodel/adaptable.metamodel.js +138 -260
  233. package/src/parser/src/parser.d.ts +2 -0
  234. package/src/parser/src/parser.js +1880 -705
  235. package/src/parser/src/predicate/mapQlPredicateToExpression.js +5 -2
  236. package/src/parser/src/predicate/types.d.ts +1 -1
  237. package/src/parser/src/types.d.ts +1 -1
  238. package/src/renderReactRoot.js +15 -0
  239. package/src/themes/index.js +4 -0
  240. package/src/types.d.ts +10 -13
  241. package/themes/dark.css +3 -3
  242. package/tsconfig.cjs.tsbuildinfo +1 -1
  243. package/src/AdaptableOptions/FinsemblePluginOptions.d.ts +0 -35
  244. package/src/AdaptableOptions/Glue42PluginOptions.d.ts +0 -25
  245. package/src/AdaptableOptions/Glue42WebPluginOptions.d.ts +0 -10
  246. package/src/Api/Events/SelectionChanged.d.ts +0 -16
  247. package/src/Api/FinsembleApi.d.ts +0 -10
  248. package/src/Api/Glue42Api.d.ts +0 -75
  249. package/src/Api/Glue42WebApi.d.ts +0 -10
  250. package/src/PredefinedConfig/Glue42State.d.ts +0 -46
  251. package/src/View/Notes/NotesListing.d.ts +0 -2
  252. package/src/View/Notes/NotesListing.js +0 -88
  253. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsGlue42.d.ts +0 -9
  254. package/src/View/Schedule/Wizard/ScheduleSettingsWizard/ScheduleSettingsGlue42.js +0 -25
  255. package/src/bundle-dependencies/bundles/react-toastify/components/CloseButton.d.ts +0 -9
  256. package/src/bundle-dependencies/bundles/react-toastify/components/Icons.d.ts +0 -24
  257. package/src/bundle-dependencies/bundles/react-toastify/components/ProgressBar.d.ts +0 -59
  258. package/src/bundle-dependencies/bundles/react-toastify/components/Toast.d.ts +0 -3
  259. package/src/bundle-dependencies/bundles/react-toastify/components/ToastContainer.d.ts +0 -3
  260. package/src/bundle-dependencies/bundles/react-toastify/components/Transitions.d.ts +0 -6
  261. package/src/bundle-dependencies/bundles/react-toastify/components/index.d.ts +0 -6
  262. package/src/bundle-dependencies/bundles/react-toastify/core/eventManager.d.ts +0 -39
  263. package/src/bundle-dependencies/bundles/react-toastify/core/index.d.ts +0 -2
  264. package/src/bundle-dependencies/bundles/react-toastify/core/toast.d.ts +0 -41
  265. package/src/bundle-dependencies/bundles/react-toastify/hooks/index.d.ts +0 -2
  266. package/src/bundle-dependencies/bundles/react-toastify/hooks/useToast.d.ts +0 -10
  267. package/src/bundle-dependencies/bundles/react-toastify/hooks/useToastContainer.d.ts +0 -23
  268. package/src/bundle-dependencies/bundles/react-toastify/index.d.ts +0 -5
  269. package/src/bundle-dependencies/bundles/react-toastify/index.js +0 -1
  270. package/src/bundle-dependencies/bundles/react-toastify/inject-style.d.ts +0 -8
  271. package/src/bundle-dependencies/bundles/react-toastify/types/index.d.ts +0 -269
  272. package/src/bundle-dependencies/bundles/react-toastify/utils/collapseToast.d.ts +0 -5
  273. package/src/bundle-dependencies/bundles/react-toastify/utils/constant.d.ts +0 -23
  274. package/src/bundle-dependencies/bundles/react-toastify/utils/cssTransition.d.ts +0 -43
  275. package/src/bundle-dependencies/bundles/react-toastify/utils/index.d.ts +0 -5
  276. package/src/bundle-dependencies/bundles/react-toastify/utils/mapper.d.ts +0 -2
  277. package/src/bundle-dependencies/bundles/react-toastify/utils/propValidator.d.ts +0 -9
  278. /package/src/AdaptableOptions/{FinsemblePluginOptions.js → CommentsOptions.js} +0 -0
  279. /package/src/AdaptableOptions/{Glue42PluginOptions.js → InteropioPluginOptions.js} +0 -0
  280. /package/src/{AdaptableOptions/Glue42WebPluginOptions.js → Api/CommentApi.js} +0 -0
  281. /package/src/Api/Events/{SelectionChanged.js → CalculatedColumnChanged.js} +0 -0
  282. /package/src/Api/{FinsembleApi.js → Events/CellSelectionChanged.js} +0 -0
  283. /package/src/Api/{Glue42Api.js → Events/CommentsChangedInfo.js} +0 -0
  284. /package/src/Api/{Glue42WebApi.js → Events/RowSelectionChanged.js} +0 -0
  285. /package/src/Api/Internal/{ExpressionnternalApi.d.ts → ExpressionInternalApi.d.ts} +0 -0
  286. /package/src/Api/Internal/{ExpressionnternalApi.js → ExpressionInternalApi.js} +0 -0
  287. /package/src/Api/{NotesAPi.js → InteropioPluginApi.js} +0 -0
  288. /package/src/{PredefinedConfig/Glue42State.js → Api/NotesApi.js} +0 -0
@@ -1,3 +1,6 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //@ts-nocheck
1
4
  /* parser generated by jison 0.4.18 */
2
5
  /*
3
6
  Returns a Parser object of the following structure:
@@ -71,725 +74,1897 @@
71
74
  recoverable: (boolean: TRUE when the parser has a error recovery rule available for this particular error)
72
75
  }
73
76
  */
74
- var parser = (function(){
75
- var o=function(k,v,o,l){for(o=o||{},l=k.length;l--;o[k[l]]=v);return o},$V0=[1,5],$V1=[1,6],$V2=[1,7],$V3=[1,8],$V4=[1,9],$V5=[1,13],$V6=[1,10],$V7=[1,14],$V8=[1,12],$V9=[1,15],$Va=[4,7],$Vb=[1,18],$Vc=[1,19],$Vd=[1,20],$Ve=[1,21],$Vf=[1,22],$Vg=[1,23],$Vh=[1,24],$Vi=[1,25],$Vj=[1,26],$Vk=[1,27],$Vl=[1,28],$Vm=[1,29],$Vn=[1,30],$Vo=[1,31],$Vp=[1,32],$Vq=[1,33],$Vr=[1,34],$Vs=[1,35],$Vt=[1,36],$Vu=[1,37],$Vv=[1,38],$Vw=[4,7,9,15,16,17,18,19,20,21,22,24,25,27,28,29,30,31,32,33,35,36,37,38,40,41,44,45,47,49],$Vx=[9,35],$Vy=[2,6],$Vz=[4,7,9,15,16,21,22,24,25,27,28,29,30,31,32,33,35,36,37,38,40,41,44,45,47,49],$VA=[4,7,9,15,16,17,18,19,21,22,24,25,27,28,29,30,31,32,33,35,36,37,38,40,41,44,45,47,49],$VB=[4,7,9,21,22,24,25,35,41,44,45,47,49],$VC=[4,7,9,21,22,24,25,27,28,29,30,31,32,33,35,36,37,38,40,41,44,45,47,49],$VD=[1,76],$VE=[44,47,49];
76
- var parser = {trace: function trace () { },
77
- yy: {},
78
- symbols_: {"error":2,"program":3,"EOF":4,"expressions":5,"e":6,"NEWLINE":7,"args":8,",":9,"TRUE":10,"FALSE":11,"NUMBER":12,"STRING":13,"COL":14,"+":15,"-":16,"*":17,"/":18,"%":19,"^":20,"|":21,"&":22,"!":23,"?":24,":":25,"case_when":26,"=":27,"!=":28,"<":29,"<=":30,">":31,">=":32,"BETWEEN":33,"(":34,")":35,"STARTS_WITH":36,"ENDS_WITH":37,"CONTAINS":38,"FUNCTION":39,"IN":40,"WHERE":41,"case_expression_value":42,"when_then_list":43,"WHEN":44,"THEN":45,"case_when_else":46,"ELSE":47,"CASE":48,"END":49,"$accept":0,"$end":1},
79
- terminals_: {2:"error",4:"EOF",7:"NEWLINE",9:",",10:"TRUE",11:"FALSE",12:"NUMBER",13:"STRING",14:"COL",15:"+",16:"-",17:"*",18:"/",19:"%",20:"^",21:"|",22:"&",23:"!",24:"?",25:":",27:"=",28:"!=",29:"<",30:"<=",31:">",32:">=",33:"BETWEEN",34:"(",35:")",36:"STARTS_WITH",37:"ENDS_WITH",38:"CONTAINS",39:"FUNCTION",40:"IN",41:"WHERE",44:"WHEN",45:"THEN",47:"ELSE",48:"CASE",49:"END"},
80
- productions_: [0,[3,1],[3,2],[5,1],[5,2],[5,3],[8,0],[8,1],[8,3],[6,1],[6,1],[6,1],[6,1],[6,1],[6,3],[6,3],[6,3],[6,3],[6,3],[6,3],[6,3],[6,3],[6,2],[6,5],[6,1],[6,3],[6,3],[6,3],[6,3],[6,3],[6,3],[6,5],[6,3],[6,3],[6,3],[6,4],[6,2],[6,5],[6,3],[6,3],[42,0],[42,1],[43,4],[43,5],[46,0],[46,2],[26,5]],
81
- performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate /* action[1] */, $$ /* vstack */, _$ /* lstack */) {
82
- /* this == yyval */
83
-
84
- var $0 = $$.length - 1;
85
- switch (yystate) {
86
- case 1:
87
- return [];
88
- break;
89
- case 2:
90
- return $$[$0-1];
91
- break;
92
- case 3: case 7:
93
- this.$ = [$$[$0]];
94
- break;
95
- case 4: case 38:
96
- this.$ = $$[$0-1];
97
- break;
98
- case 5: case 8:
99
- this.$ = $$[$0-2].concat([$$[$0]]);
100
- break;
101
- case 6:
102
- this.$ = [];
103
- break;
104
- case 9:
105
- this.$ = true;
106
- break;
107
- case 10:
108
- this.$ = false;
109
- break;
110
- case 11:
111
- this.$ = Number($$[$0]);
112
- break;
113
- case 12:
114
- this.$ = $$[$0].slice(1, -1);
115
- break;
116
- case 13:
117
- this.$ = yy.node('COL', [$$[$0].slice(1, -1)], this._$, 'COLUMN');
118
- break;
119
- case 14:
120
- this.$ = yy.node('ADD', [$$[$0-2], $$[$0]], this._$, 'INFIX');
121
- break;
122
- case 15:
123
- this.$ = yy.node('SUB', [$$[$0-2], $$[$0]], this._$, 'INFIX');
124
- break;
125
- case 16:
126
- this.$ = yy.node('MUL', [$$[$0-2], $$[$0]], this._$, 'INFIX');
127
- break;
128
- case 17:
129
- this.$ = yy.node('DIV', [$$[$0-2], $$[$0]], this._$, 'INFIX');
130
- break;
131
- case 18:
132
- this.$ = yy.node('MOD', [$$[$0-2], $$[$0]], this._$, 'INFIX');
133
- break;
134
- case 19:
135
- this.$ = yy.node('POW', [$$[$0-2], $$[$0]], this._$, 'INFIX');
136
- break;
137
- case 20:
138
- this.$ = yy.node('OR', [$$[$0-2], $$[$0]], this._$, 'INFIX');
139
- break;
140
- case 21:
141
- this.$ = yy.node('AND', [$$[$0-2], $$[$0]], this._$, 'INFIX');
142
- break;
143
- case 22:
144
- this.$ = yy.node('NOT', [$$[$0]], this._$, 'UNARY');
145
- break;
146
- case 23:
147
- this.$ = yy.node('IF', [$$[$0-4], $$[$0-2], $$[$0]], this._$, 'CONDITIONAL');
148
- break;
149
- case 24: case 41: case 45:
150
- this.$ = $$[$0]
151
- break;
152
- case 25:
153
- this.$ = yy.node('EQ', [$$[$0-2], $$[$0]], this._$, 'INFIX');
154
- break;
155
- case 26:
156
- this.$ = yy.node('NEQ', [$$[$0-2], $$[$0]], this._$, 'INFIX');
157
- break;
158
- case 27:
159
- this.$ = yy.node('LT', [$$[$0-2], $$[$0]], this._$, 'INFIX');
160
- break;
161
- case 28:
162
- this.$ = yy.node('LTE', [$$[$0-2], $$[$0]], this._$, 'INFIX');
163
- break;
164
- case 29:
165
- this.$ = yy.node('GT', [$$[$0-2], $$[$0]], this._$, 'INFIX');
166
- break;
167
- case 30:
168
- this.$ = yy.node('GTE', [$$[$0-2], $$[$0]], this._$, 'INFIX');
169
- break;
170
- case 31:
171
- this.$ = yy.node('BETWEEN', [$$[$0-4], $$[$0-1]], this._$, 'INFIX');
172
- break;
173
- case 32:
174
- this.$ = yy.node('STARTS_WITH', [$$[$0-2], $$[$0]], this._$, 'INFIX');
175
- break;
176
- case 33:
177
- this.$ = yy.node('ENDS_WITH', [$$[$0-2], $$[$0]], this._$, 'INFIX');
178
- break;
179
- case 34:
180
- this.$ = yy.node('CONTAINS', [$$[$0-2], $$[$0]], this._$, 'INFIX');
181
- break;
182
- case 35:
183
- this.$ = yy.node($$[$0-3].toUpperCase(), $$[$0-1], this._$, 'FUNCTION');
184
- break;
185
- case 36:
186
- this.$ = -$$[$0];
187
- break;
188
- case 37:
189
- this.$ = yy.node('IN', [$$[$0-4], $$[$0-1]], this._$, 'INFIX');
190
- break;
191
- case 39:
192
- this.$ = yy.node('WHERE', [$$[$0-2], $$[$0]], this._$, 'INFIX');
193
- break;
194
- case 40: case 44:
195
- this.$ = null
196
- break;
197
- case 42:
198
- this.$ = [ { WHEN: $$[$0-2], THEN: $$[$0] } ]
199
- break;
200
- case 43:
201
- this.$ = $$[$0-4]; this.$.push({ WHEN: $$[$0-2], THEN: $$[$0] });
202
- break;
203
- case 46:
204
- this.$ = yy.node('CASE', [$$[$0-3], $$[$0-2], $$[$0-1]], this._$, 'CONDITIONAL');
205
- break;
206
- }
207
- },
208
- table: [{3:1,4:[1,2],5:3,6:4,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{1:[3]},{1:[2,1]},{4:[1,16],7:[1,17]},o($Va,[2,3],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv}),o($Vw,[2,9]),o($Vw,[2,10]),o($Vw,[2,11]),o($Vw,[2,12]),o($Vw,[2,13]),{6:39,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},o($Vw,[2,24]),{34:[1,40]},{6:41,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:42,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:44,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,42:43,44:[2,40],48:$V9},{1:[2,2]},o($Va,[2,4],{26:11,6:45,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,34:$V7,39:$V8,48:$V9}),{6:46,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:47,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:48,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:49,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:50,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:51,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:52,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:53,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:54,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:55,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:56,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:57,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:58,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:59,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:60,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{34:[1,61]},{6:62,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:63,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:64,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{34:[1,65]},{6:66,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},o($Vw,[2,22]),o($Vx,$Vy,{26:11,8:67,6:68,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,34:$V7,39:$V8,48:$V9}),o($Vw,[2,36]),{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,35:[1,69],36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv},{43:70,44:[1,71]},{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv,44:[2,41]},o($Va,[2,5],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv}),o($Vz,[2,14],{17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($Vz,[2,15],{17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($VA,[2,16],{20:$Vg}),o($VA,[2,17],{20:$Vg}),o($VA,[2,18],{20:$Vg}),o($Vw,[2,19]),o($VB,[2,20],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu}),o($VB,[2,21],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu}),{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,25:[1,72],27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv},o($VC,[2,25],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($VC,[2,26],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($VC,[2,27],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($VC,[2,28],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($VC,[2,29],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($VC,[2,30],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($Vx,$Vy,{26:11,6:68,8:73,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,34:$V7,39:$V8,48:$V9}),o($VC,[2,32],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($VC,[2,33],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($VC,[2,34],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg}),o($Vx,$Vy,{26:11,6:68,8:74,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,34:$V7,39:$V8,48:$V9}),o([4,7,9,24,25,35,41,44,45,47,49],[2,39],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu}),{9:$VD,35:[1,75]},o($Vx,[2,7],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv}),o($Vw,[2,38]),{44:[1,78],46:77,47:[1,79],49:[2,44]},{6:80,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:81,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{9:$VD,35:[1,82]},{9:$VD,35:[1,83]},o($Vw,[2,35]),{6:84,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{49:[1,85]},{6:86,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:87,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv,45:[1,88]},o([4,7,9,25,35,44,45,47,49],[2,23],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv}),o($Vw,[2,31]),o($Vw,[2,37]),o($Vx,[2,8],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv}),o($Vw,[2,46]),{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv,45:[1,89]},{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv,49:[2,45]},{6:90,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},{6:91,10:$V0,11:$V1,12:$V2,13:$V3,14:$V4,16:$V5,23:$V6,26:11,34:$V7,39:$V8,48:$V9},o($VE,[2,42],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv}),o($VE,[2,43],{15:$Vb,16:$Vc,17:$Vd,18:$Ve,19:$Vf,20:$Vg,21:$Vh,22:$Vi,24:$Vj,27:$Vk,28:$Vl,29:$Vm,30:$Vn,31:$Vo,32:$Vp,33:$Vq,36:$Vr,37:$Vs,38:$Vt,40:$Vu,41:$Vv})],
209
- defaultActions: {2:[2,1],16:[2,2]},
210
- parseError: function parseError (str, hash) {
211
- if (hash.recoverable) {
212
- this.trace(str);
213
- } else {
214
- var error = new Error(str);
215
- error.hash = hash;
216
- throw error;
217
- }
218
- },
219
- parse: function parse(input) {
220
- var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = '', yylineno = 0, yyleng = 0, recovering = 0, TERROR = 2, EOF = 1;
221
- var args = lstack.slice.call(arguments, 1);
222
- var lexer = Object.create(this.lexer);
223
- var sharedState = { yy: {} };
224
- for (var k in this.yy) {
225
- if (Object.prototype.hasOwnProperty.call(this.yy, k)) {
226
- sharedState.yy[k] = this.yy[k];
227
- }
228
- }
229
- lexer.setInput(input, sharedState.yy);
230
- sharedState.yy.lexer = lexer;
231
- sharedState.yy.parser = this;
232
- if (typeof lexer.yylloc == 'undefined') {
233
- lexer.yylloc = {};
234
- }
235
- var yyloc = lexer.yylloc;
236
- lstack.push(yyloc);
237
- var ranges = lexer.options && lexer.options.ranges;
238
- if (typeof sharedState.yy.parseError === 'function') {
239
- this.parseError = sharedState.yy.parseError;
240
- } else {
241
- this.parseError = Object.getPrototypeOf(this).parseError;
242
- }
243
- function popStack(n) {
244
- stack.length = stack.length - 2 * n;
245
- vstack.length = vstack.length - n;
246
- lstack.length = lstack.length - n;
247
- }
248
- _token_stack:
249
- var lex = function () {
250
- var token;
251
- token = lexer.lex() || EOF;
252
- if (typeof token !== 'number') {
253
- token = self.symbols_[token] || token;
77
+ var parser = (function () {
78
+ var o = function (k, v, o, l) {
79
+ for (o = o || {}, l = k.length; l--; o[k[l]] = v)
80
+ ;
81
+ return o;
82
+ }, $V0 = [1, 5], $V1 = [1, 6], $V2 = [1, 7], $V3 = [1, 8], $V4 = [1, 9], $V5 = [1, 13], $V6 = [1, 10], $V7 = [1, 14], $V8 = [1, 12], $V9 = [1, 15], $Va = [4, 7], $Vb = [1, 18], $Vc = [1, 19], $Vd = [1, 20], $Ve = [1, 21], $Vf = [1, 22], $Vg = [1, 23], $Vh = [1, 24], $Vi = [1, 25], $Vj = [1, 26], $Vk = [1, 27], $Vl = [1, 28], $Vm = [1, 29], $Vn = [1, 30], $Vo = [1, 31], $Vp = [1, 32], $Vq = [1, 33], $Vr = [1, 34], $Vs = [1, 35], $Vt = [1, 36], $Vu = [1, 37], $Vv = [1, 38], $Vw = [
83
+ 4, 7, 9, 15, 16, 17, 18, 19, 20, 21, 22, 24, 25, 27, 28, 29, 30, 31, 32,
84
+ 33, 35, 36, 37, 38, 40, 41, 44, 45, 47, 49,
85
+ ], $Vx = [9, 35], $Vy = [2, 6], $Vz = [
86
+ 4, 7, 9, 15, 16, 21, 22, 24, 25, 27, 28, 29, 30, 31, 32, 33, 35, 36, 37,
87
+ 38, 40, 41, 44, 45, 47, 49,
88
+ ], $VA = [
89
+ 4, 7, 9, 15, 16, 17, 18, 19, 21, 22, 24, 25, 27, 28, 29, 30, 31, 32, 33,
90
+ 35, 36, 37, 38, 40, 41, 44, 45, 47, 49,
91
+ ], $VB = [4, 7, 9, 21, 22, 24, 25, 35, 41, 44, 45, 47, 49], $VC = [
92
+ 4, 7, 9, 21, 22, 24, 25, 27, 28, 29, 30, 31, 32, 33, 35, 36, 37, 38, 40,
93
+ 41, 44, 45, 47, 49,
94
+ ], $VD = [1, 76], $VE = [44, 47, 49];
95
+ var parser = {
96
+ trace: function trace() { },
97
+ yy: {},
98
+ symbols_: {
99
+ error: 2,
100
+ program: 3,
101
+ EOF: 4,
102
+ expressions: 5,
103
+ e: 6,
104
+ NEWLINE: 7,
105
+ args: 8,
106
+ ',': 9,
107
+ TRUE: 10,
108
+ FALSE: 11,
109
+ NUMBER: 12,
110
+ STRING: 13,
111
+ COL: 14,
112
+ '+': 15,
113
+ '-': 16,
114
+ '*': 17,
115
+ '/': 18,
116
+ '%': 19,
117
+ '^': 20,
118
+ '|': 21,
119
+ '&': 22,
120
+ '!': 23,
121
+ '?': 24,
122
+ ':': 25,
123
+ case_when: 26,
124
+ '=': 27,
125
+ '!=': 28,
126
+ '<': 29,
127
+ '<=': 30,
128
+ '>': 31,
129
+ '>=': 32,
130
+ BETWEEN: 33,
131
+ '(': 34,
132
+ ')': 35,
133
+ STARTS_WITH: 36,
134
+ ENDS_WITH: 37,
135
+ CONTAINS: 38,
136
+ FUNCTION: 39,
137
+ IN: 40,
138
+ WHERE: 41,
139
+ case_expression_value: 42,
140
+ when_then_list: 43,
141
+ WHEN: 44,
142
+ THEN: 45,
143
+ case_when_else: 46,
144
+ ELSE: 47,
145
+ CASE: 48,
146
+ END: 49,
147
+ $accept: 0,
148
+ $end: 1,
149
+ },
150
+ terminals_: {
151
+ 2: 'error',
152
+ 4: 'EOF',
153
+ 7: 'NEWLINE',
154
+ 9: ',',
155
+ 10: 'TRUE',
156
+ 11: 'FALSE',
157
+ 12: 'NUMBER',
158
+ 13: 'STRING',
159
+ 14: 'COL',
160
+ 15: '+',
161
+ 16: '-',
162
+ 17: '*',
163
+ 18: '/',
164
+ 19: '%',
165
+ 20: '^',
166
+ 21: '|',
167
+ 22: '&',
168
+ 23: '!',
169
+ 24: '?',
170
+ 25: ':',
171
+ 27: '=',
172
+ 28: '!=',
173
+ 29: '<',
174
+ 30: '<=',
175
+ 31: '>',
176
+ 32: '>=',
177
+ 33: 'BETWEEN',
178
+ 34: '(',
179
+ 35: ')',
180
+ 36: 'STARTS_WITH',
181
+ 37: 'ENDS_WITH',
182
+ 38: 'CONTAINS',
183
+ 39: 'FUNCTION',
184
+ 40: 'IN',
185
+ 41: 'WHERE',
186
+ 44: 'WHEN',
187
+ 45: 'THEN',
188
+ 47: 'ELSE',
189
+ 48: 'CASE',
190
+ 49: 'END',
191
+ },
192
+ productions_: [
193
+ 0,
194
+ [3, 1],
195
+ [3, 2],
196
+ [5, 1],
197
+ [5, 2],
198
+ [5, 3],
199
+ [8, 0],
200
+ [8, 1],
201
+ [8, 3],
202
+ [6, 1],
203
+ [6, 1],
204
+ [6, 1],
205
+ [6, 1],
206
+ [6, 1],
207
+ [6, 3],
208
+ [6, 3],
209
+ [6, 3],
210
+ [6, 3],
211
+ [6, 3],
212
+ [6, 3],
213
+ [6, 3],
214
+ [6, 3],
215
+ [6, 2],
216
+ [6, 5],
217
+ [6, 1],
218
+ [6, 3],
219
+ [6, 3],
220
+ [6, 3],
221
+ [6, 3],
222
+ [6, 3],
223
+ [6, 3],
224
+ [6, 5],
225
+ [6, 3],
226
+ [6, 3],
227
+ [6, 3],
228
+ [6, 4],
229
+ [6, 2],
230
+ [6, 5],
231
+ [6, 3],
232
+ [6, 3],
233
+ [42, 0],
234
+ [42, 1],
235
+ [43, 4],
236
+ [43, 5],
237
+ [46, 0],
238
+ [46, 2],
239
+ [26, 5],
240
+ ],
241
+ performAction: function anonymous(yytext, yyleng, yylineno, yy, yystate /* action[1] */, $$ /* vstack */, _$ /* lstack */) {
242
+ /* this == yyval */
243
+ var $0 = $$.length - 1;
244
+ switch (yystate) {
245
+ case 1:
246
+ return [];
247
+ break;
248
+ case 2:
249
+ return $$[$0 - 1];
250
+ break;
251
+ case 3:
252
+ case 7:
253
+ this.$ = [$$[$0]];
254
+ break;
255
+ case 4:
256
+ case 38:
257
+ this.$ = $$[$0 - 1];
258
+ break;
259
+ case 5:
260
+ case 8:
261
+ this.$ = $$[$0 - 2].concat([$$[$0]]);
262
+ break;
263
+ case 6:
264
+ this.$ = [];
265
+ break;
266
+ case 9:
267
+ this.$ = true;
268
+ break;
269
+ case 10:
270
+ this.$ = false;
271
+ break;
272
+ case 11:
273
+ this.$ = Number($$[$0]);
274
+ break;
275
+ case 12:
276
+ this.$ = $$[$0].slice(1, -1);
277
+ break;
278
+ case 13:
279
+ this.$ = yy.node('COL', [$$[$0].slice(1, -1)], this._$, 'COLUMN');
280
+ break;
281
+ case 14:
282
+ this.$ = yy.node('ADD', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
283
+ break;
284
+ case 15:
285
+ this.$ = yy.node('SUB', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
286
+ break;
287
+ case 16:
288
+ this.$ = yy.node('MUL', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
289
+ break;
290
+ case 17:
291
+ this.$ = yy.node('DIV', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
292
+ break;
293
+ case 18:
294
+ this.$ = yy.node('MOD', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
295
+ break;
296
+ case 19:
297
+ this.$ = yy.node('POW', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
298
+ break;
299
+ case 20:
300
+ this.$ = yy.node('OR', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
301
+ break;
302
+ case 21:
303
+ this.$ = yy.node('AND', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
304
+ break;
305
+ case 22:
306
+ this.$ = yy.node('NOT', [$$[$0]], this._$, 'UNARY');
307
+ break;
308
+ case 23:
309
+ this.$ = yy.node('IF', [$$[$0 - 4], $$[$0 - 2], $$[$0]], this._$, 'CONDITIONAL');
310
+ break;
311
+ case 24:
312
+ case 41:
313
+ case 45:
314
+ this.$ = $$[$0];
315
+ break;
316
+ case 25:
317
+ this.$ = yy.node('EQ', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
318
+ break;
319
+ case 26:
320
+ this.$ = yy.node('NEQ', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
321
+ break;
322
+ case 27:
323
+ this.$ = yy.node('LT', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
324
+ break;
325
+ case 28:
326
+ this.$ = yy.node('LTE', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
327
+ break;
328
+ case 29:
329
+ this.$ = yy.node('GT', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
330
+ break;
331
+ case 30:
332
+ this.$ = yy.node('GTE', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
333
+ break;
334
+ case 31:
335
+ this.$ = yy.node('BETWEEN', [$$[$0 - 4], $$[$0 - 1]], this._$, 'INFIX');
336
+ break;
337
+ case 32:
338
+ this.$ = yy.node('STARTS_WITH', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
339
+ break;
340
+ case 33:
341
+ this.$ = yy.node('ENDS_WITH', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
342
+ break;
343
+ case 34:
344
+ this.$ = yy.node('CONTAINS', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
345
+ break;
346
+ case 35:
347
+ this.$ = yy.node($$[$0 - 3].toUpperCase(), $$[$0 - 1], this._$, 'FUNCTION');
348
+ break;
349
+ case 36:
350
+ this.$ = -$$[$0];
351
+ break;
352
+ case 37:
353
+ this.$ = yy.node('IN', [$$[$0 - 4], $$[$0 - 1]], this._$, 'INFIX');
354
+ break;
355
+ case 39:
356
+ this.$ = yy.node('WHERE', [$$[$0 - 2], $$[$0]], this._$, 'INFIX');
357
+ break;
358
+ case 40:
359
+ case 44:
360
+ this.$ = null;
361
+ break;
362
+ case 42:
363
+ this.$ = [{ WHEN: $$[$0 - 2], THEN: $$[$0] }];
364
+ break;
365
+ case 43:
366
+ this.$ = $$[$0 - 4];
367
+ this.$.push({ WHEN: $$[$0 - 2], THEN: $$[$0] });
368
+ break;
369
+ case 46:
370
+ this.$ = yy.node('CASE', [$$[$0 - 3], $$[$0 - 2], $$[$0 - 1]], this._$, 'CONDITIONAL');
371
+ break;
254
372
  }
255
- return token;
256
- };
257
- var symbol, preErrorSymbol, state, action, a, r, yyval = {}, p, len, newState, expected;
258
- while (true) {
259
- state = stack[stack.length - 1];
260
- if (this.defaultActions[state]) {
261
- action = this.defaultActions[state];
262
- } else {
263
- if (symbol === null || typeof symbol == 'undefined') {
264
- symbol = lex();
373
+ },
374
+ table: [
375
+ {
376
+ 3: 1,
377
+ 4: [1, 2],
378
+ 5: 3,
379
+ 6: 4,
380
+ 10: $V0,
381
+ 11: $V1,
382
+ 12: $V2,
383
+ 13: $V3,
384
+ 14: $V4,
385
+ 16: $V5,
386
+ 23: $V6,
387
+ 26: 11,
388
+ 34: $V7,
389
+ 39: $V8,
390
+ 48: $V9,
391
+ },
392
+ { 1: [3] },
393
+ { 1: [2, 1] },
394
+ { 4: [1, 16], 7: [1, 17] },
395
+ o($Va, [2, 3], {
396
+ 15: $Vb,
397
+ 16: $Vc,
398
+ 17: $Vd,
399
+ 18: $Ve,
400
+ 19: $Vf,
401
+ 20: $Vg,
402
+ 21: $Vh,
403
+ 22: $Vi,
404
+ 24: $Vj,
405
+ 27: $Vk,
406
+ 28: $Vl,
407
+ 29: $Vm,
408
+ 30: $Vn,
409
+ 31: $Vo,
410
+ 32: $Vp,
411
+ 33: $Vq,
412
+ 36: $Vr,
413
+ 37: $Vs,
414
+ 38: $Vt,
415
+ 40: $Vu,
416
+ 41: $Vv,
417
+ }),
418
+ o($Vw, [2, 9]),
419
+ o($Vw, [2, 10]),
420
+ o($Vw, [2, 11]),
421
+ o($Vw, [2, 12]),
422
+ o($Vw, [2, 13]),
423
+ {
424
+ 6: 39,
425
+ 10: $V0,
426
+ 11: $V1,
427
+ 12: $V2,
428
+ 13: $V3,
429
+ 14: $V4,
430
+ 16: $V5,
431
+ 23: $V6,
432
+ 26: 11,
433
+ 34: $V7,
434
+ 39: $V8,
435
+ 48: $V9,
436
+ },
437
+ o($Vw, [2, 24]),
438
+ { 34: [1, 40] },
439
+ {
440
+ 6: 41,
441
+ 10: $V0,
442
+ 11: $V1,
443
+ 12: $V2,
444
+ 13: $V3,
445
+ 14: $V4,
446
+ 16: $V5,
447
+ 23: $V6,
448
+ 26: 11,
449
+ 34: $V7,
450
+ 39: $V8,
451
+ 48: $V9,
452
+ },
453
+ {
454
+ 6: 42,
455
+ 10: $V0,
456
+ 11: $V1,
457
+ 12: $V2,
458
+ 13: $V3,
459
+ 14: $V4,
460
+ 16: $V5,
461
+ 23: $V6,
462
+ 26: 11,
463
+ 34: $V7,
464
+ 39: $V8,
465
+ 48: $V9,
466
+ },
467
+ {
468
+ 6: 44,
469
+ 10: $V0,
470
+ 11: $V1,
471
+ 12: $V2,
472
+ 13: $V3,
473
+ 14: $V4,
474
+ 16: $V5,
475
+ 23: $V6,
476
+ 26: 11,
477
+ 34: $V7,
478
+ 39: $V8,
479
+ 42: 43,
480
+ 44: [2, 40],
481
+ 48: $V9,
482
+ },
483
+ { 1: [2, 2] },
484
+ o($Va, [2, 4], {
485
+ 26: 11,
486
+ 6: 45,
487
+ 10: $V0,
488
+ 11: $V1,
489
+ 12: $V2,
490
+ 13: $V3,
491
+ 14: $V4,
492
+ 16: $V5,
493
+ 23: $V6,
494
+ 34: $V7,
495
+ 39: $V8,
496
+ 48: $V9,
497
+ }),
498
+ {
499
+ 6: 46,
500
+ 10: $V0,
501
+ 11: $V1,
502
+ 12: $V2,
503
+ 13: $V3,
504
+ 14: $V4,
505
+ 16: $V5,
506
+ 23: $V6,
507
+ 26: 11,
508
+ 34: $V7,
509
+ 39: $V8,
510
+ 48: $V9,
511
+ },
512
+ {
513
+ 6: 47,
514
+ 10: $V0,
515
+ 11: $V1,
516
+ 12: $V2,
517
+ 13: $V3,
518
+ 14: $V4,
519
+ 16: $V5,
520
+ 23: $V6,
521
+ 26: 11,
522
+ 34: $V7,
523
+ 39: $V8,
524
+ 48: $V9,
525
+ },
526
+ {
527
+ 6: 48,
528
+ 10: $V0,
529
+ 11: $V1,
530
+ 12: $V2,
531
+ 13: $V3,
532
+ 14: $V4,
533
+ 16: $V5,
534
+ 23: $V6,
535
+ 26: 11,
536
+ 34: $V7,
537
+ 39: $V8,
538
+ 48: $V9,
539
+ },
540
+ {
541
+ 6: 49,
542
+ 10: $V0,
543
+ 11: $V1,
544
+ 12: $V2,
545
+ 13: $V3,
546
+ 14: $V4,
547
+ 16: $V5,
548
+ 23: $V6,
549
+ 26: 11,
550
+ 34: $V7,
551
+ 39: $V8,
552
+ 48: $V9,
553
+ },
554
+ {
555
+ 6: 50,
556
+ 10: $V0,
557
+ 11: $V1,
558
+ 12: $V2,
559
+ 13: $V3,
560
+ 14: $V4,
561
+ 16: $V5,
562
+ 23: $V6,
563
+ 26: 11,
564
+ 34: $V7,
565
+ 39: $V8,
566
+ 48: $V9,
567
+ },
568
+ {
569
+ 6: 51,
570
+ 10: $V0,
571
+ 11: $V1,
572
+ 12: $V2,
573
+ 13: $V3,
574
+ 14: $V4,
575
+ 16: $V5,
576
+ 23: $V6,
577
+ 26: 11,
578
+ 34: $V7,
579
+ 39: $V8,
580
+ 48: $V9,
581
+ },
582
+ {
583
+ 6: 52,
584
+ 10: $V0,
585
+ 11: $V1,
586
+ 12: $V2,
587
+ 13: $V3,
588
+ 14: $V4,
589
+ 16: $V5,
590
+ 23: $V6,
591
+ 26: 11,
592
+ 34: $V7,
593
+ 39: $V8,
594
+ 48: $V9,
595
+ },
596
+ {
597
+ 6: 53,
598
+ 10: $V0,
599
+ 11: $V1,
600
+ 12: $V2,
601
+ 13: $V3,
602
+ 14: $V4,
603
+ 16: $V5,
604
+ 23: $V6,
605
+ 26: 11,
606
+ 34: $V7,
607
+ 39: $V8,
608
+ 48: $V9,
609
+ },
610
+ {
611
+ 6: 54,
612
+ 10: $V0,
613
+ 11: $V1,
614
+ 12: $V2,
615
+ 13: $V3,
616
+ 14: $V4,
617
+ 16: $V5,
618
+ 23: $V6,
619
+ 26: 11,
620
+ 34: $V7,
621
+ 39: $V8,
622
+ 48: $V9,
623
+ },
624
+ {
625
+ 6: 55,
626
+ 10: $V0,
627
+ 11: $V1,
628
+ 12: $V2,
629
+ 13: $V3,
630
+ 14: $V4,
631
+ 16: $V5,
632
+ 23: $V6,
633
+ 26: 11,
634
+ 34: $V7,
635
+ 39: $V8,
636
+ 48: $V9,
637
+ },
638
+ {
639
+ 6: 56,
640
+ 10: $V0,
641
+ 11: $V1,
642
+ 12: $V2,
643
+ 13: $V3,
644
+ 14: $V4,
645
+ 16: $V5,
646
+ 23: $V6,
647
+ 26: 11,
648
+ 34: $V7,
649
+ 39: $V8,
650
+ 48: $V9,
651
+ },
652
+ {
653
+ 6: 57,
654
+ 10: $V0,
655
+ 11: $V1,
656
+ 12: $V2,
657
+ 13: $V3,
658
+ 14: $V4,
659
+ 16: $V5,
660
+ 23: $V6,
661
+ 26: 11,
662
+ 34: $V7,
663
+ 39: $V8,
664
+ 48: $V9,
665
+ },
666
+ {
667
+ 6: 58,
668
+ 10: $V0,
669
+ 11: $V1,
670
+ 12: $V2,
671
+ 13: $V3,
672
+ 14: $V4,
673
+ 16: $V5,
674
+ 23: $V6,
675
+ 26: 11,
676
+ 34: $V7,
677
+ 39: $V8,
678
+ 48: $V9,
679
+ },
680
+ {
681
+ 6: 59,
682
+ 10: $V0,
683
+ 11: $V1,
684
+ 12: $V2,
685
+ 13: $V3,
686
+ 14: $V4,
687
+ 16: $V5,
688
+ 23: $V6,
689
+ 26: 11,
690
+ 34: $V7,
691
+ 39: $V8,
692
+ 48: $V9,
693
+ },
694
+ {
695
+ 6: 60,
696
+ 10: $V0,
697
+ 11: $V1,
698
+ 12: $V2,
699
+ 13: $V3,
700
+ 14: $V4,
701
+ 16: $V5,
702
+ 23: $V6,
703
+ 26: 11,
704
+ 34: $V7,
705
+ 39: $V8,
706
+ 48: $V9,
707
+ },
708
+ { 34: [1, 61] },
709
+ {
710
+ 6: 62,
711
+ 10: $V0,
712
+ 11: $V1,
713
+ 12: $V2,
714
+ 13: $V3,
715
+ 14: $V4,
716
+ 16: $V5,
717
+ 23: $V6,
718
+ 26: 11,
719
+ 34: $V7,
720
+ 39: $V8,
721
+ 48: $V9,
722
+ },
723
+ {
724
+ 6: 63,
725
+ 10: $V0,
726
+ 11: $V1,
727
+ 12: $V2,
728
+ 13: $V3,
729
+ 14: $V4,
730
+ 16: $V5,
731
+ 23: $V6,
732
+ 26: 11,
733
+ 34: $V7,
734
+ 39: $V8,
735
+ 48: $V9,
736
+ },
737
+ {
738
+ 6: 64,
739
+ 10: $V0,
740
+ 11: $V1,
741
+ 12: $V2,
742
+ 13: $V3,
743
+ 14: $V4,
744
+ 16: $V5,
745
+ 23: $V6,
746
+ 26: 11,
747
+ 34: $V7,
748
+ 39: $V8,
749
+ 48: $V9,
750
+ },
751
+ { 34: [1, 65] },
752
+ {
753
+ 6: 66,
754
+ 10: $V0,
755
+ 11: $V1,
756
+ 12: $V2,
757
+ 13: $V3,
758
+ 14: $V4,
759
+ 16: $V5,
760
+ 23: $V6,
761
+ 26: 11,
762
+ 34: $V7,
763
+ 39: $V8,
764
+ 48: $V9,
765
+ },
766
+ o($Vw, [2, 22]),
767
+ o($Vx, $Vy, {
768
+ 26: 11,
769
+ 8: 67,
770
+ 6: 68,
771
+ 10: $V0,
772
+ 11: $V1,
773
+ 12: $V2,
774
+ 13: $V3,
775
+ 14: $V4,
776
+ 16: $V5,
777
+ 23: $V6,
778
+ 34: $V7,
779
+ 39: $V8,
780
+ 48: $V9,
781
+ }),
782
+ o($Vw, [2, 36]),
783
+ {
784
+ 15: $Vb,
785
+ 16: $Vc,
786
+ 17: $Vd,
787
+ 18: $Ve,
788
+ 19: $Vf,
789
+ 20: $Vg,
790
+ 21: $Vh,
791
+ 22: $Vi,
792
+ 24: $Vj,
793
+ 27: $Vk,
794
+ 28: $Vl,
795
+ 29: $Vm,
796
+ 30: $Vn,
797
+ 31: $Vo,
798
+ 32: $Vp,
799
+ 33: $Vq,
800
+ 35: [1, 69],
801
+ 36: $Vr,
802
+ 37: $Vs,
803
+ 38: $Vt,
804
+ 40: $Vu,
805
+ 41: $Vv,
806
+ },
807
+ { 43: 70, 44: [1, 71] },
808
+ {
809
+ 15: $Vb,
810
+ 16: $Vc,
811
+ 17: $Vd,
812
+ 18: $Ve,
813
+ 19: $Vf,
814
+ 20: $Vg,
815
+ 21: $Vh,
816
+ 22: $Vi,
817
+ 24: $Vj,
818
+ 27: $Vk,
819
+ 28: $Vl,
820
+ 29: $Vm,
821
+ 30: $Vn,
822
+ 31: $Vo,
823
+ 32: $Vp,
824
+ 33: $Vq,
825
+ 36: $Vr,
826
+ 37: $Vs,
827
+ 38: $Vt,
828
+ 40: $Vu,
829
+ 41: $Vv,
830
+ 44: [2, 41],
831
+ },
832
+ o($Va, [2, 5], {
833
+ 15: $Vb,
834
+ 16: $Vc,
835
+ 17: $Vd,
836
+ 18: $Ve,
837
+ 19: $Vf,
838
+ 20: $Vg,
839
+ 21: $Vh,
840
+ 22: $Vi,
841
+ 24: $Vj,
842
+ 27: $Vk,
843
+ 28: $Vl,
844
+ 29: $Vm,
845
+ 30: $Vn,
846
+ 31: $Vo,
847
+ 32: $Vp,
848
+ 33: $Vq,
849
+ 36: $Vr,
850
+ 37: $Vs,
851
+ 38: $Vt,
852
+ 40: $Vu,
853
+ 41: $Vv,
854
+ }),
855
+ o($Vz, [2, 14], { 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
856
+ o($Vz, [2, 15], { 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
857
+ o($VA, [2, 16], { 20: $Vg }),
858
+ o($VA, [2, 17], { 20: $Vg }),
859
+ o($VA, [2, 18], { 20: $Vg }),
860
+ o($Vw, [2, 19]),
861
+ o($VB, [2, 20], {
862
+ 15: $Vb,
863
+ 16: $Vc,
864
+ 17: $Vd,
865
+ 18: $Ve,
866
+ 19: $Vf,
867
+ 20: $Vg,
868
+ 27: $Vk,
869
+ 28: $Vl,
870
+ 29: $Vm,
871
+ 30: $Vn,
872
+ 31: $Vo,
873
+ 32: $Vp,
874
+ 33: $Vq,
875
+ 36: $Vr,
876
+ 37: $Vs,
877
+ 38: $Vt,
878
+ 40: $Vu,
879
+ }),
880
+ o($VB, [2, 21], {
881
+ 15: $Vb,
882
+ 16: $Vc,
883
+ 17: $Vd,
884
+ 18: $Ve,
885
+ 19: $Vf,
886
+ 20: $Vg,
887
+ 27: $Vk,
888
+ 28: $Vl,
889
+ 29: $Vm,
890
+ 30: $Vn,
891
+ 31: $Vo,
892
+ 32: $Vp,
893
+ 33: $Vq,
894
+ 36: $Vr,
895
+ 37: $Vs,
896
+ 38: $Vt,
897
+ 40: $Vu,
898
+ }),
899
+ {
900
+ 15: $Vb,
901
+ 16: $Vc,
902
+ 17: $Vd,
903
+ 18: $Ve,
904
+ 19: $Vf,
905
+ 20: $Vg,
906
+ 21: $Vh,
907
+ 22: $Vi,
908
+ 24: $Vj,
909
+ 25: [1, 72],
910
+ 27: $Vk,
911
+ 28: $Vl,
912
+ 29: $Vm,
913
+ 30: $Vn,
914
+ 31: $Vo,
915
+ 32: $Vp,
916
+ 33: $Vq,
917
+ 36: $Vr,
918
+ 37: $Vs,
919
+ 38: $Vt,
920
+ 40: $Vu,
921
+ 41: $Vv,
922
+ },
923
+ o($VC, [2, 25], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
924
+ o($VC, [2, 26], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
925
+ o($VC, [2, 27], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
926
+ o($VC, [2, 28], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
927
+ o($VC, [2, 29], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
928
+ o($VC, [2, 30], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
929
+ o($Vx, $Vy, {
930
+ 26: 11,
931
+ 6: 68,
932
+ 8: 73,
933
+ 10: $V0,
934
+ 11: $V1,
935
+ 12: $V2,
936
+ 13: $V3,
937
+ 14: $V4,
938
+ 16: $V5,
939
+ 23: $V6,
940
+ 34: $V7,
941
+ 39: $V8,
942
+ 48: $V9,
943
+ }),
944
+ o($VC, [2, 32], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
945
+ o($VC, [2, 33], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
946
+ o($VC, [2, 34], { 15: $Vb, 16: $Vc, 17: $Vd, 18: $Ve, 19: $Vf, 20: $Vg }),
947
+ o($Vx, $Vy, {
948
+ 26: 11,
949
+ 6: 68,
950
+ 8: 74,
951
+ 10: $V0,
952
+ 11: $V1,
953
+ 12: $V2,
954
+ 13: $V3,
955
+ 14: $V4,
956
+ 16: $V5,
957
+ 23: $V6,
958
+ 34: $V7,
959
+ 39: $V8,
960
+ 48: $V9,
961
+ }),
962
+ o([4, 7, 9, 24, 25, 35, 41, 44, 45, 47, 49], [2, 39], {
963
+ 15: $Vb,
964
+ 16: $Vc,
965
+ 17: $Vd,
966
+ 18: $Ve,
967
+ 19: $Vf,
968
+ 20: $Vg,
969
+ 21: $Vh,
970
+ 22: $Vi,
971
+ 27: $Vk,
972
+ 28: $Vl,
973
+ 29: $Vm,
974
+ 30: $Vn,
975
+ 31: $Vo,
976
+ 32: $Vp,
977
+ 33: $Vq,
978
+ 36: $Vr,
979
+ 37: $Vs,
980
+ 38: $Vt,
981
+ 40: $Vu,
982
+ }),
983
+ { 9: $VD, 35: [1, 75] },
984
+ o($Vx, [2, 7], {
985
+ 15: $Vb,
986
+ 16: $Vc,
987
+ 17: $Vd,
988
+ 18: $Ve,
989
+ 19: $Vf,
990
+ 20: $Vg,
991
+ 21: $Vh,
992
+ 22: $Vi,
993
+ 24: $Vj,
994
+ 27: $Vk,
995
+ 28: $Vl,
996
+ 29: $Vm,
997
+ 30: $Vn,
998
+ 31: $Vo,
999
+ 32: $Vp,
1000
+ 33: $Vq,
1001
+ 36: $Vr,
1002
+ 37: $Vs,
1003
+ 38: $Vt,
1004
+ 40: $Vu,
1005
+ 41: $Vv,
1006
+ }),
1007
+ o($Vw, [2, 38]),
1008
+ { 44: [1, 78], 46: 77, 47: [1, 79], 49: [2, 44] },
1009
+ {
1010
+ 6: 80,
1011
+ 10: $V0,
1012
+ 11: $V1,
1013
+ 12: $V2,
1014
+ 13: $V3,
1015
+ 14: $V4,
1016
+ 16: $V5,
1017
+ 23: $V6,
1018
+ 26: 11,
1019
+ 34: $V7,
1020
+ 39: $V8,
1021
+ 48: $V9,
1022
+ },
1023
+ {
1024
+ 6: 81,
1025
+ 10: $V0,
1026
+ 11: $V1,
1027
+ 12: $V2,
1028
+ 13: $V3,
1029
+ 14: $V4,
1030
+ 16: $V5,
1031
+ 23: $V6,
1032
+ 26: 11,
1033
+ 34: $V7,
1034
+ 39: $V8,
1035
+ 48: $V9,
1036
+ },
1037
+ { 9: $VD, 35: [1, 82] },
1038
+ { 9: $VD, 35: [1, 83] },
1039
+ o($Vw, [2, 35]),
1040
+ {
1041
+ 6: 84,
1042
+ 10: $V0,
1043
+ 11: $V1,
1044
+ 12: $V2,
1045
+ 13: $V3,
1046
+ 14: $V4,
1047
+ 16: $V5,
1048
+ 23: $V6,
1049
+ 26: 11,
1050
+ 34: $V7,
1051
+ 39: $V8,
1052
+ 48: $V9,
1053
+ },
1054
+ { 49: [1, 85] },
1055
+ {
1056
+ 6: 86,
1057
+ 10: $V0,
1058
+ 11: $V1,
1059
+ 12: $V2,
1060
+ 13: $V3,
1061
+ 14: $V4,
1062
+ 16: $V5,
1063
+ 23: $V6,
1064
+ 26: 11,
1065
+ 34: $V7,
1066
+ 39: $V8,
1067
+ 48: $V9,
1068
+ },
1069
+ {
1070
+ 6: 87,
1071
+ 10: $V0,
1072
+ 11: $V1,
1073
+ 12: $V2,
1074
+ 13: $V3,
1075
+ 14: $V4,
1076
+ 16: $V5,
1077
+ 23: $V6,
1078
+ 26: 11,
1079
+ 34: $V7,
1080
+ 39: $V8,
1081
+ 48: $V9,
1082
+ },
1083
+ {
1084
+ 15: $Vb,
1085
+ 16: $Vc,
1086
+ 17: $Vd,
1087
+ 18: $Ve,
1088
+ 19: $Vf,
1089
+ 20: $Vg,
1090
+ 21: $Vh,
1091
+ 22: $Vi,
1092
+ 24: $Vj,
1093
+ 27: $Vk,
1094
+ 28: $Vl,
1095
+ 29: $Vm,
1096
+ 30: $Vn,
1097
+ 31: $Vo,
1098
+ 32: $Vp,
1099
+ 33: $Vq,
1100
+ 36: $Vr,
1101
+ 37: $Vs,
1102
+ 38: $Vt,
1103
+ 40: $Vu,
1104
+ 41: $Vv,
1105
+ 45: [1, 88],
1106
+ },
1107
+ o([4, 7, 9, 25, 35, 44, 45, 47, 49], [2, 23], {
1108
+ 15: $Vb,
1109
+ 16: $Vc,
1110
+ 17: $Vd,
1111
+ 18: $Ve,
1112
+ 19: $Vf,
1113
+ 20: $Vg,
1114
+ 21: $Vh,
1115
+ 22: $Vi,
1116
+ 24: $Vj,
1117
+ 27: $Vk,
1118
+ 28: $Vl,
1119
+ 29: $Vm,
1120
+ 30: $Vn,
1121
+ 31: $Vo,
1122
+ 32: $Vp,
1123
+ 33: $Vq,
1124
+ 36: $Vr,
1125
+ 37: $Vs,
1126
+ 38: $Vt,
1127
+ 40: $Vu,
1128
+ 41: $Vv,
1129
+ }),
1130
+ o($Vw, [2, 31]),
1131
+ o($Vw, [2, 37]),
1132
+ o($Vx, [2, 8], {
1133
+ 15: $Vb,
1134
+ 16: $Vc,
1135
+ 17: $Vd,
1136
+ 18: $Ve,
1137
+ 19: $Vf,
1138
+ 20: $Vg,
1139
+ 21: $Vh,
1140
+ 22: $Vi,
1141
+ 24: $Vj,
1142
+ 27: $Vk,
1143
+ 28: $Vl,
1144
+ 29: $Vm,
1145
+ 30: $Vn,
1146
+ 31: $Vo,
1147
+ 32: $Vp,
1148
+ 33: $Vq,
1149
+ 36: $Vr,
1150
+ 37: $Vs,
1151
+ 38: $Vt,
1152
+ 40: $Vu,
1153
+ 41: $Vv,
1154
+ }),
1155
+ o($Vw, [2, 46]),
1156
+ {
1157
+ 15: $Vb,
1158
+ 16: $Vc,
1159
+ 17: $Vd,
1160
+ 18: $Ve,
1161
+ 19: $Vf,
1162
+ 20: $Vg,
1163
+ 21: $Vh,
1164
+ 22: $Vi,
1165
+ 24: $Vj,
1166
+ 27: $Vk,
1167
+ 28: $Vl,
1168
+ 29: $Vm,
1169
+ 30: $Vn,
1170
+ 31: $Vo,
1171
+ 32: $Vp,
1172
+ 33: $Vq,
1173
+ 36: $Vr,
1174
+ 37: $Vs,
1175
+ 38: $Vt,
1176
+ 40: $Vu,
1177
+ 41: $Vv,
1178
+ 45: [1, 89],
1179
+ },
1180
+ {
1181
+ 15: $Vb,
1182
+ 16: $Vc,
1183
+ 17: $Vd,
1184
+ 18: $Ve,
1185
+ 19: $Vf,
1186
+ 20: $Vg,
1187
+ 21: $Vh,
1188
+ 22: $Vi,
1189
+ 24: $Vj,
1190
+ 27: $Vk,
1191
+ 28: $Vl,
1192
+ 29: $Vm,
1193
+ 30: $Vn,
1194
+ 31: $Vo,
1195
+ 32: $Vp,
1196
+ 33: $Vq,
1197
+ 36: $Vr,
1198
+ 37: $Vs,
1199
+ 38: $Vt,
1200
+ 40: $Vu,
1201
+ 41: $Vv,
1202
+ 49: [2, 45],
1203
+ },
1204
+ {
1205
+ 6: 90,
1206
+ 10: $V0,
1207
+ 11: $V1,
1208
+ 12: $V2,
1209
+ 13: $V3,
1210
+ 14: $V4,
1211
+ 16: $V5,
1212
+ 23: $V6,
1213
+ 26: 11,
1214
+ 34: $V7,
1215
+ 39: $V8,
1216
+ 48: $V9,
1217
+ },
1218
+ {
1219
+ 6: 91,
1220
+ 10: $V0,
1221
+ 11: $V1,
1222
+ 12: $V2,
1223
+ 13: $V3,
1224
+ 14: $V4,
1225
+ 16: $V5,
1226
+ 23: $V6,
1227
+ 26: 11,
1228
+ 34: $V7,
1229
+ 39: $V8,
1230
+ 48: $V9,
1231
+ },
1232
+ o($VE, [2, 42], {
1233
+ 15: $Vb,
1234
+ 16: $Vc,
1235
+ 17: $Vd,
1236
+ 18: $Ve,
1237
+ 19: $Vf,
1238
+ 20: $Vg,
1239
+ 21: $Vh,
1240
+ 22: $Vi,
1241
+ 24: $Vj,
1242
+ 27: $Vk,
1243
+ 28: $Vl,
1244
+ 29: $Vm,
1245
+ 30: $Vn,
1246
+ 31: $Vo,
1247
+ 32: $Vp,
1248
+ 33: $Vq,
1249
+ 36: $Vr,
1250
+ 37: $Vs,
1251
+ 38: $Vt,
1252
+ 40: $Vu,
1253
+ 41: $Vv,
1254
+ }),
1255
+ o($VE, [2, 43], {
1256
+ 15: $Vb,
1257
+ 16: $Vc,
1258
+ 17: $Vd,
1259
+ 18: $Ve,
1260
+ 19: $Vf,
1261
+ 20: $Vg,
1262
+ 21: $Vh,
1263
+ 22: $Vi,
1264
+ 24: $Vj,
1265
+ 27: $Vk,
1266
+ 28: $Vl,
1267
+ 29: $Vm,
1268
+ 30: $Vn,
1269
+ 31: $Vo,
1270
+ 32: $Vp,
1271
+ 33: $Vq,
1272
+ 36: $Vr,
1273
+ 37: $Vs,
1274
+ 38: $Vt,
1275
+ 40: $Vu,
1276
+ 41: $Vv,
1277
+ }),
1278
+ ],
1279
+ defaultActions: { 2: [2, 1], 16: [2, 2] },
1280
+ parseError: function parseError(str, hash) {
1281
+ if (hash.recoverable) {
1282
+ this.trace(str);
265
1283
  }
266
- action = table[state] && table[state][symbol];
267
- }
268
- if (typeof action === 'undefined' || !action.length || !action[0]) {
269
- var errStr = '';
270
- expected = [];
271
- for (p in table[state]) {
272
- if (this.terminals_[p] && p > TERROR) {
273
- expected.push('\'' + this.terminals_[p] + '\'');
274
- }
1284
+ else {
1285
+ var error = new Error(str);
1286
+ error.hash = hash;
1287
+ throw error;
1288
+ }
1289
+ },
1290
+ parse: function parse(input) {
1291
+ var self = this, stack = [0], tstack = [], vstack = [null], lstack = [], table = this.table, yytext = '', yylineno = 0, yyleng = 0, recovering = 0, TERROR = 2, EOF = 1;
1292
+ var args = lstack.slice.call(arguments, 1);
1293
+ var lexer = Object.create(this.lexer);
1294
+ var sharedState = { yy: {} };
1295
+ for (var k in this.yy) {
1296
+ if (Object.prototype.hasOwnProperty.call(this.yy, k)) {
1297
+ sharedState.yy[k] = this.yy[k];
275
1298
  }
276
- if (lexer.showPosition) {
277
- errStr = 'Parse error on line ' + (yylineno + 1) + ':\n' + lexer.showPosition() + '\nExpecting ' + expected.join(', ') + ', got \'' + (this.terminals_[symbol] || symbol) + '\'';
278
- } else {
279
- errStr = 'Parse error on line ' + (yylineno + 1) + ': Unexpected ' + (symbol == EOF ? 'end of input' : '\'' + (this.terminals_[symbol] || symbol) + '\'');
280
- }
281
- this.parseError(errStr, {
282
- text: lexer.match,
283
- token: this.terminals_[symbol] || symbol,
284
- line: lexer.yylineno,
285
- loc: yyloc,
286
- expected: expected
287
- });
288
1299
  }
289
- if (action[0] instanceof Array && action.length > 1) {
290
- throw new Error('Parse Error: multiple actions possible at state: ' + state + ', token: ' + symbol);
291
- }
292
- switch (action[0]) {
293
- case 1:
294
- stack.push(symbol);
295
- vstack.push(lexer.yytext);
296
- lstack.push(lexer.yylloc);
297
- stack.push(action[1]);
298
- symbol = null;
299
- if (!preErrorSymbol) {
300
- yyleng = lexer.yyleng;
301
- yytext = lexer.yytext;
302
- yylineno = lexer.yylineno;
303
- yyloc = lexer.yylloc;
304
- if (recovering > 0) {
305
- recovering--;
306
- }
307
- } else {
308
- symbol = preErrorSymbol;
309
- preErrorSymbol = null;
1300
+ lexer.setInput(input, sharedState.yy);
1301
+ sharedState.yy.lexer = lexer;
1302
+ sharedState.yy.parser = this;
1303
+ if (typeof lexer.yylloc == 'undefined') {
1304
+ lexer.yylloc = {};
310
1305
  }
311
- break;
312
- case 2:
313
- len = this.productions_[action[1]][1];
314
- yyval.$ = vstack[vstack.length - len];
315
- yyval._$ = {
316
- first_line: lstack[lstack.length - (len || 1)].first_line,
317
- last_line: lstack[lstack.length - 1].last_line,
318
- first_column: lstack[lstack.length - (len || 1)].first_column,
319
- last_column: lstack[lstack.length - 1].last_column
320
- };
321
- if (ranges) {
322
- yyval._$.range = [
323
- lstack[lstack.length - (len || 1)].range[0],
324
- lstack[lstack.length - 1].range[1]
325
- ];
1306
+ var yyloc = lexer.yylloc;
1307
+ lstack.push(yyloc);
1308
+ var ranges = lexer.options && lexer.options.ranges;
1309
+ if (typeof sharedState.yy.parseError === 'function') {
1310
+ this.parseError = sharedState.yy.parseError;
326
1311
  }
327
- r = this.performAction.apply(yyval, [
328
- yytext,
329
- yyleng,
330
- yylineno,
331
- sharedState.yy,
332
- action[1],
333
- vstack,
334
- lstack
335
- ].concat(args));
336
- if (typeof r !== 'undefined') {
337
- return r;
1312
+ else {
1313
+ this.parseError = Object.getPrototypeOf(this).parseError;
338
1314
  }
339
- if (len) {
340
- stack = stack.slice(0, -1 * len * 2);
341
- vstack = vstack.slice(0, -1 * len);
342
- lstack = lstack.slice(0, -1 * len);
1315
+ function popStack(n) {
1316
+ stack.length = stack.length - 2 * n;
1317
+ vstack.length = vstack.length - n;
1318
+ lstack.length = lstack.length - n;
1319
+ }
1320
+ _token_stack: var lex = function () {
1321
+ var token;
1322
+ token = lexer.lex() || EOF;
1323
+ if (typeof token !== 'number') {
1324
+ token = self.symbols_[token] || token;
1325
+ }
1326
+ return token;
1327
+ };
1328
+ var symbol, preErrorSymbol, state, action, a, r, yyval = {}, p, len, newState, expected;
1329
+ while (true) {
1330
+ state = stack[stack.length - 1];
1331
+ if (this.defaultActions[state]) {
1332
+ action = this.defaultActions[state];
1333
+ }
1334
+ else {
1335
+ if (symbol === null || typeof symbol == 'undefined') {
1336
+ symbol = lex();
1337
+ }
1338
+ action = table[state] && table[state][symbol];
1339
+ }
1340
+ if (typeof action === 'undefined' || !action.length || !action[0]) {
1341
+ var errStr = '';
1342
+ expected = [];
1343
+ for (p in table[state]) {
1344
+ if (this.terminals_[p] && p > TERROR) {
1345
+ expected.push("'" + this.terminals_[p] + "'");
1346
+ }
1347
+ }
1348
+ if (lexer.showPosition) {
1349
+ errStr =
1350
+ 'Parse error on line ' +
1351
+ (yylineno + 1) +
1352
+ ':\n' +
1353
+ lexer.showPosition() +
1354
+ '\nExpecting ' +
1355
+ expected.join(', ') +
1356
+ ", got '" +
1357
+ (this.terminals_[symbol] || symbol) +
1358
+ "'";
1359
+ }
1360
+ else {
1361
+ errStr =
1362
+ 'Parse error on line ' +
1363
+ (yylineno + 1) +
1364
+ ': Unexpected ' +
1365
+ (symbol == EOF
1366
+ ? 'end of input'
1367
+ : "'" + (this.terminals_[symbol] || symbol) + "'");
1368
+ }
1369
+ this.parseError(errStr, {
1370
+ text: lexer.match,
1371
+ token: this.terminals_[symbol] || symbol,
1372
+ line: lexer.yylineno,
1373
+ loc: yyloc,
1374
+ expected: expected,
1375
+ });
1376
+ }
1377
+ if (action[0] instanceof Array && action.length > 1) {
1378
+ throw new Error('Parse Error: multiple actions possible at state: ' +
1379
+ state +
1380
+ ', token: ' +
1381
+ symbol);
1382
+ }
1383
+ switch (action[0]) {
1384
+ case 1:
1385
+ stack.push(symbol);
1386
+ vstack.push(lexer.yytext);
1387
+ lstack.push(lexer.yylloc);
1388
+ stack.push(action[1]);
1389
+ symbol = null;
1390
+ if (!preErrorSymbol) {
1391
+ yyleng = lexer.yyleng;
1392
+ yytext = lexer.yytext;
1393
+ yylineno = lexer.yylineno;
1394
+ yyloc = lexer.yylloc;
1395
+ if (recovering > 0) {
1396
+ recovering--;
1397
+ }
1398
+ }
1399
+ else {
1400
+ symbol = preErrorSymbol;
1401
+ preErrorSymbol = null;
1402
+ }
1403
+ break;
1404
+ case 2:
1405
+ len = this.productions_[action[1]][1];
1406
+ yyval.$ = vstack[vstack.length - len];
1407
+ yyval._$ = {
1408
+ first_line: lstack[lstack.length - (len || 1)].first_line,
1409
+ last_line: lstack[lstack.length - 1].last_line,
1410
+ first_column: lstack[lstack.length - (len || 1)].first_column,
1411
+ last_column: lstack[lstack.length - 1].last_column,
1412
+ };
1413
+ if (ranges) {
1414
+ yyval._$.range = [
1415
+ lstack[lstack.length - (len || 1)].range[0],
1416
+ lstack[lstack.length - 1].range[1],
1417
+ ];
1418
+ }
1419
+ r = this.performAction.apply(yyval, [
1420
+ yytext,
1421
+ yyleng,
1422
+ yylineno,
1423
+ sharedState.yy,
1424
+ action[1],
1425
+ vstack,
1426
+ lstack,
1427
+ ].concat(args));
1428
+ if (typeof r !== 'undefined') {
1429
+ return r;
1430
+ }
1431
+ if (len) {
1432
+ stack = stack.slice(0, -1 * len * 2);
1433
+ vstack = vstack.slice(0, -1 * len);
1434
+ lstack = lstack.slice(0, -1 * len);
1435
+ }
1436
+ stack.push(this.productions_[action[1]][0]);
1437
+ vstack.push(yyval.$);
1438
+ lstack.push(yyval._$);
1439
+ newState = table[stack[stack.length - 2]][stack[stack.length - 1]];
1440
+ stack.push(newState);
1441
+ break;
1442
+ case 3:
1443
+ return true;
1444
+ }
343
1445
  }
344
- stack.push(this.productions_[action[1]][0]);
345
- vstack.push(yyval.$);
346
- lstack.push(yyval._$);
347
- newState = table[stack[stack.length - 2]][stack[stack.length - 1]];
348
- stack.push(newState);
349
- break;
350
- case 3:
351
1446
  return true;
352
- }
353
- }
354
- return true;
355
- }};
356
- /* generated by jison-lex 0.3.4 */
357
- var lexer = (function(){
358
- var lexer = ({
359
-
360
- EOF:1,
361
-
362
- parseError:function parseError(str, hash) {
363
- if (this.yy.parser) {
364
- this.yy.parser.parseError(str, hash);
365
- } else {
366
- throw new Error(str);
367
- }
368
- },
369
-
370
- // resets the lexer, sets new input
371
- setInput:function (input, yy) {
372
- this.yy = yy || this.yy || {};
373
- this._input = input;
374
- this._more = this._backtrack = this.done = false;
375
- this.yylineno = this.yyleng = 0;
376
- this.yytext = this.matched = this.match = '';
377
- this.conditionStack = ['INITIAL'];
378
- this.yylloc = {
379
- first_line: 1,
380
- first_column: 0,
381
- last_line: 1,
382
- last_column: 0
383
- };
384
- if (this.options.ranges) {
385
- this.yylloc.range = [0,0];
386
- }
387
- this.offset = 0;
388
- return this;
389
- },
390
-
391
- // consumes and returns one char from the input
392
- input:function () {
393
- var ch = this._input[0];
394
- this.yytext += ch;
395
- this.yyleng++;
396
- this.offset++;
397
- this.match += ch;
398
- this.matched += ch;
399
- var lines = ch.match(/(?:\r\n?|\n).*/g);
400
- if (lines) {
401
- this.yylineno++;
402
- this.yylloc.last_line++;
403
- } else {
404
- this.yylloc.last_column++;
405
- }
406
- if (this.options.ranges) {
407
- this.yylloc.range[1]++;
408
- }
409
-
410
- this._input = this._input.slice(1);
411
- return ch;
412
- },
413
-
414
- // unshifts one char (or a string) into the input
415
- unput:function (ch) {
416
- var len = ch.length;
417
- var lines = ch.split(/(?:\r\n?|\n)/g);
418
-
419
- this._input = ch + this._input;
420
- this.yytext = this.yytext.substr(0, this.yytext.length - len);
421
- //this.yyleng -= len;
422
- this.offset -= len;
423
- var oldLines = this.match.split(/(?:\r\n?|\n)/g);
424
- this.match = this.match.substr(0, this.match.length - 1);
425
- this.matched = this.matched.substr(0, this.matched.length - 1);
426
-
427
- if (lines.length - 1) {
428
- this.yylineno -= lines.length - 1;
429
- }
430
- var r = this.yylloc.range;
431
-
432
- this.yylloc = {
433
- first_line: this.yylloc.first_line,
434
- last_line: this.yylineno + 1,
435
- first_column: this.yylloc.first_column,
436
- last_column: lines ?
437
- (lines.length === oldLines.length ? this.yylloc.first_column : 0)
438
- + oldLines[oldLines.length - lines.length].length - lines[0].length :
439
- this.yylloc.first_column - len
440
- };
441
-
442
- if (this.options.ranges) {
443
- this.yylloc.range = [r[0], r[0] + this.yyleng - len];
444
- }
445
- this.yyleng = this.yytext.length;
446
- return this;
447
- },
448
-
449
- // When called from action, caches matched text and appends it on next action
450
- more:function () {
451
- this._more = true;
452
- return this;
453
- },
454
-
455
- // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.
456
- reject:function () {
457
- if (this.options.backtrack_lexer) {
458
- this._backtrack = true;
459
- } else {
460
- return 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(), {
461
- text: "",
462
- token: null,
463
- line: this.yylineno
464
- });
465
-
466
- }
467
- return this;
468
- },
469
-
470
- // retain first n characters of the match
471
- less:function (n) {
472
- this.unput(this.match.slice(n));
473
- },
474
-
475
- // displays already matched input, i.e. for error messages
476
- pastInput:function () {
477
- var past = this.matched.substr(0, this.matched.length - this.match.length);
478
- return (past.length > 20 ? '...':'') + past.substr(-20).replace(/\n/g, "");
479
- },
480
-
481
- // displays upcoming input, i.e. for error messages
482
- upcomingInput:function () {
483
- var next = this.match;
484
- if (next.length < 20) {
485
- next += this._input.substr(0, 20-next.length);
486
- }
487
- return (next.substr(0,20) + (next.length > 20 ? '...' : '')).replace(/\n/g, "");
488
- },
489
-
490
- // displays the character position where the lexing error occurred, i.e. for error messages
491
- showPosition:function () {
492
- var pre = this.pastInput();
493
- var c = new Array(pre.length + 1).join("-");
494
- return pre + this.upcomingInput() + "\n" + c + "^";
495
- },
496
-
497
- // test the lexed token: return FALSE when not a match, otherwise return token
498
- test_match:function(match, indexed_rule) {
499
- var token,
500
- lines,
501
- backup;
502
-
503
- if (this.options.backtrack_lexer) {
504
- // save context
505
- backup = {
506
- yylineno: this.yylineno,
507
- yylloc: {
1447
+ },
1448
+ };
1449
+ /* generated by jison-lex 0.3.4 */
1450
+ var lexer = (function () {
1451
+ var lexer = {
1452
+ EOF: 1,
1453
+ parseError: function parseError(str, hash) {
1454
+ if (this.yy.parser) {
1455
+ this.yy.parser.parseError(str, hash);
1456
+ }
1457
+ else {
1458
+ throw new Error(str);
1459
+ }
1460
+ },
1461
+ // resets the lexer, sets new input
1462
+ setInput: function (input, yy) {
1463
+ this.yy = yy || this.yy || {};
1464
+ this._input = input;
1465
+ this._more = this._backtrack = this.done = false;
1466
+ this.yylineno = this.yyleng = 0;
1467
+ this.yytext = this.matched = this.match = '';
1468
+ this.conditionStack = ['INITIAL'];
1469
+ this.yylloc = {
1470
+ first_line: 1,
1471
+ first_column: 0,
1472
+ last_line: 1,
1473
+ last_column: 0,
1474
+ };
1475
+ if (this.options.ranges) {
1476
+ this.yylloc.range = [0, 0];
1477
+ }
1478
+ this.offset = 0;
1479
+ return this;
1480
+ },
1481
+ // consumes and returns one char from the input
1482
+ input: function () {
1483
+ var ch = this._input[0];
1484
+ this.yytext += ch;
1485
+ this.yyleng++;
1486
+ this.offset++;
1487
+ this.match += ch;
1488
+ this.matched += ch;
1489
+ var lines = ch.match(/(?:\r\n?|\n).*/g);
1490
+ if (lines) {
1491
+ this.yylineno++;
1492
+ this.yylloc.last_line++;
1493
+ }
1494
+ else {
1495
+ this.yylloc.last_column++;
1496
+ }
1497
+ if (this.options.ranges) {
1498
+ this.yylloc.range[1]++;
1499
+ }
1500
+ this._input = this._input.slice(1);
1501
+ return ch;
1502
+ },
1503
+ // unshifts one char (or a string) into the input
1504
+ unput: function (ch) {
1505
+ var len = ch.length;
1506
+ var lines = ch.split(/(?:\r\n?|\n)/g);
1507
+ this._input = ch + this._input;
1508
+ this.yytext = this.yytext.substr(0, this.yytext.length - len);
1509
+ //this.yyleng -= len;
1510
+ this.offset -= len;
1511
+ var oldLines = this.match.split(/(?:\r\n?|\n)/g);
1512
+ this.match = this.match.substr(0, this.match.length - 1);
1513
+ this.matched = this.matched.substr(0, this.matched.length - 1);
1514
+ if (lines.length - 1) {
1515
+ this.yylineno -= lines.length - 1;
1516
+ }
1517
+ var r = this.yylloc.range;
1518
+ this.yylloc = {
508
1519
  first_line: this.yylloc.first_line,
509
- last_line: this.last_line,
1520
+ last_line: this.yylineno + 1,
510
1521
  first_column: this.yylloc.first_column,
511
- last_column: this.yylloc.last_column
512
- },
513
- yytext: this.yytext,
514
- match: this.match,
515
- matches: this.matches,
516
- matched: this.matched,
517
- yyleng: this.yyleng,
518
- offset: this.offset,
519
- _more: this._more,
520
- _input: this._input,
521
- yy: this.yy,
522
- conditionStack: this.conditionStack.slice(0),
523
- done: this.done
524
- };
525
- if (this.options.ranges) {
526
- backup.yylloc.range = this.yylloc.range.slice(0);
527
- }
528
- }
529
-
530
- lines = match[0].match(/(?:\r\n?|\n).*/g);
531
- if (lines) {
532
- this.yylineno += lines.length;
533
- }
534
- this.yylloc = {
535
- first_line: this.yylloc.last_line,
536
- last_line: this.yylineno + 1,
537
- first_column: this.yylloc.last_column,
538
- last_column: lines ?
539
- lines[lines.length - 1].length - lines[lines.length - 1].match(/\r?\n?/)[0].length :
540
- this.yylloc.last_column + match[0].length
541
- };
542
- this.yytext += match[0];
543
- this.match += match[0];
544
- this.matches = match;
545
- this.yyleng = this.yytext.length;
546
- if (this.options.ranges) {
547
- this.yylloc.range = [this.offset, this.offset += this.yyleng];
548
- }
549
- this._more = false;
550
- this._backtrack = false;
551
- this._input = this._input.slice(match[0].length);
552
- this.matched += match[0];
553
- token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);
554
- if (this.done && this._input) {
555
- this.done = false;
556
- }
557
- if (token) {
558
- return token;
559
- } else if (this._backtrack) {
560
- // recover context
561
- for (var k in backup) {
562
- this[k] = backup[k];
563
- }
564
- return false; // rule action called reject() implying the next rule should be tested instead.
565
- }
566
- return false;
567
- },
568
-
569
- // return next match in input
570
- next:function () {
571
- if (this.done) {
572
- return this.EOF;
573
- }
574
- if (!this._input) {
575
- this.done = true;
576
- }
577
-
578
- var token,
579
- match,
580
- tempMatch,
581
- index;
582
- if (!this._more) {
583
- this.yytext = '';
584
- this.match = '';
585
- }
586
- var rules = this._currentRules();
587
- for (var i = 0; i < rules.length; i++) {
588
- tempMatch = this._input.match(this.rules[rules[i]]);
589
- if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {
590
- match = tempMatch;
591
- index = i;
1522
+ last_column: lines
1523
+ ? (lines.length === oldLines.length
1524
+ ? this.yylloc.first_column
1525
+ : 0) +
1526
+ oldLines[oldLines.length - lines.length].length -
1527
+ lines[0].length
1528
+ : this.yylloc.first_column - len,
1529
+ };
1530
+ if (this.options.ranges) {
1531
+ this.yylloc.range = [r[0], r[0] + this.yyleng - len];
1532
+ }
1533
+ this.yyleng = this.yytext.length;
1534
+ return this;
1535
+ },
1536
+ // When called from action, caches matched text and appends it on next action
1537
+ more: function () {
1538
+ this._more = true;
1539
+ return this;
1540
+ },
1541
+ // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.
1542
+ reject: function () {
592
1543
  if (this.options.backtrack_lexer) {
593
- token = this.test_match(tempMatch, rules[i]);
1544
+ this._backtrack = true;
1545
+ }
1546
+ else {
1547
+ return this.parseError('Lexical error on line ' +
1548
+ (this.yylineno + 1) +
1549
+ '. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n' +
1550
+ this.showPosition(), {
1551
+ text: '',
1552
+ token: null,
1553
+ line: this.yylineno,
1554
+ });
1555
+ }
1556
+ return this;
1557
+ },
1558
+ // retain first n characters of the match
1559
+ less: function (n) {
1560
+ this.unput(this.match.slice(n));
1561
+ },
1562
+ // displays already matched input, i.e. for error messages
1563
+ pastInput: function () {
1564
+ var past = this.matched.substr(0, this.matched.length - this.match.length);
1565
+ return ((past.length > 20 ? '...' : '') + past.substr(-20).replace(/\n/g, ''));
1566
+ },
1567
+ // displays upcoming input, i.e. for error messages
1568
+ upcomingInput: function () {
1569
+ var next = this.match;
1570
+ if (next.length < 20) {
1571
+ next += this._input.substr(0, 20 - next.length);
1572
+ }
1573
+ return (next.substr(0, 20) + (next.length > 20 ? '...' : '')).replace(/\n/g, '');
1574
+ },
1575
+ // displays the character position where the lexing error occurred, i.e. for error messages
1576
+ showPosition: function () {
1577
+ var pre = this.pastInput();
1578
+ var c = new Array(pre.length + 1).join('-');
1579
+ return pre + this.upcomingInput() + '\n' + c + '^';
1580
+ },
1581
+ // test the lexed token: return FALSE when not a match, otherwise return token
1582
+ test_match: function (match, indexed_rule) {
1583
+ var token, lines, backup;
1584
+ if (this.options.backtrack_lexer) {
1585
+ // save context
1586
+ backup = {
1587
+ yylineno: this.yylineno,
1588
+ yylloc: {
1589
+ first_line: this.yylloc.first_line,
1590
+ last_line: this.last_line,
1591
+ first_column: this.yylloc.first_column,
1592
+ last_column: this.yylloc.last_column,
1593
+ },
1594
+ yytext: this.yytext,
1595
+ match: this.match,
1596
+ matches: this.matches,
1597
+ matched: this.matched,
1598
+ yyleng: this.yyleng,
1599
+ offset: this.offset,
1600
+ _more: this._more,
1601
+ _input: this._input,
1602
+ yy: this.yy,
1603
+ conditionStack: this.conditionStack.slice(0),
1604
+ done: this.done,
1605
+ };
1606
+ if (this.options.ranges) {
1607
+ backup.yylloc.range = this.yylloc.range.slice(0);
1608
+ }
1609
+ }
1610
+ lines = match[0].match(/(?:\r\n?|\n).*/g);
1611
+ if (lines) {
1612
+ this.yylineno += lines.length;
1613
+ }
1614
+ this.yylloc = {
1615
+ first_line: this.yylloc.last_line,
1616
+ last_line: this.yylineno + 1,
1617
+ first_column: this.yylloc.last_column,
1618
+ last_column: lines
1619
+ ? lines[lines.length - 1].length -
1620
+ lines[lines.length - 1].match(/\r?\n?/)[0].length
1621
+ : this.yylloc.last_column + match[0].length,
1622
+ };
1623
+ this.yytext += match[0];
1624
+ this.match += match[0];
1625
+ this.matches = match;
1626
+ this.yyleng = this.yytext.length;
1627
+ if (this.options.ranges) {
1628
+ this.yylloc.range = [this.offset, (this.offset += this.yyleng)];
1629
+ }
1630
+ this._more = false;
1631
+ this._backtrack = false;
1632
+ this._input = this._input.slice(match[0].length);
1633
+ this.matched += match[0];
1634
+ token = this.performAction.call(this, this.yy, this, indexed_rule, this.conditionStack[this.conditionStack.length - 1]);
1635
+ if (this.done && this._input) {
1636
+ this.done = false;
1637
+ }
1638
+ if (token) {
1639
+ return token;
1640
+ }
1641
+ else if (this._backtrack) {
1642
+ // recover context
1643
+ for (var k in backup) {
1644
+ this[k] = backup[k];
1645
+ }
1646
+ return false; // rule action called reject() implying the next rule should be tested instead.
1647
+ }
1648
+ return false;
1649
+ },
1650
+ // return next match in input
1651
+ next: function () {
1652
+ if (this.done) {
1653
+ return this.EOF;
1654
+ }
1655
+ if (!this._input) {
1656
+ this.done = true;
1657
+ }
1658
+ var token, match, tempMatch, index;
1659
+ if (!this._more) {
1660
+ this.yytext = '';
1661
+ this.match = '';
1662
+ }
1663
+ var rules = this._currentRules();
1664
+ for (var i = 0; i < rules.length; i++) {
1665
+ tempMatch = this._input.match(this.rules[rules[i]]);
1666
+ if (tempMatch && (!match || tempMatch[0].length > match[0].length)) {
1667
+ match = tempMatch;
1668
+ index = i;
1669
+ if (this.options.backtrack_lexer) {
1670
+ token = this.test_match(tempMatch, rules[i]);
1671
+ if (token !== false) {
1672
+ return token;
1673
+ }
1674
+ else if (this._backtrack) {
1675
+ match = false;
1676
+ continue; // rule action called reject() implying a rule MISmatch.
1677
+ }
1678
+ else {
1679
+ // else: this is a lexer rule which consumes input without producing a token (e.g. whitespace)
1680
+ return false;
1681
+ }
1682
+ }
1683
+ else if (!this.options.flex) {
1684
+ break;
1685
+ }
1686
+ }
1687
+ }
1688
+ if (match) {
1689
+ token = this.test_match(match, rules[index]);
594
1690
  if (token !== false) {
595
1691
  return token;
596
- } else if (this._backtrack) {
597
- match = false;
598
- continue; // rule action called reject() implying a rule MISmatch.
599
- } else {
600
- // else: this is a lexer rule which consumes input without producing a token (e.g. whitespace)
601
- return false;
602
1692
  }
603
- } else if (!this.options.flex) {
604
- break;
1693
+ // else: this is a lexer rule which consumes input without producing a token (e.g. whitespace)
1694
+ return false;
605
1695
  }
606
- }
607
- }
608
- if (match) {
609
- token = this.test_match(match, rules[index]);
610
- if (token !== false) {
611
- return token;
612
- }
613
- // else: this is a lexer rule which consumes input without producing a token (e.g. whitespace)
614
- return false;
615
- }
616
- if (this._input === "") {
617
- return this.EOF;
618
- } else {
619
- return this.parseError('Lexical error on line ' + (this.yylineno + 1) + '. Unrecognized text.\n' + this.showPosition(), {
620
- text: "",
621
- token: null,
622
- line: this.yylineno
623
- });
624
- }
625
- },
626
-
627
- // return next match that has a token
628
- lex:function lex () {
629
- var r = this.next();
630
- if (r) {
631
- return r;
632
- } else {
633
- return this.lex();
634
- }
635
- },
636
-
637
- // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
638
- begin:function begin (condition) {
639
- this.conditionStack.push(condition);
640
- },
641
-
642
- // pop the previously active lexer condition state off the condition stack
643
- popState:function popState () {
644
- var n = this.conditionStack.length - 1;
645
- if (n > 0) {
646
- return this.conditionStack.pop();
647
- } else {
648
- return this.conditionStack[0];
649
- }
650
- },
651
-
652
- // produce the lexer rule set which is active for the currently active lexer condition state
653
- _currentRules:function _currentRules () {
654
- if (this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1]) {
655
- return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;
656
- } else {
657
- return this.conditions["INITIAL"].rules;
658
- }
659
- },
660
-
661
- // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
662
- topState:function topState (n) {
663
- n = this.conditionStack.length - 1 - Math.abs(n || 0);
664
- if (n >= 0) {
665
- return this.conditionStack[n];
666
- } else {
667
- return "INITIAL";
668
- }
669
- },
670
-
671
- // alias for begin(condition)
672
- pushState:function pushState (condition) {
673
- this.begin(condition);
674
- },
675
-
676
- // return the number of states currently on the stack
677
- stateStackSize:function stateStackSize() {
678
- return this.conditionStack.length;
679
- },
680
- options: {"ranges":true},
681
- performAction: function anonymous(yy,yy_,$avoiding_name_collisions,YY_START) {
682
-
683
- yy.node = function(type, args, location, metaInfo) {
684
- return {
685
- type,
686
- args,
687
- range: location.range,
688
- metaInfo
689
- }
690
- }
691
-
692
-
693
- var YYSTATE=YY_START;
694
- switch($avoiding_name_collisions) {
695
- case 0:return 7;
696
- break;
697
- case 1:/* skip whitespace */
698
- break;
699
- case 2:return 12
700
- break;
701
- case 3:return 13
702
- break;
703
- case 4:return 39
704
- break;
705
- case 5:return 14
706
- break;
707
- case 6:return 28
708
- break;
709
- case 7:return 32
710
- break;
711
- case 8:return 30
712
- break;
713
- case 9:return 27
714
- break;
715
- case 10:return 31
716
- break;
717
- case 11:return 29
718
- break;
719
- case 12:return 36
720
- break;
721
- case 13:return 37
722
- break;
723
- case 14:return 33
724
- break;
725
- case 15:return 38
726
- break;
727
- case 16:return 23
728
- break;
729
- case 17:return 22
730
- break;
731
- case 18:return 21
732
- break;
733
- case 19:return 41
734
- break;
735
- case 20:return 40
736
- break;
737
- case 21:return 48
738
- break;
739
- case 22:return 44
740
- break;
741
- case 23:return 45
742
- break;
743
- case 24:return 47
744
- break;
745
- case 25:return 49
746
- break;
747
- case 26:return 17
748
- break;
749
- case 27:return 18
750
- break;
751
- case 28:return 16
752
- break;
753
- case 29:return 15
754
- break;
755
- case 30:return 19
756
- break;
757
- case 31:return 20
758
- break;
759
- case 32:return 34
760
- break;
761
- case 33:return 35
762
- break;
763
- case 34:return '['
764
- break;
765
- case 35:return ']'
766
- break;
767
- case 36:return 9
768
- break;
769
- case 37:return 24
770
- break;
771
- case 38:return 25
772
- break;
773
- case 39:return 10
774
- break;
775
- case 40:return 11
776
- break;
777
- case 41:return 4
778
- break;
779
- case 42:return 'INVALID'
780
- break;
781
- }
782
- },
783
- rules: [/^(?:(\r?\n)+\s*)/,/^(?:[^\S\r?\n]+)/,/^(?:[0-9]+(\.[0-9]+)?\b)/,/^(?:"[^"]*"|'[^']*')/,/^(?:[A-Za-z][A-Za-z_0-9\.]+(?=[(]))/,/^(?:\[[^[]+\])/,/^(?:!=)/,/^(?:>=)/,/^(?:<=)/,/^(?:=)/,/^(?:>)/,/^(?:<)/,/^(?:STARTS_WITH\b)/,/^(?:ENDS_WITH\b)/,/^(?:BETWEEN\b)/,/^(?:CONTAINS\b)/,/^(?:!|NOT\b)/,/^(?:&|AND\b)/,/^(?:\||OR\b)/,/^(?:WHERE\b)/,/^(?:IN\b)/,/^(?:CASE\b)/,/^(?:WHEN\b)/,/^(?:THEN\b)/,/^(?:ELSE\b)/,/^(?:END\b)/,/^(?:\*)/,/^(?:\/)/,/^(?:-)/,/^(?:\+)/,/^(?:%)/,/^(?:\^)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:,)/,/^(?:\?)/,/^(?::)/,/^(?:TRUE\b)/,/^(?:FALSE\b)/,/^(?:$)/,/^(?:.)/],
784
- conditions: {"INITIAL":{"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],"inclusive":true}}
785
- });
786
- return lexer;
787
- })();
788
- parser.lexer = lexer;
789
- function Parser () {
790
- this.yy = {};
791
- }
792
- Parser.prototype = parser;parser.Parser = Parser;
793
- return new Parser;
1696
+ if (this._input === '') {
1697
+ return this.EOF;
1698
+ }
1699
+ else {
1700
+ return this.parseError('Lexical error on line ' +
1701
+ (this.yylineno + 1) +
1702
+ '. Unrecognized text.\n' +
1703
+ this.showPosition(), {
1704
+ text: '',
1705
+ token: null,
1706
+ line: this.yylineno,
1707
+ });
1708
+ }
1709
+ },
1710
+ // return next match that has a token
1711
+ lex: function lex() {
1712
+ var r = this.next();
1713
+ if (r) {
1714
+ return r;
1715
+ }
1716
+ else {
1717
+ return this.lex();
1718
+ }
1719
+ },
1720
+ // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
1721
+ begin: function begin(condition) {
1722
+ this.conditionStack.push(condition);
1723
+ },
1724
+ // pop the previously active lexer condition state off the condition stack
1725
+ popState: function popState() {
1726
+ var n = this.conditionStack.length - 1;
1727
+ if (n > 0) {
1728
+ return this.conditionStack.pop();
1729
+ }
1730
+ else {
1731
+ return this.conditionStack[0];
1732
+ }
1733
+ },
1734
+ // produce the lexer rule set which is active for the currently active lexer condition state
1735
+ _currentRules: function _currentRules() {
1736
+ if (this.conditionStack.length &&
1737
+ this.conditionStack[this.conditionStack.length - 1]) {
1738
+ return this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules;
1739
+ }
1740
+ else {
1741
+ return this.conditions['INITIAL'].rules;
1742
+ }
1743
+ },
1744
+ // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
1745
+ topState: function topState(n) {
1746
+ n = this.conditionStack.length - 1 - Math.abs(n || 0);
1747
+ if (n >= 0) {
1748
+ return this.conditionStack[n];
1749
+ }
1750
+ else {
1751
+ return 'INITIAL';
1752
+ }
1753
+ },
1754
+ // alias for begin(condition)
1755
+ pushState: function pushState(condition) {
1756
+ this.begin(condition);
1757
+ },
1758
+ // return the number of states currently on the stack
1759
+ stateStackSize: function stateStackSize() {
1760
+ return this.conditionStack.length;
1761
+ },
1762
+ options: { ranges: true },
1763
+ performAction: function anonymous(yy, yy_, $avoiding_name_collisions, YY_START) {
1764
+ yy.node = function (type, args, location, metaInfo) {
1765
+ return {
1766
+ type,
1767
+ args,
1768
+ range: location.range,
1769
+ metaInfo,
1770
+ };
1771
+ };
1772
+ var YYSTATE = YY_START;
1773
+ switch ($avoiding_name_collisions) {
1774
+ case 0:
1775
+ return 7;
1776
+ break;
1777
+ case 1 /* skip whitespace */:
1778
+ break;
1779
+ case 2:
1780
+ return 12;
1781
+ break;
1782
+ case 3:
1783
+ return 13;
1784
+ break;
1785
+ case 4:
1786
+ return 39;
1787
+ break;
1788
+ case 5:
1789
+ return 14;
1790
+ break;
1791
+ case 6:
1792
+ return 28;
1793
+ break;
1794
+ case 7:
1795
+ return 32;
1796
+ break;
1797
+ case 8:
1798
+ return 30;
1799
+ break;
1800
+ case 9:
1801
+ return 27;
1802
+ break;
1803
+ case 10:
1804
+ return 31;
1805
+ break;
1806
+ case 11:
1807
+ return 29;
1808
+ break;
1809
+ case 12:
1810
+ return 36;
1811
+ break;
1812
+ case 13:
1813
+ return 37;
1814
+ break;
1815
+ case 14:
1816
+ return 33;
1817
+ break;
1818
+ case 15:
1819
+ return 38;
1820
+ break;
1821
+ case 16:
1822
+ return 23;
1823
+ break;
1824
+ case 17:
1825
+ return 22;
1826
+ break;
1827
+ case 18:
1828
+ return 21;
1829
+ break;
1830
+ case 19:
1831
+ return 41;
1832
+ break;
1833
+ case 20:
1834
+ return 40;
1835
+ break;
1836
+ case 21:
1837
+ return 48;
1838
+ break;
1839
+ case 22:
1840
+ return 44;
1841
+ break;
1842
+ case 23:
1843
+ return 45;
1844
+ break;
1845
+ case 24:
1846
+ return 47;
1847
+ break;
1848
+ case 25:
1849
+ return 49;
1850
+ break;
1851
+ case 26:
1852
+ return 17;
1853
+ break;
1854
+ case 27:
1855
+ return 18;
1856
+ break;
1857
+ case 28:
1858
+ return 16;
1859
+ break;
1860
+ case 29:
1861
+ return 15;
1862
+ break;
1863
+ case 30:
1864
+ return 19;
1865
+ break;
1866
+ case 31:
1867
+ return 20;
1868
+ break;
1869
+ case 32:
1870
+ return 34;
1871
+ break;
1872
+ case 33:
1873
+ return 35;
1874
+ break;
1875
+ case 34:
1876
+ return '[';
1877
+ break;
1878
+ case 35:
1879
+ return ']';
1880
+ break;
1881
+ case 36:
1882
+ return 9;
1883
+ break;
1884
+ case 37:
1885
+ return 24;
1886
+ break;
1887
+ case 38:
1888
+ return 25;
1889
+ break;
1890
+ case 39:
1891
+ return 10;
1892
+ break;
1893
+ case 40:
1894
+ return 11;
1895
+ break;
1896
+ case 41:
1897
+ return 4;
1898
+ break;
1899
+ case 42:
1900
+ return 'INVALID';
1901
+ break;
1902
+ }
1903
+ },
1904
+ rules: [
1905
+ /^(?:(\r?\n)+\s*)/,
1906
+ /^(?:[^\S\r?\n]+)/,
1907
+ /^(?:[0-9]+(\.[0-9]+)?\b)/,
1908
+ /^(?:"[^"]*"|'[^']*')/,
1909
+ /^(?:[A-Za-z][A-Za-z_0-9\.]+(?=[(]))/,
1910
+ /^(?:\[[^[]+\])/,
1911
+ /^(?:!=)/,
1912
+ /^(?:>=)/,
1913
+ /^(?:<=)/,
1914
+ /^(?:=)/,
1915
+ /^(?:>)/,
1916
+ /^(?:<)/,
1917
+ /^(?:STARTS_WITH\b)/,
1918
+ /^(?:ENDS_WITH\b)/,
1919
+ /^(?:BETWEEN\b)/,
1920
+ /^(?:CONTAINS\b)/,
1921
+ /^(?:!|NOT\b)/,
1922
+ /^(?:&|AND\b)/,
1923
+ /^(?:\||OR\b)/,
1924
+ /^(?:WHERE\b)/,
1925
+ /^(?:IN\b)/,
1926
+ /^(?:CASE\b)/,
1927
+ /^(?:WHEN\b)/,
1928
+ /^(?:THEN\b)/,
1929
+ /^(?:ELSE\b)/,
1930
+ /^(?:END\b)/,
1931
+ /^(?:\*)/,
1932
+ /^(?:\/)/,
1933
+ /^(?:-)/,
1934
+ /^(?:\+)/,
1935
+ /^(?:%)/,
1936
+ /^(?:\^)/,
1937
+ /^(?:\()/,
1938
+ /^(?:\))/,
1939
+ /^(?:\[)/,
1940
+ /^(?:\])/,
1941
+ /^(?:,)/,
1942
+ /^(?:\?)/,
1943
+ /^(?::)/,
1944
+ /^(?:TRUE\b)/,
1945
+ /^(?:FALSE\b)/,
1946
+ /^(?:$)/,
1947
+ /^(?:.)/,
1948
+ ],
1949
+ conditions: {
1950
+ INITIAL: {
1951
+ rules: [
1952
+ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
1953
+ 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
1954
+ 36, 37, 38, 39, 40, 41, 42,
1955
+ ],
1956
+ inclusive: true,
1957
+ },
1958
+ },
1959
+ };
1960
+ return lexer;
1961
+ })();
1962
+ parser.lexer = lexer;
1963
+ function Parser() {
1964
+ this.yy = {};
1965
+ }
1966
+ Parser.prototype = parser;
1967
+ parser.Parser = Parser;
1968
+ return new Parser();
794
1969
  })();
795
- module.exports = parser; module.exports.default = parser;
1970
+ exports.default = parser;