openpinescript 0.1.1__py3-none-any.whl
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.
- openpinescript/__init__.py +129 -0
- openpinescript/__main__.py +5 -0
- openpinescript/_cli.py +24 -0
- openpinescript/_engine/LICENSE +674 -0
- openpinescript/_engine/VERSION +1 -0
- openpinescript/_engine/dist/cli.mjs +108691 -0
- openpinescript/_engine/node_modules/antlr4ng/LICENSE.txt +29 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATN.cjs +3159 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATN.js +3159 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATN.mjs +3139 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNConfig.cjs +911 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNConfig.js +911 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNConfig.mjs +891 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNConfigSet.cjs +3781 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNConfigSet.js +3781 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNConfigSet.mjs +3761 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNDeserializationOptions.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNDeserializationOptions.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNDeserializationOptions.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNDeserializer.cjs +4300 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNDeserializer.js +4300 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNDeserializer.mjs +4280 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNSerializer.cjs +4798 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNSerializer.js +4798 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNSerializer.mjs +4778 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNSimulator.cjs +982 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNSimulator.js +982 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNSimulator.mjs +962 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNState.cjs +85 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNState.js +85 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ATNState.mjs +67 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AbstractPredicateTransition.cjs +78 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AbstractPredicateTransition.js +78 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AbstractPredicateTransition.mjs +58 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ActionTransition.cjs +96 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ActionTransition.js +96 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ActionTransition.mjs +76 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AmbiguityInfo.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AmbiguityInfo.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AmbiguityInfo.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ArrayPredictionContext.cjs +243 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ArrayPredictionContext.js +243 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ArrayPredictionContext.mjs +223 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AtomTransition.cjs +904 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AtomTransition.js +904 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/AtomTransition.mjs +884 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BasicBlockStartState.cjs +112 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BasicBlockStartState.js +112 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BasicBlockStartState.mjs +92 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BasicState.cjs +95 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BasicState.js +95 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BasicState.mjs +75 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BlockEndState.cjs +96 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BlockEndState.js +96 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BlockEndState.mjs +76 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BlockStartState.cjs +104 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BlockStartState.js +104 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/BlockStartState.mjs +84 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/CodePointTransitions.cjs +947 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/CodePointTransitions.js +947 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/CodePointTransitions.mjs +927 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ContextSensitivityInfo.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ContextSensitivityInfo.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ContextSensitivityInfo.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionEventInfo.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionEventInfo.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionEventInfo.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionInfo.cjs +206 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionInfo.js +206 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionInfo.mjs +188 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionState.cjs +96 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionState.js +96 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/DecisionState.mjs +76 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/EmptyPredictionContext.cjs +237 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/EmptyPredictionContext.js +237 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/EmptyPredictionContext.mjs +217 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/EpsilonTransition.cjs +103 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/EpsilonTransition.js +103 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/EpsilonTransition.mjs +83 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LL1Analyzer.cjs +3159 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LL1Analyzer.js +3159 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LL1Analyzer.mjs +3139 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerATNConfig.cjs +961 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerATNConfig.js +961 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerATNConfig.mjs +941 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerATNSimulator.cjs +5604 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerATNSimulator.js +5604 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerATNSimulator.mjs +5584 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerAction.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerAction.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerAction.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerActionExecutor.cjs +305 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerActionExecutor.js +305 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerActionExecutor.mjs +285 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerActionType.cjs +42 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerActionType.js +42 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerActionType.mjs +22 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerChannelAction.cjs +163 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerChannelAction.js +163 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerChannelAction.mjs +143 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerCustomAction.cjs +169 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerCustomAction.js +169 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerCustomAction.mjs +149 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerIndexedCustomAction.cjs +142 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerIndexedCustomAction.js +142 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerIndexedCustomAction.mjs +122 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerModeAction.cjs +163 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerModeAction.js +163 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerModeAction.mjs +143 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerMoreAction.cjs +73 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerMoreAction.js +73 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerMoreAction.mjs +53 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerPopModeAction.cjs +73 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerPopModeAction.js +73 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerPopModeAction.mjs +53 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerPushModeAction.cjs +163 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerPushModeAction.js +163 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerPushModeAction.mjs +143 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerSkipAction.cjs +71 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerSkipAction.js +71 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerSkipAction.mjs +51 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerTypeAction.cjs +159 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerTypeAction.js +159 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LexerTypeAction.mjs +139 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LookaheadEventInfo.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LookaheadEventInfo.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LookaheadEventInfo.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LoopEndState.cjs +96 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LoopEndState.js +96 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/LoopEndState.mjs +76 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/NotSetTransition.cjs +921 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/NotSetTransition.js +921 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/NotSetTransition.mjs +901 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/OrderedATNConfigSet.cjs +3824 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/OrderedATNConfigSet.js +3824 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/OrderedATNConfigSet.mjs +3804 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ParseInfo.cjs +156 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ParseInfo.js +156 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ParseInfo.mjs +138 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ParserATNSimulator.cjs +6082 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ParserATNSimulator.js +6082 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ParserATNSimulator.mjs +6062 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PlusBlockStartState.cjs +113 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PlusBlockStartState.js +113 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PlusBlockStartState.mjs +93 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PlusLoopbackState.cjs +104 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PlusLoopbackState.js +104 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PlusLoopbackState.mjs +84 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PrecedencePredicateTransition.cjs +887 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PrecedencePredicateTransition.js +887 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PrecedencePredicateTransition.mjs +867 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredicateEvalInfo.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredicateEvalInfo.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredicateEvalInfo.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredicateTransition.cjs +892 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredicateTransition.js +892 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredicateTransition.mjs +872 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContext.cjs +153 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContext.js +153 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContext.mjs +133 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContextCache.cjs +715 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContextCache.js +715 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContextCache.mjs +695 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContextUtils.cjs +3604 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContextUtils.js +3604 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionContextUtils.mjs +3584 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionMode.cjs +4284 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionMode.js +4284 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/PredictionMode.mjs +4264 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ProfilingATNSimulator.cjs +6467 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ProfilingATNSimulator.js +6467 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/ProfilingATNSimulator.mjs +6447 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RangeTransition.cjs +905 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RangeTransition.js +905 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RangeTransition.mjs +885 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleStartState.cjs +97 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleStartState.js +97 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleStartState.mjs +77 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleStopState.cjs +95 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleStopState.js +95 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleStopState.mjs +75 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleTransition.cjs +93 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleTransition.js +93 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/RuleTransition.mjs +73 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SemanticContext.cjs +807 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SemanticContext.js +807 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SemanticContext.mjs +787 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SetTransition.cjs +905 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SetTransition.js +905 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SetTransition.mjs +885 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SingletonPredictionContext.cjs +207 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SingletonPredictionContext.js +207 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/SingletonPredictionContext.mjs +187 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarBlockStartState.cjs +112 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarBlockStartState.js +112 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarBlockStartState.mjs +92 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarLoopEntryState.cjs +117 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarLoopEntryState.js +117 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarLoopEntryState.mjs +97 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarLoopbackState.cjs +95 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarLoopbackState.js +95 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/StarLoopbackState.mjs +75 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/TokensStartState.cjs +104 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/TokensStartState.js +104 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/TokensStartState.mjs +84 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/Transition.cjs +66 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/Transition.js +66 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/Transition.mjs +48 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/WildcardTransition.cjs +84 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/WildcardTransition.js +84 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/WildcardTransition.mjs +64 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/helpers.cjs +246 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/helpers.js +246 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/helpers.mjs +226 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/index.cjs +9485 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/index.js +9485 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/atn/index.mjs +9465 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFA.cjs +559 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFA.js +559 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFA.mjs +539 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFASerializer.cjs +76 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFASerializer.js +76 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFASerializer.mjs +58 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFAState.cjs +136 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFAState.js +136 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFAState.mjs +116 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFAStateEqualityComparator.cjs +150 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFAStateEqualityComparator.js +150 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/DFAStateEqualityComparator.mjs +130 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/LexerDFASerializer.cjs +237 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/LexerDFASerializer.js +237 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/LexerDFASerializer.mjs +217 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/PredPrediction.cjs +31 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/PredPrediction.js +31 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/PredPrediction.mjs +13 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/index.cjs +571 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/index.js +571 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/dfa/index.mjs +551 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/index.cjs +17501 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/index.mjs +17481 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/BitSet.cjs +208 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/BitSet.js +208 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/BitSet.mjs +190 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/DefaultEqualityComparator.cjs +68 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/DefaultEqualityComparator.js +68 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/DefaultEqualityComparator.mjs +48 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/EqualityComparator.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/EqualityComparator.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/EqualityComparator.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/HashMap.cjs +545 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/HashMap.js +545 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/HashMap.mjs +525 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/HashSet.cjs +438 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/HashSet.js +438 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/HashSet.mjs +418 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/InterpreterDataReader.cjs +4420 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/InterpreterDataReader.js +4420 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/InterpreterDataReader.mjs +4400 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/Interval.cjs +133 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/Interval.js +133 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/Interval.mjs +115 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/IntervalSet.cjs +834 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/IntervalSet.js +834 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/IntervalSet.mjs +814 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/MapKeyEqualityOperator.cjs +40 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/MapKeyEqualityOperator.js +40 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/MapKeyEqualityOperator.mjs +22 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/MultiMap.cjs +55 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/MultiMap.js +55 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/MultiMap.mjs +37 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/ObjectEqualityComparator.cjs +43 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/ObjectEqualityComparator.js +43 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/ObjectEqualityComparator.mjs +25 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/OrderedHashMap.cjs +610 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/OrderedHashMap.js +610 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/OrderedHashMap.mjs +590 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/OrderedHashSet.cjs +470 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/OrderedHashSet.js +470 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/OrderedHashSet.mjs +450 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/ParseCancellationException.cjs +34 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/ParseCancellationException.js +34 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/ParseCancellationException.mjs +16 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/index.cjs +4643 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/index.js +4643 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/misc/index.mjs +4623 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/AbstractParseTreeVisitor.cjs +63 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/AbstractParseTreeVisitor.js +63 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/AbstractParseTreeVisitor.mjs +45 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ErrorNode.cjs +211 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ErrorNode.js +211 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ErrorNode.mjs +191 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTree.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTree.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTree.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeListener.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeListener.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeListener.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeVisitor.cjs +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeVisitor.js +17 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeVisitor.mjs +0 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeWalker.cjs +267 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeWalker.js +267 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/ParseTreeWalker.mjs +247 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/TerminalNode.cjs +201 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/TerminalNode.js +201 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/TerminalNode.mjs +181 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/Trees.cjs +3159 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/Trees.js +3159 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/Trees.mjs +3139 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/index.cjs +16018 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/index.js +16018 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/tree/index.mjs +15998 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/DoubleDict.cjs +568 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/DoubleDict.js +568 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/DoubleDict.mjs +548 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/MurmurHash.cjs +98 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/MurmurHash.js +98 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/MurmurHash.mjs +80 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/helpers.cjs +78 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/helpers.js +78 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/helpers.mjs +60 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/index.cjs +625 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/index.js +625 -0
- openpinescript/_engine/node_modules/antlr4ng/dist/utils/index.mjs +605 -0
- openpinescript/_engine/node_modules/antlr4ng/package.json +72 -0
- openpinescript/_engine/package.json +94 -0
- openpinescript/_runtime.py +29 -0
- openpinescript-0.1.1.dist-info/METADATA +140 -0
- openpinescript-0.1.1.dist-info/RECORD +332 -0
- openpinescript-0.1.1.dist-info/WHEEL +4 -0
- openpinescript-0.1.1.dist-info/entry_points.txt +2 -0
- openpinescript-0.1.1.dist-info/licenses/LICENSE +674 -0
|
@@ -0,0 +1,237 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/dfa/LexerDFASerializer.ts
|
|
21
|
+
var LexerDFASerializer_exports = {};
|
|
22
|
+
__export(LexerDFASerializer_exports, {
|
|
23
|
+
LexerDFASerializer: () => LexerDFASerializer
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(LexerDFASerializer_exports);
|
|
26
|
+
|
|
27
|
+
// src/IntStream.ts
|
|
28
|
+
var IntStream;
|
|
29
|
+
((IntStream2) => {
|
|
30
|
+
IntStream2.EOF = -1;
|
|
31
|
+
IntStream2.UNKNOWN_SOURCE_NAME = "<unknown>";
|
|
32
|
+
})(IntStream || (IntStream = {}));
|
|
33
|
+
|
|
34
|
+
// src/Token.ts
|
|
35
|
+
var Token;
|
|
36
|
+
((Token2) => {
|
|
37
|
+
Token2.INVALID_TYPE = 0;
|
|
38
|
+
Token2.EPSILON = -2;
|
|
39
|
+
Token2.MIN_USER_TOKEN_TYPE = 1;
|
|
40
|
+
Token2.EOF = IntStream.EOF;
|
|
41
|
+
Token2.DEFAULT_CHANNEL = 0;
|
|
42
|
+
Token2.HIDDEN_CHANNEL = 1;
|
|
43
|
+
Token2.MIN_USER_CHANNEL_VALUE = 2;
|
|
44
|
+
})(Token || (Token = {}));
|
|
45
|
+
|
|
46
|
+
// src/Vocabulary.ts
|
|
47
|
+
var Vocabulary = class _Vocabulary {
|
|
48
|
+
static {
|
|
49
|
+
__name(this, "Vocabulary");
|
|
50
|
+
}
|
|
51
|
+
static EMPTY_NAMES = [];
|
|
52
|
+
/**
|
|
53
|
+
* Gets an empty {@link Vocabulary} instance.
|
|
54
|
+
*
|
|
55
|
+
*
|
|
56
|
+
* No literal or symbol names are assigned to token types, so
|
|
57
|
+
* {@link #getDisplayName(int)} returns the numeric value for all tokens
|
|
58
|
+
* except {@link Token#EOF}.
|
|
59
|
+
*/
|
|
60
|
+
static EMPTY_VOCABULARY = new _Vocabulary(_Vocabulary.EMPTY_NAMES, _Vocabulary.EMPTY_NAMES, _Vocabulary.EMPTY_NAMES);
|
|
61
|
+
maxTokenType;
|
|
62
|
+
literalNames;
|
|
63
|
+
symbolicNames;
|
|
64
|
+
displayNames;
|
|
65
|
+
/**
|
|
66
|
+
* Constructs a new instance of {@link Vocabulary} from the specified
|
|
67
|
+
* literal, symbolic, and display token names.
|
|
68
|
+
*
|
|
69
|
+
* @param literalNames The literal names assigned to tokens, or `null`
|
|
70
|
+
* if no literal names are assigned.
|
|
71
|
+
* @param symbolicNames The symbolic names assigned to tokens, or
|
|
72
|
+
* `null` if no symbolic names are assigned.
|
|
73
|
+
* @param displayNames The display names assigned to tokens, or `null`
|
|
74
|
+
* to use the values in `literalNames` and `symbolicNames` as
|
|
75
|
+
* the source of display names, as described in
|
|
76
|
+
* {@link #getDisplayName(int)}.
|
|
77
|
+
*/
|
|
78
|
+
constructor(literalNames, symbolicNames, displayNames) {
|
|
79
|
+
this.literalNames = literalNames ?? _Vocabulary.EMPTY_NAMES;
|
|
80
|
+
this.symbolicNames = symbolicNames ?? _Vocabulary.EMPTY_NAMES;
|
|
81
|
+
this.displayNames = displayNames ?? _Vocabulary.EMPTY_NAMES;
|
|
82
|
+
this.maxTokenType = Math.max(this.displayNames.length, Math.max(
|
|
83
|
+
this.literalNames.length,
|
|
84
|
+
this.symbolicNames.length
|
|
85
|
+
)) - 1;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Returns a {@link Vocabulary} instance from the specified set of token
|
|
89
|
+
* names. This method acts as a compatibility layer for the single
|
|
90
|
+
* `tokenNames` array generated by previous releases of ANTLR.
|
|
91
|
+
*
|
|
92
|
+
* The resulting vocabulary instance returns `null` for
|
|
93
|
+
* {@link getLiteralName getLiteralName(int)} and {@link getSymbolicName getSymbolicName(int)}, and the
|
|
94
|
+
* value from `tokenNames` for the display names.
|
|
95
|
+
*
|
|
96
|
+
* @param tokenNames The token names, or `null` if no token names are
|
|
97
|
+
* available.
|
|
98
|
+
* @returns A {@link Vocabulary} instance which uses `tokenNames` for
|
|
99
|
+
* the display names of tokens.
|
|
100
|
+
*/
|
|
101
|
+
static fromTokenNames(tokenNames) {
|
|
102
|
+
if (tokenNames == null || tokenNames.length === 0) {
|
|
103
|
+
return _Vocabulary.EMPTY_VOCABULARY;
|
|
104
|
+
}
|
|
105
|
+
const literalNames = [...tokenNames];
|
|
106
|
+
const symbolicNames = [...tokenNames];
|
|
107
|
+
for (let i = 0; i < tokenNames.length; i++) {
|
|
108
|
+
const tokenName = tokenNames[i];
|
|
109
|
+
if (tokenName == null) {
|
|
110
|
+
continue;
|
|
111
|
+
}
|
|
112
|
+
if (tokenName.length > 0) {
|
|
113
|
+
const firstChar = tokenName.codePointAt(0);
|
|
114
|
+
if (firstChar === 39) {
|
|
115
|
+
symbolicNames[i] = null;
|
|
116
|
+
continue;
|
|
117
|
+
} else if (firstChar >= 65 && firstChar <= 90) {
|
|
118
|
+
literalNames[i] = null;
|
|
119
|
+
continue;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
literalNames[i] = null;
|
|
123
|
+
symbolicNames[i] = null;
|
|
124
|
+
}
|
|
125
|
+
return new _Vocabulary(literalNames, symbolicNames, tokenNames);
|
|
126
|
+
}
|
|
127
|
+
getMaxTokenType() {
|
|
128
|
+
return this.maxTokenType;
|
|
129
|
+
}
|
|
130
|
+
getLiteralName(tokenType) {
|
|
131
|
+
if (tokenType >= 0 && tokenType < this.literalNames.length) {
|
|
132
|
+
return this.literalNames[tokenType];
|
|
133
|
+
}
|
|
134
|
+
return null;
|
|
135
|
+
}
|
|
136
|
+
getSymbolicName(tokenType) {
|
|
137
|
+
if (tokenType >= 0 && tokenType < this.symbolicNames.length) {
|
|
138
|
+
return this.symbolicNames[tokenType];
|
|
139
|
+
}
|
|
140
|
+
if (tokenType === Token.EOF) {
|
|
141
|
+
return "EOF";
|
|
142
|
+
}
|
|
143
|
+
return null;
|
|
144
|
+
}
|
|
145
|
+
getDisplayName(tokenType) {
|
|
146
|
+
if (tokenType >= 0 && tokenType < this.displayNames.length) {
|
|
147
|
+
const displayName = this.displayNames[tokenType];
|
|
148
|
+
if (displayName != null) {
|
|
149
|
+
return displayName;
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
const literalName = this.getLiteralName(tokenType);
|
|
153
|
+
if (literalName != null) {
|
|
154
|
+
return literalName;
|
|
155
|
+
}
|
|
156
|
+
const symbolicName = this.getSymbolicName(tokenType);
|
|
157
|
+
if (symbolicName != null) {
|
|
158
|
+
return symbolicName;
|
|
159
|
+
}
|
|
160
|
+
return `${tokenType}`;
|
|
161
|
+
}
|
|
162
|
+
getLiteralNames() {
|
|
163
|
+
return this.literalNames;
|
|
164
|
+
}
|
|
165
|
+
getSymbolicNames() {
|
|
166
|
+
return this.symbolicNames;
|
|
167
|
+
}
|
|
168
|
+
getDisplayNames() {
|
|
169
|
+
return this.displayNames;
|
|
170
|
+
}
|
|
171
|
+
};
|
|
172
|
+
|
|
173
|
+
// src/dfa/DFASerializer.ts
|
|
174
|
+
var DFASerializer = class {
|
|
175
|
+
static {
|
|
176
|
+
__name(this, "DFASerializer");
|
|
177
|
+
}
|
|
178
|
+
dfa;
|
|
179
|
+
vocabulary;
|
|
180
|
+
constructor(dfa, vocabulary) {
|
|
181
|
+
this.dfa = dfa;
|
|
182
|
+
this.vocabulary = vocabulary;
|
|
183
|
+
}
|
|
184
|
+
toString() {
|
|
185
|
+
if (!this.dfa.s0) {
|
|
186
|
+
return "";
|
|
187
|
+
}
|
|
188
|
+
let buf = "";
|
|
189
|
+
const states = this.dfa.getStates();
|
|
190
|
+
for (const s of states) {
|
|
191
|
+
let n = 0;
|
|
192
|
+
n = s.edges.length;
|
|
193
|
+
for (let i = 0; i < n; i++) {
|
|
194
|
+
const t = s.edges[i];
|
|
195
|
+
if (t && t.stateNumber !== 2147483647) {
|
|
196
|
+
buf += this.getStateString(s);
|
|
197
|
+
const label = this.getEdgeLabel(i);
|
|
198
|
+
buf += "-";
|
|
199
|
+
buf += label;
|
|
200
|
+
buf += "->";
|
|
201
|
+
buf += this.getStateString(t);
|
|
202
|
+
buf += "\n";
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
return buf;
|
|
207
|
+
}
|
|
208
|
+
getEdgeLabel(i) {
|
|
209
|
+
const name = this.vocabulary.getDisplayName(i - 1);
|
|
210
|
+
return `${name}`;
|
|
211
|
+
}
|
|
212
|
+
getStateString(s) {
|
|
213
|
+
const n = s.stateNumber;
|
|
214
|
+
const baseStateStr = (s.isAcceptState ? ":" : "") + "s" + n + (s.requiresFullContext ? "^" : "");
|
|
215
|
+
if (s.isAcceptState) {
|
|
216
|
+
if (s.predicates !== null) {
|
|
217
|
+
return `${baseStateStr}=>${s.predicates.toString()}`;
|
|
218
|
+
}
|
|
219
|
+
return `${baseStateStr}=>${s.prediction}`;
|
|
220
|
+
} else {
|
|
221
|
+
return `${baseStateStr}`;
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
};
|
|
225
|
+
|
|
226
|
+
// src/dfa/LexerDFASerializer.ts
|
|
227
|
+
var LexerDFASerializer = class extends DFASerializer {
|
|
228
|
+
static {
|
|
229
|
+
__name(this, "LexerDFASerializer");
|
|
230
|
+
}
|
|
231
|
+
constructor(dfa) {
|
|
232
|
+
super(dfa, Vocabulary.EMPTY_VOCABULARY);
|
|
233
|
+
}
|
|
234
|
+
getEdgeLabel = /* @__PURE__ */ __name((i) => {
|
|
235
|
+
return "'" + String.fromCharCode(i) + "'";
|
|
236
|
+
}, "getEdgeLabel");
|
|
237
|
+
};
|
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
3
|
+
|
|
4
|
+
// src/IntStream.ts
|
|
5
|
+
var IntStream;
|
|
6
|
+
((IntStream2) => {
|
|
7
|
+
IntStream2.EOF = -1;
|
|
8
|
+
IntStream2.UNKNOWN_SOURCE_NAME = "<unknown>";
|
|
9
|
+
})(IntStream || (IntStream = {}));
|
|
10
|
+
|
|
11
|
+
// src/Token.ts
|
|
12
|
+
var Token;
|
|
13
|
+
((Token2) => {
|
|
14
|
+
Token2.INVALID_TYPE = 0;
|
|
15
|
+
Token2.EPSILON = -2;
|
|
16
|
+
Token2.MIN_USER_TOKEN_TYPE = 1;
|
|
17
|
+
Token2.EOF = IntStream.EOF;
|
|
18
|
+
Token2.DEFAULT_CHANNEL = 0;
|
|
19
|
+
Token2.HIDDEN_CHANNEL = 1;
|
|
20
|
+
Token2.MIN_USER_CHANNEL_VALUE = 2;
|
|
21
|
+
})(Token || (Token = {}));
|
|
22
|
+
|
|
23
|
+
// src/Vocabulary.ts
|
|
24
|
+
var Vocabulary = class _Vocabulary {
|
|
25
|
+
static {
|
|
26
|
+
__name(this, "Vocabulary");
|
|
27
|
+
}
|
|
28
|
+
static EMPTY_NAMES = [];
|
|
29
|
+
/**
|
|
30
|
+
* Gets an empty {@link Vocabulary} instance.
|
|
31
|
+
*
|
|
32
|
+
*
|
|
33
|
+
* No literal or symbol names are assigned to token types, so
|
|
34
|
+
* {@link #getDisplayName(int)} returns the numeric value for all tokens
|
|
35
|
+
* except {@link Token#EOF}.
|
|
36
|
+
*/
|
|
37
|
+
static EMPTY_VOCABULARY = new _Vocabulary(_Vocabulary.EMPTY_NAMES, _Vocabulary.EMPTY_NAMES, _Vocabulary.EMPTY_NAMES);
|
|
38
|
+
maxTokenType;
|
|
39
|
+
literalNames;
|
|
40
|
+
symbolicNames;
|
|
41
|
+
displayNames;
|
|
42
|
+
/**
|
|
43
|
+
* Constructs a new instance of {@link Vocabulary} from the specified
|
|
44
|
+
* literal, symbolic, and display token names.
|
|
45
|
+
*
|
|
46
|
+
* @param literalNames The literal names assigned to tokens, or `null`
|
|
47
|
+
* if no literal names are assigned.
|
|
48
|
+
* @param symbolicNames The symbolic names assigned to tokens, or
|
|
49
|
+
* `null` if no symbolic names are assigned.
|
|
50
|
+
* @param displayNames The display names assigned to tokens, or `null`
|
|
51
|
+
* to use the values in `literalNames` and `symbolicNames` as
|
|
52
|
+
* the source of display names, as described in
|
|
53
|
+
* {@link #getDisplayName(int)}.
|
|
54
|
+
*/
|
|
55
|
+
constructor(literalNames, symbolicNames, displayNames) {
|
|
56
|
+
this.literalNames = literalNames ?? _Vocabulary.EMPTY_NAMES;
|
|
57
|
+
this.symbolicNames = symbolicNames ?? _Vocabulary.EMPTY_NAMES;
|
|
58
|
+
this.displayNames = displayNames ?? _Vocabulary.EMPTY_NAMES;
|
|
59
|
+
this.maxTokenType = Math.max(this.displayNames.length, Math.max(
|
|
60
|
+
this.literalNames.length,
|
|
61
|
+
this.symbolicNames.length
|
|
62
|
+
)) - 1;
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* Returns a {@link Vocabulary} instance from the specified set of token
|
|
66
|
+
* names. This method acts as a compatibility layer for the single
|
|
67
|
+
* `tokenNames` array generated by previous releases of ANTLR.
|
|
68
|
+
*
|
|
69
|
+
* The resulting vocabulary instance returns `null` for
|
|
70
|
+
* {@link getLiteralName getLiteralName(int)} and {@link getSymbolicName getSymbolicName(int)}, and the
|
|
71
|
+
* value from `tokenNames` for the display names.
|
|
72
|
+
*
|
|
73
|
+
* @param tokenNames The token names, or `null` if no token names are
|
|
74
|
+
* available.
|
|
75
|
+
* @returns A {@link Vocabulary} instance which uses `tokenNames` for
|
|
76
|
+
* the display names of tokens.
|
|
77
|
+
*/
|
|
78
|
+
static fromTokenNames(tokenNames) {
|
|
79
|
+
if (tokenNames == null || tokenNames.length === 0) {
|
|
80
|
+
return _Vocabulary.EMPTY_VOCABULARY;
|
|
81
|
+
}
|
|
82
|
+
const literalNames = [...tokenNames];
|
|
83
|
+
const symbolicNames = [...tokenNames];
|
|
84
|
+
for (let i = 0; i < tokenNames.length; i++) {
|
|
85
|
+
const tokenName = tokenNames[i];
|
|
86
|
+
if (tokenName == null) {
|
|
87
|
+
continue;
|
|
88
|
+
}
|
|
89
|
+
if (tokenName.length > 0) {
|
|
90
|
+
const firstChar = tokenName.codePointAt(0);
|
|
91
|
+
if (firstChar === 39) {
|
|
92
|
+
symbolicNames[i] = null;
|
|
93
|
+
continue;
|
|
94
|
+
} else if (firstChar >= 65 && firstChar <= 90) {
|
|
95
|
+
literalNames[i] = null;
|
|
96
|
+
continue;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
literalNames[i] = null;
|
|
100
|
+
symbolicNames[i] = null;
|
|
101
|
+
}
|
|
102
|
+
return new _Vocabulary(literalNames, symbolicNames, tokenNames);
|
|
103
|
+
}
|
|
104
|
+
getMaxTokenType() {
|
|
105
|
+
return this.maxTokenType;
|
|
106
|
+
}
|
|
107
|
+
getLiteralName(tokenType) {
|
|
108
|
+
if (tokenType >= 0 && tokenType < this.literalNames.length) {
|
|
109
|
+
return this.literalNames[tokenType];
|
|
110
|
+
}
|
|
111
|
+
return null;
|
|
112
|
+
}
|
|
113
|
+
getSymbolicName(tokenType) {
|
|
114
|
+
if (tokenType >= 0 && tokenType < this.symbolicNames.length) {
|
|
115
|
+
return this.symbolicNames[tokenType];
|
|
116
|
+
}
|
|
117
|
+
if (tokenType === Token.EOF) {
|
|
118
|
+
return "EOF";
|
|
119
|
+
}
|
|
120
|
+
return null;
|
|
121
|
+
}
|
|
122
|
+
getDisplayName(tokenType) {
|
|
123
|
+
if (tokenType >= 0 && tokenType < this.displayNames.length) {
|
|
124
|
+
const displayName = this.displayNames[tokenType];
|
|
125
|
+
if (displayName != null) {
|
|
126
|
+
return displayName;
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
const literalName = this.getLiteralName(tokenType);
|
|
130
|
+
if (literalName != null) {
|
|
131
|
+
return literalName;
|
|
132
|
+
}
|
|
133
|
+
const symbolicName = this.getSymbolicName(tokenType);
|
|
134
|
+
if (symbolicName != null) {
|
|
135
|
+
return symbolicName;
|
|
136
|
+
}
|
|
137
|
+
return `${tokenType}`;
|
|
138
|
+
}
|
|
139
|
+
getLiteralNames() {
|
|
140
|
+
return this.literalNames;
|
|
141
|
+
}
|
|
142
|
+
getSymbolicNames() {
|
|
143
|
+
return this.symbolicNames;
|
|
144
|
+
}
|
|
145
|
+
getDisplayNames() {
|
|
146
|
+
return this.displayNames;
|
|
147
|
+
}
|
|
148
|
+
};
|
|
149
|
+
|
|
150
|
+
// src/dfa/DFASerializer.ts
|
|
151
|
+
var DFASerializer = class {
|
|
152
|
+
static {
|
|
153
|
+
__name(this, "DFASerializer");
|
|
154
|
+
}
|
|
155
|
+
dfa;
|
|
156
|
+
vocabulary;
|
|
157
|
+
constructor(dfa, vocabulary) {
|
|
158
|
+
this.dfa = dfa;
|
|
159
|
+
this.vocabulary = vocabulary;
|
|
160
|
+
}
|
|
161
|
+
toString() {
|
|
162
|
+
if (!this.dfa.s0) {
|
|
163
|
+
return "";
|
|
164
|
+
}
|
|
165
|
+
let buf = "";
|
|
166
|
+
const states = this.dfa.getStates();
|
|
167
|
+
for (const s of states) {
|
|
168
|
+
let n = 0;
|
|
169
|
+
n = s.edges.length;
|
|
170
|
+
for (let i = 0; i < n; i++) {
|
|
171
|
+
const t = s.edges[i];
|
|
172
|
+
if (t && t.stateNumber !== 2147483647) {
|
|
173
|
+
buf += this.getStateString(s);
|
|
174
|
+
const label = this.getEdgeLabel(i);
|
|
175
|
+
buf += "-";
|
|
176
|
+
buf += label;
|
|
177
|
+
buf += "->";
|
|
178
|
+
buf += this.getStateString(t);
|
|
179
|
+
buf += "\n";
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
return buf;
|
|
184
|
+
}
|
|
185
|
+
getEdgeLabel(i) {
|
|
186
|
+
const name = this.vocabulary.getDisplayName(i - 1);
|
|
187
|
+
return `${name}`;
|
|
188
|
+
}
|
|
189
|
+
getStateString(s) {
|
|
190
|
+
const n = s.stateNumber;
|
|
191
|
+
const baseStateStr = (s.isAcceptState ? ":" : "") + "s" + n + (s.requiresFullContext ? "^" : "");
|
|
192
|
+
if (s.isAcceptState) {
|
|
193
|
+
if (s.predicates !== null) {
|
|
194
|
+
return `${baseStateStr}=>${s.predicates.toString()}`;
|
|
195
|
+
}
|
|
196
|
+
return `${baseStateStr}=>${s.prediction}`;
|
|
197
|
+
} else {
|
|
198
|
+
return `${baseStateStr}`;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
};
|
|
202
|
+
|
|
203
|
+
// src/dfa/LexerDFASerializer.ts
|
|
204
|
+
var LexerDFASerializer = class extends DFASerializer {
|
|
205
|
+
static {
|
|
206
|
+
__name(this, "LexerDFASerializer");
|
|
207
|
+
}
|
|
208
|
+
constructor(dfa) {
|
|
209
|
+
super(dfa, Vocabulary.EMPTY_VOCABULARY);
|
|
210
|
+
}
|
|
211
|
+
getEdgeLabel = /* @__PURE__ */ __name((i) => {
|
|
212
|
+
return "'" + String.fromCharCode(i) + "'";
|
|
213
|
+
}, "getEdgeLabel");
|
|
214
|
+
};
|
|
215
|
+
export {
|
|
216
|
+
LexerDFASerializer
|
|
217
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/dfa/PredPrediction.ts
|
|
21
|
+
var PredPrediction_exports = {};
|
|
22
|
+
__export(PredPrediction_exports, {
|
|
23
|
+
PredPrediction: () => PredPrediction
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(PredPrediction_exports);
|
|
26
|
+
var PredPrediction;
|
|
27
|
+
((PredPrediction2) => {
|
|
28
|
+
PredPrediction2.toString = /* @__PURE__ */ __name((prediction) => {
|
|
29
|
+
return `(${prediction.pred}, ${prediction.alt})`;
|
|
30
|
+
}, "toString");
|
|
31
|
+
})(PredPrediction || (PredPrediction = {}));
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/dfa/PredPrediction.ts
|
|
21
|
+
var PredPrediction_exports = {};
|
|
22
|
+
__export(PredPrediction_exports, {
|
|
23
|
+
PredPrediction: () => PredPrediction
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(PredPrediction_exports);
|
|
26
|
+
var PredPrediction;
|
|
27
|
+
((PredPrediction2) => {
|
|
28
|
+
PredPrediction2.toString = /* @__PURE__ */ __name((prediction) => {
|
|
29
|
+
return `(${prediction.pred}, ${prediction.alt})`;
|
|
30
|
+
}, "toString");
|
|
31
|
+
})(PredPrediction || (PredPrediction = {}));
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
3
|
+
|
|
4
|
+
// src/dfa/PredPrediction.ts
|
|
5
|
+
var PredPrediction;
|
|
6
|
+
((PredPrediction2) => {
|
|
7
|
+
PredPrediction2.toString = /* @__PURE__ */ __name((prediction) => {
|
|
8
|
+
return `(${prediction.pred}, ${prediction.alt})`;
|
|
9
|
+
}, "toString");
|
|
10
|
+
})(PredPrediction || (PredPrediction = {}));
|
|
11
|
+
export {
|
|
12
|
+
PredPrediction
|
|
13
|
+
};
|