text
stringlengths
0
1.05M
meta
dict
# $$\ $$\ $$$$$$$$\ $$\ $$\ # $$ | \__| \__$$ __| $$ | $$ | # $$ | $$\ $$$$$$$\ $$ | $$$$$$\ $$$$$$$\ $$ | $$$$$$\ # $$ | $$ |$$ __$$\ $$ | \____$$\ $$ __$$\ $$ |$$ __$$\ # $$ | $$ |$$ | $$ |$$ | $$$$$$$ |$$ | $$ |$$ |$$$$$$$$ | # $$ | $$ |$$ | $$ |$$ |$$ __$$ |$$ | $$ |$$ |$$ ____| # $$$$$$$$\ $$ |$$ | $$ |$$ |\$$$$$$$ |$$$$$$$ |$$ |\$$$$$$$\ # \________|\__|\__| \__|\__| \_______|\_______/ \__| \_______| # Simple and quick implementation of Lin tables for indexing Sz spin states from __future__ import division, print_function import numpy as np from itertools import permutations # necessary in LinTable class Table(object): def __init__(self, n, nu, nd): self.nu = nu self.nd = nd self.n = n if nu > n or nd > n: self.Jdu, self.Nu, self.basisu = (['1'], 1, []) self.Jdv, self.Nd, self.basisd = (['1'], 1, []) else: self.Juv, self.Nu, self.basisu = states(self.n, self.nu) self.Jdv, self.Nd, self.basisd = states(self.n, self.nd) @property def Js(self): """get J indices""" return {'u': self.Juv, 'd': self.Jdv} @property def Ns(self): """Get the Ns""" return (self.Nu, self.Nd) @property def ns(self): return (self.nu, self.nd) @property def ne(self): return self.nu + self.nd def states(n, nu): """ Create all many-body spin states Parameters ---------- n : int number of sites nu : int number of on spin-specie """ x = [0]*(n-nu) + [1]*nu states = np.array(unique_permutations(x), dtype=int) N = states.shape[0] Jv = bi2de(states) return (Jv, N, states) def state2index(states, Juv, Jdv=None): """ Parameters ---------- states : ndarray states to index Juv : list indexes of the spin-up subspace Jdv : list index of the spin-down subspace """ Nu = Juv.shape[0] Ju = {J: i for i, J in enumerate(Juv)} if Jdv is None: if len(states.shape) < 2: states = np.array([states]) Js = np.array([Ju[i] for i in bi2de(states)]) else: # Nd = Jdv.shape[0] Jd = {J: i for i, J in enumerate(Jdv)} n = states.shape[1]/2 Ius = bi2de(states[:, 1:n]) Ids = bi2de(states[:, n+1:]) Js = np.array([Jd[i] for i in Ids])*Nu + np.array([Ju[i] for i in Ius]) return Js def index2state(Is, n, Juv, Jdv=None): """ Returns state with a given index Parameters ---------- Is : ndarray list of indices n : int number of sites Juv : ndarray Lin table of spin-up states Jdv : ndarray Lin table for spin-down states """ Nu = Juv.shape[0] if Jdv is None: Ius = np.mod(Is, Nu) states_up = de2bi(Juv[Ius], n) return states_up else: # Nd = Jdv.shape[0] Ius = np.mod(Is, Nu) Ids = np.floor(Is/Nu).astype(int) states_up = de2bi(Juv[Ius], n) states_down = de2bi(Jdv[Ids], n) return (states_up, states_down) def unique_permutations(elements): """ Get all unique permutations of a list of elements Parameters ---------- elements : list a list containing the elements """ n = len(elements) uniques = list(set(elements)) nu = len(uniques) if not elements: return [] elif n == 1 or nu == 1: return [elements] elif n == nu: ps = permutations(elements) return [list(p) for p in ps] else: pu = [] # collect the results for i in np.arange(nu): # copy elements into v v = list(elements) # first instance of unique element ind = elements.index(uniques[i]) # remove this element del v[ind] # extend the result pu.extend([[uniques[i]] + perm for perm in unique_permutations(v)]) return pu def bi2de(binaries): """ Parameters ---------- binaries : ndarray Here one row is one binary number. """ n = binaries.shape[0] if len(binaries.shape) > 1: n = binaries.shape[1] decimals = np.dot(binaries, np.power(2, np.arange(n-1, -1, -1))) # print('d: {0}'.format(decimals)) # if (decimals.size == 1): # return [decimals] return decimals def de2bi(decimals, n=None): """ Parameters ---------- decimals : ndarray vector of decimals n : int number of binary digits """ decimals = np.array(decimals) try: nd = np.ceil(np.log2(np.max(decimals))) except RuntimeWarning: print('{0}:{1}'.format(decimals, n)) if n is None or n < nd: n = nd return np.remainder(np.floor(np.outer(decimals, np.power(2., np.arange(1-n,1)))), 2).astype(int)
{ "repo_name": "georglind/humo", "path": "humo/xactlintable.py", "copies": "1", "size": "5041", "license": "mit", "hash": -1903651756788467700, "line_mean": 23.1196172249, "line_max": 100, "alpha_frac": 0.475104146, "autogenerated": false, "ratio": 3.180441640378549, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4155545786378549, "avg_score": null, "num_lines": null }
# $$\ $$\ $$\ $$\ # $$ | $$ | $$ | $$ | # $$ | $$ |$$\ $$\ $$$$$$$\ $$ | $$\ $$$$$$\ $$ | # $$$$$$$$ |$$ | $$ |$$ _____|$$ | $$ |$$ __$$\ $$ | # $$ __$$ |$$ | $$ |$$ / $$$$$$ / $$$$$$$$ |$$ | # $$ | $$ |$$ | $$ |$$ | $$ _$$< $$ ____|$$ | # $$ | $$ |\$$$$$$ |\$$$$$$$\ $$ | \$$\ \$$$$$$$\ $$ | # \__| \__| \______/ \_______|\__| \__| \_______|\__| from __future__ import division, print_function import matplotlib.pyplot as plt import numpy as np def transmission(energies, H, GL, GR, RealSigLR=None): """ Huckel transmission from the Landauer formula T(E) = Tr(G Gamma_L G^\dagger Gamma_R) Parameters ---------- energies: ndarray list of energies H : ndarray Huckel Hamiltonian GL : ndarray vector of couplings to left lead GR : ndarray vector of couplings to right lead RealSigLR : ndarray vector containing the real part of the self-energy """ # left and right coupling matrices GamL = -np.diag(GL) GamR = -np.diag(GR) # Lead self energies Sigma_L + Sigma_R here assumed entirely imaginary SigLR = -1j/2*(GamL + GamR) if (RealSigLR is not None): SigLR = SigLR + RealSigLR T = np.zeros((len(energies)), dtype=np.float64) for i, E in enumerate(energies): try: G = np.linalg.inv(E*np.eye(H.shape[0]) - H - SigLR) T[i] = np.abs(np.trace(GamL.dot(G).dot(GamR).dot(np.conjugate(G.T)))) except np.linalg.LinAlgError: print("Green's function not defined at E={0}".format(E)) return T def seebeck_coefficient(Es, H, GL, GR, T=0): """ Seebeck coefficient from the Mott relation S = d ln(T)/ d (units of V/K) """ Tn = transmission(Es, H, GL, GR) S = np.pi**2/3*1/(11604)*T/(11604)*np.diff(np.log(Tn))/(Es[1] - Es[0]) return S def coupling(n, m, eta): """ Coupling vectors for the """ G = np.zeros((n,)) G[m] = eta return G
{ "repo_name": "georglind/humo", "path": "humo/huckel.py", "copies": "1", "size": "2093", "license": "mit", "hash": -788217211057895300, "line_mean": 28.4788732394, "line_max": 88, "alpha_frac": 0.4567606307, "autogenerated": false, "ratio": 2.757575757575758, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.37143363882757574, "avg_score": null, "num_lines": null }
from ctypes import * import os import numpy import pkg_resources class SWaligner(object): def __init__(self, soFile=None): # setup.py should put sw.so in the following path. if soFile is None: self.SW_DLL_PATH = os.path.dirname(os.path.abspath(__file__)) + os.path.sep + "sw.so" else: self.SW_DLL_PATH = os.path.abspath( soFile ) self._dll = CDLL(self.SW_DLL_PATH) self.dpMat = self._dll.allocate_dp_mat() def score(self, tSeq, qSeq): score = self._dll.compute_align_score(self.dpMat, tSeq, qSeq) self._dll.print_dp_mat(self.dpMat, tSeq, qSeq) print "Max: %s" % score return score def makeScorer(self, targets): ScoreType = c_int * len(targets) scores = ScoreType() for i in range(0, len(scores)): scores[i] = 0 TargetType = c_char_p * len(targets) targetSeqs = TargetType() for i in range(0, len(targetSeqs)): targetSeqs[i] = targets[i] targetLen = len(targets) def scorer(query): if not query: return numpy.zeros(len(targets)) self._dll.compute_align_scores(scores, targetLen, self.dpMat, query, targetSeqs) return numpy.array([scores[i] for i in xrange(0, len(scores))]) return scorer
{ "repo_name": "bnbowman/BarcodeAnalysis", "path": "BarcodeAnalysis/SWaligner.py", "copies": "1", "size": "3293", "license": "mit", "hash": 4638747237572512000, "line_mean": 43.5, "line_max": 97, "alpha_frac": 0.6155481324, "autogenerated": false, "ratio": 4.265544041450777, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5381092173850777, "avg_score": null, "num_lines": null }
import logging from pbcore.io import BasH5Reader, BaxH5Reader from pbcore.io.FastaIO import * import BarcodeAnalysis.SWaligner as Aligner import numpy as n from pbcore.io.BarcodeH5Reader import LabeledZmw, \ BARCODE_DELIMITER __RC_MAP__ = dict(zip('ACGTacgt-N','TGCAtgca-N')) class BarcodeScorer(object): def __init__(self, basH5, barcodeFasta, adapterSidePad = 4, insertSidePad = 4, scoreMode = 'paired', maxHits = 10, scoreFirst = False, startTimeCutoff = 1, minScore = 20, soFile=None): """A BarcodeScorer object scores ZMWs and produces summaries of the scores. Various parameters control the behavior of the object, specifically the padding allows the user to add a little extra on each side of the adapter find for safety. The most relevant parameter is the scoreMode which dictates how the barcodes are scored, either paired or symmetric.""" self.basH5 = basH5 self.barcodeFasta = list(barcodeFasta) self.aligner = Aligner.SWaligner(soFile) self.barcodeLength = n.unique(map(lambda x : len(x.sequence), self.barcodeFasta)) if len(self.barcodeLength) > 1: raise Exception("Currently, all barcodes must be the same length.") else: self.barcodeLength = int(self.barcodeLength) self.adapterSeq = "ATCTCTCTCTTTTCCTCCTCCTCCGTTGTTGTTGTTGAGAGAGAT" self.adapterSeqRc = self._rc("ATCTCTCTCTTTTCCTCCTCCTCCGTTGTTGTTGTTGAGAGAGAT") self.barcodeSeqs = [(barcode.sequence.upper(), self._rc(barcode.sequence.upper())) for barcode in self.barcodeFasta] self.adapterSidePad = adapterSidePad self.insertSidePad = insertSidePad self.maxHits = maxHits self.minScore = minScore if scoreMode not in ['symmetric', 'paired']: raise Exception("scoreMode must either be symmetric or paired") self._scoreMode = scoreMode self.scoreFirst = scoreFirst self.startTimeCutoff = startTimeCutoff self.threePrimeSeqs = [(x[0] if (i%2)==0 else x[1]) for i,x in enumerate(self.barcodeSeqs)] self.fivePrimeSeqs = [(x[1] if (i%2)==0 else x[0]) for i,x in enumerate(self.barcodeSeqs)] self.fivePrimeSeqsRc = [self._rc(s) for s in self.fivePrimeSeqs] def fwdBcAdp( seq_pair ): return "{0}{1}{2}".format(seq_pair[1], self.adapterSeqRc, seq_pair[0]) def revBcAdp( seq_pair ): return "{0}{1}{2}".format(seq_pair[0], self.adapterSeqRc, seq_pair[1]) self.adapterBcSeqs = [fwdBcAdp(p) if (i%2)==0 else revBcAdp(p) for i,p in enumerate(self.barcodeSeqs)] self.threePrimeScorer = self.aligner.makeScorer(self.threePrimeSeqs) self.fivePrimeScorer = self.aligner.makeScorer(self.fivePrimeSeqs) self.fivePrimeScorerRc = self.aligner.makeScorer(self.fivePrimeSeqsRc) self.adapterScorer = self.aligner.makeScorer(self.adapterBcSeqs) self.forwardScorer = self.aligner.makeScorer([x[0] for x in self.barcodeSeqs]) self.reverseScorer = self.aligner.makeScorer([x[1] for x in self.barcodeSeqs]) logging.debug(("Constructed BarcodeScorer with scoreMode: %s," + \ "adapterSidePad: %d, insertSidePad: %d, and scoreFirst: %r") \ % (scoreMode, adapterSidePad, insertSidePad, scoreFirst)) @property def movieName(self): return self.basH5.movieName def makeBCLabel(self, s1, s2): return BARCODE_DELIMITER.join((s1, s2)) @property def barcodeLabels(self): """The barcode labels are function of the barcodeNames and the scoreMode, they represent the user-visible names.""" if self.scoreMode == 'paired': return n.array([self.makeBCLabel(self.barcodeFasta[i].name, self.barcodeFasta[i+1].name) for i in xrange(0, len(self.barcodeSeqs), 2)]) else: return n.array([self.makeBCLabel(x.name, x.name) for x in self.barcodeFasta]) @property def barcodeNames(self): """The barcode names are the FASTA names""" return n.array([x.name for x in self.barcodeFasta]) @property def barcodeNames2(self): return [x.name for x in self.barcodeFasta] @property def scoreMode(self): return self._scoreMode def _rc(self, s): return "".join([__RC_MAP__[c] for c in s[::-1]]) def _adapterSeqs(self, zmw): def fromRange(rStart, rEnd): try: adpSeq = zmw.read(rStart - (self.barcodeLength + self.insertSidePad), rEnd + self.barcodeLength + self.insertSidePad).basecalls() except IndexError: return None return adpSeq adapterRegions = zmw.adapterRegions if len(adapterRegions) > self.maxHits: adapterRegions = adapterRegions[0:self.maxHits] seqs = [fromRange(start, end) for (start, end) in adapterRegions] return seqs def _flankingSeqs(self, zmw, trim=False): def fromRange(rStart, rEnd): try: qSeqLeft = zmw.read(rStart - (self.barcodeLength + self.insertSidePad), rStart + self.adapterSidePad).basecalls() except IndexError: qSeqLeft = None try: qSeqRight = zmw.read(rEnd - self.adapterSidePad, rEnd + self.barcodeLength + self.insertSidePad).basecalls() except IndexError: qSeqRight = None return (qSeqLeft, qSeqRight) # If requested, trim to only adapters entirely in the HQ region adapterRegions = zmw.adapterRegions if trim: if adapterRegions[0][0] < zmw.hqRegion[0]: adapterRegions = adapterRegions[1:] if adapterRegions[-1][1] > zmw.hqRegion[1]: adapterRegions = adapterRegions[:-1] # If we still have more than the maximum allowed hits, trim if len(adapterRegions) > self.maxHits: adapterRegions = adapterRegions[0:self.maxHits] seqs = [fromRange(start, end) for (start, end) in adapterRegions] # We only score the first barcode if we don't find any adapters # *and* the start time is less than the threshold. scoredFirst = False if self.scoreFirst and not len(seqs): s = zmw.zmwMetric('HQRegionStartTime') e = zmw.zmwMetric('HQRegionEndTime') # s<e => has HQ. if s < e and s <= self.startTimeCutoff: l = self.barcodeLength + self.insertSidePad l = l if zmw.hqRegion[1] > l else zmw.hqRegion[1] try: bc = zmw.read(0, l).basecalls() if len(bc) >= self.barcodeLength: seqs.insert(0, (bc, None)) scoredFirst = True except IndexError: pass return (seqs, scoredFirst) def testAligner(self, holeNumbers): for holeNumber in holeNumbers: print holeNumber zmw = self.basH5[holeNumber] print zmw adapters, _ = self._flankingSeqs(zmw) for left, right in adapters: for fwd, rev in self.barcodeSeqs: print len(fwd), len(rev) if left: print "Left, Fwd" self.aligner.score(left, fwd) print "Left, Rev" self.aligner.score(left, rev) if right: print "Right, Fwd" self.aligner.score(right, fwd) print "Right, Rev" self.aligner.score(right, rev) def scoreZmw(self, zmw): adapters, scoredFirst = self._flankingSeqs(zmw) adapterScores = [[]]*len(adapters) barcodeScores = n.zeros(len(self.barcodeSeqs)) for i,adapter in enumerate(adapters): fscores = self.forwardScorer(adapter[0]) rscores = self.reverseScorer(adapter[0]) ffscores = self.forwardScorer(adapter[1]) rrscores = self.reverseScorer(adapter[1]) scored = 2.0 if adapter[0] and adapter[1] \ else 1.0 if adapter[0] or adapter[1] \ else 0 # An adapter score is the average barcode score for # each barcode -- that way, you can compare across # adapters even if the different adapters have # different numbers of flanking sequence. if scored == 0: adapterScores[i] = barcodeScores else: adapterScores[i] = n.maximum((fscores + rrscores)/scored, (rscores + ffscores)/scored) barcodeScores = reduce(lambda x, y: x + y, adapterScores) if adapterScores \ else n.zeros(len(self.barcodeSeqs)) return (barcodeScores, adapterScores) def scoreZmw2(self, zmw): adapters, scoredFirst = self._flankingSeqs(zmw) adapterScores = [[]]*len(adapters) barcodeScores = n.zeros(len(self.barcodeSeqs)) for i,adapter in enumerate(adapters): fscores = self.fivePrimeScorerRc(adapter[0]) rscores = self.threePrimeScorer(adapter[0]) ffscores = self.fivePrimeScorerRc(adapter[1]) rrscores = self.threePrimeScorer(adapter[1]) scored = 2.0 if adapter[0] and adapter[1] \ else 1.0 if adapter[0] or adapter[1] \ else 0 # An adapter score is the average barcode score for # each barcode -- that way, you can compare across # adapters even if the different adapters have # different numbers of flanking sequence. if scored == 0: adapterScores[i] = barcodeScores else: adapterScores[i] = n.maximum((fscores + rrscores)/scored, (rscores + ffscores)/scored) barcodeScores = reduce(lambda x, y: x + y, adapterScores) if adapterScores \ else n.zeros(len(self.barcodeSeqs)) return (barcodeScores, adapterScores) def scoreZmw3(self, zmw): adapters, scoredFirst = self._flankingSeqs(zmw) adapterScores = [[]]*len(adapters) barcodeScores = n.zeros(len(self.barcodeSeqs)) for i,adapter in enumerate(adapters): fscores = self.fivePrimeScorer(adapter[0]) tscores = self.threePrimeScorer(adapter[1]) filteredF = n.array([(s if s >= self.minScore else 0) for s in fscores]) filteredT = n.array([(s if s >= self.minScore else 0) for s in tscores]) #filteredCounts = n.array([(2.0 if filteredF[i] and filteredT[i] else 1.0) for i in range(len(fscores))]) scored = 2.0 if adapter[0] and adapter[1] else \ 1.0 if adapter[0] or adapter[1] else 0 # An adapter score is the average barcode score for # each barcode -- that way, you can compare across # adapters even if the different adapters have # different numbers of flanking sequence. if scored == 0: adapterScores[i] = barcodeScores else: adapterScores[i] = (filteredF + filteredT)/scored #adapterScores[i] = (fscores + tscores)/scored barcodeScores = reduce(lambda x, y: x + y, adapterScores) if adapterScores \ else n.zeros(len(self.barcodeSeqs)) return (barcodeScores, adapterScores) def scoreZmwRc(self, zmw, trim=False): adapters, scoredFirst = self._flankingSeqs(zmw, trim) adapters2 = [((a[0], a[1]) if a[0] is None else (self._rc(a[0]), a[1])) for a in adapters] adapterScores = [[]]*len(adapters) barcodeScores = n.zeros(len(self.barcodeSeqs)) for i,adapter in enumerate(adapters2): fscores = self.fivePrimeScorerRc(adapter[0]) tscores = self.threePrimeScorer(adapter[1]) scored = 2.0 if adapter[0] and adapter[1] \ else 1.0 if adapter[0] or adapter[1] \ else 0 # An adapter score is the average barcode score for # each barcode -- that way, you can compare across # adapters even if the different adapters have # different numbers of flanking sequence. if scored == 0: adapterScores[i] = barcodeScores else: #adapterScores[i] = (filteredF + filteredT)/scored adapterScores[i] = (fscores + tscores)/scored barcodeScores = reduce(lambda x, y: x + y, adapterScores) if adapterScores \ else n.zeros(len(self.barcodeSeqs)) return (barcodeScores, adapterScores) def scoreZmwRc2(self, zmw): adapters, scoredFirst = self._flankingSeqs(zmw) adapters2 = [((a[0], a[1]) if a[0] is None else (self._rc(a[0]), a[1])) for a in adapters] for i,adapter in enumerate(adapters2): fscores = self.threePrimeScorer(adapter[0]) tscores = self.threePrimeScorer(adapter[1]) yield (fscores, tscores) def scoreZmwAdps(self, zmw): adapters = self._adapterSeqs(zmw) perAdapterScores = [[]]*len(adapters) perBarcodeScores = n.zeros(len(self.barcodeSeqs)) for i,adapter in enumerate(adapters): perAdapterScores[i] = self.adapterScorer(adapter) perBarcodeScores = reduce(lambda x, y: x + y, perAdapterScores) \ if perAdapterScores \ else n.zeros(len(self.barcodeSeqs)) return (perBarcodeScores, perAdapterScores) def scoreSelectedAdapters(self, zmw, selectedAdp, selectedBc): adapters, scoredFirst = self._flankingSeqs(zmw) assert len(adapters) == len(selectedAdp) selectedAdapters = [adapters[i] for i,v in enumerate(selectedAdp) if v == 1] selectedBcPos = [self.barcodeNames2.index(bc) for bc in selectedBc] selectedBcSeqs = [self.barcodeSeqs[i] for i in selectedBcPos] for i, adps in enumerate(selectedAdapters): fwdAdp, revAdp = adps print "FORWARD" for j, bc in enumerate(selectedBc): fwdBc, revBc = selectedBcSeqs[j] print "Adp #{0} - BC {1} - FwdAdp FwdBc".format(i+1, bc) self.aligner.score(fwdAdp, fwdBc) print "Adp #{0} - BC {1} - FwdAdp RevBc".format(i+1, bc) self.aligner.score(fwdAdp, revBc) print "REVERSE" for j, bc in enumerate(selectedBc): fwdBc, revBc = selectedBcSeqs[j] print "Adp #{0} - BC {1} - RevAdp FwdBc".format(i+1, bc) self.aligner.score(revAdp, fwdBc) print "Adp #{0} - BC {1} - revAdp RevBc".format(i+1, bc) self.aligner.score(revAdp, revBc) print "END\n" def scoreSelectedAdaptersRc(self, zmw, selectedAdp, selectedBc): adapters, scoredFirst = self._flankingSeqs(zmw) adapters2 = [((None, a[1]) if a[0] is None else (self._rc(a[0]), a[1])) for a in adapters] assert len(adapters2) == len(selectedAdp) selectedAdapters = [adapters2[i] for i,v in enumerate(selectedAdp) if v == 1] selectedBcPos = [self.barcodeNames2.index(bc) for bc in selectedBc] selected5pBcSeqs = [self.fivePrimeSeqsRc[i] for i in selectedBcPos] selected3pBcSeqs = [self.threePrimeSeqs[i] for i in selectedBcPos] for i, adps in enumerate(selectedAdapters): fwdAdp, revAdp = adps print "FORWARD" for j, bc in enumerate(selectedBc): fwdBc = selected5pBcSeqs[j] print "Adp #{0} - BC {1} - FwdAdp FwdBc".format(i+1, bc) self.aligner.score(fwdAdp, fwdBc) print "REVERSE" for j, bc in enumerate(selectedBc): revBc = selected3pBcSeqs[j] print "Adp #{0} - BC {1} - RevAdp RevBc".format(i+1, bc) self.aligner.score(revAdp, revBc) print "END\n" def scoreSelectedAdapterRegions(self, zmw, selectedAdp, selectedBc): adapters = self._adapterSeqs(zmw) assert len(adapters) == len(selectedAdp) selectedAdapters = [adapters[i] for i,v in enumerate(selectedAdp) if v == 1] selectedBcPos = [self.barcodeNames2.index(bc) for bc in selectedBc] selectedAdpBcSeqs = [self.adapterBcSeqs[i] for i in selectedBcPos] print zmw.zmwName for i, adp in enumerate(selectedAdapters): for j, bcId in enumerate(selectedBc): adpBc = selectedAdpBcSeqs[j] print "Adp #{0} - BC {1} - FwdAdp FwdBc".format(i+1, bcId) self.aligner.score(adp, adpBc) print "END\n" def chooseSymmetric(self, o): p = n.argsort(-o[2]) return LabeledZmw(o[0], o[1], p[0], o[2][p[0]], p[1], o[2][p[1]], o[3]) def choosePaired(self, o): if o[1] == 1: s = n.array([max(o[2][i], o[2][i + 1]) for i in \ xrange(0, len(self.barcodeSeqs), 2)]) p = n.argsort(-s) s = s[p] else: # score the pairs by scoring the two alternate # ways they could have been put on the molecule. A # missed adapter will confuse this computation. scores = o[3] results = n.zeros(len(self.barcodeSeqs)/2) for i in xrange(0, len(self.barcodeSeqs), 2): pths = [0,0] for j in xrange(0, len(scores)): pths[j % 2] += scores[j][i] pths[1 - j % 2] += scores[j][i + 1] results[i/2] = max(pths) p = n.argsort(-results) s = results[p] return LabeledZmw(o[0], o[1], p[0], s[0], p[1], s[1], o[3]) def labelZmws(self, holeNumbers): """Return a list of LabeledZmws for input holeNumbers""" # o here is the record immediately above. if self.scoreMode == 'symmetric': choose = self.chooseSymmetric elif self.scoreMode == 'paired': choose = self.choosePaired else: raise Exception("Unsupported scoring mode in BarcodeLabeler.py") scored = [self.scoreZmw(self.basH5[zmw]) for zmw in holeNumbers] return [choose(scoreTup) for scoreTup in scored if scoreTup[1]]
{ "repo_name": "bnbowman/BarcodeAnalysis", "path": "BarcodeAnalysis/BarcodeScorer.py", "copies": "1", "size": "20768", "license": "mit", "hash": 3103317154239369000, "line_mean": 43.5665236052, "line_max": 117, "alpha_frac": 0.5850346687, "autogenerated": false, "ratio": 3.7026207880192548, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4787655456719255, "avg_score": null, "num_lines": null }
def __init__(self, script, mode=None): self.script = script self.mode = mode self.validateSettings() def validateSettings(self): # Check the values of the specified script try: assert self.script in SCRIPT_CHOICES except: raise ValueError("Script is not a recognized DagCon script!") # If it's gcon, check that a valid mode was specified if self.script == 'gcon.py': try: assert self.mode in MODE_CHOICES except: raise ValueError("Gcon.py runners must specify mode 'r' or 'd'") # Finally, if the script and options pass, find the absolute paths self.executable = which( self.script ) #################### # Instance Methods # #################### def runGcon(self, inputFile, outputFile, refFile=None, name=None): if outputFile is None: outputFile = self.getOutputFileName( inputFile ) if name is None: path, filename = os.path.split( inputFile ) filename, ext = os.path.splitext( filename ) name = filename + '_consensus' if self.mode == 'r': assert refFile is not None p = subprocess.Popen( [self.executable, self.mode, inputFile, refFile, '--cname', name, '-o', outputFile] ) p.wait() elif self.mode == 'd': p = subprocess.Popen( [self.executable, self.mode, inputFile, '--cname', name, '-o', outputFile] ) p.wait() return outputFile def getOutputFile(self, inputFile): path, filename = os.path.split( inputFile ) root, ext = os.path.splitext( filename ) outputFile = root + '_consensus.fa' return os.path.join( path, outputFile ) def __call__(self, inputFile, refFile=None): outputFile = self.getOutputFile( inputFile ) if os.path.exists( outputFile ): return outputFile elif self.script == 'gcon.py': return self.runGcon( inputFile, outputFile, refFile )
{ "repo_name": "lufuhao/PB_rDnaTools", "path": "src/pbrdna/resequence/DagConTools.py", "copies": "2", "size": "4518", "license": "bsd-3-clause", "hash": 6348441796889369000, "line_mean": 40.8333333333, "line_max": 83, "alpha_frac": 0.5825586543, "autogenerated": false, "ratio": 4.643371017471737, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.6225929671771737, "avg_score": null, "num_lines": null }
def __init__(self, input_file=None, output_file=None): if input_file is None: self.initialize_from_args() else: self.initialize_from_call(input_file, output_file) self.validate_settings() self.initialize_readers() def initialize_from_args(self): import argparse parser = argparse.ArgumentParser() parser.add_argument('input_file', metavar='FILE', help="BasH5 or FOFN to extract from") parser.add_argument('-o', '--output', default=sys.stdout, help="Specify a file to output the data to") group = parser.add_mutually_exclusive_group(required=True) group.add_argument('--subreads', action='store_true', help="Output sequences from individual subreads") group.add_argument('--CCS', action='store_true', help="Output sequences from CCS reads") args = parser.parse_args() self.__dict__.update( vars(args) ) def initialize_from_call(self, input_file, output_file): self.input_file = input_file if output_file is None: self.output = sys.stdout else: self.output = output_file def validate_settings(self): if self.input_file.endswith('.bas.h5') or \ self.input_file.endswith('.fofn'): log.info('Creating a BasH5Extractor for "{0}"'.format(self.input_file)) log.info('Outputing extracted reads to "{0}"'.format(self.output)) else: raise ValueError('Input files must be either FOFN or BasH5!') def initialize_readers(self): self.bash5_readers = [] if self.input_file.endswith('.bas.h5'): self.add_bash5_reader( self.input_file ) elif self.input_file.endswith('.fofn'): self.parse_fofn_file( self.input_file ) def add_bash5_reader(self, bash5_file): filepath = os.path.realpath( bash5_file ) path, filename = os.path.split( filepath ) log.info('Creating a BasH5Reader for "{0}"'.format(filename)) self.bash5_readers.append( BasH5Reader( filepath ) ) def parse_fofn_file(self, fofn_file): with open(fofn_file, 'r') as handle: for line in handle: fofn_entry = line.strip() if not fofn_entry: continue if fofn_entry.endswith('.bas.h5'): self.add_bash5_reader( fofn_entry ) elif fofn_entry.endswith('.bax.h5'): self.add_bash5_reader( fofn_entry ) else: raise ValueError('FOFN must contain only BasH5 and BaxH5 files!') ################# # Class Methods # ################# @classmethod def writeCcsFastq(cls, basH5Reader, fastqWriter): log.info('Writing Fastq CCS reads from "%s"...' % basH5Reader.movieName) for zmw in basH5Reader: if zmw.ccsRead: fastqRecord = FastqRecord(zmw.ccsRead.readName, zmw.ccsRead.basecalls(), zmw.ccsRead.QualityValue()) fastqWriter.writeRecord( fastqRecord ) @classmethod def writeSubreadFastq(cls, basH5Reader, fastqWriter): log.info('Writing Fastq subreads from "%s"...' % basH5Reader.movieName) for zmw in basH5Reader: for subread in zmw.subreads(): fastqRecord = FastqRecord(subread.readName, subread.basecalls(), subread.QualityValue()) fastqWriter.writeRecord( fastqRecord ) #################### # Instance Methods # #################### def outputCcsFastq(self): log.info('Parsing Fastq CCS reads from input BAS.H5 files') with FastqWriter(self.output) as writer: for reader in self.bash5_readers: self.writeCcsFastq( reader, writer ) def outputSubreadFastq(self): log.info('Parsing Fastq subreads from input BAS.H5 files') with FastqWriter(self.output) as writer: for reader in self.bash5_readers: self.writeSubreadFastq( reader, writer ) def __call__(self): if self.CCS: self.outputCcsFastq() elif self.subreads: self.outputSubreadFastq() if __name__ == '__main__': extractor = BasH5Extractor() extractor()
{ "repo_name": "lufuhao/PB_rDnaTools", "path": "src/pbrdna/io/BasH5IO.py", "copies": "2", "size": "6696", "license": "bsd-3-clause", "hash": -7708361357265220000, "line_mean": 40.85, "line_max": 85, "alpha_frac": 0.5979689367, "autogenerated": false, "ratio": 4.1256931608133085, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5723662097513308, "avg_score": null, "num_lines": null }
def __init__(self, listFile=None, seqFile=None, distance=None): if listFile is None or seqFile is None: self.initializeFromArgs() else: self.initializeFromCall(listFile, seqFile, distance) self.validate_settings() self.initialize_output() self.parse_sequence_data() def initializeFromArgs(self): import argparse parser = argparse.ArgumentParser() parser.add_argument('listFile', metavar='FILE', help="Mothur list file of cluster data") parser.add_argument('ccsFile', metavar='FILE', help="Fasta or Fastq file of CCS sequences") parser.add_argument('sequenceFile', metavar='FILE', help="BasH5 or FOFN of sequence data") parser.add_argument('-d', '--distance', type=float, default=DEFAULT_DIST, metavar='FLOAT', help="Distance at which to cluster sequences") parser.add_argument('-f', '--outputFile', default=sys.stdout, help="Specify output file for consensus sequences") parser.add_argument('-m', '--minClusterSize', type=int, default=DEFAULT_MIN_CLUSTER, metavar='INT', help='Minimum number of CCS reads to resequence') parser.add_argument('-n', '--numProc', type=int, default=1, metavar='INT', help="Number of processors to use") parser.add_argument('-o', '--outputDir', default='reseq', help="Specify a directory for intermediate files") args = parser.parse_args() self.__dict__.update( vars(args) ) def initializeFromCall(self, listFile, seqFile, distance): self.listFile = listFile self.sequenceFile = seqFile self.distance = DEFAULT_DIST if distance is None else distance self.output = sys.stdout def validate_settings(self): # Check the values of the supplied input and output files self.listFile = validateInputFile( self.listFile, ['.list']) self.ccsFile = validateInputFile( self.ccsFile, ['.fastq']) self.sequenceFile = validateInputFile( self.sequenceFile, ['.bas.h5', '.fofn']) self.outputFile = validateOutputFile( self.outputFile ) try: # Check the value of the numProc argument assert self.numProc >= 1 except AssertionError: raise ValueError('numProc must be a positive integer!') # Find all of external tools we will need to use self.filterPlsH5 = which('filterPlsH5.py') self.compareSequences = which('compareSequences.py') self.cmph5tools = which('cmph5tools.py') self.loadPulses = which('loadPulses') self.variantCaller = which('variantCaller.py') def initialize_output(self): createDirectory( self.outputDir ) os.chdir( self.outputDir ) ################# # Class Methods # ################# @classmethod def convertDistance(cls, distance): try: distance = 'unique' if distance == 'unique' else float(distance) except: raise ValueError('"%s" is not a valid distance!' % parts[0]) return distance #################### # Instance Methods # #################### def parseDistances(self): distances = [] with open( self.listFile, 'r' ) as handle: for line in handle: parts = line.split() distance = self.convertDistance( parts[0] ) distances.append( distance ) return distances def parse_sequence_data(self): self.sequenceData = {} for fastqRecord in FastqReader( self.ccsFile ): zmw = getZmw( fastqRecord.name ) self.sequenceData[zmw] = fastqRecord def selectDistance(self, distances): # If our selected distance is present, simply return it if self.distance in distances: return self.distance # Otherwise find the largest clustering distance smaller than # the specified distance and return that possible = [d for d in distances if d != 'unique'] smaller = [d for d in possible if d < self.distance] if not smaller: raise ValueError('No valid clustering distances found!') return max(smaller) def parseClusters( self, targetDist ): with open( self.listFile, 'r' ) as handle: for line in handle: # Skip lines until we find the target distance parts = line.split() currDist = self.convertDistance( parts[0] ) if currDist != targetDist: continue # Check that the number of clusters is concordant clusterCount = int(parts[1]) clusters = parts[2:] assert len(clusters) == clusterCount # Convert the strings of clusters to Lists and return clusters = [c.split(',') for c in clusters] return clusters def trimClusterNames(self, clusters): trimmed = [] for cluster in clusters: cluster = [getZmw(c) for c in cluster] trimmed.append( frozenset(cluster) ) return trimmed def getClusterReads(self, cluster): reads = [] for ccsZmw in cluster: try: ccsRead = self.sequenceData[ccsZmw] except KeyError: #raise Warning("No CCS read found for '%s', skipping..." % ccsZmw) continue reads.append( ccsRead ) return reads def findLongestRead(self, reads): lengths = [len(read.sequence) for read in reads] maxLength = max(lengths) longestReads = [read for read in reads if len(read.sequence) == maxLength] return longestReads[0] def outputClusterWhitelist(self, cluster, count): print "Creating Whitelist for Cluster #%s" % count whiteListFile = 'cluster%s_whitelist.txt' % count if os.path.exists( whiteListFile ): return whiteListFile with open( whiteListFile, 'w' ) as handle: for zmw in cluster: handle.write(zmw + '\n') return whiteListFile def outputClusterReference(self, reference, count): print "Creating reference sequence for Cluster #%s" % count referenceFile = 'cluster%s_reference.fasta' % count if os.path.exists( referenceFile ): return referenceFile # Rename the "Reference" sequence to the cluster referenceFasta = FastaRecord("Cluster%s" % count, reference.sequence) with FastaWriter( referenceFile ) as handle: handle.writeRecord( referenceFasta ) return referenceFile def outputRepresentativeRead(self, representativeRead, count): print "Creating representative sequence file Cluster #%s" % count representativeFile = 'cluster%s_represent.fastq' % count if os.path.exists( representativeFile ): return representativeFile with FastqWriter( representativeFile ) as handle: handle.writeRecord( representativeRead ) return representativeFile def createRgnH5(self, whiteListFile, count): print "Creating Region Table for Cluster #%s" % count outputDir = 'cluster%s_regionTables' % count outputFofn = 'cluster%s_regionTables.fofn' % count if os.path.exists( outputDir ) and os.path.exists( outputFofn ): return outputFofn outputDirArg = '--outputDir=%s' % outputDir outputFofnArg = '--outputFofn=%s' % outputFofn filterArg = '--filter=ReadWhitelist=%s,MinReadScore=0.75' % whiteListFile p = subprocess.Popen( [self.filterPlsH5, self.sequenceFile, outputDirArg, outputFofnArg, filterArg] ) p.wait() print "Region Table Created Successfully" return outputFofn def createCmpH5(self, referenceFile, rgnH5File, count): print "Creating a CMP.H5 for Cluster #%s" % count cmpH5File = 'cluster%s.cmp.h5' % count if os.path.exists( cmpH5File ): return cmpH5File p = subprocess.Popen( [self.compareSequences, '--minAccuracy=0.75', '--minLength=500', '--useQuality', '--h5pbi', '--info', '--nproc=4', '-x', '-bestn', '1', '--nproc=%s' % self.numProc, '--regionTable=%s' % rgnH5File, '--algorithm=blasr', '--noiseData=-77.27,0.08654,0.00121', '--h5fn=%s' % cmpH5File, self.sequenceFile, referenceFile] ) p.wait() return cmpH5File def sortCmpH5(self, cmph5File, count): print "Sorting the CmpH5 for Cluster #%s" % count sortedCmpH5File = 'cluster%s.sorted.cmp.h5' % count if os.path.exists( sortedCmpH5File ): return sortedCmpH5File p = subprocess.Popen( [self.cmph5tools, 'sort', '--outFile=%s' % sortedCmpH5File, cmph5File] ) p.wait() return sortedCmpH5File def loadPulsesIntoCmpH5(self, sortedCmpH5File, count): print "Loading pulse data into the CmpH5 for Cluster #%s" % count p = subprocess.Popen( [self.loadPulses, self.sequenceFile, sortedCmpH5File, '-metrics', PULSE_METRICS] ) return True def runQuiver(self, referenceFile, sortedCmpH5File, count): print "Running Quiver-consensus on Cluster #%s" % count consensusFile = 'cluster%s_consensus.fastq' % count if os.path.exists( consensusFile ): return consensusFile p = subprocess.Popen( [self.variantCaller, '--algorithm=quiver', '--numWorkers=%s' % self.numProc, '--reference=%s' % referenceFile, '--outputFile=%s' % consensusFile, sortedCmpH5File]) p.wait() return consensusFile def combineOutputSequences(self, outputSequenceFiles): print "Combining Consensus and Representative sequences" outputSequences = [] for filename in outputSequenceFiles: for record in FastqReader( filename ): outputSequences.append( record ) return outputSequences def outputCombinedSequences(self, combinedSequences ): print "Writing finished sequences to file" with FastqWriter( self.outputFile ) as handle: for record in combinedSequences: handle.writeRecord( record ) def __call__(self): outputSequenceFiles = [] # Select the appropriate distance, and parse the matching clusters distances = self.parseDistances() distance = self.selectDistance( distances ) clusters = self.parseClusters( distance ) trimmedClusters = self.trimClusterNames( clusters ) # Iterate over the clusters, generating consensuses for count, cluster in enumerate( trimmedClusters ): count = str(count+1).zfill(4) print "Analyzing cluster #%s now..." % (count) reads = self.getClusterReads( cluster ) # If we have enought reads if len(reads) >= self.minClusterSize: print "%s ZMWs found (of %s), generating consensus..." % \ (len(reads), len(cluster)) # First we select the longest CCS read from the cluster longest = self.findLongestRead( reads ) referenceFile = self.outputClusterReference( longest, count ) # Second we create a Rng.H5 file to mask other reads from Blasr whiteListFile = self.outputClusterWhitelist( cluster, count ) rgnH5File = self.createRgnH5( whiteListFile, count ) # Third we create a sorted CmpH5 cmpH5File = self.createCmpH5( referenceFile, rgnH5File, count ) sortedCmpH5File = self.sortCmpH5( cmpH5File, count ) # Fourth we load rich QV data and run Quiver self.loadPulsesIntoCmpH5( sortedCmpH5File, count ) consensusFile = self.runQuiver( referenceFile, sortedCmpH5File, count ) # Finally we record the name of the output file outputSequenceFiles.append( consensusFile ) # Otherwise, we select one "Best" read to represent the cluster else: print "%s ZMWs found (of %s), skipping consensus..." % \ (len(reads), len(cluster)) reads = self.getClusterReads( cluster ) representRead = reads[0] representFile = self.outputRepresentativeRead( representRead, count ) outputSequenceFiles.append( representFile ) # Finally we combine and trim all of the output Files combinedSequences = self.combineOutputSequences( outputSequenceFiles ) self.outputCombinedSequences( combinedSequences ) if __name__ == '__main__': resequencer = rDnaResequencer() resequencer()
{ "repo_name": "lufuhao/PB_rDnaTools", "path": "src/pbrdna/rDnaResequencer.py", "copies": "2", "size": "16747", "license": "bsd-3-clause", "hash": -8621925160506433000, "line_mean": 44.2621621622, "line_max": 103, "alpha_frac": 0.5759240461, "autogenerated": false, "ratio": 4.547108335595982, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.6123032381695982, "avg_score": null, "num_lines": null }
#! $ANDROID_HOME/tools/bin monkeyrunner # -*- coding: utf-8 -*- '''uiparser''' import os import sys import subprocess import datetime import logging from com.android.monkeyrunner import MonkeyRunner, MonkeyDevice, MonkeyImage #pylint: disable=import-error class NullHandler(logging.Handler): def emit(self, record): pass logging.getLogger(__name__).addHandler(NullHandler()) logging.basicConfig(level=logging.DEBUG) SHORT = 1 MIDDLE = 5 LONG = 15 ADB = os.path.join(os.environ['ANDROID_HOME'], 'platform-tools', 'adb') # Example of Ctrip Android Apk TARGET_PACKAGE = 'ctrip.android.view' LAUNCH_ACTIVITY = 'ctrip.business.splash.CtripSplashActivity' HOME_ACTIVITY = 'ctrip.android.publicproduct.home.view.CtripHomeActivity' FLIGHT_ACTIVITY = 'ctrip.android.flight.view.inland.FlightInquireActivity' START_COMPONENT = TARGET_PACKAGE + '/' + LAUNCH_ACTIVITY DEVICE_DIR = '/sdcard/uiparser/' HOST_DIR = './' def capture(device, index): '''''' _dumpXML = DEVICE_DIR + index + '.xml' _localXML = HOST_DIR + index + '.xml' _localImage = HOST_DIR + index + '.png' _shell = [ADB, 'shell', 'uiautomator', 'dump', _dumpXML] logging.debug(datetime.datetime.now()) subprocess.call(_shell) # Stupid uiautomator, always failed here! logging.debug(datetime.datetime.now()) #MonkeyRunner.sleep(MIDDLE) _shell = [ADB, 'pull', _dumpXML, _localXML] subprocess.call(_shell) _image = device.takeSnapshot() _image.writeToFile(_localImage, 'png') def uiparser(): '''Main Entry''' device = MonkeyRunner.waitForConnection(MIDDLE) _shell = [ADB, 'shell', 'rm', '-rf', DEVICE_DIR] subprocess.call(_shell) _shell = [ADB, 'shell', 'mkdir', '-p', DEVICE_DIR] subprocess.call(_shell) device.startActivity(component=START_COMPONENT) MonkeyRunner.sleep(MIDDLE) capture(device, str(0)) if __name__ == "__main__": # MonkeyRunner Jython version is 2.5.3 (Outdated!) logging.info(sys.version) uiparser()
{ "repo_name": "9468305/script", "path": "monkeyrunner/uiparser.py", "copies": "1", "size": "1999", "license": "mit", "hash": -8114209801657805000, "line_mean": 26.0135135135, "line_max": 106, "alpha_frac": 0.6858429215, "autogenerated": false, "ratio": 3.2241935483870967, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9401937186524962, "avg_score": 0.0016198566724267658, "num_lines": 74 }
### $ANTLR 2.7.6 (2005-12-22): "yacc.g" -> "YaccLexer.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> ### header action <<< ### preamble action >>> ### preamble action <<< ### >>>The Literals<<< literals = {} ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE ID = 4 COLON = 5 SEMICOLON = 6 CHAR = 7 STRING = 8 ERROR = 9 PREC = 10 ACTION = 11 OR = 12 HYPHEN = 13 CARROT = 14 BANG = 15 LETTER = 16 DIGIT = 17 COMMENT = 18 WS = 19 class Lexer(antlr.CharScanner) : ### user action >>> ### user action <<< def __init__(self, *argv, **kwargs) : antlr.CharScanner.__init__(self, *argv, **kwargs) self.caseSensitiveLiterals = True self.setCaseSensitive(True) self.literals = literals def nextToken(self): while True: try: ### try again .. while True: _token = None _ttype = INVALID_TYPE self.resetText() try: ## for char stream error handling try: ##for lexical error handling la1 = self.LA(1) if False: pass elif la1 and la1 in u':': pass self.mCOLON(True) theRetToken = self._returnToken elif la1 and la1 in u';': pass self.mSEMICOLON(True) theRetToken = self._returnToken elif la1 and la1 in u'-': pass self.mHYPHEN(True) theRetToken = self._returnToken elif la1 and la1 in u'^': pass self.mCARROT(True) theRetToken = self._returnToken elif la1 and la1 in u'!': pass self.mBANG(True) theRetToken = self._returnToken elif la1 and la1 in u'|': pass self.mOR(True) theRetToken = self._returnToken elif la1 and la1 in u'%': pass self.mPREC(True) theRetToken = self._returnToken elif la1 and la1 in u'\'': pass self.mCHAR(True) theRetToken = self._returnToken elif la1 and la1 in u'"': pass self.mSTRING(True) theRetToken = self._returnToken elif la1 and la1 in u'{': pass self.mACTION(True) theRetToken = self._returnToken elif la1 and la1 in u'/': pass self.mCOMMENT(True) theRetToken = self._returnToken elif la1 and la1 in u'\t\n\r ': pass self.mWS(True) theRetToken = self._returnToken else: if (self.LA(1)==u'e') and (self.LA(2)==u'r') and (self.LA(3)==u'r') and (self.LA(4)==u'o') and (self.LA(5)==u'r') and (True) and (True): pass self.mERROR(True) theRetToken = self._returnToken elif (_tokenSet_0.member(self.LA(1))) and (True) and (True) and (True) and (True) and (True) and (True): pass self.mID(True) theRetToken = self._returnToken else: self.default(self.LA(1)) if not self._returnToken: raise antlr.TryAgain ### found SKIP token ### option { testLiterals=true } self.testForLiteral(self._returnToken) ### return token to caller return self._returnToken ### handle lexical errors .... except antlr.RecognitionException, e: raise antlr.TokenStreamRecognitionException(e) ### handle char stream errors ... except antlr.CharStreamException,cse: if isinstance(cse, antlr.CharStreamIOException): raise antlr.TokenStreamIOException(cse.io) else: raise antlr.TokenStreamException(str(cse)) except antlr.TryAgain: pass def mCOLON(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = COLON _saveIndex = 0 pass self.match(':') self.set_return_token(_createToken, _token, _ttype, _begin) def mSEMICOLON(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = SEMICOLON _saveIndex = 0 pass self.match(';') self.set_return_token(_createToken, _token, _ttype, _begin) def mHYPHEN(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = HYPHEN _saveIndex = 0 pass self.match('-') self.set_return_token(_createToken, _token, _ttype, _begin) def mCARROT(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = CARROT _saveIndex = 0 pass self.match('^') self.set_return_token(_createToken, _token, _ttype, _begin) def mBANG(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = BANG _saveIndex = 0 pass self.match('!') self.set_return_token(_createToken, _token, _ttype, _begin) def mOR(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = OR _saveIndex = 0 pass self.match('|') self.set_return_token(_createToken, _token, _ttype, _begin) def mPREC(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = PREC _saveIndex = 0 pass self.match("%prec") self.set_return_token(_createToken, _token, _ttype, _begin) def mERROR(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = ERROR _saveIndex = 0 pass self.match("error") self.set_return_token(_createToken, _token, _ttype, _begin) def mID(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = ID _saveIndex = 0 pass self.mLETTER(False) while True: la1 = self.LA(1) if False: pass elif la1 and la1 in u'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz': pass self.mLETTER(False) elif la1 and la1 in u'0123456789': pass self.mDIGIT(False) elif la1 and la1 in u'_': pass self.match('_') elif la1 and la1 in u'.': pass self.match('.') else: break self.set_return_token(_createToken, _token, _ttype, _begin) def mLETTER(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = LETTER _saveIndex = 0 pass la1 = self.LA(1) if False: pass elif la1 and la1 in u'abcdefghijklmnopqrstuvwxyz': pass self.matchRange(u'a', u'z') elif la1 and la1 in u'ABCDEFGHIJKLMNOPQRSTUVWXYZ': pass self.matchRange(u'A', u'Z') else: self.raise_NoViableAlt(self.LA(1)) self.set_return_token(_createToken, _token, _ttype, _begin) def mDIGIT(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = DIGIT _saveIndex = 0 pass pass self.matchRange(u'0', u'9') self.set_return_token(_createToken, _token, _ttype, _begin) def mCHAR(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = CHAR _saveIndex = 0 pass self.match('\'') la1 = self.LA(1) if False: pass elif la1 and la1 in u'\\': pass pass self.match('\\') self.matchNot(antlr.EOF_CHAR) elif la1 and la1 in u'\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\u0008\t\n\u000b\u000c\r\u000e\u000f\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !"#$%&()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[]^_`abcdefghijklmnopqrstuvwxyz{|}~\u007f': pass pass self.match(_tokenSet_1) else: self.raise_NoViableAlt(self.LA(1)) self.match('\'') self.set_return_token(_createToken, _token, _ttype, _begin) def mSTRING(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = STRING _saveIndex = 0 pass self.match('"') while True: if (_tokenSet_2.member(self.LA(1))): pass self.matchNot('"') else: break self.match('"') self.set_return_token(_createToken, _token, _ttype, _begin) def mACTION(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = ACTION _saveIndex = 0 pass self.match('{') lcount= 1 incomment= False indquote= False insquote= False while lcount != 0: if self.LA(1) == '\\': self.consume() elif self.LA(1) == '/' and self.LA(2) == '*': if not indquote and not insquote: incomment= True self.consume() elif self.LA(1) == '*' and self.LA(2) == '/': if not indquote and not insquote: incomment= False self.consume() elif self.LA(1) == '\'': if not indquote and not incomment: insquote= not insquote elif self.LA(1) == '"': if not insquote and not incomment: indquote= not indquote elif self.LA(1) == antlr.EOF: _ttype = antlr.EOF elif self.LA(1) == '\n': self.newline() elif not indquote and not insquote and not incomment: if self.LA(1)== '}': lcount -= 1 elif self.LA(1)== '{': lcount += 1 self.consume() _ttype = antlr.SKIP; self.set_return_token(_createToken, _token, _ttype, _begin) def mCOMMENT(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = COMMENT _saveIndex = 0 pass self.match("/*") while True: if (self.LA(1)==u'*') and (_tokenSet_3.member(self.LA(2))): pass pass self.match('*') self.match(_tokenSet_3) elif (_tokenSet_4.member(self.LA(1))): pass self.match(_tokenSet_4) else: break self.match("*/") _ttype = antlr.SKIP self.set_return_token(_createToken, _token, _ttype, _begin) def mWS(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = WS _saveIndex = 0 pass _cnt50= 0 while True: la1 = self.LA(1) if False: pass elif la1 and la1 in u' ': pass self.match(' ') elif la1 and la1 in u'\r': pass self.match('\r') self.match('\n') self.newline() elif la1 and la1 in u'\n': pass self.match('\n') self.newline() elif la1 and la1 in u'\t': pass self.match('\t') else: break _cnt50 += 1 if _cnt50 < 1: self.raise_NoViableAlt(self.LA(1)) _ttype = antlr.SKIP self.set_return_token(_createToken, _token, _ttype, _begin) ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 0L, 576460743847706622L, 0L, 0L] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0()) ### generate bit set def mk_tokenSet_1(): ### var1 data = [ -549755813889L, -268435457L, 0L, 0L] return data _tokenSet_1 = antlr.BitSet(mk_tokenSet_1()) ### generate bit set def mk_tokenSet_2(): ### var1 data = [ -17179869185L, -1L, 0L, 0L] return data _tokenSet_2 = antlr.BitSet(mk_tokenSet_2()) ### generate bit set def mk_tokenSet_3(): ### var1 data = [ -140737488355329L, -1L, 0L, 0L] return data _tokenSet_3 = antlr.BitSet(mk_tokenSet_3()) ### generate bit set def mk_tokenSet_4(): ### var1 data = [ -4398046511105L, -1L, 0L, 0L] return data _tokenSet_4 = antlr.BitSet(mk_tokenSet_4()) ### __main__ header action >>> if __name__ == '__main__' : import sys import antlr import YaccLexer ### create lexer - shall read from stdin try: for token in YaccLexer.Lexer(): print token except antlr.TokenStreamException, e: print "error: exception caught while lexing: ", e ### __main__ header action <<<
{ "repo_name": "darkrsw/safe", "path": "lib/deckard/src/ptgen/YaccLexer.py", "copies": "3", "size": "15607", "license": "bsd-3-clause", "hash": 4365403030418061000, "line_mean": 31.3126293996, "line_max": 311, "alpha_frac": 0.441724867, "autogenerated": false, "ratio": 4.1897986577181205, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.613152352471812, "avg_score": null, "num_lines": null }
### $ANTLR 2.7.6 (2005-12-22): "yacc.g" -> "YaccParser.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> ### header action <<< ### preamble action>>> ### preamble action <<< ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE ID = 4 COLON = 5 SEMICOLON = 6 CHAR = 7 STRING = 8 ERROR = 9 PREC = 10 ACTION = 11 OR = 12 HYPHEN = 13 CARROT = 14 BANG = 15 LETTER = 16 DIGIT = 17 COMMENT = 18 WS = 19 class Parser(antlr.LLkParser): ### user action >>> ### user action <<< def __init__(self, *args, **kwargs): antlr.LLkParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames ### __init__ header action >>> self.NonTerminals= set([]) self.Terminals= set([]) self.Rules=[] ### __init__ header action <<< def grammar(self): try: ## for error handling pass _cnt3= 0 while True: if (self.LA(1)==ID): pass self.rule() else: break _cnt3 += 1 if _cnt3 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(EOF_TYPE) except antlr.RecognitionException, ex: self.reportError(ex) self.consume() self.consumeUntil(_tokenSet_0) def rule(self): id = None try: ## for error handling pass pass id = self.LT(1) self.match(ID) self.NonTerminals.add(id.getText()) self.match(COLON) self.rhs(id.getText()) self.match(SEMICOLON) except antlr.RecognitionException, ex: self.reportError(ex) self.consume() self.consumeUntil(_tokenSet_1) def rhs(self, lhs ): id = None c = None str = None pi = None pc = None right=[] try: ## for error handling pass while True: la1 = self.LA(1) if False: pass elif la1 and la1 in [ID]: pass pass id = self.LT(1) self.match(ID) right.append(("node",id.getText())) if id.getText() == id.getText().lower(): self.NonTerminals.add(id.getText()) else: self.Terminals.add(id.getText()) elif la1 and la1 in [CHAR]: pass pass c = self.LT(1) self.match(CHAR) right.append(("node",c.getText())) self.Terminals.add(c.getText()) elif la1 and la1 in [STRING]: pass pass str = self.LT(1) self.match(STRING) right.append(("node",str.getText())) self.Terminals.add(str.getText()) elif la1 and la1 in [ERROR]: pass self.match(ERROR) right.append(("error","error")) elif la1 and la1 in [PREC]: pass self.match(PREC) la1 = self.LA(1) if False: pass elif la1 and la1 in [ID]: pass pass pi = self.LT(1) self.match(ID) right.append(("%prec","%prec "+pi.getText())) elif la1 and la1 in [CHAR]: pass pass pc = self.LT(1) self.match(CHAR) right.append(("%prec","%prec "+pc.getText())) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) elif la1 and la1 in [ACTION]: pass self.match(ACTION) else: break self.Rules.append( (lhs,right) ) la1 = self.LA(1) if False: pass elif la1 and la1 in [OR]: pass self.match(OR) self.rhs(lhs) elif la1 and la1 in [SEMICOLON]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) except antlr.RecognitionException, ex: self.reportError(ex) self.consume() self.consumeUntil(_tokenSet_2) def rulespec(self): try: ## for error handling pass self.match(HYPHEN) except antlr.RecognitionException, ex: self.reportError(ex) self.consume() self.consumeUntil(_tokenSet_0) def treespec(self): try: ## for error handling la1 = self.LA(1) if False: pass elif la1 and la1 in [CARROT]: pass self.match(CARROT) elif la1 and la1 in [BANG]: pass self.match(BANG) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) except antlr.RecognitionException, ex: self.reportError(ex) self.consume() self.consumeUntil(_tokenSet_0) _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "ID", "COLON", "SEMICOLON", "CHAR", "STRING", "ERROR", "PREC", "ACTION", "OR", "HYPHEN", "CARROT", "BANG", "LETTER", "DIGIT", "COMMENT", "WS" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 2L, 0L] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0()) ### generate bit set def mk_tokenSet_1(): ### var1 data = [ 18L, 0L] return data _tokenSet_1 = antlr.BitSet(mk_tokenSet_1()) ### generate bit set def mk_tokenSet_2(): ### var1 data = [ 64L, 0L] return data _tokenSet_2 = antlr.BitSet(mk_tokenSet_2())
{ "repo_name": "daejunpark/jsaf", "path": "third_party/deckard/src/ptgen/YaccParser.py", "copies": "3", "size": "7103", "license": "bsd-3-clause", "hash": 5657232878070735000, "line_mean": 25.405204461, "line_max": 92, "alpha_frac": 0.4237646065, "autogenerated": false, "ratio": 4.2004730928444705, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.612423769934447, "avg_score": null, "num_lines": null }
### $ANTLR 2.7.7 (20060930): "xlwt/excel-formula.g" -> "ExcelFormulaParser.py"$ ### import antlr and other modules .. import sys from arelle.xlwt import antlr ### header action >>> import struct from arelle.xlwt import Utils from arelle.xlwt.UnicodeUtils import upack1 from arelle.xlwt.ExcelMagic import * _RVAdelta = {"R": 0, "V": 0x20, "A": 0x40} _RVAdeltaRef = {"R": 0, "V": 0x20, "A": 0x40, "D": 0x20} _RVAdeltaArea = {"R": 0, "V": 0x20, "A": 0x40, "D": 0} class FormulaParseException(Exception): """ An exception indicating that a Formula could not be successfully parsed. """ ### header action <<< ### preamble action>>> ### preamble action <<< ### import antlr.Token from arelle.xlwt.antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE TRUE_CONST = 4 FALSE_CONST = 5 STR_CONST = 6 NUM_CONST = 7 INT_CONST = 8 FUNC_IF = 9 FUNC_CHOOSE = 10 NAME = 11 QUOTENAME = 12 EQ = 13 NE = 14 GT = 15 LT = 16 GE = 17 LE = 18 ADD = 19 SUB = 20 MUL = 21 DIV = 22 POWER = 23 PERCENT = 24 LP = 25 RP = 26 LB = 27 RB = 28 COLON = 29 COMMA = 30 SEMICOLON = 31 REF2D = 32 REF2D_R1C1 = 33 BANG = 34 CONCAT = 35 class Parser(antlr.LLkParser): ### user action >>> ### user action <<< def __init__(self, *args, **kwargs): antlr.LLkParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames ### __init__ header action >>> self.rpn = b"" self.sheet_references = [] self.xcall_references = [] ### __init__ header action <<< def formula(self): self.expr("V") def expr(self, arg_type): self.prec0_expr(arg_type) while True: if ((self.LA(1) >= EQ and self.LA(1) <= LE)): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [EQ]: pass self.match(EQ) op = struct.pack('B', ptgEQ) elif la1 and la1 in [NE]: pass self.match(NE) op = struct.pack('B', ptgNE) elif la1 and la1 in [GT]: pass self.match(GT) op = struct.pack('B', ptgGT) elif la1 and la1 in [LT]: pass self.match(LT) op = struct.pack('B', ptgLT) elif la1 and la1 in [GE]: pass self.match(GE) op = struct.pack('B', ptgGE) elif la1 and la1 in [LE]: pass self.match(LE) op = struct.pack('B', ptgLE) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec0_expr(arg_type) self.rpn += op else: break def prec0_expr(self, arg_type ): pass self.prec1_expr(arg_type) while True: if (self.LA(1)==CONCAT): pass pass self.match(CONCAT) op = struct.pack('B', ptgConcat) self.prec1_expr(arg_type) self.rpn += op else: break def prec1_expr(self, arg_type ): pass self.prec2_expr(arg_type) while True: if (self.LA(1)==ADD or self.LA(1)==SUB): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [ADD]: pass self.match(ADD) op = struct.pack('B', ptgAdd) elif la1 and la1 in [SUB]: pass self.match(SUB) op = struct.pack('B', ptgSub) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec2_expr(arg_type) self.rpn += op; # print "**prec1_expr4 %s" % arg_type else: break def prec2_expr(self, arg_type ): pass self.prec3_expr(arg_type) while True: if (self.LA(1)==MUL or self.LA(1)==DIV): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [MUL]: pass self.match(MUL) op = struct.pack('B', ptgMul) elif la1 and la1 in [DIV]: pass self.match(DIV) op = struct.pack('B', ptgDiv) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec3_expr(arg_type) self.rpn += op else: break def prec3_expr(self, arg_type ): pass self.prec4_expr(arg_type) while True: if (self.LA(1)==POWER): pass pass self.match(POWER) op = struct.pack('B', ptgPower) self.prec4_expr(arg_type) self.rpn += op else: break def prec4_expr(self, arg_type ): pass self.prec5_expr(arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [PERCENT]: pass self.match(PERCENT) self.rpn += struct.pack('B', ptgPercent) elif la1 and la1 in [EOF,EQ,NE,GT,LT,GE,LE,ADD,SUB,MUL,DIV,POWER,RP,COMMA,SEMICOLON,CONCAT]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def prec5_expr(self, arg_type ): la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,LP,REF2D]: pass self.primary(arg_type) elif la1 and la1 in [SUB]: pass self.match(SUB) self.primary(arg_type) self.rpn += struct.pack('B', ptgUminus) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def primary(self, arg_type ): str_tok = None int_tok = None num_tok = None ref2d_tok = None ref2d1_tok = None ref2d2_tok = None ref3d_ref2d = None ref3d_ref2d2 = None name_tok = None func_tok = None la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST]: pass self.match(TRUE_CONST) self.rpn += struct.pack("2B", ptgBool, 1) elif la1 and la1 in [FALSE_CONST]: pass self.match(FALSE_CONST) self.rpn += struct.pack("2B", ptgBool, 0) elif la1 and la1 in [STR_CONST]: pass str_tok = self.LT(1) self.match(STR_CONST) self.rpn += struct.pack("B", ptgStr) + upack1(str_tok.text[1:-1].replace("\"\"", "\"")) elif la1 and la1 in [NUM_CONST]: pass num_tok = self.LT(1) self.match(NUM_CONST) self.rpn += struct.pack("<Bd", ptgNum, float(num_tok.text)) elif la1 and la1 in [FUNC_IF]: pass self.match(FUNC_IF) self.match(LP) self.expr("V") la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<BBH", ptgAttr, 0x02, 0) # tAttrIf pos0 = len(self.rpn) - 2 self.expr(arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<BBH", ptgAttr, 0x08, 0) # tAttrSkip pos1 = len(self.rpn) - 2 self.rpn = self.rpn[:pos0] + struct.pack("<H", pos1-pos0) + self.rpn[pos0+2:] self.expr(arg_type) self.match(RP) self.rpn += struct.pack("<BBH", ptgAttr, 0x08, 3) # tAttrSkip self.rpn += struct.pack("<BBH", ptgFuncVarR, 3, 1) # 3 = nargs, 1 = IF func pos2 = len(self.rpn) self.rpn = self.rpn[:pos1] + struct.pack("<H", pos2-(pos1+2)-1) + self.rpn[pos1+2:] elif la1 and la1 in [FUNC_CHOOSE]: pass self.match(FUNC_CHOOSE) arg_type = b"R" rpn_chunks = [] self.match(LP) self.expr("V") rpn_start = len(self.rpn) ref_markers = [len(self.sheet_references)] while True: if (self.LA(1)==COMMA or self.LA(1)==SEMICOLON): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) mark = len(self.rpn) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) elif la1 and la1 in [RP,COMMA,SEMICOLON]: pass self.rpn += struct.pack("B", ptgMissArg) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) rpn_chunks.append(self.rpn[mark:]) ref_markers.append(len(self.sheet_references)) else: break self.match(RP) self.rpn = self.rpn[:rpn_start] nc = len(rpn_chunks) chunklens = [len(chunk) for chunk in rpn_chunks] skiplens = [0] * nc skiplens[-1] = 3 for ic in range(nc-1, 0, -1): skiplens[ic-1] = skiplens[ic] + chunklens[ic] + 4 jump_pos = [2 * nc + 2] for ic in range(nc): jump_pos.append(jump_pos[-1] + chunklens[ic] + 4) chunk_shift = 2 * nc + 6 # size of tAttrChoose for ic in range(nc): for refx in range(ref_markers[ic], ref_markers[ic+1]): ref = self.sheet_references[refx] self.sheet_references[refx] = (ref[0], ref[1], ref[2] + chunk_shift) chunk_shift += 4 # size of tAttrSkip choose_rpn = [] choose_rpn.append(struct.pack("<BBH", ptgAttr, 0x04, nc)) # 0x04 is tAttrChoose choose_rpn.append(struct.pack("<%dH" % (nc+1), *jump_pos)) for ic in range(nc): choose_rpn.append(rpn_chunks[ic]) choose_rpn.append(struct.pack("<BBH", ptgAttr, 0x08, skiplens[ic])) # 0x08 is tAttrSkip choose_rpn.append(struct.pack("<BBH", ptgFuncVarV, nc+1, 100)) # 100 is CHOOSE fn self.rpn += b"".join(choose_rpn) elif la1 and la1 in [LP]: pass self.match(LP) self.expr(arg_type) self.match(RP) self.rpn += struct.pack("B", ptgParen) else: if (self.LA(1)==INT_CONST) and (_tokenSet_0.member(self.LA(2))): pass int_tok = self.LT(1) self.match(INT_CONST) # print "**int_const", int_tok.text int_value = int(int_tok.text) if int_value <= 65535: self.rpn += struct.pack("<BH", ptgInt, int_value) else: self.rpn += struct.pack("<Bd", ptgNum, float(int_value)) elif (self.LA(1)==REF2D) and (_tokenSet_0.member(self.LA(2))): pass ref2d_tok = self.LT(1) self.match(REF2D) # print "**ref2d %s %s" % (ref2d_tok.text, arg_type) r, c = Utils.cell_to_packed_rowcol(ref2d_tok.text) ptg = ptgRefR + _RVAdeltaRef[arg_type] self.rpn += struct.pack("<B2H", ptg, r, c) elif (self.LA(1)==REF2D) and (self.LA(2)==COLON): pass ref2d1_tok = self.LT(1) self.match(REF2D) self.match(COLON) ref2d2_tok = self.LT(1) self.match(REF2D) r1, c1 = Utils.cell_to_packed_rowcol(ref2d1_tok.text) r2, c2 = Utils.cell_to_packed_rowcol(ref2d2_tok.text) ptg = ptgAreaR + _RVAdeltaArea[arg_type] self.rpn += struct.pack("<B4H", ptg, r1, r2, c1, c2) elif (self.LA(1)==INT_CONST or self.LA(1)==NAME or self.LA(1)==QUOTENAME) and (self.LA(2)==COLON or self.LA(2)==BANG): pass sheet1=self.sheet() sheet2 = sheet1 la1 = self.LA(1) if False: pass elif la1 and la1 in [COLON]: pass self.match(COLON) sheet2=self.sheet() elif la1 and la1 in [BANG]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(BANG) ref3d_ref2d = self.LT(1) self.match(REF2D) ptg = ptgRef3dR + _RVAdeltaRef[arg_type] rpn_ref2d = b"" r1, c1 = Utils.cell_to_packed_rowcol(ref3d_ref2d.text) rpn_ref2d = struct.pack("<3H", 0x0000, r1, c1) la1 = self.LA(1) if False: pass elif la1 and la1 in [COLON]: pass self.match(COLON) ref3d_ref2d2 = self.LT(1) self.match(REF2D) ptg = ptgArea3dR + _RVAdeltaArea[arg_type] r2, c2 = Utils.cell_to_packed_rowcol(ref3d_ref2d2.text) rpn_ref2d = struct.pack("<5H", 0x0000, r1, r2, c1, c2) elif la1 and la1 in [EOF,EQ,NE,GT,LT,GE,LE,ADD,SUB,MUL,DIV,POWER,PERCENT,RP,COMMA,SEMICOLON,CONCAT]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<B", ptg) self.sheet_references.append((sheet1, sheet2, len(self.rpn))) self.rpn += rpn_ref2d elif (self.LA(1)==NAME) and (_tokenSet_0.member(self.LA(2))): name_tok = self.LT(1) self.match(NAME) raise Exception("[formula] found unexpected NAME token (%r)" % name_tok.txt) # #### TODO: handle references to defined names here elif (self.LA(1)==NAME) and (self.LA(2)==LP): func_tok = self.LT(1) self.match(NAME) func_toku = func_tok.text.upper() if func_toku in all_funcs_by_name: (opcode, min_argc, max_argc, func_type, arg_type_str) = all_funcs_by_name[func_toku] arg_type_list = list(arg_type_str) else: raise Exception("[formula] unknown function (%s)" % func_tok.text) # print "**func_tok1 %s %s" % (func_toku, func_type) xcall = opcode < 0 if xcall: # The name of the add-in function is passed as the 1st arg # of the hidden XCALL function self.xcall_references.append((func_toku, len(self.rpn) + 1)) self.rpn += struct.pack("<BHHH", ptgNameXR, 0xadde, # ##PATCHME## index to REF entry in EXTERNSHEET record 0xefbe, # ##PATCHME## one-based index to EXTERNNAME record 0x0000) # unused self.match(LP) arg_count=self.expr_list(arg_type_list, min_argc, max_argc) self.match(RP) if arg_count > max_argc or arg_count < min_argc: raise Exception("%d parameters for function: %s" % (arg_count, func_tok.text)) if xcall: func_ptg = ptgFuncVarR + _RVAdelta[func_type] self.rpn += struct.pack("<2BH", func_ptg, arg_count + 1, 255) # 255 is magic XCALL function elif min_argc == max_argc: func_ptg = ptgFuncR + _RVAdelta[func_type] self.rpn += struct.pack("<BH", func_ptg, opcode) elif arg_count == 1 and func_tok.text.upper() == "SUM": self.rpn += struct.pack("<BBH", ptgAttr, 0x10, 0) # tAttrSum else: func_ptg = ptgFuncVarR + _RVAdelta[func_type] self.rpn += struct.pack("<2BH", func_ptg, arg_count, opcode) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def sheet(self): ref = None sheet_ref_name = None sheet_ref_int = None sheet_ref_quote = None la1 = self.LA(1) if False: pass elif la1 and la1 in [NAME]: sheet_ref_name = self.LT(1) self.match(NAME) ref = sheet_ref_name.text elif la1 and la1 in [INT_CONST]: sheet_ref_int = self.LT(1) self.match(INT_CONST) ref = sheet_ref_int.text elif la1 and la1 in [QUOTENAME]: sheet_ref_quote = self.LT(1) self.match(QUOTENAME) ref = sheet_ref_quote.text[1:-1].replace("''", "'") else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return ref def expr_list(self, arg_type_list, min_argc, max_argc ): arg_cnt = None arg_cnt = 0 arg_type = arg_type_list[arg_cnt] # print "**expr_list1[%d] req=%s" % (arg_cnt, arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) arg_cnt += 1 while True: if (self.LA(1)==COMMA or self.LA(1)==SEMICOLON): pass if arg_cnt < len(arg_type_list): arg_type = arg_type_list[arg_cnt] else: arg_type = arg_type_list[-1] if arg_type == "+": arg_type = arg_type_list[-2] # print "**expr_list2[%d] req=%s" % (arg_cnt, arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) elif la1 and la1 in [RP,COMMA,SEMICOLON]: pass self.rpn += struct.pack("B", ptgMissArg) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) arg_cnt += 1 else: break elif la1 and la1 in [RP]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return arg_cnt _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "TRUE_CONST", "FALSE_CONST", "STR_CONST", "NUM_CONST", "INT_CONST", "FUNC_IF", "FUNC_CHOOSE", "NAME", "QUOTENAME", "EQ", "NE", "GT", "LT", "GE", "LE", "ADD", "SUB", "MUL", "DIV", "POWER", "PERCENT", "LP", "RP", "LB", "RB", "COLON", "COMMA", "SEMICOLON", "REF2D", "REF2D_R1C1", "BANG", "CONCAT" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 37681618946, 0] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0())
{ "repo_name": "sternshus/arelle2.7", "path": "svr-2.7/arelle/xlwt/ExcelFormulaParser.py", "copies": "1", "size": "22206", "license": "apache-2.0", "hash": -1909032448531912000, "line_mean": 32.6965098634, "line_max": 143, "alpha_frac": 0.4560929479, "autogenerated": false, "ratio": 3.5746941403734707, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9486907363785178, "avg_score": 0.008775944897658618, "num_lines": 659 }
### $ANTLR 2.7.7 (20060930): "xlwt/excel-formula.g" -> "ExcelFormulaParser.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> import struct import Utils from UnicodeUtils import upack1 from ExcelMagic import * _RVAdelta = {"R": 0, "V": 0x20, "A": 0x40} _RVAdeltaRef = {"R": 0, "V": 0x20, "A": 0x40, "D": 0x20} _RVAdeltaArea = {"R": 0, "V": 0x20, "A": 0x40, "D": 0} class FormulaParseException(Exception): """ An exception indicating that a Formula could not be successfully parsed. """ ### header action <<< ### preamble action>>> ### preamble action <<< ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE TRUE_CONST = 4 FALSE_CONST = 5 STR_CONST = 6 NUM_CONST = 7 INT_CONST = 8 FUNC_IF = 9 FUNC_CHOOSE = 10 NAME = 11 QUOTENAME = 12 EQ = 13 NE = 14 GT = 15 LT = 16 GE = 17 LE = 18 ADD = 19 SUB = 20 MUL = 21 DIV = 22 POWER = 23 PERCENT = 24 LP = 25 RP = 26 LB = 27 RB = 28 COLON = 29 COMMA = 30 SEMICOLON = 31 REF2D = 32 REF2D_R1C1 = 33 BANG = 34 CONCAT = 35 class Parser(antlr.LLkParser): ### user action >>> ### user action <<< def __init__(self, *args, **kwargs): antlr.LLkParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames ### __init__ header action >>> self.rpn = "" self.sheet_references = [] self.xcall_references = [] ### __init__ header action <<< def formula(self): pass self.expr("V") def expr(self, arg_type ): pass self.prec0_expr(arg_type) while True: if ((self.LA(1) >= EQ and self.LA(1) <= LE)): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [EQ]: pass self.match(EQ) op = struct.pack('B', ptgEQ) elif la1 and la1 in [NE]: pass self.match(NE) op = struct.pack('B', ptgNE) elif la1 and la1 in [GT]: pass self.match(GT) op = struct.pack('B', ptgGT) elif la1 and la1 in [LT]: pass self.match(LT) op = struct.pack('B', ptgLT) elif la1 and la1 in [GE]: pass self.match(GE) op = struct.pack('B', ptgGE) elif la1 and la1 in [LE]: pass self.match(LE) op = struct.pack('B', ptgLE) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec0_expr(arg_type) self.rpn += op else: break def prec0_expr(self, arg_type ): pass self.prec1_expr(arg_type) while True: if (self.LA(1)==CONCAT): pass pass self.match(CONCAT) op = struct.pack('B', ptgConcat) self.prec1_expr(arg_type) self.rpn += op else: break def prec1_expr(self, arg_type ): pass self.prec2_expr(arg_type) while True: if (self.LA(1)==ADD or self.LA(1)==SUB): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [ADD]: pass self.match(ADD) op = struct.pack('B', ptgAdd) elif la1 and la1 in [SUB]: pass self.match(SUB) op = struct.pack('B', ptgSub) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec2_expr(arg_type) self.rpn += op; # print "**prec1_expr4 %s" % arg_type else: break def prec2_expr(self, arg_type ): pass self.prec3_expr(arg_type) while True: if (self.LA(1)==MUL or self.LA(1)==DIV): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [MUL]: pass self.match(MUL) op = struct.pack('B', ptgMul) elif la1 and la1 in [DIV]: pass self.match(DIV) op = struct.pack('B', ptgDiv) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec3_expr(arg_type) self.rpn += op else: break def prec3_expr(self, arg_type ): pass self.prec4_expr(arg_type) while True: if (self.LA(1)==POWER): pass pass self.match(POWER) op = struct.pack('B', ptgPower) self.prec4_expr(arg_type) self.rpn += op else: break def prec4_expr(self, arg_type ): pass self.prec5_expr(arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [PERCENT]: pass self.match(PERCENT) self.rpn += struct.pack('B', ptgPercent) elif la1 and la1 in [EOF,EQ,NE,GT,LT,GE,LE,ADD,SUB,MUL,DIV,POWER,RP,COMMA,SEMICOLON,CONCAT]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def prec5_expr(self, arg_type ): la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,LP,REF2D]: pass self.primary(arg_type) elif la1 and la1 in [SUB]: pass self.match(SUB) self.primary(arg_type) self.rpn += struct.pack('B', ptgUminus) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def primary(self, arg_type ): str_tok = None int_tok = None num_tok = None ref2d_tok = None ref2d1_tok = None ref2d2_tok = None ref3d_ref2d = None ref3d_ref2d2 = None name_tok = None func_tok = None la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST]: pass self.match(TRUE_CONST) self.rpn += struct.pack("2B", ptgBool, 1) elif la1 and la1 in [FALSE_CONST]: pass self.match(FALSE_CONST) self.rpn += struct.pack("2B", ptgBool, 0) elif la1 and la1 in [STR_CONST]: pass str_tok = self.LT(1) self.match(STR_CONST) self.rpn += struct.pack("B", ptgStr) + upack1(str_tok.text[1:-1].replace("\"\"", "\"")) elif la1 and la1 in [NUM_CONST]: pass num_tok = self.LT(1) self.match(NUM_CONST) self.rpn += struct.pack("<Bd", ptgNum, float(num_tok.text)) elif la1 and la1 in [FUNC_IF]: pass self.match(FUNC_IF) self.match(LP) self.expr("V") la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<BBH", ptgAttr, 0x02, 0) # tAttrIf pos0 = len(self.rpn) - 2 self.expr(arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<BBH", ptgAttr, 0x08, 0) # tAttrSkip pos1 = len(self.rpn) - 2 self.rpn = self.rpn[:pos0] + struct.pack("<H", pos1-pos0) + self.rpn[pos0+2:] self.expr(arg_type) self.match(RP) self.rpn += struct.pack("<BBH", ptgAttr, 0x08, 3) # tAttrSkip self.rpn += struct.pack("<BBH", ptgFuncVarR, 3, 1) # 3 = nargs, 1 = IF func pos2 = len(self.rpn) self.rpn = self.rpn[:pos1] + struct.pack("<H", pos2-(pos1+2)-1) + self.rpn[pos1+2:] elif la1 and la1 in [FUNC_CHOOSE]: pass self.match(FUNC_CHOOSE) arg_type = "R" rpn_chunks = [] self.match(LP) self.expr("V") rpn_start = len(self.rpn) ref_markers = [len(self.sheet_references)] while True: if (self.LA(1)==COMMA or self.LA(1)==SEMICOLON): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) mark = len(self.rpn) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) elif la1 and la1 in [RP,COMMA,SEMICOLON]: pass self.rpn += struct.pack("B", ptgMissArg) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) rpn_chunks.append(self.rpn[mark:]) ref_markers.append(len(self.sheet_references)) else: break self.match(RP) self.rpn = self.rpn[:rpn_start] nc = len(rpn_chunks) chunklens = [len(chunk) for chunk in rpn_chunks] skiplens = [0] * nc skiplens[-1] = 3 for ic in xrange(nc-1, 0, -1): skiplens[ic-1] = skiplens[ic] + chunklens[ic] + 4 jump_pos = [2 * nc + 2] for ic in xrange(nc): jump_pos.append(jump_pos[-1] + chunklens[ic] + 4) chunk_shift = 2 * nc + 6 # size of tAttrChoose for ic in xrange(nc): for refx in xrange(ref_markers[ic], ref_markers[ic+1]): ref = self.sheet_references[refx] self.sheet_references[refx] = (ref[0], ref[1], ref[2] + chunk_shift) chunk_shift += 4 # size of tAttrSkip choose_rpn = [] choose_rpn.append(struct.pack("<BBH", ptgAttr, 0x04, nc)) # 0x04 is tAttrChoose choose_rpn.append(struct.pack("<%dH" % (nc+1), *jump_pos)) for ic in xrange(nc): choose_rpn.append(rpn_chunks[ic]) choose_rpn.append(struct.pack("<BBH", ptgAttr, 0x08, skiplens[ic])) # 0x08 is tAttrSkip choose_rpn.append(struct.pack("<BBH", ptgFuncVarV, nc+1, 100)) # 100 is CHOOSE fn self.rpn += "".join(choose_rpn) elif la1 and la1 in [LP]: pass self.match(LP) self.expr(arg_type) self.match(RP) self.rpn += struct.pack("B", ptgParen) else: if (self.LA(1)==INT_CONST) and (_tokenSet_0.member(self.LA(2))): pass int_tok = self.LT(1) self.match(INT_CONST) # print "**int_const", int_tok.text int_value = int(int_tok.text) if int_value <= 65535: self.rpn += struct.pack("<BH", ptgInt, int_value) else: self.rpn += struct.pack("<Bd", ptgNum, float(int_value)) elif (self.LA(1)==REF2D) and (_tokenSet_0.member(self.LA(2))): pass ref2d_tok = self.LT(1) self.match(REF2D) # print "**ref2d %s %s" % (ref2d_tok.text, arg_type) r, c = Utils.cell_to_packed_rowcol(ref2d_tok.text) ptg = ptgRefR + _RVAdeltaRef[arg_type] self.rpn += struct.pack("<B2H", ptg, r, c) elif (self.LA(1)==REF2D) and (self.LA(2)==COLON): pass ref2d1_tok = self.LT(1) self.match(REF2D) self.match(COLON) ref2d2_tok = self.LT(1) self.match(REF2D) r1, c1 = Utils.cell_to_packed_rowcol(ref2d1_tok.text) r2, c2 = Utils.cell_to_packed_rowcol(ref2d2_tok.text) ptg = ptgAreaR + _RVAdeltaArea[arg_type] self.rpn += struct.pack("<B4H", ptg, r1, r2, c1, c2) elif (self.LA(1)==INT_CONST or self.LA(1)==NAME or self.LA(1)==QUOTENAME) and (self.LA(2)==COLON or self.LA(2)==BANG): pass sheet1=self.sheet() sheet2 = sheet1 la1 = self.LA(1) if False: pass elif la1 and la1 in [COLON]: pass self.match(COLON) sheet2=self.sheet() elif la1 and la1 in [BANG]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(BANG) ref3d_ref2d = self.LT(1) self.match(REF2D) ptg = ptgRef3dR + _RVAdeltaRef[arg_type] rpn_ref2d = "" r1, c1 = Utils.cell_to_packed_rowcol(ref3d_ref2d.text) rpn_ref2d = struct.pack("<3H", 0x0000, r1, c1) la1 = self.LA(1) if False: pass elif la1 and la1 in [COLON]: pass self.match(COLON) ref3d_ref2d2 = self.LT(1) self.match(REF2D) ptg = ptgArea3dR + _RVAdeltaArea[arg_type] r2, c2 = Utils.cell_to_packed_rowcol(ref3d_ref2d2.text) rpn_ref2d = struct.pack("<5H", 0x0000, r1, r2, c1, c2) elif la1 and la1 in [EOF,EQ,NE,GT,LT,GE,LE,ADD,SUB,MUL,DIV,POWER,PERCENT,RP,COMMA,SEMICOLON,CONCAT]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<B", ptg) self.sheet_references.append((sheet1, sheet2, len(self.rpn))) self.rpn += rpn_ref2d elif (self.LA(1)==NAME) and (_tokenSet_0.member(self.LA(2))): pass name_tok = self.LT(1) self.match(NAME) raise Exception("[formula] found unexpected NAME token (%r)" % name_tok.txt) # #### TODO: handle references to defined names here elif (self.LA(1)==NAME) and (self.LA(2)==LP): pass func_tok = self.LT(1) self.match(NAME) func_toku = func_tok.text.upper() if func_toku in all_funcs_by_name: (opcode, min_argc, max_argc, func_type, arg_type_str) = all_funcs_by_name[func_toku] arg_type_list = list(arg_type_str) else: raise Exception("[formula] unknown function (%s)" % func_tok.text) # print "**func_tok1 %s %s" % (func_toku, func_type) xcall = opcode < 0 if xcall: # The name of the add-in function is passed as the 1st arg # of the hidden XCALL function self.xcall_references.append((func_toku, len(self.rpn) + 1)) self.rpn += struct.pack("<BHHH", ptgNameXR, 0xadde, # ##PATCHME## index to REF entry in EXTERNSHEET record 0xefbe, # ##PATCHME## one-based index to EXTERNNAME record 0x0000) # unused self.match(LP) arg_count=self.expr_list(arg_type_list, min_argc, max_argc) self.match(RP) if arg_count > max_argc or arg_count < min_argc: raise Exception, "%d parameters for function: %s" % (arg_count, func_tok.text) if xcall: func_ptg = ptgFuncVarR + _RVAdelta[func_type] self.rpn += struct.pack("<2BH", func_ptg, arg_count + 1, 255) # 255 is magic XCALL function elif min_argc == max_argc: func_ptg = ptgFuncR + _RVAdelta[func_type] self.rpn += struct.pack("<BH", func_ptg, opcode) elif arg_count == 1 and func_tok.text.upper() == "SUM": self.rpn += struct.pack("<BBH", ptgAttr, 0x10, 0) # tAttrSum else: func_ptg = ptgFuncVarR + _RVAdelta[func_type] self.rpn += struct.pack("<2BH", func_ptg, arg_count, opcode) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def sheet(self): ref = None sheet_ref_name = None sheet_ref_int = None sheet_ref_quote = None la1 = self.LA(1) if False: pass elif la1 and la1 in [NAME]: pass sheet_ref_name = self.LT(1) self.match(NAME) ref = sheet_ref_name.text elif la1 and la1 in [INT_CONST]: pass sheet_ref_int = self.LT(1) self.match(INT_CONST) ref = sheet_ref_int.text elif la1 and la1 in [QUOTENAME]: pass sheet_ref_quote = self.LT(1) self.match(QUOTENAME) ref = sheet_ref_quote.text[1:-1].replace("''", "'") else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return ref def expr_list(self, arg_type_list, min_argc, max_argc ): arg_cnt = None arg_cnt = 0 arg_type = arg_type_list[arg_cnt] # print "**expr_list1[%d] req=%s" % (arg_cnt, arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) arg_cnt += 1 while True: if (self.LA(1)==COMMA or self.LA(1)==SEMICOLON): pass if arg_cnt < len(arg_type_list): arg_type = arg_type_list[arg_cnt] else: arg_type = arg_type_list[-1] if arg_type == "+": arg_type = arg_type_list[-2] # print "**expr_list2[%d] req=%s" % (arg_cnt, arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) elif la1 and la1 in [RP,COMMA,SEMICOLON]: pass self.rpn += struct.pack("B", ptgMissArg) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) arg_cnt += 1 else: break elif la1 and la1 in [RP]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return arg_cnt _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "TRUE_CONST", "FALSE_CONST", "STR_CONST", "NUM_CONST", "INT_CONST", "FUNC_IF", "FUNC_CHOOSE", "NAME", "QUOTENAME", "EQ", "NE", "GT", "LT", "GE", "LE", "ADD", "SUB", "MUL", "DIV", "POWER", "PERCENT", "LP", "RP", "LB", "RB", "COLON", "COMMA", "SEMICOLON", "REF2D", "REF2D_R1C1", "BANG", "CONCAT" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 37681618946L, 0L] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0())
{ "repo_name": "chirilo/remo", "path": "vendor-local/lib/python/tablib/packages/xlwt/ExcelFormulaParser.py", "copies": "69", "size": "22362", "license": "bsd-3-clause", "hash": 8553294643542764000, "line_mean": 32.0310192024, "line_max": 143, "alpha_frac": 0.4545657812, "autogenerated": false, "ratio": 3.5888300433317286, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": null, "num_lines": null }
### $ANTLR 2.7.7 (20060930): "xlwt/excel-formula.g" -> "ExcelFormulaParser.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> import struct import Utils from UnicodeUtils import upack1 from ExcelMagic import * _RVAdelta = {"R": 0, "V": 0x20, "A": 0x40} _RVAdeltaRef = {"R": 0, "V": 0x20, "A": 0x40, "D": 0x20} _RVAdeltaArea = {"R": 0, "V": 0x20, "A": 0x40, "D": 0} class FormulaParseException(Exception): """ An exception indicating that a Formula could not be successfully parsed. """ ### header action <<< ### preamble action>>> ### preamble action <<< ### import antlr.Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE TRUE_CONST = 4 FALSE_CONST = 5 STR_CONST = 6 NUM_CONST = 7 INT_CONST = 8 FUNC_IF = 9 FUNC_CHOOSE = 10 NAME = 11 QUOTENAME = 12 EQ = 13 NE = 14 GT = 15 LT = 16 GE = 17 LE = 18 ADD = 19 SUB = 20 MUL = 21 DIV = 22 POWER = 23 PERCENT = 24 LP = 25 RP = 26 LB = 27 RB = 28 COLON = 29 COMMA = 30 SEMICOLON = 31 REF2D = 32 REF2D_R1C1 = 33 BANG = 34 CONCAT = 35 class Parser(antlr.LLkParser): ### user action >>> ### user action <<< def __init__(self, *args, **kwargs): antlr.LLkParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames ### __init__ header action >>> self.rpn = "" self.sheet_references = [] self.xcall_references = [] ### __init__ header action <<< def formula(self): pass self.expr("V") def expr(self, arg_type ): pass self.prec0_expr(arg_type) while True: if ((self.LA(1) >= EQ and self.LA(1) <= LE)): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [EQ]: pass self.match(EQ) op = struct.pack('B', ptgEQ) elif la1 and la1 in [NE]: pass self.match(NE) op = struct.pack('B', ptgNE) elif la1 and la1 in [GT]: pass self.match(GT) op = struct.pack('B', ptgGT) elif la1 and la1 in [LT]: pass self.match(LT) op = struct.pack('B', ptgLT) elif la1 and la1 in [GE]: pass self.match(GE) op = struct.pack('B', ptgGE) elif la1 and la1 in [LE]: pass self.match(LE) op = struct.pack('B', ptgLE) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec0_expr(arg_type) self.rpn += op else: break def prec0_expr(self, arg_type ): pass self.prec1_expr(arg_type) while True: if (self.LA(1) == CONCAT): pass pass self.match(CONCAT) op = struct.pack('B', ptgConcat) self.prec1_expr(arg_type) self.rpn += op else: break def prec1_expr(self, arg_type ): pass self.prec2_expr(arg_type) while True: if (self.LA(1) == ADD or self.LA(1) == SUB): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [ADD]: pass self.match(ADD) op = struct.pack('B', ptgAdd) elif la1 and la1 in [SUB]: pass self.match(SUB) op = struct.pack('B', ptgSub) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec2_expr(arg_type) self.rpn += op; # print "**prec1_expr4 %s" % arg_type else: break def prec2_expr(self, arg_type ): pass self.prec3_expr(arg_type) while True: if (self.LA(1) == MUL or self.LA(1) == DIV): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [MUL]: pass self.match(MUL) op = struct.pack('B', ptgMul) elif la1 and la1 in [DIV]: pass self.match(DIV) op = struct.pack('B', ptgDiv) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec3_expr(arg_type) self.rpn += op else: break def prec3_expr(self, arg_type ): pass self.prec4_expr(arg_type) while True: if (self.LA(1) == POWER): pass pass self.match(POWER) op = struct.pack('B', ptgPower) self.prec4_expr(arg_type) self.rpn += op else: break def prec4_expr(self, arg_type ): pass self.prec5_expr(arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [PERCENT]: pass self.match(PERCENT) self.rpn += struct.pack('B', ptgPercent) elif la1 and la1 in [EOF, EQ, NE, GT, LT, GE, LE, ADD, SUB, MUL, DIV, POWER, RP, COMMA, SEMICOLON, CONCAT]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def prec5_expr(self, arg_type ): la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST, FALSE_CONST, STR_CONST, NUM_CONST, INT_CONST, FUNC_IF, FUNC_CHOOSE, NAME, QUOTENAME, LP, REF2D]: pass self.primary(arg_type) elif la1 and la1 in [SUB]: pass self.match(SUB) self.primary(arg_type) self.rpn += struct.pack('B', ptgUminus) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def primary(self, arg_type ): str_tok = None int_tok = None num_tok = None ref2d_tok = None ref2d1_tok = None ref2d2_tok = None ref3d_ref2d = None ref3d_ref2d2 = None name_tok = None func_tok = None la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST]: pass self.match(TRUE_CONST) self.rpn += struct.pack("2B", ptgBool, 1) elif la1 and la1 in [FALSE_CONST]: pass self.match(FALSE_CONST) self.rpn += struct.pack("2B", ptgBool, 0) elif la1 and la1 in [STR_CONST]: pass str_tok = self.LT(1) self.match(STR_CONST) self.rpn += struct.pack("B", ptgStr) + upack1(str_tok.text[1:-1].replace("\"\"", "\"")) elif la1 and la1 in [NUM_CONST]: pass num_tok = self.LT(1) self.match(NUM_CONST) self.rpn += struct.pack("<Bd", ptgNum, float(num_tok.text)) elif la1 and la1 in [FUNC_IF]: pass self.match(FUNC_IF) self.match(LP) self.expr("V") la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<BBH", ptgAttr, 0x02, 0) # tAttrIf pos0 = len(self.rpn) - 2 self.expr(arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<BBH", ptgAttr, 0x08, 0) # tAttrSkip pos1 = len(self.rpn) - 2 self.rpn = self.rpn[:pos0] + struct.pack("<H", pos1 - pos0) + self.rpn[pos0 + 2:] self.expr(arg_type) self.match(RP) self.rpn += struct.pack("<BBH", ptgAttr, 0x08, 3) # tAttrSkip self.rpn += struct.pack("<BBH", ptgFuncVarR, 3, 1) # 3 = nargs, 1 = IF func pos2 = len(self.rpn) self.rpn = self.rpn[:pos1] + struct.pack("<H", pos2 - (pos1 + 2) - 1) + self.rpn[pos1 + 2:] elif la1 and la1 in [FUNC_CHOOSE]: pass self.match(FUNC_CHOOSE) arg_type = "R" rpn_chunks = [] self.match(LP) self.expr("V") rpn_start = len(self.rpn) ref_markers = [len(self.sheet_references)] while True: if (self.LA(1) == COMMA or self.LA(1) == SEMICOLON): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) mark = len(self.rpn) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST, FALSE_CONST, STR_CONST, NUM_CONST, INT_CONST, FUNC_IF, FUNC_CHOOSE, NAME, QUOTENAME, SUB, LP, REF2D]: pass self.expr(arg_type) elif la1 and la1 in [RP, COMMA, SEMICOLON]: pass self.rpn += struct.pack("B", ptgMissArg) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) rpn_chunks.append(self.rpn[mark:]) ref_markers.append(len(self.sheet_references)) else: break self.match(RP) self.rpn = self.rpn[:rpn_start] nc = len(rpn_chunks) chunklens = [len(chunk) for chunk in rpn_chunks] skiplens = [0] * nc skiplens[-1] = 3 for ic in xrange(nc - 1, 0, -1): skiplens[ic - 1] = skiplens[ic] + chunklens[ic] + 4 jump_pos = [2 * nc + 2] for ic in xrange(nc): jump_pos.append(jump_pos[-1] + chunklens[ic] + 4) chunk_shift = 2 * nc + 6 # size of tAttrChoose for ic in xrange(nc): for refx in xrange(ref_markers[ic], ref_markers[ic + 1]): ref = self.sheet_references[refx] self.sheet_references[refx] = (ref[0], ref[1], ref[2] + chunk_shift) chunk_shift += 4 # size of tAttrSkip choose_rpn = [] choose_rpn.append(struct.pack("<BBH", ptgAttr, 0x04, nc)) # 0x04 is tAttrChoose choose_rpn.append(struct.pack("<%dH" % (nc + 1), *jump_pos)) for ic in xrange(nc): choose_rpn.append(rpn_chunks[ic]) choose_rpn.append(struct.pack("<BBH", ptgAttr, 0x08, skiplens[ic])) # 0x08 is tAttrSkip choose_rpn.append(struct.pack("<BBH", ptgFuncVarV, nc + 1, 100)) # 100 is CHOOSE fn self.rpn += "".join(choose_rpn) elif la1 and la1 in [LP]: pass self.match(LP) self.expr(arg_type) self.match(RP) self.rpn += struct.pack("B", ptgParen) else: if (self.LA(1) == INT_CONST) and (_tokenSet_0.member(self.LA(2))): pass int_tok = self.LT(1) self.match(INT_CONST) # print "**int_const", int_tok.text int_value = int(int_tok.text) if int_value <= 65535: self.rpn += struct.pack("<BH", ptgInt, int_value) else: self.rpn += struct.pack("<Bd", ptgNum, float(int_value)) elif (self.LA(1) == REF2D) and (_tokenSet_0.member(self.LA(2))): pass ref2d_tok = self.LT(1) self.match(REF2D) # print "**ref2d %s %s" % (ref2d_tok.text, arg_type) r, c = Utils.cell_to_packed_rowcol(ref2d_tok.text) ptg = ptgRefR + _RVAdeltaRef[arg_type] self.rpn += struct.pack("<B2H", ptg, r, c) elif (self.LA(1) == REF2D) and (self.LA(2) == COLON): pass ref2d1_tok = self.LT(1) self.match(REF2D) self.match(COLON) ref2d2_tok = self.LT(1) self.match(REF2D) r1, c1 = Utils.cell_to_packed_rowcol(ref2d1_tok.text) r2, c2 = Utils.cell_to_packed_rowcol(ref2d2_tok.text) ptg = ptgAreaR + _RVAdeltaArea[arg_type] self.rpn += struct.pack("<B4H", ptg, r1, r2, c1, c2) elif (self.LA(1) == INT_CONST or self.LA(1) == NAME or self.LA(1) == QUOTENAME) and ( self.LA(2) == COLON or self.LA(2) == BANG): pass sheet1 = self.sheet() sheet2 = sheet1 la1 = self.LA(1) if False: pass elif la1 and la1 in [COLON]: pass self.match(COLON) sheet2 = self.sheet() elif la1 and la1 in [BANG]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(BANG) ref3d_ref2d = self.LT(1) self.match(REF2D) ptg = ptgRef3dR + _RVAdeltaRef[arg_type] rpn_ref2d = "" r1, c1 = Utils.cell_to_packed_rowcol(ref3d_ref2d.text) rpn_ref2d = struct.pack("<3H", 0x0000, r1, c1) la1 = self.LA(1) if False: pass elif la1 and la1 in [COLON]: pass self.match(COLON) ref3d_ref2d2 = self.LT(1) self.match(REF2D) ptg = ptgArea3dR + _RVAdeltaArea[arg_type] r2, c2 = Utils.cell_to_packed_rowcol(ref3d_ref2d2.text) rpn_ref2d = struct.pack("<5H", 0x0000, r1, r2, c1, c2) elif la1 and la1 in [EOF, EQ, NE, GT, LT, GE, LE, ADD, SUB, MUL, DIV, POWER, PERCENT, RP, COMMA, SEMICOLON, CONCAT]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<B", ptg) self.sheet_references.append((sheet1, sheet2, len(self.rpn))) self.rpn += rpn_ref2d elif (self.LA(1) == NAME) and (_tokenSet_0.member(self.LA(2))): pass name_tok = self.LT(1) self.match(NAME) raise Exception("[formula] found unexpected NAME token (%r)" % name_tok.txt) # #### TODO: handle references to defined names here elif (self.LA(1) == NAME) and (self.LA(2) == LP): pass func_tok = self.LT(1) self.match(NAME) func_toku = func_tok.text.upper() if func_toku in all_funcs_by_name: (opcode, min_argc, max_argc, func_type, arg_type_str) = all_funcs_by_name[func_toku] arg_type_list = list(arg_type_str) else: raise Exception("[formula] unknown function (%s)" % func_tok.text) # print "**func_tok1 %s %s" % (func_toku, func_type) xcall = opcode < 0 if xcall: # The name of the add-in function is passed as the 1st arg # of the hidden XCALL function self.xcall_references.append((func_toku, len(self.rpn) + 1)) self.rpn += struct.pack("<BHHH", ptgNameXR, 0xadde, # ##PATCHME## index to REF entry in EXTERNSHEET record 0xefbe, # ##PATCHME## one-based index to EXTERNNAME record 0x0000) # unused self.match(LP) arg_count = self.expr_list(arg_type_list, min_argc, max_argc) self.match(RP) if arg_count > max_argc or arg_count < min_argc: raise Exception, "%d parameters for function: %s" % (arg_count, func_tok.text) if xcall: func_ptg = ptgFuncVarR + _RVAdelta[func_type] self.rpn += struct.pack("<2BH", func_ptg, arg_count + 1, 255) # 255 is magic XCALL function elif min_argc == max_argc: func_ptg = ptgFuncR + _RVAdelta[func_type] self.rpn += struct.pack("<BH", func_ptg, opcode) elif arg_count == 1 and func_tok.text.upper() == "SUM": self.rpn += struct.pack("<BBH", ptgAttr, 0x10, 0) # tAttrSum else: func_ptg = ptgFuncVarR + _RVAdelta[func_type] self.rpn += struct.pack("<2BH", func_ptg, arg_count, opcode) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def sheet(self): ref = None sheet_ref_name = None sheet_ref_int = None sheet_ref_quote = None la1 = self.LA(1) if False: pass elif la1 and la1 in [NAME]: pass sheet_ref_name = self.LT(1) self.match(NAME) ref = sheet_ref_name.text elif la1 and la1 in [INT_CONST]: pass sheet_ref_int = self.LT(1) self.match(INT_CONST) ref = sheet_ref_int.text elif la1 and la1 in [QUOTENAME]: pass sheet_ref_quote = self.LT(1) self.match(QUOTENAME) ref = sheet_ref_quote.text[1:-1].replace("''", "'") else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return ref def expr_list(self, arg_type_list, min_argc, max_argc ): arg_cnt = None arg_cnt = 0 arg_type = arg_type_list[arg_cnt] # print "**expr_list1[%d] req=%s" % (arg_cnt, arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST, FALSE_CONST, STR_CONST, NUM_CONST, INT_CONST, FUNC_IF, FUNC_CHOOSE, NAME, QUOTENAME, SUB, LP, REF2D]: pass self.expr(arg_type) arg_cnt += 1 while True: if (self.LA(1) == COMMA or self.LA(1) == SEMICOLON): pass if arg_cnt < len(arg_type_list): arg_type = arg_type_list[arg_cnt] else: arg_type = arg_type_list[-1] if arg_type == "+": arg_type = arg_type_list[-2] # print "**expr_list2[%d] req=%s" % (arg_cnt, arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST, FALSE_CONST, STR_CONST, NUM_CONST, INT_CONST, FUNC_IF, FUNC_CHOOSE, NAME, QUOTENAME, SUB, LP, REF2D]: pass self.expr(arg_type) elif la1 and la1 in [RP, COMMA, SEMICOLON]: pass self.rpn += struct.pack("B", ptgMissArg) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) arg_cnt += 1 else: break elif la1 and la1 in [RP]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return arg_cnt _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "TRUE_CONST", "FALSE_CONST", "STR_CONST", "NUM_CONST", "INT_CONST", "FUNC_IF", "FUNC_CHOOSE", "NAME", "QUOTENAME", "EQ", "NE", "GT", "LT", "GE", "LE", "ADD", "SUB", "MUL", "DIV", "POWER", "PERCENT", "LP", "RP", "LB", "RB", "COLON", "COMMA", "SEMICOLON", "REF2D", "REF2D_R1C1", "BANG", "CONCAT" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [37681618946L, 0L] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0())
{ "repo_name": "rhefner1/ghidonations", "path": "xlwt/ExcelFormulaParser.py", "copies": "1", "size": "22904", "license": "apache-2.0", "hash": 1802339211981135000, "line_mean": 32.6823529412, "line_max": 120, "alpha_frac": 0.4429357317, "autogenerated": false, "ratio": 3.6488768519993626, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.958305206742496, "avg_score": 0.0017521032548803658, "num_lines": 680 }
### $ANTLR 2.7.7 (20060930): "xlwt/excel-formula.g" -> "ExcelFormulaParser.py"$ ### import antlr and other modules .. import sys from . import antlr ### header action >>> import struct from . import Utils from .UnicodeUtils import upack1 from .ExcelMagic import * _RVAdelta = {"R": 0, "V": 0x20, "A": 0x40} _RVAdeltaRef = {"R": 0, "V": 0x20, "A": 0x40, "D": 0x20} _RVAdeltaArea = {"R": 0, "V": 0x20, "A": 0x40, "D": 0} class FormulaParseException(Exception): """ An exception indicating that a Formula could not be successfully parsed. """ ### header action <<< ### preamble action>>> ### preamble action <<< ### import antlr.Token from .antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE TRUE_CONST = 4 FALSE_CONST = 5 STR_CONST = 6 NUM_CONST = 7 INT_CONST = 8 FUNC_IF = 9 FUNC_CHOOSE = 10 NAME = 11 QUOTENAME = 12 EQ = 13 NE = 14 GT = 15 LT = 16 GE = 17 LE = 18 ADD = 19 SUB = 20 MUL = 21 DIV = 22 POWER = 23 PERCENT = 24 LP = 25 RP = 26 LB = 27 RB = 28 COLON = 29 COMMA = 30 SEMICOLON = 31 REF2D = 32 REF2D_R1C1 = 33 BANG = 34 CONCAT = 35 class Parser(antlr.LLkParser): ### user action >>> ### user action <<< def __init__(self, *args, **kwargs): antlr.LLkParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames ### __init__ header action >>> self.rpn = b"" self.sheet_references = [] self.xcall_references = [] ### __init__ header action <<< def formula(self): self.expr("V") def expr(self, arg_type): self.prec0_expr(arg_type) while True: if ((self.LA(1) >= EQ and self.LA(1) <= LE)): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [EQ]: pass self.match(EQ) op = struct.pack('B', ptgEQ) elif la1 and la1 in [NE]: pass self.match(NE) op = struct.pack('B', ptgNE) elif la1 and la1 in [GT]: pass self.match(GT) op = struct.pack('B', ptgGT) elif la1 and la1 in [LT]: pass self.match(LT) op = struct.pack('B', ptgLT) elif la1 and la1 in [GE]: pass self.match(GE) op = struct.pack('B', ptgGE) elif la1 and la1 in [LE]: pass self.match(LE) op = struct.pack('B', ptgLE) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec0_expr(arg_type) self.rpn += op else: break def prec0_expr(self, arg_type ): pass self.prec1_expr(arg_type) while True: if (self.LA(1)==CONCAT): pass pass self.match(CONCAT) op = struct.pack('B', ptgConcat) self.prec1_expr(arg_type) self.rpn += op else: break def prec1_expr(self, arg_type ): pass self.prec2_expr(arg_type) while True: if (self.LA(1)==ADD or self.LA(1)==SUB): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [ADD]: pass self.match(ADD) op = struct.pack('B', ptgAdd) elif la1 and la1 in [SUB]: pass self.match(SUB) op = struct.pack('B', ptgSub) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec2_expr(arg_type) self.rpn += op; # print "**prec1_expr4 %s" % arg_type else: break def prec2_expr(self, arg_type ): pass self.prec3_expr(arg_type) while True: if (self.LA(1)==MUL or self.LA(1)==DIV): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [MUL]: pass self.match(MUL) op = struct.pack('B', ptgMul) elif la1 and la1 in [DIV]: pass self.match(DIV) op = struct.pack('B', ptgDiv) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.prec3_expr(arg_type) self.rpn += op else: break def prec3_expr(self, arg_type ): pass self.prec4_expr(arg_type) while True: if (self.LA(1)==POWER): pass pass self.match(POWER) op = struct.pack('B', ptgPower) self.prec4_expr(arg_type) self.rpn += op else: break def prec4_expr(self, arg_type ): pass self.prec5_expr(arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [PERCENT]: pass self.match(PERCENT) self.rpn += struct.pack('B', ptgPercent) elif la1 and la1 in [EOF,EQ,NE,GT,LT,GE,LE,ADD,SUB,MUL,DIV,POWER,RP,COMMA,SEMICOLON,CONCAT]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def prec5_expr(self, arg_type ): la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,LP,REF2D]: pass self.primary(arg_type) elif la1 and la1 in [SUB]: pass self.match(SUB) self.primary(arg_type) self.rpn += struct.pack('B', ptgUminus) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def primary(self, arg_type ): str_tok = None int_tok = None num_tok = None ref2d_tok = None ref2d1_tok = None ref2d2_tok = None ref3d_ref2d = None ref3d_ref2d2 = None name_tok = None func_tok = None la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST]: pass self.match(TRUE_CONST) self.rpn += struct.pack("2B", ptgBool, 1) elif la1 and la1 in [FALSE_CONST]: pass self.match(FALSE_CONST) self.rpn += struct.pack("2B", ptgBool, 0) elif la1 and la1 in [STR_CONST]: pass str_tok = self.LT(1) self.match(STR_CONST) self.rpn += struct.pack("B", ptgStr) + upack1(str_tok.text[1:-1].replace("\"\"", "\"")) elif la1 and la1 in [NUM_CONST]: pass num_tok = self.LT(1) self.match(NUM_CONST) self.rpn += struct.pack("<Bd", ptgNum, float(num_tok.text)) elif la1 and la1 in [FUNC_IF]: pass self.match(FUNC_IF) self.match(LP) self.expr("V") la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<BBH", ptgAttr, 0x02, 0) # tAttrIf pos0 = len(self.rpn) - 2 self.expr(arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<BBH", ptgAttr, 0x08, 0) # tAttrSkip pos1 = len(self.rpn) - 2 self.rpn = self.rpn[:pos0] + struct.pack("<H", pos1-pos0) + self.rpn[pos0+2:] self.expr(arg_type) self.match(RP) self.rpn += struct.pack("<BBH", ptgAttr, 0x08, 3) # tAttrSkip self.rpn += struct.pack("<BBH", ptgFuncVarR, 3, 1) # 3 = nargs, 1 = IF func pos2 = len(self.rpn) self.rpn = self.rpn[:pos1] + struct.pack("<H", pos2-(pos1+2)-1) + self.rpn[pos1+2:] elif la1 and la1 in [FUNC_CHOOSE]: pass self.match(FUNC_CHOOSE) arg_type = b"R" rpn_chunks = [] self.match(LP) self.expr("V") rpn_start = len(self.rpn) ref_markers = [len(self.sheet_references)] while True: if (self.LA(1)==COMMA or self.LA(1)==SEMICOLON): pass la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) mark = len(self.rpn) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) elif la1 and la1 in [RP,COMMA,SEMICOLON]: pass self.rpn += struct.pack("B", ptgMissArg) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) rpn_chunks.append(self.rpn[mark:]) ref_markers.append(len(self.sheet_references)) else: break self.match(RP) self.rpn = self.rpn[:rpn_start] nc = len(rpn_chunks) chunklens = [len(chunk) for chunk in rpn_chunks] skiplens = [0] * nc skiplens[-1] = 3 for ic in range(nc-1, 0, -1): skiplens[ic-1] = skiplens[ic] + chunklens[ic] + 4 jump_pos = [2 * nc + 2] for ic in range(nc): jump_pos.append(jump_pos[-1] + chunklens[ic] + 4) chunk_shift = 2 * nc + 6 # size of tAttrChoose for ic in range(nc): for refx in range(ref_markers[ic], ref_markers[ic+1]): ref = self.sheet_references[refx] self.sheet_references[refx] = (ref[0], ref[1], ref[2] + chunk_shift) chunk_shift += 4 # size of tAttrSkip choose_rpn = [] choose_rpn.append(struct.pack("<BBH", ptgAttr, 0x04, nc)) # 0x04 is tAttrChoose choose_rpn.append(struct.pack("<%dH" % (nc+1), *jump_pos)) for ic in range(nc): choose_rpn.append(rpn_chunks[ic]) choose_rpn.append(struct.pack("<BBH", ptgAttr, 0x08, skiplens[ic])) # 0x08 is tAttrSkip choose_rpn.append(struct.pack("<BBH", ptgFuncVarV, nc+1, 100)) # 100 is CHOOSE fn self.rpn += b"".join(choose_rpn) elif la1 and la1 in [LP]: pass self.match(LP) self.expr(arg_type) self.match(RP) self.rpn += struct.pack("B", ptgParen) else: if (self.LA(1)==INT_CONST) and (_tokenSet_0.member(self.LA(2))): pass int_tok = self.LT(1) self.match(INT_CONST) # print "**int_const", int_tok.text int_value = int(int_tok.text) if int_value <= 65535: self.rpn += struct.pack("<BH", ptgInt, int_value) else: self.rpn += struct.pack("<Bd", ptgNum, float(int_value)) elif (self.LA(1)==REF2D) and (_tokenSet_0.member(self.LA(2))): pass ref2d_tok = self.LT(1) self.match(REF2D) # print "**ref2d %s %s" % (ref2d_tok.text, arg_type) r, c = Utils.cell_to_packed_rowcol(ref2d_tok.text) ptg = ptgRefR + _RVAdeltaRef[arg_type] self.rpn += struct.pack("<B2H", ptg, r, c) elif (self.LA(1)==REF2D) and (self.LA(2)==COLON): pass ref2d1_tok = self.LT(1) self.match(REF2D) self.match(COLON) ref2d2_tok = self.LT(1) self.match(REF2D) r1, c1 = Utils.cell_to_packed_rowcol(ref2d1_tok.text) r2, c2 = Utils.cell_to_packed_rowcol(ref2d2_tok.text) ptg = ptgAreaR + _RVAdeltaArea[arg_type] self.rpn += struct.pack("<B4H", ptg, r1, r2, c1, c2) elif (self.LA(1)==INT_CONST or self.LA(1)==NAME or self.LA(1)==QUOTENAME) and (self.LA(2)==COLON or self.LA(2)==BANG): pass sheet1=self.sheet() sheet2 = sheet1 la1 = self.LA(1) if False: pass elif la1 and la1 in [COLON]: pass self.match(COLON) sheet2=self.sheet() elif la1 and la1 in [BANG]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(BANG) ref3d_ref2d = self.LT(1) self.match(REF2D) ptg = ptgRef3dR + _RVAdeltaRef[arg_type] rpn_ref2d = b"" r1, c1 = Utils.cell_to_packed_rowcol(ref3d_ref2d.text) rpn_ref2d = struct.pack("<3H", 0x0000, r1, c1) la1 = self.LA(1) if False: pass elif la1 and la1 in [COLON]: pass self.match(COLON) ref3d_ref2d2 = self.LT(1) self.match(REF2D) ptg = ptgArea3dR + _RVAdeltaArea[arg_type] r2, c2 = Utils.cell_to_packed_rowcol(ref3d_ref2d2.text) rpn_ref2d = struct.pack("<5H", 0x0000, r1, r2, c1, c2) elif la1 and la1 in [EOF,EQ,NE,GT,LT,GE,LE,ADD,SUB,MUL,DIV,POWER,PERCENT,RP,COMMA,SEMICOLON,CONCAT]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.rpn += struct.pack("<B", ptg) self.sheet_references.append((sheet1, sheet2, len(self.rpn))) self.rpn += rpn_ref2d elif (self.LA(1)==NAME) and (_tokenSet_0.member(self.LA(2))): name_tok = self.LT(1) self.match(NAME) raise Exception("[formula] found unexpected NAME token (%r)" % name_tok.txt) # #### TODO: handle references to defined names here elif (self.LA(1)==NAME) and (self.LA(2)==LP): func_tok = self.LT(1) self.match(NAME) func_toku = func_tok.text.upper() if func_toku in all_funcs_by_name: (opcode, min_argc, max_argc, func_type, arg_type_str) = all_funcs_by_name[func_toku] arg_type_list = list(arg_type_str) else: raise Exception("[formula] unknown function (%s)" % func_tok.text) # print "**func_tok1 %s %s" % (func_toku, func_type) xcall = opcode < 0 if xcall: # The name of the add-in function is passed as the 1st arg # of the hidden XCALL function self.xcall_references.append((func_toku, len(self.rpn) + 1)) self.rpn += struct.pack("<BHHH", ptgNameXR, 0xadde, # ##PATCHME## index to REF entry in EXTERNSHEET record 0xefbe, # ##PATCHME## one-based index to EXTERNNAME record 0x0000) # unused self.match(LP) arg_count=self.expr_list(arg_type_list, min_argc, max_argc) self.match(RP) if arg_count > max_argc or arg_count < min_argc: raise Exception("%d parameters for function: %s" % (arg_count, func_tok.text)) if xcall: func_ptg = ptgFuncVarR + _RVAdelta[func_type] self.rpn += struct.pack("<2BH", func_ptg, arg_count + 1, 255) # 255 is magic XCALL function elif min_argc == max_argc: func_ptg = ptgFuncR + _RVAdelta[func_type] self.rpn += struct.pack("<BH", func_ptg, opcode) elif arg_count == 1 and func_tok.text.upper() == "SUM": self.rpn += struct.pack("<BBH", ptgAttr, 0x10, 0) # tAttrSum else: func_ptg = ptgFuncVarR + _RVAdelta[func_type] self.rpn += struct.pack("<2BH", func_ptg, arg_count, opcode) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) def sheet(self): ref = None sheet_ref_name = None sheet_ref_int = None sheet_ref_quote = None la1 = self.LA(1) if False: pass elif la1 and la1 in [NAME]: sheet_ref_name = self.LT(1) self.match(NAME) ref = sheet_ref_name.text elif la1 and la1 in [INT_CONST]: sheet_ref_int = self.LT(1) self.match(INT_CONST) ref = sheet_ref_int.text elif la1 and la1 in [QUOTENAME]: sheet_ref_quote = self.LT(1) self.match(QUOTENAME) ref = sheet_ref_quote.text[1:-1].replace("''", "'") else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return ref def expr_list(self, arg_type_list, min_argc, max_argc ): arg_cnt = None arg_cnt = 0 arg_type = arg_type_list[arg_cnt] # print "**expr_list1[%d] req=%s" % (arg_cnt, arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) arg_cnt += 1 while True: if (self.LA(1)==COMMA or self.LA(1)==SEMICOLON): pass if arg_cnt < len(arg_type_list): arg_type = arg_type_list[arg_cnt] else: arg_type = arg_type_list[-1] if arg_type == "+": arg_type = arg_type_list[-2] # print "**expr_list2[%d] req=%s" % (arg_cnt, arg_type) la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass self.match(SEMICOLON) elif la1 and la1 in [COMMA]: pass self.match(COMMA) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) la1 = self.LA(1) if False: pass elif la1 and la1 in [TRUE_CONST,FALSE_CONST,STR_CONST,NUM_CONST,INT_CONST,FUNC_IF,FUNC_CHOOSE,NAME,QUOTENAME,SUB,LP,REF2D]: pass self.expr(arg_type) elif la1 and la1 in [RP,COMMA,SEMICOLON]: pass self.rpn += struct.pack("B", ptgMissArg) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) arg_cnt += 1 else: break elif la1 and la1 in [RP]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return arg_cnt _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "TRUE_CONST", "FALSE_CONST", "STR_CONST", "NUM_CONST", "INT_CONST", "FUNC_IF", "FUNC_CHOOSE", "NAME", "QUOTENAME", "EQ", "NE", "GT", "LT", "GE", "LE", "ADD", "SUB", "MUL", "DIV", "POWER", "PERCENT", "LP", "RP", "LB", "RB", "COLON", "COMMA", "SEMICOLON", "REF2D", "REF2D_R1C1", "BANG", "CONCAT" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 37681618946, 0] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0())
{ "repo_name": "bopo/tablib", "path": "tablib/packages/xlwt3/ExcelFormulaParser.py", "copies": "46", "size": "22812", "license": "mit", "hash": -3495928913831055400, "line_mean": 32.6160849772, "line_max": 143, "alpha_frac": 0.4417850254, "autogenerated": false, "ratio": 3.6540124939932723, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": null, "num_lines": null }
### $ANTLR 2.7.7 (20160104): "lexed.g" -> "LexedLexer.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> ### header action <<< ### preamble action >>> ### preamble action <<< ### >>>The Literals<<< literals = {} ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE DIGIT = 4 COLON = 5 SPACES = 6 NEWLINE = 7 NUMBER = 8 SYMBOL = 9 QUOTED_LITERAL = 10 CONTENT = 11 class Lexer(antlr.CharScanner) : ### user action >>> ### user action <<< def __init__(self, *argv, **kwargs) : antlr.CharScanner.__init__(self, *argv, **kwargs) self.caseSensitiveLiterals = True self.setCaseSensitive(True) self.literals = literals def nextToken(self): while True: try: ### try again .. while True: _token = None _ttype = INVALID_TYPE self.resetText() try: ## for char stream error handling try: ##for lexical error handling la1 = self.LA(1) if False: pass elif la1 and la1 in u':': pass self.mCOLON(True) theRetToken = self._returnToken elif la1 and la1 in u' ': pass self.mSPACES(True) theRetToken = self._returnToken elif la1 and la1 in u'\n': pass self.mNEWLINE(True) theRetToken = self._returnToken elif la1 and la1 in u'0123456789': pass self.mNUMBER(True) theRetToken = self._returnToken elif la1 and la1 in u'ABCDEFGHIJKLMNOPQRSTUVWXYZ': pass self.mSYMBOL(True) theRetToken = self._returnToken elif la1 and la1 in u'"': pass self.mQUOTED_LITERAL(True) theRetToken = self._returnToken elif la1 and la1 in u'(': pass self.mCONTENT(True) theRetToken = self._returnToken else: self.default(self.LA(1)) if not self._returnToken: raise antlr.TryAgain ### found SKIP token ### return token to caller return self._returnToken ### handle lexical errors .... except antlr.RecognitionException, e: raise antlr.TokenStreamRecognitionException(e) ### handle char stream errors ... except antlr.CharStreamException,cse: if isinstance(cse, antlr.CharStreamIOException): raise antlr.TokenStreamIOException(cse.io) else: raise antlr.TokenStreamException(str(cse)) except antlr.TryAgain: pass def mDIGIT(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = DIGIT _saveIndex = 0 pass self.matchRange(u'0', u'9') self.set_return_token(_createToken, _token, _ttype, _begin) def mCOLON(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = COLON _saveIndex = 0 pass self.match(':') self.set_return_token(_createToken, _token, _ttype, _begin) def mSPACES(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = SPACES _saveIndex = 0 pass _cnt5= 0 while True: if (self.LA(1)==u' '): pass self.match(' ') else: break _cnt5 += 1 if _cnt5 < 1: self.raise_NoViableAlt(self.LA(1)) self.set_return_token(_createToken, _token, _ttype, _begin) def mNEWLINE(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = NEWLINE _saveIndex = 0 pass self.match('\n') self.newline(); self.set_return_token(_createToken, _token, _ttype, _begin) def mNUMBER(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = NUMBER _saveIndex = 0 pass _cnt9= 0 while True: if ((self.LA(1) >= u'0' and self.LA(1) <= u'9')): pass self.mDIGIT(False) else: break _cnt9 += 1 if _cnt9 < 1: self.raise_NoViableAlt(self.LA(1)) self.set_return_token(_createToken, _token, _ttype, _begin) def mSYMBOL(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = SYMBOL _saveIndex = 0 pass _cnt12= 0 while True: if ((self.LA(1) >= u'A' and self.LA(1) <= u'Z')): pass self.matchRange(u'A', u'Z') else: break _cnt12 += 1 if _cnt12 < 1: self.raise_NoViableAlt(self.LA(1)) self.set_return_token(_createToken, _token, _ttype, _begin) def mQUOTED_LITERAL(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = QUOTED_LITERAL _saveIndex = 0 pass self.match('"') _cnt15= 0 while True: la1 = self.LA(1) if False: pass elif la1 and la1 in u'abcdefghijklmnopqrstuvwxyz': pass self.matchRange(u'a', u'z') elif la1 and la1 in u'_': pass self.match('_') else: break _cnt15 += 1 if _cnt15 < 1: self.raise_NoViableAlt(self.LA(1)) self.match('"') self.set_return_token(_createToken, _token, _ttype, _begin) def mCONTENT(self, _createToken): _ttype = 0 _token = None _begin = self.text.length() _ttype = CONTENT _saveIndex = 0 pass _saveIndex = self.text.length() self.match('(') self.text.setLength(_saveIndex) while True: ### nongreedy exit test if ((self.LA(1)==u')') and (self.LA(2)==u'\n')): break if ((self.LA(1) >= u'\u0000' and self.LA(1) <= u'\u00ff')) and ((self.LA(2) >= u'\u0000' and self.LA(2) <= u'\u00ff')): pass self.matchNot(antlr.EOF_CHAR) else: break _saveIndex = self.text.length() self.match(')') self.text.setLength(_saveIndex) _saveIndex = self.text.length() self.mNEWLINE(False) self.text.setLength(_saveIndex) self.set_return_token(_createToken, _token, _ttype, _begin) ### __main__ header action >>> if __name__ == '__main__' : import sys import antlr import LexedLexer ### create lexer - shall read from stdin try: for token in LexedLexer.Lexer(): print token except antlr.TokenStreamException, e: print "error: exception caught while lexing: ", e ### __main__ header action <<<
{ "repo_name": "andybalaam/pepper", "path": "old/pepper1/src/parse/LexedLexer.py", "copies": "1", "size": "8649", "license": "mit", "hash": 869102682061540100, "line_mean": 31.1524163569, "line_max": 131, "alpha_frac": 0.4403977338, "autogenerated": false, "ratio": 4.3201798201798205, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.526057755397982, "avg_score": null, "num_lines": null }
### $ANTLR 2.7.7 (20160104): "lexed.g" -> "LexedParser.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> ### header action <<< ### preamble action>>> ### preamble action <<< ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE DIGIT = 4 COLON = 5 SPACES = 6 NEWLINE = 7 NUMBER = 8 SYMBOL = 9 QUOTED_LITERAL = 10 CONTENT = 11 class Parser(antlr.LLkParser): ### user action >>> ### user action <<< def __init__(self, *args, **kwargs): antlr.LLkParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames def tokenName(self): t = None s = None l = None pass la1 = self.LA(1) if False: pass elif la1 and la1 in [SYMBOL]: pass s = self.LT(1) self.match(SYMBOL) t=s elif la1 and la1 in [QUOTED_LITERAL]: pass l = self.LT(1) self.match(QUOTED_LITERAL) t=l else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) return t def line(self): t = None linenum = None colnum = None content = None try: ## for error handling pass linenum = self.LT(1) self.match(NUMBER) self.match(COLON) colnum = self.LT(1) self.match(NUMBER) self.match(SPACES) symbol=self.tokenName() la1 = self.LA(1) if False: pass elif la1 and la1 in [CONTENT]: pass content = self.LT(1) self.match(CONTENT) elif la1 and la1 in [NEWLINE]: pass self.match(NEWLINE) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) from antlr import CommonToken import PepperParser t = CommonToken( type = PepperParser._tokenNames.index( symbol.getText() ) ) if content is not None: t.setText( content.getText() ) t.setLine( int( linenum.getText() ) ) t.setColumn( int( colnum.getText() ) ) except antlr.RecognitionException, ex: return None return t _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "DIGIT", "COLON", "SPACES", "NEWLINE", "NUMBER", "SYMBOL", "QUOTED_LITERAL", "CONTENT" ]
{ "repo_name": "andybalaam/pepper", "path": "old/pepper1/src/parse/LexedParser.py", "copies": "1", "size": "3046", "license": "mit", "hash": -8377346580719194000, "line_mean": 23.368, "line_max": 84, "alpha_frac": 0.4878529219, "autogenerated": false, "ratio": 3.798004987531172, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4785857909431172, "avg_score": null, "num_lines": null }
### $ANTLR 2.7.7 (20160104): "newsyntaxpepper.g" -> "NewSyntaxPepperParser.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> ### header action <<< ### preamble action>>> ### preamble action <<< ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE WHITESPACE = 4 COMMENT = 5 DIGIT = 6 DIGITS = 7 INT = 8 DOT = 9 FLOAT = 10 INT_OR_DOT_OR_FLOAT = 11 TRIPLEDOUBLEQUOTE = 12 DOUBLEQUOTE = 13 DOUBLEQUOTESTRING = 14 TRIPLEDOUBLEQUOTESTRING = 15 STRING = 16 LBRACE = 17 RBRACE = 18 PIPE = 19 LPAREN = 20 RPAREN = 21 LSQUBR = 22 RSQUBR = 23 COMMA = 24 SEMICOLON = 25 STARTSYMBOLCHAR = 26 MIDSYMBOLCHAR = 27 SYMBOL = 28 PLUS = 29 MINUS = 30 TIMES = 31 PLUSEQUALS = 32 GT = 33 LT = 34 COLON = 35 EQUALS = 36 EQUALSEQUALS = 37 LITERAL_def = 38 LITERAL_def_init = 39 LITERAL_class = 40 LITERAL_interface = 41 LITERAL_while = 42 LITERAL_import = 43 LITERAL_quote = 44 NEWLINE = 45 INDENT = 46 DEDENT = 47 LITERAL_var = 48 LITERAL_return = 49 class Parser(antlr.LLkParser): ### user action >>> ### user action <<< def __init__(self, *args, **kwargs): antlr.LLkParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames self.buildTokenTypeASTClassMap() self.astFactory = antlr.ASTFactory(self.getTokenTypeToASTClassMap()) self.astFactory.setASTNodeClass() def program(self): self.returnAST = None currentAST = antlr.ASTPair() program_AST = None pass while True: if (_tokenSet_0.member(self.LA(1))): pass self.statement() self.addASTChild(currentAST, self.returnAST) else: break tmp31_AST = None tmp31_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp31_AST) self.match(EOF_TYPE) program_AST = currentAST.root self.returnAST = program_AST def statement(self): self.returnAST = None currentAST = antlr.ASTPair() statement_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [SEMICOLON]: pass tmp32_AST = None tmp32_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp32_AST) self.match(SEMICOLON) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_def]: pass self.functionDefinition() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_class]: pass self.classDefinition() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_interface]: pass self.interfaceDefinition() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_while]: pass self.whileStatement() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_import]: pass self.importStatement() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LBRACE]: pass self.codeBlock() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root else: if (_tokenSet_1.member(self.LA(1))) and (_tokenSet_2.member(self.LA(2))): pass self.initialisationOrExpression() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif (self.LA(1)==SYMBOL) and (self.LA(2)==PLUSEQUALS): pass self.modification() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = statement_AST def initialisationOrExpression(self): self.returnAST = None currentAST = antlr.ASTPair() initialisationOrExpression_AST = None pass self.expression() self.addASTChild(currentAST, self.returnAST) if (self.LA(1)==SYMBOL) and (self.LA(2)==EQUALS): pass tmp33_AST = None tmp33_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp33_AST) self.match(SYMBOL) tmp34_AST = None tmp34_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp34_AST) self.match(EQUALS) self.expression() self.addASTChild(currentAST, self.returnAST) elif (_tokenSet_3.member(self.LA(1))) and (_tokenSet_4.member(self.LA(2))): pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) initialisationOrExpression_AST = currentAST.root self.returnAST = initialisationOrExpression_AST def modification(self): self.returnAST = None currentAST = antlr.ASTPair() modification_AST = None pass tmp35_AST = None tmp35_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp35_AST) self.match(SYMBOL) tmp36_AST = None tmp36_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp36_AST) self.match(PLUSEQUALS) self.expression() self.addASTChild(currentAST, self.returnAST) modification_AST = currentAST.root self.returnAST = modification_AST def functionDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() functionDefinition_AST = None pass tmp37_AST = None tmp37_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp37_AST) self.match(LITERAL_def) self.expression() self.addASTChild(currentAST, self.returnAST) tmp38_AST = None tmp38_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp38_AST) self.match(SYMBOL) self.typedArgumentsList() self.addASTChild(currentAST, self.returnAST) self.suite() self.addASTChild(currentAST, self.returnAST) functionDefinition_AST = currentAST.root self.returnAST = functionDefinition_AST def classDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() classDefinition_AST = None pass tmp39_AST = None tmp39_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp39_AST) self.match(LITERAL_class) tmp40_AST = None tmp40_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp40_AST) self.match(SYMBOL) self.classSuite() self.addASTChild(currentAST, self.returnAST) classDefinition_AST = currentAST.root self.returnAST = classDefinition_AST def interfaceDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() interfaceDefinition_AST = None pass tmp41_AST = None tmp41_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp41_AST) self.match(LITERAL_interface) tmp42_AST = None tmp42_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp42_AST) self.match(SYMBOL) self.interfaceSuite() self.addASTChild(currentAST, self.returnAST) interfaceDefinition_AST = currentAST.root self.returnAST = interfaceDefinition_AST def whileStatement(self): self.returnAST = None currentAST = antlr.ASTPair() whileStatement_AST = None pass tmp43_AST = None tmp43_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp43_AST) self.match(LITERAL_while) self.expression() self.addASTChild(currentAST, self.returnAST) self.suite() self.addASTChild(currentAST, self.returnAST) whileStatement_AST = currentAST.root self.returnAST = whileStatement_AST def importStatement(self): self.returnAST = None currentAST = antlr.ASTPair() importStatement_AST = None pass tmp44_AST = None tmp44_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp44_AST) self.match(LITERAL_import) tmp45_AST = None tmp45_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp45_AST) self.match(SYMBOL) importStatement_AST = currentAST.root self.returnAST = importStatement_AST def codeBlock(self): self.returnAST = None currentAST = antlr.ASTPair() codeBlock_AST = None pass tmp46_AST = None tmp46_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp46_AST) self.match(LBRACE) la1 = self.LA(1) if False: pass elif la1 and la1 in [PIPE]: pass self.codeBlockArgs() self.addASTChild(currentAST, self.returnAST) elif la1 and la1 in [INT,FLOAT,STRING,LBRACE,RBRACE,LPAREN,SEMICOLON,SYMBOL,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) while True: if (_tokenSet_0.member(self.LA(1))): pass self.statement() self.addASTChild(currentAST, self.returnAST) else: break self.match(RBRACE) codeBlock_AST = currentAST.root self.returnAST = codeBlock_AST def codeBlockArgs(self): self.returnAST = None currentAST = antlr.ASTPair() codeBlockArgs_AST = None pass tmp48_AST = None tmp48_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp48_AST) self.match(PIPE) tmp49_AST = None tmp49_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp49_AST) self.match(SYMBOL) self.match(PIPE) codeBlockArgs_AST = currentAST.root self.returnAST = codeBlockArgs_AST def classStatement(self): self.returnAST = None currentAST = antlr.ASTPair() classStatement_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LBRACE,LPAREN,SEMICOLON,SYMBOL,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote]: pass self.statement() self.addASTChild(currentAST, self.returnAST) classStatement_AST = currentAST.root elif la1 and la1 in [LITERAL_def_init]: pass self.initFunctionDefinition() self.addASTChild(currentAST, self.returnAST) classStatement_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = classStatement_AST def initFunctionDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() initFunctionDefinition_AST = None pass tmp51_AST = None tmp51_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp51_AST) self.match(LITERAL_def_init) self.typedArgumentsList() self.addASTChild(currentAST, self.returnAST) self.initFunctionSuite() self.addASTChild(currentAST, self.returnAST) initFunctionDefinition_AST = currentAST.root self.returnAST = initFunctionDefinition_AST def interfaceStatement(self): self.returnAST = None currentAST = antlr.ASTPair() interfaceStatement_AST = None pass self.interfaceFunctionDefinition() self.addASTChild(currentAST, self.returnAST) interfaceStatement_AST = currentAST.root self.returnAST = interfaceStatement_AST def interfaceFunctionDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() interfaceFunctionDefinition_AST = None pass tmp52_AST = None tmp52_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp52_AST) self.match(LITERAL_def) self.expression() self.addASTChild(currentAST, self.returnAST) tmp53_AST = None tmp53_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp53_AST) self.match(SYMBOL) self.typedArgumentsList() self.addASTChild(currentAST, self.returnAST) interfaceFunctionDefinition_AST = currentAST.root self.returnAST = interfaceFunctionDefinition_AST def expression(self): self.returnAST = None currentAST = antlr.ASTPair() expression_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [LPAREN]: pass self.match(LPAREN) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(RPAREN) expression_AST = currentAST.root elif la1 and la1 in [INT,FLOAT,STRING,SYMBOL,LITERAL_quote]: pass self.commaExpression() self.addASTChild(currentAST, self.returnAST) expression_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = expression_AST def typedArgumentsList(self): self.returnAST = None currentAST = antlr.ASTPair() typedArgumentsList_AST = None pass tmp56_AST = None tmp56_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp56_AST) self.match(LPAREN) la1 = self.LA(1) if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,SYMBOL,LITERAL_quote]: pass self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) tmp57_AST = None tmp57_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp57_AST) self.match(SYMBOL) while True: if (self.LA(1)==COMMA): pass tmp58_AST = None tmp58_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp58_AST) self.match(COMMA) self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) tmp59_AST = None tmp59_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp59_AST) self.match(SYMBOL) else: break elif la1 and la1 in [RPAREN]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(RPAREN) typedArgumentsList_AST = currentAST.root self.returnAST = typedArgumentsList_AST def suite(self): self.returnAST = None currentAST = antlr.ASTPair() suite_AST = None pass tmp61_AST = None tmp61_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp61_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) _cnt114= 0 while True: la1 = self.LA(1) if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LBRACE,LPAREN,SEMICOLON,SYMBOL,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote]: pass self.statement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break elif la1 and la1 in [LITERAL_return]: pass self.returnStatement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt114 += 1 if _cnt114 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) suite_AST = currentAST.root self.returnAST = suite_AST def initFunctionSuite(self): self.returnAST = None currentAST = antlr.ASTPair() initFunctionSuite_AST = None pass tmp64_AST = None tmp64_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp64_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) la1 = self.LA(1) if False: pass elif la1 and la1 in [LITERAL_var]: pass pass self.varStatement() self.addASTChild(currentAST, self.returnAST) while True: if (_tokenSet_0.member(self.LA(1))): pass self.statement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break elif la1 and la1 in [INT,FLOAT,STRING,LBRACE,LPAREN,SEMICOLON,SYMBOL,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote]: pass _cnt135= 0 while True: if (_tokenSet_0.member(self.LA(1))): pass self.statement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt135 += 1 if _cnt135 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) initFunctionSuite_AST = currentAST.root self.returnAST = initFunctionSuite_AST def classSuite(self): self.returnAST = None currentAST = antlr.ASTPair() classSuite_AST = None pass tmp67_AST = None tmp67_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp67_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) _cnt119= 0 while True: if (_tokenSet_5.member(self.LA(1))): pass self.classStatement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt119 += 1 if _cnt119 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) classSuite_AST = currentAST.root self.returnAST = classSuite_AST def interfaceSuite(self): self.returnAST = None currentAST = antlr.ASTPair() interfaceSuite_AST = None pass tmp69_AST = None tmp69_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp69_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) _cnt124= 0 while True: if (self.LA(1)==LITERAL_def): pass self.interfaceStatement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt124 += 1 if _cnt124 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) interfaceSuite_AST = currentAST.root self.returnAST = interfaceSuite_AST def noCommaExpression(self): self.returnAST = None currentAST = antlr.ASTPair() noCommaExpression_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [LPAREN]: pass self.match(LPAREN) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(RPAREN) noCommaExpression_AST = currentAST.root elif la1 and la1 in [INT,FLOAT,STRING,SYMBOL,LITERAL_quote]: pass self.calcExpression() self.addASTChild(currentAST, self.returnAST) noCommaExpression_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = noCommaExpression_AST def calcExpression(self): self.returnAST = None currentAST = antlr.ASTPair() calcExpression_AST = None pass self.simpleExpression() self.addASTChild(currentAST, self.returnAST) la1 = self.LA(1) if False: pass elif la1 and la1 in [PLUS,MINUS,TIMES,GT,LT,EQUALSEQUALS]: pass la1 = self.LA(1) if False: pass elif la1 and la1 in [EQUALSEQUALS]: pass tmp73_AST = None tmp73_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp73_AST) self.match(EQUALSEQUALS) elif la1 and la1 in [PLUS]: pass tmp74_AST = None tmp74_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp74_AST) self.match(PLUS) elif la1 and la1 in [MINUS]: pass tmp75_AST = None tmp75_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp75_AST) self.match(MINUS) elif la1 and la1 in [TIMES]: pass tmp76_AST = None tmp76_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp76_AST) self.match(TIMES) elif la1 and la1 in [GT]: pass tmp77_AST = None tmp77_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp77_AST) self.match(GT) elif la1 and la1 in [LT]: pass tmp78_AST = None tmp78_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp78_AST) self.match(LT) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) elif la1 and la1 in [EOF,INT,DOT,FLOAT,STRING,LBRACE,RBRACE,LPAREN,RPAREN,RSQUBR,COMMA,SEMICOLON,SYMBOL,COLON,LITERAL_def,LITERAL_def_init,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote,NEWLINE,DEDENT,LITERAL_return]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) calcExpression_AST = currentAST.root self.returnAST = calcExpression_AST def commaExpression(self): self.returnAST = None currentAST = antlr.ASTPair() commaExpression_AST = None pass self.lookupExpression() self.addASTChild(currentAST, self.returnAST) la1 = self.LA(1) if False: pass elif la1 and la1 in [COMMA]: pass tmp79_AST = None tmp79_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp79_AST) self.match(COMMA) self.lookupExpression() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==COMMA): pass self.match(COMMA) self.lookupExpression() self.addASTChild(currentAST, self.returnAST) else: break elif la1 and la1 in [EOF,INT,FLOAT,STRING,LBRACE,RBRACE,LPAREN,RPAREN,RSQUBR,SEMICOLON,SYMBOL,COLON,LITERAL_def,LITERAL_def_init,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote,NEWLINE,DEDENT,LITERAL_return]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) commaExpression_AST = currentAST.root self.returnAST = commaExpression_AST def lookupExpression(self): self.returnAST = None currentAST = antlr.ASTPair() lookupExpression_AST = None pass self.calcExpression() self.addASTChild(currentAST, self.returnAST) la1 = self.LA(1) if False: pass elif la1 and la1 in [DOT]: pass tmp81_AST = None tmp81_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp81_AST) self.match(DOT) self.calcExpression() self.addASTChild(currentAST, self.returnAST) elif la1 and la1 in [EOF,INT,FLOAT,STRING,LBRACE,RBRACE,LPAREN,RPAREN,RSQUBR,COMMA,SEMICOLON,SYMBOL,COLON,LITERAL_def,LITERAL_def_init,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote,NEWLINE,DEDENT,LITERAL_return]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) lookupExpression_AST = currentAST.root self.returnAST = lookupExpression_AST def simpleExpression(self): self.returnAST = None currentAST = antlr.ASTPair() simpleExpression_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [INT]: pass tmp82_AST = None tmp82_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp82_AST) self.match(INT) simpleExpression_AST = currentAST.root elif la1 and la1 in [FLOAT]: pass tmp83_AST = None tmp83_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp83_AST) self.match(FLOAT) simpleExpression_AST = currentAST.root elif la1 and la1 in [STRING]: pass tmp84_AST = None tmp84_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp84_AST) self.match(STRING) simpleExpression_AST = currentAST.root elif la1 and la1 in [LITERAL_quote]: pass self.quotedCode() self.addASTChild(currentAST, self.returnAST) simpleExpression_AST = currentAST.root else: if (self.LA(1)==SYMBOL) and (_tokenSet_6.member(self.LA(2))): pass self.functionCallOrSymbol() self.addASTChild(currentAST, self.returnAST) simpleExpression_AST = currentAST.root elif (self.LA(1)==SYMBOL) and (self.LA(2)==LSQUBR): pass self.arrayLookup() self.addASTChild(currentAST, self.returnAST) simpleExpression_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = simpleExpression_AST def functionCallOrSymbol(self): self.returnAST = None currentAST = antlr.ASTPair() functionCallOrSymbol_AST = None pass tmp85_AST = None tmp85_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp85_AST) self.match(SYMBOL) while True: if (self.LA(1)==LPAREN) and (_tokenSet_7.member(self.LA(2))): pass tmp86_AST = None tmp86_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp86_AST) self.match(LPAREN) self.argumentsList() self.addASTChild(currentAST, self.returnAST) self.match(RPAREN) else: break functionCallOrSymbol_AST = currentAST.root self.returnAST = functionCallOrSymbol_AST def arrayLookup(self): self.returnAST = None currentAST = antlr.ASTPair() arrayLookup_AST = None pass tmp88_AST = None tmp88_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp88_AST) self.match(SYMBOL) tmp89_AST = None tmp89_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp89_AST) self.match(LSQUBR) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(RSQUBR) arrayLookup_AST = currentAST.root self.returnAST = arrayLookup_AST def quotedCode(self): self.returnAST = None currentAST = antlr.ASTPair() quotedCode_AST = None pass tmp91_AST = None tmp91_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp91_AST) self.match(LITERAL_quote) self.suite() self.addASTChild(currentAST, self.returnAST) quotedCode_AST = currentAST.root self.returnAST = quotedCode_AST def argumentsList(self): self.returnAST = None currentAST = antlr.ASTPair() argumentsList_AST = None pass la1 = self.LA(1) if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,SYMBOL,LITERAL_quote]: pass self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==COMMA): pass tmp92_AST = None tmp92_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp92_AST) self.match(COMMA) self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) else: break elif la1 and la1 in [RPAREN]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) argumentsList_AST = currentAST.root self.returnAST = argumentsList_AST def suiteStart(self): self.returnAST = None currentAST = antlr.ASTPair() suiteStart_AST = None pass _cnt104= 0 while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break _cnt104 += 1 if _cnt104 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(INDENT) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break suiteStart_AST = currentAST.root self.returnAST = suiteStart_AST def suiteEnd(self): self.returnAST = None currentAST = antlr.ASTPair() suiteEnd_AST = None pass self.match(DEDENT) suiteEnd_AST = currentAST.root self.returnAST = suiteEnd_AST def returnStatement(self): self.returnAST = None currentAST = antlr.ASTPair() returnStatement_AST = None pass tmp97_AST = None tmp97_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp97_AST) self.match(LITERAL_return) self.expression() self.addASTChild(currentAST, self.returnAST) returnStatement_AST = currentAST.root self.returnAST = returnStatement_AST def varStatement(self): self.returnAST = None currentAST = antlr.ASTPair() varStatement_AST = None pass tmp98_AST = None tmp98_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp98_AST) self.match(LITERAL_var) self.varSuite() self.addASTChild(currentAST, self.returnAST) varStatement_AST = currentAST.root self.returnAST = varStatement_AST def varSuite(self): self.returnAST = None currentAST = antlr.ASTPair() varSuite_AST = None pass tmp99_AST = None tmp99_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp99_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) _cnt140= 0 while True: if (_tokenSet_1.member(self.LA(1))): pass self.initialisation() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt140 += 1 if _cnt140 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) varSuite_AST = currentAST.root self.returnAST = varSuite_AST def initialisation(self): self.returnAST = None currentAST = antlr.ASTPair() initialisation_AST = None pass self.expression() self.addASTChild(currentAST, self.returnAST) tmp101_AST = None tmp101_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp101_AST) self.match(SYMBOL) tmp102_AST = None tmp102_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp102_AST) self.match(EQUALS) self.expression() self.addASTChild(currentAST, self.returnAST) initialisation_AST = currentAST.root self.returnAST = initialisation_AST def buildTokenTypeASTClassMap(self): self.tokenTypeToASTClassMap = None _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "WHITESPACE", "COMMENT", "DIGIT", "DIGITS", "INT", "DOT", "FLOAT", "INT_OR_DOT_OR_FLOAT", "TRIPLEDOUBLEQUOTE", "DOUBLEQUOTE", "DOUBLEQUOTESTRING", "TRIPLEDOUBLEQUOTESTRING", "STRING", "LBRACE", "RBRACE", "PIPE", "LPAREN", "RPAREN", "LSQUBR", "RSQUBR", "COMMA", "SEMICOLON", "STARTSYMBOLCHAR", "MIDSYMBOLCHAR", "SYMBOL", "PLUS", "MINUS", "TIMES", "PLUSEQUALS", "GT", "LT", "COLON", "EQUALS", "EQUALSEQUALS", "\"def\"", "\"def_init\"", "\"class\"", "\"interface\"", "\"while\"", "\"import\"", "\"quote\"", "NEWLINE", "INDENT", "DEDENT", "\"var\"", "\"return\"" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 34360041604352L, 0L] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0()) ### generate bit set def mk_tokenSet_1(): ### var1 data = [ 17592455595264L, 0L] return data _tokenSet_1 = antlr.BitSet(mk_tokenSet_1()) ### generate bit set def mk_tokenSet_2(): ### var1 data = [ 773982959109890L, 0L] return data _tokenSet_2 = antlr.BitSet(mk_tokenSet_2()) ### generate bit set def mk_tokenSet_3(): ### var1 data = [ 773781611545858L, 0L] return data _tokenSet_3 = antlr.BitSet(mk_tokenSet_3()) ### generate bit set def mk_tokenSet_4(): ### var1 data = [ 773987265087234L, 0L] return data _tokenSet_4 = antlr.BitSet(mk_tokenSet_4()) ### generate bit set def mk_tokenSet_5(): ### var1 data = [ 34909797418240L, 0L] return data _tokenSet_5 = antlr.BitSet(mk_tokenSet_5()) ### generate bit set def mk_tokenSet_6(): ### var1 data = [ 773982965401346L, 0L] return data _tokenSet_6 = antlr.BitSet(mk_tokenSet_6()) ### generate bit set def mk_tokenSet_7(): ### var1 data = [ 17592457692416L, 0L] return data _tokenSet_7 = antlr.BitSet(mk_tokenSet_7())
{ "repo_name": "andybalaam/pepper", "path": "old/pepper1/src/newsyntaxparse/NewSyntaxPepperParser.py", "copies": "1", "size": "39995", "license": "mit", "hash": 4351324132428863000, "line_mean": 31.6489795918, "line_max": 253, "alpha_frac": 0.5487685961, "autogenerated": false, "ratio": 3.9614698890649764, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5010238485164976, "avg_score": null, "num_lines": null }
### $ANTLR 2.7.7 (20160104): "newsyntaxpepper.g" -> "NewSyntaxPepperTreeWalker.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> ### header action <<< ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE WHITESPACE = 4 COMMENT = 5 DIGIT = 6 DIGITS = 7 INT = 8 DOT = 9 FLOAT = 10 INT_OR_DOT_OR_FLOAT = 11 TRIPLEDOUBLEQUOTE = 12 DOUBLEQUOTE = 13 DOUBLEQUOTESTRING = 14 TRIPLEDOUBLEQUOTESTRING = 15 STRING = 16 LBRACE = 17 RBRACE = 18 PIPE = 19 LPAREN = 20 RPAREN = 21 LSQUBR = 22 RSQUBR = 23 COMMA = 24 SEMICOLON = 25 STARTSYMBOLCHAR = 26 MIDSYMBOLCHAR = 27 SYMBOL = 28 PLUS = 29 MINUS = 30 TIMES = 31 PLUSEQUALS = 32 GT = 33 LT = 34 COLON = 35 EQUALS = 36 EQUALSEQUALS = 37 LITERAL_def = 38 LITERAL_def_init = 39 LITERAL_class = 40 LITERAL_interface = 41 LITERAL_while = 42 LITERAL_import = 43 LITERAL_quote = 44 NEWLINE = 45 INDENT = 46 DEDENT = 47 LITERAL_var = 48 LITERAL_return = 49 ### user code>>> from libpepper.vals.all_values import * ### user code<<< class Walker(antlr.TreeParser): # ctor .. def __init__(self, *args, **kwargs): antlr.TreeParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames ### user action >>> ### user action <<< def statement(self, _t): r = None statement_AST_in = None if _t != antlr.ASTNULL: statement_AST_in = _t try: ## for error handling if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,GT,LT,LITERAL_quote]: pass e=self.expression(_t) _t = self._retTree r = e elif la1 and la1 in [EQUALS]: pass i=self.initialisation(_t) _t = self._retTree r = i elif la1 and la1 in [PLUSEQUALS]: pass m=self.modification(_t) _t = self._retTree r = m elif la1 and la1 in [LITERAL_def]: pass f=self.functionDefinition(_t) _t = self._retTree r = f elif la1 and la1 in [LITERAL_class]: pass c=self.classDefinition(_t) _t = self._retTree r = c elif la1 and la1 in [LITERAL_interface]: pass n=self.interfaceDefinition(_t) _t = self._retTree r = n elif la1 and la1 in [LITERAL_while]: pass w=self.whileStatement(_t) _t = self._retTree r = w elif la1 and la1 in [LITERAL_import]: pass i=self.importStatement(_t) _t = self._retTree r = i elif la1 and la1 in [LBRACE]: pass c=self.codeBlock(_t) _t = self._retTree r = c else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def expression(self, _t): r = None expression_AST_in = None if _t != antlr.ASTNULL: expression_AST_in = _t i = None d = None t = None try: ## for error handling if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [SYMBOL]: pass s=self.symbol(_t) _t = self._retTree r = s elif la1 and la1 in [INT]: pass i = _t self.match(_t,INT) _t = _t.getNextSibling() r = PepInt( i.getText() ) elif la1 and la1 in [FLOAT]: pass d = _t self.match(_t,FLOAT) _t = _t.getNextSibling() r = PepFloat( d.getText() ) elif la1 and la1 in [STRING]: pass t = _t self.match(_t,STRING) _t = _t.getNextSibling() r = PepString( t.getText() ) elif la1 and la1 in [LSQUBR]: pass a=self.arraylookup(_t) _t = self._retTree r = a elif la1 and la1 in [PLUS]: pass _t152 = _t tmp1_AST_in = _t self.match(_t,PLUS) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t152 _t = _t.getNextSibling() r = PepPlus( e1, e2 ) elif la1 and la1 in [MINUS]: pass _t153 = _t tmp2_AST_in = _t self.match(_t,MINUS) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t153 _t = _t.getNextSibling() r = PepMinus( e1, e2 ) elif la1 and la1 in [TIMES]: pass _t154 = _t tmp3_AST_in = _t self.match(_t,TIMES) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t154 _t = _t.getNextSibling() r = PepTimes( e1, e2 ) elif la1 and la1 in [GT]: pass _t155 = _t tmp4_AST_in = _t self.match(_t,GT) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t155 _t = _t.getNextSibling() r = PepGreaterThan( e1, e2 ) elif la1 and la1 in [LT]: pass _t156 = _t tmp5_AST_in = _t self.match(_t,LT) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t156 _t = _t.getNextSibling() r = PepLessThan( e1, e2 ) elif la1 and la1 in [LPAREN]: pass f=self.functionCall(_t) _t = self._retTree r = f elif la1 and la1 in [LITERAL_quote]: pass q=self.quotedCode(_t) _t = self._retTree r = q elif la1 and la1 in [COMMA]: pass t=self.tuple(_t) _t = self._retTree r = t else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initialisation(self, _t): r = None initialisation_AST_in = None if _t != antlr.ASTNULL: initialisation_AST_in = _t try: ## for error handling pass _t158 = _t tmp6_AST_in = _t self.match(_t,EQUALS) _t = _t.getFirstChild() t=self.expression(_t) _t = self._retTree s=self.symbol(_t) _t = self._retTree v=self.expression(_t) _t = self._retTree _t = _t158 _t = _t.getNextSibling() r = PepInit( t, s, v ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def modification(self, _t): r = None modification_AST_in = None if _t != antlr.ASTNULL: modification_AST_in = _t try: ## for error handling pass _t160 = _t tmp7_AST_in = _t self.match(_t,PLUSEQUALS) _t = _t.getFirstChild() s=self.symbol(_t) _t = self._retTree v=self.expression(_t) _t = self._retTree _t = _t160 _t = _t.getNextSibling() r = PepModification( s, v ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def functionDefinition(self, _t): r = None functionDefinition_AST_in = None if _t != antlr.ASTNULL: functionDefinition_AST_in = _t try: ## for error handling pass _t162 = _t tmp8_AST_in = _t self.match(_t,LITERAL_def) _t = _t.getFirstChild() t=self.expression(_t) _t = self._retTree n=self.symbol(_t) _t = self._retTree a=self.typedArgumentsList(_t) _t = self._retTree s=self.suite(_t) _t = self._retTree _t = _t162 _t = _t.getNextSibling() r = PepDef( t, n, a, s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def classDefinition(self, _t): r = None classDefinition_AST_in = None if _t != antlr.ASTNULL: classDefinition_AST_in = _t try: ## for error handling pass _t168 = _t tmp9_AST_in = _t self.match(_t,LITERAL_class) _t = _t.getFirstChild() n=self.symbol(_t) _t = self._retTree s=self.classSuite(_t) _t = self._retTree _t = _t168 _t = _t.getNextSibling() r = PepClass( n, (), s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceDefinition(self, _t): r = None interfaceDefinition_AST_in = None if _t != antlr.ASTNULL: interfaceDefinition_AST_in = _t try: ## for error handling pass _t170 = _t tmp10_AST_in = _t self.match(_t,LITERAL_interface) _t = _t.getFirstChild() n=self.symbol(_t) _t = self._retTree s=self.interfaceSuite(_t) _t = self._retTree _t = _t170 _t = _t.getNextSibling() r = PepInterface( n, (), s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def whileStatement(self, _t): r = None whileStatement_AST_in = None if _t != antlr.ASTNULL: whileStatement_AST_in = _t try: ## for error handling pass _t172 = _t tmp11_AST_in = _t self.match(_t,LITERAL_while) _t = _t.getFirstChild() e=self.expression(_t) _t = self._retTree s=self.suite(_t) _t = self._retTree _t = _t172 _t = _t.getNextSibling() r = PepWhile( e, s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def importStatement(self, _t): r = None importStatement_AST_in = None if _t != antlr.ASTNULL: importStatement_AST_in = _t m = None try: ## for error handling pass _t174 = _t tmp12_AST_in = _t self.match(_t,LITERAL_import) _t = _t.getFirstChild() m = _t self.match(_t,SYMBOL) _t = _t.getNextSibling() _t = _t174 _t = _t.getNextSibling() r = PepImport( m.getText() ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def codeBlock(self, _t): r = None codeBlock_AST_in = None if _t != antlr.ASTNULL: codeBlock_AST_in = _t try: ## for error handling pass _t146 = _t tmp13_AST_in = _t self.match(_t,LBRACE) _t = _t.getFirstChild() a=self.codeBlockArgs(_t) _t = self._retTree s=self.statementsList(_t) _t = self._retTree _t = _t146 _t = _t.getNextSibling() r = PepCodeBlock(a, s) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def codeBlockArgs(self, _t): r = None codeBlockArgs_AST_in = None if _t != antlr.ASTNULL: codeBlockArgs_AST_in = _t try: ## for error handling pass _t148 = _t tmp14_AST_in = _t self.match(_t,PIPE) _t = _t.getFirstChild() s=self.symbol(_t) _t = self._retTree _t = _t148 _t = _t.getNextSibling() r = (s,) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def statementsList(self, _t): r = None statementsList_AST_in = None if _t != antlr.ASTNULL: statementsList_AST_in = _t r = () try: ## for error handling pass s=self.statementOrReturnStatement(_t) _t = self._retTree r = (s,) while True: if not _t: _t = antlr.ASTNULL if (_tokenSet_0.member(_t.getType())): pass s=self.statementOrReturnStatement(_t) _t = self._retTree r += (s,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def symbol(self, _t): r = None symbol_AST_in = None if _t != antlr.ASTNULL: symbol_AST_in = _t f = None try: ## for error handling pass f = _t self.match(_t,SYMBOL) _t = _t.getNextSibling() r = PepSymbol( f.getText() ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def classStatement(self, _t): r = None classStatement_AST_in = None if _t != antlr.ASTNULL: classStatement_AST_in = _t try: ## for error handling if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LBRACE,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,PLUSEQUALS,GT,LT,EQUALS,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote]: pass s=self.statement(_t) _t = self._retTree r = s elif la1 and la1 in [LITERAL_def_init]: pass f=self.initFunctionDefinition(_t) _t = self._retTree r = f else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initFunctionDefinition(self, _t): r = None initFunctionDefinition_AST_in = None if _t != antlr.ASTNULL: initFunctionDefinition_AST_in = _t try: ## for error handling pass _t166 = _t tmp15_AST_in = _t self.match(_t,LITERAL_def_init) _t = _t.getFirstChild() a=self.typedArgumentsList(_t) _t = self._retTree s=self.initFunctionSuite(_t) _t = self._retTree _t = _t166 _t = _t.getNextSibling() r = PepDefInit( a, s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceStatement(self, _t): r = None interfaceStatement_AST_in = None if _t != antlr.ASTNULL: interfaceStatement_AST_in = _t try: ## for error handling pass f=self.interfaceFunctionDefinition(_t) _t = self._retTree r = f except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceFunctionDefinition(self, _t): r = None interfaceFunctionDefinition_AST_in = None if _t != antlr.ASTNULL: interfaceFunctionDefinition_AST_in = _t try: ## for error handling pass _t164 = _t tmp16_AST_in = _t self.match(_t,LITERAL_def) _t = _t.getFirstChild() t=self.expression(_t) _t = self._retTree n=self.symbol(_t) _t = self._retTree a=self.typedArgumentsList(_t) _t = self._retTree _t = _t164 _t = _t.getNextSibling() r = PepInterfaceDef( t, n, a ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def arraylookup(self, _t): r = None arraylookup_AST_in = None if _t != antlr.ASTNULL: arraylookup_AST_in = _t try: ## for error handling pass _t177 = _t tmp17_AST_in = _t self.match(_t,LSQUBR) _t = _t.getFirstChild() arr=self.symbol(_t) _t = self._retTree idx=self.expression(_t) _t = self._retTree _t = _t177 _t = _t.getNextSibling() r = PepArrayLookup( arr, idx ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def functionCall(self, _t): r = None functionCall_AST_in = None if _t != antlr.ASTNULL: functionCall_AST_in = _t try: ## for error handling pass _t186 = _t tmp18_AST_in = _t self.match(_t,LPAREN) _t = _t.getFirstChild() f=self.symbol(_t) _t = self._retTree a=self.argumentsList(_t) _t = self._retTree _t = _t186 _t = _t.getNextSibling() r = PepFunctionCall( f, a ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def quotedCode(self, _t): r = None quotedCode_AST_in = None if _t != antlr.ASTNULL: quotedCode_AST_in = _t try: ## for error handling pass _t179 = _t tmp19_AST_in = _t self.match(_t,LITERAL_quote) _t = _t.getFirstChild() s=self.suite(_t) _t = self._retTree _t = _t179 _t = _t.getNextSibling() r = PepQuote( s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def tuple(self, _t): r = None tuple_AST_in = None if _t != antlr.ASTNULL: tuple_AST_in = _t try: ## for error handling pass t=self.tupleContents(_t) _t = self._retTree r = PepTuple( t ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def typedArgumentsList(self, _t): r = None typedArgumentsList_AST_in = None if _t != antlr.ASTNULL: typedArgumentsList_AST_in = _t r = () try: ## for error handling pass _t188 = _t tmp20_AST_in = _t self.match(_t,LPAREN) _t = _t.getFirstChild() if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,GT,LT,LITERAL_quote]: pass e=self.expression(_t) _t = self._retTree s=self.symbol(_t) _t = self._retTree r = ( (e,s), ) while True: if not _t: _t = antlr.ASTNULL if (_t.getType()==COMMA): pass tmp21_AST_in = _t self.match(_t,COMMA) _t = _t.getNextSibling() e=self.expression(_t) _t = self._retTree s=self.symbol(_t) _t = self._retTree r += ( (e,s), ) else: break elif la1 and la1 in [3]: pass else: raise antlr.NoViableAltException(_t) _t = _t188 _t = _t.getNextSibling() except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def suite(self, _t): r = None suite_AST_in = None if _t != antlr.ASTNULL: suite_AST_in = _t try: ## for error handling pass _t193 = _t tmp22_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.statementsList(_t) _t = self._retTree _t = _t193 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initFunctionSuite(self, _t): r = None initFunctionSuite_AST_in = None if _t != antlr.ASTNULL: initFunctionSuite_AST_in = _t try: ## for error handling pass _t199 = _t tmp23_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.initFunctionStatementsList(_t) _t = self._retTree _t = _t199 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def classSuite(self, _t): r = None classSuite_AST_in = None if _t != antlr.ASTNULL: classSuite_AST_in = _t try: ## for error handling pass _t195 = _t tmp24_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.classStatementsList(_t) _t = self._retTree _t = _t195 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceSuite(self, _t): r = None interfaceSuite_AST_in = None if _t != antlr.ASTNULL: interfaceSuite_AST_in = _t try: ## for error handling pass _t197 = _t tmp25_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.interfaceStatementsList(_t) _t = self._retTree _t = _t197 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def tupleContents(self, _t): r = None tupleContents_AST_in = None if _t != antlr.ASTNULL: tupleContents_AST_in = _t try: ## for error handling pass _t182 = _t tmp26_AST_in = _t self.match(_t,COMMA) _t = _t.getFirstChild() e=self.expression(_t) _t = self._retTree r = (e,) while True: if not _t: _t = antlr.ASTNULL if (_tokenSet_1.member(_t.getType())): pass e=self.expression(_t) _t = self._retTree r += (e,) else: break _t = _t182 _t = _t.getNextSibling() except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def argumentsList(self, _t): r = None argumentsList_AST_in = None if _t != antlr.ASTNULL: argumentsList_AST_in = _t r = () try: ## for error handling pass if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,GT,LT,LITERAL_quote]: pass e=self.expression(_t) _t = self._retTree r = (e,) while True: if not _t: _t = antlr.ASTNULL if (_t.getType()==COMMA): pass tmp27_AST_in = _t self.match(_t,COMMA) _t = _t.getNextSibling() e=self.expression(_t) _t = self._retTree r += (e,) else: break elif la1 and la1 in [3]: pass else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def classStatementsList(self, _t): r = None classStatementsList_AST_in = None if _t != antlr.ASTNULL: classStatementsList_AST_in = _t r = () try: ## for error handling pass s=self.classStatement(_t) _t = self._retTree r = (s,) while True: if not _t: _t = antlr.ASTNULL if (_tokenSet_2.member(_t.getType())): pass s=self.classStatement(_t) _t = self._retTree r += (s,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceStatementsList(self, _t): r = None interfaceStatementsList_AST_in = None if _t != antlr.ASTNULL: interfaceStatementsList_AST_in = _t r = () try: ## for error handling pass s=self.interfaceStatement(_t) _t = self._retTree r = (s,) while True: if not _t: _t = antlr.ASTNULL if (_t.getType()==LITERAL_def): pass s=self.interfaceStatement(_t) _t = self._retTree r += (s,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initFunctionStatementsList(self, _t): r = None initFunctionStatementsList_AST_in = None if _t != antlr.ASTNULL: initFunctionStatementsList_AST_in = _t r = () try: ## for error handling pass if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [LITERAL_var]: pass v=self.varStatement(_t) _t = self._retTree r = (v,) elif la1 and la1 in [INT,FLOAT,STRING,LBRACE,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,PLUSEQUALS,GT,LT,EQUALS,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote]: pass s=self.statement(_t) _t = self._retTree r = (s,) else: raise antlr.NoViableAltException(_t) while True: if not _t: _t = antlr.ASTNULL if (_tokenSet_3.member(_t.getType())): pass s=self.statement(_t) _t = self._retTree r += (s,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def varSuite(self, _t): r = None varSuite_AST_in = None if _t != antlr.ASTNULL: varSuite_AST_in = _t try: ## for error handling pass _t201 = _t tmp28_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.initialisationsList(_t) _t = self._retTree _t = _t201 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initialisationsList(self, _t): r = None initialisationsList_AST_in = None if _t != antlr.ASTNULL: initialisationsList_AST_in = _t r = () try: ## for error handling pass i=self.initialisation(_t) _t = self._retTree r = (i,) while True: if not _t: _t = antlr.ASTNULL if (_t.getType()==EQUALS): pass i=self.initialisation(_t) _t = self._retTree r += (i,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def statementOrReturnStatement(self, _t): r = None statementOrReturnStatement_AST_in = None if _t != antlr.ASTNULL: statementOrReturnStatement_AST_in = _t try: ## for error handling if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LBRACE,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,PLUSEQUALS,GT,LT,EQUALS,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_while,LITERAL_import,LITERAL_quote]: pass s=self.statement(_t) _t = self._retTree r = s elif la1 and la1 in [LITERAL_return]: pass _t225 = _t tmp29_AST_in = _t self.match(_t,LITERAL_return) _t = _t.getFirstChild() e=self.expression(_t) _t = self._retTree _t = _t225 _t = _t.getNextSibling() r = PepReturn( e ) else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def varStatement(self, _t): r = None varStatement_AST_in = None if _t != antlr.ASTNULL: varStatement_AST_in = _t try: ## for error handling pass _t223 = _t tmp30_AST_in = _t self.match(_t,LITERAL_var) _t = _t.getFirstChild() s=self.varSuite(_t) _t = self._retTree _t = _t223 _t = _t.getNextSibling() r = PepVar( s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "WHITESPACE", "COMMENT", "DIGIT", "DIGITS", "INT", "DOT", "FLOAT", "INT_OR_DOT_OR_FLOAT", "TRIPLEDOUBLEQUOTE", "DOUBLEQUOTE", "DOUBLEQUOTESTRING", "TRIPLEDOUBLEQUOTESTRING", "STRING", "LBRACE", "RBRACE", "PIPE", "LPAREN", "RPAREN", "LSQUBR", "RSQUBR", "COMMA", "SEMICOLON", "STARTSYMBOLCHAR", "MIDSYMBOLCHAR", "SYMBOL", "PLUS", "MINUS", "TIMES", "PLUSEQUALS", "GT", "LT", "COLON", "EQUALS", "EQUALSEQUALS", "\"def\"", "\"def_init\"", "\"class\"", "\"interface\"", "\"while\"", "\"import\"", "\"quote\"", "NEWLINE", "INDENT", "DEDENT", "\"var\"", "\"return\"" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 597412524786944L, 0L] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0()) ### generate bit set def mk_tokenSet_1(): ### var1 data = [ 17622004466944L, 0L] return data _tokenSet_1 = antlr.BitSet(mk_tokenSet_1()) ### generate bit set def mk_tokenSet_2(): ### var1 data = [ 35012327179520L, 0L] return data _tokenSet_2 = antlr.BitSet(mk_tokenSet_2()) ### generate bit set def mk_tokenSet_3(): ### var1 data = [ 34462571365632L, 0L] return data _tokenSet_3 = antlr.BitSet(mk_tokenSet_3())
{ "repo_name": "andybalaam/pepper", "path": "old/pepper1/src/newsyntaxparse/NewSyntaxPepperTreeWalker.py", "copies": "1", "size": "38806", "license": "mit", "hash": -3041609279451810300, "line_mean": 27.2636562272, "line_max": 213, "alpha_frac": 0.4210173684, "autogenerated": false, "ratio": 3.9707357003990587, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9773856164054517, "avg_score": 0.02357938094890809, "num_lines": 1373 }
### $ANTLR 2.7.7 (20160104): "pepper.g" -> "PepperParser.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> ### header action <<< ### preamble action>>> ### preamble action <<< ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE INDENT = 4 DEDENT = 5 WHITESPACE = 6 LEADINGSP = 7 COMMENT = 8 DIGIT = 9 DIGITS = 10 INT = 11 FLOAT = 12 INT_OR_FLOAT = 13 TRIPLEDOUBLEQUOTE = 14 DOUBLEQUOTE = 15 DOUBLEQUOTESTRING = 16 TRIPLEDOUBLEQUOTESTRING = 17 STRING = 18 LPAREN = 19 RPAREN = 20 LSQUBR = 21 RSQUBR = 22 COMMA = 23 STARTSYMBOLCHAR = 24 MIDSYMBOLCHAR = 25 SYMBOL_EL = 26 SYMBOL = 27 NEWLINE = 28 PLUS = 29 MINUS = 30 TIMES = 31 PLUSEQUALS = 32 GT = 33 LT = 34 COLON = 35 EQUALS = 36 LITERAL_def = 37 LITERAL_def_init = 38 LITERAL_class = 39 LITERAL_interface = 40 LITERAL_for = 41 LITERAL_in = 42 LITERAL_while = 43 LITERAL_import = 44 LITERAL_if = 45 LITERAL_else = 46 LITERAL_quote = 47 LITERAL_var = 48 LITERAL_return = 49 class Parser(antlr.LLkParser): ### user action >>> ### user action <<< def __init__(self, *args, **kwargs): antlr.LLkParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames self.buildTokenTypeASTClassMap() self.astFactory = antlr.ASTFactory(self.getTokenTypeToASTClassMap()) self.astFactory.setASTNodeClass() def program(self): self.returnAST = None currentAST = antlr.ASTPair() program_AST = None pass while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break while True: if (_tokenSet_0.member(self.LA(1))): pass self.statement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break tmp3_AST = None tmp3_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp3_AST) self.match(EOF_TYPE) program_AST = currentAST.root self.returnAST = program_AST def statement(self): self.returnAST = None currentAST = antlr.ASTPair() statement_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [LITERAL_def]: pass self.functionDefinition() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_class]: pass self.classDefinition() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_interface]: pass self.interfaceDefinition() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_for]: pass self.forStatement() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_while]: pass self.whileStatement() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif la1 and la1 in [LITERAL_import]: pass self.importStatement() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root else: if (_tokenSet_1.member(self.LA(1))) and (_tokenSet_2.member(self.LA(2))): pass self.initialisationOrExpression() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root elif (self.LA(1)==SYMBOL) and (self.LA(2)==PLUSEQUALS): pass self.modification() self.addASTChild(currentAST, self.returnAST) statement_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = statement_AST def initialisationOrExpression(self): self.returnAST = None currentAST = antlr.ASTPair() initialisationOrExpression_AST = None pass self.expression() self.addASTChild(currentAST, self.returnAST) la1 = self.LA(1) if False: pass elif la1 and la1 in [SYMBOL]: pass tmp4_AST = None tmp4_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp4_AST) self.match(SYMBOL) tmp5_AST = None tmp5_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp5_AST) self.match(EQUALS) self.expression() self.addASTChild(currentAST, self.returnAST) elif la1 and la1 in [NEWLINE]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(NEWLINE) initialisationOrExpression_AST = currentAST.root self.returnAST = initialisationOrExpression_AST def modification(self): self.returnAST = None currentAST = antlr.ASTPair() modification_AST = None pass tmp7_AST = None tmp7_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp7_AST) self.match(SYMBOL) tmp8_AST = None tmp8_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp8_AST) self.match(PLUSEQUALS) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) modification_AST = currentAST.root self.returnAST = modification_AST def functionDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() functionDefinition_AST = None pass tmp10_AST = None tmp10_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp10_AST) self.match(LITERAL_def) self.expression() self.addASTChild(currentAST, self.returnAST) tmp11_AST = None tmp11_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp11_AST) self.match(SYMBOL) self.typedArgumentsList() self.addASTChild(currentAST, self.returnAST) self.suite() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) functionDefinition_AST = currentAST.root self.returnAST = functionDefinition_AST def classDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() classDefinition_AST = None pass tmp13_AST = None tmp13_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp13_AST) self.match(LITERAL_class) tmp14_AST = None tmp14_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp14_AST) self.match(SYMBOL) self.classSuite() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) classDefinition_AST = currentAST.root self.returnAST = classDefinition_AST def interfaceDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() interfaceDefinition_AST = None pass tmp16_AST = None tmp16_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp16_AST) self.match(LITERAL_interface) tmp17_AST = None tmp17_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp17_AST) self.match(SYMBOL) self.interfaceSuite() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) interfaceDefinition_AST = currentAST.root self.returnAST = interfaceDefinition_AST def forStatement(self): self.returnAST = None currentAST = antlr.ASTPair() forStatement_AST = None pass tmp19_AST = None tmp19_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp19_AST) self.match(LITERAL_for) self.expression() self.addASTChild(currentAST, self.returnAST) tmp20_AST = None tmp20_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp20_AST) self.match(SYMBOL) self.match(LITERAL_in) self.expression() self.addASTChild(currentAST, self.returnAST) self.suite() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) forStatement_AST = currentAST.root self.returnAST = forStatement_AST def whileStatement(self): self.returnAST = None currentAST = antlr.ASTPair() whileStatement_AST = None pass tmp23_AST = None tmp23_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp23_AST) self.match(LITERAL_while) self.expression() self.addASTChild(currentAST, self.returnAST) self.suite() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) whileStatement_AST = currentAST.root self.returnAST = whileStatement_AST def importStatement(self): self.returnAST = None currentAST = antlr.ASTPair() importStatement_AST = None pass tmp25_AST = None tmp25_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp25_AST) self.match(LITERAL_import) tmp26_AST = None tmp26_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp26_AST) self.match(SYMBOL) self.match(NEWLINE) importStatement_AST = currentAST.root self.returnAST = importStatement_AST def classStatement(self): self.returnAST = None currentAST = antlr.ASTPair() classStatement_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,SYMBOL,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_for,LITERAL_while,LITERAL_import,LITERAL_if,LITERAL_quote]: pass self.statement() self.addASTChild(currentAST, self.returnAST) classStatement_AST = currentAST.root elif la1 and la1 in [LITERAL_def_init]: pass self.initFunctionDefinition() self.addASTChild(currentAST, self.returnAST) classStatement_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = classStatement_AST def initFunctionDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() initFunctionDefinition_AST = None pass tmp28_AST = None tmp28_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp28_AST) self.match(LITERAL_def_init) self.typedArgumentsList() self.addASTChild(currentAST, self.returnAST) self.initFunctionSuite() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) initFunctionDefinition_AST = currentAST.root self.returnAST = initFunctionDefinition_AST def interfaceStatement(self): self.returnAST = None currentAST = antlr.ASTPair() interfaceStatement_AST = None pass self.interfaceFunctionDefinition() self.addASTChild(currentAST, self.returnAST) interfaceStatement_AST = currentAST.root self.returnAST = interfaceStatement_AST def interfaceFunctionDefinition(self): self.returnAST = None currentAST = antlr.ASTPair() interfaceFunctionDefinition_AST = None pass tmp30_AST = None tmp30_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp30_AST) self.match(LITERAL_def) self.expression() self.addASTChild(currentAST, self.returnAST) tmp31_AST = None tmp31_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp31_AST) self.match(SYMBOL) self.typedArgumentsList() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) interfaceFunctionDefinition_AST = currentAST.root self.returnAST = interfaceFunctionDefinition_AST def expression(self): self.returnAST = None currentAST = antlr.ASTPair() expression_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [LPAREN]: pass self.match(LPAREN) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(RPAREN) expression_AST = currentAST.root elif la1 and la1 in [INT,FLOAT,STRING,SYMBOL,LITERAL_if,LITERAL_quote]: pass self.commaExpression() self.addASTChild(currentAST, self.returnAST) expression_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = expression_AST def typedArgumentsList(self): self.returnAST = None currentAST = antlr.ASTPair() typedArgumentsList_AST = None pass tmp35_AST = None tmp35_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp35_AST) self.match(LPAREN) la1 = self.LA(1) if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,SYMBOL,LITERAL_if,LITERAL_quote]: pass self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) tmp36_AST = None tmp36_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp36_AST) self.match(SYMBOL) while True: if (self.LA(1)==COMMA): pass tmp37_AST = None tmp37_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp37_AST) self.match(COMMA) self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) tmp38_AST = None tmp38_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp38_AST) self.match(SYMBOL) else: break elif la1 and la1 in [RPAREN]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(RPAREN) typedArgumentsList_AST = currentAST.root self.returnAST = typedArgumentsList_AST def suite(self): self.returnAST = None currentAST = antlr.ASTPair() suite_AST = None pass tmp40_AST = None tmp40_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp40_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) _cnt113= 0 while True: la1 = self.LA(1) if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,SYMBOL,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_for,LITERAL_while,LITERAL_import,LITERAL_if,LITERAL_quote]: pass self.statement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break elif la1 and la1 in [LITERAL_return]: pass self.returnStatement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt113 += 1 if _cnt113 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) suite_AST = currentAST.root self.returnAST = suite_AST def initFunctionSuite(self): self.returnAST = None currentAST = antlr.ASTPair() initFunctionSuite_AST = None pass tmp43_AST = None tmp43_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp43_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) la1 = self.LA(1) if False: pass elif la1 and la1 in [LITERAL_var]: pass pass self.varStatement() self.addASTChild(currentAST, self.returnAST) while True: if (_tokenSet_0.member(self.LA(1))): pass self.statement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,SYMBOL,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_for,LITERAL_while,LITERAL_import,LITERAL_if,LITERAL_quote]: pass _cnt134= 0 while True: if (_tokenSet_0.member(self.LA(1))): pass self.statement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt134 += 1 if _cnt134 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) initFunctionSuite_AST = currentAST.root self.returnAST = initFunctionSuite_AST def classSuite(self): self.returnAST = None currentAST = antlr.ASTPair() classSuite_AST = None pass tmp46_AST = None tmp46_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp46_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) _cnt118= 0 while True: if (_tokenSet_3.member(self.LA(1))): pass self.classStatement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt118 += 1 if _cnt118 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) classSuite_AST = currentAST.root self.returnAST = classSuite_AST def interfaceSuite(self): self.returnAST = None currentAST = antlr.ASTPair() interfaceSuite_AST = None pass tmp48_AST = None tmp48_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp48_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) _cnt123= 0 while True: if (self.LA(1)==LITERAL_def): pass self.interfaceStatement() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt123 += 1 if _cnt123 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) interfaceSuite_AST = currentAST.root self.returnAST = interfaceSuite_AST def noCommaExpression(self): self.returnAST = None currentAST = antlr.ASTPair() noCommaExpression_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [LPAREN]: pass self.match(LPAREN) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(RPAREN) noCommaExpression_AST = currentAST.root elif la1 and la1 in [INT,FLOAT,STRING,SYMBOL,LITERAL_if,LITERAL_quote]: pass self.calcExpression() self.addASTChild(currentAST, self.returnAST) noCommaExpression_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = noCommaExpression_AST def calcExpression(self): self.returnAST = None currentAST = antlr.ASTPair() calcExpression_AST = None pass self.simpleExpression() self.addASTChild(currentAST, self.returnAST) la1 = self.LA(1) if False: pass elif la1 and la1 in [PLUS,MINUS,TIMES,GT,LT]: pass la1 = self.LA(1) if False: pass elif la1 and la1 in [PLUS]: pass tmp52_AST = None tmp52_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp52_AST) self.match(PLUS) elif la1 and la1 in [MINUS]: pass tmp53_AST = None tmp53_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp53_AST) self.match(MINUS) elif la1 and la1 in [TIMES]: pass tmp54_AST = None tmp54_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp54_AST) self.match(TIMES) elif la1 and la1 in [GT]: pass tmp55_AST = None tmp55_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp55_AST) self.match(GT) elif la1 and la1 in [LT]: pass tmp56_AST = None tmp56_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp56_AST) self.match(LT) else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) elif la1 and la1 in [RPAREN,RSQUBR,COMMA,SYMBOL,NEWLINE,COLON]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) calcExpression_AST = currentAST.root self.returnAST = calcExpression_AST def commaExpression(self): self.returnAST = None currentAST = antlr.ASTPair() commaExpression_AST = None pass self.calcExpression() self.addASTChild(currentAST, self.returnAST) la1 = self.LA(1) if False: pass elif la1 and la1 in [COMMA]: pass tmp57_AST = None tmp57_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp57_AST) self.match(COMMA) self.calcExpression() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==COMMA): pass self.match(COMMA) self.calcExpression() self.addASTChild(currentAST, self.returnAST) else: break elif la1 and la1 in [RPAREN,RSQUBR,SYMBOL,NEWLINE,COLON]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) commaExpression_AST = currentAST.root self.returnAST = commaExpression_AST def simpleExpression(self): self.returnAST = None currentAST = antlr.ASTPair() simpleExpression_AST = None la1 = self.LA(1) if False: pass elif la1 and la1 in [INT]: pass tmp59_AST = None tmp59_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp59_AST) self.match(INT) simpleExpression_AST = currentAST.root elif la1 and la1 in [FLOAT]: pass tmp60_AST = None tmp60_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp60_AST) self.match(FLOAT) simpleExpression_AST = currentAST.root elif la1 and la1 in [STRING]: pass tmp61_AST = None tmp61_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp61_AST) self.match(STRING) simpleExpression_AST = currentAST.root elif la1 and la1 in [LITERAL_if]: pass self.ifExpression() self.addASTChild(currentAST, self.returnAST) simpleExpression_AST = currentAST.root elif la1 and la1 in [LITERAL_quote]: pass self.quotedCode() self.addASTChild(currentAST, self.returnAST) simpleExpression_AST = currentAST.root else: if (self.LA(1)==SYMBOL) and (_tokenSet_4.member(self.LA(2))): pass tmp62_AST = None tmp62_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp62_AST) self.match(SYMBOL) simpleExpression_AST = currentAST.root elif (self.LA(1)==SYMBOL) and (self.LA(2)==LPAREN): pass self.functionCall() self.addASTChild(currentAST, self.returnAST) simpleExpression_AST = currentAST.root elif (self.LA(1)==SYMBOL) and (self.LA(2)==LSQUBR): pass self.arrayLookup() self.addASTChild(currentAST, self.returnAST) simpleExpression_AST = currentAST.root else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.returnAST = simpleExpression_AST def functionCall(self): self.returnAST = None currentAST = antlr.ASTPair() functionCall_AST = None pass tmp63_AST = None tmp63_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp63_AST) self.match(SYMBOL) tmp64_AST = None tmp64_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp64_AST) self.match(LPAREN) self.argumentsList() self.addASTChild(currentAST, self.returnAST) self.match(RPAREN) functionCall_AST = currentAST.root self.returnAST = functionCall_AST def arrayLookup(self): self.returnAST = None currentAST = antlr.ASTPair() arrayLookup_AST = None pass tmp66_AST = None tmp66_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp66_AST) self.match(SYMBOL) tmp67_AST = None tmp67_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp67_AST) self.match(LSQUBR) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(RSQUBR) arrayLookup_AST = currentAST.root self.returnAST = arrayLookup_AST def ifExpression(self): self.returnAST = None currentAST = antlr.ASTPair() ifExpression_AST = None pass tmp69_AST = None tmp69_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp69_AST) self.match(LITERAL_if) self.expression() self.addASTChild(currentAST, self.returnAST) self.suite() self.addASTChild(currentAST, self.returnAST) if (self.LA(1)==NEWLINE) and (self.LA(2)==LITERAL_else): pass self.match(NEWLINE) tmp71_AST = None tmp71_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp71_AST) self.match(LITERAL_else) self.suite() self.addASTChild(currentAST, self.returnAST) elif (_tokenSet_4.member(self.LA(1))) and (_tokenSet_5.member(self.LA(2))): pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) ifExpression_AST = currentAST.root self.returnAST = ifExpression_AST def quotedCode(self): self.returnAST = None currentAST = antlr.ASTPair() quotedCode_AST = None pass tmp72_AST = None tmp72_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp72_AST) self.match(LITERAL_quote) self.suite() self.addASTChild(currentAST, self.returnAST) quotedCode_AST = currentAST.root self.returnAST = quotedCode_AST def argumentsList(self): self.returnAST = None currentAST = antlr.ASTPair() argumentsList_AST = None pass la1 = self.LA(1) if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,SYMBOL,LITERAL_if,LITERAL_quote]: pass self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==COMMA): pass tmp73_AST = None tmp73_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp73_AST) self.match(COMMA) self.noCommaExpression() self.addASTChild(currentAST, self.returnAST) else: break elif la1 and la1 in [RPAREN]: pass else: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) argumentsList_AST = currentAST.root self.returnAST = argumentsList_AST def suiteStart(self): self.returnAST = None currentAST = antlr.ASTPair() suiteStart_AST = None pass _cnt103= 0 while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break _cnt103 += 1 if _cnt103 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.match(INDENT) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break suiteStart_AST = currentAST.root self.returnAST = suiteStart_AST def suiteEnd(self): self.returnAST = None currentAST = antlr.ASTPair() suiteEnd_AST = None pass self.match(DEDENT) suiteEnd_AST = currentAST.root self.returnAST = suiteEnd_AST def returnStatement(self): self.returnAST = None currentAST = antlr.ASTPair() returnStatement_AST = None pass tmp78_AST = None tmp78_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp78_AST) self.match(LITERAL_return) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) returnStatement_AST = currentAST.root self.returnAST = returnStatement_AST def varStatement(self): self.returnAST = None currentAST = antlr.ASTPair() varStatement_AST = None pass tmp80_AST = None tmp80_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp80_AST) self.match(LITERAL_var) self.varSuite() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) varStatement_AST = currentAST.root self.returnAST = varStatement_AST def varSuite(self): self.returnAST = None currentAST = antlr.ASTPair() varSuite_AST = None pass tmp82_AST = None tmp82_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp82_AST) self.match(COLON) self.suiteStart() self.addASTChild(currentAST, self.returnAST) _cnt139= 0 while True: if (_tokenSet_1.member(self.LA(1))): pass self.initialisation() self.addASTChild(currentAST, self.returnAST) while True: if (self.LA(1)==NEWLINE): pass self.match(NEWLINE) else: break else: break _cnt139 += 1 if _cnt139 < 1: raise antlr.NoViableAltException(self.LT(1), self.getFilename()) self.suiteEnd() self.addASTChild(currentAST, self.returnAST) varSuite_AST = currentAST.root self.returnAST = varSuite_AST def initialisation(self): self.returnAST = None currentAST = antlr.ASTPair() initialisation_AST = None pass self.expression() self.addASTChild(currentAST, self.returnAST) tmp84_AST = None tmp84_AST = self.astFactory.create(self.LT(1)) self.addASTChild(currentAST, tmp84_AST) self.match(SYMBOL) tmp85_AST = None tmp85_AST = self.astFactory.create(self.LT(1)) self.makeASTRoot(currentAST, tmp85_AST) self.match(EQUALS) self.expression() self.addASTChild(currentAST, self.returnAST) self.match(NEWLINE) initialisation_AST = currentAST.root self.returnAST = initialisation_AST def buildTokenTypeASTClassMap(self): self.tokenTypeToASTClassMap = None _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "INDENT", "DEDENT", "WHITESPACE", "LEADINGSP", "COMMENT", "DIGIT", "DIGITS", "INT", "FLOAT", "INT_OR_FLOAT", "TRIPLEDOUBLEQUOTE", "DOUBLEQUOTE", "DOUBLEQUOTESTRING", "TRIPLEDOUBLEQUOTESTRING", "STRING", "LPAREN", "RPAREN", "LSQUBR", "RSQUBR", "COMMA", "STARTSYMBOLCHAR", "MIDSYMBOLCHAR", "SYMBOL_EL", "SYMBOL", "NEWLINE", "PLUS", "MINUS", "TIMES", "PLUSEQUALS", "GT", "LT", "COLON", "EQUALS", "\"def\"", "\"def_init\"", "\"class\"", "\"interface\"", "\"for\"", "\"in\"", "\"while\"", "\"import\"", "\"if\"", "\"else\"", "\"quote\"", "\"var\"", "\"return\"" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 206296004171776L, 0L] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0()) ### generate bit set def mk_tokenSet_1(): ### var1 data = [ 175921995454464L, 0L] return data _tokenSet_1 = antlr.BitSet(mk_tokenSet_1()) ### generate bit set def mk_tokenSet_2(): ### var1 data = [ 175986162014208L, 0L] return data _tokenSet_2 = antlr.BitSet(mk_tokenSet_2()) ### generate bit set def mk_tokenSet_3(): ### var1 data = [ 206570882078720L, 0L] return data _tokenSet_3 = antlr.BitSet(mk_tokenSet_3()) ### generate bit set def mk_tokenSet_4(): ### var1 data = [ 64303923200L, 0L] return data _tokenSet_4 = antlr.BitSet(mk_tokenSet_4()) ### generate bit set def mk_tokenSet_5(): ### var1 data = [ 774051771193378L, 0L] return data _tokenSet_5 = antlr.BitSet(mk_tokenSet_5())
{ "repo_name": "andybalaam/pepper", "path": "old/pepper1/src/parse/PepperParser.py", "copies": "1", "size": "38969", "license": "mit", "hash": -271541759041786560, "line_mean": 31.205785124, "line_max": 175, "alpha_frac": 0.5427647617, "autogenerated": false, "ratio": 4.004212905877518, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5046977667577518, "avg_score": null, "num_lines": null }
### $ANTLR 2.7.7 (20160104): "pepper.g" -> "PepperTreeWalker.py"$ ### import antlr and other modules .. import sys import antlr version = sys.version.split()[0] if version < '2.2.1': False = 0 if version < '2.3': True = not False ### header action >>> ### header action <<< ### import antlr.Token from antlr import Token ### >>>The Known Token Types <<< SKIP = antlr.SKIP INVALID_TYPE = antlr.INVALID_TYPE EOF_TYPE = antlr.EOF_TYPE EOF = antlr.EOF NULL_TREE_LOOKAHEAD = antlr.NULL_TREE_LOOKAHEAD MIN_USER_TYPE = antlr.MIN_USER_TYPE INDENT = 4 DEDENT = 5 WHITESPACE = 6 LEADINGSP = 7 COMMENT = 8 DIGIT = 9 DIGITS = 10 INT = 11 FLOAT = 12 INT_OR_FLOAT = 13 TRIPLEDOUBLEQUOTE = 14 DOUBLEQUOTE = 15 DOUBLEQUOTESTRING = 16 TRIPLEDOUBLEQUOTESTRING = 17 STRING = 18 LPAREN = 19 RPAREN = 20 LSQUBR = 21 RSQUBR = 22 COMMA = 23 STARTSYMBOLCHAR = 24 MIDSYMBOLCHAR = 25 SYMBOL_EL = 26 SYMBOL = 27 NEWLINE = 28 PLUS = 29 MINUS = 30 TIMES = 31 PLUSEQUALS = 32 GT = 33 LT = 34 COLON = 35 EQUALS = 36 LITERAL_def = 37 LITERAL_def_init = 38 LITERAL_class = 39 LITERAL_interface = 40 LITERAL_for = 41 LITERAL_in = 42 LITERAL_while = 43 LITERAL_import = 44 LITERAL_if = 45 LITERAL_else = 46 LITERAL_quote = 47 LITERAL_var = 48 LITERAL_return = 49 ### user code>>> from libpepper.vals.all_values import * ### user code<<< class Walker(antlr.TreeParser): # ctor .. def __init__(self, *args, **kwargs): antlr.TreeParser.__init__(self, *args, **kwargs) self.tokenNames = _tokenNames ### user action >>> ### user action <<< def statement(self, _t): r = None statement_AST_in = None if _t != antlr.ASTNULL: statement_AST_in = _t try: ## for error handling if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,GT,LT,LITERAL_if,LITERAL_quote]: pass e=self.expression(_t) _t = self._retTree r = e elif la1 and la1 in [EQUALS]: pass i=self.initialisation(_t) _t = self._retTree r = i elif la1 and la1 in [PLUSEQUALS]: pass m=self.modification(_t) _t = self._retTree r = m elif la1 and la1 in [LITERAL_def]: pass f=self.functionDefinition(_t) _t = self._retTree r = f elif la1 and la1 in [LITERAL_class]: pass c=self.classDefinition(_t) _t = self._retTree r = c elif la1 and la1 in [LITERAL_interface]: pass n=self.interfaceDefinition(_t) _t = self._retTree r = n elif la1 and la1 in [LITERAL_for]: pass f=self.forStatement(_t) _t = self._retTree r = f elif la1 and la1 in [LITERAL_while]: pass w=self.whileStatement(_t) _t = self._retTree r = w elif la1 and la1 in [LITERAL_import]: pass i=self.importStatement(_t) _t = self._retTree r = i else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def expression(self, _t): r = None expression_AST_in = None if _t != antlr.ASTNULL: expression_AST_in = _t i = None d = None t = None try: ## for error handling if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [SYMBOL]: pass s=self.symbol(_t) _t = self._retTree r = s elif la1 and la1 in [INT]: pass i = _t self.match(_t,INT) _t = _t.getNextSibling() r = PepInt( i.getText() ) elif la1 and la1 in [FLOAT]: pass d = _t self.match(_t,FLOAT) _t = _t.getNextSibling() r = PepFloat( d.getText() ) elif la1 and la1 in [STRING]: pass t = _t self.match(_t,STRING) _t = _t.getNextSibling() r = PepString( t.getText() ) elif la1 and la1 in [LSQUBR]: pass a=self.arraylookup(_t) _t = self._retTree r = a elif la1 and la1 in [LITERAL_if]: pass i=self.ifExpression(_t) _t = self._retTree r = i elif la1 and la1 in [PLUS]: pass _t147 = _t tmp87_AST_in = _t self.match(_t,PLUS) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t147 _t = _t.getNextSibling() r = PepPlus( e1, e2 ) elif la1 and la1 in [MINUS]: pass _t148 = _t tmp88_AST_in = _t self.match(_t,MINUS) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t148 _t = _t.getNextSibling() r = PepMinus( e1, e2 ) elif la1 and la1 in [TIMES]: pass _t149 = _t tmp89_AST_in = _t self.match(_t,TIMES) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t149 _t = _t.getNextSibling() r = PepTimes( e1, e2 ) elif la1 and la1 in [GT]: pass _t150 = _t tmp90_AST_in = _t self.match(_t,GT) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t150 _t = _t.getNextSibling() r = PepGreaterThan( e1, e2 ) elif la1 and la1 in [LT]: pass _t151 = _t tmp91_AST_in = _t self.match(_t,LT) _t = _t.getFirstChild() e1=self.expression(_t) _t = self._retTree e2=self.expression(_t) _t = self._retTree _t = _t151 _t = _t.getNextSibling() r = PepLessThan( e1, e2 ) elif la1 and la1 in [LPAREN]: pass f=self.functionCall(_t) _t = self._retTree r = f elif la1 and la1 in [LITERAL_quote]: pass q=self.quotedCode(_t) _t = self._retTree r = q elif la1 and la1 in [COMMA]: pass t=self.tuple(_t) _t = self._retTree r = t else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initialisation(self, _t): r = None initialisation_AST_in = None if _t != antlr.ASTNULL: initialisation_AST_in = _t try: ## for error handling pass _t153 = _t tmp92_AST_in = _t self.match(_t,EQUALS) _t = _t.getFirstChild() t=self.expression(_t) _t = self._retTree s=self.symbol(_t) _t = self._retTree v=self.expression(_t) _t = self._retTree _t = _t153 _t = _t.getNextSibling() r = PepInit( t, s, v ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def modification(self, _t): r = None modification_AST_in = None if _t != antlr.ASTNULL: modification_AST_in = _t try: ## for error handling pass _t155 = _t tmp93_AST_in = _t self.match(_t,PLUSEQUALS) _t = _t.getFirstChild() s=self.symbol(_t) _t = self._retTree v=self.expression(_t) _t = self._retTree _t = _t155 _t = _t.getNextSibling() r = PepModification( s, v ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def functionDefinition(self, _t): r = None functionDefinition_AST_in = None if _t != antlr.ASTNULL: functionDefinition_AST_in = _t try: ## for error handling pass _t157 = _t tmp94_AST_in = _t self.match(_t,LITERAL_def) _t = _t.getFirstChild() t=self.expression(_t) _t = self._retTree n=self.symbol(_t) _t = self._retTree a=self.typedArgumentsList(_t) _t = self._retTree s=self.suite(_t) _t = self._retTree _t = _t157 _t = _t.getNextSibling() r = PepDef( t, n, a, s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def classDefinition(self, _t): r = None classDefinition_AST_in = None if _t != antlr.ASTNULL: classDefinition_AST_in = _t try: ## for error handling pass _t163 = _t tmp95_AST_in = _t self.match(_t,LITERAL_class) _t = _t.getFirstChild() n=self.symbol(_t) _t = self._retTree s=self.classSuite(_t) _t = self._retTree _t = _t163 _t = _t.getNextSibling() r = PepClass( n, (), s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceDefinition(self, _t): r = None interfaceDefinition_AST_in = None if _t != antlr.ASTNULL: interfaceDefinition_AST_in = _t try: ## for error handling pass _t165 = _t tmp96_AST_in = _t self.match(_t,LITERAL_interface) _t = _t.getFirstChild() n=self.symbol(_t) _t = self._retTree s=self.interfaceSuite(_t) _t = self._retTree _t = _t165 _t = _t.getNextSibling() r = PepInterface( n, (), s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def forStatement(self, _t): r = None forStatement_AST_in = None if _t != antlr.ASTNULL: forStatement_AST_in = _t try: ## for error handling pass _t167 = _t tmp97_AST_in = _t self.match(_t,LITERAL_for) _t = _t.getFirstChild() t=self.expression(_t) _t = self._retTree v=self.symbol(_t) _t = self._retTree i=self.expression(_t) _t = self._retTree s=self.suite(_t) _t = self._retTree _t = _t167 _t = _t.getNextSibling() r = PepFor( t, v, i, s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def whileStatement(self, _t): r = None whileStatement_AST_in = None if _t != antlr.ASTNULL: whileStatement_AST_in = _t try: ## for error handling pass _t169 = _t tmp98_AST_in = _t self.match(_t,LITERAL_while) _t = _t.getFirstChild() e=self.expression(_t) _t = self._retTree s=self.suite(_t) _t = self._retTree _t = _t169 _t = _t.getNextSibling() r = PepWhile( e, s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def importStatement(self, _t): r = None importStatement_AST_in = None if _t != antlr.ASTNULL: importStatement_AST_in = _t m = None try: ## for error handling pass _t171 = _t tmp99_AST_in = _t self.match(_t,LITERAL_import) _t = _t.getFirstChild() m = _t self.match(_t,SYMBOL) _t = _t.getNextSibling() _t = _t171 _t = _t.getNextSibling() r = PepImport( m.getText() ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def classStatement(self, _t): r = None classStatement_AST_in = None if _t != antlr.ASTNULL: classStatement_AST_in = _t try: ## for error handling if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,PLUSEQUALS,GT,LT,EQUALS,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_for,LITERAL_while,LITERAL_import,LITERAL_if,LITERAL_quote]: pass s=self.statement(_t) _t = self._retTree r = s elif la1 and la1 in [LITERAL_def_init]: pass f=self.initFunctionDefinition(_t) _t = self._retTree r = f else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initFunctionDefinition(self, _t): r = None initFunctionDefinition_AST_in = None if _t != antlr.ASTNULL: initFunctionDefinition_AST_in = _t try: ## for error handling pass _t161 = _t tmp100_AST_in = _t self.match(_t,LITERAL_def_init) _t = _t.getFirstChild() a=self.typedArgumentsList(_t) _t = self._retTree s=self.initFunctionSuite(_t) _t = self._retTree _t = _t161 _t = _t.getNextSibling() r = PepDefInit( a, s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceStatement(self, _t): r = None interfaceStatement_AST_in = None if _t != antlr.ASTNULL: interfaceStatement_AST_in = _t try: ## for error handling pass f=self.interfaceFunctionDefinition(_t) _t = self._retTree r = f except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceFunctionDefinition(self, _t): r = None interfaceFunctionDefinition_AST_in = None if _t != antlr.ASTNULL: interfaceFunctionDefinition_AST_in = _t try: ## for error handling pass _t159 = _t tmp101_AST_in = _t self.match(_t,LITERAL_def) _t = _t.getFirstChild() t=self.expression(_t) _t = self._retTree n=self.symbol(_t) _t = self._retTree a=self.typedArgumentsList(_t) _t = self._retTree _t = _t159 _t = _t.getNextSibling() r = PepInterfaceDef( t, n, a ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def symbol(self, _t): r = None symbol_AST_in = None if _t != antlr.ASTNULL: symbol_AST_in = _t f = None try: ## for error handling pass f = _t self.match(_t,SYMBOL) _t = _t.getNextSibling() r = PepSymbol( f.getText() ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def arraylookup(self, _t): r = None arraylookup_AST_in = None if _t != antlr.ASTNULL: arraylookup_AST_in = _t try: ## for error handling pass _t174 = _t tmp102_AST_in = _t self.match(_t,LSQUBR) _t = _t.getFirstChild() arr=self.symbol(_t) _t = self._retTree idx=self.expression(_t) _t = self._retTree _t = _t174 _t = _t.getNextSibling() r = PepArrayLookup( arr, idx ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def ifExpression(self, _t): r = None ifExpression_AST_in = None if _t != antlr.ASTNULL: ifExpression_AST_in = _t try: ## for error handling pass _t176 = _t tmp103_AST_in = _t self.match(_t,LITERAL_if) _t = _t.getFirstChild() pred=self.expression(_t) _t = self._retTree s=self.suite(_t) _t = self._retTree es=self.elseExpression(_t) _t = self._retTree _t = _t176 _t = _t.getNextSibling() r = PepIf( pred, s, es ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def functionCall(self, _t): r = None functionCall_AST_in = None if _t != antlr.ASTNULL: functionCall_AST_in = _t try: ## for error handling pass _t187 = _t tmp104_AST_in = _t self.match(_t,LPAREN) _t = _t.getFirstChild() f=self.symbol(_t) _t = self._retTree a=self.argumentsList(_t) _t = self._retTree _t = _t187 _t = _t.getNextSibling() r = PepFunctionCall( f, a ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def quotedCode(self, _t): r = None quotedCode_AST_in = None if _t != antlr.ASTNULL: quotedCode_AST_in = _t try: ## for error handling pass _t180 = _t tmp105_AST_in = _t self.match(_t,LITERAL_quote) _t = _t.getFirstChild() s=self.suite(_t) _t = self._retTree _t = _t180 _t = _t.getNextSibling() r = PepQuote( s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def tuple(self, _t): r = None tuple_AST_in = None if _t != antlr.ASTNULL: tuple_AST_in = _t try: ## for error handling pass t=self.tupleContents(_t) _t = self._retTree r = PepTuple( t ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def typedArgumentsList(self, _t): r = None typedArgumentsList_AST_in = None if _t != antlr.ASTNULL: typedArgumentsList_AST_in = _t r = () try: ## for error handling pass _t189 = _t tmp106_AST_in = _t self.match(_t,LPAREN) _t = _t.getFirstChild() if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,GT,LT,LITERAL_if,LITERAL_quote]: pass e=self.expression(_t) _t = self._retTree s=self.symbol(_t) _t = self._retTree r = ( (e,s), ) while True: if not _t: _t = antlr.ASTNULL if (_t.getType()==COMMA): pass tmp107_AST_in = _t self.match(_t,COMMA) _t = _t.getNextSibling() e=self.expression(_t) _t = self._retTree s=self.symbol(_t) _t = self._retTree r += ( (e,s), ) else: break elif la1 and la1 in [3]: pass else: raise antlr.NoViableAltException(_t) _t = _t189 _t = _t.getNextSibling() except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def suite(self, _t): r = None suite_AST_in = None if _t != antlr.ASTNULL: suite_AST_in = _t try: ## for error handling pass _t194 = _t tmp108_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.statementsList(_t) _t = self._retTree _t = _t194 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initFunctionSuite(self, _t): r = None initFunctionSuite_AST_in = None if _t != antlr.ASTNULL: initFunctionSuite_AST_in = _t try: ## for error handling pass _t200 = _t tmp109_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.initFunctionStatementsList(_t) _t = self._retTree _t = _t200 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def classSuite(self, _t): r = None classSuite_AST_in = None if _t != antlr.ASTNULL: classSuite_AST_in = _t try: ## for error handling pass _t196 = _t tmp110_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.classStatementsList(_t) _t = self._retTree _t = _t196 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceSuite(self, _t): r = None interfaceSuite_AST_in = None if _t != antlr.ASTNULL: interfaceSuite_AST_in = _t try: ## for error handling pass _t198 = _t tmp111_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.interfaceStatementsList(_t) _t = self._retTree _t = _t198 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def elseExpression(self, _t): r = None elseExpression_AST_in = None if _t != antlr.ASTNULL: elseExpression_AST_in = _t r = None try: ## for error handling pass if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [LITERAL_else]: pass tmp112_AST_in = _t self.match(_t,LITERAL_else) _t = _t.getNextSibling() s=self.suite(_t) _t = self._retTree r = s elif la1 and la1 in [3]: pass else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def tupleContents(self, _t): r = None tupleContents_AST_in = None if _t != antlr.ASTNULL: tupleContents_AST_in = _t try: ## for error handling pass _t183 = _t tmp113_AST_in = _t self.match(_t,COMMA) _t = _t.getFirstChild() e=self.expression(_t) _t = self._retTree r = (e,) while True: if not _t: _t = antlr.ASTNULL if (_tokenSet_0.member(_t.getType())): pass e=self.expression(_t) _t = self._retTree r += (e,) else: break _t = _t183 _t = _t.getNextSibling() except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def argumentsList(self, _t): r = None argumentsList_AST_in = None if _t != antlr.ASTNULL: argumentsList_AST_in = _t r = () try: ## for error handling pass if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,GT,LT,LITERAL_if,LITERAL_quote]: pass e=self.expression(_t) _t = self._retTree r = (e,) while True: if not _t: _t = antlr.ASTNULL if (_t.getType()==COMMA): pass tmp114_AST_in = _t self.match(_t,COMMA) _t = _t.getNextSibling() e=self.expression(_t) _t = self._retTree r += (e,) else: break elif la1 and la1 in [3]: pass else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def statementsList(self, _t): r = None statementsList_AST_in = None if _t != antlr.ASTNULL: statementsList_AST_in = _t r = () try: ## for error handling pass s=self.statementOrReturnStatement(_t) _t = self._retTree r = (s,) while True: if not _t: _t = antlr.ASTNULL if (_tokenSet_1.member(_t.getType())): pass s=self.statementOrReturnStatement(_t) _t = self._retTree r += (s,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def classStatementsList(self, _t): r = None classStatementsList_AST_in = None if _t != antlr.ASTNULL: classStatementsList_AST_in = _t r = () try: ## for error handling pass s=self.classStatement(_t) _t = self._retTree r = (s,) while True: if not _t: _t = antlr.ASTNULL if (_tokenSet_2.member(_t.getType())): pass s=self.classStatement(_t) _t = self._retTree r += (s,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def interfaceStatementsList(self, _t): r = None interfaceStatementsList_AST_in = None if _t != antlr.ASTNULL: interfaceStatementsList_AST_in = _t r = () try: ## for error handling pass s=self.interfaceStatement(_t) _t = self._retTree r = (s,) while True: if not _t: _t = antlr.ASTNULL if (_t.getType()==LITERAL_def): pass s=self.interfaceStatement(_t) _t = self._retTree r += (s,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initFunctionStatementsList(self, _t): r = None initFunctionStatementsList_AST_in = None if _t != antlr.ASTNULL: initFunctionStatementsList_AST_in = _t r = () try: ## for error handling pass if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [LITERAL_var]: pass v=self.varStatement(_t) _t = self._retTree r = (v,) elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,PLUSEQUALS,GT,LT,EQUALS,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_for,LITERAL_while,LITERAL_import,LITERAL_if,LITERAL_quote]: pass s=self.statement(_t) _t = self._retTree r = (s,) else: raise antlr.NoViableAltException(_t) while True: if not _t: _t = antlr.ASTNULL if (_tokenSet_3.member(_t.getType())): pass s=self.statement(_t) _t = self._retTree r += (s,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def varSuite(self, _t): r = None varSuite_AST_in = None if _t != antlr.ASTNULL: varSuite_AST_in = _t try: ## for error handling pass _t202 = _t tmp115_AST_in = _t self.match(_t,COLON) _t = _t.getFirstChild() s=self.initialisationsList(_t) _t = self._retTree _t = _t202 _t = _t.getNextSibling() r = s except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def initialisationsList(self, _t): r = None initialisationsList_AST_in = None if _t != antlr.ASTNULL: initialisationsList_AST_in = _t r = () try: ## for error handling pass i=self.initialisation(_t) _t = self._retTree r = (i,) while True: if not _t: _t = antlr.ASTNULL if (_t.getType()==EQUALS): pass i=self.initialisation(_t) _t = self._retTree r += (i,) else: break except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def statementOrReturnStatement(self, _t): r = None statementOrReturnStatement_AST_in = None if _t != antlr.ASTNULL: statementOrReturnStatement_AST_in = _t try: ## for error handling if not _t: _t = antlr.ASTNULL la1 = _t.getType() if False: pass elif la1 and la1 in [INT,FLOAT,STRING,LPAREN,LSQUBR,COMMA,SYMBOL,PLUS,MINUS,TIMES,PLUSEQUALS,GT,LT,EQUALS,LITERAL_def,LITERAL_class,LITERAL_interface,LITERAL_for,LITERAL_while,LITERAL_import,LITERAL_if,LITERAL_quote]: pass s=self.statement(_t) _t = self._retTree r = s elif la1 and la1 in [LITERAL_return]: pass _t226 = _t tmp116_AST_in = _t self.match(_t,LITERAL_return) _t = _t.getFirstChild() e=self.expression(_t) _t = self._retTree _t = _t226 _t = _t.getNextSibling() r = PepReturn( e ) else: raise antlr.NoViableAltException(_t) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r def varStatement(self, _t): r = None varStatement_AST_in = None if _t != antlr.ASTNULL: varStatement_AST_in = _t try: ## for error handling pass _t224 = _t tmp117_AST_in = _t self.match(_t,LITERAL_var) _t = _t.getFirstChild() s=self.varSuite(_t) _t = self._retTree _t = _t224 _t = _t.getNextSibling() r = PepVar( s ) except antlr.RecognitionException, ex: self.reportError(ex) if _t: _t = _t.getNextSibling() self._retTree = _t return r _tokenNames = [ "<0>", "EOF", "<2>", "NULL_TREE_LOOKAHEAD", "INDENT", "DEDENT", "WHITESPACE", "LEADINGSP", "COMMENT", "DIGIT", "DIGITS", "INT", "FLOAT", "INT_OR_FLOAT", "TRIPLEDOUBLEQUOTE", "DOUBLEQUOTE", "DOUBLEQUOTESTRING", "TRIPLEDOUBLEQUOTESTRING", "STRING", "LPAREN", "RPAREN", "LSQUBR", "RSQUBR", "COMMA", "STARTSYMBOLCHAR", "MIDSYMBOLCHAR", "SYMBOL_EL", "SYMBOL", "NEWLINE", "PLUS", "MINUS", "TIMES", "PLUSEQUALS", "GT", "LT", "COLON", "EQUALS", "\"def\"", "\"def_init\"", "\"class\"", "\"interface\"", "\"for\"", "\"in\"", "\"while\"", "\"import\"", "\"if\"", "\"else\"", "\"quote\"", "\"var\"", "\"return\"" ] ### generate bit set def mk_tokenSet_0(): ### var1 data = [ 175951533840384L, 0L] return data _tokenSet_0 = antlr.BitSet(mk_tokenSet_0()) ### generate bit set def mk_tokenSet_1(): ### var1 data = [ 769348510423040L, 0L] return data _tokenSet_1 = antlr.BitSet(mk_tokenSet_1()) ### generate bit set def mk_tokenSet_2(): ### var1 data = [ 206673434908672L, 0L] return data _tokenSet_2 = antlr.BitSet(mk_tokenSet_2()) ### generate bit set def mk_tokenSet_3(): ### var1 data = [ 206398557001728L, 0L] return data _tokenSet_3 = antlr.BitSet(mk_tokenSet_3())
{ "repo_name": "andybalaam/pepper", "path": "old/pepper1/src/parse/PepperTreeWalker.py", "copies": "1", "size": "40382", "license": "mit", "hash": 2938147023336140300, "line_mean": 27.3980309423, "line_max": 229, "alpha_frac": 0.4210291714, "autogenerated": false, "ratio": 3.9796984330343945, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4900727604434394, "avg_score": null, "num_lines": null }
# $ANTLR 3.0.1 C.g 2010-02-23 09:58:53 from antlr3 import * from antlr3.compat import set, frozenset ## @file # The file defines the Lexer for C source files. # # THIS FILE IS AUTO-GENENERATED. PLEASE DON NOT MODIFY THIS FILE. # This file is generated by running: # java org.antlr.Tool C.g # # Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR> # # This program and the accompanying materials are licensed and made available # under the terms and conditions of the BSD License which accompanies this # distribution. The full text of the license may be found at: # http://opensource.org/licenses/bsd-license.php # # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. # ## # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types T114=114 T115=115 T116=116 T117=117 FloatTypeSuffix=16 LETTER=11 T29=29 T28=28 T27=27 T26=26 T25=25 EOF=-1 STRING_LITERAL=9 FLOATING_POINT_LITERAL=10 T38=38 T37=37 T39=39 T34=34 COMMENT=22 T33=33 T36=36 T35=35 T30=30 T32=32 T31=31 LINE_COMMENT=23 IntegerTypeSuffix=14 CHARACTER_LITERAL=8 T49=49 T48=48 T100=100 T43=43 T42=42 T102=102 T41=41 T101=101 T40=40 T47=47 T46=46 T45=45 T44=44 T109=109 T107=107 T108=108 T105=105 WS=19 T106=106 T103=103 T104=104 T50=50 LINE_COMMAND=24 T59=59 T113=113 T52=52 T112=112 T51=51 T111=111 T54=54 T110=110 EscapeSequence=12 DECIMAL_LITERAL=7 T53=53 T56=56 T55=55 T58=58 T57=57 T75=75 T76=76 T73=73 T74=74 T79=79 T77=77 T78=78 Exponent=15 HexDigit=13 T72=72 T71=71 T70=70 T62=62 T63=63 T64=64 T65=65 T66=66 T67=67 T68=68 T69=69 IDENTIFIER=4 UnicodeVocabulary=21 HEX_LITERAL=5 T61=61 T60=60 T99=99 T97=97 BS=20 T98=98 T95=95 T96=96 OCTAL_LITERAL=6 T94=94 Tokens=118 T93=93 T92=92 T91=91 T90=90 T88=88 T89=89 T84=84 T85=85 T86=86 T87=87 UnicodeEscape=18 T81=81 T80=80 T83=83 OctalEscape=17 T82=82 class CLexer(Lexer): grammarFileName = "C.g" def __init__(self, input=None): Lexer.__init__(self, input) self.dfa25 = self.DFA25( self, 25, eot = self.DFA25_eot, eof = self.DFA25_eof, min = self.DFA25_min, max = self.DFA25_max, accept = self.DFA25_accept, special = self.DFA25_special, transition = self.DFA25_transition ) self.dfa35 = self.DFA35( self, 35, eot = self.DFA35_eot, eof = self.DFA35_eof, min = self.DFA35_min, max = self.DFA35_max, accept = self.DFA35_accept, special = self.DFA35_special, transition = self.DFA35_transition ) # $ANTLR start T25 def mT25(self, ): try: self.type = T25 # C.g:27:5: ( ';' ) # C.g:27:7: ';' self.match(u';') finally: pass # $ANTLR end T25 # $ANTLR start T26 def mT26(self, ): try: self.type = T26 # C.g:28:5: ( 'typedef' ) # C.g:28:7: 'typedef' self.match("typedef") finally: pass # $ANTLR end T26 # $ANTLR start T27 def mT27(self, ): try: self.type = T27 # C.g:29:5: ( ',' ) # C.g:29:7: ',' self.match(u',') finally: pass # $ANTLR end T27 # $ANTLR start T28 def mT28(self, ): try: self.type = T28 # C.g:30:5: ( '=' ) # C.g:30:7: '=' self.match(u'=') finally: pass # $ANTLR end T28 # $ANTLR start T29 def mT29(self, ): try: self.type = T29 # C.g:31:5: ( 'extern' ) # C.g:31:7: 'extern' self.match("extern") finally: pass # $ANTLR end T29 # $ANTLR start T30 def mT30(self, ): try: self.type = T30 # C.g:32:5: ( 'static' ) # C.g:32:7: 'static' self.match("static") finally: pass # $ANTLR end T30 # $ANTLR start T31 def mT31(self, ): try: self.type = T31 # C.g:33:5: ( 'auto' ) # C.g:33:7: 'auto' self.match("auto") finally: pass # $ANTLR end T31 # $ANTLR start T32 def mT32(self, ): try: self.type = T32 # C.g:34:5: ( 'register' ) # C.g:34:7: 'register' self.match("register") finally: pass # $ANTLR end T32 # $ANTLR start T33 def mT33(self, ): try: self.type = T33 # C.g:35:5: ( 'STATIC' ) # C.g:35:7: 'STATIC' self.match("STATIC") finally: pass # $ANTLR end T33 # $ANTLR start T34 def mT34(self, ): try: self.type = T34 # C.g:36:5: ( 'void' ) # C.g:36:7: 'void' self.match("void") finally: pass # $ANTLR end T34 # $ANTLR start T35 def mT35(self, ): try: self.type = T35 # C.g:37:5: ( 'char' ) # C.g:37:7: 'char' self.match("char") finally: pass # $ANTLR end T35 # $ANTLR start T36 def mT36(self, ): try: self.type = T36 # C.g:38:5: ( 'short' ) # C.g:38:7: 'short' self.match("short") finally: pass # $ANTLR end T36 # $ANTLR start T37 def mT37(self, ): try: self.type = T37 # C.g:39:5: ( 'int' ) # C.g:39:7: 'int' self.match("int") finally: pass # $ANTLR end T37 # $ANTLR start T38 def mT38(self, ): try: self.type = T38 # C.g:40:5: ( 'long' ) # C.g:40:7: 'long' self.match("long") finally: pass # $ANTLR end T38 # $ANTLR start T39 def mT39(self, ): try: self.type = T39 # C.g:41:5: ( 'float' ) # C.g:41:7: 'float' self.match("float") finally: pass # $ANTLR end T39 # $ANTLR start T40 def mT40(self, ): try: self.type = T40 # C.g:42:5: ( 'double' ) # C.g:42:7: 'double' self.match("double") finally: pass # $ANTLR end T40 # $ANTLR start T41 def mT41(self, ): try: self.type = T41 # C.g:43:5: ( 'signed' ) # C.g:43:7: 'signed' self.match("signed") finally: pass # $ANTLR end T41 # $ANTLR start T42 def mT42(self, ): try: self.type = T42 # C.g:44:5: ( 'unsigned' ) # C.g:44:7: 'unsigned' self.match("unsigned") finally: pass # $ANTLR end T42 # $ANTLR start T43 def mT43(self, ): try: self.type = T43 # C.g:45:5: ( '{' ) # C.g:45:7: '{' self.match(u'{') finally: pass # $ANTLR end T43 # $ANTLR start T44 def mT44(self, ): try: self.type = T44 # C.g:46:5: ( '}' ) # C.g:46:7: '}' self.match(u'}') finally: pass # $ANTLR end T44 # $ANTLR start T45 def mT45(self, ): try: self.type = T45 # C.g:47:5: ( 'struct' ) # C.g:47:7: 'struct' self.match("struct") finally: pass # $ANTLR end T45 # $ANTLR start T46 def mT46(self, ): try: self.type = T46 # C.g:48:5: ( 'union' ) # C.g:48:7: 'union' self.match("union") finally: pass # $ANTLR end T46 # $ANTLR start T47 def mT47(self, ): try: self.type = T47 # C.g:49:5: ( ':' ) # C.g:49:7: ':' self.match(u':') finally: pass # $ANTLR end T47 # $ANTLR start T48 def mT48(self, ): try: self.type = T48 # C.g:50:5: ( 'enum' ) # C.g:50:7: 'enum' self.match("enum") finally: pass # $ANTLR end T48 # $ANTLR start T49 def mT49(self, ): try: self.type = T49 # C.g:51:5: ( 'const' ) # C.g:51:7: 'const' self.match("const") finally: pass # $ANTLR end T49 # $ANTLR start T50 def mT50(self, ): try: self.type = T50 # C.g:52:5: ( 'volatile' ) # C.g:52:7: 'volatile' self.match("volatile") finally: pass # $ANTLR end T50 # $ANTLR start T51 def mT51(self, ): try: self.type = T51 # C.g:53:5: ( 'IN' ) # C.g:53:7: 'IN' self.match("IN") finally: pass # $ANTLR end T51 # $ANTLR start T52 def mT52(self, ): try: self.type = T52 # C.g:54:5: ( 'OUT' ) # C.g:54:7: 'OUT' self.match("OUT") finally: pass # $ANTLR end T52 # $ANTLR start T53 def mT53(self, ): try: self.type = T53 # C.g:55:5: ( 'OPTIONAL' ) # C.g:55:7: 'OPTIONAL' self.match("OPTIONAL") finally: pass # $ANTLR end T53 # $ANTLR start T54 def mT54(self, ): try: self.type = T54 # C.g:56:5: ( 'CONST' ) # C.g:56:7: 'CONST' self.match("CONST") finally: pass # $ANTLR end T54 # $ANTLR start T55 def mT55(self, ): try: self.type = T55 # C.g:57:5: ( 'UNALIGNED' ) # C.g:57:7: 'UNALIGNED' self.match("UNALIGNED") finally: pass # $ANTLR end T55 # $ANTLR start T56 def mT56(self, ): try: self.type = T56 # C.g:58:5: ( 'VOLATILE' ) # C.g:58:7: 'VOLATILE' self.match("VOLATILE") finally: pass # $ANTLR end T56 # $ANTLR start T57 def mT57(self, ): try: self.type = T57 # C.g:59:5: ( 'GLOBAL_REMOVE_IF_UNREFERENCED' ) # C.g:59:7: 'GLOBAL_REMOVE_IF_UNREFERENCED' self.match("GLOBAL_REMOVE_IF_UNREFERENCED") finally: pass # $ANTLR end T57 # $ANTLR start T58 def mT58(self, ): try: self.type = T58 # C.g:60:5: ( 'EFIAPI' ) # C.g:60:7: 'EFIAPI' self.match("EFIAPI") finally: pass # $ANTLR end T58 # $ANTLR start T59 def mT59(self, ): try: self.type = T59 # C.g:61:5: ( 'EFI_BOOTSERVICE' ) # C.g:61:7: 'EFI_BOOTSERVICE' self.match("EFI_BOOTSERVICE") finally: pass # $ANTLR end T59 # $ANTLR start T60 def mT60(self, ): try: self.type = T60 # C.g:62:5: ( 'EFI_RUNTIMESERVICE' ) # C.g:62:7: 'EFI_RUNTIMESERVICE' self.match("EFI_RUNTIMESERVICE") finally: pass # $ANTLR end T60 # $ANTLR start T61 def mT61(self, ): try: self.type = T61 # C.g:63:5: ( 'PACKED' ) # C.g:63:7: 'PACKED' self.match("PACKED") finally: pass # $ANTLR end T61 # $ANTLR start T62 def mT62(self, ): try: self.type = T62 # C.g:64:5: ( '(' ) # C.g:64:7: '(' self.match(u'(') finally: pass # $ANTLR end T62 # $ANTLR start T63 def mT63(self, ): try: self.type = T63 # C.g:65:5: ( ')' ) # C.g:65:7: ')' self.match(u')') finally: pass # $ANTLR end T63 # $ANTLR start T64 def mT64(self, ): try: self.type = T64 # C.g:66:5: ( '[' ) # C.g:66:7: '[' self.match(u'[') finally: pass # $ANTLR end T64 # $ANTLR start T65 def mT65(self, ): try: self.type = T65 # C.g:67:5: ( ']' ) # C.g:67:7: ']' self.match(u']') finally: pass # $ANTLR end T65 # $ANTLR start T66 def mT66(self, ): try: self.type = T66 # C.g:68:5: ( '*' ) # C.g:68:7: '*' self.match(u'*') finally: pass # $ANTLR end T66 # $ANTLR start T67 def mT67(self, ): try: self.type = T67 # C.g:69:5: ( '...' ) # C.g:69:7: '...' self.match("...") finally: pass # $ANTLR end T67 # $ANTLR start T68 def mT68(self, ): try: self.type = T68 # C.g:70:5: ( '+' ) # C.g:70:7: '+' self.match(u'+') finally: pass # $ANTLR end T68 # $ANTLR start T69 def mT69(self, ): try: self.type = T69 # C.g:71:5: ( '-' ) # C.g:71:7: '-' self.match(u'-') finally: pass # $ANTLR end T69 # $ANTLR start T70 def mT70(self, ): try: self.type = T70 # C.g:72:5: ( '/' ) # C.g:72:7: '/' self.match(u'/') finally: pass # $ANTLR end T70 # $ANTLR start T71 def mT71(self, ): try: self.type = T71 # C.g:73:5: ( '%' ) # C.g:73:7: '%' self.match(u'%') finally: pass # $ANTLR end T71 # $ANTLR start T72 def mT72(self, ): try: self.type = T72 # C.g:74:5: ( '++' ) # C.g:74:7: '++' self.match("++") finally: pass # $ANTLR end T72 # $ANTLR start T73 def mT73(self, ): try: self.type = T73 # C.g:75:5: ( '--' ) # C.g:75:7: '--' self.match("--") finally: pass # $ANTLR end T73 # $ANTLR start T74 def mT74(self, ): try: self.type = T74 # C.g:76:5: ( 'sizeof' ) # C.g:76:7: 'sizeof' self.match("sizeof") finally: pass # $ANTLR end T74 # $ANTLR start T75 def mT75(self, ): try: self.type = T75 # C.g:77:5: ( '.' ) # C.g:77:7: '.' self.match(u'.') finally: pass # $ANTLR end T75 # $ANTLR start T76 def mT76(self, ): try: self.type = T76 # C.g:78:5: ( '->' ) # C.g:78:7: '->' self.match("->") finally: pass # $ANTLR end T76 # $ANTLR start T77 def mT77(self, ): try: self.type = T77 # C.g:79:5: ( '&' ) # C.g:79:7: '&' self.match(u'&') finally: pass # $ANTLR end T77 # $ANTLR start T78 def mT78(self, ): try: self.type = T78 # C.g:80:5: ( '~' ) # C.g:80:7: '~' self.match(u'~') finally: pass # $ANTLR end T78 # $ANTLR start T79 def mT79(self, ): try: self.type = T79 # C.g:81:5: ( '!' ) # C.g:81:7: '!' self.match(u'!') finally: pass # $ANTLR end T79 # $ANTLR start T80 def mT80(self, ): try: self.type = T80 # C.g:82:5: ( '*=' ) # C.g:82:7: '*=' self.match("*=") finally: pass # $ANTLR end T80 # $ANTLR start T81 def mT81(self, ): try: self.type = T81 # C.g:83:5: ( '/=' ) # C.g:83:7: '/=' self.match("/=") finally: pass # $ANTLR end T81 # $ANTLR start T82 def mT82(self, ): try: self.type = T82 # C.g:84:5: ( '%=' ) # C.g:84:7: '%=' self.match("%=") finally: pass # $ANTLR end T82 # $ANTLR start T83 def mT83(self, ): try: self.type = T83 # C.g:85:5: ( '+=' ) # C.g:85:7: '+=' self.match("+=") finally: pass # $ANTLR end T83 # $ANTLR start T84 def mT84(self, ): try: self.type = T84 # C.g:86:5: ( '-=' ) # C.g:86:7: '-=' self.match("-=") finally: pass # $ANTLR end T84 # $ANTLR start T85 def mT85(self, ): try: self.type = T85 # C.g:87:5: ( '<<=' ) # C.g:87:7: '<<=' self.match("<<=") finally: pass # $ANTLR end T85 # $ANTLR start T86 def mT86(self, ): try: self.type = T86 # C.g:88:5: ( '>>=' ) # C.g:88:7: '>>=' self.match(">>=") finally: pass # $ANTLR end T86 # $ANTLR start T87 def mT87(self, ): try: self.type = T87 # C.g:89:5: ( '&=' ) # C.g:89:7: '&=' self.match("&=") finally: pass # $ANTLR end T87 # $ANTLR start T88 def mT88(self, ): try: self.type = T88 # C.g:90:5: ( '^=' ) # C.g:90:7: '^=' self.match("^=") finally: pass # $ANTLR end T88 # $ANTLR start T89 def mT89(self, ): try: self.type = T89 # C.g:91:5: ( '|=' ) # C.g:91:7: '|=' self.match("|=") finally: pass # $ANTLR end T89 # $ANTLR start T90 def mT90(self, ): try: self.type = T90 # C.g:92:5: ( '?' ) # C.g:92:7: '?' self.match(u'?') finally: pass # $ANTLR end T90 # $ANTLR start T91 def mT91(self, ): try: self.type = T91 # C.g:93:5: ( '||' ) # C.g:93:7: '||' self.match("||") finally: pass # $ANTLR end T91 # $ANTLR start T92 def mT92(self, ): try: self.type = T92 # C.g:94:5: ( '&&' ) # C.g:94:7: '&&' self.match("&&") finally: pass # $ANTLR end T92 # $ANTLR start T93 def mT93(self, ): try: self.type = T93 # C.g:95:5: ( '|' ) # C.g:95:7: '|' self.match(u'|') finally: pass # $ANTLR end T93 # $ANTLR start T94 def mT94(self, ): try: self.type = T94 # C.g:96:5: ( '^' ) # C.g:96:7: '^' self.match(u'^') finally: pass # $ANTLR end T94 # $ANTLR start T95 def mT95(self, ): try: self.type = T95 # C.g:97:5: ( '==' ) # C.g:97:7: '==' self.match("==") finally: pass # $ANTLR end T95 # $ANTLR start T96 def mT96(self, ): try: self.type = T96 # C.g:98:5: ( '!=' ) # C.g:98:7: '!=' self.match("!=") finally: pass # $ANTLR end T96 # $ANTLR start T97 def mT97(self, ): try: self.type = T97 # C.g:99:5: ( '<' ) # C.g:99:7: '<' self.match(u'<') finally: pass # $ANTLR end T97 # $ANTLR start T98 def mT98(self, ): try: self.type = T98 # C.g:100:5: ( '>' ) # C.g:100:7: '>' self.match(u'>') finally: pass # $ANTLR end T98 # $ANTLR start T99 def mT99(self, ): try: self.type = T99 # C.g:101:5: ( '<=' ) # C.g:101:7: '<=' self.match("<=") finally: pass # $ANTLR end T99 # $ANTLR start T100 def mT100(self, ): try: self.type = T100 # C.g:102:6: ( '>=' ) # C.g:102:8: '>=' self.match(">=") finally: pass # $ANTLR end T100 # $ANTLR start T101 def mT101(self, ): try: self.type = T101 # C.g:103:6: ( '<<' ) # C.g:103:8: '<<' self.match("<<") finally: pass # $ANTLR end T101 # $ANTLR start T102 def mT102(self, ): try: self.type = T102 # C.g:104:6: ( '>>' ) # C.g:104:8: '>>' self.match(">>") finally: pass # $ANTLR end T102 # $ANTLR start T103 def mT103(self, ): try: self.type = T103 # C.g:105:6: ( '__asm__' ) # C.g:105:8: '__asm__' self.match("__asm__") finally: pass # $ANTLR end T103 # $ANTLR start T104 def mT104(self, ): try: self.type = T104 # C.g:106:6: ( '_asm' ) # C.g:106:8: '_asm' self.match("_asm") finally: pass # $ANTLR end T104 # $ANTLR start T105 def mT105(self, ): try: self.type = T105 # C.g:107:6: ( '__asm' ) # C.g:107:8: '__asm' self.match("__asm") finally: pass # $ANTLR end T105 # $ANTLR start T106 def mT106(self, ): try: self.type = T106 # C.g:108:6: ( 'case' ) # C.g:108:8: 'case' self.match("case") finally: pass # $ANTLR end T106 # $ANTLR start T107 def mT107(self, ): try: self.type = T107 # C.g:109:6: ( 'default' ) # C.g:109:8: 'default' self.match("default") finally: pass # $ANTLR end T107 # $ANTLR start T108 def mT108(self, ): try: self.type = T108 # C.g:110:6: ( 'if' ) # C.g:110:8: 'if' self.match("if") finally: pass # $ANTLR end T108 # $ANTLR start T109 def mT109(self, ): try: self.type = T109 # C.g:111:6: ( 'else' ) # C.g:111:8: 'else' self.match("else") finally: pass # $ANTLR end T109 # $ANTLR start T110 def mT110(self, ): try: self.type = T110 # C.g:112:6: ( 'switch' ) # C.g:112:8: 'switch' self.match("switch") finally: pass # $ANTLR end T110 # $ANTLR start T111 def mT111(self, ): try: self.type = T111 # C.g:113:6: ( 'while' ) # C.g:113:8: 'while' self.match("while") finally: pass # $ANTLR end T111 # $ANTLR start T112 def mT112(self, ): try: self.type = T112 # C.g:114:6: ( 'do' ) # C.g:114:8: 'do' self.match("do") finally: pass # $ANTLR end T112 # $ANTLR start T113 def mT113(self, ): try: self.type = T113 # C.g:115:6: ( 'for' ) # C.g:115:8: 'for' self.match("for") finally: pass # $ANTLR end T113 # $ANTLR start T114 def mT114(self, ): try: self.type = T114 # C.g:116:6: ( 'goto' ) # C.g:116:8: 'goto' self.match("goto") finally: pass # $ANTLR end T114 # $ANTLR start T115 def mT115(self, ): try: self.type = T115 # C.g:117:6: ( 'continue' ) # C.g:117:8: 'continue' self.match("continue") finally: pass # $ANTLR end T115 # $ANTLR start T116 def mT116(self, ): try: self.type = T116 # C.g:118:6: ( 'break' ) # C.g:118:8: 'break' self.match("break") finally: pass # $ANTLR end T116 # $ANTLR start T117 def mT117(self, ): try: self.type = T117 # C.g:119:6: ( 'return' ) # C.g:119:8: 'return' self.match("return") finally: pass # $ANTLR end T117 # $ANTLR start IDENTIFIER def mIDENTIFIER(self, ): try: self.type = IDENTIFIER # C.g:586:2: ( LETTER ( LETTER | '0' .. '9' )* ) # C.g:586:4: LETTER ( LETTER | '0' .. '9' )* self.mLETTER() # C.g:586:11: ( LETTER | '0' .. '9' )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == u'$' or (u'0' <= LA1_0 <= u'9') or (u'A' <= LA1_0 <= u'Z') or LA1_0 == u'_' or (u'a' <= LA1_0 <= u'z')) : alt1 = 1 if alt1 == 1: # C.g: if self.input.LA(1) == u'$' or (u'0' <= self.input.LA(1) <= u'9') or (u'A' <= self.input.LA(1) <= u'Z') or self.input.LA(1) == u'_' or (u'a' <= self.input.LA(1) <= u'z'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 finally: pass # $ANTLR end IDENTIFIER # $ANTLR start LETTER def mLETTER(self, ): try: # C.g:591:2: ( '$' | 'A' .. 'Z' | 'a' .. 'z' | '_' ) # C.g: if self.input.LA(1) == u'$' or (u'A' <= self.input.LA(1) <= u'Z') or self.input.LA(1) == u'_' or (u'a' <= self.input.LA(1) <= u'z'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end LETTER # $ANTLR start CHARACTER_LITERAL def mCHARACTER_LITERAL(self, ): try: self.type = CHARACTER_LITERAL # C.g:598:5: ( ( 'L' )? '\\'' ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) '\\'' ) # C.g:598:9: ( 'L' )? '\\'' ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) '\\'' # C.g:598:9: ( 'L' )? alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == u'L') : alt2 = 1 if alt2 == 1: # C.g:598:10: 'L' self.match(u'L') self.match(u'\'') # C.g:598:21: ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == u'\\') : alt3 = 1 elif ((u'\u0000' <= LA3_0 <= u'&') or (u'(' <= LA3_0 <= u'[') or (u']' <= LA3_0 <= u'\uFFFE')) : alt3 = 2 else: nvae = NoViableAltException("598:21: ( EscapeSequence | ~ ( '\\'' | '\\\\' ) )", 3, 0, self.input) raise nvae if alt3 == 1: # C.g:598:23: EscapeSequence self.mEscapeSequence() elif alt3 == 2: # C.g:598:40: ~ ( '\\'' | '\\\\' ) if (u'\u0000' <= self.input.LA(1) <= u'&') or (u'(' <= self.input.LA(1) <= u'[') or (u']' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(u'\'') finally: pass # $ANTLR end CHARACTER_LITERAL # $ANTLR start STRING_LITERAL def mSTRING_LITERAL(self, ): try: self.type = STRING_LITERAL # C.g:602:5: ( ( 'L' )? '\"' ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* '\"' ) # C.g:602:8: ( 'L' )? '\"' ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* '\"' # C.g:602:8: ( 'L' )? alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == u'L') : alt4 = 1 if alt4 == 1: # C.g:602:9: 'L' self.match(u'L') self.match(u'"') # C.g:602:19: ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* while True: #loop5 alt5 = 3 LA5_0 = self.input.LA(1) if (LA5_0 == u'\\') : alt5 = 1 elif ((u'\u0000' <= LA5_0 <= u'!') or (u'#' <= LA5_0 <= u'[') or (u']' <= LA5_0 <= u'\uFFFE')) : alt5 = 2 if alt5 == 1: # C.g:602:21: EscapeSequence self.mEscapeSequence() elif alt5 == 2: # C.g:602:38: ~ ( '\\\\' | '\"' ) if (u'\u0000' <= self.input.LA(1) <= u'!') or (u'#' <= self.input.LA(1) <= u'[') or (u']' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop5 self.match(u'"') finally: pass # $ANTLR end STRING_LITERAL # $ANTLR start HEX_LITERAL def mHEX_LITERAL(self, ): try: self.type = HEX_LITERAL # C.g:605:13: ( '0' ( 'x' | 'X' ) ( HexDigit )+ ( IntegerTypeSuffix )? ) # C.g:605:15: '0' ( 'x' | 'X' ) ( HexDigit )+ ( IntegerTypeSuffix )? self.match(u'0') if self.input.LA(1) == u'X' or self.input.LA(1) == u'x': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:605:29: ( HexDigit )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if ((u'0' <= LA6_0 <= u'9') or (u'A' <= LA6_0 <= u'F') or (u'a' <= LA6_0 <= u'f')) : alt6 = 1 if alt6 == 1: # C.g:605:29: HexDigit self.mHexDigit() else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 # C.g:605:39: ( IntegerTypeSuffix )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == u'L' or LA7_0 == u'U' or LA7_0 == u'l' or LA7_0 == u'u') : alt7 = 1 if alt7 == 1: # C.g:605:39: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end HEX_LITERAL # $ANTLR start DECIMAL_LITERAL def mDECIMAL_LITERAL(self, ): try: self.type = DECIMAL_LITERAL # C.g:607:17: ( ( '0' | '1' .. '9' ( '0' .. '9' )* ) ( IntegerTypeSuffix )? ) # C.g:607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* ) ( IntegerTypeSuffix )? # C.g:607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == u'0') : alt9 = 1 elif ((u'1' <= LA9_0 <= u'9')) : alt9 = 2 else: nvae = NoViableAltException("607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* )", 9, 0, self.input) raise nvae if alt9 == 1: # C.g:607:20: '0' self.match(u'0') elif alt9 == 2: # C.g:607:26: '1' .. '9' ( '0' .. '9' )* self.matchRange(u'1', u'9') # C.g:607:35: ( '0' .. '9' )* while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if ((u'0' <= LA8_0 <= u'9')) : alt8 = 1 if alt8 == 1: # C.g:607:35: '0' .. '9' self.matchRange(u'0', u'9') else: break #loop8 # C.g:607:46: ( IntegerTypeSuffix )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == u'L' or LA10_0 == u'U' or LA10_0 == u'l' or LA10_0 == u'u') : alt10 = 1 if alt10 == 1: # C.g:607:46: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end DECIMAL_LITERAL # $ANTLR start OCTAL_LITERAL def mOCTAL_LITERAL(self, ): try: self.type = OCTAL_LITERAL # C.g:609:15: ( '0' ( '0' .. '7' )+ ( IntegerTypeSuffix )? ) # C.g:609:17: '0' ( '0' .. '7' )+ ( IntegerTypeSuffix )? self.match(u'0') # C.g:609:21: ( '0' .. '7' )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((u'0' <= LA11_0 <= u'7')) : alt11 = 1 if alt11 == 1: # C.g:609:22: '0' .. '7' self.matchRange(u'0', u'7') else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 # C.g:609:33: ( IntegerTypeSuffix )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == u'L' or LA12_0 == u'U' or LA12_0 == u'l' or LA12_0 == u'u') : alt12 = 1 if alt12 == 1: # C.g:609:33: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end OCTAL_LITERAL # $ANTLR start HexDigit def mHexDigit(self, ): try: # C.g:612:10: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) ) # C.g:612:12: ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) if (u'0' <= self.input.LA(1) <= u'9') or (u'A' <= self.input.LA(1) <= u'F') or (u'a' <= self.input.LA(1) <= u'f'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end HexDigit # $ANTLR start IntegerTypeSuffix def mIntegerTypeSuffix(self, ): try: # C.g:616:2: ( ( 'u' | 'U' ) | ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) ) alt13 = 4 LA13_0 = self.input.LA(1) if (LA13_0 == u'U' or LA13_0 == u'u') : LA13_1 = self.input.LA(2) if (LA13_1 == u'L' or LA13_1 == u'l') : LA13_3 = self.input.LA(3) if (LA13_3 == u'L' or LA13_3 == u'l') : alt13 = 4 else: alt13 = 3 else: alt13 = 1 elif (LA13_0 == u'L' or LA13_0 == u'l') : alt13 = 2 else: nvae = NoViableAltException("614:1: fragment IntegerTypeSuffix : ( ( 'u' | 'U' ) | ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) );", 13, 0, self.input) raise nvae if alt13 == 1: # C.g:616:4: ( 'u' | 'U' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 2: # C.g:617:4: ( 'l' | 'L' ) if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 3: # C.g:618:4: ( 'u' | 'U' ) ( 'l' | 'L' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 4: # C.g:619:4: ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end IntegerTypeSuffix # $ANTLR start FLOATING_POINT_LITERAL def mFLOATING_POINT_LITERAL(self, ): try: self.type = FLOATING_POINT_LITERAL # C.g:623:5: ( ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( Exponent )? ( FloatTypeSuffix )? | '.' ( '0' .. '9' )+ ( Exponent )? ( FloatTypeSuffix )? | ( '0' .. '9' )+ Exponent ( FloatTypeSuffix )? | ( '0' .. '9' )+ ( Exponent )? FloatTypeSuffix ) alt25 = 4 alt25 = self.dfa25.predict(self.input) if alt25 == 1: # C.g:623:9: ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( Exponent )? ( FloatTypeSuffix )? # C.g:623:9: ( '0' .. '9' )+ cnt14 = 0 while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if ((u'0' <= LA14_0 <= u'9')) : alt14 = 1 if alt14 == 1: # C.g:623:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt14 >= 1: break #loop14 eee = EarlyExitException(14, self.input) raise eee cnt14 += 1 self.match(u'.') # C.g:623:25: ( '0' .. '9' )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if ((u'0' <= LA15_0 <= u'9')) : alt15 = 1 if alt15 == 1: # C.g:623:26: '0' .. '9' self.matchRange(u'0', u'9') else: break #loop15 # C.g:623:37: ( Exponent )? alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == u'E' or LA16_0 == u'e') : alt16 = 1 if alt16 == 1: # C.g:623:37: Exponent self.mExponent() # C.g:623:47: ( FloatTypeSuffix )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == u'D' or LA17_0 == u'F' or LA17_0 == u'd' or LA17_0 == u'f') : alt17 = 1 if alt17 == 1: # C.g:623:47: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 2: # C.g:624:9: '.' ( '0' .. '9' )+ ( Exponent )? ( FloatTypeSuffix )? self.match(u'.') # C.g:624:13: ( '0' .. '9' )+ cnt18 = 0 while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if ((u'0' <= LA18_0 <= u'9')) : alt18 = 1 if alt18 == 1: # C.g:624:14: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt18 >= 1: break #loop18 eee = EarlyExitException(18, self.input) raise eee cnt18 += 1 # C.g:624:25: ( Exponent )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == u'E' or LA19_0 == u'e') : alt19 = 1 if alt19 == 1: # C.g:624:25: Exponent self.mExponent() # C.g:624:35: ( FloatTypeSuffix )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == u'D' or LA20_0 == u'F' or LA20_0 == u'd' or LA20_0 == u'f') : alt20 = 1 if alt20 == 1: # C.g:624:35: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 3: # C.g:625:9: ( '0' .. '9' )+ Exponent ( FloatTypeSuffix )? # C.g:625:9: ( '0' .. '9' )+ cnt21 = 0 while True: #loop21 alt21 = 2 LA21_0 = self.input.LA(1) if ((u'0' <= LA21_0 <= u'9')) : alt21 = 1 if alt21 == 1: # C.g:625:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt21 >= 1: break #loop21 eee = EarlyExitException(21, self.input) raise eee cnt21 += 1 self.mExponent() # C.g:625:30: ( FloatTypeSuffix )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == u'D' or LA22_0 == u'F' or LA22_0 == u'd' or LA22_0 == u'f') : alt22 = 1 if alt22 == 1: # C.g:625:30: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 4: # C.g:626:9: ( '0' .. '9' )+ ( Exponent )? FloatTypeSuffix # C.g:626:9: ( '0' .. '9' )+ cnt23 = 0 while True: #loop23 alt23 = 2 LA23_0 = self.input.LA(1) if ((u'0' <= LA23_0 <= u'9')) : alt23 = 1 if alt23 == 1: # C.g:626:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt23 >= 1: break #loop23 eee = EarlyExitException(23, self.input) raise eee cnt23 += 1 # C.g:626:21: ( Exponent )? alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == u'E' or LA24_0 == u'e') : alt24 = 1 if alt24 == 1: # C.g:626:21: Exponent self.mExponent() self.mFloatTypeSuffix() finally: pass # $ANTLR end FLOATING_POINT_LITERAL # $ANTLR start Exponent def mExponent(self, ): try: # C.g:630:10: ( ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ ) # C.g:630:12: ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ if self.input.LA(1) == u'E' or self.input.LA(1) == u'e': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:630:22: ( '+' | '-' )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == u'+' or LA26_0 == u'-') : alt26 = 1 if alt26 == 1: # C.g: if self.input.LA(1) == u'+' or self.input.LA(1) == u'-': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:630:33: ( '0' .. '9' )+ cnt27 = 0 while True: #loop27 alt27 = 2 LA27_0 = self.input.LA(1) if ((u'0' <= LA27_0 <= u'9')) : alt27 = 1 if alt27 == 1: # C.g:630:34: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt27 >= 1: break #loop27 eee = EarlyExitException(27, self.input) raise eee cnt27 += 1 finally: pass # $ANTLR end Exponent # $ANTLR start FloatTypeSuffix def mFloatTypeSuffix(self, ): try: # C.g:633:17: ( ( 'f' | 'F' | 'd' | 'D' ) ) # C.g:633:19: ( 'f' | 'F' | 'd' | 'D' ) if self.input.LA(1) == u'D' or self.input.LA(1) == u'F' or self.input.LA(1) == u'd' or self.input.LA(1) == u'f': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end FloatTypeSuffix # $ANTLR start EscapeSequence def mEscapeSequence(self, ): try: # C.g:637:5: ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape ) alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == u'\\') : LA28_1 = self.input.LA(2) if (LA28_1 == u'"' or LA28_1 == u'\'' or LA28_1 == u'\\' or LA28_1 == u'b' or LA28_1 == u'f' or LA28_1 == u'n' or LA28_1 == u'r' or LA28_1 == u't') : alt28 = 1 elif ((u'0' <= LA28_1 <= u'7')) : alt28 = 2 else: nvae = NoViableAltException("635:1: fragment EscapeSequence : ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape );", 28, 1, self.input) raise nvae else: nvae = NoViableAltException("635:1: fragment EscapeSequence : ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape );", 28, 0, self.input) raise nvae if alt28 == 1: # C.g:637:8: '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) self.match(u'\\') if self.input.LA(1) == u'"' or self.input.LA(1) == u'\'' or self.input.LA(1) == u'\\' or self.input.LA(1) == u'b' or self.input.LA(1) == u'f' or self.input.LA(1) == u'n' or self.input.LA(1) == u'r' or self.input.LA(1) == u't': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt28 == 2: # C.g:638:9: OctalEscape self.mOctalEscape() finally: pass # $ANTLR end EscapeSequence # $ANTLR start OctalEscape def mOctalEscape(self, ): try: # C.g:643:5: ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ) alt29 = 3 LA29_0 = self.input.LA(1) if (LA29_0 == u'\\') : LA29_1 = self.input.LA(2) if ((u'0' <= LA29_1 <= u'3')) : LA29_2 = self.input.LA(3) if ((u'0' <= LA29_2 <= u'7')) : LA29_4 = self.input.LA(4) if ((u'0' <= LA29_4 <= u'7')) : alt29 = 1 else: alt29 = 2 else: alt29 = 3 elif ((u'4' <= LA29_1 <= u'7')) : LA29_3 = self.input.LA(3) if ((u'0' <= LA29_3 <= u'7')) : alt29 = 2 else: alt29 = 3 else: nvae = NoViableAltException("641:1: fragment OctalEscape : ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) );", 29, 1, self.input) raise nvae else: nvae = NoViableAltException("641:1: fragment OctalEscape : ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) );", 29, 0, self.input) raise nvae if alt29 == 1: # C.g:643:9: '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) self.match(u'\\') # C.g:643:14: ( '0' .. '3' ) # C.g:643:15: '0' .. '3' self.matchRange(u'0', u'3') # C.g:643:25: ( '0' .. '7' ) # C.g:643:26: '0' .. '7' self.matchRange(u'0', u'7') # C.g:643:36: ( '0' .. '7' ) # C.g:643:37: '0' .. '7' self.matchRange(u'0', u'7') elif alt29 == 2: # C.g:644:9: '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) self.match(u'\\') # C.g:644:14: ( '0' .. '7' ) # C.g:644:15: '0' .. '7' self.matchRange(u'0', u'7') # C.g:644:25: ( '0' .. '7' ) # C.g:644:26: '0' .. '7' self.matchRange(u'0', u'7') elif alt29 == 3: # C.g:645:9: '\\\\' ( '0' .. '7' ) self.match(u'\\') # C.g:645:14: ( '0' .. '7' ) # C.g:645:15: '0' .. '7' self.matchRange(u'0', u'7') finally: pass # $ANTLR end OctalEscape # $ANTLR start UnicodeEscape def mUnicodeEscape(self, ): try: # C.g:650:5: ( '\\\\' 'u' HexDigit HexDigit HexDigit HexDigit ) # C.g:650:9: '\\\\' 'u' HexDigit HexDigit HexDigit HexDigit self.match(u'\\') self.match(u'u') self.mHexDigit() self.mHexDigit() self.mHexDigit() self.mHexDigit() finally: pass # $ANTLR end UnicodeEscape # $ANTLR start WS def mWS(self, ): try: self.type = WS # C.g:653:5: ( ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) ) # C.g:653:8: ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) if (u'\t' <= self.input.LA(1) <= u'\n') or (u'\f' <= self.input.LA(1) <= u'\r') or self.input.LA(1) == u' ': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end WS # $ANTLR start BS def mBS(self, ): try: self.type = BS # C.g:657:5: ( ( '\\\\' ) ) # C.g:657:7: ( '\\\\' ) # C.g:657:7: ( '\\\\' ) # C.g:657:8: '\\\\' self.match(u'\\') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end BS # $ANTLR start UnicodeVocabulary def mUnicodeVocabulary(self, ): try: self.type = UnicodeVocabulary # C.g:665:5: ( '\\u0003' .. '\\uFFFE' ) # C.g:665:7: '\\u0003' .. '\\uFFFE' self.matchRange(u'\u0003', u'\uFFFE') finally: pass # $ANTLR end UnicodeVocabulary # $ANTLR start COMMENT def mCOMMENT(self, ): try: self.type = COMMENT # C.g:668:5: ( '/*' ( options {greedy=false; } : . )* '*/' ) # C.g:668:9: '/*' ( options {greedy=false; } : . )* '*/' self.match("/*") # C.g:668:14: ( options {greedy=false; } : . )* while True: #loop30 alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == u'*') : LA30_1 = self.input.LA(2) if (LA30_1 == u'/') : alt30 = 2 elif ((u'\u0000' <= LA30_1 <= u'.') or (u'0' <= LA30_1 <= u'\uFFFE')) : alt30 = 1 elif ((u'\u0000' <= LA30_0 <= u')') or (u'+' <= LA30_0 <= u'\uFFFE')) : alt30 = 1 if alt30 == 1: # C.g:668:42: . self.matchAny() else: break #loop30 self.match("*/") #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end COMMENT # $ANTLR start LINE_COMMENT def mLINE_COMMENT(self, ): try: self.type = LINE_COMMENT # C.g:673:5: ( '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) # C.g:673:7: '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' self.match("//") # C.g:673:12: (~ ( '\\n' | '\\r' ) )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if ((u'\u0000' <= LA31_0 <= u'\t') or (u'\u000B' <= LA31_0 <= u'\f') or (u'\u000E' <= LA31_0 <= u'\uFFFE')) : alt31 = 1 if alt31 == 1: # C.g:673:12: ~ ( '\\n' | '\\r' ) if (u'\u0000' <= self.input.LA(1) <= u'\t') or (u'\u000B' <= self.input.LA(1) <= u'\f') or (u'\u000E' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop31 # C.g:673:26: ( '\\r' )? alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == u'\r') : alt32 = 1 if alt32 == 1: # C.g:673:26: '\\r' self.match(u'\r') self.match(u'\n') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end LINE_COMMENT # $ANTLR start LINE_COMMAND def mLINE_COMMAND(self, ): try: self.type = LINE_COMMAND # C.g:678:5: ( '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) # C.g:678:7: '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' self.match(u'#') # C.g:678:11: (~ ( '\\n' | '\\r' ) )* while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if ((u'\u0000' <= LA33_0 <= u'\t') or (u'\u000B' <= LA33_0 <= u'\f') or (u'\u000E' <= LA33_0 <= u'\uFFFE')) : alt33 = 1 if alt33 == 1: # C.g:678:11: ~ ( '\\n' | '\\r' ) if (u'\u0000' <= self.input.LA(1) <= u'\t') or (u'\u000B' <= self.input.LA(1) <= u'\f') or (u'\u000E' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop33 # C.g:678:25: ( '\\r' )? alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == u'\r') : alt34 = 1 if alt34 == 1: # C.g:678:25: '\\r' self.match(u'\r') self.match(u'\n') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end LINE_COMMAND def mTokens(self): # C.g:1:8: ( T25 | T26 | T27 | T28 | T29 | T30 | T31 | T32 | T33 | T34 | T35 | T36 | T37 | T38 | T39 | T40 | T41 | T42 | T43 | T44 | T45 | T46 | T47 | T48 | T49 | T50 | T51 | T52 | T53 | T54 | T55 | T56 | T57 | T58 | T59 | T60 | T61 | T62 | T63 | T64 | T65 | T66 | T67 | T68 | T69 | T70 | T71 | T72 | T73 | T74 | T75 | T76 | T77 | T78 | T79 | T80 | T81 | T82 | T83 | T84 | T85 | T86 | T87 | T88 | T89 | T90 | T91 | T92 | T93 | T94 | T95 | T96 | T97 | T98 | T99 | T100 | T101 | T102 | T103 | T104 | T105 | T106 | T107 | T108 | T109 | T110 | T111 | T112 | T113 | T114 | T115 | T116 | T117 | IDENTIFIER | CHARACTER_LITERAL | STRING_LITERAL | HEX_LITERAL | DECIMAL_LITERAL | OCTAL_LITERAL | FLOATING_POINT_LITERAL | WS | BS | UnicodeVocabulary | COMMENT | LINE_COMMENT | LINE_COMMAND ) alt35 = 106 alt35 = self.dfa35.predict(self.input) if alt35 == 1: # C.g:1:10: T25 self.mT25() elif alt35 == 2: # C.g:1:14: T26 self.mT26() elif alt35 == 3: # C.g:1:18: T27 self.mT27() elif alt35 == 4: # C.g:1:22: T28 self.mT28() elif alt35 == 5: # C.g:1:26: T29 self.mT29() elif alt35 == 6: # C.g:1:30: T30 self.mT30() elif alt35 == 7: # C.g:1:34: T31 self.mT31() elif alt35 == 8: # C.g:1:38: T32 self.mT32() elif alt35 == 9: # C.g:1:42: T33 self.mT33() elif alt35 == 10: # C.g:1:46: T34 self.mT34() elif alt35 == 11: # C.g:1:50: T35 self.mT35() elif alt35 == 12: # C.g:1:54: T36 self.mT36() elif alt35 == 13: # C.g:1:58: T37 self.mT37() elif alt35 == 14: # C.g:1:62: T38 self.mT38() elif alt35 == 15: # C.g:1:66: T39 self.mT39() elif alt35 == 16: # C.g:1:70: T40 self.mT40() elif alt35 == 17: # C.g:1:74: T41 self.mT41() elif alt35 == 18: # C.g:1:78: T42 self.mT42() elif alt35 == 19: # C.g:1:82: T43 self.mT43() elif alt35 == 20: # C.g:1:86: T44 self.mT44() elif alt35 == 21: # C.g:1:90: T45 self.mT45() elif alt35 == 22: # C.g:1:94: T46 self.mT46() elif alt35 == 23: # C.g:1:98: T47 self.mT47() elif alt35 == 24: # C.g:1:102: T48 self.mT48() elif alt35 == 25: # C.g:1:106: T49 self.mT49() elif alt35 == 26: # C.g:1:110: T50 self.mT50() elif alt35 == 27: # C.g:1:114: T51 self.mT51() elif alt35 == 28: # C.g:1:118: T52 self.mT52() elif alt35 == 29: # C.g:1:122: T53 self.mT53() elif alt35 == 30: # C.g:1:126: T54 self.mT54() elif alt35 == 31: # C.g:1:130: T55 self.mT55() elif alt35 == 32: # C.g:1:134: T56 self.mT56() elif alt35 == 33: # C.g:1:138: T57 self.mT57() elif alt35 == 34: # C.g:1:142: T58 self.mT58() elif alt35 == 35: # C.g:1:146: T59 self.mT59() elif alt35 == 36: # C.g:1:150: T60 self.mT60() elif alt35 == 37: # C.g:1:154: T61 self.mT61() elif alt35 == 38: # C.g:1:158: T62 self.mT62() elif alt35 == 39: # C.g:1:162: T63 self.mT63() elif alt35 == 40: # C.g:1:166: T64 self.mT64() elif alt35 == 41: # C.g:1:170: T65 self.mT65() elif alt35 == 42: # C.g:1:174: T66 self.mT66() elif alt35 == 43: # C.g:1:178: T67 self.mT67() elif alt35 == 44: # C.g:1:182: T68 self.mT68() elif alt35 == 45: # C.g:1:186: T69 self.mT69() elif alt35 == 46: # C.g:1:190: T70 self.mT70() elif alt35 == 47: # C.g:1:194: T71 self.mT71() elif alt35 == 48: # C.g:1:198: T72 self.mT72() elif alt35 == 49: # C.g:1:202: T73 self.mT73() elif alt35 == 50: # C.g:1:206: T74 self.mT74() elif alt35 == 51: # C.g:1:210: T75 self.mT75() elif alt35 == 52: # C.g:1:214: T76 self.mT76() elif alt35 == 53: # C.g:1:218: T77 self.mT77() elif alt35 == 54: # C.g:1:222: T78 self.mT78() elif alt35 == 55: # C.g:1:226: T79 self.mT79() elif alt35 == 56: # C.g:1:230: T80 self.mT80() elif alt35 == 57: # C.g:1:234: T81 self.mT81() elif alt35 == 58: # C.g:1:238: T82 self.mT82() elif alt35 == 59: # C.g:1:242: T83 self.mT83() elif alt35 == 60: # C.g:1:246: T84 self.mT84() elif alt35 == 61: # C.g:1:250: T85 self.mT85() elif alt35 == 62: # C.g:1:254: T86 self.mT86() elif alt35 == 63: # C.g:1:258: T87 self.mT87() elif alt35 == 64: # C.g:1:262: T88 self.mT88() elif alt35 == 65: # C.g:1:266: T89 self.mT89() elif alt35 == 66: # C.g:1:270: T90 self.mT90() elif alt35 == 67: # C.g:1:274: T91 self.mT91() elif alt35 == 68: # C.g:1:278: T92 self.mT92() elif alt35 == 69: # C.g:1:282: T93 self.mT93() elif alt35 == 70: # C.g:1:286: T94 self.mT94() elif alt35 == 71: # C.g:1:290: T95 self.mT95() elif alt35 == 72: # C.g:1:294: T96 self.mT96() elif alt35 == 73: # C.g:1:298: T97 self.mT97() elif alt35 == 74: # C.g:1:302: T98 self.mT98() elif alt35 == 75: # C.g:1:306: T99 self.mT99() elif alt35 == 76: # C.g:1:310: T100 self.mT100() elif alt35 == 77: # C.g:1:315: T101 self.mT101() elif alt35 == 78: # C.g:1:320: T102 self.mT102() elif alt35 == 79: # C.g:1:325: T103 self.mT103() elif alt35 == 80: # C.g:1:330: T104 self.mT104() elif alt35 == 81: # C.g:1:335: T105 self.mT105() elif alt35 == 82: # C.g:1:340: T106 self.mT106() elif alt35 == 83: # C.g:1:345: T107 self.mT107() elif alt35 == 84: # C.g:1:350: T108 self.mT108() elif alt35 == 85: # C.g:1:355: T109 self.mT109() elif alt35 == 86: # C.g:1:360: T110 self.mT110() elif alt35 == 87: # C.g:1:365: T111 self.mT111() elif alt35 == 88: # C.g:1:370: T112 self.mT112() elif alt35 == 89: # C.g:1:375: T113 self.mT113() elif alt35 == 90: # C.g:1:380: T114 self.mT114() elif alt35 == 91: # C.g:1:385: T115 self.mT115() elif alt35 == 92: # C.g:1:390: T116 self.mT116() elif alt35 == 93: # C.g:1:395: T117 self.mT117() elif alt35 == 94: # C.g:1:400: IDENTIFIER self.mIDENTIFIER() elif alt35 == 95: # C.g:1:411: CHARACTER_LITERAL self.mCHARACTER_LITERAL() elif alt35 == 96: # C.g:1:429: STRING_LITERAL self.mSTRING_LITERAL() elif alt35 == 97: # C.g:1:444: HEX_LITERAL self.mHEX_LITERAL() elif alt35 == 98: # C.g:1:456: DECIMAL_LITERAL self.mDECIMAL_LITERAL() elif alt35 == 99: # C.g:1:472: OCTAL_LITERAL self.mOCTAL_LITERAL() elif alt35 == 100: # C.g:1:486: FLOATING_POINT_LITERAL self.mFLOATING_POINT_LITERAL() elif alt35 == 101: # C.g:1:509: WS self.mWS() elif alt35 == 102: # C.g:1:512: BS self.mBS() elif alt35 == 103: # C.g:1:515: UnicodeVocabulary self.mUnicodeVocabulary() elif alt35 == 104: # C.g:1:533: COMMENT self.mCOMMENT() elif alt35 == 105: # C.g:1:541: LINE_COMMENT self.mLINE_COMMENT() elif alt35 == 106: # C.g:1:554: LINE_COMMAND self.mLINE_COMMAND() # lookup tables for DFA #25 DFA25_eot = DFA.unpack( u"\7\uffff\1\10\2\uffff" ) DFA25_eof = DFA.unpack( u"\12\uffff" ) DFA25_min = DFA.unpack( u"\2\56\2\uffff\1\53\1\uffff\2\60\2\uffff" ) DFA25_max = DFA.unpack( u"\1\71\1\146\2\uffff\1\71\1\uffff\1\71\1\146\2\uffff" ) DFA25_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff\1\4\2\uffff\2\3" ) DFA25_special = DFA.unpack( u"\12\uffff" ) DFA25_transition = [ DFA.unpack(u"\1\2\1\uffff\12\1"), DFA.unpack(u"\1\3\1\uffff\12\1\12\uffff\1\5\1\4\1\5\35\uffff\1\5" u"\1\4\1\5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\6\1\uffff\1\6\2\uffff\12\7"), DFA.unpack(u""), DFA.unpack(u"\12\7"), DFA.unpack(u"\12\7\12\uffff\1\11\1\uffff\1\11\35\uffff\1\11\1\uffff" u"\1\11"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #25 DFA25 = DFA # lookup tables for DFA #35 DFA35_eot = DFA.unpack( u"\2\uffff\1\76\1\uffff\1\101\14\76\3\uffff\10\76\4\uffff\1\151\1" u"\153\1\157\1\163\1\167\1\171\1\174\1\uffff\1\177\1\u0082\1\u0085" u"\1\u0087\1\u008a\1\uffff\5\76\1\uffff\2\73\2\u0095\2\uffff\1\73" u"\2\uffff\1\76\4\uffff\16\76\1\u00ad\5\76\1\u00b4\1\76\3\uffff\1" u"\u00b7\10\76\34\uffff\1\u00c1\2\uffff\1\u00c3\10\uffff\5\76\3\uffff" u"\1\u00c9\1\uffff\1\u0095\3\uffff\23\76\1\uffff\1\u00de\1\76\1\u00e0" u"\3\76\1\uffff\2\76\1\uffff\1\76\1\u00e7\6\76\4\uffff\5\76\1\uffff" u"\1\76\1\u00f5\1\76\1\u00f7\6\76\1\u00fe\4\76\1\u0103\1\u0104\2" u"\76\1\u0107\1\uffff\1\u0108\1\uffff\6\76\1\uffff\10\76\1\u0118" u"\1\76\1\u011a\2\76\1\uffff\1\76\1\uffff\5\76\1\u0123\1\uffff\4" u"\76\2\uffff\1\76\1\u0129\2\uffff\1\u012a\3\76\1\u012e\1\76\1\u0130" u"\7\76\1\u0139\1\uffff\1\u013a\1\uffff\1\u013b\1\76\1\u013d\1\u013e" u"\1\u013f\1\u0140\1\u0141\1\u0142\1\uffff\1\76\1\u0144\1\u0145\2" u"\76\2\uffff\1\76\1\u0149\1\76\1\uffff\1\76\1\uffff\5\76\1\u0151" u"\1\u0152\1\76\3\uffff\1\u0154\6\uffff\1\76\2\uffff\2\76\1\u0158" u"\1\uffff\7\76\2\uffff\1\u0160\1\uffff\1\u0161\1\u0162\1\u0163\1" u"\uffff\1\u0164\1\u0165\1\76\1\u0167\3\76\6\uffff\1\u016b\1\uffff" u"\3\76\1\uffff\21\76\1\u0180\2\76\1\uffff\3\76\1\u0186\1\76\1\uffff" u"\11\76\1\u0191\1\uffff" ) DFA35_eof = DFA.unpack( u"\u0192\uffff" ) DFA35_min = DFA.unpack( u"\1\3\1\uffff\1\171\1\uffff\1\75\1\154\1\150\1\165\1\145\1\124\1" u"\157\1\141\1\146\1\157\1\154\1\145\1\156\3\uffff\1\116\1\120\1" u"\117\1\116\1\117\1\114\1\106\1\101\4\uffff\1\75\1\56\1\53\1\55" u"\1\52\1\75\1\46\1\uffff\1\75\1\74\3\75\1\uffff\1\137\1\150\1\157" u"\1\162\1\42\1\uffff\2\0\2\56\2\uffff\1\0\2\uffff\1\160\4\uffff" u"\1\163\1\164\1\165\1\151\1\141\1\147\1\157\1\164\1\147\1\101\1" u"\151\1\163\1\156\1\141\1\44\1\164\1\156\1\162\1\157\1\146\1\44" u"\1\151\3\uffff\1\44\2\124\1\116\1\101\1\114\1\117\1\111\1\103\34" u"\uffff\1\75\2\uffff\1\75\10\uffff\1\141\1\163\1\151\1\164\1\145" u"\3\uffff\1\56\1\uffff\1\56\3\uffff\3\145\1\155\2\164\1\165\1\145" u"\1\156\1\162\1\157\1\151\1\165\1\124\1\141\1\144\1\145\1\163\1" u"\162\1\uffff\1\44\1\147\1\44\2\141\1\142\1\uffff\1\151\1\157\1" u"\uffff\1\111\1\44\1\123\1\114\1\101\1\102\1\101\1\113\4\uffff\1" u"\163\1\155\1\154\1\157\1\141\1\uffff\1\144\1\44\1\162\1\44\1\143" u"\1\151\1\143\1\157\1\145\1\164\1\44\1\163\1\162\1\111\1\164\2\44" u"\1\151\1\164\1\44\1\uffff\1\44\1\uffff\1\164\1\165\1\154\1\147" u"\1\156\1\117\1\uffff\1\124\1\111\1\124\1\101\1\102\1\120\1\105" u"\1\155\1\44\1\145\1\44\1\153\1\145\1\uffff\1\156\1\uffff\1\150" u"\1\143\1\164\1\146\1\144\1\44\1\uffff\1\164\1\156\1\103\1\151\2" u"\uffff\1\156\1\44\2\uffff\1\44\1\154\1\145\1\156\1\44\1\116\1\44" u"\1\107\1\111\1\114\1\125\1\117\1\111\1\104\1\44\1\uffff\1\44\1" u"\uffff\1\44\1\146\6\44\1\uffff\1\145\2\44\1\154\1\165\2\uffff\1" u"\164\1\44\1\145\1\uffff\1\101\1\uffff\1\116\1\114\1\137\1\116\1" u"\117\2\44\1\137\3\uffff\1\44\6\uffff\1\162\2\uffff\2\145\1\44\1" u"\uffff\1\144\1\114\2\105\1\122\2\124\2\uffff\1\44\1\uffff\3\44" u"\1\uffff\2\44\1\104\1\44\1\105\1\111\1\123\6\uffff\1\44\1\uffff" u"\2\115\1\105\1\uffff\1\117\1\105\1\122\1\126\1\123\1\126\2\105" u"\1\111\1\137\1\122\1\103\1\111\1\126\1\105\1\106\1\111\1\44\1\137" u"\1\103\1\uffff\1\125\1\105\1\116\1\44\1\122\1\uffff\1\105\1\106" u"\1\105\1\122\1\105\1\116\1\103\1\105\1\104\1\44\1\uffff" ) DFA35_max = DFA.unpack( u"\1\ufffe\1\uffff\1\171\1\uffff\1\75\1\170\1\167\1\165\1\145\1\124" u"\2\157\1\156\3\157\1\156\3\uffff\1\116\1\125\1\117\1\116\1\117" u"\1\114\1\106\1\101\4\uffff\1\75\1\71\1\75\1\76\3\75\1\uffff\2\75" u"\1\76\1\75\1\174\1\uffff\1\141\1\150\1\157\1\162\1\47\1\uffff\2" u"\ufffe\1\170\1\146\2\uffff\1\ufffe\2\uffff\1\160\4\uffff\1\163" u"\1\164\1\165\1\151\1\162\1\172\1\157\2\164\1\101\1\154\1\163\1" u"\156\1\141\1\172\1\164\1\156\1\162\1\157\1\146\1\172\1\163\3\uffff" u"\1\172\2\124\1\116\1\101\1\114\1\117\1\111\1\103\34\uffff\1\75" u"\2\uffff\1\75\10\uffff\1\141\1\163\1\151\1\164\1\145\3\uffff\1" u"\146\1\uffff\1\146\3\uffff\3\145\1\155\2\164\1\165\1\145\1\156" u"\1\162\1\157\1\151\1\165\1\124\1\141\1\144\1\145\1\164\1\162\1" u"\uffff\1\172\1\147\1\172\2\141\1\142\1\uffff\1\151\1\157\1\uffff" u"\1\111\1\172\1\123\1\114\1\101\1\102\1\137\1\113\4\uffff\1\163" u"\1\155\1\154\1\157\1\141\1\uffff\1\144\1\172\1\162\1\172\1\143" u"\1\151\1\143\1\157\1\145\1\164\1\172\1\163\1\162\1\111\1\164\2" u"\172\1\151\1\164\1\172\1\uffff\1\172\1\uffff\1\164\1\165\1\154" u"\1\147\1\156\1\117\1\uffff\1\124\1\111\1\124\1\101\1\122\1\120" u"\1\105\1\155\1\172\1\145\1\172\1\153\1\145\1\uffff\1\156\1\uffff" u"\1\150\1\143\1\164\1\146\1\144\1\172\1\uffff\1\164\1\156\1\103" u"\1\151\2\uffff\1\156\1\172\2\uffff\1\172\1\154\1\145\1\156\1\172" u"\1\116\1\172\1\107\1\111\1\114\1\125\1\117\1\111\1\104\1\172\1" u"\uffff\1\172\1\uffff\1\172\1\146\6\172\1\uffff\1\145\2\172\1\154" u"\1\165\2\uffff\1\164\1\172\1\145\1\uffff\1\101\1\uffff\1\116\1" u"\114\1\137\1\116\1\117\2\172\1\137\3\uffff\1\172\6\uffff\1\162" u"\2\uffff\2\145\1\172\1\uffff\1\144\1\114\2\105\1\122\2\124\2\uffff" u"\1\172\1\uffff\3\172\1\uffff\2\172\1\104\1\172\1\105\1\111\1\123" u"\6\uffff\1\172\1\uffff\2\115\1\105\1\uffff\1\117\1\105\1\122\1" u"\126\1\123\1\126\2\105\1\111\1\137\1\122\1\103\1\111\1\126\1\105" u"\1\106\1\111\1\172\1\137\1\103\1\uffff\1\125\1\105\1\116\1\172" u"\1\122\1\uffff\1\105\1\106\1\105\1\122\1\105\1\116\1\103\1\105" u"\1\104\1\172\1\uffff" ) DFA35_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\3\15\uffff\1\23\1\24\1\27\10\uffff\1\46" u"\1\47\1\50\1\51\7\uffff\1\66\5\uffff\1\102\5\uffff\1\136\4\uffff" u"\1\145\1\146\1\uffff\1\147\1\1\1\uffff\1\136\1\3\1\107\1\4\26\uffff" u"\1\23\1\24\1\27\11\uffff\1\46\1\47\1\50\1\51\1\70\1\52\1\53\1\63" u"\1\144\1\73\1\60\1\54\1\74\1\64\1\61\1\55\1\150\1\151\1\71\1\56" u"\1\72\1\57\1\77\1\104\1\65\1\66\1\110\1\67\1\uffff\1\113\1\111" u"\1\uffff\1\114\1\112\1\100\1\106\1\103\1\101\1\105\1\102\5\uffff" u"\1\140\1\137\1\141\1\uffff\1\142\1\uffff\1\145\1\146\1\152\23\uffff" u"\1\124\6\uffff\1\130\2\uffff\1\33\10\uffff\1\75\1\115\1\76\1\116" u"\5\uffff\1\143\24\uffff\1\15\1\uffff\1\131\6\uffff\1\34\15\uffff" u"\1\125\1\uffff\1\30\6\uffff\1\7\4\uffff\1\12\1\122\2\uffff\1\13" u"\1\16\17\uffff\1\120\1\uffff\1\132\10\uffff\1\14\5\uffff\1\31\1" u"\17\3\uffff\1\26\1\uffff\1\36\10\uffff\1\121\1\127\1\134\1\uffff" u"\1\5\1\126\1\6\1\25\1\62\1\21\1\uffff\1\135\1\11\3\uffff\1\20\7" u"\uffff\1\42\1\45\1\uffff\1\2\3\uffff\1\123\7\uffff\1\117\1\10\1" u"\32\1\133\1\22\1\35\1\uffff\1\40\3\uffff\1\37\24\uffff\1\43\5\uffff" u"\1\44\12\uffff\1\41" ) DFA35_special = DFA.unpack( u"\u0192\uffff" ) DFA35_transition = [ DFA.unpack(u"\6\73\2\70\1\73\2\70\22\73\1\70\1\50\1\65\1\72\1\63" u"\1\45\1\46\1\64\1\34\1\35\1\40\1\42\1\3\1\43\1\41\1\44\1\66\11" u"\67\1\23\1\1\1\51\1\4\1\52\1\55\1\73\2\63\1\26\1\63\1\32\1\63\1" u"\31\1\63\1\24\2\63\1\62\2\63\1\25\1\33\2\63\1\11\1\63\1\27\1\30" u"\4\63\1\36\1\71\1\37\1\53\1\56\1\73\1\7\1\61\1\13\1\17\1\5\1\16" u"\1\60\1\63\1\14\2\63\1\15\5\63\1\10\1\6\1\2\1\20\1\12\1\57\3\63" u"\1\21\1\54\1\22\1\47\uff80\73"), DFA.unpack(u""), DFA.unpack(u"\1\75"), DFA.unpack(u""), DFA.unpack(u"\1\100"), DFA.unpack(u"\1\102\1\uffff\1\104\11\uffff\1\103"), DFA.unpack(u"\1\110\1\107\12\uffff\1\106\2\uffff\1\105"), DFA.unpack(u"\1\111"), DFA.unpack(u"\1\112"), DFA.unpack(u"\1\113"), DFA.unpack(u"\1\114"), DFA.unpack(u"\1\115\6\uffff\1\117\6\uffff\1\116"), DFA.unpack(u"\1\120\7\uffff\1\121"), DFA.unpack(u"\1\122"), DFA.unpack(u"\1\124\2\uffff\1\123"), DFA.unpack(u"\1\125\11\uffff\1\126"), DFA.unpack(u"\1\127"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134\4\uffff\1\135"), DFA.unpack(u"\1\136"), DFA.unpack(u"\1\137"), DFA.unpack(u"\1\140"), DFA.unpack(u"\1\141"), DFA.unpack(u"\1\142"), DFA.unpack(u"\1\143"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\150"), DFA.unpack(u"\1\152\1\uffff\12\154"), DFA.unpack(u"\1\156\21\uffff\1\155"), DFA.unpack(u"\1\162\17\uffff\1\160\1\161"), DFA.unpack(u"\1\164\4\uffff\1\165\15\uffff\1\166"), DFA.unpack(u"\1\170"), DFA.unpack(u"\1\173\26\uffff\1\172"), DFA.unpack(u""), DFA.unpack(u"\1\176"), DFA.unpack(u"\1\u0080\1\u0081"), DFA.unpack(u"\1\u0084\1\u0083"), DFA.unpack(u"\1\u0086"), DFA.unpack(u"\1\u0089\76\uffff\1\u0088"), DFA.unpack(u""), DFA.unpack(u"\1\u008c\1\uffff\1\u008d"), DFA.unpack(u"\1\u008e"), DFA.unpack(u"\1\u008f"), DFA.unpack(u"\1\u0090"), DFA.unpack(u"\1\u0091\4\uffff\1\u0092"), DFA.unpack(u""), DFA.unpack(u"\47\u0092\1\uffff\uffd7\u0092"), DFA.unpack(u"\uffff\u0091"), DFA.unpack(u"\1\154\1\uffff\10\u0094\2\154\12\uffff\3\154\21\uffff" u"\1\u0093\13\uffff\3\154\21\uffff\1\u0093"), DFA.unpack(u"\1\154\1\uffff\12\u0096\12\uffff\3\154\35\uffff\3\154"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\uffff\u0099"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u009a"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u009b"), DFA.unpack(u"\1\u009c"), DFA.unpack(u"\1\u009d"), DFA.unpack(u"\1\u009e"), DFA.unpack(u"\1\u009f\20\uffff\1\u00a0"), DFA.unpack(u"\1\u00a2\22\uffff\1\u00a1"), DFA.unpack(u"\1\u00a3"), DFA.unpack(u"\1\u00a4"), DFA.unpack(u"\1\u00a5\14\uffff\1\u00a6"), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\1\u00a9\2\uffff\1\u00a8"), DFA.unpack(u"\1\u00aa"), DFA.unpack(u"\1\u00ab"), DFA.unpack(u"\1\u00ac"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00ae"), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\1\u00b0"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\1\u00b2"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\24\76\1\u00b3\5\76"), DFA.unpack(u"\1\u00b6\11\uffff\1\u00b5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00b8"), DFA.unpack(u"\1\u00b9"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\1\u00bb"), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\1\u00bd"), DFA.unpack(u"\1\u00be"), DFA.unpack(u"\1\u00bf"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c0"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c4"), DFA.unpack(u"\1\u00c5"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u"\1\u00c7"), DFA.unpack(u"\1\u00c8"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\154\1\uffff\10\u0094\2\154\12\uffff\3\154\35\uffff" u"\3\154"), DFA.unpack(u""), DFA.unpack(u"\1\154\1\uffff\12\u0096\12\uffff\3\154\35\uffff\3\154"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ca"), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\1\u00cc"), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u"\1\u00cf"), DFA.unpack(u"\1\u00d0"), DFA.unpack(u"\1\u00d1"), DFA.unpack(u"\1\u00d2"), DFA.unpack(u"\1\u00d3"), DFA.unpack(u"\1\u00d4"), DFA.unpack(u"\1\u00d5"), DFA.unpack(u"\1\u00d6"), DFA.unpack(u"\1\u00d7"), DFA.unpack(u"\1\u00d8"), DFA.unpack(u"\1\u00d9"), DFA.unpack(u"\1\u00da"), DFA.unpack(u"\1\u00dc\1\u00db"), DFA.unpack(u"\1\u00dd"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00df"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00e1"), DFA.unpack(u"\1\u00e2"), DFA.unpack(u"\1\u00e3"), DFA.unpack(u""), DFA.unpack(u"\1\u00e4"), DFA.unpack(u"\1\u00e5"), DFA.unpack(u""), DFA.unpack(u"\1\u00e6"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00e8"), DFA.unpack(u"\1\u00e9"), DFA.unpack(u"\1\u00ea"), DFA.unpack(u"\1\u00eb"), DFA.unpack(u"\1\u00ed\35\uffff\1\u00ec"), DFA.unpack(u"\1\u00ee"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ef"), DFA.unpack(u"\1\u00f0"), DFA.unpack(u"\1\u00f1"), DFA.unpack(u"\1\u00f2"), DFA.unpack(u"\1\u00f3"), DFA.unpack(u""), DFA.unpack(u"\1\u00f4"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00f6"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00f8"), DFA.unpack(u"\1\u00f9"), DFA.unpack(u"\1\u00fa"), DFA.unpack(u"\1\u00fb"), DFA.unpack(u"\1\u00fc"), DFA.unpack(u"\1\u00fd"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00ff"), DFA.unpack(u"\1\u0100"), DFA.unpack(u"\1\u0101"), DFA.unpack(u"\1\u0102"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0105"), DFA.unpack(u"\1\u0106"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0109"), DFA.unpack(u"\1\u010a"), DFA.unpack(u"\1\u010b"), DFA.unpack(u"\1\u010c"), DFA.unpack(u"\1\u010d"), DFA.unpack(u"\1\u010e"), DFA.unpack(u""), DFA.unpack(u"\1\u010f"), DFA.unpack(u"\1\u0110"), DFA.unpack(u"\1\u0111"), DFA.unpack(u"\1\u0112"), DFA.unpack(u"\1\u0114\17\uffff\1\u0113"), DFA.unpack(u"\1\u0115"), DFA.unpack(u"\1\u0116"), DFA.unpack(u"\1\u0117"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0119"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u011b"), DFA.unpack(u"\1\u011c"), DFA.unpack(u""), DFA.unpack(u"\1\u011d"), DFA.unpack(u""), DFA.unpack(u"\1\u011e"), DFA.unpack(u"\1\u011f"), DFA.unpack(u"\1\u0120"), DFA.unpack(u"\1\u0121"), DFA.unpack(u"\1\u0122"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0124"), DFA.unpack(u"\1\u0125"), DFA.unpack(u"\1\u0126"), DFA.unpack(u"\1\u0127"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0128"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u012b"), DFA.unpack(u"\1\u012c"), DFA.unpack(u"\1\u012d"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u012f"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0131"), DFA.unpack(u"\1\u0132"), DFA.unpack(u"\1\u0133"), DFA.unpack(u"\1\u0134"), DFA.unpack(u"\1\u0135"), DFA.unpack(u"\1\u0136"), DFA.unpack(u"\1\u0137"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\u0138\1" u"\uffff\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u013c"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0143"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0146"), DFA.unpack(u"\1\u0147"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0148"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u014a"), DFA.unpack(u""), DFA.unpack(u"\1\u014b"), DFA.unpack(u""), DFA.unpack(u"\1\u014c"), DFA.unpack(u"\1\u014d"), DFA.unpack(u"\1\u014e"), DFA.unpack(u"\1\u014f"), DFA.unpack(u"\1\u0150"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0153"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0155"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0156"), DFA.unpack(u"\1\u0157"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0159"), DFA.unpack(u"\1\u015a"), DFA.unpack(u"\1\u015b"), DFA.unpack(u"\1\u015c"), DFA.unpack(u"\1\u015d"), DFA.unpack(u"\1\u015e"), DFA.unpack(u"\1\u015f"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0166"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0168"), DFA.unpack(u"\1\u0169"), DFA.unpack(u"\1\u016a"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u016c"), DFA.unpack(u"\1\u016d"), DFA.unpack(u"\1\u016e"), DFA.unpack(u""), DFA.unpack(u"\1\u016f"), DFA.unpack(u"\1\u0170"), DFA.unpack(u"\1\u0171"), DFA.unpack(u"\1\u0172"), DFA.unpack(u"\1\u0173"), DFA.unpack(u"\1\u0174"), DFA.unpack(u"\1\u0175"), DFA.unpack(u"\1\u0176"), DFA.unpack(u"\1\u0177"), DFA.unpack(u"\1\u0178"), DFA.unpack(u"\1\u0179"), DFA.unpack(u"\1\u017a"), DFA.unpack(u"\1\u017b"), DFA.unpack(u"\1\u017c"), DFA.unpack(u"\1\u017d"), DFA.unpack(u"\1\u017e"), DFA.unpack(u"\1\u017f"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0181"), DFA.unpack(u"\1\u0182"), DFA.unpack(u""), DFA.unpack(u"\1\u0183"), DFA.unpack(u"\1\u0184"), DFA.unpack(u"\1\u0185"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0187"), DFA.unpack(u""), DFA.unpack(u"\1\u0188"), DFA.unpack(u"\1\u0189"), DFA.unpack(u"\1\u018a"), DFA.unpack(u"\1\u018b"), DFA.unpack(u"\1\u018c"), DFA.unpack(u"\1\u018d"), DFA.unpack(u"\1\u018e"), DFA.unpack(u"\1\u018f"), DFA.unpack(u"\1\u0190"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"") ] # class definition for DFA #35 DFA35 = DFA
{ "repo_name": "bitcrystal/buildtools-BaseTools", "path": "Source/Python/Ecc/CLexer.py", "copies": "12", "size": "99224", "license": "bsd-2-clause", "hash": 4469196425170517500, "line_mean": 18.0574085304, "line_max": 789, "alpha_frac": 0.3868721277, "autogenerated": false, "ratio": 2.8896266526879844, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9276498780387984, "avg_score": null, "num_lines": null }
# $ANTLR 3.0.1 C.g 2010-02-23 09:58:53 from antlr3 import * from antlr3.compat import set, frozenset ## @file # The file defines the Lexer for C source files. # # THIS FILE IS AUTO-GENENERATED. PLEASE DON NOT MODIFY THIS FILE. # This file is generated by running: # java org.antlr.Tool C.g # # Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR> # # This program and the accompanying materials are licensed and made available # under the terms and conditions of the BSD License which accompanies this # distribution. The full text of the license may be found at: # http://opensource.org/licenses/bsd-license.php # # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. # ## # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types T114=114 T115=115 T116=116 T117=117 FloatTypeSuffix=16 LETTER=11 T29=29 T28=28 T27=27 T26=26 T25=25 EOF=-1 STRING_LITERAL=9 FLOATING_POINT_LITERAL=10 T38=38 T37=37 T39=39 T34=34 COMMENT=22 T33=33 T36=36 T35=35 T30=30 T32=32 T31=31 LINE_COMMENT=23 IntegerTypeSuffix=14 CHARACTER_LITERAL=8 T49=49 T48=48 T100=100 T43=43 T42=42 T102=102 T41=41 T101=101 T40=40 T47=47 T46=46 T45=45 T44=44 T109=109 T107=107 T108=108 T105=105 WS=19 T106=106 T103=103 T104=104 T50=50 LINE_COMMAND=24 T59=59 T113=113 T52=52 T112=112 T51=51 T111=111 T54=54 T110=110 EscapeSequence=12 DECIMAL_LITERAL=7 T53=53 T56=56 T55=55 T58=58 T57=57 T75=75 T76=76 T73=73 T74=74 T79=79 T77=77 T78=78 Exponent=15 HexDigit=13 T72=72 T71=71 T70=70 T62=62 T63=63 T64=64 T65=65 T66=66 T67=67 T68=68 T69=69 IDENTIFIER=4 UnicodeVocabulary=21 HEX_LITERAL=5 T61=61 T60=60 T99=99 T97=97 BS=20 T98=98 T95=95 T96=96 OCTAL_LITERAL=6 T94=94 Tokens=118 T93=93 T92=92 T91=91 T90=90 T88=88 T89=89 T84=84 T85=85 T86=86 T87=87 UnicodeEscape=18 T81=81 T80=80 T83=83 OctalEscape=17 T82=82 class CLexer(Lexer): grammarFileName = "C.g" def __init__(self, input=None): Lexer.__init__(self, input) self.dfa25 = self.DFA25( self, 25, eot = self.DFA25_eot, eof = self.DFA25_eof, min = self.DFA25_min, max = self.DFA25_max, accept = self.DFA25_accept, special = self.DFA25_special, transition = self.DFA25_transition ) self.dfa35 = self.DFA35( self, 35, eot = self.DFA35_eot, eof = self.DFA35_eof, min = self.DFA35_min, max = self.DFA35_max, accept = self.DFA35_accept, special = self.DFA35_special, transition = self.DFA35_transition ) # $ANTLR start T25 def mT25(self, ): try: self.type = T25 # C.g:27:5: ( ';' ) # C.g:27:7: ';' self.match(u';') finally: pass # $ANTLR end T25 # $ANTLR start T26 def mT26(self, ): try: self.type = T26 # C.g:28:5: ( 'typedef' ) # C.g:28:7: 'typedef' self.match("typedef") finally: pass # $ANTLR end T26 # $ANTLR start T27 def mT27(self, ): try: self.type = T27 # C.g:29:5: ( ',' ) # C.g:29:7: ',' self.match(u',') finally: pass # $ANTLR end T27 # $ANTLR start T28 def mT28(self, ): try: self.type = T28 # C.g:30:5: ( '=' ) # C.g:30:7: '=' self.match(u'=') finally: pass # $ANTLR end T28 # $ANTLR start T29 def mT29(self, ): try: self.type = T29 # C.g:31:5: ( 'extern' ) # C.g:31:7: 'extern' self.match("extern") finally: pass # $ANTLR end T29 # $ANTLR start T30 def mT30(self, ): try: self.type = T30 # C.g:32:5: ( 'static' ) # C.g:32:7: 'static' self.match("static") finally: pass # $ANTLR end T30 # $ANTLR start T31 def mT31(self, ): try: self.type = T31 # C.g:33:5: ( 'auto' ) # C.g:33:7: 'auto' self.match("auto") finally: pass # $ANTLR end T31 # $ANTLR start T32 def mT32(self, ): try: self.type = T32 # C.g:34:5: ( 'register' ) # C.g:34:7: 'register' self.match("register") finally: pass # $ANTLR end T32 # $ANTLR start T33 def mT33(self, ): try: self.type = T33 # C.g:35:5: ( 'STATIC' ) # C.g:35:7: 'STATIC' self.match("STATIC") finally: pass # $ANTLR end T33 # $ANTLR start T34 def mT34(self, ): try: self.type = T34 # C.g:36:5: ( 'void' ) # C.g:36:7: 'void' self.match("void") finally: pass # $ANTLR end T34 # $ANTLR start T35 def mT35(self, ): try: self.type = T35 # C.g:37:5: ( 'char' ) # C.g:37:7: 'char' self.match("char") finally: pass # $ANTLR end T35 # $ANTLR start T36 def mT36(self, ): try: self.type = T36 # C.g:38:5: ( 'short' ) # C.g:38:7: 'short' self.match("short") finally: pass # $ANTLR end T36 # $ANTLR start T37 def mT37(self, ): try: self.type = T37 # C.g:39:5: ( 'int' ) # C.g:39:7: 'int' self.match("int") finally: pass # $ANTLR end T37 # $ANTLR start T38 def mT38(self, ): try: self.type = T38 # C.g:40:5: ( 'long' ) # C.g:40:7: 'long' self.match("long") finally: pass # $ANTLR end T38 # $ANTLR start T39 def mT39(self, ): try: self.type = T39 # C.g:41:5: ( 'float' ) # C.g:41:7: 'float' self.match("float") finally: pass # $ANTLR end T39 # $ANTLR start T40 def mT40(self, ): try: self.type = T40 # C.g:42:5: ( 'double' ) # C.g:42:7: 'double' self.match("double") finally: pass # $ANTLR end T40 # $ANTLR start T41 def mT41(self, ): try: self.type = T41 # C.g:43:5: ( 'signed' ) # C.g:43:7: 'signed' self.match("signed") finally: pass # $ANTLR end T41 # $ANTLR start T42 def mT42(self, ): try: self.type = T42 # C.g:44:5: ( 'unsigned' ) # C.g:44:7: 'unsigned' self.match("unsigned") finally: pass # $ANTLR end T42 # $ANTLR start T43 def mT43(self, ): try: self.type = T43 # C.g:45:5: ( '{' ) # C.g:45:7: '{' self.match(u'{') finally: pass # $ANTLR end T43 # $ANTLR start T44 def mT44(self, ): try: self.type = T44 # C.g:46:5: ( '}' ) # C.g:46:7: '}' self.match(u'}') finally: pass # $ANTLR end T44 # $ANTLR start T45 def mT45(self, ): try: self.type = T45 # C.g:47:5: ( 'struct' ) # C.g:47:7: 'struct' self.match("struct") finally: pass # $ANTLR end T45 # $ANTLR start T46 def mT46(self, ): try: self.type = T46 # C.g:48:5: ( 'union' ) # C.g:48:7: 'union' self.match("union") finally: pass # $ANTLR end T46 # $ANTLR start T47 def mT47(self, ): try: self.type = T47 # C.g:49:5: ( ':' ) # C.g:49:7: ':' self.match(u':') finally: pass # $ANTLR end T47 # $ANTLR start T48 def mT48(self, ): try: self.type = T48 # C.g:50:5: ( 'enum' ) # C.g:50:7: 'enum' self.match("enum") finally: pass # $ANTLR end T48 # $ANTLR start T49 def mT49(self, ): try: self.type = T49 # C.g:51:5: ( 'const' ) # C.g:51:7: 'const' self.match("const") finally: pass # $ANTLR end T49 # $ANTLR start T50 def mT50(self, ): try: self.type = T50 # C.g:52:5: ( 'volatile' ) # C.g:52:7: 'volatile' self.match("volatile") finally: pass # $ANTLR end T50 # $ANTLR start T51 def mT51(self, ): try: self.type = T51 # C.g:53:5: ( 'IN' ) # C.g:53:7: 'IN' self.match("IN") finally: pass # $ANTLR end T51 # $ANTLR start T52 def mT52(self, ): try: self.type = T52 # C.g:54:5: ( 'OUT' ) # C.g:54:7: 'OUT' self.match("OUT") finally: pass # $ANTLR end T52 # $ANTLR start T53 def mT53(self, ): try: self.type = T53 # C.g:55:5: ( 'OPTIONAL' ) # C.g:55:7: 'OPTIONAL' self.match("OPTIONAL") finally: pass # $ANTLR end T53 # $ANTLR start T54 def mT54(self, ): try: self.type = T54 # C.g:56:5: ( 'CONST' ) # C.g:56:7: 'CONST' self.match("CONST") finally: pass # $ANTLR end T54 # $ANTLR start T55 def mT55(self, ): try: self.type = T55 # C.g:57:5: ( 'UNALIGNED' ) # C.g:57:7: 'UNALIGNED' self.match("UNALIGNED") finally: pass # $ANTLR end T55 # $ANTLR start T56 def mT56(self, ): try: self.type = T56 # C.g:58:5: ( 'VOLATILE' ) # C.g:58:7: 'VOLATILE' self.match("VOLATILE") finally: pass # $ANTLR end T56 # $ANTLR start T57 def mT57(self, ): try: self.type = T57 # C.g:59:5: ( 'GLOBAL_REMOVE_IF_UNREFERENCED' ) # C.g:59:7: 'GLOBAL_REMOVE_IF_UNREFERENCED' self.match("GLOBAL_REMOVE_IF_UNREFERENCED") finally: pass # $ANTLR end T57 # $ANTLR start T58 def mT58(self, ): try: self.type = T58 # C.g:60:5: ( 'EFIAPI' ) # C.g:60:7: 'EFIAPI' self.match("EFIAPI") finally: pass # $ANTLR end T58 # $ANTLR start T59 def mT59(self, ): try: self.type = T59 # C.g:61:5: ( 'EFI_BOOTSERVICE' ) # C.g:61:7: 'EFI_BOOTSERVICE' self.match("EFI_BOOTSERVICE") finally: pass # $ANTLR end T59 # $ANTLR start T60 def mT60(self, ): try: self.type = T60 # C.g:62:5: ( 'EFI_RUNTIMESERVICE' ) # C.g:62:7: 'EFI_RUNTIMESERVICE' self.match("EFI_RUNTIMESERVICE") finally: pass # $ANTLR end T60 # $ANTLR start T61 def mT61(self, ): try: self.type = T61 # C.g:63:5: ( 'PACKED' ) # C.g:63:7: 'PACKED' self.match("PACKED") finally: pass # $ANTLR end T61 # $ANTLR start T62 def mT62(self, ): try: self.type = T62 # C.g:64:5: ( '(' ) # C.g:64:7: '(' self.match(u'(') finally: pass # $ANTLR end T62 # $ANTLR start T63 def mT63(self, ): try: self.type = T63 # C.g:65:5: ( ')' ) # C.g:65:7: ')' self.match(u')') finally: pass # $ANTLR end T63 # $ANTLR start T64 def mT64(self, ): try: self.type = T64 # C.g:66:5: ( '[' ) # C.g:66:7: '[' self.match(u'[') finally: pass # $ANTLR end T64 # $ANTLR start T65 def mT65(self, ): try: self.type = T65 # C.g:67:5: ( ']' ) # C.g:67:7: ']' self.match(u']') finally: pass # $ANTLR end T65 # $ANTLR start T66 def mT66(self, ): try: self.type = T66 # C.g:68:5: ( '*' ) # C.g:68:7: '*' self.match(u'*') finally: pass # $ANTLR end T66 # $ANTLR start T67 def mT67(self, ): try: self.type = T67 # C.g:69:5: ( '...' ) # C.g:69:7: '...' self.match("...") finally: pass # $ANTLR end T67 # $ANTLR start T68 def mT68(self, ): try: self.type = T68 # C.g:70:5: ( '+' ) # C.g:70:7: '+' self.match(u'+') finally: pass # $ANTLR end T68 # $ANTLR start T69 def mT69(self, ): try: self.type = T69 # C.g:71:5: ( '-' ) # C.g:71:7: '-' self.match(u'-') finally: pass # $ANTLR end T69 # $ANTLR start T70 def mT70(self, ): try: self.type = T70 # C.g:72:5: ( '/' ) # C.g:72:7: '/' self.match(u'/') finally: pass # $ANTLR end T70 # $ANTLR start T71 def mT71(self, ): try: self.type = T71 # C.g:73:5: ( '%' ) # C.g:73:7: '%' self.match(u'%') finally: pass # $ANTLR end T71 # $ANTLR start T72 def mT72(self, ): try: self.type = T72 # C.g:74:5: ( '++' ) # C.g:74:7: '++' self.match("++") finally: pass # $ANTLR end T72 # $ANTLR start T73 def mT73(self, ): try: self.type = T73 # C.g:75:5: ( '--' ) # C.g:75:7: '--' self.match("--") finally: pass # $ANTLR end T73 # $ANTLR start T74 def mT74(self, ): try: self.type = T74 # C.g:76:5: ( 'sizeof' ) # C.g:76:7: 'sizeof' self.match("sizeof") finally: pass # $ANTLR end T74 # $ANTLR start T75 def mT75(self, ): try: self.type = T75 # C.g:77:5: ( '.' ) # C.g:77:7: '.' self.match(u'.') finally: pass # $ANTLR end T75 # $ANTLR start T76 def mT76(self, ): try: self.type = T76 # C.g:78:5: ( '->' ) # C.g:78:7: '->' self.match("->") finally: pass # $ANTLR end T76 # $ANTLR start T77 def mT77(self, ): try: self.type = T77 # C.g:79:5: ( '&' ) # C.g:79:7: '&' self.match(u'&') finally: pass # $ANTLR end T77 # $ANTLR start T78 def mT78(self, ): try: self.type = T78 # C.g:80:5: ( '~' ) # C.g:80:7: '~' self.match(u'~') finally: pass # $ANTLR end T78 # $ANTLR start T79 def mT79(self, ): try: self.type = T79 # C.g:81:5: ( '!' ) # C.g:81:7: '!' self.match(u'!') finally: pass # $ANTLR end T79 # $ANTLR start T80 def mT80(self, ): try: self.type = T80 # C.g:82:5: ( '*=' ) # C.g:82:7: '*=' self.match("*=") finally: pass # $ANTLR end T80 # $ANTLR start T81 def mT81(self, ): try: self.type = T81 # C.g:83:5: ( '/=' ) # C.g:83:7: '/=' self.match("/=") finally: pass # $ANTLR end T81 # $ANTLR start T82 def mT82(self, ): try: self.type = T82 # C.g:84:5: ( '%=' ) # C.g:84:7: '%=' self.match("%=") finally: pass # $ANTLR end T82 # $ANTLR start T83 def mT83(self, ): try: self.type = T83 # C.g:85:5: ( '+=' ) # C.g:85:7: '+=' self.match("+=") finally: pass # $ANTLR end T83 # $ANTLR start T84 def mT84(self, ): try: self.type = T84 # C.g:86:5: ( '-=' ) # C.g:86:7: '-=' self.match("-=") finally: pass # $ANTLR end T84 # $ANTLR start T85 def mT85(self, ): try: self.type = T85 # C.g:87:5: ( '<<=' ) # C.g:87:7: '<<=' self.match("<<=") finally: pass # $ANTLR end T85 # $ANTLR start T86 def mT86(self, ): try: self.type = T86 # C.g:88:5: ( '>>=' ) # C.g:88:7: '>>=' self.match(">>=") finally: pass # $ANTLR end T86 # $ANTLR start T87 def mT87(self, ): try: self.type = T87 # C.g:89:5: ( '&=' ) # C.g:89:7: '&=' self.match("&=") finally: pass # $ANTLR end T87 # $ANTLR start T88 def mT88(self, ): try: self.type = T88 # C.g:90:5: ( '^=' ) # C.g:90:7: '^=' self.match("^=") finally: pass # $ANTLR end T88 # $ANTLR start T89 def mT89(self, ): try: self.type = T89 # C.g:91:5: ( '|=' ) # C.g:91:7: '|=' self.match("|=") finally: pass # $ANTLR end T89 # $ANTLR start T90 def mT90(self, ): try: self.type = T90 # C.g:92:5: ( '?' ) # C.g:92:7: '?' self.match(u'?') finally: pass # $ANTLR end T90 # $ANTLR start T91 def mT91(self, ): try: self.type = T91 # C.g:93:5: ( '||' ) # C.g:93:7: '||' self.match("||") finally: pass # $ANTLR end T91 # $ANTLR start T92 def mT92(self, ): try: self.type = T92 # C.g:94:5: ( '&&' ) # C.g:94:7: '&&' self.match("&&") finally: pass # $ANTLR end T92 # $ANTLR start T93 def mT93(self, ): try: self.type = T93 # C.g:95:5: ( '|' ) # C.g:95:7: '|' self.match(u'|') finally: pass # $ANTLR end T93 # $ANTLR start T94 def mT94(self, ): try: self.type = T94 # C.g:96:5: ( '^' ) # C.g:96:7: '^' self.match(u'^') finally: pass # $ANTLR end T94 # $ANTLR start T95 def mT95(self, ): try: self.type = T95 # C.g:97:5: ( '==' ) # C.g:97:7: '==' self.match("==") finally: pass # $ANTLR end T95 # $ANTLR start T96 def mT96(self, ): try: self.type = T96 # C.g:98:5: ( '!=' ) # C.g:98:7: '!=' self.match("!=") finally: pass # $ANTLR end T96 # $ANTLR start T97 def mT97(self, ): try: self.type = T97 # C.g:99:5: ( '<' ) # C.g:99:7: '<' self.match(u'<') finally: pass # $ANTLR end T97 # $ANTLR start T98 def mT98(self, ): try: self.type = T98 # C.g:100:5: ( '>' ) # C.g:100:7: '>' self.match(u'>') finally: pass # $ANTLR end T98 # $ANTLR start T99 def mT99(self, ): try: self.type = T99 # C.g:101:5: ( '<=' ) # C.g:101:7: '<=' self.match("<=") finally: pass # $ANTLR end T99 # $ANTLR start T100 def mT100(self, ): try: self.type = T100 # C.g:102:6: ( '>=' ) # C.g:102:8: '>=' self.match(">=") finally: pass # $ANTLR end T100 # $ANTLR start T101 def mT101(self, ): try: self.type = T101 # C.g:103:6: ( '<<' ) # C.g:103:8: '<<' self.match("<<") finally: pass # $ANTLR end T101 # $ANTLR start T102 def mT102(self, ): try: self.type = T102 # C.g:104:6: ( '>>' ) # C.g:104:8: '>>' self.match(">>") finally: pass # $ANTLR end T102 # $ANTLR start T103 def mT103(self, ): try: self.type = T103 # C.g:105:6: ( '__asm__' ) # C.g:105:8: '__asm__' self.match("__asm__") finally: pass # $ANTLR end T103 # $ANTLR start T104 def mT104(self, ): try: self.type = T104 # C.g:106:6: ( '_asm' ) # C.g:106:8: '_asm' self.match("_asm") finally: pass # $ANTLR end T104 # $ANTLR start T105 def mT105(self, ): try: self.type = T105 # C.g:107:6: ( '__asm' ) # C.g:107:8: '__asm' self.match("__asm") finally: pass # $ANTLR end T105 # $ANTLR start T106 def mT106(self, ): try: self.type = T106 # C.g:108:6: ( 'case' ) # C.g:108:8: 'case' self.match("case") finally: pass # $ANTLR end T106 # $ANTLR start T107 def mT107(self, ): try: self.type = T107 # C.g:109:6: ( 'default' ) # C.g:109:8: 'default' self.match("default") finally: pass # $ANTLR end T107 # $ANTLR start T108 def mT108(self, ): try: self.type = T108 # C.g:110:6: ( 'if' ) # C.g:110:8: 'if' self.match("if") finally: pass # $ANTLR end T108 # $ANTLR start T109 def mT109(self, ): try: self.type = T109 # C.g:111:6: ( 'else' ) # C.g:111:8: 'else' self.match("else") finally: pass # $ANTLR end T109 # $ANTLR start T110 def mT110(self, ): try: self.type = T110 # C.g:112:6: ( 'switch' ) # C.g:112:8: 'switch' self.match("switch") finally: pass # $ANTLR end T110 # $ANTLR start T111 def mT111(self, ): try: self.type = T111 # C.g:113:6: ( 'while' ) # C.g:113:8: 'while' self.match("while") finally: pass # $ANTLR end T111 # $ANTLR start T112 def mT112(self, ): try: self.type = T112 # C.g:114:6: ( 'do' ) # C.g:114:8: 'do' self.match("do") finally: pass # $ANTLR end T112 # $ANTLR start T113 def mT113(self, ): try: self.type = T113 # C.g:115:6: ( 'for' ) # C.g:115:8: 'for' self.match("for") finally: pass # $ANTLR end T113 # $ANTLR start T114 def mT114(self, ): try: self.type = T114 # C.g:116:6: ( 'goto' ) # C.g:116:8: 'goto' self.match("goto") finally: pass # $ANTLR end T114 # $ANTLR start T115 def mT115(self, ): try: self.type = T115 # C.g:117:6: ( 'continue' ) # C.g:117:8: 'continue' self.match("continue") finally: pass # $ANTLR end T115 # $ANTLR start T116 def mT116(self, ): try: self.type = T116 # C.g:118:6: ( 'break' ) # C.g:118:8: 'break' self.match("break") finally: pass # $ANTLR end T116 # $ANTLR start T117 def mT117(self, ): try: self.type = T117 # C.g:119:6: ( 'return' ) # C.g:119:8: 'return' self.match("return") finally: pass # $ANTLR end T117 # $ANTLR start IDENTIFIER def mIDENTIFIER(self, ): try: self.type = IDENTIFIER # C.g:586:2: ( LETTER ( LETTER | '0' .. '9' )* ) # C.g:586:4: LETTER ( LETTER | '0' .. '9' )* self.mLETTER() # C.g:586:11: ( LETTER | '0' .. '9' )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == u'$' or (u'0' <= LA1_0 <= u'9') or (u'A' <= LA1_0 <= u'Z') or LA1_0 == u'_' or (u'a' <= LA1_0 <= u'z')) : alt1 = 1 if alt1 == 1: # C.g: if self.input.LA(1) == u'$' or (u'0' <= self.input.LA(1) <= u'9') or (u'A' <= self.input.LA(1) <= u'Z') or self.input.LA(1) == u'_' or (u'a' <= self.input.LA(1) <= u'z'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 finally: pass # $ANTLR end IDENTIFIER # $ANTLR start LETTER def mLETTER(self, ): try: # C.g:591:2: ( '$' | 'A' .. 'Z' | 'a' .. 'z' | '_' ) # C.g: if self.input.LA(1) == u'$' or (u'A' <= self.input.LA(1) <= u'Z') or self.input.LA(1) == u'_' or (u'a' <= self.input.LA(1) <= u'z'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end LETTER # $ANTLR start CHARACTER_LITERAL def mCHARACTER_LITERAL(self, ): try: self.type = CHARACTER_LITERAL # C.g:598:5: ( ( 'L' )? '\\'' ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) '\\'' ) # C.g:598:9: ( 'L' )? '\\'' ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) '\\'' # C.g:598:9: ( 'L' )? alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == u'L') : alt2 = 1 if alt2 == 1: # C.g:598:10: 'L' self.match(u'L') self.match(u'\'') # C.g:598:21: ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == u'\\') : alt3 = 1 elif ((u'\u0000' <= LA3_0 <= u'&') or (u'(' <= LA3_0 <= u'[') or (u']' <= LA3_0 <= u'\uFFFE')) : alt3 = 2 else: nvae = NoViableAltException("598:21: ( EscapeSequence | ~ ( '\\'' | '\\\\' ) )", 3, 0, self.input) raise nvae if alt3 == 1: # C.g:598:23: EscapeSequence self.mEscapeSequence() elif alt3 == 2: # C.g:598:40: ~ ( '\\'' | '\\\\' ) if (u'\u0000' <= self.input.LA(1) <= u'&') or (u'(' <= self.input.LA(1) <= u'[') or (u']' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(u'\'') finally: pass # $ANTLR end CHARACTER_LITERAL # $ANTLR start STRING_LITERAL def mSTRING_LITERAL(self, ): try: self.type = STRING_LITERAL # C.g:602:5: ( ( 'L' )? '\"' ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* '\"' ) # C.g:602:8: ( 'L' )? '\"' ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* '\"' # C.g:602:8: ( 'L' )? alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == u'L') : alt4 = 1 if alt4 == 1: # C.g:602:9: 'L' self.match(u'L') self.match(u'"') # C.g:602:19: ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* while True: #loop5 alt5 = 3 LA5_0 = self.input.LA(1) if (LA5_0 == u'\\') : alt5 = 1 elif ((u'\u0000' <= LA5_0 <= u'!') or (u'#' <= LA5_0 <= u'[') or (u']' <= LA5_0 <= u'\uFFFE')) : alt5 = 2 if alt5 == 1: # C.g:602:21: EscapeSequence self.mEscapeSequence() elif alt5 == 2: # C.g:602:38: ~ ( '\\\\' | '\"' ) if (u'\u0000' <= self.input.LA(1) <= u'!') or (u'#' <= self.input.LA(1) <= u'[') or (u']' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop5 self.match(u'"') finally: pass # $ANTLR end STRING_LITERAL # $ANTLR start HEX_LITERAL def mHEX_LITERAL(self, ): try: self.type = HEX_LITERAL # C.g:605:13: ( '0' ( 'x' | 'X' ) ( HexDigit )+ ( IntegerTypeSuffix )? ) # C.g:605:15: '0' ( 'x' | 'X' ) ( HexDigit )+ ( IntegerTypeSuffix )? self.match(u'0') if self.input.LA(1) == u'X' or self.input.LA(1) == u'x': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:605:29: ( HexDigit )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if ((u'0' <= LA6_0 <= u'9') or (u'A' <= LA6_0 <= u'F') or (u'a' <= LA6_0 <= u'f')) : alt6 = 1 if alt6 == 1: # C.g:605:29: HexDigit self.mHexDigit() else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 # C.g:605:39: ( IntegerTypeSuffix )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == u'L' or LA7_0 == u'U' or LA7_0 == u'l' or LA7_0 == u'u') : alt7 = 1 if alt7 == 1: # C.g:605:39: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end HEX_LITERAL # $ANTLR start DECIMAL_LITERAL def mDECIMAL_LITERAL(self, ): try: self.type = DECIMAL_LITERAL # C.g:607:17: ( ( '0' | '1' .. '9' ( '0' .. '9' )* ) ( IntegerTypeSuffix )? ) # C.g:607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* ) ( IntegerTypeSuffix )? # C.g:607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == u'0') : alt9 = 1 elif ((u'1' <= LA9_0 <= u'9')) : alt9 = 2 else: nvae = NoViableAltException("607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* )", 9, 0, self.input) raise nvae if alt9 == 1: # C.g:607:20: '0' self.match(u'0') elif alt9 == 2: # C.g:607:26: '1' .. '9' ( '0' .. '9' )* self.matchRange(u'1', u'9') # C.g:607:35: ( '0' .. '9' )* while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if ((u'0' <= LA8_0 <= u'9')) : alt8 = 1 if alt8 == 1: # C.g:607:35: '0' .. '9' self.matchRange(u'0', u'9') else: break #loop8 # C.g:607:46: ( IntegerTypeSuffix )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == u'L' or LA10_0 == u'U' or LA10_0 == u'l' or LA10_0 == u'u') : alt10 = 1 if alt10 == 1: # C.g:607:46: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end DECIMAL_LITERAL # $ANTLR start OCTAL_LITERAL def mOCTAL_LITERAL(self, ): try: self.type = OCTAL_LITERAL # C.g:609:15: ( '0' ( '0' .. '7' )+ ( IntegerTypeSuffix )? ) # C.g:609:17: '0' ( '0' .. '7' )+ ( IntegerTypeSuffix )? self.match(u'0') # C.g:609:21: ( '0' .. '7' )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((u'0' <= LA11_0 <= u'7')) : alt11 = 1 if alt11 == 1: # C.g:609:22: '0' .. '7' self.matchRange(u'0', u'7') else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 # C.g:609:33: ( IntegerTypeSuffix )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == u'L' or LA12_0 == u'U' or LA12_0 == u'l' or LA12_0 == u'u') : alt12 = 1 if alt12 == 1: # C.g:609:33: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end OCTAL_LITERAL # $ANTLR start HexDigit def mHexDigit(self, ): try: # C.g:612:10: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) ) # C.g:612:12: ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) if (u'0' <= self.input.LA(1) <= u'9') or (u'A' <= self.input.LA(1) <= u'F') or (u'a' <= self.input.LA(1) <= u'f'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end HexDigit # $ANTLR start IntegerTypeSuffix def mIntegerTypeSuffix(self, ): try: # C.g:616:2: ( ( 'u' | 'U' ) | ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) ) alt13 = 4 LA13_0 = self.input.LA(1) if (LA13_0 == u'U' or LA13_0 == u'u') : LA13_1 = self.input.LA(2) if (LA13_1 == u'L' or LA13_1 == u'l') : LA13_3 = self.input.LA(3) if (LA13_3 == u'L' or LA13_3 == u'l') : alt13 = 4 else: alt13 = 3 else: alt13 = 1 elif (LA13_0 == u'L' or LA13_0 == u'l') : alt13 = 2 else: nvae = NoViableAltException("614:1: fragment IntegerTypeSuffix : ( ( 'u' | 'U' ) | ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) );", 13, 0, self.input) raise nvae if alt13 == 1: # C.g:616:4: ( 'u' | 'U' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 2: # C.g:617:4: ( 'l' | 'L' ) if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 3: # C.g:618:4: ( 'u' | 'U' ) ( 'l' | 'L' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 4: # C.g:619:4: ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end IntegerTypeSuffix # $ANTLR start FLOATING_POINT_LITERAL def mFLOATING_POINT_LITERAL(self, ): try: self.type = FLOATING_POINT_LITERAL # C.g:623:5: ( ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( Exponent )? ( FloatTypeSuffix )? | '.' ( '0' .. '9' )+ ( Exponent )? ( FloatTypeSuffix )? | ( '0' .. '9' )+ Exponent ( FloatTypeSuffix )? | ( '0' .. '9' )+ ( Exponent )? FloatTypeSuffix ) alt25 = 4 alt25 = self.dfa25.predict(self.input) if alt25 == 1: # C.g:623:9: ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( Exponent )? ( FloatTypeSuffix )? # C.g:623:9: ( '0' .. '9' )+ cnt14 = 0 while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if ((u'0' <= LA14_0 <= u'9')) : alt14 = 1 if alt14 == 1: # C.g:623:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt14 >= 1: break #loop14 eee = EarlyExitException(14, self.input) raise eee cnt14 += 1 self.match(u'.') # C.g:623:25: ( '0' .. '9' )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if ((u'0' <= LA15_0 <= u'9')) : alt15 = 1 if alt15 == 1: # C.g:623:26: '0' .. '9' self.matchRange(u'0', u'9') else: break #loop15 # C.g:623:37: ( Exponent )? alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == u'E' or LA16_0 == u'e') : alt16 = 1 if alt16 == 1: # C.g:623:37: Exponent self.mExponent() # C.g:623:47: ( FloatTypeSuffix )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == u'D' or LA17_0 == u'F' or LA17_0 == u'd' or LA17_0 == u'f') : alt17 = 1 if alt17 == 1: # C.g:623:47: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 2: # C.g:624:9: '.' ( '0' .. '9' )+ ( Exponent )? ( FloatTypeSuffix )? self.match(u'.') # C.g:624:13: ( '0' .. '9' )+ cnt18 = 0 while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if ((u'0' <= LA18_0 <= u'9')) : alt18 = 1 if alt18 == 1: # C.g:624:14: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt18 >= 1: break #loop18 eee = EarlyExitException(18, self.input) raise eee cnt18 += 1 # C.g:624:25: ( Exponent )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == u'E' or LA19_0 == u'e') : alt19 = 1 if alt19 == 1: # C.g:624:25: Exponent self.mExponent() # C.g:624:35: ( FloatTypeSuffix )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == u'D' or LA20_0 == u'F' or LA20_0 == u'd' or LA20_0 == u'f') : alt20 = 1 if alt20 == 1: # C.g:624:35: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 3: # C.g:625:9: ( '0' .. '9' )+ Exponent ( FloatTypeSuffix )? # C.g:625:9: ( '0' .. '9' )+ cnt21 = 0 while True: #loop21 alt21 = 2 LA21_0 = self.input.LA(1) if ((u'0' <= LA21_0 <= u'9')) : alt21 = 1 if alt21 == 1: # C.g:625:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt21 >= 1: break #loop21 eee = EarlyExitException(21, self.input) raise eee cnt21 += 1 self.mExponent() # C.g:625:30: ( FloatTypeSuffix )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == u'D' or LA22_0 == u'F' or LA22_0 == u'd' or LA22_0 == u'f') : alt22 = 1 if alt22 == 1: # C.g:625:30: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 4: # C.g:626:9: ( '0' .. '9' )+ ( Exponent )? FloatTypeSuffix # C.g:626:9: ( '0' .. '9' )+ cnt23 = 0 while True: #loop23 alt23 = 2 LA23_0 = self.input.LA(1) if ((u'0' <= LA23_0 <= u'9')) : alt23 = 1 if alt23 == 1: # C.g:626:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt23 >= 1: break #loop23 eee = EarlyExitException(23, self.input) raise eee cnt23 += 1 # C.g:626:21: ( Exponent )? alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == u'E' or LA24_0 == u'e') : alt24 = 1 if alt24 == 1: # C.g:626:21: Exponent self.mExponent() self.mFloatTypeSuffix() finally: pass # $ANTLR end FLOATING_POINT_LITERAL # $ANTLR start Exponent def mExponent(self, ): try: # C.g:630:10: ( ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ ) # C.g:630:12: ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ if self.input.LA(1) == u'E' or self.input.LA(1) == u'e': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:630:22: ( '+' | '-' )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == u'+' or LA26_0 == u'-') : alt26 = 1 if alt26 == 1: # C.g: if self.input.LA(1) == u'+' or self.input.LA(1) == u'-': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:630:33: ( '0' .. '9' )+ cnt27 = 0 while True: #loop27 alt27 = 2 LA27_0 = self.input.LA(1) if ((u'0' <= LA27_0 <= u'9')) : alt27 = 1 if alt27 == 1: # C.g:630:34: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt27 >= 1: break #loop27 eee = EarlyExitException(27, self.input) raise eee cnt27 += 1 finally: pass # $ANTLR end Exponent # $ANTLR start FloatTypeSuffix def mFloatTypeSuffix(self, ): try: # C.g:633:17: ( ( 'f' | 'F' | 'd' | 'D' ) ) # C.g:633:19: ( 'f' | 'F' | 'd' | 'D' ) if self.input.LA(1) == u'D' or self.input.LA(1) == u'F' or self.input.LA(1) == u'd' or self.input.LA(1) == u'f': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end FloatTypeSuffix # $ANTLR start EscapeSequence def mEscapeSequence(self, ): try: # C.g:637:5: ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape ) alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == u'\\') : LA28_1 = self.input.LA(2) if (LA28_1 == u'"' or LA28_1 == u'\'' or LA28_1 == u'\\' or LA28_1 == u'b' or LA28_1 == u'f' or LA28_1 == u'n' or LA28_1 == u'r' or LA28_1 == u't') : alt28 = 1 elif ((u'0' <= LA28_1 <= u'7')) : alt28 = 2 else: nvae = NoViableAltException("635:1: fragment EscapeSequence : ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape );", 28, 1, self.input) raise nvae else: nvae = NoViableAltException("635:1: fragment EscapeSequence : ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape );", 28, 0, self.input) raise nvae if alt28 == 1: # C.g:637:8: '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) self.match(u'\\') if self.input.LA(1) == u'"' or self.input.LA(1) == u'\'' or self.input.LA(1) == u'\\' or self.input.LA(1) == u'b' or self.input.LA(1) == u'f' or self.input.LA(1) == u'n' or self.input.LA(1) == u'r' or self.input.LA(1) == u't': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt28 == 2: # C.g:638:9: OctalEscape self.mOctalEscape() finally: pass # $ANTLR end EscapeSequence # $ANTLR start OctalEscape def mOctalEscape(self, ): try: # C.g:643:5: ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ) alt29 = 3 LA29_0 = self.input.LA(1) if (LA29_0 == u'\\') : LA29_1 = self.input.LA(2) if ((u'0' <= LA29_1 <= u'3')) : LA29_2 = self.input.LA(3) if ((u'0' <= LA29_2 <= u'7')) : LA29_4 = self.input.LA(4) if ((u'0' <= LA29_4 <= u'7')) : alt29 = 1 else: alt29 = 2 else: alt29 = 3 elif ((u'4' <= LA29_1 <= u'7')) : LA29_3 = self.input.LA(3) if ((u'0' <= LA29_3 <= u'7')) : alt29 = 2 else: alt29 = 3 else: nvae = NoViableAltException("641:1: fragment OctalEscape : ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) );", 29, 1, self.input) raise nvae else: nvae = NoViableAltException("641:1: fragment OctalEscape : ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) );", 29, 0, self.input) raise nvae if alt29 == 1: # C.g:643:9: '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) self.match(u'\\') # C.g:643:14: ( '0' .. '3' ) # C.g:643:15: '0' .. '3' self.matchRange(u'0', u'3') # C.g:643:25: ( '0' .. '7' ) # C.g:643:26: '0' .. '7' self.matchRange(u'0', u'7') # C.g:643:36: ( '0' .. '7' ) # C.g:643:37: '0' .. '7' self.matchRange(u'0', u'7') elif alt29 == 2: # C.g:644:9: '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) self.match(u'\\') # C.g:644:14: ( '0' .. '7' ) # C.g:644:15: '0' .. '7' self.matchRange(u'0', u'7') # C.g:644:25: ( '0' .. '7' ) # C.g:644:26: '0' .. '7' self.matchRange(u'0', u'7') elif alt29 == 3: # C.g:645:9: '\\\\' ( '0' .. '7' ) self.match(u'\\') # C.g:645:14: ( '0' .. '7' ) # C.g:645:15: '0' .. '7' self.matchRange(u'0', u'7') finally: pass # $ANTLR end OctalEscape # $ANTLR start UnicodeEscape def mUnicodeEscape(self, ): try: # C.g:650:5: ( '\\\\' 'u' HexDigit HexDigit HexDigit HexDigit ) # C.g:650:9: '\\\\' 'u' HexDigit HexDigit HexDigit HexDigit self.match(u'\\') self.match(u'u') self.mHexDigit() self.mHexDigit() self.mHexDigit() self.mHexDigit() finally: pass # $ANTLR end UnicodeEscape # $ANTLR start WS def mWS(self, ): try: self.type = WS # C.g:653:5: ( ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) ) # C.g:653:8: ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) if (u'\t' <= self.input.LA(1) <= u'\n') or (u'\f' <= self.input.LA(1) <= u'\r') or self.input.LA(1) == u' ': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end WS # $ANTLR start BS def mBS(self, ): try: self.type = BS # C.g:657:5: ( ( '\\\\' ) ) # C.g:657:7: ( '\\\\' ) # C.g:657:7: ( '\\\\' ) # C.g:657:8: '\\\\' self.match(u'\\') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end BS # $ANTLR start UnicodeVocabulary def mUnicodeVocabulary(self, ): try: self.type = UnicodeVocabulary # C.g:665:5: ( '\\u0003' .. '\\uFFFE' ) # C.g:665:7: '\\u0003' .. '\\uFFFE' self.matchRange(u'\u0003', u'\uFFFE') finally: pass # $ANTLR end UnicodeVocabulary # $ANTLR start COMMENT def mCOMMENT(self, ): try: self.type = COMMENT # C.g:668:5: ( '/*' ( options {greedy=false; } : . )* '*/' ) # C.g:668:9: '/*' ( options {greedy=false; } : . )* '*/' self.match("/*") # C.g:668:14: ( options {greedy=false; } : . )* while True: #loop30 alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == u'*') : LA30_1 = self.input.LA(2) if (LA30_1 == u'/') : alt30 = 2 elif ((u'\u0000' <= LA30_1 <= u'.') or (u'0' <= LA30_1 <= u'\uFFFE')) : alt30 = 1 elif ((u'\u0000' <= LA30_0 <= u')') or (u'+' <= LA30_0 <= u'\uFFFE')) : alt30 = 1 if alt30 == 1: # C.g:668:42: . self.matchAny() else: break #loop30 self.match("*/") #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end COMMENT # $ANTLR start LINE_COMMENT def mLINE_COMMENT(self, ): try: self.type = LINE_COMMENT # C.g:673:5: ( '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) # C.g:673:7: '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' self.match("//") # C.g:673:12: (~ ( '\\n' | '\\r' ) )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if ((u'\u0000' <= LA31_0 <= u'\t') or (u'\u000B' <= LA31_0 <= u'\f') or (u'\u000E' <= LA31_0 <= u'\uFFFE')) : alt31 = 1 if alt31 == 1: # C.g:673:12: ~ ( '\\n' | '\\r' ) if (u'\u0000' <= self.input.LA(1) <= u'\t') or (u'\u000B' <= self.input.LA(1) <= u'\f') or (u'\u000E' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop31 # C.g:673:26: ( '\\r' )? alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == u'\r') : alt32 = 1 if alt32 == 1: # C.g:673:26: '\\r' self.match(u'\r') self.match(u'\n') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end LINE_COMMENT # $ANTLR start LINE_COMMAND def mLINE_COMMAND(self, ): try: self.type = LINE_COMMAND # C.g:678:5: ( '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) # C.g:678:7: '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' self.match(u'#') # C.g:678:11: (~ ( '\\n' | '\\r' ) )* while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if ((u'\u0000' <= LA33_0 <= u'\t') or (u'\u000B' <= LA33_0 <= u'\f') or (u'\u000E' <= LA33_0 <= u'\uFFFE')) : alt33 = 1 if alt33 == 1: # C.g:678:11: ~ ( '\\n' | '\\r' ) if (u'\u0000' <= self.input.LA(1) <= u'\t') or (u'\u000B' <= self.input.LA(1) <= u'\f') or (u'\u000E' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop33 # C.g:678:25: ( '\\r' )? alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == u'\r') : alt34 = 1 if alt34 == 1: # C.g:678:25: '\\r' self.match(u'\r') self.match(u'\n') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end LINE_COMMAND def mTokens(self): # C.g:1:8: ( T25 | T26 | T27 | T28 | T29 | T30 | T31 | T32 | T33 | T34 | T35 | T36 | T37 | T38 | T39 | T40 | T41 | T42 | T43 | T44 | T45 | T46 | T47 | T48 | T49 | T50 | T51 | T52 | T53 | T54 | T55 | T56 | T57 | T58 | T59 | T60 | T61 | T62 | T63 | T64 | T65 | T66 | T67 | T68 | T69 | T70 | T71 | T72 | T73 | T74 | T75 | T76 | T77 | T78 | T79 | T80 | T81 | T82 | T83 | T84 | T85 | T86 | T87 | T88 | T89 | T90 | T91 | T92 | T93 | T94 | T95 | T96 | T97 | T98 | T99 | T100 | T101 | T102 | T103 | T104 | T105 | T106 | T107 | T108 | T109 | T110 | T111 | T112 | T113 | T114 | T115 | T116 | T117 | IDENTIFIER | CHARACTER_LITERAL | STRING_LITERAL | HEX_LITERAL | DECIMAL_LITERAL | OCTAL_LITERAL | FLOATING_POINT_LITERAL | WS | BS | UnicodeVocabulary | COMMENT | LINE_COMMENT | LINE_COMMAND ) alt35 = 106 alt35 = self.dfa35.predict(self.input) if alt35 == 1: # C.g:1:10: T25 self.mT25() elif alt35 == 2: # C.g:1:14: T26 self.mT26() elif alt35 == 3: # C.g:1:18: T27 self.mT27() elif alt35 == 4: # C.g:1:22: T28 self.mT28() elif alt35 == 5: # C.g:1:26: T29 self.mT29() elif alt35 == 6: # C.g:1:30: T30 self.mT30() elif alt35 == 7: # C.g:1:34: T31 self.mT31() elif alt35 == 8: # C.g:1:38: T32 self.mT32() elif alt35 == 9: # C.g:1:42: T33 self.mT33() elif alt35 == 10: # C.g:1:46: T34 self.mT34() elif alt35 == 11: # C.g:1:50: T35 self.mT35() elif alt35 == 12: # C.g:1:54: T36 self.mT36() elif alt35 == 13: # C.g:1:58: T37 self.mT37() elif alt35 == 14: # C.g:1:62: T38 self.mT38() elif alt35 == 15: # C.g:1:66: T39 self.mT39() elif alt35 == 16: # C.g:1:70: T40 self.mT40() elif alt35 == 17: # C.g:1:74: T41 self.mT41() elif alt35 == 18: # C.g:1:78: T42 self.mT42() elif alt35 == 19: # C.g:1:82: T43 self.mT43() elif alt35 == 20: # C.g:1:86: T44 self.mT44() elif alt35 == 21: # C.g:1:90: T45 self.mT45() elif alt35 == 22: # C.g:1:94: T46 self.mT46() elif alt35 == 23: # C.g:1:98: T47 self.mT47() elif alt35 == 24: # C.g:1:102: T48 self.mT48() elif alt35 == 25: # C.g:1:106: T49 self.mT49() elif alt35 == 26: # C.g:1:110: T50 self.mT50() elif alt35 == 27: # C.g:1:114: T51 self.mT51() elif alt35 == 28: # C.g:1:118: T52 self.mT52() elif alt35 == 29: # C.g:1:122: T53 self.mT53() elif alt35 == 30: # C.g:1:126: T54 self.mT54() elif alt35 == 31: # C.g:1:130: T55 self.mT55() elif alt35 == 32: # C.g:1:134: T56 self.mT56() elif alt35 == 33: # C.g:1:138: T57 self.mT57() elif alt35 == 34: # C.g:1:142: T58 self.mT58() elif alt35 == 35: # C.g:1:146: T59 self.mT59() elif alt35 == 36: # C.g:1:150: T60 self.mT60() elif alt35 == 37: # C.g:1:154: T61 self.mT61() elif alt35 == 38: # C.g:1:158: T62 self.mT62() elif alt35 == 39: # C.g:1:162: T63 self.mT63() elif alt35 == 40: # C.g:1:166: T64 self.mT64() elif alt35 == 41: # C.g:1:170: T65 self.mT65() elif alt35 == 42: # C.g:1:174: T66 self.mT66() elif alt35 == 43: # C.g:1:178: T67 self.mT67() elif alt35 == 44: # C.g:1:182: T68 self.mT68() elif alt35 == 45: # C.g:1:186: T69 self.mT69() elif alt35 == 46: # C.g:1:190: T70 self.mT70() elif alt35 == 47: # C.g:1:194: T71 self.mT71() elif alt35 == 48: # C.g:1:198: T72 self.mT72() elif alt35 == 49: # C.g:1:202: T73 self.mT73() elif alt35 == 50: # C.g:1:206: T74 self.mT74() elif alt35 == 51: # C.g:1:210: T75 self.mT75() elif alt35 == 52: # C.g:1:214: T76 self.mT76() elif alt35 == 53: # C.g:1:218: T77 self.mT77() elif alt35 == 54: # C.g:1:222: T78 self.mT78() elif alt35 == 55: # C.g:1:226: T79 self.mT79() elif alt35 == 56: # C.g:1:230: T80 self.mT80() elif alt35 == 57: # C.g:1:234: T81 self.mT81() elif alt35 == 58: # C.g:1:238: T82 self.mT82() elif alt35 == 59: # C.g:1:242: T83 self.mT83() elif alt35 == 60: # C.g:1:246: T84 self.mT84() elif alt35 == 61: # C.g:1:250: T85 self.mT85() elif alt35 == 62: # C.g:1:254: T86 self.mT86() elif alt35 == 63: # C.g:1:258: T87 self.mT87() elif alt35 == 64: # C.g:1:262: T88 self.mT88() elif alt35 == 65: # C.g:1:266: T89 self.mT89() elif alt35 == 66: # C.g:1:270: T90 self.mT90() elif alt35 == 67: # C.g:1:274: T91 self.mT91() elif alt35 == 68: # C.g:1:278: T92 self.mT92() elif alt35 == 69: # C.g:1:282: T93 self.mT93() elif alt35 == 70: # C.g:1:286: T94 self.mT94() elif alt35 == 71: # C.g:1:290: T95 self.mT95() elif alt35 == 72: # C.g:1:294: T96 self.mT96() elif alt35 == 73: # C.g:1:298: T97 self.mT97() elif alt35 == 74: # C.g:1:302: T98 self.mT98() elif alt35 == 75: # C.g:1:306: T99 self.mT99() elif alt35 == 76: # C.g:1:310: T100 self.mT100() elif alt35 == 77: # C.g:1:315: T101 self.mT101() elif alt35 == 78: # C.g:1:320: T102 self.mT102() elif alt35 == 79: # C.g:1:325: T103 self.mT103() elif alt35 == 80: # C.g:1:330: T104 self.mT104() elif alt35 == 81: # C.g:1:335: T105 self.mT105() elif alt35 == 82: # C.g:1:340: T106 self.mT106() elif alt35 == 83: # C.g:1:345: T107 self.mT107() elif alt35 == 84: # C.g:1:350: T108 self.mT108() elif alt35 == 85: # C.g:1:355: T109 self.mT109() elif alt35 == 86: # C.g:1:360: T110 self.mT110() elif alt35 == 87: # C.g:1:365: T111 self.mT111() elif alt35 == 88: # C.g:1:370: T112 self.mT112() elif alt35 == 89: # C.g:1:375: T113 self.mT113() elif alt35 == 90: # C.g:1:380: T114 self.mT114() elif alt35 == 91: # C.g:1:385: T115 self.mT115() elif alt35 == 92: # C.g:1:390: T116 self.mT116() elif alt35 == 93: # C.g:1:395: T117 self.mT117() elif alt35 == 94: # C.g:1:400: IDENTIFIER self.mIDENTIFIER() elif alt35 == 95: # C.g:1:411: CHARACTER_LITERAL self.mCHARACTER_LITERAL() elif alt35 == 96: # C.g:1:429: STRING_LITERAL self.mSTRING_LITERAL() elif alt35 == 97: # C.g:1:444: HEX_LITERAL self.mHEX_LITERAL() elif alt35 == 98: # C.g:1:456: DECIMAL_LITERAL self.mDECIMAL_LITERAL() elif alt35 == 99: # C.g:1:472: OCTAL_LITERAL self.mOCTAL_LITERAL() elif alt35 == 100: # C.g:1:486: FLOATING_POINT_LITERAL self.mFLOATING_POINT_LITERAL() elif alt35 == 101: # C.g:1:509: WS self.mWS() elif alt35 == 102: # C.g:1:512: BS self.mBS() elif alt35 == 103: # C.g:1:515: UnicodeVocabulary self.mUnicodeVocabulary() elif alt35 == 104: # C.g:1:533: COMMENT self.mCOMMENT() elif alt35 == 105: # C.g:1:541: LINE_COMMENT self.mLINE_COMMENT() elif alt35 == 106: # C.g:1:554: LINE_COMMAND self.mLINE_COMMAND() # lookup tables for DFA #25 DFA25_eot = DFA.unpack( u"\7\uffff\1\10\2\uffff" ) DFA25_eof = DFA.unpack( u"\12\uffff" ) DFA25_min = DFA.unpack( u"\2\56\2\uffff\1\53\1\uffff\2\60\2\uffff" ) DFA25_max = DFA.unpack( u"\1\71\1\146\2\uffff\1\71\1\uffff\1\71\1\146\2\uffff" ) DFA25_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff\1\4\2\uffff\2\3" ) DFA25_special = DFA.unpack( u"\12\uffff" ) DFA25_transition = [ DFA.unpack(u"\1\2\1\uffff\12\1"), DFA.unpack(u"\1\3\1\uffff\12\1\12\uffff\1\5\1\4\1\5\35\uffff\1\5" u"\1\4\1\5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\6\1\uffff\1\6\2\uffff\12\7"), DFA.unpack(u""), DFA.unpack(u"\12\7"), DFA.unpack(u"\12\7\12\uffff\1\11\1\uffff\1\11\35\uffff\1\11\1\uffff" u"\1\11"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #25 DFA25 = DFA # lookup tables for DFA #35 DFA35_eot = DFA.unpack( u"\2\uffff\1\76\1\uffff\1\101\14\76\3\uffff\10\76\4\uffff\1\151\1" u"\153\1\157\1\163\1\167\1\171\1\174\1\uffff\1\177\1\u0082\1\u0085" u"\1\u0087\1\u008a\1\uffff\5\76\1\uffff\2\73\2\u0095\2\uffff\1\73" u"\2\uffff\1\76\4\uffff\16\76\1\u00ad\5\76\1\u00b4\1\76\3\uffff\1" u"\u00b7\10\76\34\uffff\1\u00c1\2\uffff\1\u00c3\10\uffff\5\76\3\uffff" u"\1\u00c9\1\uffff\1\u0095\3\uffff\23\76\1\uffff\1\u00de\1\76\1\u00e0" u"\3\76\1\uffff\2\76\1\uffff\1\76\1\u00e7\6\76\4\uffff\5\76\1\uffff" u"\1\76\1\u00f5\1\76\1\u00f7\6\76\1\u00fe\4\76\1\u0103\1\u0104\2" u"\76\1\u0107\1\uffff\1\u0108\1\uffff\6\76\1\uffff\10\76\1\u0118" u"\1\76\1\u011a\2\76\1\uffff\1\76\1\uffff\5\76\1\u0123\1\uffff\4" u"\76\2\uffff\1\76\1\u0129\2\uffff\1\u012a\3\76\1\u012e\1\76\1\u0130" u"\7\76\1\u0139\1\uffff\1\u013a\1\uffff\1\u013b\1\76\1\u013d\1\u013e" u"\1\u013f\1\u0140\1\u0141\1\u0142\1\uffff\1\76\1\u0144\1\u0145\2" u"\76\2\uffff\1\76\1\u0149\1\76\1\uffff\1\76\1\uffff\5\76\1\u0151" u"\1\u0152\1\76\3\uffff\1\u0154\6\uffff\1\76\2\uffff\2\76\1\u0158" u"\1\uffff\7\76\2\uffff\1\u0160\1\uffff\1\u0161\1\u0162\1\u0163\1" u"\uffff\1\u0164\1\u0165\1\76\1\u0167\3\76\6\uffff\1\u016b\1\uffff" u"\3\76\1\uffff\21\76\1\u0180\2\76\1\uffff\3\76\1\u0186\1\76\1\uffff" u"\11\76\1\u0191\1\uffff" ) DFA35_eof = DFA.unpack( u"\u0192\uffff" ) DFA35_min = DFA.unpack( u"\1\3\1\uffff\1\171\1\uffff\1\75\1\154\1\150\1\165\1\145\1\124\1" u"\157\1\141\1\146\1\157\1\154\1\145\1\156\3\uffff\1\116\1\120\1" u"\117\1\116\1\117\1\114\1\106\1\101\4\uffff\1\75\1\56\1\53\1\55" u"\1\52\1\75\1\46\1\uffff\1\75\1\74\3\75\1\uffff\1\137\1\150\1\157" u"\1\162\1\42\1\uffff\2\0\2\56\2\uffff\1\0\2\uffff\1\160\4\uffff" u"\1\163\1\164\1\165\1\151\1\141\1\147\1\157\1\164\1\147\1\101\1" u"\151\1\163\1\156\1\141\1\44\1\164\1\156\1\162\1\157\1\146\1\44" u"\1\151\3\uffff\1\44\2\124\1\116\1\101\1\114\1\117\1\111\1\103\34" u"\uffff\1\75\2\uffff\1\75\10\uffff\1\141\1\163\1\151\1\164\1\145" u"\3\uffff\1\56\1\uffff\1\56\3\uffff\3\145\1\155\2\164\1\165\1\145" u"\1\156\1\162\1\157\1\151\1\165\1\124\1\141\1\144\1\145\1\163\1" u"\162\1\uffff\1\44\1\147\1\44\2\141\1\142\1\uffff\1\151\1\157\1" u"\uffff\1\111\1\44\1\123\1\114\1\101\1\102\1\101\1\113\4\uffff\1" u"\163\1\155\1\154\1\157\1\141\1\uffff\1\144\1\44\1\162\1\44\1\143" u"\1\151\1\143\1\157\1\145\1\164\1\44\1\163\1\162\1\111\1\164\2\44" u"\1\151\1\164\1\44\1\uffff\1\44\1\uffff\1\164\1\165\1\154\1\147" u"\1\156\1\117\1\uffff\1\124\1\111\1\124\1\101\1\102\1\120\1\105" u"\1\155\1\44\1\145\1\44\1\153\1\145\1\uffff\1\156\1\uffff\1\150" u"\1\143\1\164\1\146\1\144\1\44\1\uffff\1\164\1\156\1\103\1\151\2" u"\uffff\1\156\1\44\2\uffff\1\44\1\154\1\145\1\156\1\44\1\116\1\44" u"\1\107\1\111\1\114\1\125\1\117\1\111\1\104\1\44\1\uffff\1\44\1" u"\uffff\1\44\1\146\6\44\1\uffff\1\145\2\44\1\154\1\165\2\uffff\1" u"\164\1\44\1\145\1\uffff\1\101\1\uffff\1\116\1\114\1\137\1\116\1" u"\117\2\44\1\137\3\uffff\1\44\6\uffff\1\162\2\uffff\2\145\1\44\1" u"\uffff\1\144\1\114\2\105\1\122\2\124\2\uffff\1\44\1\uffff\3\44" u"\1\uffff\2\44\1\104\1\44\1\105\1\111\1\123\6\uffff\1\44\1\uffff" u"\2\115\1\105\1\uffff\1\117\1\105\1\122\1\126\1\123\1\126\2\105" u"\1\111\1\137\1\122\1\103\1\111\1\126\1\105\1\106\1\111\1\44\1\137" u"\1\103\1\uffff\1\125\1\105\1\116\1\44\1\122\1\uffff\1\105\1\106" u"\1\105\1\122\1\105\1\116\1\103\1\105\1\104\1\44\1\uffff" ) DFA35_max = DFA.unpack( u"\1\ufffe\1\uffff\1\171\1\uffff\1\75\1\170\1\167\1\165\1\145\1\124" u"\2\157\1\156\3\157\1\156\3\uffff\1\116\1\125\1\117\1\116\1\117" u"\1\114\1\106\1\101\4\uffff\1\75\1\71\1\75\1\76\3\75\1\uffff\2\75" u"\1\76\1\75\1\174\1\uffff\1\141\1\150\1\157\1\162\1\47\1\uffff\2" u"\ufffe\1\170\1\146\2\uffff\1\ufffe\2\uffff\1\160\4\uffff\1\163" u"\1\164\1\165\1\151\1\162\1\172\1\157\2\164\1\101\1\154\1\163\1" u"\156\1\141\1\172\1\164\1\156\1\162\1\157\1\146\1\172\1\163\3\uffff" u"\1\172\2\124\1\116\1\101\1\114\1\117\1\111\1\103\34\uffff\1\75" u"\2\uffff\1\75\10\uffff\1\141\1\163\1\151\1\164\1\145\3\uffff\1" u"\146\1\uffff\1\146\3\uffff\3\145\1\155\2\164\1\165\1\145\1\156" u"\1\162\1\157\1\151\1\165\1\124\1\141\1\144\1\145\1\164\1\162\1" u"\uffff\1\172\1\147\1\172\2\141\1\142\1\uffff\1\151\1\157\1\uffff" u"\1\111\1\172\1\123\1\114\1\101\1\102\1\137\1\113\4\uffff\1\163" u"\1\155\1\154\1\157\1\141\1\uffff\1\144\1\172\1\162\1\172\1\143" u"\1\151\1\143\1\157\1\145\1\164\1\172\1\163\1\162\1\111\1\164\2" u"\172\1\151\1\164\1\172\1\uffff\1\172\1\uffff\1\164\1\165\1\154" u"\1\147\1\156\1\117\1\uffff\1\124\1\111\1\124\1\101\1\122\1\120" u"\1\105\1\155\1\172\1\145\1\172\1\153\1\145\1\uffff\1\156\1\uffff" u"\1\150\1\143\1\164\1\146\1\144\1\172\1\uffff\1\164\1\156\1\103" u"\1\151\2\uffff\1\156\1\172\2\uffff\1\172\1\154\1\145\1\156\1\172" u"\1\116\1\172\1\107\1\111\1\114\1\125\1\117\1\111\1\104\1\172\1" u"\uffff\1\172\1\uffff\1\172\1\146\6\172\1\uffff\1\145\2\172\1\154" u"\1\165\2\uffff\1\164\1\172\1\145\1\uffff\1\101\1\uffff\1\116\1" u"\114\1\137\1\116\1\117\2\172\1\137\3\uffff\1\172\6\uffff\1\162" u"\2\uffff\2\145\1\172\1\uffff\1\144\1\114\2\105\1\122\2\124\2\uffff" u"\1\172\1\uffff\3\172\1\uffff\2\172\1\104\1\172\1\105\1\111\1\123" u"\6\uffff\1\172\1\uffff\2\115\1\105\1\uffff\1\117\1\105\1\122\1" u"\126\1\123\1\126\2\105\1\111\1\137\1\122\1\103\1\111\1\126\1\105" u"\1\106\1\111\1\172\1\137\1\103\1\uffff\1\125\1\105\1\116\1\172" u"\1\122\1\uffff\1\105\1\106\1\105\1\122\1\105\1\116\1\103\1\105" u"\1\104\1\172\1\uffff" ) DFA35_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\3\15\uffff\1\23\1\24\1\27\10\uffff\1\46" u"\1\47\1\50\1\51\7\uffff\1\66\5\uffff\1\102\5\uffff\1\136\4\uffff" u"\1\145\1\146\1\uffff\1\147\1\1\1\uffff\1\136\1\3\1\107\1\4\26\uffff" u"\1\23\1\24\1\27\11\uffff\1\46\1\47\1\50\1\51\1\70\1\52\1\53\1\63" u"\1\144\1\73\1\60\1\54\1\74\1\64\1\61\1\55\1\150\1\151\1\71\1\56" u"\1\72\1\57\1\77\1\104\1\65\1\66\1\110\1\67\1\uffff\1\113\1\111" u"\1\uffff\1\114\1\112\1\100\1\106\1\103\1\101\1\105\1\102\5\uffff" u"\1\140\1\137\1\141\1\uffff\1\142\1\uffff\1\145\1\146\1\152\23\uffff" u"\1\124\6\uffff\1\130\2\uffff\1\33\10\uffff\1\75\1\115\1\76\1\116" u"\5\uffff\1\143\24\uffff\1\15\1\uffff\1\131\6\uffff\1\34\15\uffff" u"\1\125\1\uffff\1\30\6\uffff\1\7\4\uffff\1\12\1\122\2\uffff\1\13" u"\1\16\17\uffff\1\120\1\uffff\1\132\10\uffff\1\14\5\uffff\1\31\1" u"\17\3\uffff\1\26\1\uffff\1\36\10\uffff\1\121\1\127\1\134\1\uffff" u"\1\5\1\126\1\6\1\25\1\62\1\21\1\uffff\1\135\1\11\3\uffff\1\20\7" u"\uffff\1\42\1\45\1\uffff\1\2\3\uffff\1\123\7\uffff\1\117\1\10\1" u"\32\1\133\1\22\1\35\1\uffff\1\40\3\uffff\1\37\24\uffff\1\43\5\uffff" u"\1\44\12\uffff\1\41" ) DFA35_special = DFA.unpack( u"\u0192\uffff" ) DFA35_transition = [ DFA.unpack(u"\6\73\2\70\1\73\2\70\22\73\1\70\1\50\1\65\1\72\1\63" u"\1\45\1\46\1\64\1\34\1\35\1\40\1\42\1\3\1\43\1\41\1\44\1\66\11" u"\67\1\23\1\1\1\51\1\4\1\52\1\55\1\73\2\63\1\26\1\63\1\32\1\63\1" u"\31\1\63\1\24\2\63\1\62\2\63\1\25\1\33\2\63\1\11\1\63\1\27\1\30" u"\4\63\1\36\1\71\1\37\1\53\1\56\1\73\1\7\1\61\1\13\1\17\1\5\1\16" u"\1\60\1\63\1\14\2\63\1\15\5\63\1\10\1\6\1\2\1\20\1\12\1\57\3\63" u"\1\21\1\54\1\22\1\47\uff80\73"), DFA.unpack(u""), DFA.unpack(u"\1\75"), DFA.unpack(u""), DFA.unpack(u"\1\100"), DFA.unpack(u"\1\102\1\uffff\1\104\11\uffff\1\103"), DFA.unpack(u"\1\110\1\107\12\uffff\1\106\2\uffff\1\105"), DFA.unpack(u"\1\111"), DFA.unpack(u"\1\112"), DFA.unpack(u"\1\113"), DFA.unpack(u"\1\114"), DFA.unpack(u"\1\115\6\uffff\1\117\6\uffff\1\116"), DFA.unpack(u"\1\120\7\uffff\1\121"), DFA.unpack(u"\1\122"), DFA.unpack(u"\1\124\2\uffff\1\123"), DFA.unpack(u"\1\125\11\uffff\1\126"), DFA.unpack(u"\1\127"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134\4\uffff\1\135"), DFA.unpack(u"\1\136"), DFA.unpack(u"\1\137"), DFA.unpack(u"\1\140"), DFA.unpack(u"\1\141"), DFA.unpack(u"\1\142"), DFA.unpack(u"\1\143"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\150"), DFA.unpack(u"\1\152\1\uffff\12\154"), DFA.unpack(u"\1\156\21\uffff\1\155"), DFA.unpack(u"\1\162\17\uffff\1\160\1\161"), DFA.unpack(u"\1\164\4\uffff\1\165\15\uffff\1\166"), DFA.unpack(u"\1\170"), DFA.unpack(u"\1\173\26\uffff\1\172"), DFA.unpack(u""), DFA.unpack(u"\1\176"), DFA.unpack(u"\1\u0080\1\u0081"), DFA.unpack(u"\1\u0084\1\u0083"), DFA.unpack(u"\1\u0086"), DFA.unpack(u"\1\u0089\76\uffff\1\u0088"), DFA.unpack(u""), DFA.unpack(u"\1\u008c\1\uffff\1\u008d"), DFA.unpack(u"\1\u008e"), DFA.unpack(u"\1\u008f"), DFA.unpack(u"\1\u0090"), DFA.unpack(u"\1\u0091\4\uffff\1\u0092"), DFA.unpack(u""), DFA.unpack(u"\47\u0092\1\uffff\uffd7\u0092"), DFA.unpack(u"\uffff\u0091"), DFA.unpack(u"\1\154\1\uffff\10\u0094\2\154\12\uffff\3\154\21\uffff" u"\1\u0093\13\uffff\3\154\21\uffff\1\u0093"), DFA.unpack(u"\1\154\1\uffff\12\u0096\12\uffff\3\154\35\uffff\3\154"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\uffff\u0099"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u009a"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u009b"), DFA.unpack(u"\1\u009c"), DFA.unpack(u"\1\u009d"), DFA.unpack(u"\1\u009e"), DFA.unpack(u"\1\u009f\20\uffff\1\u00a0"), DFA.unpack(u"\1\u00a2\22\uffff\1\u00a1"), DFA.unpack(u"\1\u00a3"), DFA.unpack(u"\1\u00a4"), DFA.unpack(u"\1\u00a5\14\uffff\1\u00a6"), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\1\u00a9\2\uffff\1\u00a8"), DFA.unpack(u"\1\u00aa"), DFA.unpack(u"\1\u00ab"), DFA.unpack(u"\1\u00ac"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00ae"), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\1\u00b0"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\1\u00b2"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\24\76\1\u00b3\5\76"), DFA.unpack(u"\1\u00b6\11\uffff\1\u00b5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00b8"), DFA.unpack(u"\1\u00b9"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\1\u00bb"), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\1\u00bd"), DFA.unpack(u"\1\u00be"), DFA.unpack(u"\1\u00bf"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c0"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c4"), DFA.unpack(u"\1\u00c5"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u"\1\u00c7"), DFA.unpack(u"\1\u00c8"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\154\1\uffff\10\u0094\2\154\12\uffff\3\154\35\uffff" u"\3\154"), DFA.unpack(u""), DFA.unpack(u"\1\154\1\uffff\12\u0096\12\uffff\3\154\35\uffff\3\154"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ca"), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\1\u00cc"), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u"\1\u00cf"), DFA.unpack(u"\1\u00d0"), DFA.unpack(u"\1\u00d1"), DFA.unpack(u"\1\u00d2"), DFA.unpack(u"\1\u00d3"), DFA.unpack(u"\1\u00d4"), DFA.unpack(u"\1\u00d5"), DFA.unpack(u"\1\u00d6"), DFA.unpack(u"\1\u00d7"), DFA.unpack(u"\1\u00d8"), DFA.unpack(u"\1\u00d9"), DFA.unpack(u"\1\u00da"), DFA.unpack(u"\1\u00dc\1\u00db"), DFA.unpack(u"\1\u00dd"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00df"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00e1"), DFA.unpack(u"\1\u00e2"), DFA.unpack(u"\1\u00e3"), DFA.unpack(u""), DFA.unpack(u"\1\u00e4"), DFA.unpack(u"\1\u00e5"), DFA.unpack(u""), DFA.unpack(u"\1\u00e6"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00e8"), DFA.unpack(u"\1\u00e9"), DFA.unpack(u"\1\u00ea"), DFA.unpack(u"\1\u00eb"), DFA.unpack(u"\1\u00ed\35\uffff\1\u00ec"), DFA.unpack(u"\1\u00ee"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ef"), DFA.unpack(u"\1\u00f0"), DFA.unpack(u"\1\u00f1"), DFA.unpack(u"\1\u00f2"), DFA.unpack(u"\1\u00f3"), DFA.unpack(u""), DFA.unpack(u"\1\u00f4"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00f6"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00f8"), DFA.unpack(u"\1\u00f9"), DFA.unpack(u"\1\u00fa"), DFA.unpack(u"\1\u00fb"), DFA.unpack(u"\1\u00fc"), DFA.unpack(u"\1\u00fd"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00ff"), DFA.unpack(u"\1\u0100"), DFA.unpack(u"\1\u0101"), DFA.unpack(u"\1\u0102"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0105"), DFA.unpack(u"\1\u0106"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0109"), DFA.unpack(u"\1\u010a"), DFA.unpack(u"\1\u010b"), DFA.unpack(u"\1\u010c"), DFA.unpack(u"\1\u010d"), DFA.unpack(u"\1\u010e"), DFA.unpack(u""), DFA.unpack(u"\1\u010f"), DFA.unpack(u"\1\u0110"), DFA.unpack(u"\1\u0111"), DFA.unpack(u"\1\u0112"), DFA.unpack(u"\1\u0114\17\uffff\1\u0113"), DFA.unpack(u"\1\u0115"), DFA.unpack(u"\1\u0116"), DFA.unpack(u"\1\u0117"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0119"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u011b"), DFA.unpack(u"\1\u011c"), DFA.unpack(u""), DFA.unpack(u"\1\u011d"), DFA.unpack(u""), DFA.unpack(u"\1\u011e"), DFA.unpack(u"\1\u011f"), DFA.unpack(u"\1\u0120"), DFA.unpack(u"\1\u0121"), DFA.unpack(u"\1\u0122"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0124"), DFA.unpack(u"\1\u0125"), DFA.unpack(u"\1\u0126"), DFA.unpack(u"\1\u0127"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0128"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u012b"), DFA.unpack(u"\1\u012c"), DFA.unpack(u"\1\u012d"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u012f"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0131"), DFA.unpack(u"\1\u0132"), DFA.unpack(u"\1\u0133"), DFA.unpack(u"\1\u0134"), DFA.unpack(u"\1\u0135"), DFA.unpack(u"\1\u0136"), DFA.unpack(u"\1\u0137"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\u0138\1" u"\uffff\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u013c"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0143"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0146"), DFA.unpack(u"\1\u0147"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0148"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u014a"), DFA.unpack(u""), DFA.unpack(u"\1\u014b"), DFA.unpack(u""), DFA.unpack(u"\1\u014c"), DFA.unpack(u"\1\u014d"), DFA.unpack(u"\1\u014e"), DFA.unpack(u"\1\u014f"), DFA.unpack(u"\1\u0150"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0153"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0155"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0156"), DFA.unpack(u"\1\u0157"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0159"), DFA.unpack(u"\1\u015a"), DFA.unpack(u"\1\u015b"), DFA.unpack(u"\1\u015c"), DFA.unpack(u"\1\u015d"), DFA.unpack(u"\1\u015e"), DFA.unpack(u"\1\u015f"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0166"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0168"), DFA.unpack(u"\1\u0169"), DFA.unpack(u"\1\u016a"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u016c"), DFA.unpack(u"\1\u016d"), DFA.unpack(u"\1\u016e"), DFA.unpack(u""), DFA.unpack(u"\1\u016f"), DFA.unpack(u"\1\u0170"), DFA.unpack(u"\1\u0171"), DFA.unpack(u"\1\u0172"), DFA.unpack(u"\1\u0173"), DFA.unpack(u"\1\u0174"), DFA.unpack(u"\1\u0175"), DFA.unpack(u"\1\u0176"), DFA.unpack(u"\1\u0177"), DFA.unpack(u"\1\u0178"), DFA.unpack(u"\1\u0179"), DFA.unpack(u"\1\u017a"), DFA.unpack(u"\1\u017b"), DFA.unpack(u"\1\u017c"), DFA.unpack(u"\1\u017d"), DFA.unpack(u"\1\u017e"), DFA.unpack(u"\1\u017f"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0181"), DFA.unpack(u"\1\u0182"), DFA.unpack(u""), DFA.unpack(u"\1\u0183"), DFA.unpack(u"\1\u0184"), DFA.unpack(u"\1\u0185"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0187"), DFA.unpack(u""), DFA.unpack(u"\1\u0188"), DFA.unpack(u"\1\u0189"), DFA.unpack(u"\1\u018a"), DFA.unpack(u"\1\u018b"), DFA.unpack(u"\1\u018c"), DFA.unpack(u"\1\u018d"), DFA.unpack(u"\1\u018e"), DFA.unpack(u"\1\u018f"), DFA.unpack(u"\1\u0190"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"") ] # class definition for DFA #35 DFA35 = DFA
{ "repo_name": "MattDevo/edk2", "path": "BaseTools/Source/Python/Ecc/CLexer.py", "copies": "2", "size": "99175", "license": "bsd-2-clause", "hash": -6816669922006539000, "line_mean": 18.0475035375, "line_max": 789, "alpha_frac": 0.387063272, "autogenerated": false, "ratio": 2.8887044157054644, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4275767687705464, "avg_score": null, "num_lines": null }
# $ANTLR 3.0.1 C.g 2010-02-23 09:58:53 from antlr3 import * from antlr3.compat import set, frozenset ## @file # The file defines the Lexer for C source files. # # THIS FILE IS AUTO-GENERATED. PLEASE DO NOT MODIFY THIS FILE. # This file is generated by running: # java org.antlr.Tool C.g # # Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR> # # This program and the accompanying materials are licensed and made available # under the terms and conditions of the BSD License which accompanies this # distribution. The full text of the license may be found at: # http://opensource.org/licenses/bsd-license.php # # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. # ## # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types T114=114 T115=115 T116=116 T117=117 FloatTypeSuffix=16 LETTER=11 T29=29 T28=28 T27=27 T26=26 T25=25 EOF=-1 STRING_LITERAL=9 FLOATING_POINT_LITERAL=10 T38=38 T37=37 T39=39 T34=34 COMMENT=22 T33=33 T36=36 T35=35 T30=30 T32=32 T31=31 LINE_COMMENT=23 IntegerTypeSuffix=14 CHARACTER_LITERAL=8 T49=49 T48=48 T100=100 T43=43 T42=42 T102=102 T41=41 T101=101 T40=40 T47=47 T46=46 T45=45 T44=44 T109=109 T107=107 T108=108 T105=105 WS=19 T106=106 T103=103 T104=104 T50=50 LINE_COMMAND=24 T59=59 T113=113 T52=52 T112=112 T51=51 T111=111 T54=54 T110=110 EscapeSequence=12 DECIMAL_LITERAL=7 T53=53 T56=56 T55=55 T58=58 T57=57 T75=75 T76=76 T73=73 T74=74 T79=79 T77=77 T78=78 Exponent=15 HexDigit=13 T72=72 T71=71 T70=70 T62=62 T63=63 T64=64 T65=65 T66=66 T67=67 T68=68 T69=69 IDENTIFIER=4 UnicodeVocabulary=21 HEX_LITERAL=5 T61=61 T60=60 T99=99 T97=97 BS=20 T98=98 T95=95 T96=96 OCTAL_LITERAL=6 T94=94 Tokens=118 T93=93 T92=92 T91=91 T90=90 T88=88 T89=89 T84=84 T85=85 T86=86 T87=87 UnicodeEscape=18 T81=81 T80=80 T83=83 OctalEscape=17 T82=82 class CLexer(Lexer): grammarFileName = "C.g" def __init__(self, input=None): Lexer.__init__(self, input) self.dfa25 = self.DFA25( self, 25, eot = self.DFA25_eot, eof = self.DFA25_eof, min = self.DFA25_min, max = self.DFA25_max, accept = self.DFA25_accept, special = self.DFA25_special, transition = self.DFA25_transition ) self.dfa35 = self.DFA35( self, 35, eot = self.DFA35_eot, eof = self.DFA35_eof, min = self.DFA35_min, max = self.DFA35_max, accept = self.DFA35_accept, special = self.DFA35_special, transition = self.DFA35_transition ) # $ANTLR start T25 def mT25(self, ): try: self.type = T25 # C.g:27:5: ( ';' ) # C.g:27:7: ';' self.match(u';') finally: pass # $ANTLR end T25 # $ANTLR start T26 def mT26(self, ): try: self.type = T26 # C.g:28:5: ( 'typedef' ) # C.g:28:7: 'typedef' self.match("typedef") finally: pass # $ANTLR end T26 # $ANTLR start T27 def mT27(self, ): try: self.type = T27 # C.g:29:5: ( ',' ) # C.g:29:7: ',' self.match(u',') finally: pass # $ANTLR end T27 # $ANTLR start T28 def mT28(self, ): try: self.type = T28 # C.g:30:5: ( '=' ) # C.g:30:7: '=' self.match(u'=') finally: pass # $ANTLR end T28 # $ANTLR start T29 def mT29(self, ): try: self.type = T29 # C.g:31:5: ( 'extern' ) # C.g:31:7: 'extern' self.match("extern") finally: pass # $ANTLR end T29 # $ANTLR start T30 def mT30(self, ): try: self.type = T30 # C.g:32:5: ( 'static' ) # C.g:32:7: 'static' self.match("static") finally: pass # $ANTLR end T30 # $ANTLR start T31 def mT31(self, ): try: self.type = T31 # C.g:33:5: ( 'auto' ) # C.g:33:7: 'auto' self.match("auto") finally: pass # $ANTLR end T31 # $ANTLR start T32 def mT32(self, ): try: self.type = T32 # C.g:34:5: ( 'register' ) # C.g:34:7: 'register' self.match("register") finally: pass # $ANTLR end T32 # $ANTLR start T33 def mT33(self, ): try: self.type = T33 # C.g:35:5: ( 'STATIC' ) # C.g:35:7: 'STATIC' self.match("STATIC") finally: pass # $ANTLR end T33 # $ANTLR start T34 def mT34(self, ): try: self.type = T34 # C.g:36:5: ( 'void' ) # C.g:36:7: 'void' self.match("void") finally: pass # $ANTLR end T34 # $ANTLR start T35 def mT35(self, ): try: self.type = T35 # C.g:37:5: ( 'char' ) # C.g:37:7: 'char' self.match("char") finally: pass # $ANTLR end T35 # $ANTLR start T36 def mT36(self, ): try: self.type = T36 # C.g:38:5: ( 'short' ) # C.g:38:7: 'short' self.match("short") finally: pass # $ANTLR end T36 # $ANTLR start T37 def mT37(self, ): try: self.type = T37 # C.g:39:5: ( 'int' ) # C.g:39:7: 'int' self.match("int") finally: pass # $ANTLR end T37 # $ANTLR start T38 def mT38(self, ): try: self.type = T38 # C.g:40:5: ( 'long' ) # C.g:40:7: 'long' self.match("long") finally: pass # $ANTLR end T38 # $ANTLR start T39 def mT39(self, ): try: self.type = T39 # C.g:41:5: ( 'float' ) # C.g:41:7: 'float' self.match("float") finally: pass # $ANTLR end T39 # $ANTLR start T40 def mT40(self, ): try: self.type = T40 # C.g:42:5: ( 'double' ) # C.g:42:7: 'double' self.match("double") finally: pass # $ANTLR end T40 # $ANTLR start T41 def mT41(self, ): try: self.type = T41 # C.g:43:5: ( 'signed' ) # C.g:43:7: 'signed' self.match("signed") finally: pass # $ANTLR end T41 # $ANTLR start T42 def mT42(self, ): try: self.type = T42 # C.g:44:5: ( 'unsigned' ) # C.g:44:7: 'unsigned' self.match("unsigned") finally: pass # $ANTLR end T42 # $ANTLR start T43 def mT43(self, ): try: self.type = T43 # C.g:45:5: ( '{' ) # C.g:45:7: '{' self.match(u'{') finally: pass # $ANTLR end T43 # $ANTLR start T44 def mT44(self, ): try: self.type = T44 # C.g:46:5: ( '}' ) # C.g:46:7: '}' self.match(u'}') finally: pass # $ANTLR end T44 # $ANTLR start T45 def mT45(self, ): try: self.type = T45 # C.g:47:5: ( 'struct' ) # C.g:47:7: 'struct' self.match("struct") finally: pass # $ANTLR end T45 # $ANTLR start T46 def mT46(self, ): try: self.type = T46 # C.g:48:5: ( 'union' ) # C.g:48:7: 'union' self.match("union") finally: pass # $ANTLR end T46 # $ANTLR start T47 def mT47(self, ): try: self.type = T47 # C.g:49:5: ( ':' ) # C.g:49:7: ':' self.match(u':') finally: pass # $ANTLR end T47 # $ANTLR start T48 def mT48(self, ): try: self.type = T48 # C.g:50:5: ( 'enum' ) # C.g:50:7: 'enum' self.match("enum") finally: pass # $ANTLR end T48 # $ANTLR start T49 def mT49(self, ): try: self.type = T49 # C.g:51:5: ( 'const' ) # C.g:51:7: 'const' self.match("const") finally: pass # $ANTLR end T49 # $ANTLR start T50 def mT50(self, ): try: self.type = T50 # C.g:52:5: ( 'volatile' ) # C.g:52:7: 'volatile' self.match("volatile") finally: pass # $ANTLR end T50 # $ANTLR start T51 def mT51(self, ): try: self.type = T51 # C.g:53:5: ( 'IN' ) # C.g:53:7: 'IN' self.match("IN") finally: pass # $ANTLR end T51 # $ANTLR start T52 def mT52(self, ): try: self.type = T52 # C.g:54:5: ( 'OUT' ) # C.g:54:7: 'OUT' self.match("OUT") finally: pass # $ANTLR end T52 # $ANTLR start T53 def mT53(self, ): try: self.type = T53 # C.g:55:5: ( 'OPTIONAL' ) # C.g:55:7: 'OPTIONAL' self.match("OPTIONAL") finally: pass # $ANTLR end T53 # $ANTLR start T54 def mT54(self, ): try: self.type = T54 # C.g:56:5: ( 'CONST' ) # C.g:56:7: 'CONST' self.match("CONST") finally: pass # $ANTLR end T54 # $ANTLR start T55 def mT55(self, ): try: self.type = T55 # C.g:57:5: ( 'UNALIGNED' ) # C.g:57:7: 'UNALIGNED' self.match("UNALIGNED") finally: pass # $ANTLR end T55 # $ANTLR start T56 def mT56(self, ): try: self.type = T56 # C.g:58:5: ( 'VOLATILE' ) # C.g:58:7: 'VOLATILE' self.match("VOLATILE") finally: pass # $ANTLR end T56 # $ANTLR start T57 def mT57(self, ): try: self.type = T57 # C.g:59:5: ( 'GLOBAL_REMOVE_IF_UNREFERENCED' ) # C.g:59:7: 'GLOBAL_REMOVE_IF_UNREFERENCED' self.match("GLOBAL_REMOVE_IF_UNREFERENCED") finally: pass # $ANTLR end T57 # $ANTLR start T58 def mT58(self, ): try: self.type = T58 # C.g:60:5: ( 'EFIAPI' ) # C.g:60:7: 'EFIAPI' self.match("EFIAPI") finally: pass # $ANTLR end T58 # $ANTLR start T59 def mT59(self, ): try: self.type = T59 # C.g:61:5: ( 'EFI_BOOTSERVICE' ) # C.g:61:7: 'EFI_BOOTSERVICE' self.match("EFI_BOOTSERVICE") finally: pass # $ANTLR end T59 # $ANTLR start T60 def mT60(self, ): try: self.type = T60 # C.g:62:5: ( 'EFI_RUNTIMESERVICE' ) # C.g:62:7: 'EFI_RUNTIMESERVICE' self.match("EFI_RUNTIMESERVICE") finally: pass # $ANTLR end T60 # $ANTLR start T61 def mT61(self, ): try: self.type = T61 # C.g:63:5: ( 'PACKED' ) # C.g:63:7: 'PACKED' self.match("PACKED") finally: pass # $ANTLR end T61 # $ANTLR start T62 def mT62(self, ): try: self.type = T62 # C.g:64:5: ( '(' ) # C.g:64:7: '(' self.match(u'(') finally: pass # $ANTLR end T62 # $ANTLR start T63 def mT63(self, ): try: self.type = T63 # C.g:65:5: ( ')' ) # C.g:65:7: ')' self.match(u')') finally: pass # $ANTLR end T63 # $ANTLR start T64 def mT64(self, ): try: self.type = T64 # C.g:66:5: ( '[' ) # C.g:66:7: '[' self.match(u'[') finally: pass # $ANTLR end T64 # $ANTLR start T65 def mT65(self, ): try: self.type = T65 # C.g:67:5: ( ']' ) # C.g:67:7: ']' self.match(u']') finally: pass # $ANTLR end T65 # $ANTLR start T66 def mT66(self, ): try: self.type = T66 # C.g:68:5: ( '*' ) # C.g:68:7: '*' self.match(u'*') finally: pass # $ANTLR end T66 # $ANTLR start T67 def mT67(self, ): try: self.type = T67 # C.g:69:5: ( '...' ) # C.g:69:7: '...' self.match("...") finally: pass # $ANTLR end T67 # $ANTLR start T68 def mT68(self, ): try: self.type = T68 # C.g:70:5: ( '+' ) # C.g:70:7: '+' self.match(u'+') finally: pass # $ANTLR end T68 # $ANTLR start T69 def mT69(self, ): try: self.type = T69 # C.g:71:5: ( '-' ) # C.g:71:7: '-' self.match(u'-') finally: pass # $ANTLR end T69 # $ANTLR start T70 def mT70(self, ): try: self.type = T70 # C.g:72:5: ( '/' ) # C.g:72:7: '/' self.match(u'/') finally: pass # $ANTLR end T70 # $ANTLR start T71 def mT71(self, ): try: self.type = T71 # C.g:73:5: ( '%' ) # C.g:73:7: '%' self.match(u'%') finally: pass # $ANTLR end T71 # $ANTLR start T72 def mT72(self, ): try: self.type = T72 # C.g:74:5: ( '++' ) # C.g:74:7: '++' self.match("++") finally: pass # $ANTLR end T72 # $ANTLR start T73 def mT73(self, ): try: self.type = T73 # C.g:75:5: ( '--' ) # C.g:75:7: '--' self.match("--") finally: pass # $ANTLR end T73 # $ANTLR start T74 def mT74(self, ): try: self.type = T74 # C.g:76:5: ( 'sizeof' ) # C.g:76:7: 'sizeof' self.match("sizeof") finally: pass # $ANTLR end T74 # $ANTLR start T75 def mT75(self, ): try: self.type = T75 # C.g:77:5: ( '.' ) # C.g:77:7: '.' self.match(u'.') finally: pass # $ANTLR end T75 # $ANTLR start T76 def mT76(self, ): try: self.type = T76 # C.g:78:5: ( '->' ) # C.g:78:7: '->' self.match("->") finally: pass # $ANTLR end T76 # $ANTLR start T77 def mT77(self, ): try: self.type = T77 # C.g:79:5: ( '&' ) # C.g:79:7: '&' self.match(u'&') finally: pass # $ANTLR end T77 # $ANTLR start T78 def mT78(self, ): try: self.type = T78 # C.g:80:5: ( '~' ) # C.g:80:7: '~' self.match(u'~') finally: pass # $ANTLR end T78 # $ANTLR start T79 def mT79(self, ): try: self.type = T79 # C.g:81:5: ( '!' ) # C.g:81:7: '!' self.match(u'!') finally: pass # $ANTLR end T79 # $ANTLR start T80 def mT80(self, ): try: self.type = T80 # C.g:82:5: ( '*=' ) # C.g:82:7: '*=' self.match("*=") finally: pass # $ANTLR end T80 # $ANTLR start T81 def mT81(self, ): try: self.type = T81 # C.g:83:5: ( '/=' ) # C.g:83:7: '/=' self.match("/=") finally: pass # $ANTLR end T81 # $ANTLR start T82 def mT82(self, ): try: self.type = T82 # C.g:84:5: ( '%=' ) # C.g:84:7: '%=' self.match("%=") finally: pass # $ANTLR end T82 # $ANTLR start T83 def mT83(self, ): try: self.type = T83 # C.g:85:5: ( '+=' ) # C.g:85:7: '+=' self.match("+=") finally: pass # $ANTLR end T83 # $ANTLR start T84 def mT84(self, ): try: self.type = T84 # C.g:86:5: ( '-=' ) # C.g:86:7: '-=' self.match("-=") finally: pass # $ANTLR end T84 # $ANTLR start T85 def mT85(self, ): try: self.type = T85 # C.g:87:5: ( '<<=' ) # C.g:87:7: '<<=' self.match("<<=") finally: pass # $ANTLR end T85 # $ANTLR start T86 def mT86(self, ): try: self.type = T86 # C.g:88:5: ( '>>=' ) # C.g:88:7: '>>=' self.match(">>=") finally: pass # $ANTLR end T86 # $ANTLR start T87 def mT87(self, ): try: self.type = T87 # C.g:89:5: ( '&=' ) # C.g:89:7: '&=' self.match("&=") finally: pass # $ANTLR end T87 # $ANTLR start T88 def mT88(self, ): try: self.type = T88 # C.g:90:5: ( '^=' ) # C.g:90:7: '^=' self.match("^=") finally: pass # $ANTLR end T88 # $ANTLR start T89 def mT89(self, ): try: self.type = T89 # C.g:91:5: ( '|=' ) # C.g:91:7: '|=' self.match("|=") finally: pass # $ANTLR end T89 # $ANTLR start T90 def mT90(self, ): try: self.type = T90 # C.g:92:5: ( '?' ) # C.g:92:7: '?' self.match(u'?') finally: pass # $ANTLR end T90 # $ANTLR start T91 def mT91(self, ): try: self.type = T91 # C.g:93:5: ( '||' ) # C.g:93:7: '||' self.match("||") finally: pass # $ANTLR end T91 # $ANTLR start T92 def mT92(self, ): try: self.type = T92 # C.g:94:5: ( '&&' ) # C.g:94:7: '&&' self.match("&&") finally: pass # $ANTLR end T92 # $ANTLR start T93 def mT93(self, ): try: self.type = T93 # C.g:95:5: ( '|' ) # C.g:95:7: '|' self.match(u'|') finally: pass # $ANTLR end T93 # $ANTLR start T94 def mT94(self, ): try: self.type = T94 # C.g:96:5: ( '^' ) # C.g:96:7: '^' self.match(u'^') finally: pass # $ANTLR end T94 # $ANTLR start T95 def mT95(self, ): try: self.type = T95 # C.g:97:5: ( '==' ) # C.g:97:7: '==' self.match("==") finally: pass # $ANTLR end T95 # $ANTLR start T96 def mT96(self, ): try: self.type = T96 # C.g:98:5: ( '!=' ) # C.g:98:7: '!=' self.match("!=") finally: pass # $ANTLR end T96 # $ANTLR start T97 def mT97(self, ): try: self.type = T97 # C.g:99:5: ( '<' ) # C.g:99:7: '<' self.match(u'<') finally: pass # $ANTLR end T97 # $ANTLR start T98 def mT98(self, ): try: self.type = T98 # C.g:100:5: ( '>' ) # C.g:100:7: '>' self.match(u'>') finally: pass # $ANTLR end T98 # $ANTLR start T99 def mT99(self, ): try: self.type = T99 # C.g:101:5: ( '<=' ) # C.g:101:7: '<=' self.match("<=") finally: pass # $ANTLR end T99 # $ANTLR start T100 def mT100(self, ): try: self.type = T100 # C.g:102:6: ( '>=' ) # C.g:102:8: '>=' self.match(">=") finally: pass # $ANTLR end T100 # $ANTLR start T101 def mT101(self, ): try: self.type = T101 # C.g:103:6: ( '<<' ) # C.g:103:8: '<<' self.match("<<") finally: pass # $ANTLR end T101 # $ANTLR start T102 def mT102(self, ): try: self.type = T102 # C.g:104:6: ( '>>' ) # C.g:104:8: '>>' self.match(">>") finally: pass # $ANTLR end T102 # $ANTLR start T103 def mT103(self, ): try: self.type = T103 # C.g:105:6: ( '__asm__' ) # C.g:105:8: '__asm__' self.match("__asm__") finally: pass # $ANTLR end T103 # $ANTLR start T104 def mT104(self, ): try: self.type = T104 # C.g:106:6: ( '_asm' ) # C.g:106:8: '_asm' self.match("_asm") finally: pass # $ANTLR end T104 # $ANTLR start T105 def mT105(self, ): try: self.type = T105 # C.g:107:6: ( '__asm' ) # C.g:107:8: '__asm' self.match("__asm") finally: pass # $ANTLR end T105 # $ANTLR start T106 def mT106(self, ): try: self.type = T106 # C.g:108:6: ( 'case' ) # C.g:108:8: 'case' self.match("case") finally: pass # $ANTLR end T106 # $ANTLR start T107 def mT107(self, ): try: self.type = T107 # C.g:109:6: ( 'default' ) # C.g:109:8: 'default' self.match("default") finally: pass # $ANTLR end T107 # $ANTLR start T108 def mT108(self, ): try: self.type = T108 # C.g:110:6: ( 'if' ) # C.g:110:8: 'if' self.match("if") finally: pass # $ANTLR end T108 # $ANTLR start T109 def mT109(self, ): try: self.type = T109 # C.g:111:6: ( 'else' ) # C.g:111:8: 'else' self.match("else") finally: pass # $ANTLR end T109 # $ANTLR start T110 def mT110(self, ): try: self.type = T110 # C.g:112:6: ( 'switch' ) # C.g:112:8: 'switch' self.match("switch") finally: pass # $ANTLR end T110 # $ANTLR start T111 def mT111(self, ): try: self.type = T111 # C.g:113:6: ( 'while' ) # C.g:113:8: 'while' self.match("while") finally: pass # $ANTLR end T111 # $ANTLR start T112 def mT112(self, ): try: self.type = T112 # C.g:114:6: ( 'do' ) # C.g:114:8: 'do' self.match("do") finally: pass # $ANTLR end T112 # $ANTLR start T113 def mT113(self, ): try: self.type = T113 # C.g:115:6: ( 'for' ) # C.g:115:8: 'for' self.match("for") finally: pass # $ANTLR end T113 # $ANTLR start T114 def mT114(self, ): try: self.type = T114 # C.g:116:6: ( 'goto' ) # C.g:116:8: 'goto' self.match("goto") finally: pass # $ANTLR end T114 # $ANTLR start T115 def mT115(self, ): try: self.type = T115 # C.g:117:6: ( 'continue' ) # C.g:117:8: 'continue' self.match("continue") finally: pass # $ANTLR end T115 # $ANTLR start T116 def mT116(self, ): try: self.type = T116 # C.g:118:6: ( 'break' ) # C.g:118:8: 'break' self.match("break") finally: pass # $ANTLR end T116 # $ANTLR start T117 def mT117(self, ): try: self.type = T117 # C.g:119:6: ( 'return' ) # C.g:119:8: 'return' self.match("return") finally: pass # $ANTLR end T117 # $ANTLR start IDENTIFIER def mIDENTIFIER(self, ): try: self.type = IDENTIFIER # C.g:586:2: ( LETTER ( LETTER | '0' .. '9' )* ) # C.g:586:4: LETTER ( LETTER | '0' .. '9' )* self.mLETTER() # C.g:586:11: ( LETTER | '0' .. '9' )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == u'$' or (u'0' <= LA1_0 <= u'9') or (u'A' <= LA1_0 <= u'Z') or LA1_0 == u'_' or (u'a' <= LA1_0 <= u'z')) : alt1 = 1 if alt1 == 1: # C.g: if self.input.LA(1) == u'$' or (u'0' <= self.input.LA(1) <= u'9') or (u'A' <= self.input.LA(1) <= u'Z') or self.input.LA(1) == u'_' or (u'a' <= self.input.LA(1) <= u'z'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 finally: pass # $ANTLR end IDENTIFIER # $ANTLR start LETTER def mLETTER(self, ): try: # C.g:591:2: ( '$' | 'A' .. 'Z' | 'a' .. 'z' | '_' ) # C.g: if self.input.LA(1) == u'$' or (u'A' <= self.input.LA(1) <= u'Z') or self.input.LA(1) == u'_' or (u'a' <= self.input.LA(1) <= u'z'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end LETTER # $ANTLR start CHARACTER_LITERAL def mCHARACTER_LITERAL(self, ): try: self.type = CHARACTER_LITERAL # C.g:598:5: ( ( 'L' )? '\\'' ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) '\\'' ) # C.g:598:9: ( 'L' )? '\\'' ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) '\\'' # C.g:598:9: ( 'L' )? alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == u'L') : alt2 = 1 if alt2 == 1: # C.g:598:10: 'L' self.match(u'L') self.match(u'\'') # C.g:598:21: ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == u'\\') : alt3 = 1 elif ((u'\u0000' <= LA3_0 <= u'&') or (u'(' <= LA3_0 <= u'[') or (u']' <= LA3_0 <= u'\uFFFE')) : alt3 = 2 else: nvae = NoViableAltException("598:21: ( EscapeSequence | ~ ( '\\'' | '\\\\' ) )", 3, 0, self.input) raise nvae if alt3 == 1: # C.g:598:23: EscapeSequence self.mEscapeSequence() elif alt3 == 2: # C.g:598:40: ~ ( '\\'' | '\\\\' ) if (u'\u0000' <= self.input.LA(1) <= u'&') or (u'(' <= self.input.LA(1) <= u'[') or (u']' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(u'\'') finally: pass # $ANTLR end CHARACTER_LITERAL # $ANTLR start STRING_LITERAL def mSTRING_LITERAL(self, ): try: self.type = STRING_LITERAL # C.g:602:5: ( ( 'L' )? '\"' ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* '\"' ) # C.g:602:8: ( 'L' )? '\"' ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* '\"' # C.g:602:8: ( 'L' )? alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == u'L') : alt4 = 1 if alt4 == 1: # C.g:602:9: 'L' self.match(u'L') self.match(u'"') # C.g:602:19: ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* while True: #loop5 alt5 = 3 LA5_0 = self.input.LA(1) if (LA5_0 == u'\\') : alt5 = 1 elif ((u'\u0000' <= LA5_0 <= u'!') or (u'#' <= LA5_0 <= u'[') or (u']' <= LA5_0 <= u'\uFFFE')) : alt5 = 2 if alt5 == 1: # C.g:602:21: EscapeSequence self.mEscapeSequence() elif alt5 == 2: # C.g:602:38: ~ ( '\\\\' | '\"' ) if (u'\u0000' <= self.input.LA(1) <= u'!') or (u'#' <= self.input.LA(1) <= u'[') or (u']' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop5 self.match(u'"') finally: pass # $ANTLR end STRING_LITERAL # $ANTLR start HEX_LITERAL def mHEX_LITERAL(self, ): try: self.type = HEX_LITERAL # C.g:605:13: ( '0' ( 'x' | 'X' ) ( HexDigit )+ ( IntegerTypeSuffix )? ) # C.g:605:15: '0' ( 'x' | 'X' ) ( HexDigit )+ ( IntegerTypeSuffix )? self.match(u'0') if self.input.LA(1) == u'X' or self.input.LA(1) == u'x': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:605:29: ( HexDigit )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if ((u'0' <= LA6_0 <= u'9') or (u'A' <= LA6_0 <= u'F') or (u'a' <= LA6_0 <= u'f')) : alt6 = 1 if alt6 == 1: # C.g:605:29: HexDigit self.mHexDigit() else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 # C.g:605:39: ( IntegerTypeSuffix )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == u'L' or LA7_0 == u'U' or LA7_0 == u'l' or LA7_0 == u'u') : alt7 = 1 if alt7 == 1: # C.g:605:39: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end HEX_LITERAL # $ANTLR start DECIMAL_LITERAL def mDECIMAL_LITERAL(self, ): try: self.type = DECIMAL_LITERAL # C.g:607:17: ( ( '0' | '1' .. '9' ( '0' .. '9' )* ) ( IntegerTypeSuffix )? ) # C.g:607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* ) ( IntegerTypeSuffix )? # C.g:607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == u'0') : alt9 = 1 elif ((u'1' <= LA9_0 <= u'9')) : alt9 = 2 else: nvae = NoViableAltException("607:19: ( '0' | '1' .. '9' ( '0' .. '9' )* )", 9, 0, self.input) raise nvae if alt9 == 1: # C.g:607:20: '0' self.match(u'0') elif alt9 == 2: # C.g:607:26: '1' .. '9' ( '0' .. '9' )* self.matchRange(u'1', u'9') # C.g:607:35: ( '0' .. '9' )* while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if ((u'0' <= LA8_0 <= u'9')) : alt8 = 1 if alt8 == 1: # C.g:607:35: '0' .. '9' self.matchRange(u'0', u'9') else: break #loop8 # C.g:607:46: ( IntegerTypeSuffix )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == u'L' or LA10_0 == u'U' or LA10_0 == u'l' or LA10_0 == u'u') : alt10 = 1 if alt10 == 1: # C.g:607:46: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end DECIMAL_LITERAL # $ANTLR start OCTAL_LITERAL def mOCTAL_LITERAL(self, ): try: self.type = OCTAL_LITERAL # C.g:609:15: ( '0' ( '0' .. '7' )+ ( IntegerTypeSuffix )? ) # C.g:609:17: '0' ( '0' .. '7' )+ ( IntegerTypeSuffix )? self.match(u'0') # C.g:609:21: ( '0' .. '7' )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((u'0' <= LA11_0 <= u'7')) : alt11 = 1 if alt11 == 1: # C.g:609:22: '0' .. '7' self.matchRange(u'0', u'7') else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 # C.g:609:33: ( IntegerTypeSuffix )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == u'L' or LA12_0 == u'U' or LA12_0 == u'l' or LA12_0 == u'u') : alt12 = 1 if alt12 == 1: # C.g:609:33: IntegerTypeSuffix self.mIntegerTypeSuffix() finally: pass # $ANTLR end OCTAL_LITERAL # $ANTLR start HexDigit def mHexDigit(self, ): try: # C.g:612:10: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) ) # C.g:612:12: ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) if (u'0' <= self.input.LA(1) <= u'9') or (u'A' <= self.input.LA(1) <= u'F') or (u'a' <= self.input.LA(1) <= u'f'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end HexDigit # $ANTLR start IntegerTypeSuffix def mIntegerTypeSuffix(self, ): try: # C.g:616:2: ( ( 'u' | 'U' ) | ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) ) alt13 = 4 LA13_0 = self.input.LA(1) if (LA13_0 == u'U' or LA13_0 == u'u') : LA13_1 = self.input.LA(2) if (LA13_1 == u'L' or LA13_1 == u'l') : LA13_3 = self.input.LA(3) if (LA13_3 == u'L' or LA13_3 == u'l') : alt13 = 4 else: alt13 = 3 else: alt13 = 1 elif (LA13_0 == u'L' or LA13_0 == u'l') : alt13 = 2 else: nvae = NoViableAltException("614:1: fragment IntegerTypeSuffix : ( ( 'u' | 'U' ) | ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) | ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) );", 13, 0, self.input) raise nvae if alt13 == 1: # C.g:616:4: ( 'u' | 'U' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 2: # C.g:617:4: ( 'l' | 'L' ) if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 3: # C.g:618:4: ( 'u' | 'U' ) ( 'l' | 'L' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 4: # C.g:619:4: ( 'u' | 'U' ) ( 'l' | 'L' ) ( 'l' | 'L' ) if self.input.LA(1) == u'U' or self.input.LA(1) == u'u': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == u'L' or self.input.LA(1) == u'l': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end IntegerTypeSuffix # $ANTLR start FLOATING_POINT_LITERAL def mFLOATING_POINT_LITERAL(self, ): try: self.type = FLOATING_POINT_LITERAL # C.g:623:5: ( ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( Exponent )? ( FloatTypeSuffix )? | '.' ( '0' .. '9' )+ ( Exponent )? ( FloatTypeSuffix )? | ( '0' .. '9' )+ Exponent ( FloatTypeSuffix )? | ( '0' .. '9' )+ ( Exponent )? FloatTypeSuffix ) alt25 = 4 alt25 = self.dfa25.predict(self.input) if alt25 == 1: # C.g:623:9: ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( Exponent )? ( FloatTypeSuffix )? # C.g:623:9: ( '0' .. '9' )+ cnt14 = 0 while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if ((u'0' <= LA14_0 <= u'9')) : alt14 = 1 if alt14 == 1: # C.g:623:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt14 >= 1: break #loop14 eee = EarlyExitException(14, self.input) raise eee cnt14 += 1 self.match(u'.') # C.g:623:25: ( '0' .. '9' )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if ((u'0' <= LA15_0 <= u'9')) : alt15 = 1 if alt15 == 1: # C.g:623:26: '0' .. '9' self.matchRange(u'0', u'9') else: break #loop15 # C.g:623:37: ( Exponent )? alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == u'E' or LA16_0 == u'e') : alt16 = 1 if alt16 == 1: # C.g:623:37: Exponent self.mExponent() # C.g:623:47: ( FloatTypeSuffix )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == u'D' or LA17_0 == u'F' or LA17_0 == u'd' or LA17_0 == u'f') : alt17 = 1 if alt17 == 1: # C.g:623:47: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 2: # C.g:624:9: '.' ( '0' .. '9' )+ ( Exponent )? ( FloatTypeSuffix )? self.match(u'.') # C.g:624:13: ( '0' .. '9' )+ cnt18 = 0 while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if ((u'0' <= LA18_0 <= u'9')) : alt18 = 1 if alt18 == 1: # C.g:624:14: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt18 >= 1: break #loop18 eee = EarlyExitException(18, self.input) raise eee cnt18 += 1 # C.g:624:25: ( Exponent )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == u'E' or LA19_0 == u'e') : alt19 = 1 if alt19 == 1: # C.g:624:25: Exponent self.mExponent() # C.g:624:35: ( FloatTypeSuffix )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == u'D' or LA20_0 == u'F' or LA20_0 == u'd' or LA20_0 == u'f') : alt20 = 1 if alt20 == 1: # C.g:624:35: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 3: # C.g:625:9: ( '0' .. '9' )+ Exponent ( FloatTypeSuffix )? # C.g:625:9: ( '0' .. '9' )+ cnt21 = 0 while True: #loop21 alt21 = 2 LA21_0 = self.input.LA(1) if ((u'0' <= LA21_0 <= u'9')) : alt21 = 1 if alt21 == 1: # C.g:625:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt21 >= 1: break #loop21 eee = EarlyExitException(21, self.input) raise eee cnt21 += 1 self.mExponent() # C.g:625:30: ( FloatTypeSuffix )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == u'D' or LA22_0 == u'F' or LA22_0 == u'd' or LA22_0 == u'f') : alt22 = 1 if alt22 == 1: # C.g:625:30: FloatTypeSuffix self.mFloatTypeSuffix() elif alt25 == 4: # C.g:626:9: ( '0' .. '9' )+ ( Exponent )? FloatTypeSuffix # C.g:626:9: ( '0' .. '9' )+ cnt23 = 0 while True: #loop23 alt23 = 2 LA23_0 = self.input.LA(1) if ((u'0' <= LA23_0 <= u'9')) : alt23 = 1 if alt23 == 1: # C.g:626:10: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt23 >= 1: break #loop23 eee = EarlyExitException(23, self.input) raise eee cnt23 += 1 # C.g:626:21: ( Exponent )? alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == u'E' or LA24_0 == u'e') : alt24 = 1 if alt24 == 1: # C.g:626:21: Exponent self.mExponent() self.mFloatTypeSuffix() finally: pass # $ANTLR end FLOATING_POINT_LITERAL # $ANTLR start Exponent def mExponent(self, ): try: # C.g:630:10: ( ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ ) # C.g:630:12: ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ if self.input.LA(1) == u'E' or self.input.LA(1) == u'e': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:630:22: ( '+' | '-' )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == u'+' or LA26_0 == u'-') : alt26 = 1 if alt26 == 1: # C.g: if self.input.LA(1) == u'+' or self.input.LA(1) == u'-': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # C.g:630:33: ( '0' .. '9' )+ cnt27 = 0 while True: #loop27 alt27 = 2 LA27_0 = self.input.LA(1) if ((u'0' <= LA27_0 <= u'9')) : alt27 = 1 if alt27 == 1: # C.g:630:34: '0' .. '9' self.matchRange(u'0', u'9') else: if cnt27 >= 1: break #loop27 eee = EarlyExitException(27, self.input) raise eee cnt27 += 1 finally: pass # $ANTLR end Exponent # $ANTLR start FloatTypeSuffix def mFloatTypeSuffix(self, ): try: # C.g:633:17: ( ( 'f' | 'F' | 'd' | 'D' ) ) # C.g:633:19: ( 'f' | 'F' | 'd' | 'D' ) if self.input.LA(1) == u'D' or self.input.LA(1) == u'F' or self.input.LA(1) == u'd' or self.input.LA(1) == u'f': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end FloatTypeSuffix # $ANTLR start EscapeSequence def mEscapeSequence(self, ): try: # C.g:637:5: ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape ) alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == u'\\') : LA28_1 = self.input.LA(2) if (LA28_1 == u'"' or LA28_1 == u'\'' or LA28_1 == u'\\' or LA28_1 == u'b' or LA28_1 == u'f' or LA28_1 == u'n' or LA28_1 == u'r' or LA28_1 == u't') : alt28 = 1 elif ((u'0' <= LA28_1 <= u'7')) : alt28 = 2 else: nvae = NoViableAltException("635:1: fragment EscapeSequence : ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape );", 28, 1, self.input) raise nvae else: nvae = NoViableAltException("635:1: fragment EscapeSequence : ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OctalEscape );", 28, 0, self.input) raise nvae if alt28 == 1: # C.g:637:8: '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) self.match(u'\\') if self.input.LA(1) == u'"' or self.input.LA(1) == u'\'' or self.input.LA(1) == u'\\' or self.input.LA(1) == u'b' or self.input.LA(1) == u'f' or self.input.LA(1) == u'n' or self.input.LA(1) == u'r' or self.input.LA(1) == u't': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt28 == 2: # C.g:638:9: OctalEscape self.mOctalEscape() finally: pass # $ANTLR end EscapeSequence # $ANTLR start OctalEscape def mOctalEscape(self, ): try: # C.g:643:5: ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ) alt29 = 3 LA29_0 = self.input.LA(1) if (LA29_0 == u'\\') : LA29_1 = self.input.LA(2) if ((u'0' <= LA29_1 <= u'3')) : LA29_2 = self.input.LA(3) if ((u'0' <= LA29_2 <= u'7')) : LA29_4 = self.input.LA(4) if ((u'0' <= LA29_4 <= u'7')) : alt29 = 1 else: alt29 = 2 else: alt29 = 3 elif ((u'4' <= LA29_1 <= u'7')) : LA29_3 = self.input.LA(3) if ((u'0' <= LA29_3 <= u'7')) : alt29 = 2 else: alt29 = 3 else: nvae = NoViableAltException("641:1: fragment OctalEscape : ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) );", 29, 1, self.input) raise nvae else: nvae = NoViableAltException("641:1: fragment OctalEscape : ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) );", 29, 0, self.input) raise nvae if alt29 == 1: # C.g:643:9: '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) self.match(u'\\') # C.g:643:14: ( '0' .. '3' ) # C.g:643:15: '0' .. '3' self.matchRange(u'0', u'3') # C.g:643:25: ( '0' .. '7' ) # C.g:643:26: '0' .. '7' self.matchRange(u'0', u'7') # C.g:643:36: ( '0' .. '7' ) # C.g:643:37: '0' .. '7' self.matchRange(u'0', u'7') elif alt29 == 2: # C.g:644:9: '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) self.match(u'\\') # C.g:644:14: ( '0' .. '7' ) # C.g:644:15: '0' .. '7' self.matchRange(u'0', u'7') # C.g:644:25: ( '0' .. '7' ) # C.g:644:26: '0' .. '7' self.matchRange(u'0', u'7') elif alt29 == 3: # C.g:645:9: '\\\\' ( '0' .. '7' ) self.match(u'\\') # C.g:645:14: ( '0' .. '7' ) # C.g:645:15: '0' .. '7' self.matchRange(u'0', u'7') finally: pass # $ANTLR end OctalEscape # $ANTLR start UnicodeEscape def mUnicodeEscape(self, ): try: # C.g:650:5: ( '\\\\' 'u' HexDigit HexDigit HexDigit HexDigit ) # C.g:650:9: '\\\\' 'u' HexDigit HexDigit HexDigit HexDigit self.match(u'\\') self.match(u'u') self.mHexDigit() self.mHexDigit() self.mHexDigit() self.mHexDigit() finally: pass # $ANTLR end UnicodeEscape # $ANTLR start WS def mWS(self, ): try: self.type = WS # C.g:653:5: ( ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) ) # C.g:653:8: ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) if (u'\t' <= self.input.LA(1) <= u'\n') or (u'\f' <= self.input.LA(1) <= u'\r') or self.input.LA(1) == u' ': self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end WS # $ANTLR start BS def mBS(self, ): try: self.type = BS # C.g:657:5: ( ( '\\\\' ) ) # C.g:657:7: ( '\\\\' ) # C.g:657:7: ( '\\\\' ) # C.g:657:8: '\\\\' self.match(u'\\') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end BS # $ANTLR start UnicodeVocabulary def mUnicodeVocabulary(self, ): try: self.type = UnicodeVocabulary # C.g:665:5: ( '\\u0003' .. '\\uFFFE' ) # C.g:665:7: '\\u0003' .. '\\uFFFE' self.matchRange(u'\u0003', u'\uFFFE') finally: pass # $ANTLR end UnicodeVocabulary # $ANTLR start COMMENT def mCOMMENT(self, ): try: self.type = COMMENT # C.g:668:5: ( '/*' ( options {greedy=false; } : . )* '*/' ) # C.g:668:9: '/*' ( options {greedy=false; } : . )* '*/' self.match("/*") # C.g:668:14: ( options {greedy=false; } : . )* while True: #loop30 alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == u'*') : LA30_1 = self.input.LA(2) if (LA30_1 == u'/') : alt30 = 2 elif ((u'\u0000' <= LA30_1 <= u'.') or (u'0' <= LA30_1 <= u'\uFFFE')) : alt30 = 1 elif ((u'\u0000' <= LA30_0 <= u')') or (u'+' <= LA30_0 <= u'\uFFFE')) : alt30 = 1 if alt30 == 1: # C.g:668:42: . self.matchAny() else: break #loop30 self.match("*/") #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end COMMENT # $ANTLR start LINE_COMMENT def mLINE_COMMENT(self, ): try: self.type = LINE_COMMENT # C.g:673:5: ( '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) # C.g:673:7: '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' self.match("//") # C.g:673:12: (~ ( '\\n' | '\\r' ) )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if ((u'\u0000' <= LA31_0 <= u'\t') or (u'\u000B' <= LA31_0 <= u'\f') or (u'\u000E' <= LA31_0 <= u'\uFFFE')) : alt31 = 1 if alt31 == 1: # C.g:673:12: ~ ( '\\n' | '\\r' ) if (u'\u0000' <= self.input.LA(1) <= u'\t') or (u'\u000B' <= self.input.LA(1) <= u'\f') or (u'\u000E' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop31 # C.g:673:26: ( '\\r' )? alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == u'\r') : alt32 = 1 if alt32 == 1: # C.g:673:26: '\\r' self.match(u'\r') self.match(u'\n') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end LINE_COMMENT # $ANTLR start LINE_COMMAND def mLINE_COMMAND(self, ): try: self.type = LINE_COMMAND # C.g:678:5: ( '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) # C.g:678:7: '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' self.match(u'#') # C.g:678:11: (~ ( '\\n' | '\\r' ) )* while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if ((u'\u0000' <= LA33_0 <= u'\t') or (u'\u000B' <= LA33_0 <= u'\f') or (u'\u000E' <= LA33_0 <= u'\uFFFE')) : alt33 = 1 if alt33 == 1: # C.g:678:11: ~ ( '\\n' | '\\r' ) if (u'\u0000' <= self.input.LA(1) <= u'\t') or (u'\u000B' <= self.input.LA(1) <= u'\f') or (u'\u000E' <= self.input.LA(1) <= u'\uFFFE'): self.input.consume(); else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop33 # C.g:678:25: ( '\\r' )? alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == u'\r') : alt34 = 1 if alt34 == 1: # C.g:678:25: '\\r' self.match(u'\r') self.match(u'\n') #action start self.channel=HIDDEN; #action end finally: pass # $ANTLR end LINE_COMMAND def mTokens(self): # C.g:1:8: ( T25 | T26 | T27 | T28 | T29 | T30 | T31 | T32 | T33 | T34 | T35 | T36 | T37 | T38 | T39 | T40 | T41 | T42 | T43 | T44 | T45 | T46 | T47 | T48 | T49 | T50 | T51 | T52 | T53 | T54 | T55 | T56 | T57 | T58 | T59 | T60 | T61 | T62 | T63 | T64 | T65 | T66 | T67 | T68 | T69 | T70 | T71 | T72 | T73 | T74 | T75 | T76 | T77 | T78 | T79 | T80 | T81 | T82 | T83 | T84 | T85 | T86 | T87 | T88 | T89 | T90 | T91 | T92 | T93 | T94 | T95 | T96 | T97 | T98 | T99 | T100 | T101 | T102 | T103 | T104 | T105 | T106 | T107 | T108 | T109 | T110 | T111 | T112 | T113 | T114 | T115 | T116 | T117 | IDENTIFIER | CHARACTER_LITERAL | STRING_LITERAL | HEX_LITERAL | DECIMAL_LITERAL | OCTAL_LITERAL | FLOATING_POINT_LITERAL | WS | BS | UnicodeVocabulary | COMMENT | LINE_COMMENT | LINE_COMMAND ) alt35 = 106 alt35 = self.dfa35.predict(self.input) if alt35 == 1: # C.g:1:10: T25 self.mT25() elif alt35 == 2: # C.g:1:14: T26 self.mT26() elif alt35 == 3: # C.g:1:18: T27 self.mT27() elif alt35 == 4: # C.g:1:22: T28 self.mT28() elif alt35 == 5: # C.g:1:26: T29 self.mT29() elif alt35 == 6: # C.g:1:30: T30 self.mT30() elif alt35 == 7: # C.g:1:34: T31 self.mT31() elif alt35 == 8: # C.g:1:38: T32 self.mT32() elif alt35 == 9: # C.g:1:42: T33 self.mT33() elif alt35 == 10: # C.g:1:46: T34 self.mT34() elif alt35 == 11: # C.g:1:50: T35 self.mT35() elif alt35 == 12: # C.g:1:54: T36 self.mT36() elif alt35 == 13: # C.g:1:58: T37 self.mT37() elif alt35 == 14: # C.g:1:62: T38 self.mT38() elif alt35 == 15: # C.g:1:66: T39 self.mT39() elif alt35 == 16: # C.g:1:70: T40 self.mT40() elif alt35 == 17: # C.g:1:74: T41 self.mT41() elif alt35 == 18: # C.g:1:78: T42 self.mT42() elif alt35 == 19: # C.g:1:82: T43 self.mT43() elif alt35 == 20: # C.g:1:86: T44 self.mT44() elif alt35 == 21: # C.g:1:90: T45 self.mT45() elif alt35 == 22: # C.g:1:94: T46 self.mT46() elif alt35 == 23: # C.g:1:98: T47 self.mT47() elif alt35 == 24: # C.g:1:102: T48 self.mT48() elif alt35 == 25: # C.g:1:106: T49 self.mT49() elif alt35 == 26: # C.g:1:110: T50 self.mT50() elif alt35 == 27: # C.g:1:114: T51 self.mT51() elif alt35 == 28: # C.g:1:118: T52 self.mT52() elif alt35 == 29: # C.g:1:122: T53 self.mT53() elif alt35 == 30: # C.g:1:126: T54 self.mT54() elif alt35 == 31: # C.g:1:130: T55 self.mT55() elif alt35 == 32: # C.g:1:134: T56 self.mT56() elif alt35 == 33: # C.g:1:138: T57 self.mT57() elif alt35 == 34: # C.g:1:142: T58 self.mT58() elif alt35 == 35: # C.g:1:146: T59 self.mT59() elif alt35 == 36: # C.g:1:150: T60 self.mT60() elif alt35 == 37: # C.g:1:154: T61 self.mT61() elif alt35 == 38: # C.g:1:158: T62 self.mT62() elif alt35 == 39: # C.g:1:162: T63 self.mT63() elif alt35 == 40: # C.g:1:166: T64 self.mT64() elif alt35 == 41: # C.g:1:170: T65 self.mT65() elif alt35 == 42: # C.g:1:174: T66 self.mT66() elif alt35 == 43: # C.g:1:178: T67 self.mT67() elif alt35 == 44: # C.g:1:182: T68 self.mT68() elif alt35 == 45: # C.g:1:186: T69 self.mT69() elif alt35 == 46: # C.g:1:190: T70 self.mT70() elif alt35 == 47: # C.g:1:194: T71 self.mT71() elif alt35 == 48: # C.g:1:198: T72 self.mT72() elif alt35 == 49: # C.g:1:202: T73 self.mT73() elif alt35 == 50: # C.g:1:206: T74 self.mT74() elif alt35 == 51: # C.g:1:210: T75 self.mT75() elif alt35 == 52: # C.g:1:214: T76 self.mT76() elif alt35 == 53: # C.g:1:218: T77 self.mT77() elif alt35 == 54: # C.g:1:222: T78 self.mT78() elif alt35 == 55: # C.g:1:226: T79 self.mT79() elif alt35 == 56: # C.g:1:230: T80 self.mT80() elif alt35 == 57: # C.g:1:234: T81 self.mT81() elif alt35 == 58: # C.g:1:238: T82 self.mT82() elif alt35 == 59: # C.g:1:242: T83 self.mT83() elif alt35 == 60: # C.g:1:246: T84 self.mT84() elif alt35 == 61: # C.g:1:250: T85 self.mT85() elif alt35 == 62: # C.g:1:254: T86 self.mT86() elif alt35 == 63: # C.g:1:258: T87 self.mT87() elif alt35 == 64: # C.g:1:262: T88 self.mT88() elif alt35 == 65: # C.g:1:266: T89 self.mT89() elif alt35 == 66: # C.g:1:270: T90 self.mT90() elif alt35 == 67: # C.g:1:274: T91 self.mT91() elif alt35 == 68: # C.g:1:278: T92 self.mT92() elif alt35 == 69: # C.g:1:282: T93 self.mT93() elif alt35 == 70: # C.g:1:286: T94 self.mT94() elif alt35 == 71: # C.g:1:290: T95 self.mT95() elif alt35 == 72: # C.g:1:294: T96 self.mT96() elif alt35 == 73: # C.g:1:298: T97 self.mT97() elif alt35 == 74: # C.g:1:302: T98 self.mT98() elif alt35 == 75: # C.g:1:306: T99 self.mT99() elif alt35 == 76: # C.g:1:310: T100 self.mT100() elif alt35 == 77: # C.g:1:315: T101 self.mT101() elif alt35 == 78: # C.g:1:320: T102 self.mT102() elif alt35 == 79: # C.g:1:325: T103 self.mT103() elif alt35 == 80: # C.g:1:330: T104 self.mT104() elif alt35 == 81: # C.g:1:335: T105 self.mT105() elif alt35 == 82: # C.g:1:340: T106 self.mT106() elif alt35 == 83: # C.g:1:345: T107 self.mT107() elif alt35 == 84: # C.g:1:350: T108 self.mT108() elif alt35 == 85: # C.g:1:355: T109 self.mT109() elif alt35 == 86: # C.g:1:360: T110 self.mT110() elif alt35 == 87: # C.g:1:365: T111 self.mT111() elif alt35 == 88: # C.g:1:370: T112 self.mT112() elif alt35 == 89: # C.g:1:375: T113 self.mT113() elif alt35 == 90: # C.g:1:380: T114 self.mT114() elif alt35 == 91: # C.g:1:385: T115 self.mT115() elif alt35 == 92: # C.g:1:390: T116 self.mT116() elif alt35 == 93: # C.g:1:395: T117 self.mT117() elif alt35 == 94: # C.g:1:400: IDENTIFIER self.mIDENTIFIER() elif alt35 == 95: # C.g:1:411: CHARACTER_LITERAL self.mCHARACTER_LITERAL() elif alt35 == 96: # C.g:1:429: STRING_LITERAL self.mSTRING_LITERAL() elif alt35 == 97: # C.g:1:444: HEX_LITERAL self.mHEX_LITERAL() elif alt35 == 98: # C.g:1:456: DECIMAL_LITERAL self.mDECIMAL_LITERAL() elif alt35 == 99: # C.g:1:472: OCTAL_LITERAL self.mOCTAL_LITERAL() elif alt35 == 100: # C.g:1:486: FLOATING_POINT_LITERAL self.mFLOATING_POINT_LITERAL() elif alt35 == 101: # C.g:1:509: WS self.mWS() elif alt35 == 102: # C.g:1:512: BS self.mBS() elif alt35 == 103: # C.g:1:515: UnicodeVocabulary self.mUnicodeVocabulary() elif alt35 == 104: # C.g:1:533: COMMENT self.mCOMMENT() elif alt35 == 105: # C.g:1:541: LINE_COMMENT self.mLINE_COMMENT() elif alt35 == 106: # C.g:1:554: LINE_COMMAND self.mLINE_COMMAND() # lookup tables for DFA #25 DFA25_eot = DFA.unpack( u"\7\uffff\1\10\2\uffff" ) DFA25_eof = DFA.unpack( u"\12\uffff" ) DFA25_min = DFA.unpack( u"\2\56\2\uffff\1\53\1\uffff\2\60\2\uffff" ) DFA25_max = DFA.unpack( u"\1\71\1\146\2\uffff\1\71\1\uffff\1\71\1\146\2\uffff" ) DFA25_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff\1\4\2\uffff\2\3" ) DFA25_special = DFA.unpack( u"\12\uffff" ) DFA25_transition = [ DFA.unpack(u"\1\2\1\uffff\12\1"), DFA.unpack(u"\1\3\1\uffff\12\1\12\uffff\1\5\1\4\1\5\35\uffff\1\5" u"\1\4\1\5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\6\1\uffff\1\6\2\uffff\12\7"), DFA.unpack(u""), DFA.unpack(u"\12\7"), DFA.unpack(u"\12\7\12\uffff\1\11\1\uffff\1\11\35\uffff\1\11\1\uffff" u"\1\11"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #25 DFA25 = DFA # lookup tables for DFA #35 DFA35_eot = DFA.unpack( u"\2\uffff\1\76\1\uffff\1\101\14\76\3\uffff\10\76\4\uffff\1\151\1" u"\153\1\157\1\163\1\167\1\171\1\174\1\uffff\1\177\1\u0082\1\u0085" u"\1\u0087\1\u008a\1\uffff\5\76\1\uffff\2\73\2\u0095\2\uffff\1\73" u"\2\uffff\1\76\4\uffff\16\76\1\u00ad\5\76\1\u00b4\1\76\3\uffff\1" u"\u00b7\10\76\34\uffff\1\u00c1\2\uffff\1\u00c3\10\uffff\5\76\3\uffff" u"\1\u00c9\1\uffff\1\u0095\3\uffff\23\76\1\uffff\1\u00de\1\76\1\u00e0" u"\3\76\1\uffff\2\76\1\uffff\1\76\1\u00e7\6\76\4\uffff\5\76\1\uffff" u"\1\76\1\u00f5\1\76\1\u00f7\6\76\1\u00fe\4\76\1\u0103\1\u0104\2" u"\76\1\u0107\1\uffff\1\u0108\1\uffff\6\76\1\uffff\10\76\1\u0118" u"\1\76\1\u011a\2\76\1\uffff\1\76\1\uffff\5\76\1\u0123\1\uffff\4" u"\76\2\uffff\1\76\1\u0129\2\uffff\1\u012a\3\76\1\u012e\1\76\1\u0130" u"\7\76\1\u0139\1\uffff\1\u013a\1\uffff\1\u013b\1\76\1\u013d\1\u013e" u"\1\u013f\1\u0140\1\u0141\1\u0142\1\uffff\1\76\1\u0144\1\u0145\2" u"\76\2\uffff\1\76\1\u0149\1\76\1\uffff\1\76\1\uffff\5\76\1\u0151" u"\1\u0152\1\76\3\uffff\1\u0154\6\uffff\1\76\2\uffff\2\76\1\u0158" u"\1\uffff\7\76\2\uffff\1\u0160\1\uffff\1\u0161\1\u0162\1\u0163\1" u"\uffff\1\u0164\1\u0165\1\76\1\u0167\3\76\6\uffff\1\u016b\1\uffff" u"\3\76\1\uffff\21\76\1\u0180\2\76\1\uffff\3\76\1\u0186\1\76\1\uffff" u"\11\76\1\u0191\1\uffff" ) DFA35_eof = DFA.unpack( u"\u0192\uffff" ) DFA35_min = DFA.unpack( u"\1\3\1\uffff\1\171\1\uffff\1\75\1\154\1\150\1\165\1\145\1\124\1" u"\157\1\141\1\146\1\157\1\154\1\145\1\156\3\uffff\1\116\1\120\1" u"\117\1\116\1\117\1\114\1\106\1\101\4\uffff\1\75\1\56\1\53\1\55" u"\1\52\1\75\1\46\1\uffff\1\75\1\74\3\75\1\uffff\1\137\1\150\1\157" u"\1\162\1\42\1\uffff\2\0\2\56\2\uffff\1\0\2\uffff\1\160\4\uffff" u"\1\163\1\164\1\165\1\151\1\141\1\147\1\157\1\164\1\147\1\101\1" u"\151\1\163\1\156\1\141\1\44\1\164\1\156\1\162\1\157\1\146\1\44" u"\1\151\3\uffff\1\44\2\124\1\116\1\101\1\114\1\117\1\111\1\103\34" u"\uffff\1\75\2\uffff\1\75\10\uffff\1\141\1\163\1\151\1\164\1\145" u"\3\uffff\1\56\1\uffff\1\56\3\uffff\3\145\1\155\2\164\1\165\1\145" u"\1\156\1\162\1\157\1\151\1\165\1\124\1\141\1\144\1\145\1\163\1" u"\162\1\uffff\1\44\1\147\1\44\2\141\1\142\1\uffff\1\151\1\157\1" u"\uffff\1\111\1\44\1\123\1\114\1\101\1\102\1\101\1\113\4\uffff\1" u"\163\1\155\1\154\1\157\1\141\1\uffff\1\144\1\44\1\162\1\44\1\143" u"\1\151\1\143\1\157\1\145\1\164\1\44\1\163\1\162\1\111\1\164\2\44" u"\1\151\1\164\1\44\1\uffff\1\44\1\uffff\1\164\1\165\1\154\1\147" u"\1\156\1\117\1\uffff\1\124\1\111\1\124\1\101\1\102\1\120\1\105" u"\1\155\1\44\1\145\1\44\1\153\1\145\1\uffff\1\156\1\uffff\1\150" u"\1\143\1\164\1\146\1\144\1\44\1\uffff\1\164\1\156\1\103\1\151\2" u"\uffff\1\156\1\44\2\uffff\1\44\1\154\1\145\1\156\1\44\1\116\1\44" u"\1\107\1\111\1\114\1\125\1\117\1\111\1\104\1\44\1\uffff\1\44\1" u"\uffff\1\44\1\146\6\44\1\uffff\1\145\2\44\1\154\1\165\2\uffff\1" u"\164\1\44\1\145\1\uffff\1\101\1\uffff\1\116\1\114\1\137\1\116\1" u"\117\2\44\1\137\3\uffff\1\44\6\uffff\1\162\2\uffff\2\145\1\44\1" u"\uffff\1\144\1\114\2\105\1\122\2\124\2\uffff\1\44\1\uffff\3\44" u"\1\uffff\2\44\1\104\1\44\1\105\1\111\1\123\6\uffff\1\44\1\uffff" u"\2\115\1\105\1\uffff\1\117\1\105\1\122\1\126\1\123\1\126\2\105" u"\1\111\1\137\1\122\1\103\1\111\1\126\1\105\1\106\1\111\1\44\1\137" u"\1\103\1\uffff\1\125\1\105\1\116\1\44\1\122\1\uffff\1\105\1\106" u"\1\105\1\122\1\105\1\116\1\103\1\105\1\104\1\44\1\uffff" ) DFA35_max = DFA.unpack( u"\1\ufffe\1\uffff\1\171\1\uffff\1\75\1\170\1\167\1\165\1\145\1\124" u"\2\157\1\156\3\157\1\156\3\uffff\1\116\1\125\1\117\1\116\1\117" u"\1\114\1\106\1\101\4\uffff\1\75\1\71\1\75\1\76\3\75\1\uffff\2\75" u"\1\76\1\75\1\174\1\uffff\1\141\1\150\1\157\1\162\1\47\1\uffff\2" u"\ufffe\1\170\1\146\2\uffff\1\ufffe\2\uffff\1\160\4\uffff\1\163" u"\1\164\1\165\1\151\1\162\1\172\1\157\2\164\1\101\1\154\1\163\1" u"\156\1\141\1\172\1\164\1\156\1\162\1\157\1\146\1\172\1\163\3\uffff" u"\1\172\2\124\1\116\1\101\1\114\1\117\1\111\1\103\34\uffff\1\75" u"\2\uffff\1\75\10\uffff\1\141\1\163\1\151\1\164\1\145\3\uffff\1" u"\146\1\uffff\1\146\3\uffff\3\145\1\155\2\164\1\165\1\145\1\156" u"\1\162\1\157\1\151\1\165\1\124\1\141\1\144\1\145\1\164\1\162\1" u"\uffff\1\172\1\147\1\172\2\141\1\142\1\uffff\1\151\1\157\1\uffff" u"\1\111\1\172\1\123\1\114\1\101\1\102\1\137\1\113\4\uffff\1\163" u"\1\155\1\154\1\157\1\141\1\uffff\1\144\1\172\1\162\1\172\1\143" u"\1\151\1\143\1\157\1\145\1\164\1\172\1\163\1\162\1\111\1\164\2" u"\172\1\151\1\164\1\172\1\uffff\1\172\1\uffff\1\164\1\165\1\154" u"\1\147\1\156\1\117\1\uffff\1\124\1\111\1\124\1\101\1\122\1\120" u"\1\105\1\155\1\172\1\145\1\172\1\153\1\145\1\uffff\1\156\1\uffff" u"\1\150\1\143\1\164\1\146\1\144\1\172\1\uffff\1\164\1\156\1\103" u"\1\151\2\uffff\1\156\1\172\2\uffff\1\172\1\154\1\145\1\156\1\172" u"\1\116\1\172\1\107\1\111\1\114\1\125\1\117\1\111\1\104\1\172\1" u"\uffff\1\172\1\uffff\1\172\1\146\6\172\1\uffff\1\145\2\172\1\154" u"\1\165\2\uffff\1\164\1\172\1\145\1\uffff\1\101\1\uffff\1\116\1" u"\114\1\137\1\116\1\117\2\172\1\137\3\uffff\1\172\6\uffff\1\162" u"\2\uffff\2\145\1\172\1\uffff\1\144\1\114\2\105\1\122\2\124\2\uffff" u"\1\172\1\uffff\3\172\1\uffff\2\172\1\104\1\172\1\105\1\111\1\123" u"\6\uffff\1\172\1\uffff\2\115\1\105\1\uffff\1\117\1\105\1\122\1" u"\126\1\123\1\126\2\105\1\111\1\137\1\122\1\103\1\111\1\126\1\105" u"\1\106\1\111\1\172\1\137\1\103\1\uffff\1\125\1\105\1\116\1\172" u"\1\122\1\uffff\1\105\1\106\1\105\1\122\1\105\1\116\1\103\1\105" u"\1\104\1\172\1\uffff" ) DFA35_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\3\15\uffff\1\23\1\24\1\27\10\uffff\1\46" u"\1\47\1\50\1\51\7\uffff\1\66\5\uffff\1\102\5\uffff\1\136\4\uffff" u"\1\145\1\146\1\uffff\1\147\1\1\1\uffff\1\136\1\3\1\107\1\4\26\uffff" u"\1\23\1\24\1\27\11\uffff\1\46\1\47\1\50\1\51\1\70\1\52\1\53\1\63" u"\1\144\1\73\1\60\1\54\1\74\1\64\1\61\1\55\1\150\1\151\1\71\1\56" u"\1\72\1\57\1\77\1\104\1\65\1\66\1\110\1\67\1\uffff\1\113\1\111" u"\1\uffff\1\114\1\112\1\100\1\106\1\103\1\101\1\105\1\102\5\uffff" u"\1\140\1\137\1\141\1\uffff\1\142\1\uffff\1\145\1\146\1\152\23\uffff" u"\1\124\6\uffff\1\130\2\uffff\1\33\10\uffff\1\75\1\115\1\76\1\116" u"\5\uffff\1\143\24\uffff\1\15\1\uffff\1\131\6\uffff\1\34\15\uffff" u"\1\125\1\uffff\1\30\6\uffff\1\7\4\uffff\1\12\1\122\2\uffff\1\13" u"\1\16\17\uffff\1\120\1\uffff\1\132\10\uffff\1\14\5\uffff\1\31\1" u"\17\3\uffff\1\26\1\uffff\1\36\10\uffff\1\121\1\127\1\134\1\uffff" u"\1\5\1\126\1\6\1\25\1\62\1\21\1\uffff\1\135\1\11\3\uffff\1\20\7" u"\uffff\1\42\1\45\1\uffff\1\2\3\uffff\1\123\7\uffff\1\117\1\10\1" u"\32\1\133\1\22\1\35\1\uffff\1\40\3\uffff\1\37\24\uffff\1\43\5\uffff" u"\1\44\12\uffff\1\41" ) DFA35_special = DFA.unpack( u"\u0192\uffff" ) DFA35_transition = [ DFA.unpack(u"\6\73\2\70\1\73\2\70\22\73\1\70\1\50\1\65\1\72\1\63" u"\1\45\1\46\1\64\1\34\1\35\1\40\1\42\1\3\1\43\1\41\1\44\1\66\11" u"\67\1\23\1\1\1\51\1\4\1\52\1\55\1\73\2\63\1\26\1\63\1\32\1\63\1" u"\31\1\63\1\24\2\63\1\62\2\63\1\25\1\33\2\63\1\11\1\63\1\27\1\30" u"\4\63\1\36\1\71\1\37\1\53\1\56\1\73\1\7\1\61\1\13\1\17\1\5\1\16" u"\1\60\1\63\1\14\2\63\1\15\5\63\1\10\1\6\1\2\1\20\1\12\1\57\3\63" u"\1\21\1\54\1\22\1\47\uff80\73"), DFA.unpack(u""), DFA.unpack(u"\1\75"), DFA.unpack(u""), DFA.unpack(u"\1\100"), DFA.unpack(u"\1\102\1\uffff\1\104\11\uffff\1\103"), DFA.unpack(u"\1\110\1\107\12\uffff\1\106\2\uffff\1\105"), DFA.unpack(u"\1\111"), DFA.unpack(u"\1\112"), DFA.unpack(u"\1\113"), DFA.unpack(u"\1\114"), DFA.unpack(u"\1\115\6\uffff\1\117\6\uffff\1\116"), DFA.unpack(u"\1\120\7\uffff\1\121"), DFA.unpack(u"\1\122"), DFA.unpack(u"\1\124\2\uffff\1\123"), DFA.unpack(u"\1\125\11\uffff\1\126"), DFA.unpack(u"\1\127"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134\4\uffff\1\135"), DFA.unpack(u"\1\136"), DFA.unpack(u"\1\137"), DFA.unpack(u"\1\140"), DFA.unpack(u"\1\141"), DFA.unpack(u"\1\142"), DFA.unpack(u"\1\143"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\150"), DFA.unpack(u"\1\152\1\uffff\12\154"), DFA.unpack(u"\1\156\21\uffff\1\155"), DFA.unpack(u"\1\162\17\uffff\1\160\1\161"), DFA.unpack(u"\1\164\4\uffff\1\165\15\uffff\1\166"), DFA.unpack(u"\1\170"), DFA.unpack(u"\1\173\26\uffff\1\172"), DFA.unpack(u""), DFA.unpack(u"\1\176"), DFA.unpack(u"\1\u0080\1\u0081"), DFA.unpack(u"\1\u0084\1\u0083"), DFA.unpack(u"\1\u0086"), DFA.unpack(u"\1\u0089\76\uffff\1\u0088"), DFA.unpack(u""), DFA.unpack(u"\1\u008c\1\uffff\1\u008d"), DFA.unpack(u"\1\u008e"), DFA.unpack(u"\1\u008f"), DFA.unpack(u"\1\u0090"), DFA.unpack(u"\1\u0091\4\uffff\1\u0092"), DFA.unpack(u""), DFA.unpack(u"\47\u0092\1\uffff\uffd7\u0092"), DFA.unpack(u"\uffff\u0091"), DFA.unpack(u"\1\154\1\uffff\10\u0094\2\154\12\uffff\3\154\21\uffff" u"\1\u0093\13\uffff\3\154\21\uffff\1\u0093"), DFA.unpack(u"\1\154\1\uffff\12\u0096\12\uffff\3\154\35\uffff\3\154"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\uffff\u0099"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u009a"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u009b"), DFA.unpack(u"\1\u009c"), DFA.unpack(u"\1\u009d"), DFA.unpack(u"\1\u009e"), DFA.unpack(u"\1\u009f\20\uffff\1\u00a0"), DFA.unpack(u"\1\u00a2\22\uffff\1\u00a1"), DFA.unpack(u"\1\u00a3"), DFA.unpack(u"\1\u00a4"), DFA.unpack(u"\1\u00a5\14\uffff\1\u00a6"), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\1\u00a9\2\uffff\1\u00a8"), DFA.unpack(u"\1\u00aa"), DFA.unpack(u"\1\u00ab"), DFA.unpack(u"\1\u00ac"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00ae"), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\1\u00b0"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\1\u00b2"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\24\76\1\u00b3\5\76"), DFA.unpack(u"\1\u00b6\11\uffff\1\u00b5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00b8"), DFA.unpack(u"\1\u00b9"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\1\u00bb"), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\1\u00bd"), DFA.unpack(u"\1\u00be"), DFA.unpack(u"\1\u00bf"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c0"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c4"), DFA.unpack(u"\1\u00c5"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u"\1\u00c7"), DFA.unpack(u"\1\u00c8"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\154\1\uffff\10\u0094\2\154\12\uffff\3\154\35\uffff" u"\3\154"), DFA.unpack(u""), DFA.unpack(u"\1\154\1\uffff\12\u0096\12\uffff\3\154\35\uffff\3\154"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ca"), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\1\u00cc"), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u"\1\u00cf"), DFA.unpack(u"\1\u00d0"), DFA.unpack(u"\1\u00d1"), DFA.unpack(u"\1\u00d2"), DFA.unpack(u"\1\u00d3"), DFA.unpack(u"\1\u00d4"), DFA.unpack(u"\1\u00d5"), DFA.unpack(u"\1\u00d6"), DFA.unpack(u"\1\u00d7"), DFA.unpack(u"\1\u00d8"), DFA.unpack(u"\1\u00d9"), DFA.unpack(u"\1\u00da"), DFA.unpack(u"\1\u00dc\1\u00db"), DFA.unpack(u"\1\u00dd"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00df"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00e1"), DFA.unpack(u"\1\u00e2"), DFA.unpack(u"\1\u00e3"), DFA.unpack(u""), DFA.unpack(u"\1\u00e4"), DFA.unpack(u"\1\u00e5"), DFA.unpack(u""), DFA.unpack(u"\1\u00e6"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00e8"), DFA.unpack(u"\1\u00e9"), DFA.unpack(u"\1\u00ea"), DFA.unpack(u"\1\u00eb"), DFA.unpack(u"\1\u00ed\35\uffff\1\u00ec"), DFA.unpack(u"\1\u00ee"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ef"), DFA.unpack(u"\1\u00f0"), DFA.unpack(u"\1\u00f1"), DFA.unpack(u"\1\u00f2"), DFA.unpack(u"\1\u00f3"), DFA.unpack(u""), DFA.unpack(u"\1\u00f4"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00f6"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00f8"), DFA.unpack(u"\1\u00f9"), DFA.unpack(u"\1\u00fa"), DFA.unpack(u"\1\u00fb"), DFA.unpack(u"\1\u00fc"), DFA.unpack(u"\1\u00fd"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u00ff"), DFA.unpack(u"\1\u0100"), DFA.unpack(u"\1\u0101"), DFA.unpack(u"\1\u0102"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0105"), DFA.unpack(u"\1\u0106"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0109"), DFA.unpack(u"\1\u010a"), DFA.unpack(u"\1\u010b"), DFA.unpack(u"\1\u010c"), DFA.unpack(u"\1\u010d"), DFA.unpack(u"\1\u010e"), DFA.unpack(u""), DFA.unpack(u"\1\u010f"), DFA.unpack(u"\1\u0110"), DFA.unpack(u"\1\u0111"), DFA.unpack(u"\1\u0112"), DFA.unpack(u"\1\u0114\17\uffff\1\u0113"), DFA.unpack(u"\1\u0115"), DFA.unpack(u"\1\u0116"), DFA.unpack(u"\1\u0117"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0119"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u011b"), DFA.unpack(u"\1\u011c"), DFA.unpack(u""), DFA.unpack(u"\1\u011d"), DFA.unpack(u""), DFA.unpack(u"\1\u011e"), DFA.unpack(u"\1\u011f"), DFA.unpack(u"\1\u0120"), DFA.unpack(u"\1\u0121"), DFA.unpack(u"\1\u0122"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0124"), DFA.unpack(u"\1\u0125"), DFA.unpack(u"\1\u0126"), DFA.unpack(u"\1\u0127"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0128"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u012b"), DFA.unpack(u"\1\u012c"), DFA.unpack(u"\1\u012d"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u012f"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0131"), DFA.unpack(u"\1\u0132"), DFA.unpack(u"\1\u0133"), DFA.unpack(u"\1\u0134"), DFA.unpack(u"\1\u0135"), DFA.unpack(u"\1\u0136"), DFA.unpack(u"\1\u0137"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\u0138\1" u"\uffff\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u013c"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0143"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0146"), DFA.unpack(u"\1\u0147"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0148"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u014a"), DFA.unpack(u""), DFA.unpack(u"\1\u014b"), DFA.unpack(u""), DFA.unpack(u"\1\u014c"), DFA.unpack(u"\1\u014d"), DFA.unpack(u"\1\u014e"), DFA.unpack(u"\1\u014f"), DFA.unpack(u"\1\u0150"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0153"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0155"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0156"), DFA.unpack(u"\1\u0157"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u0159"), DFA.unpack(u"\1\u015a"), DFA.unpack(u"\1\u015b"), DFA.unpack(u"\1\u015c"), DFA.unpack(u"\1\u015d"), DFA.unpack(u"\1\u015e"), DFA.unpack(u"\1\u015f"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0166"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0168"), DFA.unpack(u"\1\u0169"), DFA.unpack(u"\1\u016a"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u""), DFA.unpack(u"\1\u016c"), DFA.unpack(u"\1\u016d"), DFA.unpack(u"\1\u016e"), DFA.unpack(u""), DFA.unpack(u"\1\u016f"), DFA.unpack(u"\1\u0170"), DFA.unpack(u"\1\u0171"), DFA.unpack(u"\1\u0172"), DFA.unpack(u"\1\u0173"), DFA.unpack(u"\1\u0174"), DFA.unpack(u"\1\u0175"), DFA.unpack(u"\1\u0176"), DFA.unpack(u"\1\u0177"), DFA.unpack(u"\1\u0178"), DFA.unpack(u"\1\u0179"), DFA.unpack(u"\1\u017a"), DFA.unpack(u"\1\u017b"), DFA.unpack(u"\1\u017c"), DFA.unpack(u"\1\u017d"), DFA.unpack(u"\1\u017e"), DFA.unpack(u"\1\u017f"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0181"), DFA.unpack(u"\1\u0182"), DFA.unpack(u""), DFA.unpack(u"\1\u0183"), DFA.unpack(u"\1\u0184"), DFA.unpack(u"\1\u0185"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"\1\u0187"), DFA.unpack(u""), DFA.unpack(u"\1\u0188"), DFA.unpack(u"\1\u0189"), DFA.unpack(u"\1\u018a"), DFA.unpack(u"\1\u018b"), DFA.unpack(u"\1\u018c"), DFA.unpack(u"\1\u018d"), DFA.unpack(u"\1\u018e"), DFA.unpack(u"\1\u018f"), DFA.unpack(u"\1\u0190"), DFA.unpack(u"\1\76\13\uffff\12\76\7\uffff\32\76\4\uffff\1\76\1\uffff" u"\32\76"), DFA.unpack(u"") ] # class definition for DFA #35 DFA35 = DFA
{ "repo_name": "google/google-ctf", "path": "third_party/edk2/BaseTools/Source/Python/Ecc/CParser3/CLexer.py", "copies": "2", "size": "99172", "license": "apache-2.0", "hash": -5253425472234195000, "line_mean": 18.0468971094, "line_max": 789, "alpha_frac": 0.3870447304, "autogenerated": false, "ratio": 2.888869468962102, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4275914199362102, "avg_score": null, "num_lines": null }
# $ANTLR 3.0.1 C.g 2010-02-23 09:58:53 from antlr3 import * from antlr3.compat import set, frozenset ## @file # The file defines the parser for C source files. # # THIS FILE IS AUTO-GENENERATED. PLEASE DON NOT MODIFY THIS FILE. # This file is generated by running: # java org.antlr.Tool C.g # # Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR> # # This program and the accompanying materials are licensed and made available # under the terms and conditions of the BSD License which accompanies this # distribution. The full text of the license may be found at: # http://opensource.org/licenses/bsd-license.php # # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. # ## import CodeFragment import FileProfile # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types BS=20 LINE_COMMENT=23 FloatTypeSuffix=16 IntegerTypeSuffix=14 LETTER=11 OCTAL_LITERAL=6 CHARACTER_LITERAL=8 Exponent=15 EOF=-1 HexDigit=13 STRING_LITERAL=9 WS=19 FLOATING_POINT_LITERAL=10 IDENTIFIER=4 UnicodeEscape=18 LINE_COMMAND=24 UnicodeVocabulary=21 HEX_LITERAL=5 COMMENT=22 DECIMAL_LITERAL=7 EscapeSequence=12 OctalEscape=17 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "IDENTIFIER", "HEX_LITERAL", "OCTAL_LITERAL", "DECIMAL_LITERAL", "CHARACTER_LITERAL", "STRING_LITERAL", "FLOATING_POINT_LITERAL", "LETTER", "EscapeSequence", "HexDigit", "IntegerTypeSuffix", "Exponent", "FloatTypeSuffix", "OctalEscape", "UnicodeEscape", "WS", "BS", "UnicodeVocabulary", "COMMENT", "LINE_COMMENT", "LINE_COMMAND", "';'", "'typedef'", "','", "'='", "'extern'", "'static'", "'auto'", "'register'", "'STATIC'", "'void'", "'char'", "'short'", "'int'", "'long'", "'float'", "'double'", "'signed'", "'unsigned'", "'{'", "'}'", "'struct'", "'union'", "':'", "'enum'", "'const'", "'volatile'", "'IN'", "'OUT'", "'OPTIONAL'", "'CONST'", "'UNALIGNED'", "'VOLATILE'", "'GLOBAL_REMOVE_IF_UNREFERENCED'", "'EFIAPI'", "'EFI_BOOTSERVICE'", "'EFI_RUNTIMESERVICE'", "'PACKED'", "'('", "')'", "'['", "']'", "'*'", "'...'", "'+'", "'-'", "'/'", "'%'", "'++'", "'--'", "'sizeof'", "'.'", "'->'", "'&'", "'~'", "'!'", "'*='", "'/='", "'%='", "'+='", "'-='", "'<<='", "'>>='", "'&='", "'^='", "'|='", "'?'", "'||'", "'&&'", "'|'", "'^'", "'=='", "'!='", "'<'", "'>'", "'<='", "'>='", "'<<'", "'>>'", "'__asm__'", "'_asm'", "'__asm'", "'case'", "'default'", "'if'", "'else'", "'switch'", "'while'", "'do'", "'for'", "'goto'", "'continue'", "'break'", "'return'" ] class function_definition_scope(object): def __init__(self): self.ModifierText = None self.DeclText = None self.LBLine = None self.LBOffset = None self.DeclLine = None self.DeclOffset = None class postfix_expression_scope(object): def __init__(self): self.FuncCallText = None class CParser(Parser): grammarFileName = "C.g" tokenNames = tokenNames def __init__(self, input): Parser.__init__(self, input) self.ruleMemo = {} self.function_definition_stack = [] self.postfix_expression_stack = [] def printTokenInfo(self, line, offset, tokenText): print str(line)+ ',' + str(offset) + ':' + str(tokenText) def StorePredicateExpression(self, StartLine, StartOffset, EndLine, EndOffset, Text): PredExp = CodeFragment.PredicateExpression(Text, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.PredicateExpressionList.append(PredExp) def StoreEnumerationDefinition(self, StartLine, StartOffset, EndLine, EndOffset, Text): EnumDef = CodeFragment.EnumerationDefinition(Text, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.EnumerationDefinitionList.append(EnumDef) def StoreStructUnionDefinition(self, StartLine, StartOffset, EndLine, EndOffset, Text): SUDef = CodeFragment.StructUnionDefinition(Text, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.StructUnionDefinitionList.append(SUDef) def StoreTypedefDefinition(self, StartLine, StartOffset, EndLine, EndOffset, FromText, ToText): Tdef = CodeFragment.TypedefDefinition(FromText, ToText, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.TypedefDefinitionList.append(Tdef) def StoreFunctionDefinition(self, StartLine, StartOffset, EndLine, EndOffset, ModifierText, DeclText, LeftBraceLine, LeftBraceOffset, DeclLine, DeclOffset): FuncDef = CodeFragment.FunctionDefinition(ModifierText, DeclText, (StartLine, StartOffset), (EndLine, EndOffset), (LeftBraceLine, LeftBraceOffset), (DeclLine, DeclOffset)) FileProfile.FunctionDefinitionList.append(FuncDef) def StoreVariableDeclaration(self, StartLine, StartOffset, EndLine, EndOffset, ModifierText, DeclText): VarDecl = CodeFragment.VariableDeclaration(ModifierText, DeclText, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.VariableDeclarationList.append(VarDecl) def StoreFunctionCalling(self, StartLine, StartOffset, EndLine, EndOffset, FuncName, ParamList): FuncCall = CodeFragment.FunctionCalling(FuncName, ParamList, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.FunctionCallingList.append(FuncCall) # $ANTLR start translation_unit # C.g:102:1: translation_unit : ( external_declaration )* ; def translation_unit(self, ): translation_unit_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 1): return # C.g:103:2: ( ( external_declaration )* ) # C.g:103:4: ( external_declaration )* # C.g:103:4: ( external_declaration )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == IDENTIFIER or LA1_0 == 26 or (29 <= LA1_0 <= 42) or (45 <= LA1_0 <= 46) or (48 <= LA1_0 <= 62) or LA1_0 == 66) : alt1 = 1 if alt1 == 1: # C.g:0:0: external_declaration self.following.append(self.FOLLOW_external_declaration_in_translation_unit74) self.external_declaration() self.following.pop() if self.failed: return else: break #loop1 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 1, translation_unit_StartIndex) pass return # $ANTLR end translation_unit # $ANTLR start external_declaration # C.g:114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? ); def external_declaration(self, ): external_declaration_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 2): return # C.g:119:2: ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? ) alt3 = 3 LA3_0 = self.input.LA(1) if ((29 <= LA3_0 <= 33)) : LA3_1 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 1, self.input) raise nvae elif (LA3_0 == 34) : LA3_2 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 2, self.input) raise nvae elif (LA3_0 == 35) : LA3_3 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 3, self.input) raise nvae elif (LA3_0 == 36) : LA3_4 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 4, self.input) raise nvae elif (LA3_0 == 37) : LA3_5 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 5, self.input) raise nvae elif (LA3_0 == 38) : LA3_6 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 6, self.input) raise nvae elif (LA3_0 == 39) : LA3_7 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 7, self.input) raise nvae elif (LA3_0 == 40) : LA3_8 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 8, self.input) raise nvae elif (LA3_0 == 41) : LA3_9 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 9, self.input) raise nvae elif (LA3_0 == 42) : LA3_10 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 10, self.input) raise nvae elif ((45 <= LA3_0 <= 46)) : LA3_11 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 11, self.input) raise nvae elif (LA3_0 == 48) : LA3_12 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 12, self.input) raise nvae elif (LA3_0 == IDENTIFIER) : LA3_13 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 elif (True) : alt3 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 13, self.input) raise nvae elif (LA3_0 == 58) : LA3_14 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 14, self.input) raise nvae elif (LA3_0 == 66) and (self.synpred4()): alt3 = 1 elif (LA3_0 == 59) : LA3_16 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 16, self.input) raise nvae elif (LA3_0 == 60) : LA3_17 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 17, self.input) raise nvae elif ((49 <= LA3_0 <= 57) or LA3_0 == 61) : LA3_18 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 18, self.input) raise nvae elif (LA3_0 == 62) and (self.synpred4()): alt3 = 1 elif (LA3_0 == 26) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 0, self.input) raise nvae if alt3 == 1: # C.g:119:4: ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition self.following.append(self.FOLLOW_function_definition_in_external_declaration113) self.function_definition() self.following.pop() if self.failed: return elif alt3 == 2: # C.g:120:4: declaration self.following.append(self.FOLLOW_declaration_in_external_declaration118) self.declaration() self.following.pop() if self.failed: return elif alt3 == 3: # C.g:121:4: macro_statement ( ';' )? self.following.append(self.FOLLOW_macro_statement_in_external_declaration123) self.macro_statement() self.following.pop() if self.failed: return # C.g:121:20: ( ';' )? alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == 25) : alt2 = 1 if alt2 == 1: # C.g:121:21: ';' self.match(self.input, 25, self.FOLLOW_25_in_external_declaration126) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 2, external_declaration_StartIndex) pass return # $ANTLR end external_declaration class function_definition_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start function_definition # C.g:126:1: function_definition : (d= declaration_specifiers )? declarator ( ( declaration )+ a= compound_statement | b= compound_statement ) ; def function_definition(self, ): self.function_definition_stack.append(function_definition_scope()) retval = self.function_definition_return() retval.start = self.input.LT(1) function_definition_StartIndex = self.input.index() d = None a = None b = None declarator1 = None self.function_definition_stack[-1].ModifierText = '' self.function_definition_stack[-1].DeclText = '' self.function_definition_stack[-1].LBLine = 0 self.function_definition_stack[-1].LBOffset = 0 self.function_definition_stack[-1].DeclLine = 0 self.function_definition_stack[-1].DeclOffset = 0 try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 3): return retval # C.g:146:2: ( (d= declaration_specifiers )? declarator ( ( declaration )+ a= compound_statement | b= compound_statement ) ) # C.g:146:4: (d= declaration_specifiers )? declarator ( ( declaration )+ a= compound_statement | b= compound_statement ) # C.g:146:5: (d= declaration_specifiers )? alt4 = 2 LA4 = self.input.LA(1) if LA4 == 29 or LA4 == 30 or LA4 == 31 or LA4 == 32 or LA4 == 33 or LA4 == 34 or LA4 == 35 or LA4 == 36 or LA4 == 37 or LA4 == 38 or LA4 == 39 or LA4 == 40 or LA4 == 41 or LA4 == 42 or LA4 == 45 or LA4 == 46 or LA4 == 48 or LA4 == 49 or LA4 == 50 or LA4 == 51 or LA4 == 52 or LA4 == 53 or LA4 == 54 or LA4 == 55 or LA4 == 56 or LA4 == 57 or LA4 == 61: alt4 = 1 elif LA4 == IDENTIFIER: LA4 = self.input.LA(2) if LA4 == 66: alt4 = 1 elif LA4 == 58: LA4_21 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 59: LA4_22 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 60: LA4_23 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == IDENTIFIER: LA4_24 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 62: LA4_25 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 29 or LA4 == 30 or LA4 == 31 or LA4 == 32 or LA4 == 33: LA4_26 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 34: LA4_27 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 35: LA4_28 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 36: LA4_29 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 37: LA4_30 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 38: LA4_31 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 39: LA4_32 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 40: LA4_33 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 41: LA4_34 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 42: LA4_35 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 45 or LA4 == 46: LA4_36 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 48: LA4_37 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 49 or LA4 == 50 or LA4 == 51 or LA4 == 52 or LA4 == 53 or LA4 == 54 or LA4 == 55 or LA4 == 56 or LA4 == 57 or LA4 == 61: LA4_38 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 58: LA4_14 = self.input.LA(2) if (self.synpred7()) : alt4 = 1 elif LA4 == 59: LA4_16 = self.input.LA(2) if (self.synpred7()) : alt4 = 1 elif LA4 == 60: LA4_17 = self.input.LA(2) if (self.synpred7()) : alt4 = 1 if alt4 == 1: # C.g:0:0: d= declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_function_definition157) d = self.declaration_specifiers() self.following.pop() if self.failed: return retval self.following.append(self.FOLLOW_declarator_in_function_definition160) declarator1 = self.declarator() self.following.pop() if self.failed: return retval # C.g:147:3: ( ( declaration )+ a= compound_statement | b= compound_statement ) alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == IDENTIFIER or LA6_0 == 26 or (29 <= LA6_0 <= 42) or (45 <= LA6_0 <= 46) or (48 <= LA6_0 <= 61)) : alt6 = 1 elif (LA6_0 == 43) : alt6 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("147:3: ( ( declaration )+ a= compound_statement | b= compound_statement )", 6, 0, self.input) raise nvae if alt6 == 1: # C.g:147:5: ( declaration )+ a= compound_statement # C.g:147:5: ( declaration )+ cnt5 = 0 while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == IDENTIFIER or LA5_0 == 26 or (29 <= LA5_0 <= 42) or (45 <= LA5_0 <= 46) or (48 <= LA5_0 <= 61)) : alt5 = 1 if alt5 == 1: # C.g:0:0: declaration self.following.append(self.FOLLOW_declaration_in_function_definition166) self.declaration() self.following.pop() if self.failed: return retval else: if cnt5 >= 1: break #loop5 if self.backtracking > 0: self.failed = True return retval eee = EarlyExitException(5, self.input) raise eee cnt5 += 1 self.following.append(self.FOLLOW_compound_statement_in_function_definition171) a = self.compound_statement() self.following.pop() if self.failed: return retval elif alt6 == 2: # C.g:148:5: b= compound_statement self.following.append(self.FOLLOW_compound_statement_in_function_definition180) b = self.compound_statement() self.following.pop() if self.failed: return retval if self.backtracking == 0: if d != None: self.function_definition_stack[-1].ModifierText = self.input.toString(d.start,d.stop) else: self.function_definition_stack[-1].ModifierText = '' self.function_definition_stack[-1].DeclText = self.input.toString(declarator1.start,declarator1.stop) self.function_definition_stack[-1].DeclLine = declarator1.start.line self.function_definition_stack[-1].DeclOffset = declarator1.start.charPositionInLine if a != None: self.function_definition_stack[-1].LBLine = a.start.line self.function_definition_stack[-1].LBOffset = a.start.charPositionInLine else: self.function_definition_stack[-1].LBLine = b.start.line self.function_definition_stack[-1].LBOffset = b.start.charPositionInLine retval.stop = self.input.LT(-1) if self.backtracking == 0: self.StoreFunctionDefinition(retval.start.line, retval.start.charPositionInLine, retval.stop.line, retval.stop.charPositionInLine, self.function_definition_stack[-1].ModifierText, self.function_definition_stack[-1].DeclText, self.function_definition_stack[-1].LBLine, self.function_definition_stack[-1].LBOffset, self.function_definition_stack[-1].DeclLine, self.function_definition_stack[-1].DeclOffset) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 3, function_definition_StartIndex) self.function_definition_stack.pop() pass return retval # $ANTLR end function_definition # $ANTLR start declaration # C.g:166:1: declaration : (a= 'typedef' (b= declaration_specifiers )? c= init_declarator_list d= ';' | s= declaration_specifiers (t= init_declarator_list )? e= ';' ); def declaration(self, ): declaration_StartIndex = self.input.index() a = None d = None e = None b = None c = None s = None t = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 4): return # C.g:167:2: (a= 'typedef' (b= declaration_specifiers )? c= init_declarator_list d= ';' | s= declaration_specifiers (t= init_declarator_list )? e= ';' ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == 26) : alt9 = 1 elif (LA9_0 == IDENTIFIER or (29 <= LA9_0 <= 42) or (45 <= LA9_0 <= 46) or (48 <= LA9_0 <= 61)) : alt9 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("166:1: declaration : (a= 'typedef' (b= declaration_specifiers )? c= init_declarator_list d= ';' | s= declaration_specifiers (t= init_declarator_list )? e= ';' );", 9, 0, self.input) raise nvae if alt9 == 1: # C.g:167:4: a= 'typedef' (b= declaration_specifiers )? c= init_declarator_list d= ';' a = self.input.LT(1) self.match(self.input, 26, self.FOLLOW_26_in_declaration203) if self.failed: return # C.g:167:17: (b= declaration_specifiers )? alt7 = 2 LA7 = self.input.LA(1) if LA7 == 29 or LA7 == 30 or LA7 == 31 or LA7 == 32 or LA7 == 33 or LA7 == 34 or LA7 == 35 or LA7 == 36 or LA7 == 37 or LA7 == 38 or LA7 == 39 or LA7 == 40 or LA7 == 41 or LA7 == 42 or LA7 == 45 or LA7 == 46 or LA7 == 48 or LA7 == 49 or LA7 == 50 or LA7 == 51 or LA7 == 52 or LA7 == 53 or LA7 == 54 or LA7 == 55 or LA7 == 56 or LA7 == 57 or LA7 == 61: alt7 = 1 elif LA7 == IDENTIFIER: LA7_13 = self.input.LA(2) if (LA7_13 == 62) : LA7_21 = self.input.LA(3) if (self.synpred10()) : alt7 = 1 elif (LA7_13 == IDENTIFIER or (29 <= LA7_13 <= 42) or (45 <= LA7_13 <= 46) or (48 <= LA7_13 <= 61) or LA7_13 == 66) : alt7 = 1 elif LA7 == 58: LA7_14 = self.input.LA(2) if (self.synpred10()) : alt7 = 1 elif LA7 == 59: LA7_16 = self.input.LA(2) if (self.synpred10()) : alt7 = 1 elif LA7 == 60: LA7_17 = self.input.LA(2) if (self.synpred10()) : alt7 = 1 if alt7 == 1: # C.g:0:0: b= declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_declaration207) b = self.declaration_specifiers() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_init_declarator_list_in_declaration216) c = self.init_declarator_list() self.following.pop() if self.failed: return d = self.input.LT(1) self.match(self.input, 25, self.FOLLOW_25_in_declaration220) if self.failed: return if self.backtracking == 0: if b != None: self.StoreTypedefDefinition(a.line, a.charPositionInLine, d.line, d.charPositionInLine, self.input.toString(b.start,b.stop), self.input.toString(c.start,c.stop)) else: self.StoreTypedefDefinition(a.line, a.charPositionInLine, d.line, d.charPositionInLine, '', self.input.toString(c.start,c.stop)) elif alt9 == 2: # C.g:175:4: s= declaration_specifiers (t= init_declarator_list )? e= ';' self.following.append(self.FOLLOW_declaration_specifiers_in_declaration234) s = self.declaration_specifiers() self.following.pop() if self.failed: return # C.g:175:30: (t= init_declarator_list )? alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == IDENTIFIER or (58 <= LA8_0 <= 60) or LA8_0 == 62 or LA8_0 == 66) : alt8 = 1 if alt8 == 1: # C.g:0:0: t= init_declarator_list self.following.append(self.FOLLOW_init_declarator_list_in_declaration238) t = self.init_declarator_list() self.following.pop() if self.failed: return e = self.input.LT(1) self.match(self.input, 25, self.FOLLOW_25_in_declaration243) if self.failed: return if self.backtracking == 0: if t != None: self.StoreVariableDeclaration(s.start.line, s.start.charPositionInLine, t.start.line, t.start.charPositionInLine, self.input.toString(s.start,s.stop), self.input.toString(t.start,t.stop)) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 4, declaration_StartIndex) pass return # $ANTLR end declaration class declaration_specifiers_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start declaration_specifiers # C.g:182:1: declaration_specifiers : ( storage_class_specifier | type_specifier | type_qualifier )+ ; def declaration_specifiers(self, ): retval = self.declaration_specifiers_return() retval.start = self.input.LT(1) declaration_specifiers_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 5): return retval # C.g:183:2: ( ( storage_class_specifier | type_specifier | type_qualifier )+ ) # C.g:183:6: ( storage_class_specifier | type_specifier | type_qualifier )+ # C.g:183:6: ( storage_class_specifier | type_specifier | type_qualifier )+ cnt10 = 0 while True: #loop10 alt10 = 4 LA10 = self.input.LA(1) if LA10 == 58: LA10_2 = self.input.LA(2) if (self.synpred15()) : alt10 = 3 elif LA10 == 59: LA10_3 = self.input.LA(2) if (self.synpred15()) : alt10 = 3 elif LA10 == 60: LA10_4 = self.input.LA(2) if (self.synpred15()) : alt10 = 3 elif LA10 == IDENTIFIER: LA10_5 = self.input.LA(2) if (self.synpred14()) : alt10 = 2 elif LA10 == 53: LA10_9 = self.input.LA(2) if (self.synpred15()) : alt10 = 3 elif LA10 == 29 or LA10 == 30 or LA10 == 31 or LA10 == 32 or LA10 == 33: alt10 = 1 elif LA10 == 34 or LA10 == 35 or LA10 == 36 or LA10 == 37 or LA10 == 38 or LA10 == 39 or LA10 == 40 or LA10 == 41 or LA10 == 42 or LA10 == 45 or LA10 == 46 or LA10 == 48: alt10 = 2 elif LA10 == 49 or LA10 == 50 or LA10 == 51 or LA10 == 52 or LA10 == 54 or LA10 == 55 or LA10 == 56 or LA10 == 57 or LA10 == 61: alt10 = 3 if alt10 == 1: # C.g:183:10: storage_class_specifier self.following.append(self.FOLLOW_storage_class_specifier_in_declaration_specifiers264) self.storage_class_specifier() self.following.pop() if self.failed: return retval elif alt10 == 2: # C.g:184:7: type_specifier self.following.append(self.FOLLOW_type_specifier_in_declaration_specifiers272) self.type_specifier() self.following.pop() if self.failed: return retval elif alt10 == 3: # C.g:185:13: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_declaration_specifiers286) self.type_qualifier() self.following.pop() if self.failed: return retval else: if cnt10 >= 1: break #loop10 if self.backtracking > 0: self.failed = True return retval eee = EarlyExitException(10, self.input) raise eee cnt10 += 1 retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 5, declaration_specifiers_StartIndex) pass return retval # $ANTLR end declaration_specifiers class init_declarator_list_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start init_declarator_list # C.g:189:1: init_declarator_list : init_declarator ( ',' init_declarator )* ; def init_declarator_list(self, ): retval = self.init_declarator_list_return() retval.start = self.input.LT(1) init_declarator_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 6): return retval # C.g:190:2: ( init_declarator ( ',' init_declarator )* ) # C.g:190:4: init_declarator ( ',' init_declarator )* self.following.append(self.FOLLOW_init_declarator_in_init_declarator_list308) self.init_declarator() self.following.pop() if self.failed: return retval # C.g:190:20: ( ',' init_declarator )* while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == 27) : alt11 = 1 if alt11 == 1: # C.g:190:21: ',' init_declarator self.match(self.input, 27, self.FOLLOW_27_in_init_declarator_list311) if self.failed: return retval self.following.append(self.FOLLOW_init_declarator_in_init_declarator_list313) self.init_declarator() self.following.pop() if self.failed: return retval else: break #loop11 retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 6, init_declarator_list_StartIndex) pass return retval # $ANTLR end init_declarator_list # $ANTLR start init_declarator # C.g:193:1: init_declarator : declarator ( '=' initializer )? ; def init_declarator(self, ): init_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 7): return # C.g:194:2: ( declarator ( '=' initializer )? ) # C.g:194:4: declarator ( '=' initializer )? self.following.append(self.FOLLOW_declarator_in_init_declarator326) self.declarator() self.following.pop() if self.failed: return # C.g:194:15: ( '=' initializer )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == 28) : alt12 = 1 if alt12 == 1: # C.g:194:16: '=' initializer self.match(self.input, 28, self.FOLLOW_28_in_init_declarator329) if self.failed: return self.following.append(self.FOLLOW_initializer_in_init_declarator331) self.initializer() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 7, init_declarator_StartIndex) pass return # $ANTLR end init_declarator # $ANTLR start storage_class_specifier # C.g:197:1: storage_class_specifier : ( 'extern' | 'static' | 'auto' | 'register' | 'STATIC' ); def storage_class_specifier(self, ): storage_class_specifier_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 8): return # C.g:198:2: ( 'extern' | 'static' | 'auto' | 'register' | 'STATIC' ) # C.g: if (29 <= self.input.LA(1) <= 33): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_storage_class_specifier0 ) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 8, storage_class_specifier_StartIndex) pass return # $ANTLR end storage_class_specifier # $ANTLR start type_specifier # C.g:205:1: type_specifier : ( 'void' | 'char' | 'short' | 'int' | 'long' | 'float' | 'double' | 'signed' | 'unsigned' | s= struct_or_union_specifier | e= enum_specifier | ( IDENTIFIER ( type_qualifier )* declarator )=> type_id ); def type_specifier(self, ): type_specifier_StartIndex = self.input.index() s = None e = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 9): return # C.g:206:2: ( 'void' | 'char' | 'short' | 'int' | 'long' | 'float' | 'double' | 'signed' | 'unsigned' | s= struct_or_union_specifier | e= enum_specifier | ( IDENTIFIER ( type_qualifier )* declarator )=> type_id ) alt13 = 12 LA13_0 = self.input.LA(1) if (LA13_0 == 34) : alt13 = 1 elif (LA13_0 == 35) : alt13 = 2 elif (LA13_0 == 36) : alt13 = 3 elif (LA13_0 == 37) : alt13 = 4 elif (LA13_0 == 38) : alt13 = 5 elif (LA13_0 == 39) : alt13 = 6 elif (LA13_0 == 40) : alt13 = 7 elif (LA13_0 == 41) : alt13 = 8 elif (LA13_0 == 42) : alt13 = 9 elif ((45 <= LA13_0 <= 46)) : alt13 = 10 elif (LA13_0 == 48) : alt13 = 11 elif (LA13_0 == IDENTIFIER) and (self.synpred34()): alt13 = 12 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("205:1: type_specifier : ( 'void' | 'char' | 'short' | 'int' | 'long' | 'float' | 'double' | 'signed' | 'unsigned' | s= struct_or_union_specifier | e= enum_specifier | ( IDENTIFIER ( type_qualifier )* declarator )=> type_id );", 13, 0, self.input) raise nvae if alt13 == 1: # C.g:206:4: 'void' self.match(self.input, 34, self.FOLLOW_34_in_type_specifier376) if self.failed: return elif alt13 == 2: # C.g:207:4: 'char' self.match(self.input, 35, self.FOLLOW_35_in_type_specifier381) if self.failed: return elif alt13 == 3: # C.g:208:4: 'short' self.match(self.input, 36, self.FOLLOW_36_in_type_specifier386) if self.failed: return elif alt13 == 4: # C.g:209:4: 'int' self.match(self.input, 37, self.FOLLOW_37_in_type_specifier391) if self.failed: return elif alt13 == 5: # C.g:210:4: 'long' self.match(self.input, 38, self.FOLLOW_38_in_type_specifier396) if self.failed: return elif alt13 == 6: # C.g:211:4: 'float' self.match(self.input, 39, self.FOLLOW_39_in_type_specifier401) if self.failed: return elif alt13 == 7: # C.g:212:4: 'double' self.match(self.input, 40, self.FOLLOW_40_in_type_specifier406) if self.failed: return elif alt13 == 8: # C.g:213:4: 'signed' self.match(self.input, 41, self.FOLLOW_41_in_type_specifier411) if self.failed: return elif alt13 == 9: # C.g:214:4: 'unsigned' self.match(self.input, 42, self.FOLLOW_42_in_type_specifier416) if self.failed: return elif alt13 == 10: # C.g:215:4: s= struct_or_union_specifier self.following.append(self.FOLLOW_struct_or_union_specifier_in_type_specifier423) s = self.struct_or_union_specifier() self.following.pop() if self.failed: return if self.backtracking == 0: if s.stop != None: self.StoreStructUnionDefinition(s.start.line, s.start.charPositionInLine, s.stop.line, s.stop.charPositionInLine, self.input.toString(s.start,s.stop)) elif alt13 == 11: # C.g:220:4: e= enum_specifier self.following.append(self.FOLLOW_enum_specifier_in_type_specifier433) e = self.enum_specifier() self.following.pop() if self.failed: return if self.backtracking == 0: if e.stop != None: self.StoreEnumerationDefinition(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start,e.stop)) elif alt13 == 12: # C.g:225:4: ( IDENTIFIER ( type_qualifier )* declarator )=> type_id self.following.append(self.FOLLOW_type_id_in_type_specifier451) self.type_id() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 9, type_specifier_StartIndex) pass return # $ANTLR end type_specifier # $ANTLR start type_id # C.g:228:1: type_id : IDENTIFIER ; def type_id(self, ): type_id_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 10): return # C.g:229:5: ( IDENTIFIER ) # C.g:229:9: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_type_id467) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 10, type_id_StartIndex) pass return # $ANTLR end type_id class struct_or_union_specifier_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start struct_or_union_specifier # C.g:233:1: struct_or_union_specifier options {k=3; } : ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER ); def struct_or_union_specifier(self, ): retval = self.struct_or_union_specifier_return() retval.start = self.input.LT(1) struct_or_union_specifier_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 11): return retval # C.g:235:2: ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER ) alt15 = 2 LA15_0 = self.input.LA(1) if ((45 <= LA15_0 <= 46)) : LA15_1 = self.input.LA(2) if (LA15_1 == IDENTIFIER) : LA15_2 = self.input.LA(3) if (LA15_2 == 43) : alt15 = 1 elif (LA15_2 == EOF or LA15_2 == IDENTIFIER or LA15_2 == 25 or LA15_2 == 27 or (29 <= LA15_2 <= 42) or (45 <= LA15_2 <= 64) or LA15_2 == 66) : alt15 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("233:1: struct_or_union_specifier options {k=3; } : ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER );", 15, 2, self.input) raise nvae elif (LA15_1 == 43) : alt15 = 1 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("233:1: struct_or_union_specifier options {k=3; } : ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER );", 15, 1, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("233:1: struct_or_union_specifier options {k=3; } : ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER );", 15, 0, self.input) raise nvae if alt15 == 1: # C.g:235:4: struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' self.following.append(self.FOLLOW_struct_or_union_in_struct_or_union_specifier494) self.struct_or_union() self.following.pop() if self.failed: return retval # C.g:235:20: ( IDENTIFIER )? alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == IDENTIFIER) : alt14 = 1 if alt14 == 1: # C.g:0:0: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_struct_or_union_specifier496) if self.failed: return retval self.match(self.input, 43, self.FOLLOW_43_in_struct_or_union_specifier499) if self.failed: return retval self.following.append(self.FOLLOW_struct_declaration_list_in_struct_or_union_specifier501) self.struct_declaration_list() self.following.pop() if self.failed: return retval self.match(self.input, 44, self.FOLLOW_44_in_struct_or_union_specifier503) if self.failed: return retval elif alt15 == 2: # C.g:236:4: struct_or_union IDENTIFIER self.following.append(self.FOLLOW_struct_or_union_in_struct_or_union_specifier508) self.struct_or_union() self.following.pop() if self.failed: return retval self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_struct_or_union_specifier510) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 11, struct_or_union_specifier_StartIndex) pass return retval # $ANTLR end struct_or_union_specifier # $ANTLR start struct_or_union # C.g:239:1: struct_or_union : ( 'struct' | 'union' ); def struct_or_union(self, ): struct_or_union_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 12): return # C.g:240:2: ( 'struct' | 'union' ) # C.g: if (45 <= self.input.LA(1) <= 46): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_struct_or_union0 ) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 12, struct_or_union_StartIndex) pass return # $ANTLR end struct_or_union # $ANTLR start struct_declaration_list # C.g:244:1: struct_declaration_list : ( struct_declaration )+ ; def struct_declaration_list(self, ): struct_declaration_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 13): return # C.g:245:2: ( ( struct_declaration )+ ) # C.g:245:4: ( struct_declaration )+ # C.g:245:4: ( struct_declaration )+ cnt16 = 0 while True: #loop16 alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == IDENTIFIER or (34 <= LA16_0 <= 42) or (45 <= LA16_0 <= 46) or (48 <= LA16_0 <= 61)) : alt16 = 1 if alt16 == 1: # C.g:0:0: struct_declaration self.following.append(self.FOLLOW_struct_declaration_in_struct_declaration_list537) self.struct_declaration() self.following.pop() if self.failed: return else: if cnt16 >= 1: break #loop16 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(16, self.input) raise eee cnt16 += 1 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 13, struct_declaration_list_StartIndex) pass return # $ANTLR end struct_declaration_list # $ANTLR start struct_declaration # C.g:248:1: struct_declaration : specifier_qualifier_list struct_declarator_list ';' ; def struct_declaration(self, ): struct_declaration_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 14): return # C.g:249:2: ( specifier_qualifier_list struct_declarator_list ';' ) # C.g:249:4: specifier_qualifier_list struct_declarator_list ';' self.following.append(self.FOLLOW_specifier_qualifier_list_in_struct_declaration549) self.specifier_qualifier_list() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_struct_declarator_list_in_struct_declaration551) self.struct_declarator_list() self.following.pop() if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_struct_declaration553) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 14, struct_declaration_StartIndex) pass return # $ANTLR end struct_declaration # $ANTLR start specifier_qualifier_list # C.g:252:1: specifier_qualifier_list : ( type_qualifier | type_specifier )+ ; def specifier_qualifier_list(self, ): specifier_qualifier_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 15): return # C.g:253:2: ( ( type_qualifier | type_specifier )+ ) # C.g:253:4: ( type_qualifier | type_specifier )+ # C.g:253:4: ( type_qualifier | type_specifier )+ cnt17 = 0 while True: #loop17 alt17 = 3 LA17 = self.input.LA(1) if LA17 == 58: LA17_2 = self.input.LA(2) if (self.synpred39()) : alt17 = 1 elif LA17 == 59: LA17_3 = self.input.LA(2) if (self.synpred39()) : alt17 = 1 elif LA17 == 60: LA17_4 = self.input.LA(2) if (self.synpred39()) : alt17 = 1 elif LA17 == IDENTIFIER: LA17 = self.input.LA(2) if LA17 == EOF or LA17 == IDENTIFIER or LA17 == 34 or LA17 == 35 or LA17 == 36 or LA17 == 37 or LA17 == 38 or LA17 == 39 or LA17 == 40 or LA17 == 41 or LA17 == 42 or LA17 == 45 or LA17 == 46 or LA17 == 48 or LA17 == 49 or LA17 == 50 or LA17 == 51 or LA17 == 52 or LA17 == 53 or LA17 == 54 or LA17 == 55 or LA17 == 56 or LA17 == 57 or LA17 == 58 or LA17 == 59 or LA17 == 60 or LA17 == 61 or LA17 == 63 or LA17 == 66: alt17 = 2 elif LA17 == 62: LA17_94 = self.input.LA(3) if (self.synpred40()) : alt17 = 2 elif LA17 == 47: LA17_95 = self.input.LA(3) if (self.synpred40()) : alt17 = 2 elif LA17 == 64: LA17_96 = self.input.LA(3) if (self.synpred40()) : alt17 = 2 elif LA17 == 49 or LA17 == 50 or LA17 == 51 or LA17 == 52 or LA17 == 53 or LA17 == 54 or LA17 == 55 or LA17 == 56 or LA17 == 57 or LA17 == 61: alt17 = 1 elif LA17 == 34 or LA17 == 35 or LA17 == 36 or LA17 == 37 or LA17 == 38 or LA17 == 39 or LA17 == 40 or LA17 == 41 or LA17 == 42 or LA17 == 45 or LA17 == 46 or LA17 == 48: alt17 = 2 if alt17 == 1: # C.g:253:6: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_specifier_qualifier_list566) self.type_qualifier() self.following.pop() if self.failed: return elif alt17 == 2: # C.g:253:23: type_specifier self.following.append(self.FOLLOW_type_specifier_in_specifier_qualifier_list570) self.type_specifier() self.following.pop() if self.failed: return else: if cnt17 >= 1: break #loop17 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(17, self.input) raise eee cnt17 += 1 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 15, specifier_qualifier_list_StartIndex) pass return # $ANTLR end specifier_qualifier_list # $ANTLR start struct_declarator_list # C.g:256:1: struct_declarator_list : struct_declarator ( ',' struct_declarator )* ; def struct_declarator_list(self, ): struct_declarator_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 16): return # C.g:257:2: ( struct_declarator ( ',' struct_declarator )* ) # C.g:257:4: struct_declarator ( ',' struct_declarator )* self.following.append(self.FOLLOW_struct_declarator_in_struct_declarator_list584) self.struct_declarator() self.following.pop() if self.failed: return # C.g:257:22: ( ',' struct_declarator )* while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == 27) : alt18 = 1 if alt18 == 1: # C.g:257:23: ',' struct_declarator self.match(self.input, 27, self.FOLLOW_27_in_struct_declarator_list587) if self.failed: return self.following.append(self.FOLLOW_struct_declarator_in_struct_declarator_list589) self.struct_declarator() self.following.pop() if self.failed: return else: break #loop18 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 16, struct_declarator_list_StartIndex) pass return # $ANTLR end struct_declarator_list # $ANTLR start struct_declarator # C.g:260:1: struct_declarator : ( declarator ( ':' constant_expression )? | ':' constant_expression ); def struct_declarator(self, ): struct_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 17): return # C.g:261:2: ( declarator ( ':' constant_expression )? | ':' constant_expression ) alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == IDENTIFIER or (58 <= LA20_0 <= 60) or LA20_0 == 62 or LA20_0 == 66) : alt20 = 1 elif (LA20_0 == 47) : alt20 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("260:1: struct_declarator : ( declarator ( ':' constant_expression )? | ':' constant_expression );", 20, 0, self.input) raise nvae if alt20 == 1: # C.g:261:4: declarator ( ':' constant_expression )? self.following.append(self.FOLLOW_declarator_in_struct_declarator602) self.declarator() self.following.pop() if self.failed: return # C.g:261:15: ( ':' constant_expression )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == 47) : alt19 = 1 if alt19 == 1: # C.g:261:16: ':' constant_expression self.match(self.input, 47, self.FOLLOW_47_in_struct_declarator605) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_struct_declarator607) self.constant_expression() self.following.pop() if self.failed: return elif alt20 == 2: # C.g:262:4: ':' constant_expression self.match(self.input, 47, self.FOLLOW_47_in_struct_declarator614) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_struct_declarator616) self.constant_expression() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 17, struct_declarator_StartIndex) pass return # $ANTLR end struct_declarator class enum_specifier_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start enum_specifier # C.g:265:1: enum_specifier options {k=3; } : ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER ); def enum_specifier(self, ): retval = self.enum_specifier_return() retval.start = self.input.LT(1) enum_specifier_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 18): return retval # C.g:267:2: ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER ) alt23 = 3 LA23_0 = self.input.LA(1) if (LA23_0 == 48) : LA23_1 = self.input.LA(2) if (LA23_1 == IDENTIFIER) : LA23_2 = self.input.LA(3) if (LA23_2 == 43) : alt23 = 2 elif (LA23_2 == EOF or LA23_2 == IDENTIFIER or LA23_2 == 25 or LA23_2 == 27 or (29 <= LA23_2 <= 42) or (45 <= LA23_2 <= 64) or LA23_2 == 66) : alt23 = 3 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("265:1: enum_specifier options {k=3; } : ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER );", 23, 2, self.input) raise nvae elif (LA23_1 == 43) : alt23 = 1 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("265:1: enum_specifier options {k=3; } : ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER );", 23, 1, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("265:1: enum_specifier options {k=3; } : ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER );", 23, 0, self.input) raise nvae if alt23 == 1: # C.g:267:4: 'enum' '{' enumerator_list ( ',' )? '}' self.match(self.input, 48, self.FOLLOW_48_in_enum_specifier634) if self.failed: return retval self.match(self.input, 43, self.FOLLOW_43_in_enum_specifier636) if self.failed: return retval self.following.append(self.FOLLOW_enumerator_list_in_enum_specifier638) self.enumerator_list() self.following.pop() if self.failed: return retval # C.g:267:31: ( ',' )? alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == 27) : alt21 = 1 if alt21 == 1: # C.g:0:0: ',' self.match(self.input, 27, self.FOLLOW_27_in_enum_specifier640) if self.failed: return retval self.match(self.input, 44, self.FOLLOW_44_in_enum_specifier643) if self.failed: return retval elif alt23 == 2: # C.g:268:4: 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' self.match(self.input, 48, self.FOLLOW_48_in_enum_specifier648) if self.failed: return retval self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enum_specifier650) if self.failed: return retval self.match(self.input, 43, self.FOLLOW_43_in_enum_specifier652) if self.failed: return retval self.following.append(self.FOLLOW_enumerator_list_in_enum_specifier654) self.enumerator_list() self.following.pop() if self.failed: return retval # C.g:268:42: ( ',' )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == 27) : alt22 = 1 if alt22 == 1: # C.g:0:0: ',' self.match(self.input, 27, self.FOLLOW_27_in_enum_specifier656) if self.failed: return retval self.match(self.input, 44, self.FOLLOW_44_in_enum_specifier659) if self.failed: return retval elif alt23 == 3: # C.g:269:4: 'enum' IDENTIFIER self.match(self.input, 48, self.FOLLOW_48_in_enum_specifier664) if self.failed: return retval self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enum_specifier666) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 18, enum_specifier_StartIndex) pass return retval # $ANTLR end enum_specifier # $ANTLR start enumerator_list # C.g:272:1: enumerator_list : enumerator ( ',' enumerator )* ; def enumerator_list(self, ): enumerator_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 19): return # C.g:273:2: ( enumerator ( ',' enumerator )* ) # C.g:273:4: enumerator ( ',' enumerator )* self.following.append(self.FOLLOW_enumerator_in_enumerator_list677) self.enumerator() self.following.pop() if self.failed: return # C.g:273:15: ( ',' enumerator )* while True: #loop24 alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == 27) : LA24_1 = self.input.LA(2) if (LA24_1 == IDENTIFIER) : alt24 = 1 if alt24 == 1: # C.g:273:16: ',' enumerator self.match(self.input, 27, self.FOLLOW_27_in_enumerator_list680) if self.failed: return self.following.append(self.FOLLOW_enumerator_in_enumerator_list682) self.enumerator() self.following.pop() if self.failed: return else: break #loop24 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 19, enumerator_list_StartIndex) pass return # $ANTLR end enumerator_list # $ANTLR start enumerator # C.g:276:1: enumerator : IDENTIFIER ( '=' constant_expression )? ; def enumerator(self, ): enumerator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 20): return # C.g:277:2: ( IDENTIFIER ( '=' constant_expression )? ) # C.g:277:4: IDENTIFIER ( '=' constant_expression )? self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enumerator695) if self.failed: return # C.g:277:15: ( '=' constant_expression )? alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == 28) : alt25 = 1 if alt25 == 1: # C.g:277:16: '=' constant_expression self.match(self.input, 28, self.FOLLOW_28_in_enumerator698) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_enumerator700) self.constant_expression() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 20, enumerator_StartIndex) pass return # $ANTLR end enumerator # $ANTLR start type_qualifier # C.g:280:1: type_qualifier : ( 'const' | 'volatile' | 'IN' | 'OUT' | 'OPTIONAL' | 'CONST' | 'UNALIGNED' | 'VOLATILE' | 'GLOBAL_REMOVE_IF_UNREFERENCED' | 'EFIAPI' | 'EFI_BOOTSERVICE' | 'EFI_RUNTIMESERVICE' | 'PACKED' ); def type_qualifier(self, ): type_qualifier_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 21): return # C.g:281:2: ( 'const' | 'volatile' | 'IN' | 'OUT' | 'OPTIONAL' | 'CONST' | 'UNALIGNED' | 'VOLATILE' | 'GLOBAL_REMOVE_IF_UNREFERENCED' | 'EFIAPI' | 'EFI_BOOTSERVICE' | 'EFI_RUNTIMESERVICE' | 'PACKED' ) # C.g: if (49 <= self.input.LA(1) <= 61): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_type_qualifier0 ) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 21, type_qualifier_StartIndex) pass return # $ANTLR end type_qualifier class declarator_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start declarator # C.g:296:1: declarator : ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator | pointer ); def declarator(self, ): retval = self.declarator_return() retval.start = self.input.LT(1) declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 22): return retval # C.g:297:2: ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator | pointer ) alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == 66) : LA30_1 = self.input.LA(2) if (self.synpred66()) : alt30 = 1 elif (True) : alt30 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("296:1: declarator : ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator | pointer );", 30, 1, self.input) raise nvae elif (LA30_0 == IDENTIFIER or (58 <= LA30_0 <= 60) or LA30_0 == 62) : alt30 = 1 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("296:1: declarator : ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator | pointer );", 30, 0, self.input) raise nvae if alt30 == 1: # C.g:297:4: ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator # C.g:297:4: ( pointer )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == 66) : alt26 = 1 if alt26 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_declarator784) self.pointer() self.following.pop() if self.failed: return retval # C.g:297:13: ( 'EFIAPI' )? alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == 58) : alt27 = 1 if alt27 == 1: # C.g:297:14: 'EFIAPI' self.match(self.input, 58, self.FOLLOW_58_in_declarator788) if self.failed: return retval # C.g:297:25: ( 'EFI_BOOTSERVICE' )? alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == 59) : alt28 = 1 if alt28 == 1: # C.g:297:26: 'EFI_BOOTSERVICE' self.match(self.input, 59, self.FOLLOW_59_in_declarator793) if self.failed: return retval # C.g:297:46: ( 'EFI_RUNTIMESERVICE' )? alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == 60) : alt29 = 1 if alt29 == 1: # C.g:297:47: 'EFI_RUNTIMESERVICE' self.match(self.input, 60, self.FOLLOW_60_in_declarator798) if self.failed: return retval self.following.append(self.FOLLOW_direct_declarator_in_declarator802) self.direct_declarator() self.following.pop() if self.failed: return retval elif alt30 == 2: # C.g:299:4: pointer self.following.append(self.FOLLOW_pointer_in_declarator808) self.pointer() self.following.pop() if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 22, declarator_StartIndex) pass return retval # $ANTLR end declarator # $ANTLR start direct_declarator # C.g:302:1: direct_declarator : ( IDENTIFIER ( declarator_suffix )* | '(' ( 'EFIAPI' )? declarator ')' ( declarator_suffix )+ ); def direct_declarator(self, ): direct_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 23): return # C.g:303:2: ( IDENTIFIER ( declarator_suffix )* | '(' ( 'EFIAPI' )? declarator ')' ( declarator_suffix )+ ) alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == IDENTIFIER) : alt34 = 1 elif (LA34_0 == 62) : alt34 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("302:1: direct_declarator : ( IDENTIFIER ( declarator_suffix )* | '(' ( 'EFIAPI' )? declarator ')' ( declarator_suffix )+ );", 34, 0, self.input) raise nvae if alt34 == 1: # C.g:303:4: IDENTIFIER ( declarator_suffix )* self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_direct_declarator819) if self.failed: return # C.g:303:15: ( declarator_suffix )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == 62) : LA31 = self.input.LA(2) if LA31 == 63: LA31_30 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 58: LA31_31 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 66: LA31_32 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 59: LA31_33 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 60: LA31_34 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == IDENTIFIER: LA31_35 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 29 or LA31 == 30 or LA31 == 31 or LA31 == 32 or LA31 == 33: LA31_37 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 34: LA31_38 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 35: LA31_39 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 36: LA31_40 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 37: LA31_41 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 38: LA31_42 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 39: LA31_43 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 40: LA31_44 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 41: LA31_45 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 42: LA31_46 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 45 or LA31 == 46: LA31_47 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 48: LA31_48 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 49 or LA31 == 50 or LA31 == 51 or LA31 == 52 or LA31 == 53 or LA31 == 54 or LA31 == 55 or LA31 == 56 or LA31 == 57 or LA31 == 61: LA31_49 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif (LA31_0 == 64) : LA31 = self.input.LA(2) if LA31 == 65: LA31_51 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 62: LA31_52 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == IDENTIFIER: LA31_53 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == HEX_LITERAL: LA31_54 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == OCTAL_LITERAL: LA31_55 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == DECIMAL_LITERAL: LA31_56 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == CHARACTER_LITERAL: LA31_57 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == STRING_LITERAL: LA31_58 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == FLOATING_POINT_LITERAL: LA31_59 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 72: LA31_60 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 73: LA31_61 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 66 or LA31 == 68 or LA31 == 69 or LA31 == 77 or LA31 == 78 or LA31 == 79: LA31_62 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 74: LA31_63 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 if alt31 == 1: # C.g:0:0: declarator_suffix self.following.append(self.FOLLOW_declarator_suffix_in_direct_declarator821) self.declarator_suffix() self.following.pop() if self.failed: return else: break #loop31 elif alt34 == 2: # C.g:304:4: '(' ( 'EFIAPI' )? declarator ')' ( declarator_suffix )+ self.match(self.input, 62, self.FOLLOW_62_in_direct_declarator827) if self.failed: return # C.g:304:8: ( 'EFIAPI' )? alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == 58) : LA32_1 = self.input.LA(2) if (self.synpred69()) : alt32 = 1 if alt32 == 1: # C.g:304:9: 'EFIAPI' self.match(self.input, 58, self.FOLLOW_58_in_direct_declarator830) if self.failed: return self.following.append(self.FOLLOW_declarator_in_direct_declarator834) self.declarator() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_direct_declarator836) if self.failed: return # C.g:304:35: ( declarator_suffix )+ cnt33 = 0 while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == 62) : LA33 = self.input.LA(2) if LA33 == 63: LA33_30 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 58: LA33_31 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 66: LA33_32 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 59: LA33_33 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 60: LA33_34 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == IDENTIFIER: LA33_35 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 29 or LA33 == 30 or LA33 == 31 or LA33 == 32 or LA33 == 33: LA33_37 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 34: LA33_38 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 35: LA33_39 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 36: LA33_40 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 37: LA33_41 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 38: LA33_42 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 39: LA33_43 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 40: LA33_44 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 41: LA33_45 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 42: LA33_46 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 45 or LA33 == 46: LA33_47 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 48: LA33_48 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 49 or LA33 == 50 or LA33 == 51 or LA33 == 52 or LA33 == 53 or LA33 == 54 or LA33 == 55 or LA33 == 56 or LA33 == 57 or LA33 == 61: LA33_49 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif (LA33_0 == 64) : LA33 = self.input.LA(2) if LA33 == 65: LA33_51 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 62: LA33_52 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == IDENTIFIER: LA33_53 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == HEX_LITERAL: LA33_54 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == OCTAL_LITERAL: LA33_55 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == DECIMAL_LITERAL: LA33_56 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == CHARACTER_LITERAL: LA33_57 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == STRING_LITERAL: LA33_58 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == FLOATING_POINT_LITERAL: LA33_59 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 72: LA33_60 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 73: LA33_61 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 66 or LA33 == 68 or LA33 == 69 or LA33 == 77 or LA33 == 78 or LA33 == 79: LA33_62 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 74: LA33_63 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 if alt33 == 1: # C.g:0:0: declarator_suffix self.following.append(self.FOLLOW_declarator_suffix_in_direct_declarator838) self.declarator_suffix() self.following.pop() if self.failed: return else: if cnt33 >= 1: break #loop33 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(33, self.input) raise eee cnt33 += 1 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 23, direct_declarator_StartIndex) pass return # $ANTLR end direct_declarator # $ANTLR start declarator_suffix # C.g:307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' ); def declarator_suffix(self, ): declarator_suffix_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 24): return # C.g:308:2: ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' ) alt35 = 5 LA35_0 = self.input.LA(1) if (LA35_0 == 64) : LA35_1 = self.input.LA(2) if (LA35_1 == 65) : alt35 = 2 elif ((IDENTIFIER <= LA35_1 <= FLOATING_POINT_LITERAL) or LA35_1 == 62 or LA35_1 == 66 or (68 <= LA35_1 <= 69) or (72 <= LA35_1 <= 74) or (77 <= LA35_1 <= 79)) : alt35 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' );", 35, 1, self.input) raise nvae elif (LA35_0 == 62) : LA35 = self.input.LA(2) if LA35 == 63: alt35 = 5 elif LA35 == 29 or LA35 == 30 or LA35 == 31 or LA35 == 32 or LA35 == 33 or LA35 == 34 or LA35 == 35 or LA35 == 36 or LA35 == 37 or LA35 == 38 or LA35 == 39 or LA35 == 40 or LA35 == 41 or LA35 == 42 or LA35 == 45 or LA35 == 46 or LA35 == 48 or LA35 == 49 or LA35 == 50 or LA35 == 51 or LA35 == 52 or LA35 == 53 or LA35 == 54 or LA35 == 55 or LA35 == 56 or LA35 == 57 or LA35 == 58 or LA35 == 59 or LA35 == 60 or LA35 == 61 or LA35 == 66: alt35 = 3 elif LA35 == IDENTIFIER: LA35_29 = self.input.LA(3) if (self.synpred73()) : alt35 = 3 elif (self.synpred74()) : alt35 = 4 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' );", 35, 29, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' );", 35, 2, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' );", 35, 0, self.input) raise nvae if alt35 == 1: # C.g:308:6: '[' constant_expression ']' self.match(self.input, 64, self.FOLLOW_64_in_declarator_suffix852) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_declarator_suffix854) self.constant_expression() self.following.pop() if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_declarator_suffix856) if self.failed: return elif alt35 == 2: # C.g:309:9: '[' ']' self.match(self.input, 64, self.FOLLOW_64_in_declarator_suffix866) if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_declarator_suffix868) if self.failed: return elif alt35 == 3: # C.g:310:9: '(' parameter_type_list ')' self.match(self.input, 62, self.FOLLOW_62_in_declarator_suffix878) if self.failed: return self.following.append(self.FOLLOW_parameter_type_list_in_declarator_suffix880) self.parameter_type_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_declarator_suffix882) if self.failed: return elif alt35 == 4: # C.g:311:9: '(' identifier_list ')' self.match(self.input, 62, self.FOLLOW_62_in_declarator_suffix892) if self.failed: return self.following.append(self.FOLLOW_identifier_list_in_declarator_suffix894) self.identifier_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_declarator_suffix896) if self.failed: return elif alt35 == 5: # C.g:312:9: '(' ')' self.match(self.input, 62, self.FOLLOW_62_in_declarator_suffix906) if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_declarator_suffix908) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 24, declarator_suffix_StartIndex) pass return # $ANTLR end declarator_suffix # $ANTLR start pointer # C.g:315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' ); def pointer(self, ): pointer_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 25): return # C.g:316:2: ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' ) alt38 = 3 LA38_0 = self.input.LA(1) if (LA38_0 == 66) : LA38 = self.input.LA(2) if LA38 == 66: LA38_2 = self.input.LA(3) if (self.synpred78()) : alt38 = 2 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 2, self.input) raise nvae elif LA38 == 58: LA38_3 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 3, self.input) raise nvae elif LA38 == 59: LA38_4 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 4, self.input) raise nvae elif LA38 == 60: LA38_5 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 5, self.input) raise nvae elif LA38 == EOF or LA38 == IDENTIFIER or LA38 == 25 or LA38 == 26 or LA38 == 27 or LA38 == 28 or LA38 == 29 or LA38 == 30 or LA38 == 31 or LA38 == 32 or LA38 == 33 or LA38 == 34 or LA38 == 35 or LA38 == 36 or LA38 == 37 or LA38 == 38 or LA38 == 39 or LA38 == 40 or LA38 == 41 or LA38 == 42 or LA38 == 43 or LA38 == 45 or LA38 == 46 or LA38 == 47 or LA38 == 48 or LA38 == 62 or LA38 == 63 or LA38 == 64: alt38 = 3 elif LA38 == 53: LA38_21 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 21, self.input) raise nvae elif LA38 == 49 or LA38 == 50 or LA38 == 51 or LA38 == 52 or LA38 == 54 or LA38 == 55 or LA38 == 56 or LA38 == 57 or LA38 == 61: LA38_29 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 29, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 1, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 0, self.input) raise nvae if alt38 == 1: # C.g:316:4: '*' ( type_qualifier )+ ( pointer )? self.match(self.input, 66, self.FOLLOW_66_in_pointer919) if self.failed: return # C.g:316:8: ( type_qualifier )+ cnt36 = 0 while True: #loop36 alt36 = 2 LA36 = self.input.LA(1) if LA36 == 58: LA36_2 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 elif LA36 == 59: LA36_3 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 elif LA36 == 60: LA36_4 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 elif LA36 == 53: LA36_20 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 elif LA36 == 49 or LA36 == 50 or LA36 == 51 or LA36 == 52 or LA36 == 54 or LA36 == 55 or LA36 == 56 or LA36 == 57 or LA36 == 61: LA36_28 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 if alt36 == 1: # C.g:0:0: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_pointer921) self.type_qualifier() self.following.pop() if self.failed: return else: if cnt36 >= 1: break #loop36 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(36, self.input) raise eee cnt36 += 1 # C.g:316:24: ( pointer )? alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == 66) : LA37_1 = self.input.LA(2) if (self.synpred76()) : alt37 = 1 if alt37 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_pointer924) self.pointer() self.following.pop() if self.failed: return elif alt38 == 2: # C.g:317:4: '*' pointer self.match(self.input, 66, self.FOLLOW_66_in_pointer930) if self.failed: return self.following.append(self.FOLLOW_pointer_in_pointer932) self.pointer() self.following.pop() if self.failed: return elif alt38 == 3: # C.g:318:4: '*' self.match(self.input, 66, self.FOLLOW_66_in_pointer937) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 25, pointer_StartIndex) pass return # $ANTLR end pointer # $ANTLR start parameter_type_list # C.g:321:1: parameter_type_list : parameter_list ( ',' ( 'OPTIONAL' )? '...' )? ; def parameter_type_list(self, ): parameter_type_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 26): return # C.g:322:2: ( parameter_list ( ',' ( 'OPTIONAL' )? '...' )? ) # C.g:322:4: parameter_list ( ',' ( 'OPTIONAL' )? '...' )? self.following.append(self.FOLLOW_parameter_list_in_parameter_type_list948) self.parameter_list() self.following.pop() if self.failed: return # C.g:322:19: ( ',' ( 'OPTIONAL' )? '...' )? alt40 = 2 LA40_0 = self.input.LA(1) if (LA40_0 == 27) : alt40 = 1 if alt40 == 1: # C.g:322:20: ',' ( 'OPTIONAL' )? '...' self.match(self.input, 27, self.FOLLOW_27_in_parameter_type_list951) if self.failed: return # C.g:322:24: ( 'OPTIONAL' )? alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == 53) : alt39 = 1 if alt39 == 1: # C.g:322:25: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_parameter_type_list954) if self.failed: return self.match(self.input, 67, self.FOLLOW_67_in_parameter_type_list958) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 26, parameter_type_list_StartIndex) pass return # $ANTLR end parameter_type_list # $ANTLR start parameter_list # C.g:325:1: parameter_list : parameter_declaration ( ',' ( 'OPTIONAL' )? parameter_declaration )* ; def parameter_list(self, ): parameter_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 27): return # C.g:326:2: ( parameter_declaration ( ',' ( 'OPTIONAL' )? parameter_declaration )* ) # C.g:326:4: parameter_declaration ( ',' ( 'OPTIONAL' )? parameter_declaration )* self.following.append(self.FOLLOW_parameter_declaration_in_parameter_list971) self.parameter_declaration() self.following.pop() if self.failed: return # C.g:326:26: ( ',' ( 'OPTIONAL' )? parameter_declaration )* while True: #loop42 alt42 = 2 LA42_0 = self.input.LA(1) if (LA42_0 == 27) : LA42_1 = self.input.LA(2) if (LA42_1 == 53) : LA42_3 = self.input.LA(3) if (self.synpred82()) : alt42 = 1 elif (LA42_1 == IDENTIFIER or (29 <= LA42_1 <= 42) or (45 <= LA42_1 <= 46) or (48 <= LA42_1 <= 52) or (54 <= LA42_1 <= 61) or LA42_1 == 66) : alt42 = 1 if alt42 == 1: # C.g:326:27: ',' ( 'OPTIONAL' )? parameter_declaration self.match(self.input, 27, self.FOLLOW_27_in_parameter_list974) if self.failed: return # C.g:326:31: ( 'OPTIONAL' )? alt41 = 2 LA41_0 = self.input.LA(1) if (LA41_0 == 53) : LA41_1 = self.input.LA(2) if (self.synpred81()) : alt41 = 1 if alt41 == 1: # C.g:326:32: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_parameter_list977) if self.failed: return self.following.append(self.FOLLOW_parameter_declaration_in_parameter_list981) self.parameter_declaration() self.following.pop() if self.failed: return else: break #loop42 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 27, parameter_list_StartIndex) pass return # $ANTLR end parameter_list # $ANTLR start parameter_declaration # C.g:329:1: parameter_declaration : ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? | ( pointer )* IDENTIFIER ); def parameter_declaration(self, ): parameter_declaration_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 28): return # C.g:330:2: ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? | ( pointer )* IDENTIFIER ) alt46 = 2 LA46 = self.input.LA(1) if LA46 == 29 or LA46 == 30 or LA46 == 31 or LA46 == 32 or LA46 == 33 or LA46 == 34 or LA46 == 35 or LA46 == 36 or LA46 == 37 or LA46 == 38 or LA46 == 39 or LA46 == 40 or LA46 == 41 or LA46 == 42 or LA46 == 45 or LA46 == 46 or LA46 == 48 or LA46 == 49 or LA46 == 50 or LA46 == 51 or LA46 == 52 or LA46 == 53 or LA46 == 54 or LA46 == 55 or LA46 == 56 or LA46 == 57 or LA46 == 58 or LA46 == 59 or LA46 == 60 or LA46 == 61: alt46 = 1 elif LA46 == IDENTIFIER: LA46_13 = self.input.LA(2) if (self.synpred86()) : alt46 = 1 elif (True) : alt46 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("329:1: parameter_declaration : ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? | ( pointer )* IDENTIFIER );", 46, 13, self.input) raise nvae elif LA46 == 66: alt46 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("329:1: parameter_declaration : ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? | ( pointer )* IDENTIFIER );", 46, 0, self.input) raise nvae if alt46 == 1: # C.g:330:4: declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? self.following.append(self.FOLLOW_declaration_specifiers_in_parameter_declaration994) self.declaration_specifiers() self.following.pop() if self.failed: return # C.g:330:27: ( declarator | abstract_declarator )* while True: #loop43 alt43 = 3 LA43 = self.input.LA(1) if LA43 == 66: LA43_5 = self.input.LA(2) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == IDENTIFIER or LA43 == 58 or LA43 == 59 or LA43 == 60: alt43 = 1 elif LA43 == 62: LA43 = self.input.LA(2) if LA43 == 29 or LA43 == 30 or LA43 == 31 or LA43 == 32 or LA43 == 33 or LA43 == 34 or LA43 == 35 or LA43 == 36 or LA43 == 37 or LA43 == 38 or LA43 == 39 or LA43 == 40 or LA43 == 41 or LA43 == 42 or LA43 == 45 or LA43 == 46 or LA43 == 48 or LA43 == 49 or LA43 == 50 or LA43 == 51 or LA43 == 52 or LA43 == 53 or LA43 == 54 or LA43 == 55 or LA43 == 56 or LA43 == 57 or LA43 == 61 or LA43 == 63 or LA43 == 64: alt43 = 2 elif LA43 == IDENTIFIER: LA43_37 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 58: LA43_38 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 66: LA43_39 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 59: LA43_40 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 60: LA43_41 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 62: LA43_43 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 64: alt43 = 2 if alt43 == 1: # C.g:330:28: declarator self.following.append(self.FOLLOW_declarator_in_parameter_declaration997) self.declarator() self.following.pop() if self.failed: return elif alt43 == 2: # C.g:330:39: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_parameter_declaration999) self.abstract_declarator() self.following.pop() if self.failed: return else: break #loop43 # C.g:330:61: ( 'OPTIONAL' )? alt44 = 2 LA44_0 = self.input.LA(1) if (LA44_0 == 53) : alt44 = 1 if alt44 == 1: # C.g:330:62: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_parameter_declaration1004) if self.failed: return elif alt46 == 2: # C.g:332:4: ( pointer )* IDENTIFIER # C.g:332:4: ( pointer )* while True: #loop45 alt45 = 2 LA45_0 = self.input.LA(1) if (LA45_0 == 66) : alt45 = 1 if alt45 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_parameter_declaration1013) self.pointer() self.following.pop() if self.failed: return else: break #loop45 self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_parameter_declaration1016) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 28, parameter_declaration_StartIndex) pass return # $ANTLR end parameter_declaration # $ANTLR start identifier_list # C.g:335:1: identifier_list : IDENTIFIER ( ',' IDENTIFIER )* ; def identifier_list(self, ): identifier_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 29): return # C.g:336:2: ( IDENTIFIER ( ',' IDENTIFIER )* ) # C.g:336:4: IDENTIFIER ( ',' IDENTIFIER )* self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_identifier_list1027) if self.failed: return # C.g:337:2: ( ',' IDENTIFIER )* while True: #loop47 alt47 = 2 LA47_0 = self.input.LA(1) if (LA47_0 == 27) : alt47 = 1 if alt47 == 1: # C.g:337:3: ',' IDENTIFIER self.match(self.input, 27, self.FOLLOW_27_in_identifier_list1031) if self.failed: return self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_identifier_list1033) if self.failed: return else: break #loop47 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 29, identifier_list_StartIndex) pass return # $ANTLR end identifier_list # $ANTLR start type_name # C.g:340:1: type_name : ( specifier_qualifier_list ( abstract_declarator )? | type_id ); def type_name(self, ): type_name_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 30): return # C.g:341:2: ( specifier_qualifier_list ( abstract_declarator )? | type_id ) alt49 = 2 LA49_0 = self.input.LA(1) if ((34 <= LA49_0 <= 42) or (45 <= LA49_0 <= 46) or (48 <= LA49_0 <= 61)) : alt49 = 1 elif (LA49_0 == IDENTIFIER) : LA49_13 = self.input.LA(2) if (self.synpred90()) : alt49 = 1 elif (True) : alt49 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("340:1: type_name : ( specifier_qualifier_list ( abstract_declarator )? | type_id );", 49, 13, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("340:1: type_name : ( specifier_qualifier_list ( abstract_declarator )? | type_id );", 49, 0, self.input) raise nvae if alt49 == 1: # C.g:341:4: specifier_qualifier_list ( abstract_declarator )? self.following.append(self.FOLLOW_specifier_qualifier_list_in_type_name1046) self.specifier_qualifier_list() self.following.pop() if self.failed: return # C.g:341:29: ( abstract_declarator )? alt48 = 2 LA48_0 = self.input.LA(1) if (LA48_0 == 62 or LA48_0 == 64 or LA48_0 == 66) : alt48 = 1 if alt48 == 1: # C.g:0:0: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_type_name1048) self.abstract_declarator() self.following.pop() if self.failed: return elif alt49 == 2: # C.g:342:4: type_id self.following.append(self.FOLLOW_type_id_in_type_name1054) self.type_id() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 30, type_name_StartIndex) pass return # $ANTLR end type_name # $ANTLR start abstract_declarator # C.g:345:1: abstract_declarator : ( pointer ( direct_abstract_declarator )? | direct_abstract_declarator ); def abstract_declarator(self, ): abstract_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 31): return # C.g:346:2: ( pointer ( direct_abstract_declarator )? | direct_abstract_declarator ) alt51 = 2 LA51_0 = self.input.LA(1) if (LA51_0 == 66) : alt51 = 1 elif (LA51_0 == 62 or LA51_0 == 64) : alt51 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("345:1: abstract_declarator : ( pointer ( direct_abstract_declarator )? | direct_abstract_declarator );", 51, 0, self.input) raise nvae if alt51 == 1: # C.g:346:4: pointer ( direct_abstract_declarator )? self.following.append(self.FOLLOW_pointer_in_abstract_declarator1065) self.pointer() self.following.pop() if self.failed: return # C.g:346:12: ( direct_abstract_declarator )? alt50 = 2 LA50_0 = self.input.LA(1) if (LA50_0 == 62) : LA50 = self.input.LA(2) if LA50 == 63: LA50_12 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 58: LA50_13 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 66: LA50_14 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 59: LA50_15 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 60: LA50_16 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == IDENTIFIER: LA50_17 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 62: LA50_18 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 64: LA50_19 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 29 or LA50 == 30 or LA50 == 31 or LA50 == 32 or LA50 == 33: LA50_20 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 34: LA50_21 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 35: LA50_22 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 36: LA50_23 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 37: LA50_24 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 38: LA50_25 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 39: LA50_26 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 40: LA50_27 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 41: LA50_28 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 42: LA50_29 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 45 or LA50 == 46: LA50_30 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 48: LA50_31 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 49 or LA50 == 50 or LA50 == 51 or LA50 == 52 or LA50 == 53 or LA50 == 54 or LA50 == 55 or LA50 == 56 or LA50 == 57 or LA50 == 61: LA50_32 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif (LA50_0 == 64) : LA50 = self.input.LA(2) if LA50 == 65: LA50_33 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 62: LA50_34 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == IDENTIFIER: LA50_35 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == HEX_LITERAL: LA50_36 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == OCTAL_LITERAL: LA50_37 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == DECIMAL_LITERAL: LA50_38 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == CHARACTER_LITERAL: LA50_39 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == STRING_LITERAL: LA50_40 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == FLOATING_POINT_LITERAL: LA50_41 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 72: LA50_42 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 73: LA50_43 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 66 or LA50 == 68 or LA50 == 69 or LA50 == 77 or LA50 == 78 or LA50 == 79: LA50_44 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 74: LA50_45 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 if alt50 == 1: # C.g:0:0: direct_abstract_declarator self.following.append(self.FOLLOW_direct_abstract_declarator_in_abstract_declarator1067) self.direct_abstract_declarator() self.following.pop() if self.failed: return elif alt51 == 2: # C.g:347:4: direct_abstract_declarator self.following.append(self.FOLLOW_direct_abstract_declarator_in_abstract_declarator1073) self.direct_abstract_declarator() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 31, abstract_declarator_StartIndex) pass return # $ANTLR end abstract_declarator # $ANTLR start direct_abstract_declarator # C.g:350:1: direct_abstract_declarator : ( '(' abstract_declarator ')' | abstract_declarator_suffix ) ( abstract_declarator_suffix )* ; def direct_abstract_declarator(self, ): direct_abstract_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 32): return # C.g:351:2: ( ( '(' abstract_declarator ')' | abstract_declarator_suffix ) ( abstract_declarator_suffix )* ) # C.g:351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix ) ( abstract_declarator_suffix )* # C.g:351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix ) alt52 = 2 LA52_0 = self.input.LA(1) if (LA52_0 == 62) : LA52 = self.input.LA(2) if LA52 == IDENTIFIER or LA52 == 29 or LA52 == 30 or LA52 == 31 or LA52 == 32 or LA52 == 33 or LA52 == 34 or LA52 == 35 or LA52 == 36 or LA52 == 37 or LA52 == 38 or LA52 == 39 or LA52 == 40 or LA52 == 41 or LA52 == 42 or LA52 == 45 or LA52 == 46 or LA52 == 48 or LA52 == 49 or LA52 == 50 or LA52 == 51 or LA52 == 52 or LA52 == 53 or LA52 == 54 or LA52 == 55 or LA52 == 56 or LA52 == 57 or LA52 == 58 or LA52 == 59 or LA52 == 60 or LA52 == 61 or LA52 == 63: alt52 = 2 elif LA52 == 66: LA52_18 = self.input.LA(3) if (self.synpred93()) : alt52 = 1 elif (True) : alt52 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix )", 52, 18, self.input) raise nvae elif LA52 == 62 or LA52 == 64: alt52 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix )", 52, 1, self.input) raise nvae elif (LA52_0 == 64) : alt52 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix )", 52, 0, self.input) raise nvae if alt52 == 1: # C.g:351:6: '(' abstract_declarator ')' self.match(self.input, 62, self.FOLLOW_62_in_direct_abstract_declarator1086) if self.failed: return self.following.append(self.FOLLOW_abstract_declarator_in_direct_abstract_declarator1088) self.abstract_declarator() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_direct_abstract_declarator1090) if self.failed: return elif alt52 == 2: # C.g:351:36: abstract_declarator_suffix self.following.append(self.FOLLOW_abstract_declarator_suffix_in_direct_abstract_declarator1094) self.abstract_declarator_suffix() self.following.pop() if self.failed: return # C.g:351:65: ( abstract_declarator_suffix )* while True: #loop53 alt53 = 2 LA53_0 = self.input.LA(1) if (LA53_0 == 62) : LA53 = self.input.LA(2) if LA53 == 63: LA53_12 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 58: LA53_13 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 66: LA53_14 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 59: LA53_15 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 60: LA53_16 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == IDENTIFIER: LA53_17 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 29 or LA53 == 30 or LA53 == 31 or LA53 == 32 or LA53 == 33: LA53_19 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 34: LA53_20 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 35: LA53_21 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 36: LA53_22 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 37: LA53_23 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 38: LA53_24 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 39: LA53_25 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 40: LA53_26 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 41: LA53_27 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 42: LA53_28 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 45 or LA53 == 46: LA53_29 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 48: LA53_30 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 49 or LA53 == 50 or LA53 == 51 or LA53 == 52 or LA53 == 53 or LA53 == 54 or LA53 == 55 or LA53 == 56 or LA53 == 57 or LA53 == 61: LA53_31 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif (LA53_0 == 64) : LA53 = self.input.LA(2) if LA53 == 65: LA53_33 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 62: LA53_34 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == IDENTIFIER: LA53_35 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == HEX_LITERAL: LA53_36 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == OCTAL_LITERAL: LA53_37 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == DECIMAL_LITERAL: LA53_38 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == CHARACTER_LITERAL: LA53_39 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == STRING_LITERAL: LA53_40 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == FLOATING_POINT_LITERAL: LA53_41 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 72: LA53_42 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 73: LA53_43 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 66 or LA53 == 68 or LA53 == 69 or LA53 == 77 or LA53 == 78 or LA53 == 79: LA53_44 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 74: LA53_45 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 if alt53 == 1: # C.g:0:0: abstract_declarator_suffix self.following.append(self.FOLLOW_abstract_declarator_suffix_in_direct_abstract_declarator1098) self.abstract_declarator_suffix() self.following.pop() if self.failed: return else: break #loop53 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 32, direct_abstract_declarator_StartIndex) pass return # $ANTLR end direct_abstract_declarator # $ANTLR start abstract_declarator_suffix # C.g:354:1: abstract_declarator_suffix : ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' ); def abstract_declarator_suffix(self, ): abstract_declarator_suffix_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 33): return # C.g:355:2: ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' ) alt54 = 4 LA54_0 = self.input.LA(1) if (LA54_0 == 64) : LA54_1 = self.input.LA(2) if (LA54_1 == 65) : alt54 = 1 elif ((IDENTIFIER <= LA54_1 <= FLOATING_POINT_LITERAL) or LA54_1 == 62 or LA54_1 == 66 or (68 <= LA54_1 <= 69) or (72 <= LA54_1 <= 74) or (77 <= LA54_1 <= 79)) : alt54 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("354:1: abstract_declarator_suffix : ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' );", 54, 1, self.input) raise nvae elif (LA54_0 == 62) : LA54_2 = self.input.LA(2) if (LA54_2 == 63) : alt54 = 3 elif (LA54_2 == IDENTIFIER or (29 <= LA54_2 <= 42) or (45 <= LA54_2 <= 46) or (48 <= LA54_2 <= 61) or LA54_2 == 66) : alt54 = 4 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("354:1: abstract_declarator_suffix : ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' );", 54, 2, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("354:1: abstract_declarator_suffix : ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' );", 54, 0, self.input) raise nvae if alt54 == 1: # C.g:355:4: '[' ']' self.match(self.input, 64, self.FOLLOW_64_in_abstract_declarator_suffix1110) if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_abstract_declarator_suffix1112) if self.failed: return elif alt54 == 2: # C.g:356:4: '[' constant_expression ']' self.match(self.input, 64, self.FOLLOW_64_in_abstract_declarator_suffix1117) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_abstract_declarator_suffix1119) self.constant_expression() self.following.pop() if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_abstract_declarator_suffix1121) if self.failed: return elif alt54 == 3: # C.g:357:4: '(' ')' self.match(self.input, 62, self.FOLLOW_62_in_abstract_declarator_suffix1126) if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_abstract_declarator_suffix1128) if self.failed: return elif alt54 == 4: # C.g:358:4: '(' parameter_type_list ')' self.match(self.input, 62, self.FOLLOW_62_in_abstract_declarator_suffix1133) if self.failed: return self.following.append(self.FOLLOW_parameter_type_list_in_abstract_declarator_suffix1135) self.parameter_type_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_abstract_declarator_suffix1137) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 33, abstract_declarator_suffix_StartIndex) pass return # $ANTLR end abstract_declarator_suffix # $ANTLR start initializer # C.g:361:1: initializer : ( assignment_expression | '{' initializer_list ( ',' )? '}' ); def initializer(self, ): initializer_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 34): return # C.g:363:2: ( assignment_expression | '{' initializer_list ( ',' )? '}' ) alt56 = 2 LA56_0 = self.input.LA(1) if ((IDENTIFIER <= LA56_0 <= FLOATING_POINT_LITERAL) or LA56_0 == 62 or LA56_0 == 66 or (68 <= LA56_0 <= 69) or (72 <= LA56_0 <= 74) or (77 <= LA56_0 <= 79)) : alt56 = 1 elif (LA56_0 == 43) : alt56 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("361:1: initializer : ( assignment_expression | '{' initializer_list ( ',' )? '}' );", 56, 0, self.input) raise nvae if alt56 == 1: # C.g:363:4: assignment_expression self.following.append(self.FOLLOW_assignment_expression_in_initializer1150) self.assignment_expression() self.following.pop() if self.failed: return elif alt56 == 2: # C.g:364:4: '{' initializer_list ( ',' )? '}' self.match(self.input, 43, self.FOLLOW_43_in_initializer1155) if self.failed: return self.following.append(self.FOLLOW_initializer_list_in_initializer1157) self.initializer_list() self.following.pop() if self.failed: return # C.g:364:25: ( ',' )? alt55 = 2 LA55_0 = self.input.LA(1) if (LA55_0 == 27) : alt55 = 1 if alt55 == 1: # C.g:0:0: ',' self.match(self.input, 27, self.FOLLOW_27_in_initializer1159) if self.failed: return self.match(self.input, 44, self.FOLLOW_44_in_initializer1162) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 34, initializer_StartIndex) pass return # $ANTLR end initializer # $ANTLR start initializer_list # C.g:367:1: initializer_list : initializer ( ',' initializer )* ; def initializer_list(self, ): initializer_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 35): return # C.g:368:2: ( initializer ( ',' initializer )* ) # C.g:368:4: initializer ( ',' initializer )* self.following.append(self.FOLLOW_initializer_in_initializer_list1173) self.initializer() self.following.pop() if self.failed: return # C.g:368:16: ( ',' initializer )* while True: #loop57 alt57 = 2 LA57_0 = self.input.LA(1) if (LA57_0 == 27) : LA57_1 = self.input.LA(2) if ((IDENTIFIER <= LA57_1 <= FLOATING_POINT_LITERAL) or LA57_1 == 43 or LA57_1 == 62 or LA57_1 == 66 or (68 <= LA57_1 <= 69) or (72 <= LA57_1 <= 74) or (77 <= LA57_1 <= 79)) : alt57 = 1 if alt57 == 1: # C.g:368:17: ',' initializer self.match(self.input, 27, self.FOLLOW_27_in_initializer_list1176) if self.failed: return self.following.append(self.FOLLOW_initializer_in_initializer_list1178) self.initializer() self.following.pop() if self.failed: return else: break #loop57 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 35, initializer_list_StartIndex) pass return # $ANTLR end initializer_list class argument_expression_list_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start argument_expression_list # C.g:373:1: argument_expression_list : assignment_expression ( 'OPTIONAL' )? ( ',' assignment_expression ( 'OPTIONAL' )? )* ; def argument_expression_list(self, ): retval = self.argument_expression_list_return() retval.start = self.input.LT(1) argument_expression_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 36): return retval # C.g:374:2: ( assignment_expression ( 'OPTIONAL' )? ( ',' assignment_expression ( 'OPTIONAL' )? )* ) # C.g:374:6: assignment_expression ( 'OPTIONAL' )? ( ',' assignment_expression ( 'OPTIONAL' )? )* self.following.append(self.FOLLOW_assignment_expression_in_argument_expression_list1196) self.assignment_expression() self.following.pop() if self.failed: return retval # C.g:374:28: ( 'OPTIONAL' )? alt58 = 2 LA58_0 = self.input.LA(1) if (LA58_0 == 53) : alt58 = 1 if alt58 == 1: # C.g:374:29: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_argument_expression_list1199) if self.failed: return retval # C.g:374:42: ( ',' assignment_expression ( 'OPTIONAL' )? )* while True: #loop60 alt60 = 2 LA60_0 = self.input.LA(1) if (LA60_0 == 27) : alt60 = 1 if alt60 == 1: # C.g:374:43: ',' assignment_expression ( 'OPTIONAL' )? self.match(self.input, 27, self.FOLLOW_27_in_argument_expression_list1204) if self.failed: return retval self.following.append(self.FOLLOW_assignment_expression_in_argument_expression_list1206) self.assignment_expression() self.following.pop() if self.failed: return retval # C.g:374:69: ( 'OPTIONAL' )? alt59 = 2 LA59_0 = self.input.LA(1) if (LA59_0 == 53) : alt59 = 1 if alt59 == 1: # C.g:374:70: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_argument_expression_list1209) if self.failed: return retval else: break #loop60 retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 36, argument_expression_list_StartIndex) pass return retval # $ANTLR end argument_expression_list # $ANTLR start additive_expression # C.g:377:1: additive_expression : ( multiplicative_expression ) ( '+' multiplicative_expression | '-' multiplicative_expression )* ; def additive_expression(self, ): additive_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 37): return # C.g:378:2: ( ( multiplicative_expression ) ( '+' multiplicative_expression | '-' multiplicative_expression )* ) # C.g:378:4: ( multiplicative_expression ) ( '+' multiplicative_expression | '-' multiplicative_expression )* # C.g:378:4: ( multiplicative_expression ) # C.g:378:5: multiplicative_expression self.following.append(self.FOLLOW_multiplicative_expression_in_additive_expression1225) self.multiplicative_expression() self.following.pop() if self.failed: return # C.g:378:32: ( '+' multiplicative_expression | '-' multiplicative_expression )* while True: #loop61 alt61 = 3 LA61_0 = self.input.LA(1) if (LA61_0 == 68) : alt61 = 1 elif (LA61_0 == 69) : alt61 = 2 if alt61 == 1: # C.g:378:33: '+' multiplicative_expression self.match(self.input, 68, self.FOLLOW_68_in_additive_expression1229) if self.failed: return self.following.append(self.FOLLOW_multiplicative_expression_in_additive_expression1231) self.multiplicative_expression() self.following.pop() if self.failed: return elif alt61 == 2: # C.g:378:65: '-' multiplicative_expression self.match(self.input, 69, self.FOLLOW_69_in_additive_expression1235) if self.failed: return self.following.append(self.FOLLOW_multiplicative_expression_in_additive_expression1237) self.multiplicative_expression() self.following.pop() if self.failed: return else: break #loop61 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 37, additive_expression_StartIndex) pass return # $ANTLR end additive_expression # $ANTLR start multiplicative_expression # C.g:381:1: multiplicative_expression : ( cast_expression ) ( '*' cast_expression | '/' cast_expression | '%' cast_expression )* ; def multiplicative_expression(self, ): multiplicative_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 38): return # C.g:382:2: ( ( cast_expression ) ( '*' cast_expression | '/' cast_expression | '%' cast_expression )* ) # C.g:382:4: ( cast_expression ) ( '*' cast_expression | '/' cast_expression | '%' cast_expression )* # C.g:382:4: ( cast_expression ) # C.g:382:5: cast_expression self.following.append(self.FOLLOW_cast_expression_in_multiplicative_expression1251) self.cast_expression() self.following.pop() if self.failed: return # C.g:382:22: ( '*' cast_expression | '/' cast_expression | '%' cast_expression )* while True: #loop62 alt62 = 4 LA62 = self.input.LA(1) if LA62 == 66: alt62 = 1 elif LA62 == 70: alt62 = 2 elif LA62 == 71: alt62 = 3 if alt62 == 1: # C.g:382:23: '*' cast_expression self.match(self.input, 66, self.FOLLOW_66_in_multiplicative_expression1255) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_multiplicative_expression1257) self.cast_expression() self.following.pop() if self.failed: return elif alt62 == 2: # C.g:382:45: '/' cast_expression self.match(self.input, 70, self.FOLLOW_70_in_multiplicative_expression1261) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_multiplicative_expression1263) self.cast_expression() self.following.pop() if self.failed: return elif alt62 == 3: # C.g:382:67: '%' cast_expression self.match(self.input, 71, self.FOLLOW_71_in_multiplicative_expression1267) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_multiplicative_expression1269) self.cast_expression() self.following.pop() if self.failed: return else: break #loop62 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 38, multiplicative_expression_StartIndex) pass return # $ANTLR end multiplicative_expression # $ANTLR start cast_expression # C.g:385:1: cast_expression : ( '(' type_name ')' cast_expression | unary_expression ); def cast_expression(self, ): cast_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 39): return # C.g:386:2: ( '(' type_name ')' cast_expression | unary_expression ) alt63 = 2 LA63_0 = self.input.LA(1) if (LA63_0 == 62) : LA63 = self.input.LA(2) if LA63 == 34 or LA63 == 35 or LA63 == 36 or LA63 == 37 or LA63 == 38 or LA63 == 39 or LA63 == 40 or LA63 == 41 or LA63 == 42 or LA63 == 45 or LA63 == 46 or LA63 == 48 or LA63 == 49 or LA63 == 50 or LA63 == 51 or LA63 == 52 or LA63 == 53 or LA63 == 54 or LA63 == 55 or LA63 == 56 or LA63 == 57 or LA63 == 58 or LA63 == 59 or LA63 == 60 or LA63 == 61: alt63 = 1 elif LA63 == IDENTIFIER: LA63_25 = self.input.LA(3) if (self.synpred109()) : alt63 = 1 elif (True) : alt63 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("385:1: cast_expression : ( '(' type_name ')' cast_expression | unary_expression );", 63, 25, self.input) raise nvae elif LA63 == HEX_LITERAL or LA63 == OCTAL_LITERAL or LA63 == DECIMAL_LITERAL or LA63 == CHARACTER_LITERAL or LA63 == STRING_LITERAL or LA63 == FLOATING_POINT_LITERAL or LA63 == 62 or LA63 == 66 or LA63 == 68 or LA63 == 69 or LA63 == 72 or LA63 == 73 or LA63 == 74 or LA63 == 77 or LA63 == 78 or LA63 == 79: alt63 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("385:1: cast_expression : ( '(' type_name ')' cast_expression | unary_expression );", 63, 1, self.input) raise nvae elif ((IDENTIFIER <= LA63_0 <= FLOATING_POINT_LITERAL) or LA63_0 == 66 or (68 <= LA63_0 <= 69) or (72 <= LA63_0 <= 74) or (77 <= LA63_0 <= 79)) : alt63 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("385:1: cast_expression : ( '(' type_name ')' cast_expression | unary_expression );", 63, 0, self.input) raise nvae if alt63 == 1: # C.g:386:4: '(' type_name ')' cast_expression self.match(self.input, 62, self.FOLLOW_62_in_cast_expression1282) if self.failed: return self.following.append(self.FOLLOW_type_name_in_cast_expression1284) self.type_name() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_cast_expression1286) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_cast_expression1288) self.cast_expression() self.following.pop() if self.failed: return elif alt63 == 2: # C.g:387:4: unary_expression self.following.append(self.FOLLOW_unary_expression_in_cast_expression1293) self.unary_expression() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 39, cast_expression_StartIndex) pass return # $ANTLR end cast_expression # $ANTLR start unary_expression # C.g:390:1: unary_expression : ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' ); def unary_expression(self, ): unary_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 40): return # C.g:391:2: ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' ) alt64 = 6 LA64 = self.input.LA(1) if LA64 == IDENTIFIER or LA64 == HEX_LITERAL or LA64 == OCTAL_LITERAL or LA64 == DECIMAL_LITERAL or LA64 == CHARACTER_LITERAL or LA64 == STRING_LITERAL or LA64 == FLOATING_POINT_LITERAL or LA64 == 62: alt64 = 1 elif LA64 == 72: alt64 = 2 elif LA64 == 73: alt64 = 3 elif LA64 == 66 or LA64 == 68 or LA64 == 69 or LA64 == 77 or LA64 == 78 or LA64 == 79: alt64 = 4 elif LA64 == 74: LA64_12 = self.input.LA(2) if (LA64_12 == 62) : LA64_13 = self.input.LA(3) if (self.synpred114()) : alt64 = 5 elif (True) : alt64 = 6 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("390:1: unary_expression : ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' );", 64, 13, self.input) raise nvae elif ((IDENTIFIER <= LA64_12 <= FLOATING_POINT_LITERAL) or LA64_12 == 66 or (68 <= LA64_12 <= 69) or (72 <= LA64_12 <= 74) or (77 <= LA64_12 <= 79)) : alt64 = 5 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("390:1: unary_expression : ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' );", 64, 12, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("390:1: unary_expression : ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' );", 64, 0, self.input) raise nvae if alt64 == 1: # C.g:391:4: postfix_expression self.following.append(self.FOLLOW_postfix_expression_in_unary_expression1304) self.postfix_expression() self.following.pop() if self.failed: return elif alt64 == 2: # C.g:392:4: '++' unary_expression self.match(self.input, 72, self.FOLLOW_72_in_unary_expression1309) if self.failed: return self.following.append(self.FOLLOW_unary_expression_in_unary_expression1311) self.unary_expression() self.following.pop() if self.failed: return elif alt64 == 3: # C.g:393:4: '--' unary_expression self.match(self.input, 73, self.FOLLOW_73_in_unary_expression1316) if self.failed: return self.following.append(self.FOLLOW_unary_expression_in_unary_expression1318) self.unary_expression() self.following.pop() if self.failed: return elif alt64 == 4: # C.g:394:4: unary_operator cast_expression self.following.append(self.FOLLOW_unary_operator_in_unary_expression1323) self.unary_operator() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_unary_expression1325) self.cast_expression() self.following.pop() if self.failed: return elif alt64 == 5: # C.g:395:4: 'sizeof' unary_expression self.match(self.input, 74, self.FOLLOW_74_in_unary_expression1330) if self.failed: return self.following.append(self.FOLLOW_unary_expression_in_unary_expression1332) self.unary_expression() self.following.pop() if self.failed: return elif alt64 == 6: # C.g:396:4: 'sizeof' '(' type_name ')' self.match(self.input, 74, self.FOLLOW_74_in_unary_expression1337) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_unary_expression1339) if self.failed: return self.following.append(self.FOLLOW_type_name_in_unary_expression1341) self.type_name() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_unary_expression1343) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 40, unary_expression_StartIndex) pass return # $ANTLR end unary_expression # $ANTLR start postfix_expression # C.g:399:1: postfix_expression : p= primary_expression ( '[' expression ']' | '(' a= ')' | '(' c= argument_expression_list b= ')' | '(' macro_parameter_list ')' | '.' x= IDENTIFIER | '*' y= IDENTIFIER | '->' z= IDENTIFIER | '++' | '--' )* ; def postfix_expression(self, ): self.postfix_expression_stack.append(postfix_expression_scope()) postfix_expression_StartIndex = self.input.index() a = None b = None x = None y = None z = None p = None c = None self.postfix_expression_stack[-1].FuncCallText = '' try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 41): return # C.g:406:2: (p= primary_expression ( '[' expression ']' | '(' a= ')' | '(' c= argument_expression_list b= ')' | '(' macro_parameter_list ')' | '.' x= IDENTIFIER | '*' y= IDENTIFIER | '->' z= IDENTIFIER | '++' | '--' )* ) # C.g:406:6: p= primary_expression ( '[' expression ']' | '(' a= ')' | '(' c= argument_expression_list b= ')' | '(' macro_parameter_list ')' | '.' x= IDENTIFIER | '*' y= IDENTIFIER | '->' z= IDENTIFIER | '++' | '--' )* self.following.append(self.FOLLOW_primary_expression_in_postfix_expression1367) p = self.primary_expression() self.following.pop() if self.failed: return if self.backtracking == 0: self.postfix_expression_stack[-1].FuncCallText += self.input.toString(p.start,p.stop) # C.g:407:9: ( '[' expression ']' | '(' a= ')' | '(' c= argument_expression_list b= ')' | '(' macro_parameter_list ')' | '.' x= IDENTIFIER | '*' y= IDENTIFIER | '->' z= IDENTIFIER | '++' | '--' )* while True: #loop65 alt65 = 10 LA65 = self.input.LA(1) if LA65 == 66: LA65_1 = self.input.LA(2) if (LA65_1 == IDENTIFIER) : LA65_30 = self.input.LA(3) if (self.synpred120()) : alt65 = 6 elif LA65 == 64: alt65 = 1 elif LA65 == 62: LA65 = self.input.LA(2) if LA65 == 63: alt65 = 2 elif LA65 == 29 or LA65 == 30 or LA65 == 31 or LA65 == 32 or LA65 == 33 or LA65 == 34 or LA65 == 35 or LA65 == 36 or LA65 == 37 or LA65 == 38 or LA65 == 39 or LA65 == 40 or LA65 == 41 or LA65 == 42 or LA65 == 45 or LA65 == 46 or LA65 == 48 or LA65 == 49 or LA65 == 50 or LA65 == 51 or LA65 == 52 or LA65 == 53 or LA65 == 54 or LA65 == 55 or LA65 == 56 or LA65 == 57 or LA65 == 58 or LA65 == 59 or LA65 == 60 or LA65 == 61: alt65 = 4 elif LA65 == IDENTIFIER: LA65_55 = self.input.LA(3) if (self.synpred117()) : alt65 = 3 elif (self.synpred118()) : alt65 = 4 elif LA65 == 66: LA65_57 = self.input.LA(3) if (self.synpred117()) : alt65 = 3 elif (self.synpred118()) : alt65 = 4 elif LA65 == HEX_LITERAL or LA65 == OCTAL_LITERAL or LA65 == DECIMAL_LITERAL or LA65 == CHARACTER_LITERAL or LA65 == STRING_LITERAL or LA65 == FLOATING_POINT_LITERAL or LA65 == 62 or LA65 == 68 or LA65 == 69 or LA65 == 72 or LA65 == 73 or LA65 == 74 or LA65 == 77 or LA65 == 78 or LA65 == 79: alt65 = 3 elif LA65 == 75: alt65 = 5 elif LA65 == 76: alt65 = 7 elif LA65 == 72: alt65 = 8 elif LA65 == 73: alt65 = 9 if alt65 == 1: # C.g:407:13: '[' expression ']' self.match(self.input, 64, self.FOLLOW_64_in_postfix_expression1383) if self.failed: return self.following.append(self.FOLLOW_expression_in_postfix_expression1385) self.expression() self.following.pop() if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_postfix_expression1387) if self.failed: return elif alt65 == 2: # C.g:408:13: '(' a= ')' self.match(self.input, 62, self.FOLLOW_62_in_postfix_expression1401) if self.failed: return a = self.input.LT(1) self.match(self.input, 63, self.FOLLOW_63_in_postfix_expression1405) if self.failed: return if self.backtracking == 0: self.StoreFunctionCalling(p.start.line, p.start.charPositionInLine, a.line, a.charPositionInLine, self.postfix_expression_stack[-1].FuncCallText, '') elif alt65 == 3: # C.g:409:13: '(' c= argument_expression_list b= ')' self.match(self.input, 62, self.FOLLOW_62_in_postfix_expression1420) if self.failed: return self.following.append(self.FOLLOW_argument_expression_list_in_postfix_expression1424) c = self.argument_expression_list() self.following.pop() if self.failed: return b = self.input.LT(1) self.match(self.input, 63, self.FOLLOW_63_in_postfix_expression1428) if self.failed: return if self.backtracking == 0: self.StoreFunctionCalling(p.start.line, p.start.charPositionInLine, b.line, b.charPositionInLine, self.postfix_expression_stack[-1].FuncCallText, self.input.toString(c.start,c.stop)) elif alt65 == 4: # C.g:410:13: '(' macro_parameter_list ')' self.match(self.input, 62, self.FOLLOW_62_in_postfix_expression1444) if self.failed: return self.following.append(self.FOLLOW_macro_parameter_list_in_postfix_expression1446) self.macro_parameter_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_postfix_expression1448) if self.failed: return elif alt65 == 5: # C.g:411:13: '.' x= IDENTIFIER self.match(self.input, 75, self.FOLLOW_75_in_postfix_expression1462) if self.failed: return x = self.input.LT(1) self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_postfix_expression1466) if self.failed: return if self.backtracking == 0: self.postfix_expression_stack[-1].FuncCallText += '.' + x.text elif alt65 == 6: # C.g:412:13: '*' y= IDENTIFIER self.match(self.input, 66, self.FOLLOW_66_in_postfix_expression1482) if self.failed: return y = self.input.LT(1) self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_postfix_expression1486) if self.failed: return if self.backtracking == 0: self.postfix_expression_stack[-1].FuncCallText = y.text elif alt65 == 7: # C.g:413:13: '->' z= IDENTIFIER self.match(self.input, 76, self.FOLLOW_76_in_postfix_expression1502) if self.failed: return z = self.input.LT(1) self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_postfix_expression1506) if self.failed: return if self.backtracking == 0: self.postfix_expression_stack[-1].FuncCallText += '->' + z.text elif alt65 == 8: # C.g:414:13: '++' self.match(self.input, 72, self.FOLLOW_72_in_postfix_expression1522) if self.failed: return elif alt65 == 9: # C.g:415:13: '--' self.match(self.input, 73, self.FOLLOW_73_in_postfix_expression1536) if self.failed: return else: break #loop65 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 41, postfix_expression_StartIndex) self.postfix_expression_stack.pop() pass return # $ANTLR end postfix_expression # $ANTLR start macro_parameter_list # C.g:419:1: macro_parameter_list : parameter_declaration ( ',' parameter_declaration )* ; def macro_parameter_list(self, ): macro_parameter_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 42): return # C.g:420:2: ( parameter_declaration ( ',' parameter_declaration )* ) # C.g:420:4: parameter_declaration ( ',' parameter_declaration )* self.following.append(self.FOLLOW_parameter_declaration_in_macro_parameter_list1559) self.parameter_declaration() self.following.pop() if self.failed: return # C.g:420:26: ( ',' parameter_declaration )* while True: #loop66 alt66 = 2 LA66_0 = self.input.LA(1) if (LA66_0 == 27) : alt66 = 1 if alt66 == 1: # C.g:420:27: ',' parameter_declaration self.match(self.input, 27, self.FOLLOW_27_in_macro_parameter_list1562) if self.failed: return self.following.append(self.FOLLOW_parameter_declaration_in_macro_parameter_list1564) self.parameter_declaration() self.following.pop() if self.failed: return else: break #loop66 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 42, macro_parameter_list_StartIndex) pass return # $ANTLR end macro_parameter_list # $ANTLR start unary_operator # C.g:423:1: unary_operator : ( '&' | '*' | '+' | '-' | '~' | '!' ); def unary_operator(self, ): unary_operator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 43): return # C.g:424:2: ( '&' | '*' | '+' | '-' | '~' | '!' ) # C.g: if self.input.LA(1) == 66 or (68 <= self.input.LA(1) <= 69) or (77 <= self.input.LA(1) <= 79): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_unary_operator0 ) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 43, unary_operator_StartIndex) pass return # $ANTLR end unary_operator class primary_expression_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start primary_expression # C.g:432:1: primary_expression : ( IDENTIFIER | constant | '(' expression ')' ); def primary_expression(self, ): retval = self.primary_expression_return() retval.start = self.input.LT(1) primary_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 44): return retval # C.g:433:2: ( IDENTIFIER | constant | '(' expression ')' ) alt67 = 3 LA67 = self.input.LA(1) if LA67 == IDENTIFIER: LA67_1 = self.input.LA(2) if (LA67_1 == EOF or LA67_1 == 25 or (27 <= LA67_1 <= 28) or LA67_1 == 44 or LA67_1 == 47 or LA67_1 == 53 or (62 <= LA67_1 <= 66) or (68 <= LA67_1 <= 73) or (75 <= LA67_1 <= 77) or (80 <= LA67_1 <= 102)) : alt67 = 1 elif (LA67_1 == IDENTIFIER or LA67_1 == STRING_LITERAL) : alt67 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("432:1: primary_expression : ( IDENTIFIER | constant | '(' expression ')' );", 67, 1, self.input) raise nvae elif LA67 == HEX_LITERAL or LA67 == OCTAL_LITERAL or LA67 == DECIMAL_LITERAL or LA67 == CHARACTER_LITERAL or LA67 == STRING_LITERAL or LA67 == FLOATING_POINT_LITERAL: alt67 = 2 elif LA67 == 62: alt67 = 3 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("432:1: primary_expression : ( IDENTIFIER | constant | '(' expression ')' );", 67, 0, self.input) raise nvae if alt67 == 1: # C.g:433:4: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_primary_expression1613) if self.failed: return retval elif alt67 == 2: # C.g:434:4: constant self.following.append(self.FOLLOW_constant_in_primary_expression1618) self.constant() self.following.pop() if self.failed: return retval elif alt67 == 3: # C.g:435:4: '(' expression ')' self.match(self.input, 62, self.FOLLOW_62_in_primary_expression1623) if self.failed: return retval self.following.append(self.FOLLOW_expression_in_primary_expression1625) self.expression() self.following.pop() if self.failed: return retval self.match(self.input, 63, self.FOLLOW_63_in_primary_expression1627) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 44, primary_expression_StartIndex) pass return retval # $ANTLR end primary_expression # $ANTLR start constant # C.g:438:1: constant : ( HEX_LITERAL | OCTAL_LITERAL | DECIMAL_LITERAL | CHARACTER_LITERAL | ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ ( IDENTIFIER )* | FLOATING_POINT_LITERAL ); def constant(self, ): constant_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 45): return # C.g:439:5: ( HEX_LITERAL | OCTAL_LITERAL | DECIMAL_LITERAL | CHARACTER_LITERAL | ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ ( IDENTIFIER )* | FLOATING_POINT_LITERAL ) alt72 = 6 LA72 = self.input.LA(1) if LA72 == HEX_LITERAL: alt72 = 1 elif LA72 == OCTAL_LITERAL: alt72 = 2 elif LA72 == DECIMAL_LITERAL: alt72 = 3 elif LA72 == CHARACTER_LITERAL: alt72 = 4 elif LA72 == IDENTIFIER or LA72 == STRING_LITERAL: alt72 = 5 elif LA72 == FLOATING_POINT_LITERAL: alt72 = 6 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("438:1: constant : ( HEX_LITERAL | OCTAL_LITERAL | DECIMAL_LITERAL | CHARACTER_LITERAL | ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ ( IDENTIFIER )* | FLOATING_POINT_LITERAL );", 72, 0, self.input) raise nvae if alt72 == 1: # C.g:439:9: HEX_LITERAL self.match(self.input, HEX_LITERAL, self.FOLLOW_HEX_LITERAL_in_constant1643) if self.failed: return elif alt72 == 2: # C.g:440:9: OCTAL_LITERAL self.match(self.input, OCTAL_LITERAL, self.FOLLOW_OCTAL_LITERAL_in_constant1653) if self.failed: return elif alt72 == 3: # C.g:441:9: DECIMAL_LITERAL self.match(self.input, DECIMAL_LITERAL, self.FOLLOW_DECIMAL_LITERAL_in_constant1663) if self.failed: return elif alt72 == 4: # C.g:442:7: CHARACTER_LITERAL self.match(self.input, CHARACTER_LITERAL, self.FOLLOW_CHARACTER_LITERAL_in_constant1671) if self.failed: return elif alt72 == 5: # C.g:443:7: ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ ( IDENTIFIER )* # C.g:443:7: ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ cnt70 = 0 while True: #loop70 alt70 = 2 LA70_0 = self.input.LA(1) if (LA70_0 == IDENTIFIER) : LA70_1 = self.input.LA(2) if (LA70_1 == STRING_LITERAL) : alt70 = 1 elif (LA70_1 == IDENTIFIER) : LA70_33 = self.input.LA(3) if (self.synpred138()) : alt70 = 1 elif (LA70_0 == STRING_LITERAL) : alt70 = 1 if alt70 == 1: # C.g:443:8: ( IDENTIFIER )* ( STRING_LITERAL )+ # C.g:443:8: ( IDENTIFIER )* while True: #loop68 alt68 = 2 LA68_0 = self.input.LA(1) if (LA68_0 == IDENTIFIER) : alt68 = 1 if alt68 == 1: # C.g:0:0: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_constant1680) if self.failed: return else: break #loop68 # C.g:443:20: ( STRING_LITERAL )+ cnt69 = 0 while True: #loop69 alt69 = 2 LA69_0 = self.input.LA(1) if (LA69_0 == STRING_LITERAL) : LA69_31 = self.input.LA(2) if (self.synpred137()) : alt69 = 1 if alt69 == 1: # C.g:0:0: STRING_LITERAL self.match(self.input, STRING_LITERAL, self.FOLLOW_STRING_LITERAL_in_constant1683) if self.failed: return else: if cnt69 >= 1: break #loop69 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(69, self.input) raise eee cnt69 += 1 else: if cnt70 >= 1: break #loop70 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(70, self.input) raise eee cnt70 += 1 # C.g:443:38: ( IDENTIFIER )* while True: #loop71 alt71 = 2 LA71_0 = self.input.LA(1) if (LA71_0 == IDENTIFIER) : alt71 = 1 if alt71 == 1: # C.g:0:0: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_constant1688) if self.failed: return else: break #loop71 elif alt72 == 6: # C.g:444:9: FLOATING_POINT_LITERAL self.match(self.input, FLOATING_POINT_LITERAL, self.FOLLOW_FLOATING_POINT_LITERAL_in_constant1699) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 45, constant_StartIndex) pass return # $ANTLR end constant class expression_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start expression # C.g:449:1: expression : assignment_expression ( ',' assignment_expression )* ; def expression(self, ): retval = self.expression_return() retval.start = self.input.LT(1) expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 46): return retval # C.g:450:2: ( assignment_expression ( ',' assignment_expression )* ) # C.g:450:4: assignment_expression ( ',' assignment_expression )* self.following.append(self.FOLLOW_assignment_expression_in_expression1715) self.assignment_expression() self.following.pop() if self.failed: return retval # C.g:450:26: ( ',' assignment_expression )* while True: #loop73 alt73 = 2 LA73_0 = self.input.LA(1) if (LA73_0 == 27) : alt73 = 1 if alt73 == 1: # C.g:450:27: ',' assignment_expression self.match(self.input, 27, self.FOLLOW_27_in_expression1718) if self.failed: return retval self.following.append(self.FOLLOW_assignment_expression_in_expression1720) self.assignment_expression() self.following.pop() if self.failed: return retval else: break #loop73 retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 46, expression_StartIndex) pass return retval # $ANTLR end expression # $ANTLR start constant_expression # C.g:453:1: constant_expression : conditional_expression ; def constant_expression(self, ): constant_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 47): return # C.g:454:2: ( conditional_expression ) # C.g:454:4: conditional_expression self.following.append(self.FOLLOW_conditional_expression_in_constant_expression1733) self.conditional_expression() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 47, constant_expression_StartIndex) pass return # $ANTLR end constant_expression # $ANTLR start assignment_expression # C.g:457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression ); def assignment_expression(self, ): assignment_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 48): return # C.g:458:2: ( lvalue assignment_operator assignment_expression | conditional_expression ) alt74 = 2 LA74 = self.input.LA(1) if LA74 == IDENTIFIER: LA74 = self.input.LA(2) if LA74 == 64: LA74_13 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 13, self.input) raise nvae elif LA74 == 62: LA74_14 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 14, self.input) raise nvae elif LA74 == 75: LA74_15 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 15, self.input) raise nvae elif LA74 == 66: LA74_16 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 16, self.input) raise nvae elif LA74 == 76: LA74_17 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 17, self.input) raise nvae elif LA74 == 72: LA74_18 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 18, self.input) raise nvae elif LA74 == 73: LA74_19 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 19, self.input) raise nvae elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 elif LA74 == STRING_LITERAL: LA74_21 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 21, self.input) raise nvae elif LA74 == IDENTIFIER: LA74_22 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 22, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 1, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_44 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 44, self.input) raise nvae elif LA74 == 62: LA74_45 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 45, self.input) raise nvae elif LA74 == 75: LA74_46 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 46, self.input) raise nvae elif LA74 == 66: LA74_47 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 47, self.input) raise nvae elif LA74 == 76: LA74_48 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 48, self.input) raise nvae elif LA74 == 72: LA74_49 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 49, self.input) raise nvae elif LA74 == 73: LA74_50 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 50, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 2, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_73 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 73, self.input) raise nvae elif LA74 == 62: LA74_74 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 74, self.input) raise nvae elif LA74 == 75: LA74_75 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 75, self.input) raise nvae elif LA74 == 66: LA74_76 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 76, self.input) raise nvae elif LA74 == 76: LA74_77 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 77, self.input) raise nvae elif LA74 == 72: LA74_78 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 78, self.input) raise nvae elif LA74 == 73: LA74_79 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 79, self.input) raise nvae elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 3, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_102 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 102, self.input) raise nvae elif LA74 == 62: LA74_103 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 103, self.input) raise nvae elif LA74 == 75: LA74_104 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 104, self.input) raise nvae elif LA74 == 66: LA74_105 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 105, self.input) raise nvae elif LA74 == 76: LA74_106 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 106, self.input) raise nvae elif LA74 == 72: LA74_107 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 107, self.input) raise nvae elif LA74 == 73: LA74_108 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 108, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 4, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_131 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 131, self.input) raise nvae elif LA74 == 62: LA74_132 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 132, self.input) raise nvae elif LA74 == 75: LA74_133 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 133, self.input) raise nvae elif LA74 == 66: LA74_134 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 134, self.input) raise nvae elif LA74 == 76: LA74_135 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 135, self.input) raise nvae elif LA74 == 72: LA74_136 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 136, self.input) raise nvae elif LA74 == 73: LA74_137 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 137, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 5, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74 = self.input.LA(2) if LA74 == IDENTIFIER: LA74_160 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 160, self.input) raise nvae elif LA74 == 64: LA74_161 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 161, self.input) raise nvae elif LA74 == 62: LA74_162 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 162, self.input) raise nvae elif LA74 == 75: LA74_163 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 163, self.input) raise nvae elif LA74 == 66: LA74_164 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 164, self.input) raise nvae elif LA74 == 76: LA74_165 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 165, self.input) raise nvae elif LA74 == 72: LA74_166 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 166, self.input) raise nvae elif LA74 == 73: LA74_167 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 167, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == STRING_LITERAL: LA74_189 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 189, self.input) raise nvae elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 6, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_191 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 191, self.input) raise nvae elif LA74 == 62: LA74_192 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 192, self.input) raise nvae elif LA74 == 75: LA74_193 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 193, self.input) raise nvae elif LA74 == 66: LA74_194 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 194, self.input) raise nvae elif LA74 == 76: LA74_195 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 195, self.input) raise nvae elif LA74 == 72: LA74_196 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 196, self.input) raise nvae elif LA74 == 73: LA74_197 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 197, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 7, self.input) raise nvae elif LA74 == 62: LA74 = self.input.LA(2) if LA74 == IDENTIFIER: LA74_220 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 220, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_221 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 221, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_222 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 222, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_223 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 223, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_224 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 224, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_225 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 225, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_226 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 226, self.input) raise nvae elif LA74 == 62: LA74_227 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 227, self.input) raise nvae elif LA74 == 72: LA74_228 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 228, self.input) raise nvae elif LA74 == 73: LA74_229 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 229, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_230 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 230, self.input) raise nvae elif LA74 == 74: LA74_231 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 231, self.input) raise nvae elif LA74 == 34 or LA74 == 35 or LA74 == 36 or LA74 == 37 or LA74 == 38 or LA74 == 39 or LA74 == 40 or LA74 == 41 or LA74 == 42 or LA74 == 45 or LA74 == 46 or LA74 == 48 or LA74 == 49 or LA74 == 50 or LA74 == 51 or LA74 == 52 or LA74 == 53 or LA74 == 54 or LA74 == 55 or LA74 == 56 or LA74 == 57 or LA74 == 58 or LA74 == 59 or LA74 == 60 or LA74 == 61: alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 8, self.input) raise nvae elif LA74 == 72: LA74 = self.input.LA(2) if LA74 == IDENTIFIER: LA74_244 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 244, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_245 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 245, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_246 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 246, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_247 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 247, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_248 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 248, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_249 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 249, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_250 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 250, self.input) raise nvae elif LA74 == 62: LA74_251 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 251, self.input) raise nvae elif LA74 == 72: LA74_252 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 252, self.input) raise nvae elif LA74 == 73: LA74_253 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 253, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_254 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 254, self.input) raise nvae elif LA74 == 74: LA74_255 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 255, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 9, self.input) raise nvae elif LA74 == 73: LA74 = self.input.LA(2) if LA74 == IDENTIFIER: LA74_256 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 256, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_257 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 257, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_258 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 258, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_259 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 259, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_260 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 260, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_261 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 261, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_262 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 262, self.input) raise nvae elif LA74 == 62: LA74_263 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 263, self.input) raise nvae elif LA74 == 72: LA74_264 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 264, self.input) raise nvae elif LA74 == 73: LA74_265 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 265, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_266 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 266, self.input) raise nvae elif LA74 == 74: LA74_267 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 267, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 10, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74 = self.input.LA(2) if LA74 == 62: LA74_268 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 268, self.input) raise nvae elif LA74 == IDENTIFIER: LA74_269 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 269, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_270 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 270, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_271 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 271, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_272 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 272, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_273 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 273, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_274 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 274, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_275 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 275, self.input) raise nvae elif LA74 == 72: LA74_276 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 276, self.input) raise nvae elif LA74 == 73: LA74_277 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 277, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_278 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 278, self.input) raise nvae elif LA74 == 74: LA74_279 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 279, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 11, self.input) raise nvae elif LA74 == 74: LA74 = self.input.LA(2) if LA74 == 62: LA74_280 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 280, self.input) raise nvae elif LA74 == IDENTIFIER: LA74_281 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 281, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_282 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 282, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_283 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 283, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_284 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 284, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_285 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 285, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_286 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 286, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_287 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 287, self.input) raise nvae elif LA74 == 72: LA74_288 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 288, self.input) raise nvae elif LA74 == 73: LA74_289 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 289, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_290 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 290, self.input) raise nvae elif LA74 == 74: LA74_291 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 291, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 12, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 0, self.input) raise nvae if alt74 == 1: # C.g:458:4: lvalue assignment_operator assignment_expression self.following.append(self.FOLLOW_lvalue_in_assignment_expression1744) self.lvalue() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_assignment_operator_in_assignment_expression1746) self.assignment_operator() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_assignment_expression_in_assignment_expression1748) self.assignment_expression() self.following.pop() if self.failed: return elif alt74 == 2: # C.g:459:4: conditional_expression self.following.append(self.FOLLOW_conditional_expression_in_assignment_expression1753) self.conditional_expression() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 48, assignment_expression_StartIndex) pass return # $ANTLR end assignment_expression # $ANTLR start lvalue # C.g:462:1: lvalue : unary_expression ; def lvalue(self, ): lvalue_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 49): return # C.g:463:2: ( unary_expression ) # C.g:463:4: unary_expression self.following.append(self.FOLLOW_unary_expression_in_lvalue1765) self.unary_expression() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 49, lvalue_StartIndex) pass return # $ANTLR end lvalue # $ANTLR start assignment_operator # C.g:466:1: assignment_operator : ( '=' | '*=' | '/=' | '%=' | '+=' | '-=' | '<<=' | '>>=' | '&=' | '^=' | '|=' ); def assignment_operator(self, ): assignment_operator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 50): return # C.g:467:2: ( '=' | '*=' | '/=' | '%=' | '+=' | '-=' | '<<=' | '>>=' | '&=' | '^=' | '|=' ) # C.g: if self.input.LA(1) == 28 or (80 <= self.input.LA(1) <= 89): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_assignment_operator0 ) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 50, assignment_operator_StartIndex) pass return # $ANTLR end assignment_operator # $ANTLR start conditional_expression # C.g:480:1: conditional_expression : e= logical_or_expression ( '?' expression ':' conditional_expression )? ; def conditional_expression(self, ): conditional_expression_StartIndex = self.input.index() e = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 51): return # C.g:481:2: (e= logical_or_expression ( '?' expression ':' conditional_expression )? ) # C.g:481:4: e= logical_or_expression ( '?' expression ':' conditional_expression )? self.following.append(self.FOLLOW_logical_or_expression_in_conditional_expression1839) e = self.logical_or_expression() self.following.pop() if self.failed: return # C.g:481:28: ( '?' expression ':' conditional_expression )? alt75 = 2 LA75_0 = self.input.LA(1) if (LA75_0 == 90) : alt75 = 1 if alt75 == 1: # C.g:481:29: '?' expression ':' conditional_expression self.match(self.input, 90, self.FOLLOW_90_in_conditional_expression1842) if self.failed: return self.following.append(self.FOLLOW_expression_in_conditional_expression1844) self.expression() self.following.pop() if self.failed: return self.match(self.input, 47, self.FOLLOW_47_in_conditional_expression1846) if self.failed: return self.following.append(self.FOLLOW_conditional_expression_in_conditional_expression1848) self.conditional_expression() self.following.pop() if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start,e.stop)) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 51, conditional_expression_StartIndex) pass return # $ANTLR end conditional_expression class logical_or_expression_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start logical_or_expression # C.g:484:1: logical_or_expression : logical_and_expression ( '||' logical_and_expression )* ; def logical_or_expression(self, ): retval = self.logical_or_expression_return() retval.start = self.input.LT(1) logical_or_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 52): return retval # C.g:485:2: ( logical_and_expression ( '||' logical_and_expression )* ) # C.g:485:4: logical_and_expression ( '||' logical_and_expression )* self.following.append(self.FOLLOW_logical_and_expression_in_logical_or_expression1863) self.logical_and_expression() self.following.pop() if self.failed: return retval # C.g:485:27: ( '||' logical_and_expression )* while True: #loop76 alt76 = 2 LA76_0 = self.input.LA(1) if (LA76_0 == 91) : alt76 = 1 if alt76 == 1: # C.g:485:28: '||' logical_and_expression self.match(self.input, 91, self.FOLLOW_91_in_logical_or_expression1866) if self.failed: return retval self.following.append(self.FOLLOW_logical_and_expression_in_logical_or_expression1868) self.logical_and_expression() self.following.pop() if self.failed: return retval else: break #loop76 retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 52, logical_or_expression_StartIndex) pass return retval # $ANTLR end logical_or_expression # $ANTLR start logical_and_expression # C.g:488:1: logical_and_expression : inclusive_or_expression ( '&&' inclusive_or_expression )* ; def logical_and_expression(self, ): logical_and_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 53): return # C.g:489:2: ( inclusive_or_expression ( '&&' inclusive_or_expression )* ) # C.g:489:4: inclusive_or_expression ( '&&' inclusive_or_expression )* self.following.append(self.FOLLOW_inclusive_or_expression_in_logical_and_expression1881) self.inclusive_or_expression() self.following.pop() if self.failed: return # C.g:489:28: ( '&&' inclusive_or_expression )* while True: #loop77 alt77 = 2 LA77_0 = self.input.LA(1) if (LA77_0 == 92) : alt77 = 1 if alt77 == 1: # C.g:489:29: '&&' inclusive_or_expression self.match(self.input, 92, self.FOLLOW_92_in_logical_and_expression1884) if self.failed: return self.following.append(self.FOLLOW_inclusive_or_expression_in_logical_and_expression1886) self.inclusive_or_expression() self.following.pop() if self.failed: return else: break #loop77 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 53, logical_and_expression_StartIndex) pass return # $ANTLR end logical_and_expression # $ANTLR start inclusive_or_expression # C.g:492:1: inclusive_or_expression : exclusive_or_expression ( '|' exclusive_or_expression )* ; def inclusive_or_expression(self, ): inclusive_or_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 54): return # C.g:493:2: ( exclusive_or_expression ( '|' exclusive_or_expression )* ) # C.g:493:4: exclusive_or_expression ( '|' exclusive_or_expression )* self.following.append(self.FOLLOW_exclusive_or_expression_in_inclusive_or_expression1899) self.exclusive_or_expression() self.following.pop() if self.failed: return # C.g:493:28: ( '|' exclusive_or_expression )* while True: #loop78 alt78 = 2 LA78_0 = self.input.LA(1) if (LA78_0 == 93) : alt78 = 1 if alt78 == 1: # C.g:493:29: '|' exclusive_or_expression self.match(self.input, 93, self.FOLLOW_93_in_inclusive_or_expression1902) if self.failed: return self.following.append(self.FOLLOW_exclusive_or_expression_in_inclusive_or_expression1904) self.exclusive_or_expression() self.following.pop() if self.failed: return else: break #loop78 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 54, inclusive_or_expression_StartIndex) pass return # $ANTLR end inclusive_or_expression # $ANTLR start exclusive_or_expression # C.g:496:1: exclusive_or_expression : and_expression ( '^' and_expression )* ; def exclusive_or_expression(self, ): exclusive_or_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 55): return # C.g:497:2: ( and_expression ( '^' and_expression )* ) # C.g:497:4: and_expression ( '^' and_expression )* self.following.append(self.FOLLOW_and_expression_in_exclusive_or_expression1917) self.and_expression() self.following.pop() if self.failed: return # C.g:497:19: ( '^' and_expression )* while True: #loop79 alt79 = 2 LA79_0 = self.input.LA(1) if (LA79_0 == 94) : alt79 = 1 if alt79 == 1: # C.g:497:20: '^' and_expression self.match(self.input, 94, self.FOLLOW_94_in_exclusive_or_expression1920) if self.failed: return self.following.append(self.FOLLOW_and_expression_in_exclusive_or_expression1922) self.and_expression() self.following.pop() if self.failed: return else: break #loop79 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 55, exclusive_or_expression_StartIndex) pass return # $ANTLR end exclusive_or_expression # $ANTLR start and_expression # C.g:500:1: and_expression : equality_expression ( '&' equality_expression )* ; def and_expression(self, ): and_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 56): return # C.g:501:2: ( equality_expression ( '&' equality_expression )* ) # C.g:501:4: equality_expression ( '&' equality_expression )* self.following.append(self.FOLLOW_equality_expression_in_and_expression1935) self.equality_expression() self.following.pop() if self.failed: return # C.g:501:24: ( '&' equality_expression )* while True: #loop80 alt80 = 2 LA80_0 = self.input.LA(1) if (LA80_0 == 77) : alt80 = 1 if alt80 == 1: # C.g:501:25: '&' equality_expression self.match(self.input, 77, self.FOLLOW_77_in_and_expression1938) if self.failed: return self.following.append(self.FOLLOW_equality_expression_in_and_expression1940) self.equality_expression() self.following.pop() if self.failed: return else: break #loop80 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 56, and_expression_StartIndex) pass return # $ANTLR end and_expression # $ANTLR start equality_expression # C.g:503:1: equality_expression : relational_expression ( ( '==' | '!=' ) relational_expression )* ; def equality_expression(self, ): equality_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 57): return # C.g:504:2: ( relational_expression ( ( '==' | '!=' ) relational_expression )* ) # C.g:504:4: relational_expression ( ( '==' | '!=' ) relational_expression )* self.following.append(self.FOLLOW_relational_expression_in_equality_expression1952) self.relational_expression() self.following.pop() if self.failed: return # C.g:504:26: ( ( '==' | '!=' ) relational_expression )* while True: #loop81 alt81 = 2 LA81_0 = self.input.LA(1) if ((95 <= LA81_0 <= 96)) : alt81 = 1 if alt81 == 1: # C.g:504:27: ( '==' | '!=' ) relational_expression if (95 <= self.input.LA(1) <= 96): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_equality_expression1955 ) raise mse self.following.append(self.FOLLOW_relational_expression_in_equality_expression1961) self.relational_expression() self.following.pop() if self.failed: return else: break #loop81 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 57, equality_expression_StartIndex) pass return # $ANTLR end equality_expression # $ANTLR start relational_expression # C.g:507:1: relational_expression : shift_expression ( ( '<' | '>' | '<=' | '>=' ) shift_expression )* ; def relational_expression(self, ): relational_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 58): return # C.g:508:2: ( shift_expression ( ( '<' | '>' | '<=' | '>=' ) shift_expression )* ) # C.g:508:4: shift_expression ( ( '<' | '>' | '<=' | '>=' ) shift_expression )* self.following.append(self.FOLLOW_shift_expression_in_relational_expression1975) self.shift_expression() self.following.pop() if self.failed: return # C.g:508:21: ( ( '<' | '>' | '<=' | '>=' ) shift_expression )* while True: #loop82 alt82 = 2 LA82_0 = self.input.LA(1) if ((97 <= LA82_0 <= 100)) : alt82 = 1 if alt82 == 1: # C.g:508:22: ( '<' | '>' | '<=' | '>=' ) shift_expression if (97 <= self.input.LA(1) <= 100): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_relational_expression1978 ) raise mse self.following.append(self.FOLLOW_shift_expression_in_relational_expression1988) self.shift_expression() self.following.pop() if self.failed: return else: break #loop82 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 58, relational_expression_StartIndex) pass return # $ANTLR end relational_expression # $ANTLR start shift_expression # C.g:511:1: shift_expression : additive_expression ( ( '<<' | '>>' ) additive_expression )* ; def shift_expression(self, ): shift_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 59): return # C.g:512:2: ( additive_expression ( ( '<<' | '>>' ) additive_expression )* ) # C.g:512:4: additive_expression ( ( '<<' | '>>' ) additive_expression )* self.following.append(self.FOLLOW_additive_expression_in_shift_expression2001) self.additive_expression() self.following.pop() if self.failed: return # C.g:512:24: ( ( '<<' | '>>' ) additive_expression )* while True: #loop83 alt83 = 2 LA83_0 = self.input.LA(1) if ((101 <= LA83_0 <= 102)) : alt83 = 1 if alt83 == 1: # C.g:512:25: ( '<<' | '>>' ) additive_expression if (101 <= self.input.LA(1) <= 102): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_shift_expression2004 ) raise mse self.following.append(self.FOLLOW_additive_expression_in_shift_expression2010) self.additive_expression() self.following.pop() if self.failed: return else: break #loop83 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 59, shift_expression_StartIndex) pass return # $ANTLR end shift_expression # $ANTLR start statement # C.g:517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration ); def statement(self, ): statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 60): return # C.g:518:2: ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration ) alt84 = 11 LA84 = self.input.LA(1) if LA84 == IDENTIFIER: LA84 = self.input.LA(2) if LA84 == 62: LA84_43 = self.input.LA(3) if (self.synpred169()) : alt84 = 3 elif (self.synpred173()) : alt84 = 7 elif (self.synpred174()) : alt84 = 8 elif (True) : alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 43, self.input) raise nvae elif LA84 == 47: alt84 = 1 elif LA84 == STRING_LITERAL or LA84 == 27 or LA84 == 28 or LA84 == 64 or LA84 == 68 or LA84 == 69 or LA84 == 70 or LA84 == 71 or LA84 == 72 or LA84 == 73 or LA84 == 75 or LA84 == 76 or LA84 == 77 or LA84 == 80 or LA84 == 81 or LA84 == 82 or LA84 == 83 or LA84 == 84 or LA84 == 85 or LA84 == 86 or LA84 == 87 or LA84 == 88 or LA84 == 89 or LA84 == 90 or LA84 == 91 or LA84 == 92 or LA84 == 93 or LA84 == 94 or LA84 == 95 or LA84 == 96 or LA84 == 97 or LA84 == 98 or LA84 == 99 or LA84 == 100 or LA84 == 101 or LA84 == 102: alt84 = 3 elif LA84 == 66: LA84_47 = self.input.LA(3) if (self.synpred169()) : alt84 = 3 elif (True) : alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 47, self.input) raise nvae elif LA84 == IDENTIFIER: LA84_53 = self.input.LA(3) if (self.synpred169()) : alt84 = 3 elif (True) : alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 53, self.input) raise nvae elif LA84 == 25: LA84_68 = self.input.LA(3) if (self.synpred169()) : alt84 = 3 elif (True) : alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 68, self.input) raise nvae elif LA84 == 29 or LA84 == 30 or LA84 == 31 or LA84 == 32 or LA84 == 33 or LA84 == 34 or LA84 == 35 or LA84 == 36 or LA84 == 37 or LA84 == 38 or LA84 == 39 or LA84 == 40 or LA84 == 41 or LA84 == 42 or LA84 == 45 or LA84 == 46 or LA84 == 48 or LA84 == 49 or LA84 == 50 or LA84 == 51 or LA84 == 52 or LA84 == 53 or LA84 == 54 or LA84 == 55 or LA84 == 56 or LA84 == 57 or LA84 == 58 or LA84 == 59 or LA84 == 60 or LA84 == 61: alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 1, self.input) raise nvae elif LA84 == 106 or LA84 == 107: alt84 = 1 elif LA84 == 43: alt84 = 2 elif LA84 == HEX_LITERAL or LA84 == OCTAL_LITERAL or LA84 == DECIMAL_LITERAL or LA84 == CHARACTER_LITERAL or LA84 == STRING_LITERAL or LA84 == FLOATING_POINT_LITERAL or LA84 == 25 or LA84 == 62 or LA84 == 66 or LA84 == 68 or LA84 == 69 or LA84 == 72 or LA84 == 73 or LA84 == 74 or LA84 == 77 or LA84 == 78 or LA84 == 79: alt84 = 3 elif LA84 == 108 or LA84 == 110: alt84 = 4 elif LA84 == 111 or LA84 == 112 or LA84 == 113: alt84 = 5 elif LA84 == 114 or LA84 == 115 or LA84 == 116 or LA84 == 117: alt84 = 6 elif LA84 == 103: alt84 = 8 elif LA84 == 104: alt84 = 9 elif LA84 == 105: alt84 = 10 elif LA84 == 26 or LA84 == 29 or LA84 == 30 or LA84 == 31 or LA84 == 32 or LA84 == 33 or LA84 == 34 or LA84 == 35 or LA84 == 36 or LA84 == 37 or LA84 == 38 or LA84 == 39 or LA84 == 40 or LA84 == 41 or LA84 == 42 or LA84 == 45 or LA84 == 46 or LA84 == 48 or LA84 == 49 or LA84 == 50 or LA84 == 51 or LA84 == 52 or LA84 == 53 or LA84 == 54 or LA84 == 55 or LA84 == 56 or LA84 == 57 or LA84 == 58 or LA84 == 59 or LA84 == 60 or LA84 == 61: alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 0, self.input) raise nvae if alt84 == 1: # C.g:518:4: labeled_statement self.following.append(self.FOLLOW_labeled_statement_in_statement2025) self.labeled_statement() self.following.pop() if self.failed: return elif alt84 == 2: # C.g:519:4: compound_statement self.following.append(self.FOLLOW_compound_statement_in_statement2030) self.compound_statement() self.following.pop() if self.failed: return elif alt84 == 3: # C.g:520:4: expression_statement self.following.append(self.FOLLOW_expression_statement_in_statement2035) self.expression_statement() self.following.pop() if self.failed: return elif alt84 == 4: # C.g:521:4: selection_statement self.following.append(self.FOLLOW_selection_statement_in_statement2040) self.selection_statement() self.following.pop() if self.failed: return elif alt84 == 5: # C.g:522:4: iteration_statement self.following.append(self.FOLLOW_iteration_statement_in_statement2045) self.iteration_statement() self.following.pop() if self.failed: return elif alt84 == 6: # C.g:523:4: jump_statement self.following.append(self.FOLLOW_jump_statement_in_statement2050) self.jump_statement() self.following.pop() if self.failed: return elif alt84 == 7: # C.g:524:4: macro_statement self.following.append(self.FOLLOW_macro_statement_in_statement2055) self.macro_statement() self.following.pop() if self.failed: return elif alt84 == 8: # C.g:525:4: asm2_statement self.following.append(self.FOLLOW_asm2_statement_in_statement2060) self.asm2_statement() self.following.pop() if self.failed: return elif alt84 == 9: # C.g:526:4: asm1_statement self.following.append(self.FOLLOW_asm1_statement_in_statement2065) self.asm1_statement() self.following.pop() if self.failed: return elif alt84 == 10: # C.g:527:4: asm_statement self.following.append(self.FOLLOW_asm_statement_in_statement2070) self.asm_statement() self.following.pop() if self.failed: return elif alt84 == 11: # C.g:528:4: declaration self.following.append(self.FOLLOW_declaration_in_statement2075) self.declaration() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 60, statement_StartIndex) pass return # $ANTLR end statement # $ANTLR start asm2_statement # C.g:531:1: asm2_statement : ( '__asm__' )? IDENTIFIER '(' (~ ( ';' ) )* ')' ';' ; def asm2_statement(self, ): asm2_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 61): return # C.g:532:2: ( ( '__asm__' )? IDENTIFIER '(' (~ ( ';' ) )* ')' ';' ) # C.g:532:4: ( '__asm__' )? IDENTIFIER '(' (~ ( ';' ) )* ')' ';' # C.g:532:4: ( '__asm__' )? alt85 = 2 LA85_0 = self.input.LA(1) if (LA85_0 == 103) : alt85 = 1 if alt85 == 1: # C.g:0:0: '__asm__' self.match(self.input, 103, self.FOLLOW_103_in_asm2_statement2086) if self.failed: return self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_asm2_statement2089) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_asm2_statement2091) if self.failed: return # C.g:532:30: (~ ( ';' ) )* while True: #loop86 alt86 = 2 LA86_0 = self.input.LA(1) if (LA86_0 == 63) : LA86_1 = self.input.LA(2) if ((IDENTIFIER <= LA86_1 <= LINE_COMMAND) or (26 <= LA86_1 <= 117)) : alt86 = 1 elif ((IDENTIFIER <= LA86_0 <= LINE_COMMAND) or (26 <= LA86_0 <= 62) or (64 <= LA86_0 <= 117)) : alt86 = 1 if alt86 == 1: # C.g:532:31: ~ ( ';' ) if (IDENTIFIER <= self.input.LA(1) <= LINE_COMMAND) or (26 <= self.input.LA(1) <= 117): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_asm2_statement2094 ) raise mse else: break #loop86 self.match(self.input, 63, self.FOLLOW_63_in_asm2_statement2101) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_asm2_statement2103) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 61, asm2_statement_StartIndex) pass return # $ANTLR end asm2_statement # $ANTLR start asm1_statement # C.g:535:1: asm1_statement : '_asm' '{' (~ ( '}' ) )* '}' ; def asm1_statement(self, ): asm1_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 62): return # C.g:536:2: ( '_asm' '{' (~ ( '}' ) )* '}' ) # C.g:536:4: '_asm' '{' (~ ( '}' ) )* '}' self.match(self.input, 104, self.FOLLOW_104_in_asm1_statement2115) if self.failed: return self.match(self.input, 43, self.FOLLOW_43_in_asm1_statement2117) if self.failed: return # C.g:536:15: (~ ( '}' ) )* while True: #loop87 alt87 = 2 LA87_0 = self.input.LA(1) if ((IDENTIFIER <= LA87_0 <= 43) or (45 <= LA87_0 <= 117)) : alt87 = 1 if alt87 == 1: # C.g:536:16: ~ ( '}' ) if (IDENTIFIER <= self.input.LA(1) <= 43) or (45 <= self.input.LA(1) <= 117): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_asm1_statement2120 ) raise mse else: break #loop87 self.match(self.input, 44, self.FOLLOW_44_in_asm1_statement2127) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 62, asm1_statement_StartIndex) pass return # $ANTLR end asm1_statement # $ANTLR start asm_statement # C.g:539:1: asm_statement : '__asm' '{' (~ ( '}' ) )* '}' ; def asm_statement(self, ): asm_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 63): return # C.g:540:2: ( '__asm' '{' (~ ( '}' ) )* '}' ) # C.g:540:4: '__asm' '{' (~ ( '}' ) )* '}' self.match(self.input, 105, self.FOLLOW_105_in_asm_statement2138) if self.failed: return self.match(self.input, 43, self.FOLLOW_43_in_asm_statement2140) if self.failed: return # C.g:540:16: (~ ( '}' ) )* while True: #loop88 alt88 = 2 LA88_0 = self.input.LA(1) if ((IDENTIFIER <= LA88_0 <= 43) or (45 <= LA88_0 <= 117)) : alt88 = 1 if alt88 == 1: # C.g:540:17: ~ ( '}' ) if (IDENTIFIER <= self.input.LA(1) <= 43) or (45 <= self.input.LA(1) <= 117): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_asm_statement2143 ) raise mse else: break #loop88 self.match(self.input, 44, self.FOLLOW_44_in_asm_statement2150) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 63, asm_statement_StartIndex) pass return # $ANTLR end asm_statement # $ANTLR start macro_statement # C.g:543:1: macro_statement : IDENTIFIER '(' ( declaration )* ( statement_list )? ( expression )? ')' ; def macro_statement(self, ): macro_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 64): return # C.g:544:2: ( IDENTIFIER '(' ( declaration )* ( statement_list )? ( expression )? ')' ) # C.g:544:4: IDENTIFIER '(' ( declaration )* ( statement_list )? ( expression )? ')' self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_macro_statement2162) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_macro_statement2164) if self.failed: return # C.g:544:19: ( declaration )* while True: #loop89 alt89 = 2 LA89 = self.input.LA(1) if LA89 == IDENTIFIER: LA89 = self.input.LA(2) if LA89 == 62: LA89_45 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_47 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 66: LA89_50 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_68 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_71 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_72 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_73 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_74 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_75 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_76 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_77 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_78 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_79 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_80 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_81 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_82 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_83 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_84 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_85 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_86 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 26: LA89 = self.input.LA(2) if LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_87 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_88 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_89 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_90 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_91 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_92 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_93 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_94 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_95 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_96 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_97 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_98 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_99 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_100 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 66: LA89_101 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_102 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_103 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_104 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_105 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89 = self.input.LA(2) if LA89 == 66: LA89_106 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_107 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_108 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_109 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_110 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_111 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_112 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_113 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_114 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_115 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_116 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_117 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_118 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_119 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_120 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_121 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_122 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_123 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_124 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_125 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89 = self.input.LA(2) if LA89 == 66: LA89_126 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_127 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_128 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_129 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_130 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_131 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_132 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_133 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_134 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_135 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_136 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_137 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_138 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_139 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_140 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_141 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_142 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_143 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_144 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_145 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89 = self.input.LA(2) if LA89 == 66: LA89_146 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_147 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_148 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_149 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_150 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_151 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_152 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_153 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_154 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_155 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_156 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_157 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_158 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_159 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_160 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_161 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_162 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_163 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_164 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_165 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89 = self.input.LA(2) if LA89 == 66: LA89_166 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_167 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_168 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_169 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_170 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_171 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_172 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_173 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_174 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_175 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_176 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_177 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_178 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_179 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_180 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_181 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_182 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_183 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_184 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_185 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89 = self.input.LA(2) if LA89 == 66: LA89_186 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_187 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_188 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_189 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_190 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_191 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_192 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_193 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_194 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_195 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_196 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_197 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_198 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_199 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_200 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_201 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_202 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_203 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_204 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_205 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89 = self.input.LA(2) if LA89 == 66: LA89_206 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_207 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_208 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_209 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_210 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_211 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_212 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_213 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_214 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_215 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_216 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_217 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_218 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_219 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_220 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_221 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_222 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_223 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_224 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_225 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89 = self.input.LA(2) if LA89 == 66: LA89_226 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_227 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_228 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_229 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_230 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_231 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_232 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_233 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_234 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_235 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_236 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_237 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_238 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_239 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_240 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_241 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_242 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_243 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_244 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_245 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89 = self.input.LA(2) if LA89 == 66: LA89_246 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_247 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_248 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_249 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_250 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_251 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_252 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_253 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_254 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_255 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_256 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_257 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_258 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_259 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_260 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_261 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_262 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_263 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_264 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_265 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89 = self.input.LA(2) if LA89 == 66: LA89_266 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_267 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_268 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_269 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_270 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_271 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_272 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_273 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_274 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_275 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_276 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_277 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_278 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_279 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_280 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_281 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_282 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_283 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_284 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_285 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89 = self.input.LA(2) if LA89 == 66: LA89_286 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_287 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_288 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_289 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_290 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_291 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_292 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_293 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_294 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_295 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_296 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_297 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_298 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_299 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_300 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_301 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_302 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_303 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_304 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_305 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_40 = self.input.LA(2) if (LA89_40 == IDENTIFIER) : LA89_306 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif (LA89_40 == 43) : LA89_307 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_41 = self.input.LA(2) if (LA89_41 == 43) : LA89_308 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif (LA89_41 == IDENTIFIER) : LA89_309 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 58 or LA89 == 59 or LA89 == 60 or LA89 == 61: LA89 = self.input.LA(2) if LA89 == 66: LA89_310 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_311 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_312 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_313 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_314 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_315 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_316 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_317 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_318 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_319 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_320 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_321 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_322 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_323 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_324 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_325 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_326 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_327 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_328 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_329 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 if alt89 == 1: # C.g:0:0: declaration self.following.append(self.FOLLOW_declaration_in_macro_statement2166) self.declaration() self.following.pop() if self.failed: return else: break #loop89 # C.g:544:33: ( statement_list )? alt90 = 2 LA90 = self.input.LA(1) if LA90 == IDENTIFIER: LA90 = self.input.LA(2) if LA90 == 25 or LA90 == 29 or LA90 == 30 or LA90 == 31 or LA90 == 32 or LA90 == 33 or LA90 == 34 or LA90 == 35 or LA90 == 36 or LA90 == 37 or LA90 == 38 or LA90 == 39 or LA90 == 40 or LA90 == 41 or LA90 == 42 or LA90 == 45 or LA90 == 46 or LA90 == 47 or LA90 == 48 or LA90 == 49 or LA90 == 50 or LA90 == 51 or LA90 == 52 or LA90 == 53 or LA90 == 54 or LA90 == 55 or LA90 == 56 or LA90 == 57 or LA90 == 58 or LA90 == 59 or LA90 == 60 or LA90 == 61: alt90 = 1 elif LA90 == 62: LA90_45 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_46 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == IDENTIFIER: LA90_47 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 64: LA90_48 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_49 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_50 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_51 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_52 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_53 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_54 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_55 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_56 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_57 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_58 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_59 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_60 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_61 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_62 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_63 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_64 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_65 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_66 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_67 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_70 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25 or LA90 == 26 or LA90 == 29 or LA90 == 30 or LA90 == 31 or LA90 == 32 or LA90 == 33 or LA90 == 34 or LA90 == 35 or LA90 == 36 or LA90 == 37 or LA90 == 38 or LA90 == 39 or LA90 == 40 or LA90 == 41 or LA90 == 42 or LA90 == 43 or LA90 == 45 or LA90 == 46 or LA90 == 48 or LA90 == 49 or LA90 == 50 or LA90 == 51 or LA90 == 52 or LA90 == 53 or LA90 == 54 or LA90 == 55 or LA90 == 56 or LA90 == 57 or LA90 == 58 or LA90 == 59 or LA90 == 60 or LA90 == 61 or LA90 == 103 or LA90 == 104 or LA90 == 105 or LA90 == 106 or LA90 == 107 or LA90 == 108 or LA90 == 110 or LA90 == 111 or LA90 == 112 or LA90 == 113 or LA90 == 114 or LA90 == 115 or LA90 == 116 or LA90 == 117: alt90 = 1 elif LA90 == HEX_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_87 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_88 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_89 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_90 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_91 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_92 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_93 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_94 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_95 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_96 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_97 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_98 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_99 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_100 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_101 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_102 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_103 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_104 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_105 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_106 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_107 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_108 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_111 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_112 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_113 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_114 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_115 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_116 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_117 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_118 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_119 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_120 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_121 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_122 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_123 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_124 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_125 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_126 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_127 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_128 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_129 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_130 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_131 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_134 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_135 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_136 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_137 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_138 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_139 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_140 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_141 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_142 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_143 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_144 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_145 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_146 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_147 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_148 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_149 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_150 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_151 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_152 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_153 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_154 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_155 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_156 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_159 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_160 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_161 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_162 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_163 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_164 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_165 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_166 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_167 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_168 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_169 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_170 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_171 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_172 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_173 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_174 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_175 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_176 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_177 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_178 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_179 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_181 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90 = self.input.LA(2) if LA90 == IDENTIFIER: LA90_183 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 64: LA90_184 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_185 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_186 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_187 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_188 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_189 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_190 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_191 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_192 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_193 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_194 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_195 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_196 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_197 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_198 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_199 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_200 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_201 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_202 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_203 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_204 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_205 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_206 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_209 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_210 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_211 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_212 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_213 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_214 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_215 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_216 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_217 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_218 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_219 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_220 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_221 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_222 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_223 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_224 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_225 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_226 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_227 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_228 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_229 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_230 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == 62: LA90 = self.input.LA(2) if LA90 == IDENTIFIER: LA90_233 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_234 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_235 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_236 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_237 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_238 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_239 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_240 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_241 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_242 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_243 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_244 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 49 or LA90 == 50 or LA90 == 51 or LA90 == 52 or LA90 == 53 or LA90 == 54 or LA90 == 55 or LA90 == 56 or LA90 == 57 or LA90 == 58 or LA90 == 59 or LA90 == 60 or LA90 == 61: LA90_245 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 34: LA90_246 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 35: LA90_247 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 36: LA90_248 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 37: LA90_249 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 38: LA90_250 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 39: LA90_251 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 40: LA90_252 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 41: LA90_253 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 42: LA90_254 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 45 or LA90 == 46: LA90_255 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 48: LA90_256 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90 = self.input.LA(2) if LA90 == IDENTIFIER: LA90_257 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_258 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_259 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_260 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_261 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_262 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_263 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_264 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_265 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_266 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_267 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_268 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90 = self.input.LA(2) if LA90 == IDENTIFIER: LA90_269 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_270 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_271 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_272 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_273 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_274 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_275 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_276 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_277 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_278 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_279 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_280 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90 = self.input.LA(2) if LA90 == 62: LA90_281 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == IDENTIFIER: LA90_282 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_283 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_284 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_285 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_286 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_287 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_288 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_289 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_290 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_291 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_292 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90 = self.input.LA(2) if LA90 == 62: LA90_293 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == IDENTIFIER: LA90_294 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_295 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_296 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_297 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_298 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_299 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_300 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_301 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_302 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_303 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_304 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 if alt90 == 1: # C.g:0:0: statement_list self.following.append(self.FOLLOW_statement_list_in_macro_statement2170) self.statement_list() self.following.pop() if self.failed: return # C.g:544:49: ( expression )? alt91 = 2 LA91_0 = self.input.LA(1) if ((IDENTIFIER <= LA91_0 <= FLOATING_POINT_LITERAL) or LA91_0 == 62 or LA91_0 == 66 or (68 <= LA91_0 <= 69) or (72 <= LA91_0 <= 74) or (77 <= LA91_0 <= 79)) : alt91 = 1 if alt91 == 1: # C.g:0:0: expression self.following.append(self.FOLLOW_expression_in_macro_statement2173) self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_macro_statement2176) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 64, macro_statement_StartIndex) pass return # $ANTLR end macro_statement # $ANTLR start labeled_statement # C.g:547:1: labeled_statement : ( IDENTIFIER ':' statement | 'case' constant_expression ':' statement | 'default' ':' statement ); def labeled_statement(self, ): labeled_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 65): return # C.g:548:2: ( IDENTIFIER ':' statement | 'case' constant_expression ':' statement | 'default' ':' statement ) alt92 = 3 LA92 = self.input.LA(1) if LA92 == IDENTIFIER: alt92 = 1 elif LA92 == 106: alt92 = 2 elif LA92 == 107: alt92 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("547:1: labeled_statement : ( IDENTIFIER ':' statement | 'case' constant_expression ':' statement | 'default' ':' statement );", 92, 0, self.input) raise nvae if alt92 == 1: # C.g:548:4: IDENTIFIER ':' statement self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_labeled_statement2188) if self.failed: return self.match(self.input, 47, self.FOLLOW_47_in_labeled_statement2190) if self.failed: return self.following.append(self.FOLLOW_statement_in_labeled_statement2192) self.statement() self.following.pop() if self.failed: return elif alt92 == 2: # C.g:549:4: 'case' constant_expression ':' statement self.match(self.input, 106, self.FOLLOW_106_in_labeled_statement2197) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_labeled_statement2199) self.constant_expression() self.following.pop() if self.failed: return self.match(self.input, 47, self.FOLLOW_47_in_labeled_statement2201) if self.failed: return self.following.append(self.FOLLOW_statement_in_labeled_statement2203) self.statement() self.following.pop() if self.failed: return elif alt92 == 3: # C.g:550:4: 'default' ':' statement self.match(self.input, 107, self.FOLLOW_107_in_labeled_statement2208) if self.failed: return self.match(self.input, 47, self.FOLLOW_47_in_labeled_statement2210) if self.failed: return self.following.append(self.FOLLOW_statement_in_labeled_statement2212) self.statement() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 65, labeled_statement_StartIndex) pass return # $ANTLR end labeled_statement class compound_statement_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start compound_statement # C.g:553:1: compound_statement : '{' ( declaration )* ( statement_list )? '}' ; def compound_statement(self, ): retval = self.compound_statement_return() retval.start = self.input.LT(1) compound_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 66): return retval # C.g:554:2: ( '{' ( declaration )* ( statement_list )? '}' ) # C.g:554:4: '{' ( declaration )* ( statement_list )? '}' self.match(self.input, 43, self.FOLLOW_43_in_compound_statement2223) if self.failed: return retval # C.g:554:8: ( declaration )* while True: #loop93 alt93 = 2 LA93 = self.input.LA(1) if LA93 == IDENTIFIER: LA93 = self.input.LA(2) if LA93 == 62: LA93_44 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_47 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 66: LA93_48 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_49 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_50 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_51 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_52 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_53 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_54 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_55 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_56 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_57 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_58 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_59 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_60 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_61 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_62 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_63 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_64 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_65 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 26: LA93 = self.input.LA(2) if LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_86 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_87 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_88 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_89 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_90 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_91 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_92 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_93 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_94 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_95 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_96 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_97 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_98 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_99 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 66: LA93_100 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_101 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_102 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_103 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_104 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93 = self.input.LA(2) if LA93 == 66: LA93_105 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_106 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_107 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_108 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_109 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_110 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_111 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_112 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_113 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_114 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_115 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_116 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_117 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_118 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_119 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_120 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_121 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_122 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_123 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_124 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93 = self.input.LA(2) if LA93 == 66: LA93_125 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_126 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_127 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_128 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_129 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_130 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_131 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_132 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_133 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_134 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_135 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_136 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_137 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_138 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_139 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_140 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_141 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_142 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_143 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_144 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93 = self.input.LA(2) if LA93 == 66: LA93_145 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_146 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_147 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_148 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_149 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_150 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_151 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_152 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_153 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_154 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_155 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_156 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_157 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_158 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_159 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_160 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_161 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_162 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_163 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_164 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93 = self.input.LA(2) if LA93 == 66: LA93_165 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_166 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_167 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_168 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_169 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_170 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_171 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_172 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_173 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_174 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_175 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_176 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_177 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_178 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_179 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_180 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_181 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_182 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_183 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_184 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93 = self.input.LA(2) if LA93 == 66: LA93_185 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_186 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_187 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_188 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_189 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_190 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_191 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_192 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_193 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_194 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_195 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_196 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_197 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_198 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_199 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_200 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_201 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_202 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_203 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_204 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93 = self.input.LA(2) if LA93 == 66: LA93_205 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_206 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_207 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_208 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_209 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_210 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_211 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_212 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_213 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_214 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_215 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_216 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_217 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_218 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_219 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_220 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_221 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_222 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_223 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_224 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93 = self.input.LA(2) if LA93 == 66: LA93_225 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_226 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_227 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_228 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_229 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_230 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_231 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_232 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_233 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_234 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_235 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_236 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_237 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_238 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_239 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_240 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_241 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_242 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_243 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_244 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93 = self.input.LA(2) if LA93 == 66: LA93_245 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_246 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_247 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_248 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_249 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_250 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_251 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_252 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_253 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_254 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_255 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_256 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_257 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_258 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_259 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_260 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_261 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_262 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_263 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_264 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93 = self.input.LA(2) if LA93 == 66: LA93_265 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_266 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_267 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_268 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_269 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_270 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_271 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_272 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_273 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_274 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_275 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_276 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_277 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_278 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_279 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_280 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_281 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_282 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_283 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_284 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93 = self.input.LA(2) if LA93 == 66: LA93_285 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_286 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_287 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_288 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_289 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_290 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_291 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_292 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_293 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_294 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_295 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_296 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_297 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_298 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_299 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_300 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_301 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_302 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_303 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_304 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_40 = self.input.LA(2) if (LA93_40 == IDENTIFIER) : LA93_305 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif (LA93_40 == 43) : LA93_306 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_41 = self.input.LA(2) if (LA93_41 == 43) : LA93_307 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif (LA93_41 == IDENTIFIER) : LA93_308 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 58 or LA93 == 59 or LA93 == 60 or LA93 == 61: LA93 = self.input.LA(2) if LA93 == 66: LA93_309 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_310 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_311 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_312 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_313 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_314 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_315 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_316 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_317 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_318 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_319 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_320 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_321 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_322 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_323 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_324 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_325 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_326 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_327 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_328 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 if alt93 == 1: # C.g:0:0: declaration self.following.append(self.FOLLOW_declaration_in_compound_statement2225) self.declaration() self.following.pop() if self.failed: return retval else: break #loop93 # C.g:554:21: ( statement_list )? alt94 = 2 LA94_0 = self.input.LA(1) if ((IDENTIFIER <= LA94_0 <= FLOATING_POINT_LITERAL) or (25 <= LA94_0 <= 26) or (29 <= LA94_0 <= 43) or (45 <= LA94_0 <= 46) or (48 <= LA94_0 <= 62) or LA94_0 == 66 or (68 <= LA94_0 <= 69) or (72 <= LA94_0 <= 74) or (77 <= LA94_0 <= 79) or (103 <= LA94_0 <= 108) or (110 <= LA94_0 <= 117)) : alt94 = 1 if alt94 == 1: # C.g:0:0: statement_list self.following.append(self.FOLLOW_statement_list_in_compound_statement2228) self.statement_list() self.following.pop() if self.failed: return retval self.match(self.input, 44, self.FOLLOW_44_in_compound_statement2231) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 66, compound_statement_StartIndex) pass return retval # $ANTLR end compound_statement # $ANTLR start statement_list # C.g:557:1: statement_list : ( statement )+ ; def statement_list(self, ): statement_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 67): return # C.g:558:2: ( ( statement )+ ) # C.g:558:4: ( statement )+ # C.g:558:4: ( statement )+ cnt95 = 0 while True: #loop95 alt95 = 2 LA95 = self.input.LA(1) if LA95 == IDENTIFIER: LA95 = self.input.LA(2) if LA95 == 62: LA95_46 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25 or LA95 == 29 or LA95 == 30 or LA95 == 31 or LA95 == 32 or LA95 == 33 or LA95 == 34 or LA95 == 35 or LA95 == 36 or LA95 == 37 or LA95 == 38 or LA95 == 39 or LA95 == 40 or LA95 == 41 or LA95 == 42 or LA95 == 45 or LA95 == 46 or LA95 == 47 or LA95 == 48 or LA95 == 49 or LA95 == 50 or LA95 == 51 or LA95 == 52 or LA95 == 53 or LA95 == 54 or LA95 == 55 or LA95 == 56 or LA95 == 57 or LA95 == 58 or LA95 == 59 or LA95 == 60 or LA95 == 61: alt95 = 1 elif LA95 == STRING_LITERAL: LA95_48 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == IDENTIFIER: LA95_49 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 64: LA95_50 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_51 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_52 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_53 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_54 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_55 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_56 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_57 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_58 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_59 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_60 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_61 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_62 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_63 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_64 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_65 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_66 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_67 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_68 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_69 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_88 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_89 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_90 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_91 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_92 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_93 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_94 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_95 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_96 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_97 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_98 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_99 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_100 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_101 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_102 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_103 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_104 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_105 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_106 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_107 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_108 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_109 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_110 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_113 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_114 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_115 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_116 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_117 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_118 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_119 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_120 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_121 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_122 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_123 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_124 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_125 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_126 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_127 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_128 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_129 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_130 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_131 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_132 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_133 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_135 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_137 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_138 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_139 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_140 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_141 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_142 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_143 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_144 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_145 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_146 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_147 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_148 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_149 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_150 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_151 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_152 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_153 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_154 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_155 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_156 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_157 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_158 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_161 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_162 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_163 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_164 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_165 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_166 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_167 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_168 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_169 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_170 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_171 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_172 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_173 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_174 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_175 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_176 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_177 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_178 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_179 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_180 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_181 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_182 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == STRING_LITERAL: LA95 = self.input.LA(2) if LA95 == IDENTIFIER: LA95_185 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 64: LA95_186 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_187 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_188 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_189 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_190 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_191 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_192 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_193 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_194 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_195 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_196 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_197 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_198 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_199 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_200 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_201 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_202 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_203 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_204 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_205 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_206 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == STRING_LITERAL: LA95_208 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_209 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_211 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_212 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_213 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_214 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_215 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_216 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_217 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_218 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_219 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_220 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_221 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_222 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_223 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_224 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_225 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_226 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_227 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_228 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_229 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_230 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_231 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_234 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95 = self.input.LA(2) if LA95 == IDENTIFIER: LA95_235 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_236 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_237 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_238 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_239 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_240 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_241 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_242 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_243 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_244 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_245 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_246 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 49 or LA95 == 50 or LA95 == 51 or LA95 == 52 or LA95 == 53 or LA95 == 54 or LA95 == 55 or LA95 == 56 or LA95 == 57 or LA95 == 58 or LA95 == 59 or LA95 == 60 or LA95 == 61: LA95_247 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 34: LA95_248 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 35: LA95_249 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 36: LA95_250 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 37: LA95_251 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 38: LA95_252 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 39: LA95_253 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 40: LA95_254 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 41: LA95_255 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 42: LA95_256 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 45 or LA95 == 46: LA95_257 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 48: LA95_258 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95 = self.input.LA(2) if LA95 == IDENTIFIER: LA95_259 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_260 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_261 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_262 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_263 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_264 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_265 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_266 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_267 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_268 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_269 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_270 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95 = self.input.LA(2) if LA95 == IDENTIFIER: LA95_271 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_272 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_273 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_274 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_275 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_276 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_277 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_278 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_279 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_280 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_281 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_282 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95 = self.input.LA(2) if LA95 == 62: LA95_283 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == IDENTIFIER: LA95_284 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_285 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_286 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_287 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_288 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_289 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_290 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_291 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_292 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_293 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_294 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95 = self.input.LA(2) if LA95 == 62: LA95_295 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == IDENTIFIER: LA95_296 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_297 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_298 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_299 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_300 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_301 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_302 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_303 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_304 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_305 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_306 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25 or LA95 == 26 or LA95 == 29 or LA95 == 30 or LA95 == 31 or LA95 == 32 or LA95 == 33 or LA95 == 34 or LA95 == 35 or LA95 == 36 or LA95 == 37 or LA95 == 38 or LA95 == 39 or LA95 == 40 or LA95 == 41 or LA95 == 42 or LA95 == 43 or LA95 == 45 or LA95 == 46 or LA95 == 48 or LA95 == 49 or LA95 == 50 or LA95 == 51 or LA95 == 52 or LA95 == 53 or LA95 == 54 or LA95 == 55 or LA95 == 56 or LA95 == 57 or LA95 == 58 or LA95 == 59 or LA95 == 60 or LA95 == 61 or LA95 == 103 or LA95 == 104 or LA95 == 105 or LA95 == 106 or LA95 == 107 or LA95 == 108 or LA95 == 110 or LA95 == 111 or LA95 == 112 or LA95 == 113 or LA95 == 114 or LA95 == 115 or LA95 == 116 or LA95 == 117: alt95 = 1 if alt95 == 1: # C.g:0:0: statement self.following.append(self.FOLLOW_statement_in_statement_list2242) self.statement() self.following.pop() if self.failed: return else: if cnt95 >= 1: break #loop95 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(95, self.input) raise eee cnt95 += 1 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 67, statement_list_StartIndex) pass return # $ANTLR end statement_list class expression_statement_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start expression_statement # C.g:561:1: expression_statement : ( ';' | expression ';' ); def expression_statement(self, ): retval = self.expression_statement_return() retval.start = self.input.LT(1) expression_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 68): return retval # C.g:562:2: ( ';' | expression ';' ) alt96 = 2 LA96_0 = self.input.LA(1) if (LA96_0 == 25) : alt96 = 1 elif ((IDENTIFIER <= LA96_0 <= FLOATING_POINT_LITERAL) or LA96_0 == 62 or LA96_0 == 66 or (68 <= LA96_0 <= 69) or (72 <= LA96_0 <= 74) or (77 <= LA96_0 <= 79)) : alt96 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("561:1: expression_statement : ( ';' | expression ';' );", 96, 0, self.input) raise nvae if alt96 == 1: # C.g:562:4: ';' self.match(self.input, 25, self.FOLLOW_25_in_expression_statement2254) if self.failed: return retval elif alt96 == 2: # C.g:563:4: expression ';' self.following.append(self.FOLLOW_expression_in_expression_statement2259) self.expression() self.following.pop() if self.failed: return retval self.match(self.input, 25, self.FOLLOW_25_in_expression_statement2261) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 68, expression_statement_StartIndex) pass return retval # $ANTLR end expression_statement # $ANTLR start selection_statement # C.g:566:1: selection_statement : ( 'if' '(' e= expression ')' statement ( options {k=1; backtrack=false; } : 'else' statement )? | 'switch' '(' expression ')' statement ); def selection_statement(self, ): selection_statement_StartIndex = self.input.index() e = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 69): return # C.g:567:2: ( 'if' '(' e= expression ')' statement ( options {k=1; backtrack=false; } : 'else' statement )? | 'switch' '(' expression ')' statement ) alt98 = 2 LA98_0 = self.input.LA(1) if (LA98_0 == 108) : alt98 = 1 elif (LA98_0 == 110) : alt98 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("566:1: selection_statement : ( 'if' '(' e= expression ')' statement ( options {k=1; backtrack=false; } : 'else' statement )? | 'switch' '(' expression ')' statement );", 98, 0, self.input) raise nvae if alt98 == 1: # C.g:567:4: 'if' '(' e= expression ')' statement ( options {k=1; backtrack=false; } : 'else' statement )? self.match(self.input, 108, self.FOLLOW_108_in_selection_statement2272) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_selection_statement2274) if self.failed: return self.following.append(self.FOLLOW_expression_in_selection_statement2278) e = self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_selection_statement2280) if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start,e.stop)) self.following.append(self.FOLLOW_statement_in_selection_statement2284) self.statement() self.following.pop() if self.failed: return # C.g:567:167: ( options {k=1; backtrack=false; } : 'else' statement )? alt97 = 2 LA97_0 = self.input.LA(1) if (LA97_0 == 109) : alt97 = 1 if alt97 == 1: # C.g:567:200: 'else' statement self.match(self.input, 109, self.FOLLOW_109_in_selection_statement2299) if self.failed: return self.following.append(self.FOLLOW_statement_in_selection_statement2301) self.statement() self.following.pop() if self.failed: return elif alt98 == 2: # C.g:568:4: 'switch' '(' expression ')' statement self.match(self.input, 110, self.FOLLOW_110_in_selection_statement2308) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_selection_statement2310) if self.failed: return self.following.append(self.FOLLOW_expression_in_selection_statement2312) self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_selection_statement2314) if self.failed: return self.following.append(self.FOLLOW_statement_in_selection_statement2316) self.statement() self.following.pop() if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 69, selection_statement_StartIndex) pass return # $ANTLR end selection_statement # $ANTLR start iteration_statement # C.g:571:1: iteration_statement : ( 'while' '(' e= expression ')' statement | 'do' statement 'while' '(' e= expression ')' ';' | 'for' '(' expression_statement e= expression_statement ( expression )? ')' statement ); def iteration_statement(self, ): iteration_statement_StartIndex = self.input.index() e = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 70): return # C.g:572:2: ( 'while' '(' e= expression ')' statement | 'do' statement 'while' '(' e= expression ')' ';' | 'for' '(' expression_statement e= expression_statement ( expression )? ')' statement ) alt100 = 3 LA100 = self.input.LA(1) if LA100 == 111: alt100 = 1 elif LA100 == 112: alt100 = 2 elif LA100 == 113: alt100 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("571:1: iteration_statement : ( 'while' '(' e= expression ')' statement | 'do' statement 'while' '(' e= expression ')' ';' | 'for' '(' expression_statement e= expression_statement ( expression )? ')' statement );", 100, 0, self.input) raise nvae if alt100 == 1: # C.g:572:4: 'while' '(' e= expression ')' statement self.match(self.input, 111, self.FOLLOW_111_in_iteration_statement2327) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_iteration_statement2329) if self.failed: return self.following.append(self.FOLLOW_expression_in_iteration_statement2333) e = self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_iteration_statement2335) if self.failed: return self.following.append(self.FOLLOW_statement_in_iteration_statement2337) self.statement() self.following.pop() if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start,e.stop)) elif alt100 == 2: # C.g:573:4: 'do' statement 'while' '(' e= expression ')' ';' self.match(self.input, 112, self.FOLLOW_112_in_iteration_statement2344) if self.failed: return self.following.append(self.FOLLOW_statement_in_iteration_statement2346) self.statement() self.following.pop() if self.failed: return self.match(self.input, 111, self.FOLLOW_111_in_iteration_statement2348) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_iteration_statement2350) if self.failed: return self.following.append(self.FOLLOW_expression_in_iteration_statement2354) e = self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_iteration_statement2356) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_iteration_statement2358) if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start,e.stop)) elif alt100 == 3: # C.g:574:4: 'for' '(' expression_statement e= expression_statement ( expression )? ')' statement self.match(self.input, 113, self.FOLLOW_113_in_iteration_statement2365) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_iteration_statement2367) if self.failed: return self.following.append(self.FOLLOW_expression_statement_in_iteration_statement2369) self.expression_statement() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_expression_statement_in_iteration_statement2373) e = self.expression_statement() self.following.pop() if self.failed: return # C.g:574:58: ( expression )? alt99 = 2 LA99_0 = self.input.LA(1) if ((IDENTIFIER <= LA99_0 <= FLOATING_POINT_LITERAL) or LA99_0 == 62 or LA99_0 == 66 or (68 <= LA99_0 <= 69) or (72 <= LA99_0 <= 74) or (77 <= LA99_0 <= 79)) : alt99 = 1 if alt99 == 1: # C.g:0:0: expression self.following.append(self.FOLLOW_expression_in_iteration_statement2375) self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_iteration_statement2378) if self.failed: return self.following.append(self.FOLLOW_statement_in_iteration_statement2380) self.statement() self.following.pop() if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start,e.stop)) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 70, iteration_statement_StartIndex) pass return # $ANTLR end iteration_statement # $ANTLR start jump_statement # C.g:577:1: jump_statement : ( 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' ); def jump_statement(self, ): jump_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 71): return # C.g:578:2: ( 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' ) alt101 = 5 LA101 = self.input.LA(1) if LA101 == 114: alt101 = 1 elif LA101 == 115: alt101 = 2 elif LA101 == 116: alt101 = 3 elif LA101 == 117: LA101_4 = self.input.LA(2) if (LA101_4 == 25) : alt101 = 4 elif ((IDENTIFIER <= LA101_4 <= FLOATING_POINT_LITERAL) or LA101_4 == 62 or LA101_4 == 66 or (68 <= LA101_4 <= 69) or (72 <= LA101_4 <= 74) or (77 <= LA101_4 <= 79)) : alt101 = 5 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("577:1: jump_statement : ( 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' );", 101, 4, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("577:1: jump_statement : ( 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' );", 101, 0, self.input) raise nvae if alt101 == 1: # C.g:578:4: 'goto' IDENTIFIER ';' self.match(self.input, 114, self.FOLLOW_114_in_jump_statement2393) if self.failed: return self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_jump_statement2395) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2397) if self.failed: return elif alt101 == 2: # C.g:579:4: 'continue' ';' self.match(self.input, 115, self.FOLLOW_115_in_jump_statement2402) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2404) if self.failed: return elif alt101 == 3: # C.g:580:4: 'break' ';' self.match(self.input, 116, self.FOLLOW_116_in_jump_statement2409) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2411) if self.failed: return elif alt101 == 4: # C.g:581:4: 'return' ';' self.match(self.input, 117, self.FOLLOW_117_in_jump_statement2416) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2418) if self.failed: return elif alt101 == 5: # C.g:582:4: 'return' expression ';' self.match(self.input, 117, self.FOLLOW_117_in_jump_statement2423) if self.failed: return self.following.append(self.FOLLOW_expression_in_jump_statement2425) self.expression() self.following.pop() if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2427) if self.failed: return except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 71, jump_statement_StartIndex) pass return # $ANTLR end jump_statement # $ANTLR start synpred2 def synpred2_fragment(self, ): # C.g:119:6: ( declaration_specifiers ) # C.g:119:6: declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_synpred2100) self.declaration_specifiers() self.following.pop() if self.failed: return # $ANTLR end synpred2 # $ANTLR start synpred4 def synpred4_fragment(self, ): # C.g:119:4: ( ( declaration_specifiers )? declarator ( declaration )* '{' ) # C.g:119:6: ( declaration_specifiers )? declarator ( declaration )* '{' # C.g:119:6: ( declaration_specifiers )? alt102 = 2 LA102 = self.input.LA(1) if LA102 == 29 or LA102 == 30 or LA102 == 31 or LA102 == 32 or LA102 == 33 or LA102 == 34 or LA102 == 35 or LA102 == 36 or LA102 == 37 or LA102 == 38 or LA102 == 39 or LA102 == 40 or LA102 == 41 or LA102 == 42 or LA102 == 45 or LA102 == 46 or LA102 == 48 or LA102 == 49 or LA102 == 50 or LA102 == 51 or LA102 == 52 or LA102 == 53 or LA102 == 54 or LA102 == 55 or LA102 == 56 or LA102 == 57 or LA102 == 61: alt102 = 1 elif LA102 == IDENTIFIER: LA102 = self.input.LA(2) if LA102 == 62: LA102_21 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 29 or LA102 == 30 or LA102 == 31 or LA102 == 32 or LA102 == 33: LA102_23 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 34: LA102_24 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 35: LA102_25 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 36: LA102_26 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 37: LA102_27 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 38: LA102_28 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 39: LA102_29 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 40: LA102_30 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 41: LA102_31 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 42: LA102_32 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 45 or LA102 == 46: LA102_33 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 48: LA102_34 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == IDENTIFIER: LA102_35 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 58: LA102_36 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 66: alt102 = 1 elif LA102 == 59: LA102_39 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 60: LA102_40 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 49 or LA102 == 50 or LA102 == 51 or LA102 == 52 or LA102 == 53 or LA102 == 54 or LA102 == 55 or LA102 == 56 or LA102 == 57 or LA102 == 61: LA102_41 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 58: LA102_14 = self.input.LA(2) if (self.synpred2()) : alt102 = 1 elif LA102 == 59: LA102_16 = self.input.LA(2) if (self.synpred2()) : alt102 = 1 elif LA102 == 60: LA102_17 = self.input.LA(2) if (self.synpred2()) : alt102 = 1 if alt102 == 1: # C.g:0:0: declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_synpred4100) self.declaration_specifiers() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_declarator_in_synpred4103) self.declarator() self.following.pop() if self.failed: return # C.g:119:41: ( declaration )* while True: #loop103 alt103 = 2 LA103_0 = self.input.LA(1) if (LA103_0 == IDENTIFIER or LA103_0 == 26 or (29 <= LA103_0 <= 42) or (45 <= LA103_0 <= 46) or (48 <= LA103_0 <= 61)) : alt103 = 1 if alt103 == 1: # C.g:0:0: declaration self.following.append(self.FOLLOW_declaration_in_synpred4105) self.declaration() self.following.pop() if self.failed: return else: break #loop103 self.match(self.input, 43, self.FOLLOW_43_in_synpred4108) if self.failed: return # $ANTLR end synpred4 # $ANTLR start synpred5 def synpred5_fragment(self, ): # C.g:120:4: ( declaration ) # C.g:120:4: declaration self.following.append(self.FOLLOW_declaration_in_synpred5118) self.declaration() self.following.pop() if self.failed: return # $ANTLR end synpred5 # $ANTLR start synpred7 def synpred7_fragment(self, ): # C.g:146:6: ( declaration_specifiers ) # C.g:146:6: declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_synpred7157) self.declaration_specifiers() self.following.pop() if self.failed: return # $ANTLR end synpred7 # $ANTLR start synpred10 def synpred10_fragment(self, ): # C.g:167:18: ( declaration_specifiers ) # C.g:167:18: declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_synpred10207) self.declaration_specifiers() self.following.pop() if self.failed: return # $ANTLR end synpred10 # $ANTLR start synpred14 def synpred14_fragment(self, ): # C.g:184:7: ( type_specifier ) # C.g:184:7: type_specifier self.following.append(self.FOLLOW_type_specifier_in_synpred14272) self.type_specifier() self.following.pop() if self.failed: return # $ANTLR end synpred14 # $ANTLR start synpred15 def synpred15_fragment(self, ): # C.g:185:13: ( type_qualifier ) # C.g:185:13: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred15286) self.type_qualifier() self.following.pop() if self.failed: return # $ANTLR end synpred15 # $ANTLR start synpred33 def synpred33_fragment(self, ): # C.g:225:16: ( type_qualifier ) # C.g:225:16: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred33444) self.type_qualifier() self.following.pop() if self.failed: return # $ANTLR end synpred33 # $ANTLR start synpred34 def synpred34_fragment(self, ): # C.g:225:4: ( IDENTIFIER ( type_qualifier )* declarator ) # C.g:225:5: IDENTIFIER ( type_qualifier )* declarator self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_synpred34442) if self.failed: return # C.g:225:16: ( type_qualifier )* while True: #loop106 alt106 = 2 LA106 = self.input.LA(1) if LA106 == 58: LA106_2 = self.input.LA(2) if (self.synpred33()) : alt106 = 1 elif LA106 == 59: LA106_3 = self.input.LA(2) if (self.synpred33()) : alt106 = 1 elif LA106 == 60: LA106_4 = self.input.LA(2) if (self.synpred33()) : alt106 = 1 elif LA106 == 49 or LA106 == 50 or LA106 == 51 or LA106 == 52 or LA106 == 53 or LA106 == 54 or LA106 == 55 or LA106 == 56 or LA106 == 57 or LA106 == 61: alt106 = 1 if alt106 == 1: # C.g:0:0: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred34444) self.type_qualifier() self.following.pop() if self.failed: return else: break #loop106 self.following.append(self.FOLLOW_declarator_in_synpred34447) self.declarator() self.following.pop() if self.failed: return # $ANTLR end synpred34 # $ANTLR start synpred39 def synpred39_fragment(self, ): # C.g:253:6: ( type_qualifier ) # C.g:253:6: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred39566) self.type_qualifier() self.following.pop() if self.failed: return # $ANTLR end synpred39 # $ANTLR start synpred40 def synpred40_fragment(self, ): # C.g:253:23: ( type_specifier ) # C.g:253:23: type_specifier self.following.append(self.FOLLOW_type_specifier_in_synpred40570) self.type_specifier() self.following.pop() if self.failed: return # $ANTLR end synpred40 # $ANTLR start synpred66 def synpred66_fragment(self, ): # C.g:297:4: ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator ) # C.g:297:4: ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator # C.g:297:4: ( pointer )? alt111 = 2 LA111_0 = self.input.LA(1) if (LA111_0 == 66) : alt111 = 1 if alt111 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_synpred66784) self.pointer() self.following.pop() if self.failed: return # C.g:297:13: ( 'EFIAPI' )? alt112 = 2 LA112_0 = self.input.LA(1) if (LA112_0 == 58) : alt112 = 1 if alt112 == 1: # C.g:297:14: 'EFIAPI' self.match(self.input, 58, self.FOLLOW_58_in_synpred66788) if self.failed: return # C.g:297:25: ( 'EFI_BOOTSERVICE' )? alt113 = 2 LA113_0 = self.input.LA(1) if (LA113_0 == 59) : alt113 = 1 if alt113 == 1: # C.g:297:26: 'EFI_BOOTSERVICE' self.match(self.input, 59, self.FOLLOW_59_in_synpred66793) if self.failed: return # C.g:297:46: ( 'EFI_RUNTIMESERVICE' )? alt114 = 2 LA114_0 = self.input.LA(1) if (LA114_0 == 60) : alt114 = 1 if alt114 == 1: # C.g:297:47: 'EFI_RUNTIMESERVICE' self.match(self.input, 60, self.FOLLOW_60_in_synpred66798) if self.failed: return self.following.append(self.FOLLOW_direct_declarator_in_synpred66802) self.direct_declarator() self.following.pop() if self.failed: return # $ANTLR end synpred66 # $ANTLR start synpred67 def synpred67_fragment(self, ): # C.g:303:15: ( declarator_suffix ) # C.g:303:15: declarator_suffix self.following.append(self.FOLLOW_declarator_suffix_in_synpred67821) self.declarator_suffix() self.following.pop() if self.failed: return # $ANTLR end synpred67 # $ANTLR start synpred69 def synpred69_fragment(self, ): # C.g:304:9: ( 'EFIAPI' ) # C.g:304:9: 'EFIAPI' self.match(self.input, 58, self.FOLLOW_58_in_synpred69830) if self.failed: return # $ANTLR end synpred69 # $ANTLR start synpred70 def synpred70_fragment(self, ): # C.g:304:35: ( declarator_suffix ) # C.g:304:35: declarator_suffix self.following.append(self.FOLLOW_declarator_suffix_in_synpred70838) self.declarator_suffix() self.following.pop() if self.failed: return # $ANTLR end synpred70 # $ANTLR start synpred73 def synpred73_fragment(self, ): # C.g:310:9: ( '(' parameter_type_list ')' ) # C.g:310:9: '(' parameter_type_list ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred73878) if self.failed: return self.following.append(self.FOLLOW_parameter_type_list_in_synpred73880) self.parameter_type_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred73882) if self.failed: return # $ANTLR end synpred73 # $ANTLR start synpred74 def synpred74_fragment(self, ): # C.g:311:9: ( '(' identifier_list ')' ) # C.g:311:9: '(' identifier_list ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred74892) if self.failed: return self.following.append(self.FOLLOW_identifier_list_in_synpred74894) self.identifier_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred74896) if self.failed: return # $ANTLR end synpred74 # $ANTLR start synpred75 def synpred75_fragment(self, ): # C.g:316:8: ( type_qualifier ) # C.g:316:8: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred75921) self.type_qualifier() self.following.pop() if self.failed: return # $ANTLR end synpred75 # $ANTLR start synpred76 def synpred76_fragment(self, ): # C.g:316:24: ( pointer ) # C.g:316:24: pointer self.following.append(self.FOLLOW_pointer_in_synpred76924) self.pointer() self.following.pop() if self.failed: return # $ANTLR end synpred76 # $ANTLR start synpred77 def synpred77_fragment(self, ): # C.g:316:4: ( '*' ( type_qualifier )+ ( pointer )? ) # C.g:316:4: '*' ( type_qualifier )+ ( pointer )? self.match(self.input, 66, self.FOLLOW_66_in_synpred77919) if self.failed: return # C.g:316:8: ( type_qualifier )+ cnt116 = 0 while True: #loop116 alt116 = 2 LA116_0 = self.input.LA(1) if ((49 <= LA116_0 <= 61)) : alt116 = 1 if alt116 == 1: # C.g:0:0: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred77921) self.type_qualifier() self.following.pop() if self.failed: return else: if cnt116 >= 1: break #loop116 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(116, self.input) raise eee cnt116 += 1 # C.g:316:24: ( pointer )? alt117 = 2 LA117_0 = self.input.LA(1) if (LA117_0 == 66) : alt117 = 1 if alt117 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_synpred77924) self.pointer() self.following.pop() if self.failed: return # $ANTLR end synpred77 # $ANTLR start synpred78 def synpred78_fragment(self, ): # C.g:317:4: ( '*' pointer ) # C.g:317:4: '*' pointer self.match(self.input, 66, self.FOLLOW_66_in_synpred78930) if self.failed: return self.following.append(self.FOLLOW_pointer_in_synpred78932) self.pointer() self.following.pop() if self.failed: return # $ANTLR end synpred78 # $ANTLR start synpred81 def synpred81_fragment(self, ): # C.g:326:32: ( 'OPTIONAL' ) # C.g:326:32: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_synpred81977) if self.failed: return # $ANTLR end synpred81 # $ANTLR start synpred82 def synpred82_fragment(self, ): # C.g:326:27: ( ',' ( 'OPTIONAL' )? parameter_declaration ) # C.g:326:27: ',' ( 'OPTIONAL' )? parameter_declaration self.match(self.input, 27, self.FOLLOW_27_in_synpred82974) if self.failed: return # C.g:326:31: ( 'OPTIONAL' )? alt119 = 2 LA119_0 = self.input.LA(1) if (LA119_0 == 53) : LA119_1 = self.input.LA(2) if (self.synpred81()) : alt119 = 1 if alt119 == 1: # C.g:326:32: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_synpred82977) if self.failed: return self.following.append(self.FOLLOW_parameter_declaration_in_synpred82981) self.parameter_declaration() self.following.pop() if self.failed: return # $ANTLR end synpred82 # $ANTLR start synpred83 def synpred83_fragment(self, ): # C.g:330:28: ( declarator ) # C.g:330:28: declarator self.following.append(self.FOLLOW_declarator_in_synpred83997) self.declarator() self.following.pop() if self.failed: return # $ANTLR end synpred83 # $ANTLR start synpred84 def synpred84_fragment(self, ): # C.g:330:39: ( abstract_declarator ) # C.g:330:39: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_synpred84999) self.abstract_declarator() self.following.pop() if self.failed: return # $ANTLR end synpred84 # $ANTLR start synpred86 def synpred86_fragment(self, ): # C.g:330:4: ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? ) # C.g:330:4: declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? self.following.append(self.FOLLOW_declaration_specifiers_in_synpred86994) self.declaration_specifiers() self.following.pop() if self.failed: return # C.g:330:27: ( declarator | abstract_declarator )* while True: #loop120 alt120 = 3 LA120 = self.input.LA(1) if LA120 == 66: LA120_3 = self.input.LA(2) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == IDENTIFIER or LA120 == 58 or LA120 == 59 or LA120 == 60: alt120 = 1 elif LA120 == 62: LA120 = self.input.LA(2) if LA120 == 29 or LA120 == 30 or LA120 == 31 or LA120 == 32 or LA120 == 33 or LA120 == 34 or LA120 == 35 or LA120 == 36 or LA120 == 37 or LA120 == 38 or LA120 == 39 or LA120 == 40 or LA120 == 41 or LA120 == 42 or LA120 == 45 or LA120 == 46 or LA120 == 48 or LA120 == 49 or LA120 == 50 or LA120 == 51 or LA120 == 52 or LA120 == 53 or LA120 == 54 or LA120 == 55 or LA120 == 56 or LA120 == 57 or LA120 == 61 or LA120 == 63 or LA120 == 64: alt120 = 2 elif LA120 == 58: LA120_21 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 66: LA120_22 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 59: LA120_23 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 60: LA120_24 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == IDENTIFIER: LA120_25 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 62: LA120_26 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 64: alt120 = 2 if alt120 == 1: # C.g:330:28: declarator self.following.append(self.FOLLOW_declarator_in_synpred86997) self.declarator() self.following.pop() if self.failed: return elif alt120 == 2: # C.g:330:39: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_synpred86999) self.abstract_declarator() self.following.pop() if self.failed: return else: break #loop120 # C.g:330:61: ( 'OPTIONAL' )? alt121 = 2 LA121_0 = self.input.LA(1) if (LA121_0 == 53) : alt121 = 1 if alt121 == 1: # C.g:330:62: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_synpred861004) if self.failed: return # $ANTLR end synpred86 # $ANTLR start synpred90 def synpred90_fragment(self, ): # C.g:341:4: ( specifier_qualifier_list ( abstract_declarator )? ) # C.g:341:4: specifier_qualifier_list ( abstract_declarator )? self.following.append(self.FOLLOW_specifier_qualifier_list_in_synpred901046) self.specifier_qualifier_list() self.following.pop() if self.failed: return # C.g:341:29: ( abstract_declarator )? alt122 = 2 LA122_0 = self.input.LA(1) if (LA122_0 == 62 or LA122_0 == 64 or LA122_0 == 66) : alt122 = 1 if alt122 == 1: # C.g:0:0: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_synpred901048) self.abstract_declarator() self.following.pop() if self.failed: return # $ANTLR end synpred90 # $ANTLR start synpred91 def synpred91_fragment(self, ): # C.g:346:12: ( direct_abstract_declarator ) # C.g:346:12: direct_abstract_declarator self.following.append(self.FOLLOW_direct_abstract_declarator_in_synpred911067) self.direct_abstract_declarator() self.following.pop() if self.failed: return # $ANTLR end synpred91 # $ANTLR start synpred93 def synpred93_fragment(self, ): # C.g:351:6: ( '(' abstract_declarator ')' ) # C.g:351:6: '(' abstract_declarator ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred931086) if self.failed: return self.following.append(self.FOLLOW_abstract_declarator_in_synpred931088) self.abstract_declarator() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred931090) if self.failed: return # $ANTLR end synpred93 # $ANTLR start synpred94 def synpred94_fragment(self, ): # C.g:351:65: ( abstract_declarator_suffix ) # C.g:351:65: abstract_declarator_suffix self.following.append(self.FOLLOW_abstract_declarator_suffix_in_synpred941098) self.abstract_declarator_suffix() self.following.pop() if self.failed: return # $ANTLR end synpred94 # $ANTLR start synpred109 def synpred109_fragment(self, ): # C.g:386:4: ( '(' type_name ')' cast_expression ) # C.g:386:4: '(' type_name ')' cast_expression self.match(self.input, 62, self.FOLLOW_62_in_synpred1091282) if self.failed: return self.following.append(self.FOLLOW_type_name_in_synpred1091284) self.type_name() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred1091286) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_synpred1091288) self.cast_expression() self.following.pop() if self.failed: return # $ANTLR end synpred109 # $ANTLR start synpred114 def synpred114_fragment(self, ): # C.g:395:4: ( 'sizeof' unary_expression ) # C.g:395:4: 'sizeof' unary_expression self.match(self.input, 74, self.FOLLOW_74_in_synpred1141330) if self.failed: return self.following.append(self.FOLLOW_unary_expression_in_synpred1141332) self.unary_expression() self.following.pop() if self.failed: return # $ANTLR end synpred114 # $ANTLR start synpred117 def synpred117_fragment(self, ): # C.g:409:13: ( '(' argument_expression_list ')' ) # C.g:409:13: '(' argument_expression_list ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred1171420) if self.failed: return self.following.append(self.FOLLOW_argument_expression_list_in_synpred1171424) self.argument_expression_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred1171428) if self.failed: return # $ANTLR end synpred117 # $ANTLR start synpred118 def synpred118_fragment(self, ): # C.g:410:13: ( '(' macro_parameter_list ')' ) # C.g:410:13: '(' macro_parameter_list ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred1181444) if self.failed: return self.following.append(self.FOLLOW_macro_parameter_list_in_synpred1181446) self.macro_parameter_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred1181448) if self.failed: return # $ANTLR end synpred118 # $ANTLR start synpred120 def synpred120_fragment(self, ): # C.g:412:13: ( '*' IDENTIFIER ) # C.g:412:13: '*' IDENTIFIER self.match(self.input, 66, self.FOLLOW_66_in_synpred1201482) if self.failed: return self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_synpred1201486) if self.failed: return # $ANTLR end synpred120 # $ANTLR start synpred137 def synpred137_fragment(self, ): # C.g:443:20: ( STRING_LITERAL ) # C.g:443:20: STRING_LITERAL self.match(self.input, STRING_LITERAL, self.FOLLOW_STRING_LITERAL_in_synpred1371683) if self.failed: return # $ANTLR end synpred137 # $ANTLR start synpred138 def synpred138_fragment(self, ): # C.g:443:8: ( ( IDENTIFIER )* ( STRING_LITERAL )+ ) # C.g:443:8: ( IDENTIFIER )* ( STRING_LITERAL )+ # C.g:443:8: ( IDENTIFIER )* while True: #loop125 alt125 = 2 LA125_0 = self.input.LA(1) if (LA125_0 == IDENTIFIER) : alt125 = 1 if alt125 == 1: # C.g:0:0: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_synpred1381680) if self.failed: return else: break #loop125 # C.g:443:20: ( STRING_LITERAL )+ cnt126 = 0 while True: #loop126 alt126 = 2 LA126_0 = self.input.LA(1) if (LA126_0 == STRING_LITERAL) : alt126 = 1 if alt126 == 1: # C.g:0:0: STRING_LITERAL self.match(self.input, STRING_LITERAL, self.FOLLOW_STRING_LITERAL_in_synpred1381683) if self.failed: return else: if cnt126 >= 1: break #loop126 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(126, self.input) raise eee cnt126 += 1 # $ANTLR end synpred138 # $ANTLR start synpred142 def synpred142_fragment(self, ): # C.g:458:4: ( lvalue assignment_operator assignment_expression ) # C.g:458:4: lvalue assignment_operator assignment_expression self.following.append(self.FOLLOW_lvalue_in_synpred1421744) self.lvalue() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_assignment_operator_in_synpred1421746) self.assignment_operator() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_assignment_expression_in_synpred1421748) self.assignment_expression() self.following.pop() if self.failed: return # $ANTLR end synpred142 # $ANTLR start synpred169 def synpred169_fragment(self, ): # C.g:520:4: ( expression_statement ) # C.g:520:4: expression_statement self.following.append(self.FOLLOW_expression_statement_in_synpred1692035) self.expression_statement() self.following.pop() if self.failed: return # $ANTLR end synpred169 # $ANTLR start synpred173 def synpred173_fragment(self, ): # C.g:524:4: ( macro_statement ) # C.g:524:4: macro_statement self.following.append(self.FOLLOW_macro_statement_in_synpred1732055) self.macro_statement() self.following.pop() if self.failed: return # $ANTLR end synpred173 # $ANTLR start synpred174 def synpred174_fragment(self, ): # C.g:525:4: ( asm2_statement ) # C.g:525:4: asm2_statement self.following.append(self.FOLLOW_asm2_statement_in_synpred1742060) self.asm2_statement() self.following.pop() if self.failed: return # $ANTLR end synpred174 # $ANTLR start synpred181 def synpred181_fragment(self, ): # C.g:544:19: ( declaration ) # C.g:544:19: declaration self.following.append(self.FOLLOW_declaration_in_synpred1812166) self.declaration() self.following.pop() if self.failed: return # $ANTLR end synpred181 # $ANTLR start synpred182 def synpred182_fragment(self, ): # C.g:544:33: ( statement_list ) # C.g:544:33: statement_list self.following.append(self.FOLLOW_statement_list_in_synpred1822170) self.statement_list() self.following.pop() if self.failed: return # $ANTLR end synpred182 # $ANTLR start synpred186 def synpred186_fragment(self, ): # C.g:554:8: ( declaration ) # C.g:554:8: declaration self.following.append(self.FOLLOW_declaration_in_synpred1862225) self.declaration() self.following.pop() if self.failed: return # $ANTLR end synpred186 # $ANTLR start synpred188 def synpred188_fragment(self, ): # C.g:558:4: ( statement ) # C.g:558:4: statement self.following.append(self.FOLLOW_statement_in_synpred1882242) self.statement() self.following.pop() if self.failed: return # $ANTLR end synpred188 def synpred69(self): self.backtracking += 1 start = self.input.mark() self.synpred69_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred81(self): self.backtracking += 1 start = self.input.mark() self.synpred81_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred82(self): self.backtracking += 1 start = self.input.mark() self.synpred82_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred66(self): self.backtracking += 1 start = self.input.mark() self.synpred66_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred83(self): self.backtracking += 1 start = self.input.mark() self.synpred83_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred84(self): self.backtracking += 1 start = self.input.mark() self.synpred84_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred67(self): self.backtracking += 1 start = self.input.mark() self.synpred67_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred86(self): self.backtracking += 1 start = self.input.mark() self.synpred86_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred120(self): self.backtracking += 1 start = self.input.mark() self.synpred120_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred40(self): self.backtracking += 1 start = self.input.mark() self.synpred40_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred142(self): self.backtracking += 1 start = self.input.mark() self.synpred142_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred182(self): self.backtracking += 1 start = self.input.mark() self.synpred182_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred109(self): self.backtracking += 1 start = self.input.mark() self.synpred109_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred181(self): self.backtracking += 1 start = self.input.mark() self.synpred181_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred186(self): self.backtracking += 1 start = self.input.mark() self.synpred186_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred188(self): self.backtracking += 1 start = self.input.mark() self.synpred188_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred169(self): self.backtracking += 1 start = self.input.mark() self.synpred169_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred117(self): self.backtracking += 1 start = self.input.mark() self.synpred117_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred70(self): self.backtracking += 1 start = self.input.mark() self.synpred70_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred118(self): self.backtracking += 1 start = self.input.mark() self.synpred118_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred34(self): self.backtracking += 1 start = self.input.mark() self.synpred34_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred33(self): self.backtracking += 1 start = self.input.mark() self.synpred33_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred94(self): self.backtracking += 1 start = self.input.mark() self.synpred94_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred39(self): self.backtracking += 1 start = self.input.mark() self.synpred39_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred74(self): self.backtracking += 1 start = self.input.mark() self.synpred74_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred114(self): self.backtracking += 1 start = self.input.mark() self.synpred114_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred93(self): self.backtracking += 1 start = self.input.mark() self.synpred93_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred75(self): self.backtracking += 1 start = self.input.mark() self.synpred75_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred137(self): self.backtracking += 1 start = self.input.mark() self.synpred137_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred90(self): self.backtracking += 1 start = self.input.mark() self.synpred90_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred138(self): self.backtracking += 1 start = self.input.mark() self.synpred138_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred91(self): self.backtracking += 1 start = self.input.mark() self.synpred91_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred73(self): self.backtracking += 1 start = self.input.mark() self.synpred73_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred5(self): self.backtracking += 1 start = self.input.mark() self.synpred5_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred78(self): self.backtracking += 1 start = self.input.mark() self.synpred78_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred7(self): self.backtracking += 1 start = self.input.mark() self.synpred7_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred76(self): self.backtracking += 1 start = self.input.mark() self.synpred76_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred77(self): self.backtracking += 1 start = self.input.mark() self.synpred77_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred2(self): self.backtracking += 1 start = self.input.mark() self.synpred2_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred4(self): self.backtracking += 1 start = self.input.mark() self.synpred4_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred174(self): self.backtracking += 1 start = self.input.mark() self.synpred174_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred173(self): self.backtracking += 1 start = self.input.mark() self.synpred173_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred14(self): self.backtracking += 1 start = self.input.mark() self.synpred14_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred15(self): self.backtracking += 1 start = self.input.mark() self.synpred15_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred10(self): self.backtracking += 1 start = self.input.mark() self.synpred10_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success FOLLOW_external_declaration_in_translation_unit74 = frozenset([1, 4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66]) FOLLOW_function_definition_in_external_declaration113 = frozenset([1]) FOLLOW_declaration_in_external_declaration118 = frozenset([1]) FOLLOW_macro_statement_in_external_declaration123 = frozenset([1, 25]) FOLLOW_25_in_external_declaration126 = frozenset([1]) FOLLOW_declaration_specifiers_in_function_definition157 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_declarator_in_function_definition160 = frozenset([4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_declaration_in_function_definition166 = frozenset([4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_compound_statement_in_function_definition171 = frozenset([1]) FOLLOW_compound_statement_in_function_definition180 = frozenset([1]) FOLLOW_26_in_declaration203 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66]) FOLLOW_declaration_specifiers_in_declaration207 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_init_declarator_list_in_declaration216 = frozenset([25]) FOLLOW_25_in_declaration220 = frozenset([1]) FOLLOW_declaration_specifiers_in_declaration234 = frozenset([4, 25, 58, 59, 60, 62, 66]) FOLLOW_init_declarator_list_in_declaration238 = frozenset([25]) FOLLOW_25_in_declaration243 = frozenset([1]) FOLLOW_storage_class_specifier_in_declaration_specifiers264 = frozenset([1, 4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_specifier_in_declaration_specifiers272 = frozenset([1, 4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_qualifier_in_declaration_specifiers286 = frozenset([1, 4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_init_declarator_in_init_declarator_list308 = frozenset([1, 27]) FOLLOW_27_in_init_declarator_list311 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_init_declarator_in_init_declarator_list313 = frozenset([1, 27]) FOLLOW_declarator_in_init_declarator326 = frozenset([1, 28]) FOLLOW_28_in_init_declarator329 = frozenset([4, 5, 6, 7, 8, 9, 10, 43, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_initializer_in_init_declarator331 = frozenset([1]) FOLLOW_set_in_storage_class_specifier0 = frozenset([1]) FOLLOW_34_in_type_specifier376 = frozenset([1]) FOLLOW_35_in_type_specifier381 = frozenset([1]) FOLLOW_36_in_type_specifier386 = frozenset([1]) FOLLOW_37_in_type_specifier391 = frozenset([1]) FOLLOW_38_in_type_specifier396 = frozenset([1]) FOLLOW_39_in_type_specifier401 = frozenset([1]) FOLLOW_40_in_type_specifier406 = frozenset([1]) FOLLOW_41_in_type_specifier411 = frozenset([1]) FOLLOW_42_in_type_specifier416 = frozenset([1]) FOLLOW_struct_or_union_specifier_in_type_specifier423 = frozenset([1]) FOLLOW_enum_specifier_in_type_specifier433 = frozenset([1]) FOLLOW_type_id_in_type_specifier451 = frozenset([1]) FOLLOW_IDENTIFIER_in_type_id467 = frozenset([1]) FOLLOW_struct_or_union_in_struct_or_union_specifier494 = frozenset([4, 43]) FOLLOW_IDENTIFIER_in_struct_or_union_specifier496 = frozenset([43]) FOLLOW_43_in_struct_or_union_specifier499 = frozenset([4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_struct_declaration_list_in_struct_or_union_specifier501 = frozenset([44]) FOLLOW_44_in_struct_or_union_specifier503 = frozenset([1]) FOLLOW_struct_or_union_in_struct_or_union_specifier508 = frozenset([4]) FOLLOW_IDENTIFIER_in_struct_or_union_specifier510 = frozenset([1]) FOLLOW_set_in_struct_or_union0 = frozenset([1]) FOLLOW_struct_declaration_in_struct_declaration_list537 = frozenset([1, 4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_specifier_qualifier_list_in_struct_declaration549 = frozenset([4, 47, 58, 59, 60, 62, 66]) FOLLOW_struct_declarator_list_in_struct_declaration551 = frozenset([25]) FOLLOW_25_in_struct_declaration553 = frozenset([1]) FOLLOW_type_qualifier_in_specifier_qualifier_list566 = frozenset([1, 4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_specifier_in_specifier_qualifier_list570 = frozenset([1, 4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_struct_declarator_in_struct_declarator_list584 = frozenset([1, 27]) FOLLOW_27_in_struct_declarator_list587 = frozenset([4, 47, 58, 59, 60, 62, 66]) FOLLOW_struct_declarator_in_struct_declarator_list589 = frozenset([1, 27]) FOLLOW_declarator_in_struct_declarator602 = frozenset([1, 47]) FOLLOW_47_in_struct_declarator605 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_struct_declarator607 = frozenset([1]) FOLLOW_47_in_struct_declarator614 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_struct_declarator616 = frozenset([1]) FOLLOW_48_in_enum_specifier634 = frozenset([43]) FOLLOW_43_in_enum_specifier636 = frozenset([4]) FOLLOW_enumerator_list_in_enum_specifier638 = frozenset([27, 44]) FOLLOW_27_in_enum_specifier640 = frozenset([44]) FOLLOW_44_in_enum_specifier643 = frozenset([1]) FOLLOW_48_in_enum_specifier648 = frozenset([4]) FOLLOW_IDENTIFIER_in_enum_specifier650 = frozenset([43]) FOLLOW_43_in_enum_specifier652 = frozenset([4]) FOLLOW_enumerator_list_in_enum_specifier654 = frozenset([27, 44]) FOLLOW_27_in_enum_specifier656 = frozenset([44]) FOLLOW_44_in_enum_specifier659 = frozenset([1]) FOLLOW_48_in_enum_specifier664 = frozenset([4]) FOLLOW_IDENTIFIER_in_enum_specifier666 = frozenset([1]) FOLLOW_enumerator_in_enumerator_list677 = frozenset([1, 27]) FOLLOW_27_in_enumerator_list680 = frozenset([4]) FOLLOW_enumerator_in_enumerator_list682 = frozenset([1, 27]) FOLLOW_IDENTIFIER_in_enumerator695 = frozenset([1, 28]) FOLLOW_28_in_enumerator698 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_enumerator700 = frozenset([1]) FOLLOW_set_in_type_qualifier0 = frozenset([1]) FOLLOW_pointer_in_declarator784 = frozenset([4, 58, 59, 60, 62]) FOLLOW_58_in_declarator788 = frozenset([4, 59, 60, 62]) FOLLOW_59_in_declarator793 = frozenset([4, 60, 62]) FOLLOW_60_in_declarator798 = frozenset([4, 62]) FOLLOW_direct_declarator_in_declarator802 = frozenset([1]) FOLLOW_pointer_in_declarator808 = frozenset([1]) FOLLOW_IDENTIFIER_in_direct_declarator819 = frozenset([1, 62, 64]) FOLLOW_declarator_suffix_in_direct_declarator821 = frozenset([1, 62, 64]) FOLLOW_62_in_direct_declarator827 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_58_in_direct_declarator830 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_declarator_in_direct_declarator834 = frozenset([63]) FOLLOW_63_in_direct_declarator836 = frozenset([62, 64]) FOLLOW_declarator_suffix_in_direct_declarator838 = frozenset([1, 62, 64]) FOLLOW_64_in_declarator_suffix852 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_declarator_suffix854 = frozenset([65]) FOLLOW_65_in_declarator_suffix856 = frozenset([1]) FOLLOW_64_in_declarator_suffix866 = frozenset([65]) FOLLOW_65_in_declarator_suffix868 = frozenset([1]) FOLLOW_62_in_declarator_suffix878 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_type_list_in_declarator_suffix880 = frozenset([63]) FOLLOW_63_in_declarator_suffix882 = frozenset([1]) FOLLOW_62_in_declarator_suffix892 = frozenset([4]) FOLLOW_identifier_list_in_declarator_suffix894 = frozenset([63]) FOLLOW_63_in_declarator_suffix896 = frozenset([1]) FOLLOW_62_in_declarator_suffix906 = frozenset([63]) FOLLOW_63_in_declarator_suffix908 = frozenset([1]) FOLLOW_66_in_pointer919 = frozenset([49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_qualifier_in_pointer921 = frozenset([1, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_pointer_in_pointer924 = frozenset([1]) FOLLOW_66_in_pointer930 = frozenset([66]) FOLLOW_pointer_in_pointer932 = frozenset([1]) FOLLOW_66_in_pointer937 = frozenset([1]) FOLLOW_parameter_list_in_parameter_type_list948 = frozenset([1, 27]) FOLLOW_27_in_parameter_type_list951 = frozenset([53, 67]) FOLLOW_53_in_parameter_type_list954 = frozenset([67]) FOLLOW_67_in_parameter_type_list958 = frozenset([1]) FOLLOW_parameter_declaration_in_parameter_list971 = frozenset([1, 27]) FOLLOW_27_in_parameter_list974 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_53_in_parameter_list977 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_declaration_in_parameter_list981 = frozenset([1, 27]) FOLLOW_declaration_specifiers_in_parameter_declaration994 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_declarator_in_parameter_declaration997 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_abstract_declarator_in_parameter_declaration999 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_53_in_parameter_declaration1004 = frozenset([1]) FOLLOW_pointer_in_parameter_declaration1013 = frozenset([4, 66]) FOLLOW_IDENTIFIER_in_parameter_declaration1016 = frozenset([1]) FOLLOW_IDENTIFIER_in_identifier_list1027 = frozenset([1, 27]) FOLLOW_27_in_identifier_list1031 = frozenset([4]) FOLLOW_IDENTIFIER_in_identifier_list1033 = frozenset([1, 27]) FOLLOW_specifier_qualifier_list_in_type_name1046 = frozenset([1, 62, 64, 66]) FOLLOW_abstract_declarator_in_type_name1048 = frozenset([1]) FOLLOW_type_id_in_type_name1054 = frozenset([1]) FOLLOW_pointer_in_abstract_declarator1065 = frozenset([1, 62, 64]) FOLLOW_direct_abstract_declarator_in_abstract_declarator1067 = frozenset([1]) FOLLOW_direct_abstract_declarator_in_abstract_declarator1073 = frozenset([1]) FOLLOW_62_in_direct_abstract_declarator1086 = frozenset([62, 64, 66]) FOLLOW_abstract_declarator_in_direct_abstract_declarator1088 = frozenset([63]) FOLLOW_63_in_direct_abstract_declarator1090 = frozenset([1, 62, 64]) FOLLOW_abstract_declarator_suffix_in_direct_abstract_declarator1094 = frozenset([1, 62, 64]) FOLLOW_abstract_declarator_suffix_in_direct_abstract_declarator1098 = frozenset([1, 62, 64]) FOLLOW_64_in_abstract_declarator_suffix1110 = frozenset([65]) FOLLOW_65_in_abstract_declarator_suffix1112 = frozenset([1]) FOLLOW_64_in_abstract_declarator_suffix1117 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_abstract_declarator_suffix1119 = frozenset([65]) FOLLOW_65_in_abstract_declarator_suffix1121 = frozenset([1]) FOLLOW_62_in_abstract_declarator_suffix1126 = frozenset([63]) FOLLOW_63_in_abstract_declarator_suffix1128 = frozenset([1]) FOLLOW_62_in_abstract_declarator_suffix1133 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_type_list_in_abstract_declarator_suffix1135 = frozenset([63]) FOLLOW_63_in_abstract_declarator_suffix1137 = frozenset([1]) FOLLOW_assignment_expression_in_initializer1150 = frozenset([1]) FOLLOW_43_in_initializer1155 = frozenset([4, 5, 6, 7, 8, 9, 10, 43, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_initializer_list_in_initializer1157 = frozenset([27, 44]) FOLLOW_27_in_initializer1159 = frozenset([44]) FOLLOW_44_in_initializer1162 = frozenset([1]) FOLLOW_initializer_in_initializer_list1173 = frozenset([1, 27]) FOLLOW_27_in_initializer_list1176 = frozenset([4, 5, 6, 7, 8, 9, 10, 43, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_initializer_in_initializer_list1178 = frozenset([1, 27]) FOLLOW_assignment_expression_in_argument_expression_list1196 = frozenset([1, 27, 53]) FOLLOW_53_in_argument_expression_list1199 = frozenset([1, 27]) FOLLOW_27_in_argument_expression_list1204 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_assignment_expression_in_argument_expression_list1206 = frozenset([1, 27, 53]) FOLLOW_53_in_argument_expression_list1209 = frozenset([1, 27]) FOLLOW_multiplicative_expression_in_additive_expression1225 = frozenset([1, 68, 69]) FOLLOW_68_in_additive_expression1229 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_multiplicative_expression_in_additive_expression1231 = frozenset([1, 68, 69]) FOLLOW_69_in_additive_expression1235 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_multiplicative_expression_in_additive_expression1237 = frozenset([1, 68, 69]) FOLLOW_cast_expression_in_multiplicative_expression1251 = frozenset([1, 66, 70, 71]) FOLLOW_66_in_multiplicative_expression1255 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_multiplicative_expression1257 = frozenset([1, 66, 70, 71]) FOLLOW_70_in_multiplicative_expression1261 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_multiplicative_expression1263 = frozenset([1, 66, 70, 71]) FOLLOW_71_in_multiplicative_expression1267 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_multiplicative_expression1269 = frozenset([1, 66, 70, 71]) FOLLOW_62_in_cast_expression1282 = frozenset([4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_name_in_cast_expression1284 = frozenset([63]) FOLLOW_63_in_cast_expression1286 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_cast_expression1288 = frozenset([1]) FOLLOW_unary_expression_in_cast_expression1293 = frozenset([1]) FOLLOW_postfix_expression_in_unary_expression1304 = frozenset([1]) FOLLOW_72_in_unary_expression1309 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_unary_expression_in_unary_expression1311 = frozenset([1]) FOLLOW_73_in_unary_expression1316 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_unary_expression_in_unary_expression1318 = frozenset([1]) FOLLOW_unary_operator_in_unary_expression1323 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_unary_expression1325 = frozenset([1]) FOLLOW_74_in_unary_expression1330 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_unary_expression_in_unary_expression1332 = frozenset([1]) FOLLOW_74_in_unary_expression1337 = frozenset([62]) FOLLOW_62_in_unary_expression1339 = frozenset([4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_name_in_unary_expression1341 = frozenset([63]) FOLLOW_63_in_unary_expression1343 = frozenset([1]) FOLLOW_primary_expression_in_postfix_expression1367 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_64_in_postfix_expression1383 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_postfix_expression1385 = frozenset([65]) FOLLOW_65_in_postfix_expression1387 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_62_in_postfix_expression1401 = frozenset([63]) FOLLOW_63_in_postfix_expression1405 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_62_in_postfix_expression1420 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_argument_expression_list_in_postfix_expression1424 = frozenset([63]) FOLLOW_63_in_postfix_expression1428 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_62_in_postfix_expression1444 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_macro_parameter_list_in_postfix_expression1446 = frozenset([63]) FOLLOW_63_in_postfix_expression1448 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_75_in_postfix_expression1462 = frozenset([4]) FOLLOW_IDENTIFIER_in_postfix_expression1466 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_66_in_postfix_expression1482 = frozenset([4]) FOLLOW_IDENTIFIER_in_postfix_expression1486 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_76_in_postfix_expression1502 = frozenset([4]) FOLLOW_IDENTIFIER_in_postfix_expression1506 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_72_in_postfix_expression1522 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_73_in_postfix_expression1536 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_parameter_declaration_in_macro_parameter_list1559 = frozenset([1, 27]) FOLLOW_27_in_macro_parameter_list1562 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_declaration_in_macro_parameter_list1564 = frozenset([1, 27]) FOLLOW_set_in_unary_operator0 = frozenset([1]) FOLLOW_IDENTIFIER_in_primary_expression1613 = frozenset([1]) FOLLOW_constant_in_primary_expression1618 = frozenset([1]) FOLLOW_62_in_primary_expression1623 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_primary_expression1625 = frozenset([63]) FOLLOW_63_in_primary_expression1627 = frozenset([1]) FOLLOW_HEX_LITERAL_in_constant1643 = frozenset([1]) FOLLOW_OCTAL_LITERAL_in_constant1653 = frozenset([1]) FOLLOW_DECIMAL_LITERAL_in_constant1663 = frozenset([1]) FOLLOW_CHARACTER_LITERAL_in_constant1671 = frozenset([1]) FOLLOW_IDENTIFIER_in_constant1680 = frozenset([4, 9]) FOLLOW_STRING_LITERAL_in_constant1683 = frozenset([1, 4, 9]) FOLLOW_IDENTIFIER_in_constant1688 = frozenset([1, 4]) FOLLOW_FLOATING_POINT_LITERAL_in_constant1699 = frozenset([1]) FOLLOW_assignment_expression_in_expression1715 = frozenset([1, 27]) FOLLOW_27_in_expression1718 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_assignment_expression_in_expression1720 = frozenset([1, 27]) FOLLOW_conditional_expression_in_constant_expression1733 = frozenset([1]) FOLLOW_lvalue_in_assignment_expression1744 = frozenset([28, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89]) FOLLOW_assignment_operator_in_assignment_expression1746 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_assignment_expression_in_assignment_expression1748 = frozenset([1]) FOLLOW_conditional_expression_in_assignment_expression1753 = frozenset([1]) FOLLOW_unary_expression_in_lvalue1765 = frozenset([1]) FOLLOW_set_in_assignment_operator0 = frozenset([1]) FOLLOW_logical_or_expression_in_conditional_expression1839 = frozenset([1, 90]) FOLLOW_90_in_conditional_expression1842 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_conditional_expression1844 = frozenset([47]) FOLLOW_47_in_conditional_expression1846 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_conditional_expression_in_conditional_expression1848 = frozenset([1]) FOLLOW_logical_and_expression_in_logical_or_expression1863 = frozenset([1, 91]) FOLLOW_91_in_logical_or_expression1866 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_logical_and_expression_in_logical_or_expression1868 = frozenset([1, 91]) FOLLOW_inclusive_or_expression_in_logical_and_expression1881 = frozenset([1, 92]) FOLLOW_92_in_logical_and_expression1884 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_inclusive_or_expression_in_logical_and_expression1886 = frozenset([1, 92]) FOLLOW_exclusive_or_expression_in_inclusive_or_expression1899 = frozenset([1, 93]) FOLLOW_93_in_inclusive_or_expression1902 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_exclusive_or_expression_in_inclusive_or_expression1904 = frozenset([1, 93]) FOLLOW_and_expression_in_exclusive_or_expression1917 = frozenset([1, 94]) FOLLOW_94_in_exclusive_or_expression1920 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_and_expression_in_exclusive_or_expression1922 = frozenset([1, 94]) FOLLOW_equality_expression_in_and_expression1935 = frozenset([1, 77]) FOLLOW_77_in_and_expression1938 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_equality_expression_in_and_expression1940 = frozenset([1, 77]) FOLLOW_relational_expression_in_equality_expression1952 = frozenset([1, 95, 96]) FOLLOW_set_in_equality_expression1955 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_relational_expression_in_equality_expression1961 = frozenset([1, 95, 96]) FOLLOW_shift_expression_in_relational_expression1975 = frozenset([1, 97, 98, 99, 100]) FOLLOW_set_in_relational_expression1978 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_shift_expression_in_relational_expression1988 = frozenset([1, 97, 98, 99, 100]) FOLLOW_additive_expression_in_shift_expression2001 = frozenset([1, 101, 102]) FOLLOW_set_in_shift_expression2004 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_additive_expression_in_shift_expression2010 = frozenset([1, 101, 102]) FOLLOW_labeled_statement_in_statement2025 = frozenset([1]) FOLLOW_compound_statement_in_statement2030 = frozenset([1]) FOLLOW_expression_statement_in_statement2035 = frozenset([1]) FOLLOW_selection_statement_in_statement2040 = frozenset([1]) FOLLOW_iteration_statement_in_statement2045 = frozenset([1]) FOLLOW_jump_statement_in_statement2050 = frozenset([1]) FOLLOW_macro_statement_in_statement2055 = frozenset([1]) FOLLOW_asm2_statement_in_statement2060 = frozenset([1]) FOLLOW_asm1_statement_in_statement2065 = frozenset([1]) FOLLOW_asm_statement_in_statement2070 = frozenset([1]) FOLLOW_declaration_in_statement2075 = frozenset([1]) FOLLOW_103_in_asm2_statement2086 = frozenset([4]) FOLLOW_IDENTIFIER_in_asm2_statement2089 = frozenset([62]) FOLLOW_62_in_asm2_statement2091 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_set_in_asm2_statement2094 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_63_in_asm2_statement2101 = frozenset([25]) FOLLOW_25_in_asm2_statement2103 = frozenset([1]) FOLLOW_104_in_asm1_statement2115 = frozenset([43]) FOLLOW_43_in_asm1_statement2117 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_set_in_asm1_statement2120 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_44_in_asm1_statement2127 = frozenset([1]) FOLLOW_105_in_asm_statement2138 = frozenset([43]) FOLLOW_43_in_asm_statement2140 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_set_in_asm_statement2143 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_44_in_asm_statement2150 = frozenset([1]) FOLLOW_IDENTIFIER_in_macro_statement2162 = frozenset([62]) FOLLOW_62_in_macro_statement2164 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_declaration_in_macro_statement2166 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_list_in_macro_statement2170 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 63, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_macro_statement2173 = frozenset([63]) FOLLOW_63_in_macro_statement2176 = frozenset([1]) FOLLOW_IDENTIFIER_in_labeled_statement2188 = frozenset([47]) FOLLOW_47_in_labeled_statement2190 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_labeled_statement2192 = frozenset([1]) FOLLOW_106_in_labeled_statement2197 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_labeled_statement2199 = frozenset([47]) FOLLOW_47_in_labeled_statement2201 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_labeled_statement2203 = frozenset([1]) FOLLOW_107_in_labeled_statement2208 = frozenset([47]) FOLLOW_47_in_labeled_statement2210 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_labeled_statement2212 = frozenset([1]) FOLLOW_43_in_compound_statement2223 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_declaration_in_compound_statement2225 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_list_in_compound_statement2228 = frozenset([44]) FOLLOW_44_in_compound_statement2231 = frozenset([1]) FOLLOW_statement_in_statement_list2242 = frozenset([1, 4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_25_in_expression_statement2254 = frozenset([1]) FOLLOW_expression_in_expression_statement2259 = frozenset([25]) FOLLOW_25_in_expression_statement2261 = frozenset([1]) FOLLOW_108_in_selection_statement2272 = frozenset([62]) FOLLOW_62_in_selection_statement2274 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_selection_statement2278 = frozenset([63]) FOLLOW_63_in_selection_statement2280 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_selection_statement2284 = frozenset([1, 109]) FOLLOW_109_in_selection_statement2299 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_selection_statement2301 = frozenset([1]) FOLLOW_110_in_selection_statement2308 = frozenset([62]) FOLLOW_62_in_selection_statement2310 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_selection_statement2312 = frozenset([63]) FOLLOW_63_in_selection_statement2314 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_selection_statement2316 = frozenset([1]) FOLLOW_111_in_iteration_statement2327 = frozenset([62]) FOLLOW_62_in_iteration_statement2329 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_iteration_statement2333 = frozenset([63]) FOLLOW_63_in_iteration_statement2335 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_iteration_statement2337 = frozenset([1]) FOLLOW_112_in_iteration_statement2344 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_iteration_statement2346 = frozenset([111]) FOLLOW_111_in_iteration_statement2348 = frozenset([62]) FOLLOW_62_in_iteration_statement2350 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_iteration_statement2354 = frozenset([63]) FOLLOW_63_in_iteration_statement2356 = frozenset([25]) FOLLOW_25_in_iteration_statement2358 = frozenset([1]) FOLLOW_113_in_iteration_statement2365 = frozenset([62]) FOLLOW_62_in_iteration_statement2367 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_statement_in_iteration_statement2369 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_statement_in_iteration_statement2373 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 63, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_iteration_statement2375 = frozenset([63]) FOLLOW_63_in_iteration_statement2378 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_iteration_statement2380 = frozenset([1]) FOLLOW_114_in_jump_statement2393 = frozenset([4]) FOLLOW_IDENTIFIER_in_jump_statement2395 = frozenset([25]) FOLLOW_25_in_jump_statement2397 = frozenset([1]) FOLLOW_115_in_jump_statement2402 = frozenset([25]) FOLLOW_25_in_jump_statement2404 = frozenset([1]) FOLLOW_116_in_jump_statement2409 = frozenset([25]) FOLLOW_25_in_jump_statement2411 = frozenset([1]) FOLLOW_117_in_jump_statement2416 = frozenset([25]) FOLLOW_25_in_jump_statement2418 = frozenset([1]) FOLLOW_117_in_jump_statement2423 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_jump_statement2425 = frozenset([25]) FOLLOW_25_in_jump_statement2427 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred2100 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred4100 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_declarator_in_synpred4103 = frozenset([4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_declaration_in_synpred4105 = frozenset([4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_43_in_synpred4108 = frozenset([1]) FOLLOW_declaration_in_synpred5118 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred7157 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred10207 = frozenset([1]) FOLLOW_type_specifier_in_synpred14272 = frozenset([1]) FOLLOW_type_qualifier_in_synpred15286 = frozenset([1]) FOLLOW_type_qualifier_in_synpred33444 = frozenset([1]) FOLLOW_IDENTIFIER_in_synpred34442 = frozenset([4, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66]) FOLLOW_type_qualifier_in_synpred34444 = frozenset([4, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66]) FOLLOW_declarator_in_synpred34447 = frozenset([1]) FOLLOW_type_qualifier_in_synpred39566 = frozenset([1]) FOLLOW_type_specifier_in_synpred40570 = frozenset([1]) FOLLOW_pointer_in_synpred66784 = frozenset([4, 58, 59, 60, 62]) FOLLOW_58_in_synpred66788 = frozenset([4, 59, 60, 62]) FOLLOW_59_in_synpred66793 = frozenset([4, 60, 62]) FOLLOW_60_in_synpred66798 = frozenset([4, 62]) FOLLOW_direct_declarator_in_synpred66802 = frozenset([1]) FOLLOW_declarator_suffix_in_synpred67821 = frozenset([1]) FOLLOW_58_in_synpred69830 = frozenset([1]) FOLLOW_declarator_suffix_in_synpred70838 = frozenset([1]) FOLLOW_62_in_synpred73878 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_type_list_in_synpred73880 = frozenset([63]) FOLLOW_63_in_synpred73882 = frozenset([1]) FOLLOW_62_in_synpred74892 = frozenset([4]) FOLLOW_identifier_list_in_synpred74894 = frozenset([63]) FOLLOW_63_in_synpred74896 = frozenset([1]) FOLLOW_type_qualifier_in_synpred75921 = frozenset([1]) FOLLOW_pointer_in_synpred76924 = frozenset([1]) FOLLOW_66_in_synpred77919 = frozenset([49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_qualifier_in_synpred77921 = frozenset([1, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_pointer_in_synpred77924 = frozenset([1]) FOLLOW_66_in_synpred78930 = frozenset([66]) FOLLOW_pointer_in_synpred78932 = frozenset([1]) FOLLOW_53_in_synpred81977 = frozenset([1]) FOLLOW_27_in_synpred82974 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_53_in_synpred82977 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_declaration_in_synpred82981 = frozenset([1]) FOLLOW_declarator_in_synpred83997 = frozenset([1]) FOLLOW_abstract_declarator_in_synpred84999 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred86994 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_declarator_in_synpred86997 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_abstract_declarator_in_synpred86999 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_53_in_synpred861004 = frozenset([1]) FOLLOW_specifier_qualifier_list_in_synpred901046 = frozenset([1, 62, 64, 66]) FOLLOW_abstract_declarator_in_synpred901048 = frozenset([1]) FOLLOW_direct_abstract_declarator_in_synpred911067 = frozenset([1]) FOLLOW_62_in_synpred931086 = frozenset([62, 64, 66]) FOLLOW_abstract_declarator_in_synpred931088 = frozenset([63]) FOLLOW_63_in_synpred931090 = frozenset([1]) FOLLOW_abstract_declarator_suffix_in_synpred941098 = frozenset([1]) FOLLOW_62_in_synpred1091282 = frozenset([4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_name_in_synpred1091284 = frozenset([63]) FOLLOW_63_in_synpred1091286 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_synpred1091288 = frozenset([1]) FOLLOW_74_in_synpred1141330 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_unary_expression_in_synpred1141332 = frozenset([1]) FOLLOW_62_in_synpred1171420 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_argument_expression_list_in_synpred1171424 = frozenset([63]) FOLLOW_63_in_synpred1171428 = frozenset([1]) FOLLOW_62_in_synpred1181444 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_macro_parameter_list_in_synpred1181446 = frozenset([63]) FOLLOW_63_in_synpred1181448 = frozenset([1]) FOLLOW_66_in_synpred1201482 = frozenset([4]) FOLLOW_IDENTIFIER_in_synpred1201486 = frozenset([1]) FOLLOW_STRING_LITERAL_in_synpred1371683 = frozenset([1]) FOLLOW_IDENTIFIER_in_synpred1381680 = frozenset([4, 9]) FOLLOW_STRING_LITERAL_in_synpred1381683 = frozenset([1, 9]) FOLLOW_lvalue_in_synpred1421744 = frozenset([28, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89]) FOLLOW_assignment_operator_in_synpred1421746 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_assignment_expression_in_synpred1421748 = frozenset([1]) FOLLOW_expression_statement_in_synpred1692035 = frozenset([1]) FOLLOW_macro_statement_in_synpred1732055 = frozenset([1]) FOLLOW_asm2_statement_in_synpred1742060 = frozenset([1]) FOLLOW_declaration_in_synpred1812166 = frozenset([1]) FOLLOW_statement_list_in_synpred1822170 = frozenset([1]) FOLLOW_declaration_in_synpred1862225 = frozenset([1]) FOLLOW_statement_in_synpred1882242 = frozenset([1])
{ "repo_name": "bitcrystal/buildtools-BaseTools", "path": "Source/Python/Ecc/CParser.py", "copies": "12", "size": "699330", "license": "bsd-2-clause", "hash": 1042354630147280800, "line_mean": 35.1115474422, "line_max": 694, "alpha_frac": 0.3897072913, "autogenerated": false, "ratio": 4.5167894903409564, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": null, "num_lines": null }
# $ANTLR 3.0.1 C.g 2010-02-23 09:58:53 from __future__ import print_function from __future__ import absolute_import from antlr3 import * from antlr3.compat import set, frozenset ## @file # The file defines the parser for C source files. # # THIS FILE IS AUTO-GENENERATED. PLEASE DON NOT MODIFY THIS FILE. # This file is generated by running: # java org.antlr.Tool C.g # # Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR> # # This program and the accompanying materials are licensed and made available # under the terms and conditions of the BSD License which accompanies this # distribution. The full text of the license may be found at: # http://opensource.org/licenses/bsd-license.php # # THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, # WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. # ## from Ecc import CodeFragment from Ecc import FileProfile # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types BS=20 LINE_COMMENT=23 FloatTypeSuffix=16 IntegerTypeSuffix=14 LETTER=11 OCTAL_LITERAL=6 CHARACTER_LITERAL=8 Exponent=15 EOF=-1 HexDigit=13 STRING_LITERAL=9 WS=19 FLOATING_POINT_LITERAL=10 IDENTIFIER=4 UnicodeEscape=18 LINE_COMMAND=24 UnicodeVocabulary=21 HEX_LITERAL=5 COMMENT=22 DECIMAL_LITERAL=7 EscapeSequence=12 OctalEscape=17 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "IDENTIFIER", "HEX_LITERAL", "OCTAL_LITERAL", "DECIMAL_LITERAL", "CHARACTER_LITERAL", "STRING_LITERAL", "FLOATING_POINT_LITERAL", "LETTER", "EscapeSequence", "HexDigit", "IntegerTypeSuffix", "Exponent", "FloatTypeSuffix", "OctalEscape", "UnicodeEscape", "WS", "BS", "UnicodeVocabulary", "COMMENT", "LINE_COMMENT", "LINE_COMMAND", "';'", "'typedef'", "','", "'='", "'extern'", "'static'", "'auto'", "'register'", "'STATIC'", "'void'", "'char'", "'short'", "'int'", "'long'", "'float'", "'double'", "'signed'", "'unsigned'", "'{'", "'}'", "'struct'", "'union'", "':'", "'enum'", "'const'", "'volatile'", "'IN'", "'OUT'", "'OPTIONAL'", "'CONST'", "'UNALIGNED'", "'VOLATILE'", "'GLOBAL_REMOVE_IF_UNREFERENCED'", "'EFIAPI'", "'EFI_BOOTSERVICE'", "'EFI_RUNTIMESERVICE'", "'PACKED'", "'('", "')'", "'['", "']'", "'*'", "'...'", "'+'", "'-'", "'/'", "'%'", "'++'", "'--'", "'sizeof'", "'.'", "'->'", "'&'", "'~'", "'!'", "'*='", "'/='", "'%='", "'+='", "'-='", "'<<='", "'>>='", "'&='", "'^='", "'|='", "'?'", "'||'", "'&&'", "'|'", "'^'", "'=='", "'!='", "'<'", "'>'", "'<='", "'>='", "'<<'", "'>>'", "'__asm__'", "'_asm'", "'__asm'", "'case'", "'default'", "'if'", "'else'", "'switch'", "'while'", "'do'", "'for'", "'goto'", "'continue'", "'break'", "'return'" ] class function_definition_scope(object): def __init__(self): self.ModifierText = None self.DeclText = None self.LBLine = None self.LBOffset = None self.DeclLine = None self.DeclOffset = None class postfix_expression_scope(object): def __init__(self): self.FuncCallText = None class CParser(Parser): grammarFileName = "C.g" tokenNames = tokenNames def __init__(self, input): Parser.__init__(self, input) self.ruleMemo = {} self.function_definition_stack = [] self.postfix_expression_stack = [] def printTokenInfo(self, line, offset, tokenText): print(str(line)+ ',' + str(offset) + ':' + str(tokenText)) def StorePredicateExpression(self, StartLine, StartOffset, EndLine, EndOffset, Text): PredExp = CodeFragment.PredicateExpression(Text, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.PredicateExpressionList.append(PredExp) def StoreEnumerationDefinition(self, StartLine, StartOffset, EndLine, EndOffset, Text): EnumDef = CodeFragment.EnumerationDefinition(Text, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.EnumerationDefinitionList.append(EnumDef) def StoreStructUnionDefinition(self, StartLine, StartOffset, EndLine, EndOffset, Text): SUDef = CodeFragment.StructUnionDefinition(Text, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.StructUnionDefinitionList.append(SUDef) def StoreTypedefDefinition(self, StartLine, StartOffset, EndLine, EndOffset, FromText, ToText): Tdef = CodeFragment.TypedefDefinition(FromText, ToText, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.TypedefDefinitionList.append(Tdef) def StoreFunctionDefinition(self, StartLine, StartOffset, EndLine, EndOffset, ModifierText, DeclText, LeftBraceLine, LeftBraceOffset, DeclLine, DeclOffset): FuncDef = CodeFragment.FunctionDefinition(ModifierText, DeclText, (StartLine, StartOffset), (EndLine, EndOffset), (LeftBraceLine, LeftBraceOffset), (DeclLine, DeclOffset)) FileProfile.FunctionDefinitionList.append(FuncDef) def StoreVariableDeclaration(self, StartLine, StartOffset, EndLine, EndOffset, ModifierText, DeclText): VarDecl = CodeFragment.VariableDeclaration(ModifierText, DeclText, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.VariableDeclarationList.append(VarDecl) def StoreFunctionCalling(self, StartLine, StartOffset, EndLine, EndOffset, FuncName, ParamList): FuncCall = CodeFragment.FunctionCalling(FuncName, ParamList, (StartLine, StartOffset), (EndLine, EndOffset)) FileProfile.FunctionCallingList.append(FuncCall) # $ANTLR start translation_unit # C.g:102:1: translation_unit : ( external_declaration )* ; def translation_unit(self, ): translation_unit_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 1): return # C.g:103:2: ( ( external_declaration )* ) # C.g:103:4: ( external_declaration )* # C.g:103:4: ( external_declaration )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == IDENTIFIER or LA1_0 == 26 or (29 <= LA1_0 <= 42) or (45 <= LA1_0 <= 46) or (48 <= LA1_0 <= 62) or LA1_0 == 66) : alt1 = 1 if alt1 == 1: # C.g:0:0: external_declaration self.following.append(self.FOLLOW_external_declaration_in_translation_unit74) self.external_declaration() self.following.pop() if self.failed: return else: break #loop1 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 1, translation_unit_StartIndex) pass return # $ANTLR end translation_unit # $ANTLR start external_declaration # C.g:114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? ); def external_declaration(self, ): external_declaration_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 2): return # C.g:119:2: ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? ) alt3 = 3 LA3_0 = self.input.LA(1) if ((29 <= LA3_0 <= 33)) : LA3_1 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 1, self.input) raise nvae elif (LA3_0 == 34) : LA3_2 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 2, self.input) raise nvae elif (LA3_0 == 35) : LA3_3 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 3, self.input) raise nvae elif (LA3_0 == 36) : LA3_4 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 4, self.input) raise nvae elif (LA3_0 == 37) : LA3_5 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 5, self.input) raise nvae elif (LA3_0 == 38) : LA3_6 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 6, self.input) raise nvae elif (LA3_0 == 39) : LA3_7 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 7, self.input) raise nvae elif (LA3_0 == 40) : LA3_8 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 8, self.input) raise nvae elif (LA3_0 == 41) : LA3_9 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 9, self.input) raise nvae elif (LA3_0 == 42) : LA3_10 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 10, self.input) raise nvae elif ((45 <= LA3_0 <= 46)) : LA3_11 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 11, self.input) raise nvae elif (LA3_0 == 48) : LA3_12 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 12, self.input) raise nvae elif (LA3_0 == IDENTIFIER) : LA3_13 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 elif (True) : alt3 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 13, self.input) raise nvae elif (LA3_0 == 58) : LA3_14 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 14, self.input) raise nvae elif (LA3_0 == 66) and (self.synpred4()): alt3 = 1 elif (LA3_0 == 59) : LA3_16 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 16, self.input) raise nvae elif (LA3_0 == 60) : LA3_17 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 17, self.input) raise nvae elif ((49 <= LA3_0 <= 57) or LA3_0 == 61) : LA3_18 = self.input.LA(2) if (self.synpred4()) : alt3 = 1 elif (self.synpred5()) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 18, self.input) raise nvae elif (LA3_0 == 62) and (self.synpred4()): alt3 = 1 elif (LA3_0 == 26) : alt3 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("114:1: external_declaration options {k=1; } : ( ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition | declaration | macro_statement ( ';' )? );", 3, 0, self.input) raise nvae if alt3 == 1: # C.g:119:4: ( ( declaration_specifiers )? declarator ( declaration )* '{' )=> function_definition self.following.append(self.FOLLOW_function_definition_in_external_declaration113) self.function_definition() self.following.pop() if self.failed: return elif alt3 == 2: # C.g:120:4: declaration self.following.append(self.FOLLOW_declaration_in_external_declaration118) self.declaration() self.following.pop() if self.failed: return elif alt3 == 3: # C.g:121:4: macro_statement ( ';' )? self.following.append(self.FOLLOW_macro_statement_in_external_declaration123) self.macro_statement() self.following.pop() if self.failed: return # C.g:121:20: ( ';' )? alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == 25) : alt2 = 1 if alt2 == 1: # C.g:121:21: ';' self.match(self.input, 25, self.FOLLOW_25_in_external_declaration126) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 2, external_declaration_StartIndex) pass return # $ANTLR end external_declaration class function_definition_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start function_definition # C.g:126:1: function_definition : (d= declaration_specifiers )? declarator ( ( declaration )+ a= compound_statement | b= compound_statement ) ; def function_definition(self, ): self.function_definition_stack.append(function_definition_scope()) retval = self.function_definition_return() retval.start = self.input.LT(1) function_definition_StartIndex = self.input.index() d = None a = None b = None declarator1 = None self.function_definition_stack[-1].ModifierText = '' self.function_definition_stack[-1].DeclText = '' self.function_definition_stack[-1].LBLine = 0 self.function_definition_stack[-1].LBOffset = 0 self.function_definition_stack[-1].DeclLine = 0 self.function_definition_stack[-1].DeclOffset = 0 try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 3): return retval # C.g:146:2: ( (d= declaration_specifiers )? declarator ( ( declaration )+ a= compound_statement | b= compound_statement ) ) # C.g:146:4: (d= declaration_specifiers )? declarator ( ( declaration )+ a= compound_statement | b= compound_statement ) # C.g:146:5: (d= declaration_specifiers )? alt4 = 2 LA4 = self.input.LA(1) if LA4 == 29 or LA4 == 30 or LA4 == 31 or LA4 == 32 or LA4 == 33 or LA4 == 34 or LA4 == 35 or LA4 == 36 or LA4 == 37 or LA4 == 38 or LA4 == 39 or LA4 == 40 or LA4 == 41 or LA4 == 42 or LA4 == 45 or LA4 == 46 or LA4 == 48 or LA4 == 49 or LA4 == 50 or LA4 == 51 or LA4 == 52 or LA4 == 53 or LA4 == 54 or LA4 == 55 or LA4 == 56 or LA4 == 57 or LA4 == 61: alt4 = 1 elif LA4 == IDENTIFIER: LA4 = self.input.LA(2) if LA4 == 66: alt4 = 1 elif LA4 == 58: LA4_21 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 59: LA4_22 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 60: LA4_23 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == IDENTIFIER: LA4_24 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 62: LA4_25 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 29 or LA4 == 30 or LA4 == 31 or LA4 == 32 or LA4 == 33: LA4_26 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 34: LA4_27 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 35: LA4_28 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 36: LA4_29 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 37: LA4_30 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 38: LA4_31 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 39: LA4_32 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 40: LA4_33 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 41: LA4_34 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 42: LA4_35 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 45 or LA4 == 46: LA4_36 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 48: LA4_37 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 49 or LA4 == 50 or LA4 == 51 or LA4 == 52 or LA4 == 53 or LA4 == 54 or LA4 == 55 or LA4 == 56 or LA4 == 57 or LA4 == 61: LA4_38 = self.input.LA(3) if (self.synpred7()) : alt4 = 1 elif LA4 == 58: LA4_14 = self.input.LA(2) if (self.synpred7()) : alt4 = 1 elif LA4 == 59: LA4_16 = self.input.LA(2) if (self.synpred7()) : alt4 = 1 elif LA4 == 60: LA4_17 = self.input.LA(2) if (self.synpred7()) : alt4 = 1 if alt4 == 1: # C.g:0:0: d= declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_function_definition157) d = self.declaration_specifiers() self.following.pop() if self.failed: return retval self.following.append(self.FOLLOW_declarator_in_function_definition160) declarator1 = self.declarator() self.following.pop() if self.failed: return retval # C.g:147:3: ( ( declaration )+ a= compound_statement | b= compound_statement ) alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == IDENTIFIER or LA6_0 == 26 or (29 <= LA6_0 <= 42) or (45 <= LA6_0 <= 46) or (48 <= LA6_0 <= 61)) : alt6 = 1 elif (LA6_0 == 43) : alt6 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("147:3: ( ( declaration )+ a= compound_statement | b= compound_statement )", 6, 0, self.input) raise nvae if alt6 == 1: # C.g:147:5: ( declaration )+ a= compound_statement # C.g:147:5: ( declaration )+ cnt5 = 0 while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == IDENTIFIER or LA5_0 == 26 or (29 <= LA5_0 <= 42) or (45 <= LA5_0 <= 46) or (48 <= LA5_0 <= 61)) : alt5 = 1 if alt5 == 1: # C.g:0:0: declaration self.following.append(self.FOLLOW_declaration_in_function_definition166) self.declaration() self.following.pop() if self.failed: return retval else: if cnt5 >= 1: break #loop5 if self.backtracking > 0: self.failed = True return retval eee = EarlyExitException(5, self.input) raise eee cnt5 += 1 self.following.append(self.FOLLOW_compound_statement_in_function_definition171) a = self.compound_statement() self.following.pop() if self.failed: return retval elif alt6 == 2: # C.g:148:5: b= compound_statement self.following.append(self.FOLLOW_compound_statement_in_function_definition180) b = self.compound_statement() self.following.pop() if self.failed: return retval if self.backtracking == 0: if d is not None: self.function_definition_stack[-1].ModifierText = self.input.toString(d.start, d.stop) else: self.function_definition_stack[-1].ModifierText = '' self.function_definition_stack[-1].DeclText = self.input.toString(declarator1.start, declarator1.stop) self.function_definition_stack[-1].DeclLine = declarator1.start.line self.function_definition_stack[-1].DeclOffset = declarator1.start.charPositionInLine if a is not None: self.function_definition_stack[-1].LBLine = a.start.line self.function_definition_stack[-1].LBOffset = a.start.charPositionInLine else: self.function_definition_stack[-1].LBLine = b.start.line self.function_definition_stack[-1].LBOffset = b.start.charPositionInLine retval.stop = self.input.LT(-1) if self.backtracking == 0: self.StoreFunctionDefinition(retval.start.line, retval.start.charPositionInLine, retval.stop.line, retval.stop.charPositionInLine, self.function_definition_stack[-1].ModifierText, self.function_definition_stack[-1].DeclText, self.function_definition_stack[-1].LBLine, self.function_definition_stack[-1].LBOffset, self.function_definition_stack[-1].DeclLine, self.function_definition_stack[-1].DeclOffset) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 3, function_definition_StartIndex) self.function_definition_stack.pop() pass return retval # $ANTLR end function_definition # $ANTLR start declaration # C.g:166:1: declaration : (a= 'typedef' (b= declaration_specifiers )? c= init_declarator_list d= ';' | s= declaration_specifiers (t= init_declarator_list )? e= ';' ); def declaration(self, ): declaration_StartIndex = self.input.index() a = None d = None e = None b = None c = None s = None t = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 4): return # C.g:167:2: (a= 'typedef' (b= declaration_specifiers )? c= init_declarator_list d= ';' | s= declaration_specifiers (t= init_declarator_list )? e= ';' ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == 26) : alt9 = 1 elif (LA9_0 == IDENTIFIER or (29 <= LA9_0 <= 42) or (45 <= LA9_0 <= 46) or (48 <= LA9_0 <= 61)) : alt9 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("166:1: declaration : (a= 'typedef' (b= declaration_specifiers )? c= init_declarator_list d= ';' | s= declaration_specifiers (t= init_declarator_list )? e= ';' );", 9, 0, self.input) raise nvae if alt9 == 1: # C.g:167:4: a= 'typedef' (b= declaration_specifiers )? c= init_declarator_list d= ';' a = self.input.LT(1) self.match(self.input, 26, self.FOLLOW_26_in_declaration203) if self.failed: return # C.g:167:17: (b= declaration_specifiers )? alt7 = 2 LA7 = self.input.LA(1) if LA7 == 29 or LA7 == 30 or LA7 == 31 or LA7 == 32 or LA7 == 33 or LA7 == 34 or LA7 == 35 or LA7 == 36 or LA7 == 37 or LA7 == 38 or LA7 == 39 or LA7 == 40 or LA7 == 41 or LA7 == 42 or LA7 == 45 or LA7 == 46 or LA7 == 48 or LA7 == 49 or LA7 == 50 or LA7 == 51 or LA7 == 52 or LA7 == 53 or LA7 == 54 or LA7 == 55 or LA7 == 56 or LA7 == 57 or LA7 == 61: alt7 = 1 elif LA7 == IDENTIFIER: LA7_13 = self.input.LA(2) if (LA7_13 == 62) : LA7_21 = self.input.LA(3) if (self.synpred10()) : alt7 = 1 elif (LA7_13 == IDENTIFIER or (29 <= LA7_13 <= 42) or (45 <= LA7_13 <= 46) or (48 <= LA7_13 <= 61) or LA7_13 == 66) : alt7 = 1 elif LA7 == 58: LA7_14 = self.input.LA(2) if (self.synpred10()) : alt7 = 1 elif LA7 == 59: LA7_16 = self.input.LA(2) if (self.synpred10()) : alt7 = 1 elif LA7 == 60: LA7_17 = self.input.LA(2) if (self.synpred10()) : alt7 = 1 if alt7 == 1: # C.g:0:0: b= declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_declaration207) b = self.declaration_specifiers() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_init_declarator_list_in_declaration216) c = self.init_declarator_list() self.following.pop() if self.failed: return d = self.input.LT(1) self.match(self.input, 25, self.FOLLOW_25_in_declaration220) if self.failed: return if self.backtracking == 0: if b is not None: self.StoreTypedefDefinition(a.line, a.charPositionInLine, d.line, d.charPositionInLine, self.input.toString(b.start, b.stop), self.input.toString(c.start, c.stop)) else: self.StoreTypedefDefinition(a.line, a.charPositionInLine, d.line, d.charPositionInLine, '', self.input.toString(c.start, c.stop)) elif alt9 == 2: # C.g:175:4: s= declaration_specifiers (t= init_declarator_list )? e= ';' self.following.append(self.FOLLOW_declaration_specifiers_in_declaration234) s = self.declaration_specifiers() self.following.pop() if self.failed: return # C.g:175:30: (t= init_declarator_list )? alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == IDENTIFIER or (58 <= LA8_0 <= 60) or LA8_0 == 62 or LA8_0 == 66) : alt8 = 1 if alt8 == 1: # C.g:0:0: t= init_declarator_list self.following.append(self.FOLLOW_init_declarator_list_in_declaration238) t = self.init_declarator_list() self.following.pop() if self.failed: return e = self.input.LT(1) self.match(self.input, 25, self.FOLLOW_25_in_declaration243) if self.failed: return if self.backtracking == 0: if t is not None: self.StoreVariableDeclaration(s.start.line, s.start.charPositionInLine, t.start.line, t.start.charPositionInLine, self.input.toString(s.start, s.stop), self.input.toString(t.start, t.stop)) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 4, declaration_StartIndex) pass return # $ANTLR end declaration class declaration_specifiers_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start declaration_specifiers # C.g:182:1: declaration_specifiers : ( storage_class_specifier | type_specifier | type_qualifier )+ ; def declaration_specifiers(self, ): retval = self.declaration_specifiers_return() retval.start = self.input.LT(1) declaration_specifiers_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 5): return retval # C.g:183:2: ( ( storage_class_specifier | type_specifier | type_qualifier )+ ) # C.g:183:6: ( storage_class_specifier | type_specifier | type_qualifier )+ # C.g:183:6: ( storage_class_specifier | type_specifier | type_qualifier )+ cnt10 = 0 while True: #loop10 alt10 = 4 LA10 = self.input.LA(1) if LA10 == 58: LA10_2 = self.input.LA(2) if (self.synpred15()) : alt10 = 3 elif LA10 == 59: LA10_3 = self.input.LA(2) if (self.synpred15()) : alt10 = 3 elif LA10 == 60: LA10_4 = self.input.LA(2) if (self.synpred15()) : alt10 = 3 elif LA10 == IDENTIFIER: LA10_5 = self.input.LA(2) if (self.synpred14()) : alt10 = 2 elif LA10 == 53: LA10_9 = self.input.LA(2) if (self.synpred15()) : alt10 = 3 elif LA10 == 29 or LA10 == 30 or LA10 == 31 or LA10 == 32 or LA10 == 33: alt10 = 1 elif LA10 == 34 or LA10 == 35 or LA10 == 36 or LA10 == 37 or LA10 == 38 or LA10 == 39 or LA10 == 40 or LA10 == 41 or LA10 == 42 or LA10 == 45 or LA10 == 46 or LA10 == 48: alt10 = 2 elif LA10 == 49 or LA10 == 50 or LA10 == 51 or LA10 == 52 or LA10 == 54 or LA10 == 55 or LA10 == 56 or LA10 == 57 or LA10 == 61: alt10 = 3 if alt10 == 1: # C.g:183:10: storage_class_specifier self.following.append(self.FOLLOW_storage_class_specifier_in_declaration_specifiers264) self.storage_class_specifier() self.following.pop() if self.failed: return retval elif alt10 == 2: # C.g:184:7: type_specifier self.following.append(self.FOLLOW_type_specifier_in_declaration_specifiers272) self.type_specifier() self.following.pop() if self.failed: return retval elif alt10 == 3: # C.g:185:13: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_declaration_specifiers286) self.type_qualifier() self.following.pop() if self.failed: return retval else: if cnt10 >= 1: break #loop10 if self.backtracking > 0: self.failed = True return retval eee = EarlyExitException(10, self.input) raise eee cnt10 += 1 retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 5, declaration_specifiers_StartIndex) pass return retval # $ANTLR end declaration_specifiers class init_declarator_list_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start init_declarator_list # C.g:189:1: init_declarator_list : init_declarator ( ',' init_declarator )* ; def init_declarator_list(self, ): retval = self.init_declarator_list_return() retval.start = self.input.LT(1) init_declarator_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 6): return retval # C.g:190:2: ( init_declarator ( ',' init_declarator )* ) # C.g:190:4: init_declarator ( ',' init_declarator )* self.following.append(self.FOLLOW_init_declarator_in_init_declarator_list308) self.init_declarator() self.following.pop() if self.failed: return retval # C.g:190:20: ( ',' init_declarator )* while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == 27) : alt11 = 1 if alt11 == 1: # C.g:190:21: ',' init_declarator self.match(self.input, 27, self.FOLLOW_27_in_init_declarator_list311) if self.failed: return retval self.following.append(self.FOLLOW_init_declarator_in_init_declarator_list313) self.init_declarator() self.following.pop() if self.failed: return retval else: break #loop11 retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 6, init_declarator_list_StartIndex) pass return retval # $ANTLR end init_declarator_list # $ANTLR start init_declarator # C.g:193:1: init_declarator : declarator ( '=' initializer )? ; def init_declarator(self, ): init_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 7): return # C.g:194:2: ( declarator ( '=' initializer )? ) # C.g:194:4: declarator ( '=' initializer )? self.following.append(self.FOLLOW_declarator_in_init_declarator326) self.declarator() self.following.pop() if self.failed: return # C.g:194:15: ( '=' initializer )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == 28) : alt12 = 1 if alt12 == 1: # C.g:194:16: '=' initializer self.match(self.input, 28, self.FOLLOW_28_in_init_declarator329) if self.failed: return self.following.append(self.FOLLOW_initializer_in_init_declarator331) self.initializer() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 7, init_declarator_StartIndex) pass return # $ANTLR end init_declarator # $ANTLR start storage_class_specifier # C.g:197:1: storage_class_specifier : ( 'extern' | 'static' | 'auto' | 'register' | 'STATIC' ); def storage_class_specifier(self, ): storage_class_specifier_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 8): return # C.g:198:2: ( 'extern' | 'static' | 'auto' | 'register' | 'STATIC' ) # C.g: if (29 <= self.input.LA(1) <= 33): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_storage_class_specifier0 ) raise mse except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 8, storage_class_specifier_StartIndex) pass return # $ANTLR end storage_class_specifier # $ANTLR start type_specifier # C.g:205:1: type_specifier : ( 'void' | 'char' | 'short' | 'int' | 'long' | 'float' | 'double' | 'signed' | 'unsigned' | s= struct_or_union_specifier | e= enum_specifier | ( IDENTIFIER ( type_qualifier )* declarator )=> type_id ); def type_specifier(self, ): type_specifier_StartIndex = self.input.index() s = None e = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 9): return # C.g:206:2: ( 'void' | 'char' | 'short' | 'int' | 'long' | 'float' | 'double' | 'signed' | 'unsigned' | s= struct_or_union_specifier | e= enum_specifier | ( IDENTIFIER ( type_qualifier )* declarator )=> type_id ) alt13 = 12 LA13_0 = self.input.LA(1) if (LA13_0 == 34) : alt13 = 1 elif (LA13_0 == 35) : alt13 = 2 elif (LA13_0 == 36) : alt13 = 3 elif (LA13_0 == 37) : alt13 = 4 elif (LA13_0 == 38) : alt13 = 5 elif (LA13_0 == 39) : alt13 = 6 elif (LA13_0 == 40) : alt13 = 7 elif (LA13_0 == 41) : alt13 = 8 elif (LA13_0 == 42) : alt13 = 9 elif ((45 <= LA13_0 <= 46)) : alt13 = 10 elif (LA13_0 == 48) : alt13 = 11 elif (LA13_0 == IDENTIFIER) and (self.synpred34()): alt13 = 12 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("205:1: type_specifier : ( 'void' | 'char' | 'short' | 'int' | 'long' | 'float' | 'double' | 'signed' | 'unsigned' | s= struct_or_union_specifier | e= enum_specifier | ( IDENTIFIER ( type_qualifier )* declarator )=> type_id );", 13, 0, self.input) raise nvae if alt13 == 1: # C.g:206:4: 'void' self.match(self.input, 34, self.FOLLOW_34_in_type_specifier376) if self.failed: return elif alt13 == 2: # C.g:207:4: 'char' self.match(self.input, 35, self.FOLLOW_35_in_type_specifier381) if self.failed: return elif alt13 == 3: # C.g:208:4: 'short' self.match(self.input, 36, self.FOLLOW_36_in_type_specifier386) if self.failed: return elif alt13 == 4: # C.g:209:4: 'int' self.match(self.input, 37, self.FOLLOW_37_in_type_specifier391) if self.failed: return elif alt13 == 5: # C.g:210:4: 'long' self.match(self.input, 38, self.FOLLOW_38_in_type_specifier396) if self.failed: return elif alt13 == 6: # C.g:211:4: 'float' self.match(self.input, 39, self.FOLLOW_39_in_type_specifier401) if self.failed: return elif alt13 == 7: # C.g:212:4: 'double' self.match(self.input, 40, self.FOLLOW_40_in_type_specifier406) if self.failed: return elif alt13 == 8: # C.g:213:4: 'signed' self.match(self.input, 41, self.FOLLOW_41_in_type_specifier411) if self.failed: return elif alt13 == 9: # C.g:214:4: 'unsigned' self.match(self.input, 42, self.FOLLOW_42_in_type_specifier416) if self.failed: return elif alt13 == 10: # C.g:215:4: s= struct_or_union_specifier self.following.append(self.FOLLOW_struct_or_union_specifier_in_type_specifier423) s = self.struct_or_union_specifier() self.following.pop() if self.failed: return if self.backtracking == 0: if s.stop is not None: self.StoreStructUnionDefinition(s.start.line, s.start.charPositionInLine, s.stop.line, s.stop.charPositionInLine, self.input.toString(s.start, s.stop)) elif alt13 == 11: # C.g:220:4: e= enum_specifier self.following.append(self.FOLLOW_enum_specifier_in_type_specifier433) e = self.enum_specifier() self.following.pop() if self.failed: return if self.backtracking == 0: if e.stop is not None: self.StoreEnumerationDefinition(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start, e.stop)) elif alt13 == 12: # C.g:225:4: ( IDENTIFIER ( type_qualifier )* declarator )=> type_id self.following.append(self.FOLLOW_type_id_in_type_specifier451) self.type_id() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 9, type_specifier_StartIndex) pass return # $ANTLR end type_specifier # $ANTLR start type_id # C.g:228:1: type_id : IDENTIFIER ; def type_id(self, ): type_id_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 10): return # C.g:229:5: ( IDENTIFIER ) # C.g:229:9: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_type_id467) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 10, type_id_StartIndex) pass return # $ANTLR end type_id class struct_or_union_specifier_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start struct_or_union_specifier # C.g:233:1: struct_or_union_specifier options {k=3; } : ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER ); def struct_or_union_specifier(self, ): retval = self.struct_or_union_specifier_return() retval.start = self.input.LT(1) struct_or_union_specifier_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 11): return retval # C.g:235:2: ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER ) alt15 = 2 LA15_0 = self.input.LA(1) if ((45 <= LA15_0 <= 46)) : LA15_1 = self.input.LA(2) if (LA15_1 == IDENTIFIER) : LA15_2 = self.input.LA(3) if (LA15_2 == 43) : alt15 = 1 elif (LA15_2 == EOF or LA15_2 == IDENTIFIER or LA15_2 == 25 or LA15_2 == 27 or (29 <= LA15_2 <= 42) or (45 <= LA15_2 <= 64) or LA15_2 == 66) : alt15 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("233:1: struct_or_union_specifier options {k=3; } : ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER );", 15, 2, self.input) raise nvae elif (LA15_1 == 43) : alt15 = 1 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("233:1: struct_or_union_specifier options {k=3; } : ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER );", 15, 1, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("233:1: struct_or_union_specifier options {k=3; } : ( struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' | struct_or_union IDENTIFIER );", 15, 0, self.input) raise nvae if alt15 == 1: # C.g:235:4: struct_or_union ( IDENTIFIER )? '{' struct_declaration_list '}' self.following.append(self.FOLLOW_struct_or_union_in_struct_or_union_specifier494) self.struct_or_union() self.following.pop() if self.failed: return retval # C.g:235:20: ( IDENTIFIER )? alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == IDENTIFIER) : alt14 = 1 if alt14 == 1: # C.g:0:0: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_struct_or_union_specifier496) if self.failed: return retval self.match(self.input, 43, self.FOLLOW_43_in_struct_or_union_specifier499) if self.failed: return retval self.following.append(self.FOLLOW_struct_declaration_list_in_struct_or_union_specifier501) self.struct_declaration_list() self.following.pop() if self.failed: return retval self.match(self.input, 44, self.FOLLOW_44_in_struct_or_union_specifier503) if self.failed: return retval elif alt15 == 2: # C.g:236:4: struct_or_union IDENTIFIER self.following.append(self.FOLLOW_struct_or_union_in_struct_or_union_specifier508) self.struct_or_union() self.following.pop() if self.failed: return retval self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_struct_or_union_specifier510) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 11, struct_or_union_specifier_StartIndex) pass return retval # $ANTLR end struct_or_union_specifier # $ANTLR start struct_or_union # C.g:239:1: struct_or_union : ( 'struct' | 'union' ); def struct_or_union(self, ): struct_or_union_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 12): return # C.g:240:2: ( 'struct' | 'union' ) # C.g: if (45 <= self.input.LA(1) <= 46): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_struct_or_union0 ) raise mse except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 12, struct_or_union_StartIndex) pass return # $ANTLR end struct_or_union # $ANTLR start struct_declaration_list # C.g:244:1: struct_declaration_list : ( struct_declaration )+ ; def struct_declaration_list(self, ): struct_declaration_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 13): return # C.g:245:2: ( ( struct_declaration )+ ) # C.g:245:4: ( struct_declaration )+ # C.g:245:4: ( struct_declaration )+ cnt16 = 0 while True: #loop16 alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == IDENTIFIER or (34 <= LA16_0 <= 42) or (45 <= LA16_0 <= 46) or (48 <= LA16_0 <= 61)) : alt16 = 1 if alt16 == 1: # C.g:0:0: struct_declaration self.following.append(self.FOLLOW_struct_declaration_in_struct_declaration_list537) self.struct_declaration() self.following.pop() if self.failed: return else: if cnt16 >= 1: break #loop16 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(16, self.input) raise eee cnt16 += 1 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 13, struct_declaration_list_StartIndex) pass return # $ANTLR end struct_declaration_list # $ANTLR start struct_declaration # C.g:248:1: struct_declaration : specifier_qualifier_list struct_declarator_list ';' ; def struct_declaration(self, ): struct_declaration_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 14): return # C.g:249:2: ( specifier_qualifier_list struct_declarator_list ';' ) # C.g:249:4: specifier_qualifier_list struct_declarator_list ';' self.following.append(self.FOLLOW_specifier_qualifier_list_in_struct_declaration549) self.specifier_qualifier_list() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_struct_declarator_list_in_struct_declaration551) self.struct_declarator_list() self.following.pop() if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_struct_declaration553) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 14, struct_declaration_StartIndex) pass return # $ANTLR end struct_declaration # $ANTLR start specifier_qualifier_list # C.g:252:1: specifier_qualifier_list : ( type_qualifier | type_specifier )+ ; def specifier_qualifier_list(self, ): specifier_qualifier_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 15): return # C.g:253:2: ( ( type_qualifier | type_specifier )+ ) # C.g:253:4: ( type_qualifier | type_specifier )+ # C.g:253:4: ( type_qualifier | type_specifier )+ cnt17 = 0 while True: #loop17 alt17 = 3 LA17 = self.input.LA(1) if LA17 == 58: LA17_2 = self.input.LA(2) if (self.synpred39()) : alt17 = 1 elif LA17 == 59: LA17_3 = self.input.LA(2) if (self.synpred39()) : alt17 = 1 elif LA17 == 60: LA17_4 = self.input.LA(2) if (self.synpred39()) : alt17 = 1 elif LA17 == IDENTIFIER: LA17 = self.input.LA(2) if LA17 == EOF or LA17 == IDENTIFIER or LA17 == 34 or LA17 == 35 or LA17 == 36 or LA17 == 37 or LA17 == 38 or LA17 == 39 or LA17 == 40 or LA17 == 41 or LA17 == 42 or LA17 == 45 or LA17 == 46 or LA17 == 48 or LA17 == 49 or LA17 == 50 or LA17 == 51 or LA17 == 52 or LA17 == 53 or LA17 == 54 or LA17 == 55 or LA17 == 56 or LA17 == 57 or LA17 == 58 or LA17 == 59 or LA17 == 60 or LA17 == 61 or LA17 == 63 or LA17 == 66: alt17 = 2 elif LA17 == 62: LA17_94 = self.input.LA(3) if (self.synpred40()) : alt17 = 2 elif LA17 == 47: LA17_95 = self.input.LA(3) if (self.synpred40()) : alt17 = 2 elif LA17 == 64: LA17_96 = self.input.LA(3) if (self.synpred40()) : alt17 = 2 elif LA17 == 49 or LA17 == 50 or LA17 == 51 or LA17 == 52 or LA17 == 53 or LA17 == 54 or LA17 == 55 or LA17 == 56 or LA17 == 57 or LA17 == 61: alt17 = 1 elif LA17 == 34 or LA17 == 35 or LA17 == 36 or LA17 == 37 or LA17 == 38 or LA17 == 39 or LA17 == 40 or LA17 == 41 or LA17 == 42 or LA17 == 45 or LA17 == 46 or LA17 == 48: alt17 = 2 if alt17 == 1: # C.g:253:6: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_specifier_qualifier_list566) self.type_qualifier() self.following.pop() if self.failed: return elif alt17 == 2: # C.g:253:23: type_specifier self.following.append(self.FOLLOW_type_specifier_in_specifier_qualifier_list570) self.type_specifier() self.following.pop() if self.failed: return else: if cnt17 >= 1: break #loop17 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(17, self.input) raise eee cnt17 += 1 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 15, specifier_qualifier_list_StartIndex) pass return # $ANTLR end specifier_qualifier_list # $ANTLR start struct_declarator_list # C.g:256:1: struct_declarator_list : struct_declarator ( ',' struct_declarator )* ; def struct_declarator_list(self, ): struct_declarator_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 16): return # C.g:257:2: ( struct_declarator ( ',' struct_declarator )* ) # C.g:257:4: struct_declarator ( ',' struct_declarator )* self.following.append(self.FOLLOW_struct_declarator_in_struct_declarator_list584) self.struct_declarator() self.following.pop() if self.failed: return # C.g:257:22: ( ',' struct_declarator )* while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == 27) : alt18 = 1 if alt18 == 1: # C.g:257:23: ',' struct_declarator self.match(self.input, 27, self.FOLLOW_27_in_struct_declarator_list587) if self.failed: return self.following.append(self.FOLLOW_struct_declarator_in_struct_declarator_list589) self.struct_declarator() self.following.pop() if self.failed: return else: break #loop18 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 16, struct_declarator_list_StartIndex) pass return # $ANTLR end struct_declarator_list # $ANTLR start struct_declarator # C.g:260:1: struct_declarator : ( declarator ( ':' constant_expression )? | ':' constant_expression ); def struct_declarator(self, ): struct_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 17): return # C.g:261:2: ( declarator ( ':' constant_expression )? | ':' constant_expression ) alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == IDENTIFIER or (58 <= LA20_0 <= 60) or LA20_0 == 62 or LA20_0 == 66) : alt20 = 1 elif (LA20_0 == 47) : alt20 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("260:1: struct_declarator : ( declarator ( ':' constant_expression )? | ':' constant_expression );", 20, 0, self.input) raise nvae if alt20 == 1: # C.g:261:4: declarator ( ':' constant_expression )? self.following.append(self.FOLLOW_declarator_in_struct_declarator602) self.declarator() self.following.pop() if self.failed: return # C.g:261:15: ( ':' constant_expression )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == 47) : alt19 = 1 if alt19 == 1: # C.g:261:16: ':' constant_expression self.match(self.input, 47, self.FOLLOW_47_in_struct_declarator605) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_struct_declarator607) self.constant_expression() self.following.pop() if self.failed: return elif alt20 == 2: # C.g:262:4: ':' constant_expression self.match(self.input, 47, self.FOLLOW_47_in_struct_declarator614) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_struct_declarator616) self.constant_expression() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 17, struct_declarator_StartIndex) pass return # $ANTLR end struct_declarator class enum_specifier_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start enum_specifier # C.g:265:1: enum_specifier options {k=3; } : ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER ); def enum_specifier(self, ): retval = self.enum_specifier_return() retval.start = self.input.LT(1) enum_specifier_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 18): return retval # C.g:267:2: ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER ) alt23 = 3 LA23_0 = self.input.LA(1) if (LA23_0 == 48) : LA23_1 = self.input.LA(2) if (LA23_1 == IDENTIFIER) : LA23_2 = self.input.LA(3) if (LA23_2 == 43) : alt23 = 2 elif (LA23_2 == EOF or LA23_2 == IDENTIFIER or LA23_2 == 25 or LA23_2 == 27 or (29 <= LA23_2 <= 42) or (45 <= LA23_2 <= 64) or LA23_2 == 66) : alt23 = 3 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("265:1: enum_specifier options {k=3; } : ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER );", 23, 2, self.input) raise nvae elif (LA23_1 == 43) : alt23 = 1 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("265:1: enum_specifier options {k=3; } : ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER );", 23, 1, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("265:1: enum_specifier options {k=3; } : ( 'enum' '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' | 'enum' IDENTIFIER );", 23, 0, self.input) raise nvae if alt23 == 1: # C.g:267:4: 'enum' '{' enumerator_list ( ',' )? '}' self.match(self.input, 48, self.FOLLOW_48_in_enum_specifier634) if self.failed: return retval self.match(self.input, 43, self.FOLLOW_43_in_enum_specifier636) if self.failed: return retval self.following.append(self.FOLLOW_enumerator_list_in_enum_specifier638) self.enumerator_list() self.following.pop() if self.failed: return retval # C.g:267:31: ( ',' )? alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == 27) : alt21 = 1 if alt21 == 1: # C.g:0:0: ',' self.match(self.input, 27, self.FOLLOW_27_in_enum_specifier640) if self.failed: return retval self.match(self.input, 44, self.FOLLOW_44_in_enum_specifier643) if self.failed: return retval elif alt23 == 2: # C.g:268:4: 'enum' IDENTIFIER '{' enumerator_list ( ',' )? '}' self.match(self.input, 48, self.FOLLOW_48_in_enum_specifier648) if self.failed: return retval self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enum_specifier650) if self.failed: return retval self.match(self.input, 43, self.FOLLOW_43_in_enum_specifier652) if self.failed: return retval self.following.append(self.FOLLOW_enumerator_list_in_enum_specifier654) self.enumerator_list() self.following.pop() if self.failed: return retval # C.g:268:42: ( ',' )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == 27) : alt22 = 1 if alt22 == 1: # C.g:0:0: ',' self.match(self.input, 27, self.FOLLOW_27_in_enum_specifier656) if self.failed: return retval self.match(self.input, 44, self.FOLLOW_44_in_enum_specifier659) if self.failed: return retval elif alt23 == 3: # C.g:269:4: 'enum' IDENTIFIER self.match(self.input, 48, self.FOLLOW_48_in_enum_specifier664) if self.failed: return retval self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enum_specifier666) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 18, enum_specifier_StartIndex) pass return retval # $ANTLR end enum_specifier # $ANTLR start enumerator_list # C.g:272:1: enumerator_list : enumerator ( ',' enumerator )* ; def enumerator_list(self, ): enumerator_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 19): return # C.g:273:2: ( enumerator ( ',' enumerator )* ) # C.g:273:4: enumerator ( ',' enumerator )* self.following.append(self.FOLLOW_enumerator_in_enumerator_list677) self.enumerator() self.following.pop() if self.failed: return # C.g:273:15: ( ',' enumerator )* while True: #loop24 alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == 27) : LA24_1 = self.input.LA(2) if (LA24_1 == IDENTIFIER) : alt24 = 1 if alt24 == 1: # C.g:273:16: ',' enumerator self.match(self.input, 27, self.FOLLOW_27_in_enumerator_list680) if self.failed: return self.following.append(self.FOLLOW_enumerator_in_enumerator_list682) self.enumerator() self.following.pop() if self.failed: return else: break #loop24 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 19, enumerator_list_StartIndex) pass return # $ANTLR end enumerator_list # $ANTLR start enumerator # C.g:276:1: enumerator : IDENTIFIER ( '=' constant_expression )? ; def enumerator(self, ): enumerator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 20): return # C.g:277:2: ( IDENTIFIER ( '=' constant_expression )? ) # C.g:277:4: IDENTIFIER ( '=' constant_expression )? self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enumerator695) if self.failed: return # C.g:277:15: ( '=' constant_expression )? alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == 28) : alt25 = 1 if alt25 == 1: # C.g:277:16: '=' constant_expression self.match(self.input, 28, self.FOLLOW_28_in_enumerator698) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_enumerator700) self.constant_expression() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 20, enumerator_StartIndex) pass return # $ANTLR end enumerator # $ANTLR start type_qualifier # C.g:280:1: type_qualifier : ( 'const' | 'volatile' | 'IN' | 'OUT' | 'OPTIONAL' | 'CONST' | 'UNALIGNED' | 'VOLATILE' | 'GLOBAL_REMOVE_IF_UNREFERENCED' | 'EFIAPI' | 'EFI_BOOTSERVICE' | 'EFI_RUNTIMESERVICE' | 'PACKED' ); def type_qualifier(self, ): type_qualifier_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 21): return # C.g:281:2: ( 'const' | 'volatile' | 'IN' | 'OUT' | 'OPTIONAL' | 'CONST' | 'UNALIGNED' | 'VOLATILE' | 'GLOBAL_REMOVE_IF_UNREFERENCED' | 'EFIAPI' | 'EFI_BOOTSERVICE' | 'EFI_RUNTIMESERVICE' | 'PACKED' ) # C.g: if (49 <= self.input.LA(1) <= 61): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_type_qualifier0 ) raise mse except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 21, type_qualifier_StartIndex) pass return # $ANTLR end type_qualifier class declarator_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start declarator # C.g:296:1: declarator : ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator | pointer ); def declarator(self, ): retval = self.declarator_return() retval.start = self.input.LT(1) declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 22): return retval # C.g:297:2: ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator | pointer ) alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == 66) : LA30_1 = self.input.LA(2) if (self.synpred66()) : alt30 = 1 elif (True) : alt30 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("296:1: declarator : ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator | pointer );", 30, 1, self.input) raise nvae elif (LA30_0 == IDENTIFIER or (58 <= LA30_0 <= 60) or LA30_0 == 62) : alt30 = 1 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("296:1: declarator : ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator | pointer );", 30, 0, self.input) raise nvae if alt30 == 1: # C.g:297:4: ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator # C.g:297:4: ( pointer )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == 66) : alt26 = 1 if alt26 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_declarator784) self.pointer() self.following.pop() if self.failed: return retval # C.g:297:13: ( 'EFIAPI' )? alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == 58) : alt27 = 1 if alt27 == 1: # C.g:297:14: 'EFIAPI' self.match(self.input, 58, self.FOLLOW_58_in_declarator788) if self.failed: return retval # C.g:297:25: ( 'EFI_BOOTSERVICE' )? alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == 59) : alt28 = 1 if alt28 == 1: # C.g:297:26: 'EFI_BOOTSERVICE' self.match(self.input, 59, self.FOLLOW_59_in_declarator793) if self.failed: return retval # C.g:297:46: ( 'EFI_RUNTIMESERVICE' )? alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == 60) : alt29 = 1 if alt29 == 1: # C.g:297:47: 'EFI_RUNTIMESERVICE' self.match(self.input, 60, self.FOLLOW_60_in_declarator798) if self.failed: return retval self.following.append(self.FOLLOW_direct_declarator_in_declarator802) self.direct_declarator() self.following.pop() if self.failed: return retval elif alt30 == 2: # C.g:299:4: pointer self.following.append(self.FOLLOW_pointer_in_declarator808) self.pointer() self.following.pop() if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 22, declarator_StartIndex) pass return retval # $ANTLR end declarator # $ANTLR start direct_declarator # C.g:302:1: direct_declarator : ( IDENTIFIER ( declarator_suffix )* | '(' ( 'EFIAPI' )? declarator ')' ( declarator_suffix )+ ); def direct_declarator(self, ): direct_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 23): return # C.g:303:2: ( IDENTIFIER ( declarator_suffix )* | '(' ( 'EFIAPI' )? declarator ')' ( declarator_suffix )+ ) alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == IDENTIFIER) : alt34 = 1 elif (LA34_0 == 62) : alt34 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("302:1: direct_declarator : ( IDENTIFIER ( declarator_suffix )* | '(' ( 'EFIAPI' )? declarator ')' ( declarator_suffix )+ );", 34, 0, self.input) raise nvae if alt34 == 1: # C.g:303:4: IDENTIFIER ( declarator_suffix )* self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_direct_declarator819) if self.failed: return # C.g:303:15: ( declarator_suffix )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == 62) : LA31 = self.input.LA(2) if LA31 == 63: LA31_30 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 58: LA31_31 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 66: LA31_32 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 59: LA31_33 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 60: LA31_34 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == IDENTIFIER: LA31_35 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 29 or LA31 == 30 or LA31 == 31 or LA31 == 32 or LA31 == 33: LA31_37 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 34: LA31_38 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 35: LA31_39 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 36: LA31_40 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 37: LA31_41 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 38: LA31_42 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 39: LA31_43 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 40: LA31_44 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 41: LA31_45 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 42: LA31_46 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 45 or LA31 == 46: LA31_47 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 48: LA31_48 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 49 or LA31 == 50 or LA31 == 51 or LA31 == 52 or LA31 == 53 or LA31 == 54 or LA31 == 55 or LA31 == 56 or LA31 == 57 or LA31 == 61: LA31_49 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif (LA31_0 == 64) : LA31 = self.input.LA(2) if LA31 == 65: LA31_51 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 62: LA31_52 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == IDENTIFIER: LA31_53 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == HEX_LITERAL: LA31_54 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == OCTAL_LITERAL: LA31_55 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == DECIMAL_LITERAL: LA31_56 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == CHARACTER_LITERAL: LA31_57 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == STRING_LITERAL: LA31_58 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == FLOATING_POINT_LITERAL: LA31_59 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 72: LA31_60 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 73: LA31_61 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 66 or LA31 == 68 or LA31 == 69 or LA31 == 77 or LA31 == 78 or LA31 == 79: LA31_62 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 elif LA31 == 74: LA31_63 = self.input.LA(3) if (self.synpred67()) : alt31 = 1 if alt31 == 1: # C.g:0:0: declarator_suffix self.following.append(self.FOLLOW_declarator_suffix_in_direct_declarator821) self.declarator_suffix() self.following.pop() if self.failed: return else: break #loop31 elif alt34 == 2: # C.g:304:4: '(' ( 'EFIAPI' )? declarator ')' ( declarator_suffix )+ self.match(self.input, 62, self.FOLLOW_62_in_direct_declarator827) if self.failed: return # C.g:304:8: ( 'EFIAPI' )? alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == 58) : LA32_1 = self.input.LA(2) if (self.synpred69()) : alt32 = 1 if alt32 == 1: # C.g:304:9: 'EFIAPI' self.match(self.input, 58, self.FOLLOW_58_in_direct_declarator830) if self.failed: return self.following.append(self.FOLLOW_declarator_in_direct_declarator834) self.declarator() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_direct_declarator836) if self.failed: return # C.g:304:35: ( declarator_suffix )+ cnt33 = 0 while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == 62) : LA33 = self.input.LA(2) if LA33 == 63: LA33_30 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 58: LA33_31 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 66: LA33_32 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 59: LA33_33 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 60: LA33_34 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == IDENTIFIER: LA33_35 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 29 or LA33 == 30 or LA33 == 31 or LA33 == 32 or LA33 == 33: LA33_37 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 34: LA33_38 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 35: LA33_39 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 36: LA33_40 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 37: LA33_41 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 38: LA33_42 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 39: LA33_43 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 40: LA33_44 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 41: LA33_45 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 42: LA33_46 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 45 or LA33 == 46: LA33_47 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 48: LA33_48 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 49 or LA33 == 50 or LA33 == 51 or LA33 == 52 or LA33 == 53 or LA33 == 54 or LA33 == 55 or LA33 == 56 or LA33 == 57 or LA33 == 61: LA33_49 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif (LA33_0 == 64) : LA33 = self.input.LA(2) if LA33 == 65: LA33_51 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 62: LA33_52 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == IDENTIFIER: LA33_53 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == HEX_LITERAL: LA33_54 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == OCTAL_LITERAL: LA33_55 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == DECIMAL_LITERAL: LA33_56 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == CHARACTER_LITERAL: LA33_57 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == STRING_LITERAL: LA33_58 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == FLOATING_POINT_LITERAL: LA33_59 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 72: LA33_60 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 73: LA33_61 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 66 or LA33 == 68 or LA33 == 69 or LA33 == 77 or LA33 == 78 or LA33 == 79: LA33_62 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 elif LA33 == 74: LA33_63 = self.input.LA(3) if (self.synpred70()) : alt33 = 1 if alt33 == 1: # C.g:0:0: declarator_suffix self.following.append(self.FOLLOW_declarator_suffix_in_direct_declarator838) self.declarator_suffix() self.following.pop() if self.failed: return else: if cnt33 >= 1: break #loop33 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(33, self.input) raise eee cnt33 += 1 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 23, direct_declarator_StartIndex) pass return # $ANTLR end direct_declarator # $ANTLR start declarator_suffix # C.g:307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' ); def declarator_suffix(self, ): declarator_suffix_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 24): return # C.g:308:2: ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' ) alt35 = 5 LA35_0 = self.input.LA(1) if (LA35_0 == 64) : LA35_1 = self.input.LA(2) if (LA35_1 == 65) : alt35 = 2 elif ((IDENTIFIER <= LA35_1 <= FLOATING_POINT_LITERAL) or LA35_1 == 62 or LA35_1 == 66 or (68 <= LA35_1 <= 69) or (72 <= LA35_1 <= 74) or (77 <= LA35_1 <= 79)) : alt35 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' );", 35, 1, self.input) raise nvae elif (LA35_0 == 62) : LA35 = self.input.LA(2) if LA35 == 63: alt35 = 5 elif LA35 == 29 or LA35 == 30 or LA35 == 31 or LA35 == 32 or LA35 == 33 or LA35 == 34 or LA35 == 35 or LA35 == 36 or LA35 == 37 or LA35 == 38 or LA35 == 39 or LA35 == 40 or LA35 == 41 or LA35 == 42 or LA35 == 45 or LA35 == 46 or LA35 == 48 or LA35 == 49 or LA35 == 50 or LA35 == 51 or LA35 == 52 or LA35 == 53 or LA35 == 54 or LA35 == 55 or LA35 == 56 or LA35 == 57 or LA35 == 58 or LA35 == 59 or LA35 == 60 or LA35 == 61 or LA35 == 66: alt35 = 3 elif LA35 == IDENTIFIER: LA35_29 = self.input.LA(3) if (self.synpred73()) : alt35 = 3 elif (self.synpred74()) : alt35 = 4 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' );", 35, 29, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' );", 35, 2, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("307:1: declarator_suffix : ( '[' constant_expression ']' | '[' ']' | '(' parameter_type_list ')' | '(' identifier_list ')' | '(' ')' );", 35, 0, self.input) raise nvae if alt35 == 1: # C.g:308:6: '[' constant_expression ']' self.match(self.input, 64, self.FOLLOW_64_in_declarator_suffix852) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_declarator_suffix854) self.constant_expression() self.following.pop() if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_declarator_suffix856) if self.failed: return elif alt35 == 2: # C.g:309:9: '[' ']' self.match(self.input, 64, self.FOLLOW_64_in_declarator_suffix866) if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_declarator_suffix868) if self.failed: return elif alt35 == 3: # C.g:310:9: '(' parameter_type_list ')' self.match(self.input, 62, self.FOLLOW_62_in_declarator_suffix878) if self.failed: return self.following.append(self.FOLLOW_parameter_type_list_in_declarator_suffix880) self.parameter_type_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_declarator_suffix882) if self.failed: return elif alt35 == 4: # C.g:311:9: '(' identifier_list ')' self.match(self.input, 62, self.FOLLOW_62_in_declarator_suffix892) if self.failed: return self.following.append(self.FOLLOW_identifier_list_in_declarator_suffix894) self.identifier_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_declarator_suffix896) if self.failed: return elif alt35 == 5: # C.g:312:9: '(' ')' self.match(self.input, 62, self.FOLLOW_62_in_declarator_suffix906) if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_declarator_suffix908) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 24, declarator_suffix_StartIndex) pass return # $ANTLR end declarator_suffix # $ANTLR start pointer # C.g:315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' ); def pointer(self, ): pointer_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 25): return # C.g:316:2: ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' ) alt38 = 3 LA38_0 = self.input.LA(1) if (LA38_0 == 66) : LA38 = self.input.LA(2) if LA38 == 66: LA38_2 = self.input.LA(3) if (self.synpred78()) : alt38 = 2 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 2, self.input) raise nvae elif LA38 == 58: LA38_3 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 3, self.input) raise nvae elif LA38 == 59: LA38_4 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 4, self.input) raise nvae elif LA38 == 60: LA38_5 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 5, self.input) raise nvae elif LA38 == EOF or LA38 == IDENTIFIER or LA38 == 25 or LA38 == 26 or LA38 == 27 or LA38 == 28 or LA38 == 29 or LA38 == 30 or LA38 == 31 or LA38 == 32 or LA38 == 33 or LA38 == 34 or LA38 == 35 or LA38 == 36 or LA38 == 37 or LA38 == 38 or LA38 == 39 or LA38 == 40 or LA38 == 41 or LA38 == 42 or LA38 == 43 or LA38 == 45 or LA38 == 46 or LA38 == 47 or LA38 == 48 or LA38 == 62 or LA38 == 63 or LA38 == 64: alt38 = 3 elif LA38 == 53: LA38_21 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 21, self.input) raise nvae elif LA38 == 49 or LA38 == 50 or LA38 == 51 or LA38 == 52 or LA38 == 54 or LA38 == 55 or LA38 == 56 or LA38 == 57 or LA38 == 61: LA38_29 = self.input.LA(3) if (self.synpred77()) : alt38 = 1 elif (True) : alt38 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 29, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 1, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("315:1: pointer : ( '*' ( type_qualifier )+ ( pointer )? | '*' pointer | '*' );", 38, 0, self.input) raise nvae if alt38 == 1: # C.g:316:4: '*' ( type_qualifier )+ ( pointer )? self.match(self.input, 66, self.FOLLOW_66_in_pointer919) if self.failed: return # C.g:316:8: ( type_qualifier )+ cnt36 = 0 while True: #loop36 alt36 = 2 LA36 = self.input.LA(1) if LA36 == 58: LA36_2 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 elif LA36 == 59: LA36_3 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 elif LA36 == 60: LA36_4 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 elif LA36 == 53: LA36_20 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 elif LA36 == 49 or LA36 == 50 or LA36 == 51 or LA36 == 52 or LA36 == 54 or LA36 == 55 or LA36 == 56 or LA36 == 57 or LA36 == 61: LA36_28 = self.input.LA(2) if (self.synpred75()) : alt36 = 1 if alt36 == 1: # C.g:0:0: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_pointer921) self.type_qualifier() self.following.pop() if self.failed: return else: if cnt36 >= 1: break #loop36 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(36, self.input) raise eee cnt36 += 1 # C.g:316:24: ( pointer )? alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == 66) : LA37_1 = self.input.LA(2) if (self.synpred76()) : alt37 = 1 if alt37 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_pointer924) self.pointer() self.following.pop() if self.failed: return elif alt38 == 2: # C.g:317:4: '*' pointer self.match(self.input, 66, self.FOLLOW_66_in_pointer930) if self.failed: return self.following.append(self.FOLLOW_pointer_in_pointer932) self.pointer() self.following.pop() if self.failed: return elif alt38 == 3: # C.g:318:4: '*' self.match(self.input, 66, self.FOLLOW_66_in_pointer937) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 25, pointer_StartIndex) pass return # $ANTLR end pointer # $ANTLR start parameter_type_list # C.g:321:1: parameter_type_list : parameter_list ( ',' ( 'OPTIONAL' )? '...' )? ; def parameter_type_list(self, ): parameter_type_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 26): return # C.g:322:2: ( parameter_list ( ',' ( 'OPTIONAL' )? '...' )? ) # C.g:322:4: parameter_list ( ',' ( 'OPTIONAL' )? '...' )? self.following.append(self.FOLLOW_parameter_list_in_parameter_type_list948) self.parameter_list() self.following.pop() if self.failed: return # C.g:322:19: ( ',' ( 'OPTIONAL' )? '...' )? alt40 = 2 LA40_0 = self.input.LA(1) if (LA40_0 == 27) : alt40 = 1 if alt40 == 1: # C.g:322:20: ',' ( 'OPTIONAL' )? '...' self.match(self.input, 27, self.FOLLOW_27_in_parameter_type_list951) if self.failed: return # C.g:322:24: ( 'OPTIONAL' )? alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == 53) : alt39 = 1 if alt39 == 1: # C.g:322:25: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_parameter_type_list954) if self.failed: return self.match(self.input, 67, self.FOLLOW_67_in_parameter_type_list958) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 26, parameter_type_list_StartIndex) pass return # $ANTLR end parameter_type_list # $ANTLR start parameter_list # C.g:325:1: parameter_list : parameter_declaration ( ',' ( 'OPTIONAL' )? parameter_declaration )* ; def parameter_list(self, ): parameter_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 27): return # C.g:326:2: ( parameter_declaration ( ',' ( 'OPTIONAL' )? parameter_declaration )* ) # C.g:326:4: parameter_declaration ( ',' ( 'OPTIONAL' )? parameter_declaration )* self.following.append(self.FOLLOW_parameter_declaration_in_parameter_list971) self.parameter_declaration() self.following.pop() if self.failed: return # C.g:326:26: ( ',' ( 'OPTIONAL' )? parameter_declaration )* while True: #loop42 alt42 = 2 LA42_0 = self.input.LA(1) if (LA42_0 == 27) : LA42_1 = self.input.LA(2) if (LA42_1 == 53) : LA42_3 = self.input.LA(3) if (self.synpred82()) : alt42 = 1 elif (LA42_1 == IDENTIFIER or (29 <= LA42_1 <= 42) or (45 <= LA42_1 <= 46) or (48 <= LA42_1 <= 52) or (54 <= LA42_1 <= 61) or LA42_1 == 66) : alt42 = 1 if alt42 == 1: # C.g:326:27: ',' ( 'OPTIONAL' )? parameter_declaration self.match(self.input, 27, self.FOLLOW_27_in_parameter_list974) if self.failed: return # C.g:326:31: ( 'OPTIONAL' )? alt41 = 2 LA41_0 = self.input.LA(1) if (LA41_0 == 53) : LA41_1 = self.input.LA(2) if (self.synpred81()) : alt41 = 1 if alt41 == 1: # C.g:326:32: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_parameter_list977) if self.failed: return self.following.append(self.FOLLOW_parameter_declaration_in_parameter_list981) self.parameter_declaration() self.following.pop() if self.failed: return else: break #loop42 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 27, parameter_list_StartIndex) pass return # $ANTLR end parameter_list # $ANTLR start parameter_declaration # C.g:329:1: parameter_declaration : ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? | ( pointer )* IDENTIFIER ); def parameter_declaration(self, ): parameter_declaration_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 28): return # C.g:330:2: ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? | ( pointer )* IDENTIFIER ) alt46 = 2 LA46 = self.input.LA(1) if LA46 == 29 or LA46 == 30 or LA46 == 31 or LA46 == 32 or LA46 == 33 or LA46 == 34 or LA46 == 35 or LA46 == 36 or LA46 == 37 or LA46 == 38 or LA46 == 39 or LA46 == 40 or LA46 == 41 or LA46 == 42 or LA46 == 45 or LA46 == 46 or LA46 == 48 or LA46 == 49 or LA46 == 50 or LA46 == 51 or LA46 == 52 or LA46 == 53 or LA46 == 54 or LA46 == 55 or LA46 == 56 or LA46 == 57 or LA46 == 58 or LA46 == 59 or LA46 == 60 or LA46 == 61: alt46 = 1 elif LA46 == IDENTIFIER: LA46_13 = self.input.LA(2) if (self.synpred86()) : alt46 = 1 elif (True) : alt46 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("329:1: parameter_declaration : ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? | ( pointer )* IDENTIFIER );", 46, 13, self.input) raise nvae elif LA46 == 66: alt46 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("329:1: parameter_declaration : ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? | ( pointer )* IDENTIFIER );", 46, 0, self.input) raise nvae if alt46 == 1: # C.g:330:4: declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? self.following.append(self.FOLLOW_declaration_specifiers_in_parameter_declaration994) self.declaration_specifiers() self.following.pop() if self.failed: return # C.g:330:27: ( declarator | abstract_declarator )* while True: #loop43 alt43 = 3 LA43 = self.input.LA(1) if LA43 == 66: LA43_5 = self.input.LA(2) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == IDENTIFIER or LA43 == 58 or LA43 == 59 or LA43 == 60: alt43 = 1 elif LA43 == 62: LA43 = self.input.LA(2) if LA43 == 29 or LA43 == 30 or LA43 == 31 or LA43 == 32 or LA43 == 33 or LA43 == 34 or LA43 == 35 or LA43 == 36 or LA43 == 37 or LA43 == 38 or LA43 == 39 or LA43 == 40 or LA43 == 41 or LA43 == 42 or LA43 == 45 or LA43 == 46 or LA43 == 48 or LA43 == 49 or LA43 == 50 or LA43 == 51 or LA43 == 52 or LA43 == 53 or LA43 == 54 or LA43 == 55 or LA43 == 56 or LA43 == 57 or LA43 == 61 or LA43 == 63 or LA43 == 64: alt43 = 2 elif LA43 == IDENTIFIER: LA43_37 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 58: LA43_38 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 66: LA43_39 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 59: LA43_40 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 60: LA43_41 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 62: LA43_43 = self.input.LA(3) if (self.synpred83()) : alt43 = 1 elif (self.synpred84()) : alt43 = 2 elif LA43 == 64: alt43 = 2 if alt43 == 1: # C.g:330:28: declarator self.following.append(self.FOLLOW_declarator_in_parameter_declaration997) self.declarator() self.following.pop() if self.failed: return elif alt43 == 2: # C.g:330:39: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_parameter_declaration999) self.abstract_declarator() self.following.pop() if self.failed: return else: break #loop43 # C.g:330:61: ( 'OPTIONAL' )? alt44 = 2 LA44_0 = self.input.LA(1) if (LA44_0 == 53) : alt44 = 1 if alt44 == 1: # C.g:330:62: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_parameter_declaration1004) if self.failed: return elif alt46 == 2: # C.g:332:4: ( pointer )* IDENTIFIER # C.g:332:4: ( pointer )* while True: #loop45 alt45 = 2 LA45_0 = self.input.LA(1) if (LA45_0 == 66) : alt45 = 1 if alt45 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_parameter_declaration1013) self.pointer() self.following.pop() if self.failed: return else: break #loop45 self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_parameter_declaration1016) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 28, parameter_declaration_StartIndex) pass return # $ANTLR end parameter_declaration # $ANTLR start identifier_list # C.g:335:1: identifier_list : IDENTIFIER ( ',' IDENTIFIER )* ; def identifier_list(self, ): identifier_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 29): return # C.g:336:2: ( IDENTIFIER ( ',' IDENTIFIER )* ) # C.g:336:4: IDENTIFIER ( ',' IDENTIFIER )* self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_identifier_list1027) if self.failed: return # C.g:337:2: ( ',' IDENTIFIER )* while True: #loop47 alt47 = 2 LA47_0 = self.input.LA(1) if (LA47_0 == 27) : alt47 = 1 if alt47 == 1: # C.g:337:3: ',' IDENTIFIER self.match(self.input, 27, self.FOLLOW_27_in_identifier_list1031) if self.failed: return self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_identifier_list1033) if self.failed: return else: break #loop47 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 29, identifier_list_StartIndex) pass return # $ANTLR end identifier_list # $ANTLR start type_name # C.g:340:1: type_name : ( specifier_qualifier_list ( abstract_declarator )? | type_id ); def type_name(self, ): type_name_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 30): return # C.g:341:2: ( specifier_qualifier_list ( abstract_declarator )? | type_id ) alt49 = 2 LA49_0 = self.input.LA(1) if ((34 <= LA49_0 <= 42) or (45 <= LA49_0 <= 46) or (48 <= LA49_0 <= 61)) : alt49 = 1 elif (LA49_0 == IDENTIFIER) : LA49_13 = self.input.LA(2) if (self.synpred90()) : alt49 = 1 elif (True) : alt49 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("340:1: type_name : ( specifier_qualifier_list ( abstract_declarator )? | type_id );", 49, 13, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("340:1: type_name : ( specifier_qualifier_list ( abstract_declarator )? | type_id );", 49, 0, self.input) raise nvae if alt49 == 1: # C.g:341:4: specifier_qualifier_list ( abstract_declarator )? self.following.append(self.FOLLOW_specifier_qualifier_list_in_type_name1046) self.specifier_qualifier_list() self.following.pop() if self.failed: return # C.g:341:29: ( abstract_declarator )? alt48 = 2 LA48_0 = self.input.LA(1) if (LA48_0 == 62 or LA48_0 == 64 or LA48_0 == 66) : alt48 = 1 if alt48 == 1: # C.g:0:0: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_type_name1048) self.abstract_declarator() self.following.pop() if self.failed: return elif alt49 == 2: # C.g:342:4: type_id self.following.append(self.FOLLOW_type_id_in_type_name1054) self.type_id() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 30, type_name_StartIndex) pass return # $ANTLR end type_name # $ANTLR start abstract_declarator # C.g:345:1: abstract_declarator : ( pointer ( direct_abstract_declarator )? | direct_abstract_declarator ); def abstract_declarator(self, ): abstract_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 31): return # C.g:346:2: ( pointer ( direct_abstract_declarator )? | direct_abstract_declarator ) alt51 = 2 LA51_0 = self.input.LA(1) if (LA51_0 == 66) : alt51 = 1 elif (LA51_0 == 62 or LA51_0 == 64) : alt51 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("345:1: abstract_declarator : ( pointer ( direct_abstract_declarator )? | direct_abstract_declarator );", 51, 0, self.input) raise nvae if alt51 == 1: # C.g:346:4: pointer ( direct_abstract_declarator )? self.following.append(self.FOLLOW_pointer_in_abstract_declarator1065) self.pointer() self.following.pop() if self.failed: return # C.g:346:12: ( direct_abstract_declarator )? alt50 = 2 LA50_0 = self.input.LA(1) if (LA50_0 == 62) : LA50 = self.input.LA(2) if LA50 == 63: LA50_12 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 58: LA50_13 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 66: LA50_14 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 59: LA50_15 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 60: LA50_16 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == IDENTIFIER: LA50_17 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 62: LA50_18 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 64: LA50_19 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 29 or LA50 == 30 or LA50 == 31 or LA50 == 32 or LA50 == 33: LA50_20 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 34: LA50_21 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 35: LA50_22 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 36: LA50_23 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 37: LA50_24 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 38: LA50_25 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 39: LA50_26 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 40: LA50_27 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 41: LA50_28 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 42: LA50_29 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 45 or LA50 == 46: LA50_30 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 48: LA50_31 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 49 or LA50 == 50 or LA50 == 51 or LA50 == 52 or LA50 == 53 or LA50 == 54 or LA50 == 55 or LA50 == 56 or LA50 == 57 or LA50 == 61: LA50_32 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif (LA50_0 == 64) : LA50 = self.input.LA(2) if LA50 == 65: LA50_33 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 62: LA50_34 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == IDENTIFIER: LA50_35 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == HEX_LITERAL: LA50_36 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == OCTAL_LITERAL: LA50_37 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == DECIMAL_LITERAL: LA50_38 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == CHARACTER_LITERAL: LA50_39 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == STRING_LITERAL: LA50_40 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == FLOATING_POINT_LITERAL: LA50_41 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 72: LA50_42 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 73: LA50_43 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 66 or LA50 == 68 or LA50 == 69 or LA50 == 77 or LA50 == 78 or LA50 == 79: LA50_44 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 elif LA50 == 74: LA50_45 = self.input.LA(3) if (self.synpred91()) : alt50 = 1 if alt50 == 1: # C.g:0:0: direct_abstract_declarator self.following.append(self.FOLLOW_direct_abstract_declarator_in_abstract_declarator1067) self.direct_abstract_declarator() self.following.pop() if self.failed: return elif alt51 == 2: # C.g:347:4: direct_abstract_declarator self.following.append(self.FOLLOW_direct_abstract_declarator_in_abstract_declarator1073) self.direct_abstract_declarator() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 31, abstract_declarator_StartIndex) pass return # $ANTLR end abstract_declarator # $ANTLR start direct_abstract_declarator # C.g:350:1: direct_abstract_declarator : ( '(' abstract_declarator ')' | abstract_declarator_suffix ) ( abstract_declarator_suffix )* ; def direct_abstract_declarator(self, ): direct_abstract_declarator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 32): return # C.g:351:2: ( ( '(' abstract_declarator ')' | abstract_declarator_suffix ) ( abstract_declarator_suffix )* ) # C.g:351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix ) ( abstract_declarator_suffix )* # C.g:351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix ) alt52 = 2 LA52_0 = self.input.LA(1) if (LA52_0 == 62) : LA52 = self.input.LA(2) if LA52 == IDENTIFIER or LA52 == 29 or LA52 == 30 or LA52 == 31 or LA52 == 32 or LA52 == 33 or LA52 == 34 or LA52 == 35 or LA52 == 36 or LA52 == 37 or LA52 == 38 or LA52 == 39 or LA52 == 40 or LA52 == 41 or LA52 == 42 or LA52 == 45 or LA52 == 46 or LA52 == 48 or LA52 == 49 or LA52 == 50 or LA52 == 51 or LA52 == 52 or LA52 == 53 or LA52 == 54 or LA52 == 55 or LA52 == 56 or LA52 == 57 or LA52 == 58 or LA52 == 59 or LA52 == 60 or LA52 == 61 or LA52 == 63: alt52 = 2 elif LA52 == 66: LA52_18 = self.input.LA(3) if (self.synpred93()) : alt52 = 1 elif (True) : alt52 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix )", 52, 18, self.input) raise nvae elif LA52 == 62 or LA52 == 64: alt52 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix )", 52, 1, self.input) raise nvae elif (LA52_0 == 64) : alt52 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("351:4: ( '(' abstract_declarator ')' | abstract_declarator_suffix )", 52, 0, self.input) raise nvae if alt52 == 1: # C.g:351:6: '(' abstract_declarator ')' self.match(self.input, 62, self.FOLLOW_62_in_direct_abstract_declarator1086) if self.failed: return self.following.append(self.FOLLOW_abstract_declarator_in_direct_abstract_declarator1088) self.abstract_declarator() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_direct_abstract_declarator1090) if self.failed: return elif alt52 == 2: # C.g:351:36: abstract_declarator_suffix self.following.append(self.FOLLOW_abstract_declarator_suffix_in_direct_abstract_declarator1094) self.abstract_declarator_suffix() self.following.pop() if self.failed: return # C.g:351:65: ( abstract_declarator_suffix )* while True: #loop53 alt53 = 2 LA53_0 = self.input.LA(1) if (LA53_0 == 62) : LA53 = self.input.LA(2) if LA53 == 63: LA53_12 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 58: LA53_13 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 66: LA53_14 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 59: LA53_15 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 60: LA53_16 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == IDENTIFIER: LA53_17 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 29 or LA53 == 30 or LA53 == 31 or LA53 == 32 or LA53 == 33: LA53_19 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 34: LA53_20 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 35: LA53_21 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 36: LA53_22 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 37: LA53_23 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 38: LA53_24 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 39: LA53_25 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 40: LA53_26 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 41: LA53_27 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 42: LA53_28 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 45 or LA53 == 46: LA53_29 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 48: LA53_30 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 49 or LA53 == 50 or LA53 == 51 or LA53 == 52 or LA53 == 53 or LA53 == 54 or LA53 == 55 or LA53 == 56 or LA53 == 57 or LA53 == 61: LA53_31 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif (LA53_0 == 64) : LA53 = self.input.LA(2) if LA53 == 65: LA53_33 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 62: LA53_34 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == IDENTIFIER: LA53_35 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == HEX_LITERAL: LA53_36 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == OCTAL_LITERAL: LA53_37 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == DECIMAL_LITERAL: LA53_38 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == CHARACTER_LITERAL: LA53_39 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == STRING_LITERAL: LA53_40 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == FLOATING_POINT_LITERAL: LA53_41 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 72: LA53_42 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 73: LA53_43 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 66 or LA53 == 68 or LA53 == 69 or LA53 == 77 or LA53 == 78 or LA53 == 79: LA53_44 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 elif LA53 == 74: LA53_45 = self.input.LA(3) if (self.synpred94()) : alt53 = 1 if alt53 == 1: # C.g:0:0: abstract_declarator_suffix self.following.append(self.FOLLOW_abstract_declarator_suffix_in_direct_abstract_declarator1098) self.abstract_declarator_suffix() self.following.pop() if self.failed: return else: break #loop53 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 32, direct_abstract_declarator_StartIndex) pass return # $ANTLR end direct_abstract_declarator # $ANTLR start abstract_declarator_suffix # C.g:354:1: abstract_declarator_suffix : ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' ); def abstract_declarator_suffix(self, ): abstract_declarator_suffix_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 33): return # C.g:355:2: ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' ) alt54 = 4 LA54_0 = self.input.LA(1) if (LA54_0 == 64) : LA54_1 = self.input.LA(2) if (LA54_1 == 65) : alt54 = 1 elif ((IDENTIFIER <= LA54_1 <= FLOATING_POINT_LITERAL) or LA54_1 == 62 or LA54_1 == 66 or (68 <= LA54_1 <= 69) or (72 <= LA54_1 <= 74) or (77 <= LA54_1 <= 79)) : alt54 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("354:1: abstract_declarator_suffix : ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' );", 54, 1, self.input) raise nvae elif (LA54_0 == 62) : LA54_2 = self.input.LA(2) if (LA54_2 == 63) : alt54 = 3 elif (LA54_2 == IDENTIFIER or (29 <= LA54_2 <= 42) or (45 <= LA54_2 <= 46) or (48 <= LA54_2 <= 61) or LA54_2 == 66) : alt54 = 4 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("354:1: abstract_declarator_suffix : ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' );", 54, 2, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("354:1: abstract_declarator_suffix : ( '[' ']' | '[' constant_expression ']' | '(' ')' | '(' parameter_type_list ')' );", 54, 0, self.input) raise nvae if alt54 == 1: # C.g:355:4: '[' ']' self.match(self.input, 64, self.FOLLOW_64_in_abstract_declarator_suffix1110) if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_abstract_declarator_suffix1112) if self.failed: return elif alt54 == 2: # C.g:356:4: '[' constant_expression ']' self.match(self.input, 64, self.FOLLOW_64_in_abstract_declarator_suffix1117) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_abstract_declarator_suffix1119) self.constant_expression() self.following.pop() if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_abstract_declarator_suffix1121) if self.failed: return elif alt54 == 3: # C.g:357:4: '(' ')' self.match(self.input, 62, self.FOLLOW_62_in_abstract_declarator_suffix1126) if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_abstract_declarator_suffix1128) if self.failed: return elif alt54 == 4: # C.g:358:4: '(' parameter_type_list ')' self.match(self.input, 62, self.FOLLOW_62_in_abstract_declarator_suffix1133) if self.failed: return self.following.append(self.FOLLOW_parameter_type_list_in_abstract_declarator_suffix1135) self.parameter_type_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_abstract_declarator_suffix1137) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 33, abstract_declarator_suffix_StartIndex) pass return # $ANTLR end abstract_declarator_suffix # $ANTLR start initializer # C.g:361:1: initializer : ( assignment_expression | '{' initializer_list ( ',' )? '}' ); def initializer(self, ): initializer_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 34): return # C.g:363:2: ( assignment_expression | '{' initializer_list ( ',' )? '}' ) alt56 = 2 LA56_0 = self.input.LA(1) if ((IDENTIFIER <= LA56_0 <= FLOATING_POINT_LITERAL) or LA56_0 == 62 or LA56_0 == 66 or (68 <= LA56_0 <= 69) or (72 <= LA56_0 <= 74) or (77 <= LA56_0 <= 79)) : alt56 = 1 elif (LA56_0 == 43) : alt56 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("361:1: initializer : ( assignment_expression | '{' initializer_list ( ',' )? '}' );", 56, 0, self.input) raise nvae if alt56 == 1: # C.g:363:4: assignment_expression self.following.append(self.FOLLOW_assignment_expression_in_initializer1150) self.assignment_expression() self.following.pop() if self.failed: return elif alt56 == 2: # C.g:364:4: '{' initializer_list ( ',' )? '}' self.match(self.input, 43, self.FOLLOW_43_in_initializer1155) if self.failed: return self.following.append(self.FOLLOW_initializer_list_in_initializer1157) self.initializer_list() self.following.pop() if self.failed: return # C.g:364:25: ( ',' )? alt55 = 2 LA55_0 = self.input.LA(1) if (LA55_0 == 27) : alt55 = 1 if alt55 == 1: # C.g:0:0: ',' self.match(self.input, 27, self.FOLLOW_27_in_initializer1159) if self.failed: return self.match(self.input, 44, self.FOLLOW_44_in_initializer1162) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 34, initializer_StartIndex) pass return # $ANTLR end initializer # $ANTLR start initializer_list # C.g:367:1: initializer_list : initializer ( ',' initializer )* ; def initializer_list(self, ): initializer_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 35): return # C.g:368:2: ( initializer ( ',' initializer )* ) # C.g:368:4: initializer ( ',' initializer )* self.following.append(self.FOLLOW_initializer_in_initializer_list1173) self.initializer() self.following.pop() if self.failed: return # C.g:368:16: ( ',' initializer )* while True: #loop57 alt57 = 2 LA57_0 = self.input.LA(1) if (LA57_0 == 27) : LA57_1 = self.input.LA(2) if ((IDENTIFIER <= LA57_1 <= FLOATING_POINT_LITERAL) or LA57_1 == 43 or LA57_1 == 62 or LA57_1 == 66 or (68 <= LA57_1 <= 69) or (72 <= LA57_1 <= 74) or (77 <= LA57_1 <= 79)) : alt57 = 1 if alt57 == 1: # C.g:368:17: ',' initializer self.match(self.input, 27, self.FOLLOW_27_in_initializer_list1176) if self.failed: return self.following.append(self.FOLLOW_initializer_in_initializer_list1178) self.initializer() self.following.pop() if self.failed: return else: break #loop57 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 35, initializer_list_StartIndex) pass return # $ANTLR end initializer_list class argument_expression_list_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start argument_expression_list # C.g:373:1: argument_expression_list : assignment_expression ( 'OPTIONAL' )? ( ',' assignment_expression ( 'OPTIONAL' )? )* ; def argument_expression_list(self, ): retval = self.argument_expression_list_return() retval.start = self.input.LT(1) argument_expression_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 36): return retval # C.g:374:2: ( assignment_expression ( 'OPTIONAL' )? ( ',' assignment_expression ( 'OPTIONAL' )? )* ) # C.g:374:6: assignment_expression ( 'OPTIONAL' )? ( ',' assignment_expression ( 'OPTIONAL' )? )* self.following.append(self.FOLLOW_assignment_expression_in_argument_expression_list1196) self.assignment_expression() self.following.pop() if self.failed: return retval # C.g:374:28: ( 'OPTIONAL' )? alt58 = 2 LA58_0 = self.input.LA(1) if (LA58_0 == 53) : alt58 = 1 if alt58 == 1: # C.g:374:29: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_argument_expression_list1199) if self.failed: return retval # C.g:374:42: ( ',' assignment_expression ( 'OPTIONAL' )? )* while True: #loop60 alt60 = 2 LA60_0 = self.input.LA(1) if (LA60_0 == 27) : alt60 = 1 if alt60 == 1: # C.g:374:43: ',' assignment_expression ( 'OPTIONAL' )? self.match(self.input, 27, self.FOLLOW_27_in_argument_expression_list1204) if self.failed: return retval self.following.append(self.FOLLOW_assignment_expression_in_argument_expression_list1206) self.assignment_expression() self.following.pop() if self.failed: return retval # C.g:374:69: ( 'OPTIONAL' )? alt59 = 2 LA59_0 = self.input.LA(1) if (LA59_0 == 53) : alt59 = 1 if alt59 == 1: # C.g:374:70: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_argument_expression_list1209) if self.failed: return retval else: break #loop60 retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 36, argument_expression_list_StartIndex) pass return retval # $ANTLR end argument_expression_list # $ANTLR start additive_expression # C.g:377:1: additive_expression : ( multiplicative_expression ) ( '+' multiplicative_expression | '-' multiplicative_expression )* ; def additive_expression(self, ): additive_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 37): return # C.g:378:2: ( ( multiplicative_expression ) ( '+' multiplicative_expression | '-' multiplicative_expression )* ) # C.g:378:4: ( multiplicative_expression ) ( '+' multiplicative_expression | '-' multiplicative_expression )* # C.g:378:4: ( multiplicative_expression ) # C.g:378:5: multiplicative_expression self.following.append(self.FOLLOW_multiplicative_expression_in_additive_expression1225) self.multiplicative_expression() self.following.pop() if self.failed: return # C.g:378:32: ( '+' multiplicative_expression | '-' multiplicative_expression )* while True: #loop61 alt61 = 3 LA61_0 = self.input.LA(1) if (LA61_0 == 68) : alt61 = 1 elif (LA61_0 == 69) : alt61 = 2 if alt61 == 1: # C.g:378:33: '+' multiplicative_expression self.match(self.input, 68, self.FOLLOW_68_in_additive_expression1229) if self.failed: return self.following.append(self.FOLLOW_multiplicative_expression_in_additive_expression1231) self.multiplicative_expression() self.following.pop() if self.failed: return elif alt61 == 2: # C.g:378:65: '-' multiplicative_expression self.match(self.input, 69, self.FOLLOW_69_in_additive_expression1235) if self.failed: return self.following.append(self.FOLLOW_multiplicative_expression_in_additive_expression1237) self.multiplicative_expression() self.following.pop() if self.failed: return else: break #loop61 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 37, additive_expression_StartIndex) pass return # $ANTLR end additive_expression # $ANTLR start multiplicative_expression # C.g:381:1: multiplicative_expression : ( cast_expression ) ( '*' cast_expression | '/' cast_expression | '%' cast_expression )* ; def multiplicative_expression(self, ): multiplicative_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 38): return # C.g:382:2: ( ( cast_expression ) ( '*' cast_expression | '/' cast_expression | '%' cast_expression )* ) # C.g:382:4: ( cast_expression ) ( '*' cast_expression | '/' cast_expression | '%' cast_expression )* # C.g:382:4: ( cast_expression ) # C.g:382:5: cast_expression self.following.append(self.FOLLOW_cast_expression_in_multiplicative_expression1251) self.cast_expression() self.following.pop() if self.failed: return # C.g:382:22: ( '*' cast_expression | '/' cast_expression | '%' cast_expression )* while True: #loop62 alt62 = 4 LA62 = self.input.LA(1) if LA62 == 66: alt62 = 1 elif LA62 == 70: alt62 = 2 elif LA62 == 71: alt62 = 3 if alt62 == 1: # C.g:382:23: '*' cast_expression self.match(self.input, 66, self.FOLLOW_66_in_multiplicative_expression1255) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_multiplicative_expression1257) self.cast_expression() self.following.pop() if self.failed: return elif alt62 == 2: # C.g:382:45: '/' cast_expression self.match(self.input, 70, self.FOLLOW_70_in_multiplicative_expression1261) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_multiplicative_expression1263) self.cast_expression() self.following.pop() if self.failed: return elif alt62 == 3: # C.g:382:67: '%' cast_expression self.match(self.input, 71, self.FOLLOW_71_in_multiplicative_expression1267) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_multiplicative_expression1269) self.cast_expression() self.following.pop() if self.failed: return else: break #loop62 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 38, multiplicative_expression_StartIndex) pass return # $ANTLR end multiplicative_expression # $ANTLR start cast_expression # C.g:385:1: cast_expression : ( '(' type_name ')' cast_expression | unary_expression ); def cast_expression(self, ): cast_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 39): return # C.g:386:2: ( '(' type_name ')' cast_expression | unary_expression ) alt63 = 2 LA63_0 = self.input.LA(1) if (LA63_0 == 62) : LA63 = self.input.LA(2) if LA63 == 34 or LA63 == 35 or LA63 == 36 or LA63 == 37 or LA63 == 38 or LA63 == 39 or LA63 == 40 or LA63 == 41 or LA63 == 42 or LA63 == 45 or LA63 == 46 or LA63 == 48 or LA63 == 49 or LA63 == 50 or LA63 == 51 or LA63 == 52 or LA63 == 53 or LA63 == 54 or LA63 == 55 or LA63 == 56 or LA63 == 57 or LA63 == 58 or LA63 == 59 or LA63 == 60 or LA63 == 61: alt63 = 1 elif LA63 == IDENTIFIER: LA63_25 = self.input.LA(3) if (self.synpred109()) : alt63 = 1 elif (True) : alt63 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("385:1: cast_expression : ( '(' type_name ')' cast_expression | unary_expression );", 63, 25, self.input) raise nvae elif LA63 == HEX_LITERAL or LA63 == OCTAL_LITERAL or LA63 == DECIMAL_LITERAL or LA63 == CHARACTER_LITERAL or LA63 == STRING_LITERAL or LA63 == FLOATING_POINT_LITERAL or LA63 == 62 or LA63 == 66 or LA63 == 68 or LA63 == 69 or LA63 == 72 or LA63 == 73 or LA63 == 74 or LA63 == 77 or LA63 == 78 or LA63 == 79: alt63 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("385:1: cast_expression : ( '(' type_name ')' cast_expression | unary_expression );", 63, 1, self.input) raise nvae elif ((IDENTIFIER <= LA63_0 <= FLOATING_POINT_LITERAL) or LA63_0 == 66 or (68 <= LA63_0 <= 69) or (72 <= LA63_0 <= 74) or (77 <= LA63_0 <= 79)) : alt63 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("385:1: cast_expression : ( '(' type_name ')' cast_expression | unary_expression );", 63, 0, self.input) raise nvae if alt63 == 1: # C.g:386:4: '(' type_name ')' cast_expression self.match(self.input, 62, self.FOLLOW_62_in_cast_expression1282) if self.failed: return self.following.append(self.FOLLOW_type_name_in_cast_expression1284) self.type_name() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_cast_expression1286) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_cast_expression1288) self.cast_expression() self.following.pop() if self.failed: return elif alt63 == 2: # C.g:387:4: unary_expression self.following.append(self.FOLLOW_unary_expression_in_cast_expression1293) self.unary_expression() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 39, cast_expression_StartIndex) pass return # $ANTLR end cast_expression # $ANTLR start unary_expression # C.g:390:1: unary_expression : ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' ); def unary_expression(self, ): unary_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 40): return # C.g:391:2: ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' ) alt64 = 6 LA64 = self.input.LA(1) if LA64 == IDENTIFIER or LA64 == HEX_LITERAL or LA64 == OCTAL_LITERAL or LA64 == DECIMAL_LITERAL or LA64 == CHARACTER_LITERAL or LA64 == STRING_LITERAL or LA64 == FLOATING_POINT_LITERAL or LA64 == 62: alt64 = 1 elif LA64 == 72: alt64 = 2 elif LA64 == 73: alt64 = 3 elif LA64 == 66 or LA64 == 68 or LA64 == 69 or LA64 == 77 or LA64 == 78 or LA64 == 79: alt64 = 4 elif LA64 == 74: LA64_12 = self.input.LA(2) if (LA64_12 == 62) : LA64_13 = self.input.LA(3) if (self.synpred114()) : alt64 = 5 elif (True) : alt64 = 6 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("390:1: unary_expression : ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' );", 64, 13, self.input) raise nvae elif ((IDENTIFIER <= LA64_12 <= FLOATING_POINT_LITERAL) or LA64_12 == 66 or (68 <= LA64_12 <= 69) or (72 <= LA64_12 <= 74) or (77 <= LA64_12 <= 79)) : alt64 = 5 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("390:1: unary_expression : ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' );", 64, 12, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("390:1: unary_expression : ( postfix_expression | '++' unary_expression | '--' unary_expression | unary_operator cast_expression | 'sizeof' unary_expression | 'sizeof' '(' type_name ')' );", 64, 0, self.input) raise nvae if alt64 == 1: # C.g:391:4: postfix_expression self.following.append(self.FOLLOW_postfix_expression_in_unary_expression1304) self.postfix_expression() self.following.pop() if self.failed: return elif alt64 == 2: # C.g:392:4: '++' unary_expression self.match(self.input, 72, self.FOLLOW_72_in_unary_expression1309) if self.failed: return self.following.append(self.FOLLOW_unary_expression_in_unary_expression1311) self.unary_expression() self.following.pop() if self.failed: return elif alt64 == 3: # C.g:393:4: '--' unary_expression self.match(self.input, 73, self.FOLLOW_73_in_unary_expression1316) if self.failed: return self.following.append(self.FOLLOW_unary_expression_in_unary_expression1318) self.unary_expression() self.following.pop() if self.failed: return elif alt64 == 4: # C.g:394:4: unary_operator cast_expression self.following.append(self.FOLLOW_unary_operator_in_unary_expression1323) self.unary_operator() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_unary_expression1325) self.cast_expression() self.following.pop() if self.failed: return elif alt64 == 5: # C.g:395:4: 'sizeof' unary_expression self.match(self.input, 74, self.FOLLOW_74_in_unary_expression1330) if self.failed: return self.following.append(self.FOLLOW_unary_expression_in_unary_expression1332) self.unary_expression() self.following.pop() if self.failed: return elif alt64 == 6: # C.g:396:4: 'sizeof' '(' type_name ')' self.match(self.input, 74, self.FOLLOW_74_in_unary_expression1337) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_unary_expression1339) if self.failed: return self.following.append(self.FOLLOW_type_name_in_unary_expression1341) self.type_name() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_unary_expression1343) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 40, unary_expression_StartIndex) pass return # $ANTLR end unary_expression # $ANTLR start postfix_expression # C.g:399:1: postfix_expression : p= primary_expression ( '[' expression ']' | '(' a= ')' | '(' c= argument_expression_list b= ')' | '(' macro_parameter_list ')' | '.' x= IDENTIFIER | '*' y= IDENTIFIER | '->' z= IDENTIFIER | '++' | '--' )* ; def postfix_expression(self, ): self.postfix_expression_stack.append(postfix_expression_scope()) postfix_expression_StartIndex = self.input.index() a = None b = None x = None y = None z = None p = None c = None self.postfix_expression_stack[-1].FuncCallText = '' try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 41): return # C.g:406:2: (p= primary_expression ( '[' expression ']' | '(' a= ')' | '(' c= argument_expression_list b= ')' | '(' macro_parameter_list ')' | '.' x= IDENTIFIER | '*' y= IDENTIFIER | '->' z= IDENTIFIER | '++' | '--' )* ) # C.g:406:6: p= primary_expression ( '[' expression ']' | '(' a= ')' | '(' c= argument_expression_list b= ')' | '(' macro_parameter_list ')' | '.' x= IDENTIFIER | '*' y= IDENTIFIER | '->' z= IDENTIFIER | '++' | '--' )* self.following.append(self.FOLLOW_primary_expression_in_postfix_expression1367) p = self.primary_expression() self.following.pop() if self.failed: return if self.backtracking == 0: self.postfix_expression_stack[-1].FuncCallText += self.input.toString(p.start, p.stop) # C.g:407:9: ( '[' expression ']' | '(' a= ')' | '(' c= argument_expression_list b= ')' | '(' macro_parameter_list ')' | '.' x= IDENTIFIER | '*' y= IDENTIFIER | '->' z= IDENTIFIER | '++' | '--' )* while True: #loop65 alt65 = 10 LA65 = self.input.LA(1) if LA65 == 66: LA65_1 = self.input.LA(2) if (LA65_1 == IDENTIFIER) : LA65_30 = self.input.LA(3) if (self.synpred120()) : alt65 = 6 elif LA65 == 64: alt65 = 1 elif LA65 == 62: LA65 = self.input.LA(2) if LA65 == 63: alt65 = 2 elif LA65 == 29 or LA65 == 30 or LA65 == 31 or LA65 == 32 or LA65 == 33 or LA65 == 34 or LA65 == 35 or LA65 == 36 or LA65 == 37 or LA65 == 38 or LA65 == 39 or LA65 == 40 or LA65 == 41 or LA65 == 42 or LA65 == 45 or LA65 == 46 or LA65 == 48 or LA65 == 49 or LA65 == 50 or LA65 == 51 or LA65 == 52 or LA65 == 53 or LA65 == 54 or LA65 == 55 or LA65 == 56 or LA65 == 57 or LA65 == 58 or LA65 == 59 or LA65 == 60 or LA65 == 61: alt65 = 4 elif LA65 == IDENTIFIER: LA65_55 = self.input.LA(3) if (self.synpred117()) : alt65 = 3 elif (self.synpred118()) : alt65 = 4 elif LA65 == 66: LA65_57 = self.input.LA(3) if (self.synpred117()) : alt65 = 3 elif (self.synpred118()) : alt65 = 4 elif LA65 == HEX_LITERAL or LA65 == OCTAL_LITERAL or LA65 == DECIMAL_LITERAL or LA65 == CHARACTER_LITERAL or LA65 == STRING_LITERAL or LA65 == FLOATING_POINT_LITERAL or LA65 == 62 or LA65 == 68 or LA65 == 69 or LA65 == 72 or LA65 == 73 or LA65 == 74 or LA65 == 77 or LA65 == 78 or LA65 == 79: alt65 = 3 elif LA65 == 75: alt65 = 5 elif LA65 == 76: alt65 = 7 elif LA65 == 72: alt65 = 8 elif LA65 == 73: alt65 = 9 if alt65 == 1: # C.g:407:13: '[' expression ']' self.match(self.input, 64, self.FOLLOW_64_in_postfix_expression1383) if self.failed: return self.following.append(self.FOLLOW_expression_in_postfix_expression1385) self.expression() self.following.pop() if self.failed: return self.match(self.input, 65, self.FOLLOW_65_in_postfix_expression1387) if self.failed: return elif alt65 == 2: # C.g:408:13: '(' a= ')' self.match(self.input, 62, self.FOLLOW_62_in_postfix_expression1401) if self.failed: return a = self.input.LT(1) self.match(self.input, 63, self.FOLLOW_63_in_postfix_expression1405) if self.failed: return if self.backtracking == 0: self.StoreFunctionCalling(p.start.line, p.start.charPositionInLine, a.line, a.charPositionInLine, self.postfix_expression_stack[-1].FuncCallText, '') elif alt65 == 3: # C.g:409:13: '(' c= argument_expression_list b= ')' self.match(self.input, 62, self.FOLLOW_62_in_postfix_expression1420) if self.failed: return self.following.append(self.FOLLOW_argument_expression_list_in_postfix_expression1424) c = self.argument_expression_list() self.following.pop() if self.failed: return b = self.input.LT(1) self.match(self.input, 63, self.FOLLOW_63_in_postfix_expression1428) if self.failed: return if self.backtracking == 0: self.StoreFunctionCalling(p.start.line, p.start.charPositionInLine, b.line, b.charPositionInLine, self.postfix_expression_stack[-1].FuncCallText, self.input.toString(c.start, c.stop)) elif alt65 == 4: # C.g:410:13: '(' macro_parameter_list ')' self.match(self.input, 62, self.FOLLOW_62_in_postfix_expression1444) if self.failed: return self.following.append(self.FOLLOW_macro_parameter_list_in_postfix_expression1446) self.macro_parameter_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_postfix_expression1448) if self.failed: return elif alt65 == 5: # C.g:411:13: '.' x= IDENTIFIER self.match(self.input, 75, self.FOLLOW_75_in_postfix_expression1462) if self.failed: return x = self.input.LT(1) self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_postfix_expression1466) if self.failed: return if self.backtracking == 0: self.postfix_expression_stack[-1].FuncCallText += '.' + x.text elif alt65 == 6: # C.g:412:13: '*' y= IDENTIFIER self.match(self.input, 66, self.FOLLOW_66_in_postfix_expression1482) if self.failed: return y = self.input.LT(1) self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_postfix_expression1486) if self.failed: return if self.backtracking == 0: self.postfix_expression_stack[-1].FuncCallText = y.text elif alt65 == 7: # C.g:413:13: '->' z= IDENTIFIER self.match(self.input, 76, self.FOLLOW_76_in_postfix_expression1502) if self.failed: return z = self.input.LT(1) self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_postfix_expression1506) if self.failed: return if self.backtracking == 0: self.postfix_expression_stack[-1].FuncCallText += '->' + z.text elif alt65 == 8: # C.g:414:13: '++' self.match(self.input, 72, self.FOLLOW_72_in_postfix_expression1522) if self.failed: return elif alt65 == 9: # C.g:415:13: '--' self.match(self.input, 73, self.FOLLOW_73_in_postfix_expression1536) if self.failed: return else: break #loop65 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 41, postfix_expression_StartIndex) self.postfix_expression_stack.pop() pass return # $ANTLR end postfix_expression # $ANTLR start macro_parameter_list # C.g:419:1: macro_parameter_list : parameter_declaration ( ',' parameter_declaration )* ; def macro_parameter_list(self, ): macro_parameter_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 42): return # C.g:420:2: ( parameter_declaration ( ',' parameter_declaration )* ) # C.g:420:4: parameter_declaration ( ',' parameter_declaration )* self.following.append(self.FOLLOW_parameter_declaration_in_macro_parameter_list1559) self.parameter_declaration() self.following.pop() if self.failed: return # C.g:420:26: ( ',' parameter_declaration )* while True: #loop66 alt66 = 2 LA66_0 = self.input.LA(1) if (LA66_0 == 27) : alt66 = 1 if alt66 == 1: # C.g:420:27: ',' parameter_declaration self.match(self.input, 27, self.FOLLOW_27_in_macro_parameter_list1562) if self.failed: return self.following.append(self.FOLLOW_parameter_declaration_in_macro_parameter_list1564) self.parameter_declaration() self.following.pop() if self.failed: return else: break #loop66 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 42, macro_parameter_list_StartIndex) pass return # $ANTLR end macro_parameter_list # $ANTLR start unary_operator # C.g:423:1: unary_operator : ( '&' | '*' | '+' | '-' | '~' | '!' ); def unary_operator(self, ): unary_operator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 43): return # C.g:424:2: ( '&' | '*' | '+' | '-' | '~' | '!' ) # C.g: if self.input.LA(1) == 66 or (68 <= self.input.LA(1) <= 69) or (77 <= self.input.LA(1) <= 79): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_unary_operator0 ) raise mse except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 43, unary_operator_StartIndex) pass return # $ANTLR end unary_operator class primary_expression_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start primary_expression # C.g:432:1: primary_expression : ( IDENTIFIER | constant | '(' expression ')' ); def primary_expression(self, ): retval = self.primary_expression_return() retval.start = self.input.LT(1) primary_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 44): return retval # C.g:433:2: ( IDENTIFIER | constant | '(' expression ')' ) alt67 = 3 LA67 = self.input.LA(1) if LA67 == IDENTIFIER: LA67_1 = self.input.LA(2) if (LA67_1 == EOF or LA67_1 == 25 or (27 <= LA67_1 <= 28) or LA67_1 == 44 or LA67_1 == 47 or LA67_1 == 53 or (62 <= LA67_1 <= 66) or (68 <= LA67_1 <= 73) or (75 <= LA67_1 <= 77) or (80 <= LA67_1 <= 102)) : alt67 = 1 elif (LA67_1 == IDENTIFIER or LA67_1 == STRING_LITERAL) : alt67 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("432:1: primary_expression : ( IDENTIFIER | constant | '(' expression ')' );", 67, 1, self.input) raise nvae elif LA67 == HEX_LITERAL or LA67 == OCTAL_LITERAL or LA67 == DECIMAL_LITERAL or LA67 == CHARACTER_LITERAL or LA67 == STRING_LITERAL or LA67 == FLOATING_POINT_LITERAL: alt67 = 2 elif LA67 == 62: alt67 = 3 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("432:1: primary_expression : ( IDENTIFIER | constant | '(' expression ')' );", 67, 0, self.input) raise nvae if alt67 == 1: # C.g:433:4: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_primary_expression1613) if self.failed: return retval elif alt67 == 2: # C.g:434:4: constant self.following.append(self.FOLLOW_constant_in_primary_expression1618) self.constant() self.following.pop() if self.failed: return retval elif alt67 == 3: # C.g:435:4: '(' expression ')' self.match(self.input, 62, self.FOLLOW_62_in_primary_expression1623) if self.failed: return retval self.following.append(self.FOLLOW_expression_in_primary_expression1625) self.expression() self.following.pop() if self.failed: return retval self.match(self.input, 63, self.FOLLOW_63_in_primary_expression1627) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 44, primary_expression_StartIndex) pass return retval # $ANTLR end primary_expression # $ANTLR start constant # C.g:438:1: constant : ( HEX_LITERAL | OCTAL_LITERAL | DECIMAL_LITERAL | CHARACTER_LITERAL | ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ ( IDENTIFIER )* | FLOATING_POINT_LITERAL ); def constant(self, ): constant_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 45): return # C.g:439:5: ( HEX_LITERAL | OCTAL_LITERAL | DECIMAL_LITERAL | CHARACTER_LITERAL | ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ ( IDENTIFIER )* | FLOATING_POINT_LITERAL ) alt72 = 6 LA72 = self.input.LA(1) if LA72 == HEX_LITERAL: alt72 = 1 elif LA72 == OCTAL_LITERAL: alt72 = 2 elif LA72 == DECIMAL_LITERAL: alt72 = 3 elif LA72 == CHARACTER_LITERAL: alt72 = 4 elif LA72 == IDENTIFIER or LA72 == STRING_LITERAL: alt72 = 5 elif LA72 == FLOATING_POINT_LITERAL: alt72 = 6 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("438:1: constant : ( HEX_LITERAL | OCTAL_LITERAL | DECIMAL_LITERAL | CHARACTER_LITERAL | ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ ( IDENTIFIER )* | FLOATING_POINT_LITERAL );", 72, 0, self.input) raise nvae if alt72 == 1: # C.g:439:9: HEX_LITERAL self.match(self.input, HEX_LITERAL, self.FOLLOW_HEX_LITERAL_in_constant1643) if self.failed: return elif alt72 == 2: # C.g:440:9: OCTAL_LITERAL self.match(self.input, OCTAL_LITERAL, self.FOLLOW_OCTAL_LITERAL_in_constant1653) if self.failed: return elif alt72 == 3: # C.g:441:9: DECIMAL_LITERAL self.match(self.input, DECIMAL_LITERAL, self.FOLLOW_DECIMAL_LITERAL_in_constant1663) if self.failed: return elif alt72 == 4: # C.g:442:7: CHARACTER_LITERAL self.match(self.input, CHARACTER_LITERAL, self.FOLLOW_CHARACTER_LITERAL_in_constant1671) if self.failed: return elif alt72 == 5: # C.g:443:7: ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ ( IDENTIFIER )* # C.g:443:7: ( ( IDENTIFIER )* ( STRING_LITERAL )+ )+ cnt70 = 0 while True: #loop70 alt70 = 2 LA70_0 = self.input.LA(1) if (LA70_0 == IDENTIFIER) : LA70_1 = self.input.LA(2) if (LA70_1 == STRING_LITERAL) : alt70 = 1 elif (LA70_1 == IDENTIFIER) : LA70_33 = self.input.LA(3) if (self.synpred138()) : alt70 = 1 elif (LA70_0 == STRING_LITERAL) : alt70 = 1 if alt70 == 1: # C.g:443:8: ( IDENTIFIER )* ( STRING_LITERAL )+ # C.g:443:8: ( IDENTIFIER )* while True: #loop68 alt68 = 2 LA68_0 = self.input.LA(1) if (LA68_0 == IDENTIFIER) : alt68 = 1 if alt68 == 1: # C.g:0:0: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_constant1680) if self.failed: return else: break #loop68 # C.g:443:20: ( STRING_LITERAL )+ cnt69 = 0 while True: #loop69 alt69 = 2 LA69_0 = self.input.LA(1) if (LA69_0 == STRING_LITERAL) : LA69_31 = self.input.LA(2) if (self.synpred137()) : alt69 = 1 if alt69 == 1: # C.g:0:0: STRING_LITERAL self.match(self.input, STRING_LITERAL, self.FOLLOW_STRING_LITERAL_in_constant1683) if self.failed: return else: if cnt69 >= 1: break #loop69 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(69, self.input) raise eee cnt69 += 1 else: if cnt70 >= 1: break #loop70 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(70, self.input) raise eee cnt70 += 1 # C.g:443:38: ( IDENTIFIER )* while True: #loop71 alt71 = 2 LA71_0 = self.input.LA(1) if (LA71_0 == IDENTIFIER) : alt71 = 1 if alt71 == 1: # C.g:0:0: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_constant1688) if self.failed: return else: break #loop71 elif alt72 == 6: # C.g:444:9: FLOATING_POINT_LITERAL self.match(self.input, FLOATING_POINT_LITERAL, self.FOLLOW_FLOATING_POINT_LITERAL_in_constant1699) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 45, constant_StartIndex) pass return # $ANTLR end constant class expression_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start expression # C.g:449:1: expression : assignment_expression ( ',' assignment_expression )* ; def expression(self, ): retval = self.expression_return() retval.start = self.input.LT(1) expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 46): return retval # C.g:450:2: ( assignment_expression ( ',' assignment_expression )* ) # C.g:450:4: assignment_expression ( ',' assignment_expression )* self.following.append(self.FOLLOW_assignment_expression_in_expression1715) self.assignment_expression() self.following.pop() if self.failed: return retval # C.g:450:26: ( ',' assignment_expression )* while True: #loop73 alt73 = 2 LA73_0 = self.input.LA(1) if (LA73_0 == 27) : alt73 = 1 if alt73 == 1: # C.g:450:27: ',' assignment_expression self.match(self.input, 27, self.FOLLOW_27_in_expression1718) if self.failed: return retval self.following.append(self.FOLLOW_assignment_expression_in_expression1720) self.assignment_expression() self.following.pop() if self.failed: return retval else: break #loop73 retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 46, expression_StartIndex) pass return retval # $ANTLR end expression # $ANTLR start constant_expression # C.g:453:1: constant_expression : conditional_expression ; def constant_expression(self, ): constant_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 47): return # C.g:454:2: ( conditional_expression ) # C.g:454:4: conditional_expression self.following.append(self.FOLLOW_conditional_expression_in_constant_expression1733) self.conditional_expression() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 47, constant_expression_StartIndex) pass return # $ANTLR end constant_expression # $ANTLR start assignment_expression # C.g:457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression ); def assignment_expression(self, ): assignment_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 48): return # C.g:458:2: ( lvalue assignment_operator assignment_expression | conditional_expression ) alt74 = 2 LA74 = self.input.LA(1) if LA74 == IDENTIFIER: LA74 = self.input.LA(2) if LA74 == 64: LA74_13 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 13, self.input) raise nvae elif LA74 == 62: LA74_14 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 14, self.input) raise nvae elif LA74 == 75: LA74_15 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 15, self.input) raise nvae elif LA74 == 66: LA74_16 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 16, self.input) raise nvae elif LA74 == 76: LA74_17 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 17, self.input) raise nvae elif LA74 == 72: LA74_18 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 18, self.input) raise nvae elif LA74 == 73: LA74_19 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 19, self.input) raise nvae elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 elif LA74 == STRING_LITERAL: LA74_21 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 21, self.input) raise nvae elif LA74 == IDENTIFIER: LA74_22 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 22, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 1, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_44 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 44, self.input) raise nvae elif LA74 == 62: LA74_45 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 45, self.input) raise nvae elif LA74 == 75: LA74_46 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 46, self.input) raise nvae elif LA74 == 66: LA74_47 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 47, self.input) raise nvae elif LA74 == 76: LA74_48 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 48, self.input) raise nvae elif LA74 == 72: LA74_49 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 49, self.input) raise nvae elif LA74 == 73: LA74_50 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 50, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 2, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_73 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 73, self.input) raise nvae elif LA74 == 62: LA74_74 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 74, self.input) raise nvae elif LA74 == 75: LA74_75 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 75, self.input) raise nvae elif LA74 == 66: LA74_76 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 76, self.input) raise nvae elif LA74 == 76: LA74_77 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 77, self.input) raise nvae elif LA74 == 72: LA74_78 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 78, self.input) raise nvae elif LA74 == 73: LA74_79 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 79, self.input) raise nvae elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 3, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_102 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 102, self.input) raise nvae elif LA74 == 62: LA74_103 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 103, self.input) raise nvae elif LA74 == 75: LA74_104 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 104, self.input) raise nvae elif LA74 == 66: LA74_105 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 105, self.input) raise nvae elif LA74 == 76: LA74_106 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 106, self.input) raise nvae elif LA74 == 72: LA74_107 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 107, self.input) raise nvae elif LA74 == 73: LA74_108 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 108, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 4, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_131 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 131, self.input) raise nvae elif LA74 == 62: LA74_132 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 132, self.input) raise nvae elif LA74 == 75: LA74_133 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 133, self.input) raise nvae elif LA74 == 66: LA74_134 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 134, self.input) raise nvae elif LA74 == 76: LA74_135 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 135, self.input) raise nvae elif LA74 == 72: LA74_136 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 136, self.input) raise nvae elif LA74 == 73: LA74_137 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 137, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 5, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74 = self.input.LA(2) if LA74 == IDENTIFIER: LA74_160 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 160, self.input) raise nvae elif LA74 == 64: LA74_161 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 161, self.input) raise nvae elif LA74 == 62: LA74_162 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 162, self.input) raise nvae elif LA74 == 75: LA74_163 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 163, self.input) raise nvae elif LA74 == 66: LA74_164 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 164, self.input) raise nvae elif LA74 == 76: LA74_165 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 165, self.input) raise nvae elif LA74 == 72: LA74_166 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 166, self.input) raise nvae elif LA74 == 73: LA74_167 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 167, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == STRING_LITERAL: LA74_189 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 189, self.input) raise nvae elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 6, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74 = self.input.LA(2) if LA74 == 64: LA74_191 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 191, self.input) raise nvae elif LA74 == 62: LA74_192 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 192, self.input) raise nvae elif LA74 == 75: LA74_193 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 193, self.input) raise nvae elif LA74 == 66: LA74_194 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 194, self.input) raise nvae elif LA74 == 76: LA74_195 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 195, self.input) raise nvae elif LA74 == 72: LA74_196 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 196, self.input) raise nvae elif LA74 == 73: LA74_197 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 197, self.input) raise nvae elif LA74 == EOF or LA74 == 25 or LA74 == 27 or LA74 == 44 or LA74 == 47 or LA74 == 53 or LA74 == 63 or LA74 == 65 or LA74 == 68 or LA74 == 69 or LA74 == 70 or LA74 == 71 or LA74 == 77 or LA74 == 90 or LA74 == 91 or LA74 == 92 or LA74 == 93 or LA74 == 94 or LA74 == 95 or LA74 == 96 or LA74 == 97 or LA74 == 98 or LA74 == 99 or LA74 == 100 or LA74 == 101 or LA74 == 102: alt74 = 2 elif LA74 == 28 or LA74 == 80 or LA74 == 81 or LA74 == 82 or LA74 == 83 or LA74 == 84 or LA74 == 85 or LA74 == 86 or LA74 == 87 or LA74 == 88 or LA74 == 89: alt74 = 1 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 7, self.input) raise nvae elif LA74 == 62: LA74 = self.input.LA(2) if LA74 == IDENTIFIER: LA74_220 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 220, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_221 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 221, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_222 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 222, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_223 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 223, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_224 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 224, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_225 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 225, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_226 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 226, self.input) raise nvae elif LA74 == 62: LA74_227 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 227, self.input) raise nvae elif LA74 == 72: LA74_228 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 228, self.input) raise nvae elif LA74 == 73: LA74_229 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 229, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_230 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 230, self.input) raise nvae elif LA74 == 74: LA74_231 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 231, self.input) raise nvae elif LA74 == 34 or LA74 == 35 or LA74 == 36 or LA74 == 37 or LA74 == 38 or LA74 == 39 or LA74 == 40 or LA74 == 41 or LA74 == 42 or LA74 == 45 or LA74 == 46 or LA74 == 48 or LA74 == 49 or LA74 == 50 or LA74 == 51 or LA74 == 52 or LA74 == 53 or LA74 == 54 or LA74 == 55 or LA74 == 56 or LA74 == 57 or LA74 == 58 or LA74 == 59 or LA74 == 60 or LA74 == 61: alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 8, self.input) raise nvae elif LA74 == 72: LA74 = self.input.LA(2) if LA74 == IDENTIFIER: LA74_244 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 244, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_245 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 245, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_246 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 246, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_247 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 247, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_248 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 248, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_249 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 249, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_250 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 250, self.input) raise nvae elif LA74 == 62: LA74_251 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 251, self.input) raise nvae elif LA74 == 72: LA74_252 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 252, self.input) raise nvae elif LA74 == 73: LA74_253 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 253, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_254 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 254, self.input) raise nvae elif LA74 == 74: LA74_255 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 255, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 9, self.input) raise nvae elif LA74 == 73: LA74 = self.input.LA(2) if LA74 == IDENTIFIER: LA74_256 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 256, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_257 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 257, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_258 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 258, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_259 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 259, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_260 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 260, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_261 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 261, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_262 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 262, self.input) raise nvae elif LA74 == 62: LA74_263 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 263, self.input) raise nvae elif LA74 == 72: LA74_264 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 264, self.input) raise nvae elif LA74 == 73: LA74_265 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 265, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_266 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 266, self.input) raise nvae elif LA74 == 74: LA74_267 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 267, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 10, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74 = self.input.LA(2) if LA74 == 62: LA74_268 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 268, self.input) raise nvae elif LA74 == IDENTIFIER: LA74_269 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 269, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_270 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 270, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_271 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 271, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_272 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 272, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_273 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 273, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_274 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 274, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_275 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 275, self.input) raise nvae elif LA74 == 72: LA74_276 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 276, self.input) raise nvae elif LA74 == 73: LA74_277 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 277, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_278 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 278, self.input) raise nvae elif LA74 == 74: LA74_279 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 279, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 11, self.input) raise nvae elif LA74 == 74: LA74 = self.input.LA(2) if LA74 == 62: LA74_280 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 280, self.input) raise nvae elif LA74 == IDENTIFIER: LA74_281 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 281, self.input) raise nvae elif LA74 == HEX_LITERAL: LA74_282 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 282, self.input) raise nvae elif LA74 == OCTAL_LITERAL: LA74_283 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 283, self.input) raise nvae elif LA74 == DECIMAL_LITERAL: LA74_284 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 284, self.input) raise nvae elif LA74 == CHARACTER_LITERAL: LA74_285 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 285, self.input) raise nvae elif LA74 == STRING_LITERAL: LA74_286 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 286, self.input) raise nvae elif LA74 == FLOATING_POINT_LITERAL: LA74_287 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 287, self.input) raise nvae elif LA74 == 72: LA74_288 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 288, self.input) raise nvae elif LA74 == 73: LA74_289 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 289, self.input) raise nvae elif LA74 == 66 or LA74 == 68 or LA74 == 69 or LA74 == 77 or LA74 == 78 or LA74 == 79: LA74_290 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 290, self.input) raise nvae elif LA74 == 74: LA74_291 = self.input.LA(3) if (self.synpred142()) : alt74 = 1 elif (True) : alt74 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 291, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 12, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("457:1: assignment_expression : ( lvalue assignment_operator assignment_expression | conditional_expression );", 74, 0, self.input) raise nvae if alt74 == 1: # C.g:458:4: lvalue assignment_operator assignment_expression self.following.append(self.FOLLOW_lvalue_in_assignment_expression1744) self.lvalue() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_assignment_operator_in_assignment_expression1746) self.assignment_operator() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_assignment_expression_in_assignment_expression1748) self.assignment_expression() self.following.pop() if self.failed: return elif alt74 == 2: # C.g:459:4: conditional_expression self.following.append(self.FOLLOW_conditional_expression_in_assignment_expression1753) self.conditional_expression() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 48, assignment_expression_StartIndex) pass return # $ANTLR end assignment_expression # $ANTLR start lvalue # C.g:462:1: lvalue : unary_expression ; def lvalue(self, ): lvalue_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 49): return # C.g:463:2: ( unary_expression ) # C.g:463:4: unary_expression self.following.append(self.FOLLOW_unary_expression_in_lvalue1765) self.unary_expression() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 49, lvalue_StartIndex) pass return # $ANTLR end lvalue # $ANTLR start assignment_operator # C.g:466:1: assignment_operator : ( '=' | '*=' | '/=' | '%=' | '+=' | '-=' | '<<=' | '>>=' | '&=' | '^=' | '|=' ); def assignment_operator(self, ): assignment_operator_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 50): return # C.g:467:2: ( '=' | '*=' | '/=' | '%=' | '+=' | '-=' | '<<=' | '>>=' | '&=' | '^=' | '|=' ) # C.g: if self.input.LA(1) == 28 or (80 <= self.input.LA(1) <= 89): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_assignment_operator0 ) raise mse except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 50, assignment_operator_StartIndex) pass return # $ANTLR end assignment_operator # $ANTLR start conditional_expression # C.g:480:1: conditional_expression : e= logical_or_expression ( '?' expression ':' conditional_expression )? ; def conditional_expression(self, ): conditional_expression_StartIndex = self.input.index() e = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 51): return # C.g:481:2: (e= logical_or_expression ( '?' expression ':' conditional_expression )? ) # C.g:481:4: e= logical_or_expression ( '?' expression ':' conditional_expression )? self.following.append(self.FOLLOW_logical_or_expression_in_conditional_expression1839) e = self.logical_or_expression() self.following.pop() if self.failed: return # C.g:481:28: ( '?' expression ':' conditional_expression )? alt75 = 2 LA75_0 = self.input.LA(1) if (LA75_0 == 90) : alt75 = 1 if alt75 == 1: # C.g:481:29: '?' expression ':' conditional_expression self.match(self.input, 90, self.FOLLOW_90_in_conditional_expression1842) if self.failed: return self.following.append(self.FOLLOW_expression_in_conditional_expression1844) self.expression() self.following.pop() if self.failed: return self.match(self.input, 47, self.FOLLOW_47_in_conditional_expression1846) if self.failed: return self.following.append(self.FOLLOW_conditional_expression_in_conditional_expression1848) self.conditional_expression() self.following.pop() if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start, e.stop)) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 51, conditional_expression_StartIndex) pass return # $ANTLR end conditional_expression class logical_or_expression_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start logical_or_expression # C.g:484:1: logical_or_expression : logical_and_expression ( '||' logical_and_expression )* ; def logical_or_expression(self, ): retval = self.logical_or_expression_return() retval.start = self.input.LT(1) logical_or_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 52): return retval # C.g:485:2: ( logical_and_expression ( '||' logical_and_expression )* ) # C.g:485:4: logical_and_expression ( '||' logical_and_expression )* self.following.append(self.FOLLOW_logical_and_expression_in_logical_or_expression1863) self.logical_and_expression() self.following.pop() if self.failed: return retval # C.g:485:27: ( '||' logical_and_expression )* while True: #loop76 alt76 = 2 LA76_0 = self.input.LA(1) if (LA76_0 == 91) : alt76 = 1 if alt76 == 1: # C.g:485:28: '||' logical_and_expression self.match(self.input, 91, self.FOLLOW_91_in_logical_or_expression1866) if self.failed: return retval self.following.append(self.FOLLOW_logical_and_expression_in_logical_or_expression1868) self.logical_and_expression() self.following.pop() if self.failed: return retval else: break #loop76 retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 52, logical_or_expression_StartIndex) pass return retval # $ANTLR end logical_or_expression # $ANTLR start logical_and_expression # C.g:488:1: logical_and_expression : inclusive_or_expression ( '&&' inclusive_or_expression )* ; def logical_and_expression(self, ): logical_and_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 53): return # C.g:489:2: ( inclusive_or_expression ( '&&' inclusive_or_expression )* ) # C.g:489:4: inclusive_or_expression ( '&&' inclusive_or_expression )* self.following.append(self.FOLLOW_inclusive_or_expression_in_logical_and_expression1881) self.inclusive_or_expression() self.following.pop() if self.failed: return # C.g:489:28: ( '&&' inclusive_or_expression )* while True: #loop77 alt77 = 2 LA77_0 = self.input.LA(1) if (LA77_0 == 92) : alt77 = 1 if alt77 == 1: # C.g:489:29: '&&' inclusive_or_expression self.match(self.input, 92, self.FOLLOW_92_in_logical_and_expression1884) if self.failed: return self.following.append(self.FOLLOW_inclusive_or_expression_in_logical_and_expression1886) self.inclusive_or_expression() self.following.pop() if self.failed: return else: break #loop77 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 53, logical_and_expression_StartIndex) pass return # $ANTLR end logical_and_expression # $ANTLR start inclusive_or_expression # C.g:492:1: inclusive_or_expression : exclusive_or_expression ( '|' exclusive_or_expression )* ; def inclusive_or_expression(self, ): inclusive_or_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 54): return # C.g:493:2: ( exclusive_or_expression ( '|' exclusive_or_expression )* ) # C.g:493:4: exclusive_or_expression ( '|' exclusive_or_expression )* self.following.append(self.FOLLOW_exclusive_or_expression_in_inclusive_or_expression1899) self.exclusive_or_expression() self.following.pop() if self.failed: return # C.g:493:28: ( '|' exclusive_or_expression )* while True: #loop78 alt78 = 2 LA78_0 = self.input.LA(1) if (LA78_0 == 93) : alt78 = 1 if alt78 == 1: # C.g:493:29: '|' exclusive_or_expression self.match(self.input, 93, self.FOLLOW_93_in_inclusive_or_expression1902) if self.failed: return self.following.append(self.FOLLOW_exclusive_or_expression_in_inclusive_or_expression1904) self.exclusive_or_expression() self.following.pop() if self.failed: return else: break #loop78 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 54, inclusive_or_expression_StartIndex) pass return # $ANTLR end inclusive_or_expression # $ANTLR start exclusive_or_expression # C.g:496:1: exclusive_or_expression : and_expression ( '^' and_expression )* ; def exclusive_or_expression(self, ): exclusive_or_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 55): return # C.g:497:2: ( and_expression ( '^' and_expression )* ) # C.g:497:4: and_expression ( '^' and_expression )* self.following.append(self.FOLLOW_and_expression_in_exclusive_or_expression1917) self.and_expression() self.following.pop() if self.failed: return # C.g:497:19: ( '^' and_expression )* while True: #loop79 alt79 = 2 LA79_0 = self.input.LA(1) if (LA79_0 == 94) : alt79 = 1 if alt79 == 1: # C.g:497:20: '^' and_expression self.match(self.input, 94, self.FOLLOW_94_in_exclusive_or_expression1920) if self.failed: return self.following.append(self.FOLLOW_and_expression_in_exclusive_or_expression1922) self.and_expression() self.following.pop() if self.failed: return else: break #loop79 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 55, exclusive_or_expression_StartIndex) pass return # $ANTLR end exclusive_or_expression # $ANTLR start and_expression # C.g:500:1: and_expression : equality_expression ( '&' equality_expression )* ; def and_expression(self, ): and_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 56): return # C.g:501:2: ( equality_expression ( '&' equality_expression )* ) # C.g:501:4: equality_expression ( '&' equality_expression )* self.following.append(self.FOLLOW_equality_expression_in_and_expression1935) self.equality_expression() self.following.pop() if self.failed: return # C.g:501:24: ( '&' equality_expression )* while True: #loop80 alt80 = 2 LA80_0 = self.input.LA(1) if (LA80_0 == 77) : alt80 = 1 if alt80 == 1: # C.g:501:25: '&' equality_expression self.match(self.input, 77, self.FOLLOW_77_in_and_expression1938) if self.failed: return self.following.append(self.FOLLOW_equality_expression_in_and_expression1940) self.equality_expression() self.following.pop() if self.failed: return else: break #loop80 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 56, and_expression_StartIndex) pass return # $ANTLR end and_expression # $ANTLR start equality_expression # C.g:503:1: equality_expression : relational_expression ( ( '==' | '!=' ) relational_expression )* ; def equality_expression(self, ): equality_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 57): return # C.g:504:2: ( relational_expression ( ( '==' | '!=' ) relational_expression )* ) # C.g:504:4: relational_expression ( ( '==' | '!=' ) relational_expression )* self.following.append(self.FOLLOW_relational_expression_in_equality_expression1952) self.relational_expression() self.following.pop() if self.failed: return # C.g:504:26: ( ( '==' | '!=' ) relational_expression )* while True: #loop81 alt81 = 2 LA81_0 = self.input.LA(1) if ((95 <= LA81_0 <= 96)) : alt81 = 1 if alt81 == 1: # C.g:504:27: ( '==' | '!=' ) relational_expression if (95 <= self.input.LA(1) <= 96): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_equality_expression1955 ) raise mse self.following.append(self.FOLLOW_relational_expression_in_equality_expression1961) self.relational_expression() self.following.pop() if self.failed: return else: break #loop81 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 57, equality_expression_StartIndex) pass return # $ANTLR end equality_expression # $ANTLR start relational_expression # C.g:507:1: relational_expression : shift_expression ( ( '<' | '>' | '<=' | '>=' ) shift_expression )* ; def relational_expression(self, ): relational_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 58): return # C.g:508:2: ( shift_expression ( ( '<' | '>' | '<=' | '>=' ) shift_expression )* ) # C.g:508:4: shift_expression ( ( '<' | '>' | '<=' | '>=' ) shift_expression )* self.following.append(self.FOLLOW_shift_expression_in_relational_expression1975) self.shift_expression() self.following.pop() if self.failed: return # C.g:508:21: ( ( '<' | '>' | '<=' | '>=' ) shift_expression )* while True: #loop82 alt82 = 2 LA82_0 = self.input.LA(1) if ((97 <= LA82_0 <= 100)) : alt82 = 1 if alt82 == 1: # C.g:508:22: ( '<' | '>' | '<=' | '>=' ) shift_expression if (97 <= self.input.LA(1) <= 100): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_relational_expression1978 ) raise mse self.following.append(self.FOLLOW_shift_expression_in_relational_expression1988) self.shift_expression() self.following.pop() if self.failed: return else: break #loop82 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 58, relational_expression_StartIndex) pass return # $ANTLR end relational_expression # $ANTLR start shift_expression # C.g:511:1: shift_expression : additive_expression ( ( '<<' | '>>' ) additive_expression )* ; def shift_expression(self, ): shift_expression_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 59): return # C.g:512:2: ( additive_expression ( ( '<<' | '>>' ) additive_expression )* ) # C.g:512:4: additive_expression ( ( '<<' | '>>' ) additive_expression )* self.following.append(self.FOLLOW_additive_expression_in_shift_expression2001) self.additive_expression() self.following.pop() if self.failed: return # C.g:512:24: ( ( '<<' | '>>' ) additive_expression )* while True: #loop83 alt83 = 2 LA83_0 = self.input.LA(1) if ((101 <= LA83_0 <= 102)) : alt83 = 1 if alt83 == 1: # C.g:512:25: ( '<<' | '>>' ) additive_expression if (101 <= self.input.LA(1) <= 102): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_shift_expression2004 ) raise mse self.following.append(self.FOLLOW_additive_expression_in_shift_expression2010) self.additive_expression() self.following.pop() if self.failed: return else: break #loop83 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 59, shift_expression_StartIndex) pass return # $ANTLR end shift_expression # $ANTLR start statement # C.g:517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration ); def statement(self, ): statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 60): return # C.g:518:2: ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration ) alt84 = 11 LA84 = self.input.LA(1) if LA84 == IDENTIFIER: LA84 = self.input.LA(2) if LA84 == 62: LA84_43 = self.input.LA(3) if (self.synpred169()) : alt84 = 3 elif (self.synpred173()) : alt84 = 7 elif (self.synpred174()) : alt84 = 8 elif (True) : alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 43, self.input) raise nvae elif LA84 == 47: alt84 = 1 elif LA84 == STRING_LITERAL or LA84 == 27 or LA84 == 28 or LA84 == 64 or LA84 == 68 or LA84 == 69 or LA84 == 70 or LA84 == 71 or LA84 == 72 or LA84 == 73 or LA84 == 75 or LA84 == 76 or LA84 == 77 or LA84 == 80 or LA84 == 81 or LA84 == 82 or LA84 == 83 or LA84 == 84 or LA84 == 85 or LA84 == 86 or LA84 == 87 or LA84 == 88 or LA84 == 89 or LA84 == 90 or LA84 == 91 or LA84 == 92 or LA84 == 93 or LA84 == 94 or LA84 == 95 or LA84 == 96 or LA84 == 97 or LA84 == 98 or LA84 == 99 or LA84 == 100 or LA84 == 101 or LA84 == 102: alt84 = 3 elif LA84 == 66: LA84_47 = self.input.LA(3) if (self.synpred169()) : alt84 = 3 elif (True) : alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 47, self.input) raise nvae elif LA84 == IDENTIFIER: LA84_53 = self.input.LA(3) if (self.synpred169()) : alt84 = 3 elif (True) : alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 53, self.input) raise nvae elif LA84 == 25: LA84_68 = self.input.LA(3) if (self.synpred169()) : alt84 = 3 elif (True) : alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 68, self.input) raise nvae elif LA84 == 29 or LA84 == 30 or LA84 == 31 or LA84 == 32 or LA84 == 33 or LA84 == 34 or LA84 == 35 or LA84 == 36 or LA84 == 37 or LA84 == 38 or LA84 == 39 or LA84 == 40 or LA84 == 41 or LA84 == 42 or LA84 == 45 or LA84 == 46 or LA84 == 48 or LA84 == 49 or LA84 == 50 or LA84 == 51 or LA84 == 52 or LA84 == 53 or LA84 == 54 or LA84 == 55 or LA84 == 56 or LA84 == 57 or LA84 == 58 or LA84 == 59 or LA84 == 60 or LA84 == 61: alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 1, self.input) raise nvae elif LA84 == 106 or LA84 == 107: alt84 = 1 elif LA84 == 43: alt84 = 2 elif LA84 == HEX_LITERAL or LA84 == OCTAL_LITERAL or LA84 == DECIMAL_LITERAL or LA84 == CHARACTER_LITERAL or LA84 == STRING_LITERAL or LA84 == FLOATING_POINT_LITERAL or LA84 == 25 or LA84 == 62 or LA84 == 66 or LA84 == 68 or LA84 == 69 or LA84 == 72 or LA84 == 73 or LA84 == 74 or LA84 == 77 or LA84 == 78 or LA84 == 79: alt84 = 3 elif LA84 == 108 or LA84 == 110: alt84 = 4 elif LA84 == 111 or LA84 == 112 or LA84 == 113: alt84 = 5 elif LA84 == 114 or LA84 == 115 or LA84 == 116 or LA84 == 117: alt84 = 6 elif LA84 == 103: alt84 = 8 elif LA84 == 104: alt84 = 9 elif LA84 == 105: alt84 = 10 elif LA84 == 26 or LA84 == 29 or LA84 == 30 or LA84 == 31 or LA84 == 32 or LA84 == 33 or LA84 == 34 or LA84 == 35 or LA84 == 36 or LA84 == 37 or LA84 == 38 or LA84 == 39 or LA84 == 40 or LA84 == 41 or LA84 == 42 or LA84 == 45 or LA84 == 46 or LA84 == 48 or LA84 == 49 or LA84 == 50 or LA84 == 51 or LA84 == 52 or LA84 == 53 or LA84 == 54 or LA84 == 55 or LA84 == 56 or LA84 == 57 or LA84 == 58 or LA84 == 59 or LA84 == 60 or LA84 == 61: alt84 = 11 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("517:1: statement : ( labeled_statement | compound_statement | expression_statement | selection_statement | iteration_statement | jump_statement | macro_statement | asm2_statement | asm1_statement | asm_statement | declaration );", 84, 0, self.input) raise nvae if alt84 == 1: # C.g:518:4: labeled_statement self.following.append(self.FOLLOW_labeled_statement_in_statement2025) self.labeled_statement() self.following.pop() if self.failed: return elif alt84 == 2: # C.g:519:4: compound_statement self.following.append(self.FOLLOW_compound_statement_in_statement2030) self.compound_statement() self.following.pop() if self.failed: return elif alt84 == 3: # C.g:520:4: expression_statement self.following.append(self.FOLLOW_expression_statement_in_statement2035) self.expression_statement() self.following.pop() if self.failed: return elif alt84 == 4: # C.g:521:4: selection_statement self.following.append(self.FOLLOW_selection_statement_in_statement2040) self.selection_statement() self.following.pop() if self.failed: return elif alt84 == 5: # C.g:522:4: iteration_statement self.following.append(self.FOLLOW_iteration_statement_in_statement2045) self.iteration_statement() self.following.pop() if self.failed: return elif alt84 == 6: # C.g:523:4: jump_statement self.following.append(self.FOLLOW_jump_statement_in_statement2050) self.jump_statement() self.following.pop() if self.failed: return elif alt84 == 7: # C.g:524:4: macro_statement self.following.append(self.FOLLOW_macro_statement_in_statement2055) self.macro_statement() self.following.pop() if self.failed: return elif alt84 == 8: # C.g:525:4: asm2_statement self.following.append(self.FOLLOW_asm2_statement_in_statement2060) self.asm2_statement() self.following.pop() if self.failed: return elif alt84 == 9: # C.g:526:4: asm1_statement self.following.append(self.FOLLOW_asm1_statement_in_statement2065) self.asm1_statement() self.following.pop() if self.failed: return elif alt84 == 10: # C.g:527:4: asm_statement self.following.append(self.FOLLOW_asm_statement_in_statement2070) self.asm_statement() self.following.pop() if self.failed: return elif alt84 == 11: # C.g:528:4: declaration self.following.append(self.FOLLOW_declaration_in_statement2075) self.declaration() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 60, statement_StartIndex) pass return # $ANTLR end statement # $ANTLR start asm2_statement # C.g:531:1: asm2_statement : ( '__asm__' )? IDENTIFIER '(' (~ ( ';' ) )* ')' ';' ; def asm2_statement(self, ): asm2_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 61): return # C.g:532:2: ( ( '__asm__' )? IDENTIFIER '(' (~ ( ';' ) )* ')' ';' ) # C.g:532:4: ( '__asm__' )? IDENTIFIER '(' (~ ( ';' ) )* ')' ';' # C.g:532:4: ( '__asm__' )? alt85 = 2 LA85_0 = self.input.LA(1) if (LA85_0 == 103) : alt85 = 1 if alt85 == 1: # C.g:0:0: '__asm__' self.match(self.input, 103, self.FOLLOW_103_in_asm2_statement2086) if self.failed: return self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_asm2_statement2089) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_asm2_statement2091) if self.failed: return # C.g:532:30: (~ ( ';' ) )* while True: #loop86 alt86 = 2 LA86_0 = self.input.LA(1) if (LA86_0 == 63) : LA86_1 = self.input.LA(2) if ((IDENTIFIER <= LA86_1 <= LINE_COMMAND) or (26 <= LA86_1 <= 117)) : alt86 = 1 elif ((IDENTIFIER <= LA86_0 <= LINE_COMMAND) or (26 <= LA86_0 <= 62) or (64 <= LA86_0 <= 117)) : alt86 = 1 if alt86 == 1: # C.g:532:31: ~ ( ';' ) if (IDENTIFIER <= self.input.LA(1) <= LINE_COMMAND) or (26 <= self.input.LA(1) <= 117): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_asm2_statement2094 ) raise mse else: break #loop86 self.match(self.input, 63, self.FOLLOW_63_in_asm2_statement2101) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_asm2_statement2103) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 61, asm2_statement_StartIndex) pass return # $ANTLR end asm2_statement # $ANTLR start asm1_statement # C.g:535:1: asm1_statement : '_asm' '{' (~ ( '}' ) )* '}' ; def asm1_statement(self, ): asm1_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 62): return # C.g:536:2: ( '_asm' '{' (~ ( '}' ) )* '}' ) # C.g:536:4: '_asm' '{' (~ ( '}' ) )* '}' self.match(self.input, 104, self.FOLLOW_104_in_asm1_statement2115) if self.failed: return self.match(self.input, 43, self.FOLLOW_43_in_asm1_statement2117) if self.failed: return # C.g:536:15: (~ ( '}' ) )* while True: #loop87 alt87 = 2 LA87_0 = self.input.LA(1) if ((IDENTIFIER <= LA87_0 <= 43) or (45 <= LA87_0 <= 117)) : alt87 = 1 if alt87 == 1: # C.g:536:16: ~ ( '}' ) if (IDENTIFIER <= self.input.LA(1) <= 43) or (45 <= self.input.LA(1) <= 117): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_asm1_statement2120 ) raise mse else: break #loop87 self.match(self.input, 44, self.FOLLOW_44_in_asm1_statement2127) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 62, asm1_statement_StartIndex) pass return # $ANTLR end asm1_statement # $ANTLR start asm_statement # C.g:539:1: asm_statement : '__asm' '{' (~ ( '}' ) )* '}' ; def asm_statement(self, ): asm_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 63): return # C.g:540:2: ( '__asm' '{' (~ ( '}' ) )* '}' ) # C.g:540:4: '__asm' '{' (~ ( '}' ) )* '}' self.match(self.input, 105, self.FOLLOW_105_in_asm_statement2138) if self.failed: return self.match(self.input, 43, self.FOLLOW_43_in_asm_statement2140) if self.failed: return # C.g:540:16: (~ ( '}' ) )* while True: #loop88 alt88 = 2 LA88_0 = self.input.LA(1) if ((IDENTIFIER <= LA88_0 <= 43) or (45 <= LA88_0 <= 117)) : alt88 = 1 if alt88 == 1: # C.g:540:17: ~ ( '}' ) if (IDENTIFIER <= self.input.LA(1) <= 43) or (45 <= self.input.LA(1) <= 117): self.input.consume(); self.errorRecovery = False self.failed = False else: if self.backtracking > 0: self.failed = True return mse = MismatchedSetException(None, self.input) self.recoverFromMismatchedSet( self.input, mse, self.FOLLOW_set_in_asm_statement2143 ) raise mse else: break #loop88 self.match(self.input, 44, self.FOLLOW_44_in_asm_statement2150) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 63, asm_statement_StartIndex) pass return # $ANTLR end asm_statement # $ANTLR start macro_statement # C.g:543:1: macro_statement : IDENTIFIER '(' ( declaration )* ( statement_list )? ( expression )? ')' ; def macro_statement(self, ): macro_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 64): return # C.g:544:2: ( IDENTIFIER '(' ( declaration )* ( statement_list )? ( expression )? ')' ) # C.g:544:4: IDENTIFIER '(' ( declaration )* ( statement_list )? ( expression )? ')' self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_macro_statement2162) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_macro_statement2164) if self.failed: return # C.g:544:19: ( declaration )* while True: #loop89 alt89 = 2 LA89 = self.input.LA(1) if LA89 == IDENTIFIER: LA89 = self.input.LA(2) if LA89 == 62: LA89_45 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_47 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 66: LA89_50 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_68 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_71 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_72 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_73 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_74 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_75 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_76 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_77 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_78 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_79 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_80 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_81 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_82 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_83 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_84 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_85 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_86 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 26: LA89 = self.input.LA(2) if LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_87 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_88 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_89 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_90 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_91 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_92 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_93 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_94 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_95 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_96 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_97 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_98 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_99 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_100 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 66: LA89_101 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_102 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_103 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_104 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_105 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89 = self.input.LA(2) if LA89 == 66: LA89_106 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_107 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_108 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_109 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_110 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_111 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_112 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_113 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_114 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_115 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_116 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_117 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_118 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_119 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_120 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_121 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_122 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_123 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_124 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_125 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89 = self.input.LA(2) if LA89 == 66: LA89_126 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_127 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_128 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_129 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_130 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_131 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_132 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_133 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_134 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_135 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_136 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_137 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_138 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_139 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_140 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_141 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_142 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_143 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_144 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_145 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89 = self.input.LA(2) if LA89 == 66: LA89_146 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_147 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_148 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_149 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_150 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_151 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_152 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_153 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_154 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_155 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_156 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_157 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_158 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_159 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_160 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_161 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_162 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_163 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_164 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_165 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89 = self.input.LA(2) if LA89 == 66: LA89_166 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_167 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_168 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_169 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_170 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_171 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_172 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_173 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_174 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_175 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_176 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_177 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_178 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_179 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_180 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_181 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_182 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_183 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_184 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_185 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89 = self.input.LA(2) if LA89 == 66: LA89_186 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_187 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_188 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_189 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_190 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_191 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_192 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_193 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_194 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_195 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_196 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_197 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_198 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_199 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_200 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_201 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_202 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_203 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_204 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_205 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89 = self.input.LA(2) if LA89 == 66: LA89_206 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_207 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_208 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_209 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_210 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_211 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_212 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_213 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_214 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_215 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_216 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_217 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_218 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_219 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_220 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_221 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_222 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_223 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_224 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_225 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89 = self.input.LA(2) if LA89 == 66: LA89_226 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_227 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_228 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_229 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_230 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_231 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_232 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_233 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_234 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_235 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_236 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_237 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_238 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_239 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_240 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_241 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_242 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_243 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_244 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_245 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89 = self.input.LA(2) if LA89 == 66: LA89_246 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_247 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_248 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_249 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_250 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_251 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_252 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_253 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_254 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_255 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_256 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_257 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_258 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_259 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_260 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_261 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_262 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_263 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_264 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_265 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89 = self.input.LA(2) if LA89 == 66: LA89_266 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_267 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_268 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_269 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_270 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_271 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_272 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_273 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_274 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_275 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_276 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_277 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_278 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_279 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_280 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_281 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_282 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_283 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_284 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_285 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89 = self.input.LA(2) if LA89 == 66: LA89_286 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_287 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_288 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_289 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_290 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_291 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_292 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_293 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_294 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_295 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_296 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_297 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_298 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_299 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_300 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_301 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_302 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_303 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_304 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_305 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_40 = self.input.LA(2) if (LA89_40 == IDENTIFIER) : LA89_306 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif (LA89_40 == 43) : LA89_307 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_41 = self.input.LA(2) if (LA89_41 == 43) : LA89_308 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif (LA89_41 == IDENTIFIER) : LA89_309 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 58 or LA89 == 59 or LA89 == 60 or LA89 == 61: LA89 = self.input.LA(2) if LA89 == 66: LA89_310 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 58: LA89_311 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 59: LA89_312 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 60: LA89_313 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == IDENTIFIER: LA89_314 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 62: LA89_315 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 25: LA89_316 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 29 or LA89 == 30 or LA89 == 31 or LA89 == 32 or LA89 == 33: LA89_317 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 34: LA89_318 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 35: LA89_319 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 36: LA89_320 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 37: LA89_321 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 38: LA89_322 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 39: LA89_323 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 40: LA89_324 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 41: LA89_325 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 42: LA89_326 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 45 or LA89 == 46: LA89_327 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 48: LA89_328 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 elif LA89 == 49 or LA89 == 50 or LA89 == 51 or LA89 == 52 or LA89 == 53 or LA89 == 54 or LA89 == 55 or LA89 == 56 or LA89 == 57 or LA89 == 61: LA89_329 = self.input.LA(3) if (self.synpred181()) : alt89 = 1 if alt89 == 1: # C.g:0:0: declaration self.following.append(self.FOLLOW_declaration_in_macro_statement2166) self.declaration() self.following.pop() if self.failed: return else: break #loop89 # C.g:544:33: ( statement_list )? alt90 = 2 LA90 = self.input.LA(1) if LA90 == IDENTIFIER: LA90 = self.input.LA(2) if LA90 == 25 or LA90 == 29 or LA90 == 30 or LA90 == 31 or LA90 == 32 or LA90 == 33 or LA90 == 34 or LA90 == 35 or LA90 == 36 or LA90 == 37 or LA90 == 38 or LA90 == 39 or LA90 == 40 or LA90 == 41 or LA90 == 42 or LA90 == 45 or LA90 == 46 or LA90 == 47 or LA90 == 48 or LA90 == 49 or LA90 == 50 or LA90 == 51 or LA90 == 52 or LA90 == 53 or LA90 == 54 or LA90 == 55 or LA90 == 56 or LA90 == 57 or LA90 == 58 or LA90 == 59 or LA90 == 60 or LA90 == 61: alt90 = 1 elif LA90 == 62: LA90_45 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_46 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == IDENTIFIER: LA90_47 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 64: LA90_48 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_49 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_50 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_51 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_52 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_53 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_54 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_55 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_56 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_57 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_58 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_59 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_60 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_61 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_62 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_63 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_64 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_65 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_66 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_67 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_70 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25 or LA90 == 26 or LA90 == 29 or LA90 == 30 or LA90 == 31 or LA90 == 32 or LA90 == 33 or LA90 == 34 or LA90 == 35 or LA90 == 36 or LA90 == 37 or LA90 == 38 or LA90 == 39 or LA90 == 40 or LA90 == 41 or LA90 == 42 or LA90 == 43 or LA90 == 45 or LA90 == 46 or LA90 == 48 or LA90 == 49 or LA90 == 50 or LA90 == 51 or LA90 == 52 or LA90 == 53 or LA90 == 54 or LA90 == 55 or LA90 == 56 or LA90 == 57 or LA90 == 58 or LA90 == 59 or LA90 == 60 or LA90 == 61 or LA90 == 103 or LA90 == 104 or LA90 == 105 or LA90 == 106 or LA90 == 107 or LA90 == 108 or LA90 == 110 or LA90 == 111 or LA90 == 112 or LA90 == 113 or LA90 == 114 or LA90 == 115 or LA90 == 116 or LA90 == 117: alt90 = 1 elif LA90 == HEX_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_87 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_88 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_89 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_90 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_91 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_92 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_93 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_94 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_95 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_96 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_97 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_98 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_99 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_100 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_101 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_102 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_103 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_104 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_105 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_106 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_107 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_108 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_111 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_112 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_113 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_114 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_115 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_116 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_117 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_118 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_119 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_120 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_121 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_122 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_123 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_124 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_125 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_126 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_127 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_128 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_129 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_130 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_131 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_134 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_135 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_136 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_137 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_138 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_139 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_140 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_141 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_142 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_143 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_144 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_145 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_146 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_147 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_148 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_149 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_150 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_151 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_152 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_153 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_154 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_155 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_156 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_159 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_160 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_161 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_162 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_163 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_164 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_165 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_166 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_167 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_168 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_169 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_170 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_171 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_172 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_173 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_174 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_175 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_176 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_177 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_178 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_179 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_181 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90 = self.input.LA(2) if LA90 == IDENTIFIER: LA90_183 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 64: LA90_184 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_185 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_186 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_187 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_188 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_189 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_190 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_191 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_192 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_193 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_194 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_195 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_196 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_197 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_198 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_199 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_200 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_201 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_202 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_203 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_204 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_205 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_206 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90 = self.input.LA(2) if LA90 == 64: LA90_209 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_210 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 75: LA90_211 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66: LA90_212 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 76: LA90_213 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_214 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_215 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 28 or LA90 == 80 or LA90 == 81 or LA90 == 82 or LA90 == 83 or LA90 == 84 or LA90 == 85 or LA90 == 86 or LA90 == 87 or LA90 == 88 or LA90 == 89: LA90_216 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 70: LA90_217 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 71: LA90_218 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 68: LA90_219 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 69: LA90_220 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 101 or LA90 == 102: LA90_221 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 97 or LA90 == 98 or LA90 == 99 or LA90 == 100: LA90_222 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 95 or LA90 == 96: LA90_223 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 77: LA90_224 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 94: LA90_225 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 93: LA90_226 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 92: LA90_227 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 91: LA90_228 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 90: LA90_229 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 27: LA90_230 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 25: alt90 = 1 elif LA90 == 62: LA90 = self.input.LA(2) if LA90 == IDENTIFIER: LA90_233 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_234 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_235 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_236 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_237 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_238 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_239 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_240 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_241 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_242 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_243 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_244 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 49 or LA90 == 50 or LA90 == 51 or LA90 == 52 or LA90 == 53 or LA90 == 54 or LA90 == 55 or LA90 == 56 or LA90 == 57 or LA90 == 58 or LA90 == 59 or LA90 == 60 or LA90 == 61: LA90_245 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 34: LA90_246 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 35: LA90_247 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 36: LA90_248 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 37: LA90_249 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 38: LA90_250 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 39: LA90_251 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 40: LA90_252 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 41: LA90_253 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 42: LA90_254 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 45 or LA90 == 46: LA90_255 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 48: LA90_256 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90 = self.input.LA(2) if LA90 == IDENTIFIER: LA90_257 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_258 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_259 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_260 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_261 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_262 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_263 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_264 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_265 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_266 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_267 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_268 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90 = self.input.LA(2) if LA90 == IDENTIFIER: LA90_269 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_270 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_271 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_272 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_273 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_274 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_275 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 62: LA90_276 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_277 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_278 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_279 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_280 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90 = self.input.LA(2) if LA90 == 62: LA90_281 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == IDENTIFIER: LA90_282 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_283 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_284 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_285 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_286 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_287 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_288 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_289 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_290 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_291 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_292 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90 = self.input.LA(2) if LA90 == 62: LA90_293 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == IDENTIFIER: LA90_294 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == HEX_LITERAL: LA90_295 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == OCTAL_LITERAL: LA90_296 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == DECIMAL_LITERAL: LA90_297 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == CHARACTER_LITERAL: LA90_298 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == STRING_LITERAL: LA90_299 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == FLOATING_POINT_LITERAL: LA90_300 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 72: LA90_301 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 73: LA90_302 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 66 or LA90 == 68 or LA90 == 69 or LA90 == 77 or LA90 == 78 or LA90 == 79: LA90_303 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 elif LA90 == 74: LA90_304 = self.input.LA(3) if (self.synpred182()) : alt90 = 1 if alt90 == 1: # C.g:0:0: statement_list self.following.append(self.FOLLOW_statement_list_in_macro_statement2170) self.statement_list() self.following.pop() if self.failed: return # C.g:544:49: ( expression )? alt91 = 2 LA91_0 = self.input.LA(1) if ((IDENTIFIER <= LA91_0 <= FLOATING_POINT_LITERAL) or LA91_0 == 62 or LA91_0 == 66 or (68 <= LA91_0 <= 69) or (72 <= LA91_0 <= 74) or (77 <= LA91_0 <= 79)) : alt91 = 1 if alt91 == 1: # C.g:0:0: expression self.following.append(self.FOLLOW_expression_in_macro_statement2173) self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_macro_statement2176) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 64, macro_statement_StartIndex) pass return # $ANTLR end macro_statement # $ANTLR start labeled_statement # C.g:547:1: labeled_statement : ( IDENTIFIER ':' statement | 'case' constant_expression ':' statement | 'default' ':' statement ); def labeled_statement(self, ): labeled_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 65): return # C.g:548:2: ( IDENTIFIER ':' statement | 'case' constant_expression ':' statement | 'default' ':' statement ) alt92 = 3 LA92 = self.input.LA(1) if LA92 == IDENTIFIER: alt92 = 1 elif LA92 == 106: alt92 = 2 elif LA92 == 107: alt92 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("547:1: labeled_statement : ( IDENTIFIER ':' statement | 'case' constant_expression ':' statement | 'default' ':' statement );", 92, 0, self.input) raise nvae if alt92 == 1: # C.g:548:4: IDENTIFIER ':' statement self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_labeled_statement2188) if self.failed: return self.match(self.input, 47, self.FOLLOW_47_in_labeled_statement2190) if self.failed: return self.following.append(self.FOLLOW_statement_in_labeled_statement2192) self.statement() self.following.pop() if self.failed: return elif alt92 == 2: # C.g:549:4: 'case' constant_expression ':' statement self.match(self.input, 106, self.FOLLOW_106_in_labeled_statement2197) if self.failed: return self.following.append(self.FOLLOW_constant_expression_in_labeled_statement2199) self.constant_expression() self.following.pop() if self.failed: return self.match(self.input, 47, self.FOLLOW_47_in_labeled_statement2201) if self.failed: return self.following.append(self.FOLLOW_statement_in_labeled_statement2203) self.statement() self.following.pop() if self.failed: return elif alt92 == 3: # C.g:550:4: 'default' ':' statement self.match(self.input, 107, self.FOLLOW_107_in_labeled_statement2208) if self.failed: return self.match(self.input, 47, self.FOLLOW_47_in_labeled_statement2210) if self.failed: return self.following.append(self.FOLLOW_statement_in_labeled_statement2212) self.statement() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 65, labeled_statement_StartIndex) pass return # $ANTLR end labeled_statement class compound_statement_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start compound_statement # C.g:553:1: compound_statement : '{' ( declaration )* ( statement_list )? '}' ; def compound_statement(self, ): retval = self.compound_statement_return() retval.start = self.input.LT(1) compound_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 66): return retval # C.g:554:2: ( '{' ( declaration )* ( statement_list )? '}' ) # C.g:554:4: '{' ( declaration )* ( statement_list )? '}' self.match(self.input, 43, self.FOLLOW_43_in_compound_statement2223) if self.failed: return retval # C.g:554:8: ( declaration )* while True: #loop93 alt93 = 2 LA93 = self.input.LA(1) if LA93 == IDENTIFIER: LA93 = self.input.LA(2) if LA93 == 62: LA93_44 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_47 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 66: LA93_48 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_49 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_50 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_51 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_52 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_53 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_54 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_55 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_56 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_57 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_58 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_59 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_60 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_61 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_62 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_63 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_64 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_65 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 26: LA93 = self.input.LA(2) if LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_86 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_87 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_88 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_89 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_90 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_91 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_92 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_93 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_94 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_95 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_96 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_97 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_98 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_99 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 66: LA93_100 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_101 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_102 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_103 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_104 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93 = self.input.LA(2) if LA93 == 66: LA93_105 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_106 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_107 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_108 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_109 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_110 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_111 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_112 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_113 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_114 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_115 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_116 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_117 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_118 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_119 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_120 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_121 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_122 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_123 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_124 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93 = self.input.LA(2) if LA93 == 66: LA93_125 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_126 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_127 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_128 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_129 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_130 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_131 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_132 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_133 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_134 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_135 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_136 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_137 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_138 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_139 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_140 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_141 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_142 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_143 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_144 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93 = self.input.LA(2) if LA93 == 66: LA93_145 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_146 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_147 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_148 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_149 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_150 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_151 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_152 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_153 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_154 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_155 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_156 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_157 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_158 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_159 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_160 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_161 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_162 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_163 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_164 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93 = self.input.LA(2) if LA93 == 66: LA93_165 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_166 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_167 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_168 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_169 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_170 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_171 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_172 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_173 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_174 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_175 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_176 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_177 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_178 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_179 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_180 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_181 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_182 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_183 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_184 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93 = self.input.LA(2) if LA93 == 66: LA93_185 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_186 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_187 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_188 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_189 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_190 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_191 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_192 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_193 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_194 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_195 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_196 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_197 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_198 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_199 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_200 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_201 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_202 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_203 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_204 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93 = self.input.LA(2) if LA93 == 66: LA93_205 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_206 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_207 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_208 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_209 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_210 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_211 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_212 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_213 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_214 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_215 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_216 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_217 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_218 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_219 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_220 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_221 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_222 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_223 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_224 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93 = self.input.LA(2) if LA93 == 66: LA93_225 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_226 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_227 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_228 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_229 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_230 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_231 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_232 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_233 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_234 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_235 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_236 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_237 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_238 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_239 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_240 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_241 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_242 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_243 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_244 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93 = self.input.LA(2) if LA93 == 66: LA93_245 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_246 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_247 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_248 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_249 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_250 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_251 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_252 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_253 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_254 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_255 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_256 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_257 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_258 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_259 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_260 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_261 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_262 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_263 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_264 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93 = self.input.LA(2) if LA93 == 66: LA93_265 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_266 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_267 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_268 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_269 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_270 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_271 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_272 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_273 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_274 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_275 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_276 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_277 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_278 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_279 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_280 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_281 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_282 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_283 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_284 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93 = self.input.LA(2) if LA93 == 66: LA93_285 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_286 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_287 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_288 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_289 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_290 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_291 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_292 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_293 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_294 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_295 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_296 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_297 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_298 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_299 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_300 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_301 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_302 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_303 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_304 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_40 = self.input.LA(2) if (LA93_40 == IDENTIFIER) : LA93_305 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif (LA93_40 == 43) : LA93_306 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_41 = self.input.LA(2) if (LA93_41 == 43) : LA93_307 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif (LA93_41 == IDENTIFIER) : LA93_308 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 58 or LA93 == 59 or LA93 == 60 or LA93 == 61: LA93 = self.input.LA(2) if LA93 == 66: LA93_309 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 58: LA93_310 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 59: LA93_311 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 60: LA93_312 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == IDENTIFIER: LA93_313 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 62: LA93_314 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 25: LA93_315 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 29 or LA93 == 30 or LA93 == 31 or LA93 == 32 or LA93 == 33: LA93_316 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 34: LA93_317 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 35: LA93_318 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 36: LA93_319 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 37: LA93_320 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 38: LA93_321 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 39: LA93_322 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 40: LA93_323 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 41: LA93_324 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 42: LA93_325 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 45 or LA93 == 46: LA93_326 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 48: LA93_327 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 elif LA93 == 49 or LA93 == 50 or LA93 == 51 or LA93 == 52 or LA93 == 53 or LA93 == 54 or LA93 == 55 or LA93 == 56 or LA93 == 57 or LA93 == 61: LA93_328 = self.input.LA(3) if (self.synpred186()) : alt93 = 1 if alt93 == 1: # C.g:0:0: declaration self.following.append(self.FOLLOW_declaration_in_compound_statement2225) self.declaration() self.following.pop() if self.failed: return retval else: break #loop93 # C.g:554:21: ( statement_list )? alt94 = 2 LA94_0 = self.input.LA(1) if ((IDENTIFIER <= LA94_0 <= FLOATING_POINT_LITERAL) or (25 <= LA94_0 <= 26) or (29 <= LA94_0 <= 43) or (45 <= LA94_0 <= 46) or (48 <= LA94_0 <= 62) or LA94_0 == 66 or (68 <= LA94_0 <= 69) or (72 <= LA94_0 <= 74) or (77 <= LA94_0 <= 79) or (103 <= LA94_0 <= 108) or (110 <= LA94_0 <= 117)) : alt94 = 1 if alt94 == 1: # C.g:0:0: statement_list self.following.append(self.FOLLOW_statement_list_in_compound_statement2228) self.statement_list() self.following.pop() if self.failed: return retval self.match(self.input, 44, self.FOLLOW_44_in_compound_statement2231) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 66, compound_statement_StartIndex) pass return retval # $ANTLR end compound_statement # $ANTLR start statement_list # C.g:557:1: statement_list : ( statement )+ ; def statement_list(self, ): statement_list_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 67): return # C.g:558:2: ( ( statement )+ ) # C.g:558:4: ( statement )+ # C.g:558:4: ( statement )+ cnt95 = 0 while True: #loop95 alt95 = 2 LA95 = self.input.LA(1) if LA95 == IDENTIFIER: LA95 = self.input.LA(2) if LA95 == 62: LA95_46 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25 or LA95 == 29 or LA95 == 30 or LA95 == 31 or LA95 == 32 or LA95 == 33 or LA95 == 34 or LA95 == 35 or LA95 == 36 or LA95 == 37 or LA95 == 38 or LA95 == 39 or LA95 == 40 or LA95 == 41 or LA95 == 42 or LA95 == 45 or LA95 == 46 or LA95 == 47 or LA95 == 48 or LA95 == 49 or LA95 == 50 or LA95 == 51 or LA95 == 52 or LA95 == 53 or LA95 == 54 or LA95 == 55 or LA95 == 56 or LA95 == 57 or LA95 == 58 or LA95 == 59 or LA95 == 60 or LA95 == 61: alt95 = 1 elif LA95 == STRING_LITERAL: LA95_48 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == IDENTIFIER: LA95_49 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 64: LA95_50 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_51 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_52 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_53 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_54 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_55 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_56 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_57 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_58 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_59 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_60 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_61 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_62 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_63 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_64 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_65 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_66 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_67 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_68 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_69 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_88 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_89 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_90 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_91 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_92 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_93 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_94 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_95 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_96 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_97 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_98 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_99 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_100 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_101 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_102 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_103 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_104 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_105 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_106 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_107 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_108 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_109 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_110 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_113 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_114 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_115 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_116 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_117 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_118 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_119 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_120 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_121 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_122 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_123 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_124 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_125 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_126 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_127 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_128 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_129 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_130 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_131 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_132 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_133 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_135 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_137 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_138 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_139 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_140 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_141 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_142 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_143 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_144 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_145 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_146 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_147 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_148 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_149 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_150 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_151 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_152 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_153 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_154 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_155 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_156 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_157 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_158 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_161 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_162 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_163 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_164 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_165 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_166 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_167 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_168 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_169 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_170 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_171 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_172 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_173 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_174 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_175 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_176 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_177 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_178 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_179 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_180 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_181 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_182 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == STRING_LITERAL: LA95 = self.input.LA(2) if LA95 == IDENTIFIER: LA95_185 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 64: LA95_186 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_187 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_188 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_189 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_190 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_191 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_192 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_193 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_194 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_195 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_196 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_197 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_198 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_199 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_200 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_201 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_202 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_203 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_204 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_205 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_206 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == STRING_LITERAL: LA95_208 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_209 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95 = self.input.LA(2) if LA95 == 64: LA95_211 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_212 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 75: LA95_213 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66: LA95_214 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 76: LA95_215 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_216 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_217 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 70: LA95_218 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 71: LA95_219 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 68: LA95_220 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 69: LA95_221 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 101 or LA95 == 102: LA95_222 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 97 or LA95 == 98 or LA95 == 99 or LA95 == 100: LA95_223 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 95 or LA95 == 96: LA95_224 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 77: LA95_225 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 94: LA95_226 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 93: LA95_227 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 92: LA95_228 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 91: LA95_229 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 90: LA95_230 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 27: LA95_231 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25: alt95 = 1 elif LA95 == 28 or LA95 == 80 or LA95 == 81 or LA95 == 82 or LA95 == 83 or LA95 == 84 or LA95 == 85 or LA95 == 86 or LA95 == 87 or LA95 == 88 or LA95 == 89: LA95_234 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95 = self.input.LA(2) if LA95 == IDENTIFIER: LA95_235 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_236 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_237 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_238 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_239 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_240 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_241 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_242 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_243 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_244 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_245 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_246 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 49 or LA95 == 50 or LA95 == 51 or LA95 == 52 or LA95 == 53 or LA95 == 54 or LA95 == 55 or LA95 == 56 or LA95 == 57 or LA95 == 58 or LA95 == 59 or LA95 == 60 or LA95 == 61: LA95_247 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 34: LA95_248 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 35: LA95_249 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 36: LA95_250 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 37: LA95_251 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 38: LA95_252 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 39: LA95_253 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 40: LA95_254 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 41: LA95_255 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 42: LA95_256 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 45 or LA95 == 46: LA95_257 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 48: LA95_258 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95 = self.input.LA(2) if LA95 == IDENTIFIER: LA95_259 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_260 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_261 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_262 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_263 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_264 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_265 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_266 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_267 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_268 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_269 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_270 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95 = self.input.LA(2) if LA95 == IDENTIFIER: LA95_271 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_272 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_273 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_274 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_275 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_276 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_277 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 62: LA95_278 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_279 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_280 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_281 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_282 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95 = self.input.LA(2) if LA95 == 62: LA95_283 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == IDENTIFIER: LA95_284 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_285 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_286 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_287 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_288 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_289 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_290 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_291 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_292 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_293 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_294 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95 = self.input.LA(2) if LA95 == 62: LA95_295 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == IDENTIFIER: LA95_296 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == HEX_LITERAL: LA95_297 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == OCTAL_LITERAL: LA95_298 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == DECIMAL_LITERAL: LA95_299 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == CHARACTER_LITERAL: LA95_300 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == STRING_LITERAL: LA95_301 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == FLOATING_POINT_LITERAL: LA95_302 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 72: LA95_303 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 73: LA95_304 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 66 or LA95 == 68 or LA95 == 69 or LA95 == 77 or LA95 == 78 or LA95 == 79: LA95_305 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 74: LA95_306 = self.input.LA(3) if (self.synpred188()) : alt95 = 1 elif LA95 == 25 or LA95 == 26 or LA95 == 29 or LA95 == 30 or LA95 == 31 or LA95 == 32 or LA95 == 33 or LA95 == 34 or LA95 == 35 or LA95 == 36 or LA95 == 37 or LA95 == 38 or LA95 == 39 or LA95 == 40 or LA95 == 41 or LA95 == 42 or LA95 == 43 or LA95 == 45 or LA95 == 46 or LA95 == 48 or LA95 == 49 or LA95 == 50 or LA95 == 51 or LA95 == 52 or LA95 == 53 or LA95 == 54 or LA95 == 55 or LA95 == 56 or LA95 == 57 or LA95 == 58 or LA95 == 59 or LA95 == 60 or LA95 == 61 or LA95 == 103 or LA95 == 104 or LA95 == 105 or LA95 == 106 or LA95 == 107 or LA95 == 108 or LA95 == 110 or LA95 == 111 or LA95 == 112 or LA95 == 113 or LA95 == 114 or LA95 == 115 or LA95 == 116 or LA95 == 117: alt95 = 1 if alt95 == 1: # C.g:0:0: statement self.following.append(self.FOLLOW_statement_in_statement_list2242) self.statement() self.following.pop() if self.failed: return else: if cnt95 >= 1: break #loop95 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(95, self.input) raise eee cnt95 += 1 except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 67, statement_list_StartIndex) pass return # $ANTLR end statement_list class expression_statement_return(object): def __init__(self): self.start = None self.stop = None # $ANTLR start expression_statement # C.g:561:1: expression_statement : ( ';' | expression ';' ); def expression_statement(self, ): retval = self.expression_statement_return() retval.start = self.input.LT(1) expression_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 68): return retval # C.g:562:2: ( ';' | expression ';' ) alt96 = 2 LA96_0 = self.input.LA(1) if (LA96_0 == 25) : alt96 = 1 elif ((IDENTIFIER <= LA96_0 <= FLOATING_POINT_LITERAL) or LA96_0 == 62 or LA96_0 == 66 or (68 <= LA96_0 <= 69) or (72 <= LA96_0 <= 74) or (77 <= LA96_0 <= 79)) : alt96 = 2 else: if self.backtracking > 0: self.failed = True return retval nvae = NoViableAltException("561:1: expression_statement : ( ';' | expression ';' );", 96, 0, self.input) raise nvae if alt96 == 1: # C.g:562:4: ';' self.match(self.input, 25, self.FOLLOW_25_in_expression_statement2254) if self.failed: return retval elif alt96 == 2: # C.g:563:4: expression ';' self.following.append(self.FOLLOW_expression_in_expression_statement2259) self.expression() self.following.pop() if self.failed: return retval self.match(self.input, 25, self.FOLLOW_25_in_expression_statement2261) if self.failed: return retval retval.stop = self.input.LT(-1) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 68, expression_statement_StartIndex) pass return retval # $ANTLR end expression_statement # $ANTLR start selection_statement # C.g:566:1: selection_statement : ( 'if' '(' e= expression ')' statement ( options {k=1; backtrack=false; } : 'else' statement )? | 'switch' '(' expression ')' statement ); def selection_statement(self, ): selection_statement_StartIndex = self.input.index() e = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 69): return # C.g:567:2: ( 'if' '(' e= expression ')' statement ( options {k=1; backtrack=false; } : 'else' statement )? | 'switch' '(' expression ')' statement ) alt98 = 2 LA98_0 = self.input.LA(1) if (LA98_0 == 108) : alt98 = 1 elif (LA98_0 == 110) : alt98 = 2 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("566:1: selection_statement : ( 'if' '(' e= expression ')' statement ( options {k=1; backtrack=false; } : 'else' statement )? | 'switch' '(' expression ')' statement );", 98, 0, self.input) raise nvae if alt98 == 1: # C.g:567:4: 'if' '(' e= expression ')' statement ( options {k=1; backtrack=false; } : 'else' statement )? self.match(self.input, 108, self.FOLLOW_108_in_selection_statement2272) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_selection_statement2274) if self.failed: return self.following.append(self.FOLLOW_expression_in_selection_statement2278) e = self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_selection_statement2280) if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start, e.stop)) self.following.append(self.FOLLOW_statement_in_selection_statement2284) self.statement() self.following.pop() if self.failed: return # C.g:567:167: ( options {k=1; backtrack=false; } : 'else' statement )? alt97 = 2 LA97_0 = self.input.LA(1) if (LA97_0 == 109) : alt97 = 1 if alt97 == 1: # C.g:567:200: 'else' statement self.match(self.input, 109, self.FOLLOW_109_in_selection_statement2299) if self.failed: return self.following.append(self.FOLLOW_statement_in_selection_statement2301) self.statement() self.following.pop() if self.failed: return elif alt98 == 2: # C.g:568:4: 'switch' '(' expression ')' statement self.match(self.input, 110, self.FOLLOW_110_in_selection_statement2308) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_selection_statement2310) if self.failed: return self.following.append(self.FOLLOW_expression_in_selection_statement2312) self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_selection_statement2314) if self.failed: return self.following.append(self.FOLLOW_statement_in_selection_statement2316) self.statement() self.following.pop() if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 69, selection_statement_StartIndex) pass return # $ANTLR end selection_statement # $ANTLR start iteration_statement # C.g:571:1: iteration_statement : ( 'while' '(' e= expression ')' statement | 'do' statement 'while' '(' e= expression ')' ';' | 'for' '(' expression_statement e= expression_statement ( expression )? ')' statement ); def iteration_statement(self, ): iteration_statement_StartIndex = self.input.index() e = None try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 70): return # C.g:572:2: ( 'while' '(' e= expression ')' statement | 'do' statement 'while' '(' e= expression ')' ';' | 'for' '(' expression_statement e= expression_statement ( expression )? ')' statement ) alt100 = 3 LA100 = self.input.LA(1) if LA100 == 111: alt100 = 1 elif LA100 == 112: alt100 = 2 elif LA100 == 113: alt100 = 3 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("571:1: iteration_statement : ( 'while' '(' e= expression ')' statement | 'do' statement 'while' '(' e= expression ')' ';' | 'for' '(' expression_statement e= expression_statement ( expression )? ')' statement );", 100, 0, self.input) raise nvae if alt100 == 1: # C.g:572:4: 'while' '(' e= expression ')' statement self.match(self.input, 111, self.FOLLOW_111_in_iteration_statement2327) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_iteration_statement2329) if self.failed: return self.following.append(self.FOLLOW_expression_in_iteration_statement2333) e = self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_iteration_statement2335) if self.failed: return self.following.append(self.FOLLOW_statement_in_iteration_statement2337) self.statement() self.following.pop() if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start, e.stop)) elif alt100 == 2: # C.g:573:4: 'do' statement 'while' '(' e= expression ')' ';' self.match(self.input, 112, self.FOLLOW_112_in_iteration_statement2344) if self.failed: return self.following.append(self.FOLLOW_statement_in_iteration_statement2346) self.statement() self.following.pop() if self.failed: return self.match(self.input, 111, self.FOLLOW_111_in_iteration_statement2348) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_iteration_statement2350) if self.failed: return self.following.append(self.FOLLOW_expression_in_iteration_statement2354) e = self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_iteration_statement2356) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_iteration_statement2358) if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start, e.stop)) elif alt100 == 3: # C.g:574:4: 'for' '(' expression_statement e= expression_statement ( expression )? ')' statement self.match(self.input, 113, self.FOLLOW_113_in_iteration_statement2365) if self.failed: return self.match(self.input, 62, self.FOLLOW_62_in_iteration_statement2367) if self.failed: return self.following.append(self.FOLLOW_expression_statement_in_iteration_statement2369) self.expression_statement() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_expression_statement_in_iteration_statement2373) e = self.expression_statement() self.following.pop() if self.failed: return # C.g:574:58: ( expression )? alt99 = 2 LA99_0 = self.input.LA(1) if ((IDENTIFIER <= LA99_0 <= FLOATING_POINT_LITERAL) or LA99_0 == 62 or LA99_0 == 66 or (68 <= LA99_0 <= 69) or (72 <= LA99_0 <= 74) or (77 <= LA99_0 <= 79)) : alt99 = 1 if alt99 == 1: # C.g:0:0: expression self.following.append(self.FOLLOW_expression_in_iteration_statement2375) self.expression() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_iteration_statement2378) if self.failed: return self.following.append(self.FOLLOW_statement_in_iteration_statement2380) self.statement() self.following.pop() if self.failed: return if self.backtracking == 0: self.StorePredicateExpression(e.start.line, e.start.charPositionInLine, e.stop.line, e.stop.charPositionInLine, self.input.toString(e.start, e.stop)) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 70, iteration_statement_StartIndex) pass return # $ANTLR end iteration_statement # $ANTLR start jump_statement # C.g:577:1: jump_statement : ( 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' ); def jump_statement(self, ): jump_statement_StartIndex = self.input.index() try: try: if self.backtracking > 0 and self.alreadyParsedRule(self.input, 71): return # C.g:578:2: ( 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' ) alt101 = 5 LA101 = self.input.LA(1) if LA101 == 114: alt101 = 1 elif LA101 == 115: alt101 = 2 elif LA101 == 116: alt101 = 3 elif LA101 == 117: LA101_4 = self.input.LA(2) if (LA101_4 == 25) : alt101 = 4 elif ((IDENTIFIER <= LA101_4 <= FLOATING_POINT_LITERAL) or LA101_4 == 62 or LA101_4 == 66 or (68 <= LA101_4 <= 69) or (72 <= LA101_4 <= 74) or (77 <= LA101_4 <= 79)) : alt101 = 5 else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("577:1: jump_statement : ( 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' );", 101, 4, self.input) raise nvae else: if self.backtracking > 0: self.failed = True return nvae = NoViableAltException("577:1: jump_statement : ( 'goto' IDENTIFIER ';' | 'continue' ';' | 'break' ';' | 'return' ';' | 'return' expression ';' );", 101, 0, self.input) raise nvae if alt101 == 1: # C.g:578:4: 'goto' IDENTIFIER ';' self.match(self.input, 114, self.FOLLOW_114_in_jump_statement2393) if self.failed: return self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_jump_statement2395) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2397) if self.failed: return elif alt101 == 2: # C.g:579:4: 'continue' ';' self.match(self.input, 115, self.FOLLOW_115_in_jump_statement2402) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2404) if self.failed: return elif alt101 == 3: # C.g:580:4: 'break' ';' self.match(self.input, 116, self.FOLLOW_116_in_jump_statement2409) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2411) if self.failed: return elif alt101 == 4: # C.g:581:4: 'return' ';' self.match(self.input, 117, self.FOLLOW_117_in_jump_statement2416) if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2418) if self.failed: return elif alt101 == 5: # C.g:582:4: 'return' expression ';' self.match(self.input, 117, self.FOLLOW_117_in_jump_statement2423) if self.failed: return self.following.append(self.FOLLOW_expression_in_jump_statement2425) self.expression() self.following.pop() if self.failed: return self.match(self.input, 25, self.FOLLOW_25_in_jump_statement2427) if self.failed: return except RecognitionException as re: self.reportError(re) self.recover(self.input, re) finally: if self.backtracking > 0: self.memoize(self.input, 71, jump_statement_StartIndex) pass return # $ANTLR end jump_statement # $ANTLR start synpred2 def synpred2_fragment(self, ): # C.g:119:6: ( declaration_specifiers ) # C.g:119:6: declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_synpred2100) self.declaration_specifiers() self.following.pop() if self.failed: return # $ANTLR end synpred2 # $ANTLR start synpred4 def synpred4_fragment(self, ): # C.g:119:4: ( ( declaration_specifiers )? declarator ( declaration )* '{' ) # C.g:119:6: ( declaration_specifiers )? declarator ( declaration )* '{' # C.g:119:6: ( declaration_specifiers )? alt102 = 2 LA102 = self.input.LA(1) if LA102 == 29 or LA102 == 30 or LA102 == 31 or LA102 == 32 or LA102 == 33 or LA102 == 34 or LA102 == 35 or LA102 == 36 or LA102 == 37 or LA102 == 38 or LA102 == 39 or LA102 == 40 or LA102 == 41 or LA102 == 42 or LA102 == 45 or LA102 == 46 or LA102 == 48 or LA102 == 49 or LA102 == 50 or LA102 == 51 or LA102 == 52 or LA102 == 53 or LA102 == 54 or LA102 == 55 or LA102 == 56 or LA102 == 57 or LA102 == 61: alt102 = 1 elif LA102 == IDENTIFIER: LA102 = self.input.LA(2) if LA102 == 62: LA102_21 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 29 or LA102 == 30 or LA102 == 31 or LA102 == 32 or LA102 == 33: LA102_23 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 34: LA102_24 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 35: LA102_25 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 36: LA102_26 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 37: LA102_27 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 38: LA102_28 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 39: LA102_29 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 40: LA102_30 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 41: LA102_31 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 42: LA102_32 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 45 or LA102 == 46: LA102_33 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 48: LA102_34 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == IDENTIFIER: LA102_35 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 58: LA102_36 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 66: alt102 = 1 elif LA102 == 59: LA102_39 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 60: LA102_40 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 49 or LA102 == 50 or LA102 == 51 or LA102 == 52 or LA102 == 53 or LA102 == 54 or LA102 == 55 or LA102 == 56 or LA102 == 57 or LA102 == 61: LA102_41 = self.input.LA(3) if (self.synpred2()) : alt102 = 1 elif LA102 == 58: LA102_14 = self.input.LA(2) if (self.synpred2()) : alt102 = 1 elif LA102 == 59: LA102_16 = self.input.LA(2) if (self.synpred2()) : alt102 = 1 elif LA102 == 60: LA102_17 = self.input.LA(2) if (self.synpred2()) : alt102 = 1 if alt102 == 1: # C.g:0:0: declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_synpred4100) self.declaration_specifiers() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_declarator_in_synpred4103) self.declarator() self.following.pop() if self.failed: return # C.g:119:41: ( declaration )* while True: #loop103 alt103 = 2 LA103_0 = self.input.LA(1) if (LA103_0 == IDENTIFIER or LA103_0 == 26 or (29 <= LA103_0 <= 42) or (45 <= LA103_0 <= 46) or (48 <= LA103_0 <= 61)) : alt103 = 1 if alt103 == 1: # C.g:0:0: declaration self.following.append(self.FOLLOW_declaration_in_synpred4105) self.declaration() self.following.pop() if self.failed: return else: break #loop103 self.match(self.input, 43, self.FOLLOW_43_in_synpred4108) if self.failed: return # $ANTLR end synpred4 # $ANTLR start synpred5 def synpred5_fragment(self, ): # C.g:120:4: ( declaration ) # C.g:120:4: declaration self.following.append(self.FOLLOW_declaration_in_synpred5118) self.declaration() self.following.pop() if self.failed: return # $ANTLR end synpred5 # $ANTLR start synpred7 def synpred7_fragment(self, ): # C.g:146:6: ( declaration_specifiers ) # C.g:146:6: declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_synpred7157) self.declaration_specifiers() self.following.pop() if self.failed: return # $ANTLR end synpred7 # $ANTLR start synpred10 def synpred10_fragment(self, ): # C.g:167:18: ( declaration_specifiers ) # C.g:167:18: declaration_specifiers self.following.append(self.FOLLOW_declaration_specifiers_in_synpred10207) self.declaration_specifiers() self.following.pop() if self.failed: return # $ANTLR end synpred10 # $ANTLR start synpred14 def synpred14_fragment(self, ): # C.g:184:7: ( type_specifier ) # C.g:184:7: type_specifier self.following.append(self.FOLLOW_type_specifier_in_synpred14272) self.type_specifier() self.following.pop() if self.failed: return # $ANTLR end synpred14 # $ANTLR start synpred15 def synpred15_fragment(self, ): # C.g:185:13: ( type_qualifier ) # C.g:185:13: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred15286) self.type_qualifier() self.following.pop() if self.failed: return # $ANTLR end synpred15 # $ANTLR start synpred33 def synpred33_fragment(self, ): # C.g:225:16: ( type_qualifier ) # C.g:225:16: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred33444) self.type_qualifier() self.following.pop() if self.failed: return # $ANTLR end synpred33 # $ANTLR start synpred34 def synpred34_fragment(self, ): # C.g:225:4: ( IDENTIFIER ( type_qualifier )* declarator ) # C.g:225:5: IDENTIFIER ( type_qualifier )* declarator self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_synpred34442) if self.failed: return # C.g:225:16: ( type_qualifier )* while True: #loop106 alt106 = 2 LA106 = self.input.LA(1) if LA106 == 58: LA106_2 = self.input.LA(2) if (self.synpred33()) : alt106 = 1 elif LA106 == 59: LA106_3 = self.input.LA(2) if (self.synpred33()) : alt106 = 1 elif LA106 == 60: LA106_4 = self.input.LA(2) if (self.synpred33()) : alt106 = 1 elif LA106 == 49 or LA106 == 50 or LA106 == 51 or LA106 == 52 or LA106 == 53 or LA106 == 54 or LA106 == 55 or LA106 == 56 or LA106 == 57 or LA106 == 61: alt106 = 1 if alt106 == 1: # C.g:0:0: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred34444) self.type_qualifier() self.following.pop() if self.failed: return else: break #loop106 self.following.append(self.FOLLOW_declarator_in_synpred34447) self.declarator() self.following.pop() if self.failed: return # $ANTLR end synpred34 # $ANTLR start synpred39 def synpred39_fragment(self, ): # C.g:253:6: ( type_qualifier ) # C.g:253:6: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred39566) self.type_qualifier() self.following.pop() if self.failed: return # $ANTLR end synpred39 # $ANTLR start synpred40 def synpred40_fragment(self, ): # C.g:253:23: ( type_specifier ) # C.g:253:23: type_specifier self.following.append(self.FOLLOW_type_specifier_in_synpred40570) self.type_specifier() self.following.pop() if self.failed: return # $ANTLR end synpred40 # $ANTLR start synpred66 def synpred66_fragment(self, ): # C.g:297:4: ( ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator ) # C.g:297:4: ( pointer )? ( 'EFIAPI' )? ( 'EFI_BOOTSERVICE' )? ( 'EFI_RUNTIMESERVICE' )? direct_declarator # C.g:297:4: ( pointer )? alt111 = 2 LA111_0 = self.input.LA(1) if (LA111_0 == 66) : alt111 = 1 if alt111 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_synpred66784) self.pointer() self.following.pop() if self.failed: return # C.g:297:13: ( 'EFIAPI' )? alt112 = 2 LA112_0 = self.input.LA(1) if (LA112_0 == 58) : alt112 = 1 if alt112 == 1: # C.g:297:14: 'EFIAPI' self.match(self.input, 58, self.FOLLOW_58_in_synpred66788) if self.failed: return # C.g:297:25: ( 'EFI_BOOTSERVICE' )? alt113 = 2 LA113_0 = self.input.LA(1) if (LA113_0 == 59) : alt113 = 1 if alt113 == 1: # C.g:297:26: 'EFI_BOOTSERVICE' self.match(self.input, 59, self.FOLLOW_59_in_synpred66793) if self.failed: return # C.g:297:46: ( 'EFI_RUNTIMESERVICE' )? alt114 = 2 LA114_0 = self.input.LA(1) if (LA114_0 == 60) : alt114 = 1 if alt114 == 1: # C.g:297:47: 'EFI_RUNTIMESERVICE' self.match(self.input, 60, self.FOLLOW_60_in_synpred66798) if self.failed: return self.following.append(self.FOLLOW_direct_declarator_in_synpred66802) self.direct_declarator() self.following.pop() if self.failed: return # $ANTLR end synpred66 # $ANTLR start synpred67 def synpred67_fragment(self, ): # C.g:303:15: ( declarator_suffix ) # C.g:303:15: declarator_suffix self.following.append(self.FOLLOW_declarator_suffix_in_synpred67821) self.declarator_suffix() self.following.pop() if self.failed: return # $ANTLR end synpred67 # $ANTLR start synpred69 def synpred69_fragment(self, ): # C.g:304:9: ( 'EFIAPI' ) # C.g:304:9: 'EFIAPI' self.match(self.input, 58, self.FOLLOW_58_in_synpred69830) if self.failed: return # $ANTLR end synpred69 # $ANTLR start synpred70 def synpred70_fragment(self, ): # C.g:304:35: ( declarator_suffix ) # C.g:304:35: declarator_suffix self.following.append(self.FOLLOW_declarator_suffix_in_synpred70838) self.declarator_suffix() self.following.pop() if self.failed: return # $ANTLR end synpred70 # $ANTLR start synpred73 def synpred73_fragment(self, ): # C.g:310:9: ( '(' parameter_type_list ')' ) # C.g:310:9: '(' parameter_type_list ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred73878) if self.failed: return self.following.append(self.FOLLOW_parameter_type_list_in_synpred73880) self.parameter_type_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred73882) if self.failed: return # $ANTLR end synpred73 # $ANTLR start synpred74 def synpred74_fragment(self, ): # C.g:311:9: ( '(' identifier_list ')' ) # C.g:311:9: '(' identifier_list ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred74892) if self.failed: return self.following.append(self.FOLLOW_identifier_list_in_synpred74894) self.identifier_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred74896) if self.failed: return # $ANTLR end synpred74 # $ANTLR start synpred75 def synpred75_fragment(self, ): # C.g:316:8: ( type_qualifier ) # C.g:316:8: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred75921) self.type_qualifier() self.following.pop() if self.failed: return # $ANTLR end synpred75 # $ANTLR start synpred76 def synpred76_fragment(self, ): # C.g:316:24: ( pointer ) # C.g:316:24: pointer self.following.append(self.FOLLOW_pointer_in_synpred76924) self.pointer() self.following.pop() if self.failed: return # $ANTLR end synpred76 # $ANTLR start synpred77 def synpred77_fragment(self, ): # C.g:316:4: ( '*' ( type_qualifier )+ ( pointer )? ) # C.g:316:4: '*' ( type_qualifier )+ ( pointer )? self.match(self.input, 66, self.FOLLOW_66_in_synpred77919) if self.failed: return # C.g:316:8: ( type_qualifier )+ cnt116 = 0 while True: #loop116 alt116 = 2 LA116_0 = self.input.LA(1) if ((49 <= LA116_0 <= 61)) : alt116 = 1 if alt116 == 1: # C.g:0:0: type_qualifier self.following.append(self.FOLLOW_type_qualifier_in_synpred77921) self.type_qualifier() self.following.pop() if self.failed: return else: if cnt116 >= 1: break #loop116 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(116, self.input) raise eee cnt116 += 1 # C.g:316:24: ( pointer )? alt117 = 2 LA117_0 = self.input.LA(1) if (LA117_0 == 66) : alt117 = 1 if alt117 == 1: # C.g:0:0: pointer self.following.append(self.FOLLOW_pointer_in_synpred77924) self.pointer() self.following.pop() if self.failed: return # $ANTLR end synpred77 # $ANTLR start synpred78 def synpred78_fragment(self, ): # C.g:317:4: ( '*' pointer ) # C.g:317:4: '*' pointer self.match(self.input, 66, self.FOLLOW_66_in_synpred78930) if self.failed: return self.following.append(self.FOLLOW_pointer_in_synpred78932) self.pointer() self.following.pop() if self.failed: return # $ANTLR end synpred78 # $ANTLR start synpred81 def synpred81_fragment(self, ): # C.g:326:32: ( 'OPTIONAL' ) # C.g:326:32: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_synpred81977) if self.failed: return # $ANTLR end synpred81 # $ANTLR start synpred82 def synpred82_fragment(self, ): # C.g:326:27: ( ',' ( 'OPTIONAL' )? parameter_declaration ) # C.g:326:27: ',' ( 'OPTIONAL' )? parameter_declaration self.match(self.input, 27, self.FOLLOW_27_in_synpred82974) if self.failed: return # C.g:326:31: ( 'OPTIONAL' )? alt119 = 2 LA119_0 = self.input.LA(1) if (LA119_0 == 53) : LA119_1 = self.input.LA(2) if (self.synpred81()) : alt119 = 1 if alt119 == 1: # C.g:326:32: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_synpred82977) if self.failed: return self.following.append(self.FOLLOW_parameter_declaration_in_synpred82981) self.parameter_declaration() self.following.pop() if self.failed: return # $ANTLR end synpred82 # $ANTLR start synpred83 def synpred83_fragment(self, ): # C.g:330:28: ( declarator ) # C.g:330:28: declarator self.following.append(self.FOLLOW_declarator_in_synpred83997) self.declarator() self.following.pop() if self.failed: return # $ANTLR end synpred83 # $ANTLR start synpred84 def synpred84_fragment(self, ): # C.g:330:39: ( abstract_declarator ) # C.g:330:39: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_synpred84999) self.abstract_declarator() self.following.pop() if self.failed: return # $ANTLR end synpred84 # $ANTLR start synpred86 def synpred86_fragment(self, ): # C.g:330:4: ( declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? ) # C.g:330:4: declaration_specifiers ( declarator | abstract_declarator )* ( 'OPTIONAL' )? self.following.append(self.FOLLOW_declaration_specifiers_in_synpred86994) self.declaration_specifiers() self.following.pop() if self.failed: return # C.g:330:27: ( declarator | abstract_declarator )* while True: #loop120 alt120 = 3 LA120 = self.input.LA(1) if LA120 == 66: LA120_3 = self.input.LA(2) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == IDENTIFIER or LA120 == 58 or LA120 == 59 or LA120 == 60: alt120 = 1 elif LA120 == 62: LA120 = self.input.LA(2) if LA120 == 29 or LA120 == 30 or LA120 == 31 or LA120 == 32 or LA120 == 33 or LA120 == 34 or LA120 == 35 or LA120 == 36 or LA120 == 37 or LA120 == 38 or LA120 == 39 or LA120 == 40 or LA120 == 41 or LA120 == 42 or LA120 == 45 or LA120 == 46 or LA120 == 48 or LA120 == 49 or LA120 == 50 or LA120 == 51 or LA120 == 52 or LA120 == 53 or LA120 == 54 or LA120 == 55 or LA120 == 56 or LA120 == 57 or LA120 == 61 or LA120 == 63 or LA120 == 64: alt120 = 2 elif LA120 == 58: LA120_21 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 66: LA120_22 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 59: LA120_23 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 60: LA120_24 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == IDENTIFIER: LA120_25 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 62: LA120_26 = self.input.LA(3) if (self.synpred83()) : alt120 = 1 elif (self.synpred84()) : alt120 = 2 elif LA120 == 64: alt120 = 2 if alt120 == 1: # C.g:330:28: declarator self.following.append(self.FOLLOW_declarator_in_synpred86997) self.declarator() self.following.pop() if self.failed: return elif alt120 == 2: # C.g:330:39: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_synpred86999) self.abstract_declarator() self.following.pop() if self.failed: return else: break #loop120 # C.g:330:61: ( 'OPTIONAL' )? alt121 = 2 LA121_0 = self.input.LA(1) if (LA121_0 == 53) : alt121 = 1 if alt121 == 1: # C.g:330:62: 'OPTIONAL' self.match(self.input, 53, self.FOLLOW_53_in_synpred861004) if self.failed: return # $ANTLR end synpred86 # $ANTLR start synpred90 def synpred90_fragment(self, ): # C.g:341:4: ( specifier_qualifier_list ( abstract_declarator )? ) # C.g:341:4: specifier_qualifier_list ( abstract_declarator )? self.following.append(self.FOLLOW_specifier_qualifier_list_in_synpred901046) self.specifier_qualifier_list() self.following.pop() if self.failed: return # C.g:341:29: ( abstract_declarator )? alt122 = 2 LA122_0 = self.input.LA(1) if (LA122_0 == 62 or LA122_0 == 64 or LA122_0 == 66) : alt122 = 1 if alt122 == 1: # C.g:0:0: abstract_declarator self.following.append(self.FOLLOW_abstract_declarator_in_synpred901048) self.abstract_declarator() self.following.pop() if self.failed: return # $ANTLR end synpred90 # $ANTLR start synpred91 def synpred91_fragment(self, ): # C.g:346:12: ( direct_abstract_declarator ) # C.g:346:12: direct_abstract_declarator self.following.append(self.FOLLOW_direct_abstract_declarator_in_synpred911067) self.direct_abstract_declarator() self.following.pop() if self.failed: return # $ANTLR end synpred91 # $ANTLR start synpred93 def synpred93_fragment(self, ): # C.g:351:6: ( '(' abstract_declarator ')' ) # C.g:351:6: '(' abstract_declarator ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred931086) if self.failed: return self.following.append(self.FOLLOW_abstract_declarator_in_synpred931088) self.abstract_declarator() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred931090) if self.failed: return # $ANTLR end synpred93 # $ANTLR start synpred94 def synpred94_fragment(self, ): # C.g:351:65: ( abstract_declarator_suffix ) # C.g:351:65: abstract_declarator_suffix self.following.append(self.FOLLOW_abstract_declarator_suffix_in_synpred941098) self.abstract_declarator_suffix() self.following.pop() if self.failed: return # $ANTLR end synpred94 # $ANTLR start synpred109 def synpred109_fragment(self, ): # C.g:386:4: ( '(' type_name ')' cast_expression ) # C.g:386:4: '(' type_name ')' cast_expression self.match(self.input, 62, self.FOLLOW_62_in_synpred1091282) if self.failed: return self.following.append(self.FOLLOW_type_name_in_synpred1091284) self.type_name() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred1091286) if self.failed: return self.following.append(self.FOLLOW_cast_expression_in_synpred1091288) self.cast_expression() self.following.pop() if self.failed: return # $ANTLR end synpred109 # $ANTLR start synpred114 def synpred114_fragment(self, ): # C.g:395:4: ( 'sizeof' unary_expression ) # C.g:395:4: 'sizeof' unary_expression self.match(self.input, 74, self.FOLLOW_74_in_synpred1141330) if self.failed: return self.following.append(self.FOLLOW_unary_expression_in_synpred1141332) self.unary_expression() self.following.pop() if self.failed: return # $ANTLR end synpred114 # $ANTLR start synpred117 def synpred117_fragment(self, ): # C.g:409:13: ( '(' argument_expression_list ')' ) # C.g:409:13: '(' argument_expression_list ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred1171420) if self.failed: return self.following.append(self.FOLLOW_argument_expression_list_in_synpred1171424) self.argument_expression_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred1171428) if self.failed: return # $ANTLR end synpred117 # $ANTLR start synpred118 def synpred118_fragment(self, ): # C.g:410:13: ( '(' macro_parameter_list ')' ) # C.g:410:13: '(' macro_parameter_list ')' self.match(self.input, 62, self.FOLLOW_62_in_synpred1181444) if self.failed: return self.following.append(self.FOLLOW_macro_parameter_list_in_synpred1181446) self.macro_parameter_list() self.following.pop() if self.failed: return self.match(self.input, 63, self.FOLLOW_63_in_synpred1181448) if self.failed: return # $ANTLR end synpred118 # $ANTLR start synpred120 def synpred120_fragment(self, ): # C.g:412:13: ( '*' IDENTIFIER ) # C.g:412:13: '*' IDENTIFIER self.match(self.input, 66, self.FOLLOW_66_in_synpred1201482) if self.failed: return self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_synpred1201486) if self.failed: return # $ANTLR end synpred120 # $ANTLR start synpred137 def synpred137_fragment(self, ): # C.g:443:20: ( STRING_LITERAL ) # C.g:443:20: STRING_LITERAL self.match(self.input, STRING_LITERAL, self.FOLLOW_STRING_LITERAL_in_synpred1371683) if self.failed: return # $ANTLR end synpred137 # $ANTLR start synpred138 def synpred138_fragment(self, ): # C.g:443:8: ( ( IDENTIFIER )* ( STRING_LITERAL )+ ) # C.g:443:8: ( IDENTIFIER )* ( STRING_LITERAL )+ # C.g:443:8: ( IDENTIFIER )* while True: #loop125 alt125 = 2 LA125_0 = self.input.LA(1) if (LA125_0 == IDENTIFIER) : alt125 = 1 if alt125 == 1: # C.g:0:0: IDENTIFIER self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_synpred1381680) if self.failed: return else: break #loop125 # C.g:443:20: ( STRING_LITERAL )+ cnt126 = 0 while True: #loop126 alt126 = 2 LA126_0 = self.input.LA(1) if (LA126_0 == STRING_LITERAL) : alt126 = 1 if alt126 == 1: # C.g:0:0: STRING_LITERAL self.match(self.input, STRING_LITERAL, self.FOLLOW_STRING_LITERAL_in_synpred1381683) if self.failed: return else: if cnt126 >= 1: break #loop126 if self.backtracking > 0: self.failed = True return eee = EarlyExitException(126, self.input) raise eee cnt126 += 1 # $ANTLR end synpred138 # $ANTLR start synpred142 def synpred142_fragment(self, ): # C.g:458:4: ( lvalue assignment_operator assignment_expression ) # C.g:458:4: lvalue assignment_operator assignment_expression self.following.append(self.FOLLOW_lvalue_in_synpred1421744) self.lvalue() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_assignment_operator_in_synpred1421746) self.assignment_operator() self.following.pop() if self.failed: return self.following.append(self.FOLLOW_assignment_expression_in_synpred1421748) self.assignment_expression() self.following.pop() if self.failed: return # $ANTLR end synpred142 # $ANTLR start synpred169 def synpred169_fragment(self, ): # C.g:520:4: ( expression_statement ) # C.g:520:4: expression_statement self.following.append(self.FOLLOW_expression_statement_in_synpred1692035) self.expression_statement() self.following.pop() if self.failed: return # $ANTLR end synpred169 # $ANTLR start synpred173 def synpred173_fragment(self, ): # C.g:524:4: ( macro_statement ) # C.g:524:4: macro_statement self.following.append(self.FOLLOW_macro_statement_in_synpred1732055) self.macro_statement() self.following.pop() if self.failed: return # $ANTLR end synpred173 # $ANTLR start synpred174 def synpred174_fragment(self, ): # C.g:525:4: ( asm2_statement ) # C.g:525:4: asm2_statement self.following.append(self.FOLLOW_asm2_statement_in_synpred1742060) self.asm2_statement() self.following.pop() if self.failed: return # $ANTLR end synpred174 # $ANTLR start synpred181 def synpred181_fragment(self, ): # C.g:544:19: ( declaration ) # C.g:544:19: declaration self.following.append(self.FOLLOW_declaration_in_synpred1812166) self.declaration() self.following.pop() if self.failed: return # $ANTLR end synpred181 # $ANTLR start synpred182 def synpred182_fragment(self, ): # C.g:544:33: ( statement_list ) # C.g:544:33: statement_list self.following.append(self.FOLLOW_statement_list_in_synpred1822170) self.statement_list() self.following.pop() if self.failed: return # $ANTLR end synpred182 # $ANTLR start synpred186 def synpred186_fragment(self, ): # C.g:554:8: ( declaration ) # C.g:554:8: declaration self.following.append(self.FOLLOW_declaration_in_synpred1862225) self.declaration() self.following.pop() if self.failed: return # $ANTLR end synpred186 # $ANTLR start synpred188 def synpred188_fragment(self, ): # C.g:558:4: ( statement ) # C.g:558:4: statement self.following.append(self.FOLLOW_statement_in_synpred1882242) self.statement() self.following.pop() if self.failed: return # $ANTLR end synpred188 def synpred69(self): self.backtracking += 1 start = self.input.mark() self.synpred69_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred81(self): self.backtracking += 1 start = self.input.mark() self.synpred81_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred82(self): self.backtracking += 1 start = self.input.mark() self.synpred82_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred66(self): self.backtracking += 1 start = self.input.mark() self.synpred66_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred83(self): self.backtracking += 1 start = self.input.mark() self.synpred83_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred84(self): self.backtracking += 1 start = self.input.mark() self.synpred84_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred67(self): self.backtracking += 1 start = self.input.mark() self.synpred67_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred86(self): self.backtracking += 1 start = self.input.mark() self.synpred86_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred120(self): self.backtracking += 1 start = self.input.mark() self.synpred120_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred40(self): self.backtracking += 1 start = self.input.mark() self.synpred40_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred142(self): self.backtracking += 1 start = self.input.mark() self.synpred142_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred182(self): self.backtracking += 1 start = self.input.mark() self.synpred182_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred109(self): self.backtracking += 1 start = self.input.mark() self.synpred109_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred181(self): self.backtracking += 1 start = self.input.mark() self.synpred181_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred186(self): self.backtracking += 1 start = self.input.mark() self.synpred186_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred188(self): self.backtracking += 1 start = self.input.mark() self.synpred188_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred169(self): self.backtracking += 1 start = self.input.mark() self.synpred169_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred117(self): self.backtracking += 1 start = self.input.mark() self.synpred117_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred70(self): self.backtracking += 1 start = self.input.mark() self.synpred70_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred118(self): self.backtracking += 1 start = self.input.mark() self.synpred118_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred34(self): self.backtracking += 1 start = self.input.mark() self.synpred34_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred33(self): self.backtracking += 1 start = self.input.mark() self.synpred33_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred94(self): self.backtracking += 1 start = self.input.mark() self.synpred94_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred39(self): self.backtracking += 1 start = self.input.mark() self.synpred39_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred74(self): self.backtracking += 1 start = self.input.mark() self.synpred74_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred114(self): self.backtracking += 1 start = self.input.mark() self.synpred114_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred93(self): self.backtracking += 1 start = self.input.mark() self.synpred93_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred75(self): self.backtracking += 1 start = self.input.mark() self.synpred75_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred137(self): self.backtracking += 1 start = self.input.mark() self.synpred137_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred90(self): self.backtracking += 1 start = self.input.mark() self.synpred90_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred138(self): self.backtracking += 1 start = self.input.mark() self.synpred138_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred91(self): self.backtracking += 1 start = self.input.mark() self.synpred91_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred73(self): self.backtracking += 1 start = self.input.mark() self.synpred73_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred5(self): self.backtracking += 1 start = self.input.mark() self.synpred5_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred78(self): self.backtracking += 1 start = self.input.mark() self.synpred78_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred7(self): self.backtracking += 1 start = self.input.mark() self.synpred7_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred76(self): self.backtracking += 1 start = self.input.mark() self.synpred76_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred77(self): self.backtracking += 1 start = self.input.mark() self.synpred77_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred2(self): self.backtracking += 1 start = self.input.mark() self.synpred2_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred4(self): self.backtracking += 1 start = self.input.mark() self.synpred4_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred174(self): self.backtracking += 1 start = self.input.mark() self.synpred174_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred173(self): self.backtracking += 1 start = self.input.mark() self.synpred173_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred14(self): self.backtracking += 1 start = self.input.mark() self.synpred14_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred15(self): self.backtracking += 1 start = self.input.mark() self.synpred15_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success def synpred10(self): self.backtracking += 1 start = self.input.mark() self.synpred10_fragment() success = not self.failed self.input.rewind(start) self.backtracking -= 1 self.failed = False return success FOLLOW_external_declaration_in_translation_unit74 = frozenset([1, 4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66]) FOLLOW_function_definition_in_external_declaration113 = frozenset([1]) FOLLOW_declaration_in_external_declaration118 = frozenset([1]) FOLLOW_macro_statement_in_external_declaration123 = frozenset([1, 25]) FOLLOW_25_in_external_declaration126 = frozenset([1]) FOLLOW_declaration_specifiers_in_function_definition157 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_declarator_in_function_definition160 = frozenset([4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_declaration_in_function_definition166 = frozenset([4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_compound_statement_in_function_definition171 = frozenset([1]) FOLLOW_compound_statement_in_function_definition180 = frozenset([1]) FOLLOW_26_in_declaration203 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66]) FOLLOW_declaration_specifiers_in_declaration207 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_init_declarator_list_in_declaration216 = frozenset([25]) FOLLOW_25_in_declaration220 = frozenset([1]) FOLLOW_declaration_specifiers_in_declaration234 = frozenset([4, 25, 58, 59, 60, 62, 66]) FOLLOW_init_declarator_list_in_declaration238 = frozenset([25]) FOLLOW_25_in_declaration243 = frozenset([1]) FOLLOW_storage_class_specifier_in_declaration_specifiers264 = frozenset([1, 4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_specifier_in_declaration_specifiers272 = frozenset([1, 4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_qualifier_in_declaration_specifiers286 = frozenset([1, 4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_init_declarator_in_init_declarator_list308 = frozenset([1, 27]) FOLLOW_27_in_init_declarator_list311 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_init_declarator_in_init_declarator_list313 = frozenset([1, 27]) FOLLOW_declarator_in_init_declarator326 = frozenset([1, 28]) FOLLOW_28_in_init_declarator329 = frozenset([4, 5, 6, 7, 8, 9, 10, 43, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_initializer_in_init_declarator331 = frozenset([1]) FOLLOW_set_in_storage_class_specifier0 = frozenset([1]) FOLLOW_34_in_type_specifier376 = frozenset([1]) FOLLOW_35_in_type_specifier381 = frozenset([1]) FOLLOW_36_in_type_specifier386 = frozenset([1]) FOLLOW_37_in_type_specifier391 = frozenset([1]) FOLLOW_38_in_type_specifier396 = frozenset([1]) FOLLOW_39_in_type_specifier401 = frozenset([1]) FOLLOW_40_in_type_specifier406 = frozenset([1]) FOLLOW_41_in_type_specifier411 = frozenset([1]) FOLLOW_42_in_type_specifier416 = frozenset([1]) FOLLOW_struct_or_union_specifier_in_type_specifier423 = frozenset([1]) FOLLOW_enum_specifier_in_type_specifier433 = frozenset([1]) FOLLOW_type_id_in_type_specifier451 = frozenset([1]) FOLLOW_IDENTIFIER_in_type_id467 = frozenset([1]) FOLLOW_struct_or_union_in_struct_or_union_specifier494 = frozenset([4, 43]) FOLLOW_IDENTIFIER_in_struct_or_union_specifier496 = frozenset([43]) FOLLOW_43_in_struct_or_union_specifier499 = frozenset([4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_struct_declaration_list_in_struct_or_union_specifier501 = frozenset([44]) FOLLOW_44_in_struct_or_union_specifier503 = frozenset([1]) FOLLOW_struct_or_union_in_struct_or_union_specifier508 = frozenset([4]) FOLLOW_IDENTIFIER_in_struct_or_union_specifier510 = frozenset([1]) FOLLOW_set_in_struct_or_union0 = frozenset([1]) FOLLOW_struct_declaration_in_struct_declaration_list537 = frozenset([1, 4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_specifier_qualifier_list_in_struct_declaration549 = frozenset([4, 47, 58, 59, 60, 62, 66]) FOLLOW_struct_declarator_list_in_struct_declaration551 = frozenset([25]) FOLLOW_25_in_struct_declaration553 = frozenset([1]) FOLLOW_type_qualifier_in_specifier_qualifier_list566 = frozenset([1, 4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_specifier_in_specifier_qualifier_list570 = frozenset([1, 4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_struct_declarator_in_struct_declarator_list584 = frozenset([1, 27]) FOLLOW_27_in_struct_declarator_list587 = frozenset([4, 47, 58, 59, 60, 62, 66]) FOLLOW_struct_declarator_in_struct_declarator_list589 = frozenset([1, 27]) FOLLOW_declarator_in_struct_declarator602 = frozenset([1, 47]) FOLLOW_47_in_struct_declarator605 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_struct_declarator607 = frozenset([1]) FOLLOW_47_in_struct_declarator614 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_struct_declarator616 = frozenset([1]) FOLLOW_48_in_enum_specifier634 = frozenset([43]) FOLLOW_43_in_enum_specifier636 = frozenset([4]) FOLLOW_enumerator_list_in_enum_specifier638 = frozenset([27, 44]) FOLLOW_27_in_enum_specifier640 = frozenset([44]) FOLLOW_44_in_enum_specifier643 = frozenset([1]) FOLLOW_48_in_enum_specifier648 = frozenset([4]) FOLLOW_IDENTIFIER_in_enum_specifier650 = frozenset([43]) FOLLOW_43_in_enum_specifier652 = frozenset([4]) FOLLOW_enumerator_list_in_enum_specifier654 = frozenset([27, 44]) FOLLOW_27_in_enum_specifier656 = frozenset([44]) FOLLOW_44_in_enum_specifier659 = frozenset([1]) FOLLOW_48_in_enum_specifier664 = frozenset([4]) FOLLOW_IDENTIFIER_in_enum_specifier666 = frozenset([1]) FOLLOW_enumerator_in_enumerator_list677 = frozenset([1, 27]) FOLLOW_27_in_enumerator_list680 = frozenset([4]) FOLLOW_enumerator_in_enumerator_list682 = frozenset([1, 27]) FOLLOW_IDENTIFIER_in_enumerator695 = frozenset([1, 28]) FOLLOW_28_in_enumerator698 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_enumerator700 = frozenset([1]) FOLLOW_set_in_type_qualifier0 = frozenset([1]) FOLLOW_pointer_in_declarator784 = frozenset([4, 58, 59, 60, 62]) FOLLOW_58_in_declarator788 = frozenset([4, 59, 60, 62]) FOLLOW_59_in_declarator793 = frozenset([4, 60, 62]) FOLLOW_60_in_declarator798 = frozenset([4, 62]) FOLLOW_direct_declarator_in_declarator802 = frozenset([1]) FOLLOW_pointer_in_declarator808 = frozenset([1]) FOLLOW_IDENTIFIER_in_direct_declarator819 = frozenset([1, 62, 64]) FOLLOW_declarator_suffix_in_direct_declarator821 = frozenset([1, 62, 64]) FOLLOW_62_in_direct_declarator827 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_58_in_direct_declarator830 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_declarator_in_direct_declarator834 = frozenset([63]) FOLLOW_63_in_direct_declarator836 = frozenset([62, 64]) FOLLOW_declarator_suffix_in_direct_declarator838 = frozenset([1, 62, 64]) FOLLOW_64_in_declarator_suffix852 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_declarator_suffix854 = frozenset([65]) FOLLOW_65_in_declarator_suffix856 = frozenset([1]) FOLLOW_64_in_declarator_suffix866 = frozenset([65]) FOLLOW_65_in_declarator_suffix868 = frozenset([1]) FOLLOW_62_in_declarator_suffix878 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_type_list_in_declarator_suffix880 = frozenset([63]) FOLLOW_63_in_declarator_suffix882 = frozenset([1]) FOLLOW_62_in_declarator_suffix892 = frozenset([4]) FOLLOW_identifier_list_in_declarator_suffix894 = frozenset([63]) FOLLOW_63_in_declarator_suffix896 = frozenset([1]) FOLLOW_62_in_declarator_suffix906 = frozenset([63]) FOLLOW_63_in_declarator_suffix908 = frozenset([1]) FOLLOW_66_in_pointer919 = frozenset([49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_qualifier_in_pointer921 = frozenset([1, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_pointer_in_pointer924 = frozenset([1]) FOLLOW_66_in_pointer930 = frozenset([66]) FOLLOW_pointer_in_pointer932 = frozenset([1]) FOLLOW_66_in_pointer937 = frozenset([1]) FOLLOW_parameter_list_in_parameter_type_list948 = frozenset([1, 27]) FOLLOW_27_in_parameter_type_list951 = frozenset([53, 67]) FOLLOW_53_in_parameter_type_list954 = frozenset([67]) FOLLOW_67_in_parameter_type_list958 = frozenset([1]) FOLLOW_parameter_declaration_in_parameter_list971 = frozenset([1, 27]) FOLLOW_27_in_parameter_list974 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_53_in_parameter_list977 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_declaration_in_parameter_list981 = frozenset([1, 27]) FOLLOW_declaration_specifiers_in_parameter_declaration994 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_declarator_in_parameter_declaration997 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_abstract_declarator_in_parameter_declaration999 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_53_in_parameter_declaration1004 = frozenset([1]) FOLLOW_pointer_in_parameter_declaration1013 = frozenset([4, 66]) FOLLOW_IDENTIFIER_in_parameter_declaration1016 = frozenset([1]) FOLLOW_IDENTIFIER_in_identifier_list1027 = frozenset([1, 27]) FOLLOW_27_in_identifier_list1031 = frozenset([4]) FOLLOW_IDENTIFIER_in_identifier_list1033 = frozenset([1, 27]) FOLLOW_specifier_qualifier_list_in_type_name1046 = frozenset([1, 62, 64, 66]) FOLLOW_abstract_declarator_in_type_name1048 = frozenset([1]) FOLLOW_type_id_in_type_name1054 = frozenset([1]) FOLLOW_pointer_in_abstract_declarator1065 = frozenset([1, 62, 64]) FOLLOW_direct_abstract_declarator_in_abstract_declarator1067 = frozenset([1]) FOLLOW_direct_abstract_declarator_in_abstract_declarator1073 = frozenset([1]) FOLLOW_62_in_direct_abstract_declarator1086 = frozenset([62, 64, 66]) FOLLOW_abstract_declarator_in_direct_abstract_declarator1088 = frozenset([63]) FOLLOW_63_in_direct_abstract_declarator1090 = frozenset([1, 62, 64]) FOLLOW_abstract_declarator_suffix_in_direct_abstract_declarator1094 = frozenset([1, 62, 64]) FOLLOW_abstract_declarator_suffix_in_direct_abstract_declarator1098 = frozenset([1, 62, 64]) FOLLOW_64_in_abstract_declarator_suffix1110 = frozenset([65]) FOLLOW_65_in_abstract_declarator_suffix1112 = frozenset([1]) FOLLOW_64_in_abstract_declarator_suffix1117 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_abstract_declarator_suffix1119 = frozenset([65]) FOLLOW_65_in_abstract_declarator_suffix1121 = frozenset([1]) FOLLOW_62_in_abstract_declarator_suffix1126 = frozenset([63]) FOLLOW_63_in_abstract_declarator_suffix1128 = frozenset([1]) FOLLOW_62_in_abstract_declarator_suffix1133 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_type_list_in_abstract_declarator_suffix1135 = frozenset([63]) FOLLOW_63_in_abstract_declarator_suffix1137 = frozenset([1]) FOLLOW_assignment_expression_in_initializer1150 = frozenset([1]) FOLLOW_43_in_initializer1155 = frozenset([4, 5, 6, 7, 8, 9, 10, 43, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_initializer_list_in_initializer1157 = frozenset([27, 44]) FOLLOW_27_in_initializer1159 = frozenset([44]) FOLLOW_44_in_initializer1162 = frozenset([1]) FOLLOW_initializer_in_initializer_list1173 = frozenset([1, 27]) FOLLOW_27_in_initializer_list1176 = frozenset([4, 5, 6, 7, 8, 9, 10, 43, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_initializer_in_initializer_list1178 = frozenset([1, 27]) FOLLOW_assignment_expression_in_argument_expression_list1196 = frozenset([1, 27, 53]) FOLLOW_53_in_argument_expression_list1199 = frozenset([1, 27]) FOLLOW_27_in_argument_expression_list1204 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_assignment_expression_in_argument_expression_list1206 = frozenset([1, 27, 53]) FOLLOW_53_in_argument_expression_list1209 = frozenset([1, 27]) FOLLOW_multiplicative_expression_in_additive_expression1225 = frozenset([1, 68, 69]) FOLLOW_68_in_additive_expression1229 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_multiplicative_expression_in_additive_expression1231 = frozenset([1, 68, 69]) FOLLOW_69_in_additive_expression1235 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_multiplicative_expression_in_additive_expression1237 = frozenset([1, 68, 69]) FOLLOW_cast_expression_in_multiplicative_expression1251 = frozenset([1, 66, 70, 71]) FOLLOW_66_in_multiplicative_expression1255 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_multiplicative_expression1257 = frozenset([1, 66, 70, 71]) FOLLOW_70_in_multiplicative_expression1261 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_multiplicative_expression1263 = frozenset([1, 66, 70, 71]) FOLLOW_71_in_multiplicative_expression1267 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_multiplicative_expression1269 = frozenset([1, 66, 70, 71]) FOLLOW_62_in_cast_expression1282 = frozenset([4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_name_in_cast_expression1284 = frozenset([63]) FOLLOW_63_in_cast_expression1286 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_cast_expression1288 = frozenset([1]) FOLLOW_unary_expression_in_cast_expression1293 = frozenset([1]) FOLLOW_postfix_expression_in_unary_expression1304 = frozenset([1]) FOLLOW_72_in_unary_expression1309 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_unary_expression_in_unary_expression1311 = frozenset([1]) FOLLOW_73_in_unary_expression1316 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_unary_expression_in_unary_expression1318 = frozenset([1]) FOLLOW_unary_operator_in_unary_expression1323 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_unary_expression1325 = frozenset([1]) FOLLOW_74_in_unary_expression1330 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_unary_expression_in_unary_expression1332 = frozenset([1]) FOLLOW_74_in_unary_expression1337 = frozenset([62]) FOLLOW_62_in_unary_expression1339 = frozenset([4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_name_in_unary_expression1341 = frozenset([63]) FOLLOW_63_in_unary_expression1343 = frozenset([1]) FOLLOW_primary_expression_in_postfix_expression1367 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_64_in_postfix_expression1383 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_postfix_expression1385 = frozenset([65]) FOLLOW_65_in_postfix_expression1387 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_62_in_postfix_expression1401 = frozenset([63]) FOLLOW_63_in_postfix_expression1405 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_62_in_postfix_expression1420 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_argument_expression_list_in_postfix_expression1424 = frozenset([63]) FOLLOW_63_in_postfix_expression1428 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_62_in_postfix_expression1444 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_macro_parameter_list_in_postfix_expression1446 = frozenset([63]) FOLLOW_63_in_postfix_expression1448 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_75_in_postfix_expression1462 = frozenset([4]) FOLLOW_IDENTIFIER_in_postfix_expression1466 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_66_in_postfix_expression1482 = frozenset([4]) FOLLOW_IDENTIFIER_in_postfix_expression1486 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_76_in_postfix_expression1502 = frozenset([4]) FOLLOW_IDENTIFIER_in_postfix_expression1506 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_72_in_postfix_expression1522 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_73_in_postfix_expression1536 = frozenset([1, 62, 64, 66, 72, 73, 75, 76]) FOLLOW_parameter_declaration_in_macro_parameter_list1559 = frozenset([1, 27]) FOLLOW_27_in_macro_parameter_list1562 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_declaration_in_macro_parameter_list1564 = frozenset([1, 27]) FOLLOW_set_in_unary_operator0 = frozenset([1]) FOLLOW_IDENTIFIER_in_primary_expression1613 = frozenset([1]) FOLLOW_constant_in_primary_expression1618 = frozenset([1]) FOLLOW_62_in_primary_expression1623 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_primary_expression1625 = frozenset([63]) FOLLOW_63_in_primary_expression1627 = frozenset([1]) FOLLOW_HEX_LITERAL_in_constant1643 = frozenset([1]) FOLLOW_OCTAL_LITERAL_in_constant1653 = frozenset([1]) FOLLOW_DECIMAL_LITERAL_in_constant1663 = frozenset([1]) FOLLOW_CHARACTER_LITERAL_in_constant1671 = frozenset([1]) FOLLOW_IDENTIFIER_in_constant1680 = frozenset([4, 9]) FOLLOW_STRING_LITERAL_in_constant1683 = frozenset([1, 4, 9]) FOLLOW_IDENTIFIER_in_constant1688 = frozenset([1, 4]) FOLLOW_FLOATING_POINT_LITERAL_in_constant1699 = frozenset([1]) FOLLOW_assignment_expression_in_expression1715 = frozenset([1, 27]) FOLLOW_27_in_expression1718 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_assignment_expression_in_expression1720 = frozenset([1, 27]) FOLLOW_conditional_expression_in_constant_expression1733 = frozenset([1]) FOLLOW_lvalue_in_assignment_expression1744 = frozenset([28, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89]) FOLLOW_assignment_operator_in_assignment_expression1746 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_assignment_expression_in_assignment_expression1748 = frozenset([1]) FOLLOW_conditional_expression_in_assignment_expression1753 = frozenset([1]) FOLLOW_unary_expression_in_lvalue1765 = frozenset([1]) FOLLOW_set_in_assignment_operator0 = frozenset([1]) FOLLOW_logical_or_expression_in_conditional_expression1839 = frozenset([1, 90]) FOLLOW_90_in_conditional_expression1842 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_conditional_expression1844 = frozenset([47]) FOLLOW_47_in_conditional_expression1846 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_conditional_expression_in_conditional_expression1848 = frozenset([1]) FOLLOW_logical_and_expression_in_logical_or_expression1863 = frozenset([1, 91]) FOLLOW_91_in_logical_or_expression1866 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_logical_and_expression_in_logical_or_expression1868 = frozenset([1, 91]) FOLLOW_inclusive_or_expression_in_logical_and_expression1881 = frozenset([1, 92]) FOLLOW_92_in_logical_and_expression1884 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_inclusive_or_expression_in_logical_and_expression1886 = frozenset([1, 92]) FOLLOW_exclusive_or_expression_in_inclusive_or_expression1899 = frozenset([1, 93]) FOLLOW_93_in_inclusive_or_expression1902 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_exclusive_or_expression_in_inclusive_or_expression1904 = frozenset([1, 93]) FOLLOW_and_expression_in_exclusive_or_expression1917 = frozenset([1, 94]) FOLLOW_94_in_exclusive_or_expression1920 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_and_expression_in_exclusive_or_expression1922 = frozenset([1, 94]) FOLLOW_equality_expression_in_and_expression1935 = frozenset([1, 77]) FOLLOW_77_in_and_expression1938 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_equality_expression_in_and_expression1940 = frozenset([1, 77]) FOLLOW_relational_expression_in_equality_expression1952 = frozenset([1, 95, 96]) FOLLOW_set_in_equality_expression1955 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_relational_expression_in_equality_expression1961 = frozenset([1, 95, 96]) FOLLOW_shift_expression_in_relational_expression1975 = frozenset([1, 97, 98, 99, 100]) FOLLOW_set_in_relational_expression1978 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_shift_expression_in_relational_expression1988 = frozenset([1, 97, 98, 99, 100]) FOLLOW_additive_expression_in_shift_expression2001 = frozenset([1, 101, 102]) FOLLOW_set_in_shift_expression2004 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_additive_expression_in_shift_expression2010 = frozenset([1, 101, 102]) FOLLOW_labeled_statement_in_statement2025 = frozenset([1]) FOLLOW_compound_statement_in_statement2030 = frozenset([1]) FOLLOW_expression_statement_in_statement2035 = frozenset([1]) FOLLOW_selection_statement_in_statement2040 = frozenset([1]) FOLLOW_iteration_statement_in_statement2045 = frozenset([1]) FOLLOW_jump_statement_in_statement2050 = frozenset([1]) FOLLOW_macro_statement_in_statement2055 = frozenset([1]) FOLLOW_asm2_statement_in_statement2060 = frozenset([1]) FOLLOW_asm1_statement_in_statement2065 = frozenset([1]) FOLLOW_asm_statement_in_statement2070 = frozenset([1]) FOLLOW_declaration_in_statement2075 = frozenset([1]) FOLLOW_103_in_asm2_statement2086 = frozenset([4]) FOLLOW_IDENTIFIER_in_asm2_statement2089 = frozenset([62]) FOLLOW_62_in_asm2_statement2091 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_set_in_asm2_statement2094 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_63_in_asm2_statement2101 = frozenset([25]) FOLLOW_25_in_asm2_statement2103 = frozenset([1]) FOLLOW_104_in_asm1_statement2115 = frozenset([43]) FOLLOW_43_in_asm1_statement2117 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_set_in_asm1_statement2120 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_44_in_asm1_statement2127 = frozenset([1]) FOLLOW_105_in_asm_statement2138 = frozenset([43]) FOLLOW_43_in_asm_statement2140 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_set_in_asm_statement2143 = frozenset([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_44_in_asm_statement2150 = frozenset([1]) FOLLOW_IDENTIFIER_in_macro_statement2162 = frozenset([62]) FOLLOW_62_in_macro_statement2164 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_declaration_in_macro_statement2166 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_list_in_macro_statement2170 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 63, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_macro_statement2173 = frozenset([63]) FOLLOW_63_in_macro_statement2176 = frozenset([1]) FOLLOW_IDENTIFIER_in_labeled_statement2188 = frozenset([47]) FOLLOW_47_in_labeled_statement2190 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_labeled_statement2192 = frozenset([1]) FOLLOW_106_in_labeled_statement2197 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_constant_expression_in_labeled_statement2199 = frozenset([47]) FOLLOW_47_in_labeled_statement2201 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_labeled_statement2203 = frozenset([1]) FOLLOW_107_in_labeled_statement2208 = frozenset([47]) FOLLOW_47_in_labeled_statement2210 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_labeled_statement2212 = frozenset([1]) FOLLOW_43_in_compound_statement2223 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_declaration_in_compound_statement2225 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_list_in_compound_statement2228 = frozenset([44]) FOLLOW_44_in_compound_statement2231 = frozenset([1]) FOLLOW_statement_in_statement_list2242 = frozenset([1, 4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_25_in_expression_statement2254 = frozenset([1]) FOLLOW_expression_in_expression_statement2259 = frozenset([25]) FOLLOW_25_in_expression_statement2261 = frozenset([1]) FOLLOW_108_in_selection_statement2272 = frozenset([62]) FOLLOW_62_in_selection_statement2274 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_selection_statement2278 = frozenset([63]) FOLLOW_63_in_selection_statement2280 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_selection_statement2284 = frozenset([1, 109]) FOLLOW_109_in_selection_statement2299 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_selection_statement2301 = frozenset([1]) FOLLOW_110_in_selection_statement2308 = frozenset([62]) FOLLOW_62_in_selection_statement2310 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_selection_statement2312 = frozenset([63]) FOLLOW_63_in_selection_statement2314 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_selection_statement2316 = frozenset([1]) FOLLOW_111_in_iteration_statement2327 = frozenset([62]) FOLLOW_62_in_iteration_statement2329 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_iteration_statement2333 = frozenset([63]) FOLLOW_63_in_iteration_statement2335 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_iteration_statement2337 = frozenset([1]) FOLLOW_112_in_iteration_statement2344 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_iteration_statement2346 = frozenset([111]) FOLLOW_111_in_iteration_statement2348 = frozenset([62]) FOLLOW_62_in_iteration_statement2350 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_iteration_statement2354 = frozenset([63]) FOLLOW_63_in_iteration_statement2356 = frozenset([25]) FOLLOW_25_in_iteration_statement2358 = frozenset([1]) FOLLOW_113_in_iteration_statement2365 = frozenset([62]) FOLLOW_62_in_iteration_statement2367 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_statement_in_iteration_statement2369 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_statement_in_iteration_statement2373 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 63, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_iteration_statement2375 = frozenset([63]) FOLLOW_63_in_iteration_statement2378 = frozenset([4, 5, 6, 7, 8, 9, 10, 25, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79, 103, 104, 105, 106, 107, 108, 110, 111, 112, 113, 114, 115, 116, 117]) FOLLOW_statement_in_iteration_statement2380 = frozenset([1]) FOLLOW_114_in_jump_statement2393 = frozenset([4]) FOLLOW_IDENTIFIER_in_jump_statement2395 = frozenset([25]) FOLLOW_25_in_jump_statement2397 = frozenset([1]) FOLLOW_115_in_jump_statement2402 = frozenset([25]) FOLLOW_25_in_jump_statement2404 = frozenset([1]) FOLLOW_116_in_jump_statement2409 = frozenset([25]) FOLLOW_25_in_jump_statement2411 = frozenset([1]) FOLLOW_117_in_jump_statement2416 = frozenset([25]) FOLLOW_25_in_jump_statement2418 = frozenset([1]) FOLLOW_117_in_jump_statement2423 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_expression_in_jump_statement2425 = frozenset([25]) FOLLOW_25_in_jump_statement2427 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred2100 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred4100 = frozenset([4, 58, 59, 60, 62, 66]) FOLLOW_declarator_in_synpred4103 = frozenset([4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_declaration_in_synpred4105 = frozenset([4, 26, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_43_in_synpred4108 = frozenset([1]) FOLLOW_declaration_in_synpred5118 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred7157 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred10207 = frozenset([1]) FOLLOW_type_specifier_in_synpred14272 = frozenset([1]) FOLLOW_type_qualifier_in_synpred15286 = frozenset([1]) FOLLOW_type_qualifier_in_synpred33444 = frozenset([1]) FOLLOW_IDENTIFIER_in_synpred34442 = frozenset([4, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66]) FOLLOW_type_qualifier_in_synpred34444 = frozenset([4, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 66]) FOLLOW_declarator_in_synpred34447 = frozenset([1]) FOLLOW_type_qualifier_in_synpred39566 = frozenset([1]) FOLLOW_type_specifier_in_synpred40570 = frozenset([1]) FOLLOW_pointer_in_synpred66784 = frozenset([4, 58, 59, 60, 62]) FOLLOW_58_in_synpred66788 = frozenset([4, 59, 60, 62]) FOLLOW_59_in_synpred66793 = frozenset([4, 60, 62]) FOLLOW_60_in_synpred66798 = frozenset([4, 62]) FOLLOW_direct_declarator_in_synpred66802 = frozenset([1]) FOLLOW_declarator_suffix_in_synpred67821 = frozenset([1]) FOLLOW_58_in_synpred69830 = frozenset([1]) FOLLOW_declarator_suffix_in_synpred70838 = frozenset([1]) FOLLOW_62_in_synpred73878 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_type_list_in_synpred73880 = frozenset([63]) FOLLOW_63_in_synpred73882 = frozenset([1]) FOLLOW_62_in_synpred74892 = frozenset([4]) FOLLOW_identifier_list_in_synpred74894 = frozenset([63]) FOLLOW_63_in_synpred74896 = frozenset([1]) FOLLOW_type_qualifier_in_synpred75921 = frozenset([1]) FOLLOW_pointer_in_synpred76924 = frozenset([1]) FOLLOW_66_in_synpred77919 = frozenset([49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_qualifier_in_synpred77921 = frozenset([1, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_pointer_in_synpred77924 = frozenset([1]) FOLLOW_66_in_synpred78930 = frozenset([66]) FOLLOW_pointer_in_synpred78932 = frozenset([1]) FOLLOW_53_in_synpred81977 = frozenset([1]) FOLLOW_27_in_synpred82974 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_53_in_synpred82977 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_parameter_declaration_in_synpred82981 = frozenset([1]) FOLLOW_declarator_in_synpred83997 = frozenset([1]) FOLLOW_abstract_declarator_in_synpred84999 = frozenset([1]) FOLLOW_declaration_specifiers_in_synpred86994 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_declarator_in_synpred86997 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_abstract_declarator_in_synpred86999 = frozenset([1, 4, 53, 58, 59, 60, 62, 64, 66]) FOLLOW_53_in_synpred861004 = frozenset([1]) FOLLOW_specifier_qualifier_list_in_synpred901046 = frozenset([1, 62, 64, 66]) FOLLOW_abstract_declarator_in_synpred901048 = frozenset([1]) FOLLOW_direct_abstract_declarator_in_synpred911067 = frozenset([1]) FOLLOW_62_in_synpred931086 = frozenset([62, 64, 66]) FOLLOW_abstract_declarator_in_synpred931088 = frozenset([63]) FOLLOW_63_in_synpred931090 = frozenset([1]) FOLLOW_abstract_declarator_suffix_in_synpred941098 = frozenset([1]) FOLLOW_62_in_synpred1091282 = frozenset([4, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61]) FOLLOW_type_name_in_synpred1091284 = frozenset([63]) FOLLOW_63_in_synpred1091286 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_cast_expression_in_synpred1091288 = frozenset([1]) FOLLOW_74_in_synpred1141330 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_unary_expression_in_synpred1141332 = frozenset([1]) FOLLOW_62_in_synpred1171420 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_argument_expression_list_in_synpred1171424 = frozenset([63]) FOLLOW_63_in_synpred1171428 = frozenset([1]) FOLLOW_62_in_synpred1181444 = frozenset([4, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 45, 46, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 66]) FOLLOW_macro_parameter_list_in_synpred1181446 = frozenset([63]) FOLLOW_63_in_synpred1181448 = frozenset([1]) FOLLOW_66_in_synpred1201482 = frozenset([4]) FOLLOW_IDENTIFIER_in_synpred1201486 = frozenset([1]) FOLLOW_STRING_LITERAL_in_synpred1371683 = frozenset([1]) FOLLOW_IDENTIFIER_in_synpred1381680 = frozenset([4, 9]) FOLLOW_STRING_LITERAL_in_synpred1381683 = frozenset([1, 9]) FOLLOW_lvalue_in_synpred1421744 = frozenset([28, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89]) FOLLOW_assignment_operator_in_synpred1421746 = frozenset([4, 5, 6, 7, 8, 9, 10, 62, 66, 68, 69, 72, 73, 74, 77, 78, 79]) FOLLOW_assignment_expression_in_synpred1421748 = frozenset([1]) FOLLOW_expression_statement_in_synpred1692035 = frozenset([1]) FOLLOW_macro_statement_in_synpred1732055 = frozenset([1]) FOLLOW_asm2_statement_in_synpred1742060 = frozenset([1]) FOLLOW_declaration_in_synpred1812166 = frozenset([1]) FOLLOW_statement_list_in_synpred1822170 = frozenset([1]) FOLLOW_declaration_in_synpred1862225 = frozenset([1]) FOLLOW_statement_in_synpred1882242 = frozenset([1])
{ "repo_name": "MattDevo/edk2", "path": "BaseTools/Source/Python/Ecc/CParser.py", "copies": "1", "size": "698502", "license": "bsd-2-clause", "hash": -6069237150660897000, "line_mean": 35.0774457243, "line_max": 694, "alpha_frac": 0.3905199985, "autogenerated": false, "ratio": 4.531842836010692, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.004621219654298775, "num_lines": 18839 }
# $ANTLR 3.1.2 GDBMI.g 2010-06-08 01:02:51 import sys from antlr3 import * from antlr3.compat import set, frozenset from antlr3.tree import * DONE = 1 RUNNING = 2 ERROR = 3 CONNECTED = 4 EXIT = 5 STOPPED = 6 class GDBMITuple(dict): def __getattr__(self, key): return self[key] class GDBMIResultRecord(GDBMITuple): def __init__(self): super(GDBMIResultRecord, self).__init__(self) self.token = None self.cls = None def __str__(self): return "<GDBMIRresultRecord token=%s class=%s %s>" % (self.token, self.cls, super(GDBMIResultRecord, self).__str__()) class GDBMIResponse(object): def __init__(self): self.console = [] self.target = [] self.log = [] self.exc = None self.status = None self.notify = None self.result = None def __str__(self): return "<GDBMIResponse console=%s target=%s log=%s result=%s>" % (self.console, self.target, self.log, self.result) # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types CONSOLE=15 T__24=24 T__23=23 LOG=17 T__22=22 T__21=21 STATUS=11 T__20=20 RESULT=5 EXEC=10 TARGET=16 EOF=-1 TOKEN=4 T__19=19 WS=8 EOM=18 COMMA=7 NOTIFY=12 RESULT_CLASS=6 C_STRING=14 NL=9 STRING=13 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "TOKEN", "RESULT", "RESULT_CLASS", "COMMA", "WS", "NL", "EXEC", "STATUS", "NOTIFY", "STRING", "C_STRING", "CONSOLE", "TARGET", "LOG", "EOM", "'{}'", "'{'", "'}'", "'[]'", "'['", "']'" ] class GDBMIParser(Parser): grammarFileName = "GDBMI.g" antlr_version = version_str_to_tuple("3.1.2") antlr_version_str = "3.1.2" tokenNames = tokenNames def __init__(self, input, state=None): if state is None: state = RecognizerSharedState() Parser.__init__(self, input, state) self.dfa4 = self.DFA4( self, 4, eot = self.DFA4_eot, eof = self.DFA4_eof, min = self.DFA4_min, max = self.DFA4_max, accept = self.DFA4_accept, special = self.DFA4_special, transition = self.DFA4_transition ) self._adaptor = CommonTreeAdaptor() def getTreeAdaptor(self): return self._adaptor def setTreeAdaptor(self, adaptor): self._adaptor = adaptor adaptor = property(getTreeAdaptor, setTreeAdaptor) def emitErrorMessage(self, message): self.gdbmi_error = message class result_record_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.val = None self.tree = None # $ANTLR start "result_record" # GDBMI.g:54:1: result_record returns [val] : ( TOKEN )? RESULT RESULT_CLASS ( COMMA result )* ( WS )* NL ; def result_record(self, ): retval = self.result_record_return() retval.start = self.input.LT(1) root_0 = None TOKEN1 = None RESULT2 = None RESULT_CLASS3 = None COMMA4 = None WS6 = None NL7 = None result5 = None TOKEN1_tree = None RESULT2_tree = None RESULT_CLASS3_tree = None COMMA4_tree = None WS6_tree = None NL7_tree = None retval.val = GDBMIResultRecord() try: try: # GDBMI.g:58:2: ( ( TOKEN )? RESULT RESULT_CLASS ( COMMA result )* ( WS )* NL ) # GDBMI.g:58:4: ( TOKEN )? RESULT RESULT_CLASS ( COMMA result )* ( WS )* NL pass root_0 = self._adaptor.nil() # GDBMI.g:58:4: ( TOKEN )? alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == TOKEN) : alt1 = 1 if alt1 == 1: # GDBMI.g:58:5: TOKEN pass TOKEN1=self.match(self.input, TOKEN, self.FOLLOW_TOKEN_in_result_record65) TOKEN1_tree = self._adaptor.createWithPayload(TOKEN1) self._adaptor.addChild(root_0, TOKEN1_tree) #action start retval.val.token = int(TOKEN1.text) #action end RESULT2=self.match(self.input, RESULT, self.FOLLOW_RESULT_in_result_record71) RESULT2_tree = self._adaptor.createWithPayload(RESULT2) self._adaptor.addChild(root_0, RESULT2_tree) RESULT_CLASS3=self.match(self.input, RESULT_CLASS, self.FOLLOW_RESULT_CLASS_in_result_record78) RESULT_CLASS3_tree = self._adaptor.createWithPayload(RESULT_CLASS3) self._adaptor.addChild(root_0, RESULT_CLASS3_tree) #action start retval.val.cls = str(RESULT_CLASS3.text) #action end # GDBMI.g:60:4: ( COMMA result )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == COMMA) : alt2 = 1 if alt2 == 1: # GDBMI.g:60:5: COMMA result pass COMMA4=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_result_record87) COMMA4_tree = self._adaptor.createWithPayload(COMMA4) self._adaptor.addChild(root_0, COMMA4_tree) self._state.following.append(self.FOLLOW_result_in_result_record89) result5 = self.result() self._state.following.pop() self._adaptor.addChild(root_0, result5.tree) #action start retval.val[((result5 is not None) and [result5.key] or [None])[0]] = ((result5 is not None) and [result5.val] or [None])[0] #action end else: break #loop2 # GDBMI.g:60:54: ( WS )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == WS) : alt3 = 1 if alt3 == 1: # GDBMI.g:60:54: WS pass WS6=self.match(self.input, WS, self.FOLLOW_WS_in_result_record95) WS6_tree = self._adaptor.createWithPayload(WS6) self._adaptor.addChild(root_0, WS6_tree) else: break #loop3 NL7=self.match(self.input, NL, self.FOLLOW_NL_in_result_record98) NL7_tree = self._adaptor.createWithPayload(NL7) self._adaptor.addChild(root_0, NL7_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "result_record" class output_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.response = None self.tree = None # $ANTLR start "output" # GDBMI.g:62:1: output returns [response] : ( out_of_band_record NL )* ( result_record )? ( WS )* ( NL )? ; def output(self, ): retval = self.output_return() retval.start = self.input.LT(1) root_0 = None NL9 = None WS11 = None NL12 = None out_of_band_record8 = None result_record10 = None NL9_tree = None WS11_tree = None NL12_tree = None retval.response = GDBMIResponse() try: try: # GDBMI.g:67:2: ( ( out_of_band_record NL )* ( result_record )? ( WS )* ( NL )? ) # GDBMI.g:67:4: ( out_of_band_record NL )* ( result_record )? ( WS )* ( NL )? pass root_0 = self._adaptor.nil() # GDBMI.g:67:4: ( out_of_band_record NL )* while True: #loop4 alt4 = 2 alt4 = self.dfa4.predict(self.input) if alt4 == 1: # GDBMI.g:67:5: out_of_band_record NL pass self._state.following.append(self.FOLLOW_out_of_band_record_in_output121) out_of_band_record8 = self.out_of_band_record() self._state.following.pop() self._adaptor.addChild(root_0, out_of_band_record8.tree) NL9=self.match(self.input, NL, self.FOLLOW_NL_in_output123) NL9_tree = self._adaptor.createWithPayload(NL9) self._adaptor.addChild(root_0, NL9_tree) #action start if ((out_of_band_record8 is not None) and [out_of_band_record8.console] or [None])[0]: retval.response.console.append(((out_of_band_record8 is not None) and [out_of_band_record8.console] or [None])[0]) if ((out_of_band_record8 is not None) and [out_of_band_record8.target] or [None])[0]: retval.response.target.append(((out_of_band_record8 is not None) and [out_of_band_record8.target] or [None])[0]) if ((out_of_band_record8 is not None) and [out_of_band_record8.log] or [None])[0]: retval.response.log.append(((out_of_band_record8 is not None) and [out_of_band_record8.log] or [None])[0]) if ((out_of_band_record8 is not None) and [out_of_band_record8.exc] or [None])[0]: retval.response.exc = ((out_of_band_record8 is not None) and [out_of_band_record8.exc] or [None])[0] if ((out_of_band_record8 is not None) and [out_of_band_record8.status] or [None])[0]: retval.response.status = ((out_of_band_record8 is not None) and [out_of_band_record8.status] or [None])[0] if ((out_of_band_record8 is not None) and [out_of_band_record8.notify] or [None])[0]: retval.response.notify = ((out_of_band_record8 is not None) and [out_of_band_record8.notify] or [None])[0] #action end else: break #loop4 # GDBMI.g:81:7: ( result_record )? alt5 = 2 LA5_0 = self.input.LA(1) if ((TOKEN <= LA5_0 <= RESULT)) : alt5 = 1 if alt5 == 1: # GDBMI.g:81:7: result_record pass self._state.following.append(self.FOLLOW_result_record_in_output130) result_record10 = self.result_record() self._state.following.pop() self._adaptor.addChild(root_0, result_record10.tree) #action start retval.response.result=((result_record10 is not None) and [result_record10.val] or [None])[0] #action end # GDBMI.g:83:4: ( WS )* while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == WS) : alt6 = 1 if alt6 == 1: # GDBMI.g:83:4: WS pass WS11=self.match(self.input, WS, self.FOLLOW_WS_in_output135) WS11_tree = self._adaptor.createWithPayload(WS11) self._adaptor.addChild(root_0, WS11_tree) else: break #loop6 # GDBMI.g:83:8: ( NL )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == NL) : alt7 = 1 if alt7 == 1: # GDBMI.g:83:8: NL pass NL12=self.match(self.input, NL, self.FOLLOW_NL_in_output138) NL12_tree = self._adaptor.createWithPayload(NL12) self._adaptor.addChild(root_0, NL12_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "output" class async_record_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.exc = None self.status = None self.notify = None self.tree = None # $ANTLR start "async_record" # GDBMI.g:85:1: async_record returns [exc,status,notify] : ( exec_async_output | status_async_output | notify_async_output ); def async_record(self, ): retval = self.async_record_return() retval.start = self.input.LT(1) root_0 = None exec_async_output13 = None status_async_output14 = None notify_async_output15 = None retval.exc = None retval.status = None retval.notify = None try: try: # GDBMI.g:91:2: ( exec_async_output | status_async_output | notify_async_output ) alt8 = 3 LA8 = self.input.LA(1) if LA8 == TOKEN: LA8 = self.input.LA(2) if LA8 == NOTIFY: alt8 = 3 elif LA8 == EXEC: alt8 = 1 elif LA8 == STATUS: alt8 = 2 else: nvae = NoViableAltException("", 8, 1, self.input) raise nvae elif LA8 == EXEC: alt8 = 1 elif LA8 == STATUS: alt8 = 2 elif LA8 == NOTIFY: alt8 = 3 else: nvae = NoViableAltException("", 8, 0, self.input) raise nvae if alt8 == 1: # GDBMI.g:91:3: exec_async_output pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_exec_async_output_in_async_record157) exec_async_output13 = self.exec_async_output() self._state.following.pop() self._adaptor.addChild(root_0, exec_async_output13.tree) #action start retval.exc = ((exec_async_output13 is not None) and [exec_async_output13.val] or [None])[0] #action end elif alt8 == 2: # GDBMI.g:92:2: status_async_output pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_status_async_output_in_async_record165) status_async_output14 = self.status_async_output() self._state.following.pop() self._adaptor.addChild(root_0, status_async_output14.tree) #action start retval.status = ((status_async_output14 is not None) and [status_async_output14.val] or [None])[0] #action end elif alt8 == 3: # GDBMI.g:93:2: notify_async_output pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_notify_async_output_in_async_record173) notify_async_output15 = self.notify_async_output() self._state.following.pop() self._adaptor.addChild(root_0, notify_async_output15.tree) #action start retval.notify = ((notify_async_output15 is not None) and [notify_async_output15.val] or [None])[0] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "async_record" class out_of_band_record_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.exc = None self.status = None self.notify = None self.target = None self.console = None self.log = None self.tree = None # $ANTLR start "out_of_band_record" # GDBMI.g:95:1: out_of_band_record returns [exc,status,notify,target,console,log] : ( async_record | stream_record ); def out_of_band_record(self, ): retval = self.out_of_band_record_return() retval.start = self.input.LT(1) root_0 = None async_record16 = None stream_record17 = None retval.exc = retval.status = retval.notify = None retval.target = retval.console = retval.log = None try: try: # GDBMI.g:100:2: ( async_record | stream_record ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == TOKEN or (EXEC <= LA9_0 <= NOTIFY)) : alt9 = 1 elif ((CONSOLE <= LA9_0 <= LOG)) : alt9 = 2 else: nvae = NoViableAltException("", 9, 0, self.input) raise nvae if alt9 == 1: # GDBMI.g:100:4: async_record pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_async_record_in_out_of_band_record194) async_record16 = self.async_record() self._state.following.pop() self._adaptor.addChild(root_0, async_record16.tree) #action start if ((async_record16 is not None) and [async_record16.exc] or [None])[0]: retval.exc = ((async_record16 is not None) and [async_record16.exc] or [None])[0] if ((async_record16 is not None) and [async_record16.status] or [None])[0]: retval.status = ((async_record16 is not None) and [async_record16.status] or [None])[0] if ((async_record16 is not None) and [async_record16.notify] or [None])[0]: retval.notify = ((async_record16 is not None) and [async_record16.notify] or [None])[0] #action end elif alt9 == 2: # GDBMI.g:105:2: stream_record pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_stream_record_in_out_of_band_record202) stream_record17 = self.stream_record() self._state.following.pop() self._adaptor.addChild(root_0, stream_record17.tree) #action start if ((stream_record17 is not None) and [stream_record17.target] or [None])[0]: retval.target = ((stream_record17 is not None) and [stream_record17.target] or [None])[0] if ((stream_record17 is not None) and [stream_record17.console] or [None])[0]: retval.console = ((stream_record17 is not None) and [stream_record17.console] or [None])[0] if ((stream_record17 is not None) and [stream_record17.log] or [None])[0]: retval.log = ((stream_record17 is not None) and [stream_record17.log] or [None])[0] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "out_of_band_record" class exec_async_output_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.val = None self.tree = None # $ANTLR start "exec_async_output" # GDBMI.g:111:1: exec_async_output returns [val] : ( TOKEN )? EXEC async_output ; def exec_async_output(self, ): retval = self.exec_async_output_return() retval.start = self.input.LT(1) root_0 = None TOKEN18 = None EXEC19 = None async_output20 = None TOKEN18_tree = None EXEC19_tree = None try: try: # GDBMI.g:112:2: ( ( TOKEN )? EXEC async_output ) # GDBMI.g:112:4: ( TOKEN )? EXEC async_output pass root_0 = self._adaptor.nil() # GDBMI.g:112:4: ( TOKEN )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == TOKEN) : alt10 = 1 if alt10 == 1: # GDBMI.g:112:5: TOKEN pass TOKEN18=self.match(self.input, TOKEN, self.FOLLOW_TOKEN_in_exec_async_output218) TOKEN18_tree = self._adaptor.createWithPayload(TOKEN18) self._adaptor.addChild(root_0, TOKEN18_tree) EXEC19=self.match(self.input, EXEC, self.FOLLOW_EXEC_in_exec_async_output222) EXEC19_tree = self._adaptor.createWithPayload(EXEC19) self._adaptor.addChild(root_0, EXEC19_tree) self._state.following.append(self.FOLLOW_async_output_in_exec_async_output224) async_output20 = self.async_output() self._state.following.pop() self._adaptor.addChild(root_0, async_output20.tree) #action start retval.val = ((async_output20 is not None) and [async_output20.val] or [None])[0] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "exec_async_output" class status_async_output_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.val = None self.tree = None # $ANTLR start "status_async_output" # GDBMI.g:114:1: status_async_output returns [val] : ( TOKEN )? STATUS async_output ; def status_async_output(self, ): retval = self.status_async_output_return() retval.start = self.input.LT(1) root_0 = None TOKEN21 = None STATUS22 = None async_output23 = None TOKEN21_tree = None STATUS22_tree = None try: try: # GDBMI.g:115:2: ( ( TOKEN )? STATUS async_output ) # GDBMI.g:115:4: ( TOKEN )? STATUS async_output pass root_0 = self._adaptor.nil() # GDBMI.g:115:4: ( TOKEN )? alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == TOKEN) : alt11 = 1 if alt11 == 1: # GDBMI.g:115:5: TOKEN pass TOKEN21=self.match(self.input, TOKEN, self.FOLLOW_TOKEN_in_status_async_output241) TOKEN21_tree = self._adaptor.createWithPayload(TOKEN21) self._adaptor.addChild(root_0, TOKEN21_tree) STATUS22=self.match(self.input, STATUS, self.FOLLOW_STATUS_in_status_async_output245) STATUS22_tree = self._adaptor.createWithPayload(STATUS22) self._adaptor.addChild(root_0, STATUS22_tree) self._state.following.append(self.FOLLOW_async_output_in_status_async_output247) async_output23 = self.async_output() self._state.following.pop() self._adaptor.addChild(root_0, async_output23.tree) #action start retval.val = ((async_output23 is not None) and [async_output23.val] or [None])[0] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "status_async_output" class notify_async_output_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.val = None self.tree = None # $ANTLR start "notify_async_output" # GDBMI.g:117:1: notify_async_output returns [val] : ( TOKEN )? NOTIFY async_output ; def notify_async_output(self, ): retval = self.notify_async_output_return() retval.start = self.input.LT(1) root_0 = None TOKEN24 = None NOTIFY25 = None async_output26 = None TOKEN24_tree = None NOTIFY25_tree = None try: try: # GDBMI.g:118:2: ( ( TOKEN )? NOTIFY async_output ) # GDBMI.g:118:4: ( TOKEN )? NOTIFY async_output pass root_0 = self._adaptor.nil() # GDBMI.g:118:4: ( TOKEN )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == TOKEN) : alt12 = 1 if alt12 == 1: # GDBMI.g:118:5: TOKEN pass TOKEN24=self.match(self.input, TOKEN, self.FOLLOW_TOKEN_in_notify_async_output264) TOKEN24_tree = self._adaptor.createWithPayload(TOKEN24) self._adaptor.addChild(root_0, TOKEN24_tree) NOTIFY25=self.match(self.input, NOTIFY, self.FOLLOW_NOTIFY_in_notify_async_output268) NOTIFY25_tree = self._adaptor.createWithPayload(NOTIFY25) self._adaptor.addChild(root_0, NOTIFY25_tree) self._state.following.append(self.FOLLOW_async_output_in_notify_async_output270) async_output26 = self.async_output() self._state.following.pop() self._adaptor.addChild(root_0, async_output26.tree) #action start retval.val = ((async_output26 is not None) and [async_output26.val] or [None])[0] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "notify_async_output" class async_output_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.val = None self.tree = None # $ANTLR start "async_output" # GDBMI.g:120:1: async_output returns [val] : RESULT_CLASS ( COMMA result )* NL ; def async_output(self, ): retval = self.async_output_return() retval.start = self.input.LT(1) root_0 = None RESULT_CLASS27 = None COMMA28 = None NL30 = None result29 = None RESULT_CLASS27_tree = None COMMA28_tree = None NL30_tree = None retval.val = GDBMIResultRecord() try: try: # GDBMI.g:124:2: ( RESULT_CLASS ( COMMA result )* NL ) # GDBMI.g:124:4: RESULT_CLASS ( COMMA result )* NL pass root_0 = self._adaptor.nil() RESULT_CLASS27=self.match(self.input, RESULT_CLASS, self.FOLLOW_RESULT_CLASS_in_async_output292) RESULT_CLASS27_tree = self._adaptor.createWithPayload(RESULT_CLASS27) self._adaptor.addChild(root_0, RESULT_CLASS27_tree) #action start retval.val.cls = RESULT_CLASS27.text #action end # GDBMI.g:124:50: ( COMMA result )* while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == COMMA) : alt13 = 1 if alt13 == 1: # GDBMI.g:124:51: COMMA result pass COMMA28=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_async_output297) COMMA28_tree = self._adaptor.createWithPayload(COMMA28) self._adaptor.addChild(root_0, COMMA28_tree) self._state.following.append(self.FOLLOW_result_in_async_output299) result29 = self.result() self._state.following.pop() self._adaptor.addChild(root_0, result29.tree) #action start retval.val[((result29 is not None) and [result29.key] or [None])[0]] = ((result29 is not None) and [result29.val] or [None])[0] #action end else: break #loop13 NL30=self.match(self.input, NL, self.FOLLOW_NL_in_async_output305) NL30_tree = self._adaptor.createWithPayload(NL30) self._adaptor.addChild(root_0, NL30_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "async_output" class var_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.txt = None self.tree = None # $ANTLR start "var" # GDBMI.g:127:1: var returns [txt] : STRING ; def var(self, ): retval = self.var_return() retval.start = self.input.LT(1) root_0 = None STRING31 = None STRING31_tree = None try: try: # GDBMI.g:128:2: ( STRING ) # GDBMI.g:128:4: STRING pass root_0 = self._adaptor.nil() STRING31=self.match(self.input, STRING, self.FOLLOW_STRING_in_var321) STRING31_tree = self._adaptor.createWithPayload(STRING31) self._adaptor.addChild(root_0, STRING31_tree) #action start retval.txt = str(STRING31.text) #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "var" class result_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.key = None self.val = None self.tree = None # $ANTLR start "result" # GDBMI.g:130:1: result returns [key,val] : ( var '=' value ) ; def result(self, ): retval = self.result_return() retval.start = self.input.LT(1) root_0 = None char_literal33 = None var32 = None value34 = None char_literal33_tree = None try: try: # GDBMI.g:131:2: ( ( var '=' value ) ) # GDBMI.g:131:4: ( var '=' value ) pass root_0 = self._adaptor.nil() # GDBMI.g:131:4: ( var '=' value ) # GDBMI.g:131:5: var '=' value pass self._state.following.append(self.FOLLOW_var_in_result337) var32 = self.var() self._state.following.pop() self._adaptor.addChild(root_0, var32.tree) char_literal33=self.match(self.input, NOTIFY, self.FOLLOW_NOTIFY_in_result339) char_literal33_tree = self._adaptor.createWithPayload(char_literal33) self._adaptor.addChild(root_0, char_literal33_tree) self._state.following.append(self.FOLLOW_value_in_result341) value34 = self.value() self._state.following.pop() self._adaptor.addChild(root_0, value34.tree) #action start retval.key=str(((var32 is not None) and [var32.txt] or [None])[0]) retval.val=((value34 is not None) and [value34.val] or [None])[0] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "result" class value_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.val = None self.tree = None # $ANTLR start "value" # GDBMI.g:136:1: value returns [val] : ( const | tuple | list ); def value(self, ): retval = self.value_return() retval.start = self.input.LT(1) root_0 = None const35 = None tuple36 = None list37 = None try: try: # GDBMI.g:136:21: ( const | tuple | list ) alt14 = 3 LA14 = self.input.LA(1) if LA14 == C_STRING: alt14 = 1 elif LA14 == 19 or LA14 == 20: alt14 = 2 elif LA14 == 22 or LA14 == 23: alt14 = 3 else: nvae = NoViableAltException("", 14, 0, self.input) raise nvae if alt14 == 1: # GDBMI.g:136:23: const pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_const_in_value357) const35 = self.const() self._state.following.pop() self._adaptor.addChild(root_0, const35.tree) #action start retval.val=str(((const35 is not None) and [const35.txt] or [None])[0]) #action end elif alt14 == 2: # GDBMI.g:136:54: tuple pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_tuple_in_value363) tuple36 = self.tuple() self._state.following.pop() self._adaptor.addChild(root_0, tuple36.tree) #action start retval.val=((tuple36 is not None) and [tuple36.items] or [None])[0] #action end elif alt14 == 3: # GDBMI.g:136:82: list pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_list_in_value369) list37 = self.list() self._state.following.pop() self._adaptor.addChild(root_0, list37.tree) #action start retval.val=((list37 is not None) and [list37.items] or [None])[0] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "value" class const_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.txt = None self.tree = None # $ANTLR start "const" # GDBMI.g:138:1: const returns [txt] : C_STRING ; def const(self, ): retval = self.const_return() retval.start = self.input.LT(1) root_0 = None C_STRING38 = None C_STRING38_tree = None try: try: # GDBMI.g:139:2: ( C_STRING ) # GDBMI.g:139:4: C_STRING pass root_0 = self._adaptor.nil() C_STRING38=self.match(self.input, C_STRING, self.FOLLOW_C_STRING_in_const385) C_STRING38_tree = self._adaptor.createWithPayload(C_STRING38) self._adaptor.addChild(root_0, C_STRING38_tree) #action start retval.txt=C_STRING38.text[1:-1] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "const" class tuple_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.items = None self.tree = None # $ANTLR start "tuple" # GDBMI.g:141:1: tuple returns [items] : ( '{}' | '{' a= result ( COMMA b= result )* '}' ); def tuple(self, ): retval = self.tuple_return() retval.start = self.input.LT(1) root_0 = None string_literal39 = None char_literal40 = None COMMA41 = None char_literal42 = None a = None b = None string_literal39_tree = None char_literal40_tree = None COMMA41_tree = None char_literal42_tree = None retval.items = GDBMITuple() try: try: # GDBMI.g:143:2: ( '{}' | '{' a= result ( COMMA b= result )* '}' ) alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == 19) : alt16 = 1 elif (LA16_0 == 20) : alt16 = 2 else: nvae = NoViableAltException("", 16, 0, self.input) raise nvae if alt16 == 1: # GDBMI.g:143:4: '{}' pass root_0 = self._adaptor.nil() string_literal39=self.match(self.input, 19, self.FOLLOW_19_in_tuple407) string_literal39_tree = self._adaptor.createWithPayload(string_literal39) self._adaptor.addChild(root_0, string_literal39_tree) elif alt16 == 2: # GDBMI.g:144:4: '{' a= result ( COMMA b= result )* '}' pass root_0 = self._adaptor.nil() char_literal40=self.match(self.input, 20, self.FOLLOW_20_in_tuple413) char_literal40_tree = self._adaptor.createWithPayload(char_literal40) self._adaptor.addChild(root_0, char_literal40_tree) self._state.following.append(self.FOLLOW_result_in_tuple417) a = self.result() self._state.following.pop() self._adaptor.addChild(root_0, a.tree) #action start retval.items[a.key] = a.val #action end # GDBMI.g:144:41: ( COMMA b= result )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == COMMA) : alt15 = 1 if alt15 == 1: # GDBMI.g:144:42: COMMA b= result pass COMMA41=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_tuple422) COMMA41_tree = self._adaptor.createWithPayload(COMMA41) self._adaptor.addChild(root_0, COMMA41_tree) self._state.following.append(self.FOLLOW_result_in_tuple426) b = self.result() self._state.following.pop() self._adaptor.addChild(root_0, b.tree) #action start retval.items[b.key] = b.val #action end else: break #loop15 char_literal42=self.match(self.input, 21, self.FOLLOW_21_in_tuple432) char_literal42_tree = self._adaptor.createWithPayload(char_literal42) self._adaptor.addChild(root_0, char_literal42_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "tuple" class stream_record_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.console = None self.target = None self.log = None self.tree = None # $ANTLR start "stream_record" # GDBMI.g:147:1: stream_record returns [console, target, log] : ( console_stream_output | target_stream_output | log_stream_output ); def stream_record(self, ): retval = self.stream_record_return() retval.start = self.input.LT(1) root_0 = None console_stream_output43 = None target_stream_output44 = None log_stream_output45 = None retval.console = None retval.target = None retval.log = None try: try: # GDBMI.g:153:2: ( console_stream_output | target_stream_output | log_stream_output ) alt17 = 3 LA17 = self.input.LA(1) if LA17 == CONSOLE: alt17 = 1 elif LA17 == TARGET: alt17 = 2 elif LA17 == LOG: alt17 = 3 else: nvae = NoViableAltException("", 17, 0, self.input) raise nvae if alt17 == 1: # GDBMI.g:153:4: console_stream_output pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_console_stream_output_in_stream_record453) console_stream_output43 = self.console_stream_output() self._state.following.pop() self._adaptor.addChild(root_0, console_stream_output43.tree) #action start retval.console = ((console_stream_output43 is not None) and [console_stream_output43.txt] or [None])[0] #action end elif alt17 == 2: # GDBMI.g:154:4: target_stream_output pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_target_stream_output_in_stream_record460) target_stream_output44 = self.target_stream_output() self._state.following.pop() self._adaptor.addChild(root_0, target_stream_output44.tree) #action start retval.target = ((target_stream_output44 is not None) and [target_stream_output44.txt] or [None])[0] #action end elif alt17 == 3: # GDBMI.g:155:4: log_stream_output pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_log_stream_output_in_stream_record467) log_stream_output45 = self.log_stream_output() self._state.following.pop() self._adaptor.addChild(root_0, log_stream_output45.tree) #action start retval.log = ((log_stream_output45 is not None) and [log_stream_output45.txt] or [None])[0] #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "stream_record" class list_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.items = None self.tree = None # $ANTLR start "list" # GDBMI.g:157:1: list returns [items] : ( '[]' | '[' a= value ( COMMA b= value )* ']' | '[' c= result ( COMMA d= result )* ']' ); def list(self, ): retval = self.list_return() retval.start = self.input.LT(1) root_0 = None string_literal46 = None char_literal47 = None COMMA48 = None char_literal49 = None char_literal50 = None COMMA51 = None char_literal52 = None a = None b = None c = None d = None string_literal46_tree = None char_literal47_tree = None COMMA48_tree = None char_literal49_tree = None char_literal50_tree = None COMMA51_tree = None char_literal52_tree = None retval.items=[] try: try: # GDBMI.g:159:2: ( '[]' | '[' a= value ( COMMA b= value )* ']' | '[' c= result ( COMMA d= result )* ']' ) alt20 = 3 LA20_0 = self.input.LA(1) if (LA20_0 == 22) : alt20 = 1 elif (LA20_0 == 23) : LA20_2 = self.input.LA(2) if (LA20_2 == C_STRING or (19 <= LA20_2 <= 20) or (22 <= LA20_2 <= 23)) : alt20 = 2 elif (LA20_2 == STRING) : alt20 = 3 else: nvae = NoViableAltException("", 20, 2, self.input) raise nvae else: nvae = NoViableAltException("", 20, 0, self.input) raise nvae if alt20 == 1: # GDBMI.g:159:4: '[]' pass root_0 = self._adaptor.nil() string_literal46=self.match(self.input, 22, self.FOLLOW_22_in_list489) string_literal46_tree = self._adaptor.createWithPayload(string_literal46) self._adaptor.addChild(root_0, string_literal46_tree) elif alt20 == 2: # GDBMI.g:160:4: '[' a= value ( COMMA b= value )* ']' pass root_0 = self._adaptor.nil() char_literal47=self.match(self.input, 23, self.FOLLOW_23_in_list495) char_literal47_tree = self._adaptor.createWithPayload(char_literal47) self._adaptor.addChild(root_0, char_literal47_tree) self._state.following.append(self.FOLLOW_value_in_list499) a = self.value() self._state.following.pop() self._adaptor.addChild(root_0, a.tree) #action start retval.items.append(a.val) #action end # GDBMI.g:160:39: ( COMMA b= value )* while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == COMMA) : alt18 = 1 if alt18 == 1: # GDBMI.g:160:40: COMMA b= value pass COMMA48=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_list504) COMMA48_tree = self._adaptor.createWithPayload(COMMA48) self._adaptor.addChild(root_0, COMMA48_tree) self._state.following.append(self.FOLLOW_value_in_list508) b = self.value() self._state.following.pop() self._adaptor.addChild(root_0, b.tree) #action start retval.items.append(b.val) #action end else: break #loop18 char_literal49=self.match(self.input, 24, self.FOLLOW_24_in_list514) char_literal49_tree = self._adaptor.createWithPayload(char_literal49) self._adaptor.addChild(root_0, char_literal49_tree) elif alt20 == 3: # GDBMI.g:161:4: '[' c= result ( COMMA d= result )* ']' pass root_0 = self._adaptor.nil() char_literal50=self.match(self.input, 23, self.FOLLOW_23_in_list519) char_literal50_tree = self._adaptor.createWithPayload(char_literal50) self._adaptor.addChild(root_0, char_literal50_tree) self._state.following.append(self.FOLLOW_result_in_list523) c = self.result() self._state.following.pop() self._adaptor.addChild(root_0, c.tree) #action start retval.items.append(dict( ((c.key,c.val),) )) #action end # GDBMI.g:161:59: ( COMMA d= result )* while True: #loop19 alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == COMMA) : alt19 = 1 if alt19 == 1: # GDBMI.g:161:60: COMMA d= result pass COMMA51=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_list528) COMMA51_tree = self._adaptor.createWithPayload(COMMA51) self._adaptor.addChild(root_0, COMMA51_tree) self._state.following.append(self.FOLLOW_result_in_list532) d = self.result() self._state.following.pop() self._adaptor.addChild(root_0, d.tree) #action start retval.items.append(dict( ((d.key,d.val),) )) #action end else: break #loop19 char_literal52=self.match(self.input, 24, self.FOLLOW_24_in_list538) char_literal52_tree = self._adaptor.createWithPayload(char_literal52) self._adaptor.addChild(root_0, char_literal52_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "list" class console_stream_output_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.txt = None self.tree = None # $ANTLR start "console_stream_output" # GDBMI.g:163:1: console_stream_output returns [txt] : CONSOLE C_STRING ; def console_stream_output(self, ): retval = self.console_stream_output_return() retval.start = self.input.LT(1) root_0 = None CONSOLE53 = None C_STRING54 = None CONSOLE53_tree = None C_STRING54_tree = None try: try: # GDBMI.g:164:2: ( CONSOLE C_STRING ) # GDBMI.g:164:4: CONSOLE C_STRING pass root_0 = self._adaptor.nil() CONSOLE53=self.match(self.input, CONSOLE, self.FOLLOW_CONSOLE_in_console_stream_output551) CONSOLE53_tree = self._adaptor.createWithPayload(CONSOLE53) self._adaptor.addChild(root_0, CONSOLE53_tree) C_STRING54=self.match(self.input, C_STRING, self.FOLLOW_C_STRING_in_console_stream_output553) C_STRING54_tree = self._adaptor.createWithPayload(C_STRING54) self._adaptor.addChild(root_0, C_STRING54_tree) #action start retval.txt = str(C_STRING54.text[1:-1]).decode('string_escape') #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "console_stream_output" class target_stream_output_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.txt = None self.tree = None # $ANTLR start "target_stream_output" # GDBMI.g:166:1: target_stream_output returns [txt] : TARGET C_STRING ; def target_stream_output(self, ): retval = self.target_stream_output_return() retval.start = self.input.LT(1) root_0 = None TARGET55 = None C_STRING56 = None TARGET55_tree = None C_STRING56_tree = None try: try: # GDBMI.g:167:2: ( TARGET C_STRING ) # GDBMI.g:167:4: TARGET C_STRING pass root_0 = self._adaptor.nil() TARGET55=self.match(self.input, TARGET, self.FOLLOW_TARGET_in_target_stream_output568) TARGET55_tree = self._adaptor.createWithPayload(TARGET55) self._adaptor.addChild(root_0, TARGET55_tree) C_STRING56=self.match(self.input, C_STRING, self.FOLLOW_C_STRING_in_target_stream_output570) C_STRING56_tree = self._adaptor.createWithPayload(C_STRING56) self._adaptor.addChild(root_0, C_STRING56_tree) #action start retval.txt = str(C_STRING56.text[1:-1]).decode('string_escape') #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "target_stream_output" class log_stream_output_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) self.txt = None self.tree = None # $ANTLR start "log_stream_output" # GDBMI.g:169:1: log_stream_output returns [txt] : LOG C_STRING ; def log_stream_output(self, ): retval = self.log_stream_output_return() retval.start = self.input.LT(1) root_0 = None LOG57 = None C_STRING58 = None LOG57_tree = None C_STRING58_tree = None try: try: # GDBMI.g:170:2: ( LOG C_STRING ) # GDBMI.g:170:4: LOG C_STRING pass root_0 = self._adaptor.nil() LOG57=self.match(self.input, LOG, self.FOLLOW_LOG_in_log_stream_output585) LOG57_tree = self._adaptor.createWithPayload(LOG57) self._adaptor.addChild(root_0, LOG57_tree) C_STRING58=self.match(self.input, C_STRING, self.FOLLOW_C_STRING_in_log_stream_output587) C_STRING58_tree = self._adaptor.createWithPayload(C_STRING58) self._adaptor.addChild(root_0, C_STRING58_tree) #action start retval.txt = str(C_STRING58.text[1:-1]).decode('string_escape') #action end retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "log_stream_output" # Delegated rules # lookup tables for DFA #4 DFA4_eot = DFA.unpack( u"\20\uffff" ) DFA4_eof = DFA.unpack( u"\1\2\17\uffff" ) DFA4_min = DFA.unpack( u"\1\4\1\5\16\uffff" ) DFA4_max = DFA.unpack( u"\1\21\1\14\16\uffff" ) DFA4_accept = DFA.unpack( u"\2\uffff\1\2\3\uffff\1\1\11\uffff" ) DFA4_special = DFA.unpack( u"\20\uffff" ) DFA4_transition = [ DFA.unpack(u"\1\1\1\2\2\uffff\2\2\3\6\2\uffff\3\6"), DFA.unpack(u"\1\2\4\uffff\3\6"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #4 DFA4 = DFA FOLLOW_TOKEN_in_result_record65 = frozenset([5]) FOLLOW_RESULT_in_result_record71 = frozenset([6]) FOLLOW_RESULT_CLASS_in_result_record78 = frozenset([7, 8, 9]) FOLLOW_COMMA_in_result_record87 = frozenset([13]) FOLLOW_result_in_result_record89 = frozenset([7, 8, 9]) FOLLOW_WS_in_result_record95 = frozenset([8, 9]) FOLLOW_NL_in_result_record98 = frozenset([1]) FOLLOW_out_of_band_record_in_output121 = frozenset([9]) FOLLOW_NL_in_output123 = frozenset([1, 4, 5, 8, 9, 10, 11, 12, 15, 16, 17]) FOLLOW_result_record_in_output130 = frozenset([1, 8, 9]) FOLLOW_WS_in_output135 = frozenset([1, 8, 9]) FOLLOW_NL_in_output138 = frozenset([1]) FOLLOW_exec_async_output_in_async_record157 = frozenset([1]) FOLLOW_status_async_output_in_async_record165 = frozenset([1]) FOLLOW_notify_async_output_in_async_record173 = frozenset([1]) FOLLOW_async_record_in_out_of_band_record194 = frozenset([1]) FOLLOW_stream_record_in_out_of_band_record202 = frozenset([1]) FOLLOW_TOKEN_in_exec_async_output218 = frozenset([10]) FOLLOW_EXEC_in_exec_async_output222 = frozenset([6]) FOLLOW_async_output_in_exec_async_output224 = frozenset([1]) FOLLOW_TOKEN_in_status_async_output241 = frozenset([11]) FOLLOW_STATUS_in_status_async_output245 = frozenset([6]) FOLLOW_async_output_in_status_async_output247 = frozenset([1]) FOLLOW_TOKEN_in_notify_async_output264 = frozenset([12]) FOLLOW_NOTIFY_in_notify_async_output268 = frozenset([6]) FOLLOW_async_output_in_notify_async_output270 = frozenset([1]) FOLLOW_RESULT_CLASS_in_async_output292 = frozenset([7, 9]) FOLLOW_COMMA_in_async_output297 = frozenset([13]) FOLLOW_result_in_async_output299 = frozenset([7, 9]) FOLLOW_NL_in_async_output305 = frozenset([1]) FOLLOW_STRING_in_var321 = frozenset([1]) FOLLOW_var_in_result337 = frozenset([12]) FOLLOW_NOTIFY_in_result339 = frozenset([14, 19, 20, 22, 23]) FOLLOW_value_in_result341 = frozenset([1]) FOLLOW_const_in_value357 = frozenset([1]) FOLLOW_tuple_in_value363 = frozenset([1]) FOLLOW_list_in_value369 = frozenset([1]) FOLLOW_C_STRING_in_const385 = frozenset([1]) FOLLOW_19_in_tuple407 = frozenset([1]) FOLLOW_20_in_tuple413 = frozenset([13]) FOLLOW_result_in_tuple417 = frozenset([7, 21]) FOLLOW_COMMA_in_tuple422 = frozenset([13]) FOLLOW_result_in_tuple426 = frozenset([7, 21]) FOLLOW_21_in_tuple432 = frozenset([1]) FOLLOW_console_stream_output_in_stream_record453 = frozenset([1]) FOLLOW_target_stream_output_in_stream_record460 = frozenset([1]) FOLLOW_log_stream_output_in_stream_record467 = frozenset([1]) FOLLOW_22_in_list489 = frozenset([1]) FOLLOW_23_in_list495 = frozenset([14, 19, 20, 22, 23]) FOLLOW_value_in_list499 = frozenset([7, 24]) FOLLOW_COMMA_in_list504 = frozenset([14, 19, 20, 22, 23]) FOLLOW_value_in_list508 = frozenset([7, 24]) FOLLOW_24_in_list514 = frozenset([1]) FOLLOW_23_in_list519 = frozenset([13]) FOLLOW_result_in_list523 = frozenset([7, 24]) FOLLOW_COMMA_in_list528 = frozenset([13]) FOLLOW_result_in_list532 = frozenset([7, 24]) FOLLOW_24_in_list538 = frozenset([1]) FOLLOW_CONSOLE_in_console_stream_output551 = frozenset([14]) FOLLOW_C_STRING_in_console_stream_output553 = frozenset([1]) FOLLOW_TARGET_in_target_stream_output568 = frozenset([14]) FOLLOW_C_STRING_in_target_stream_output570 = frozenset([1]) FOLLOW_LOG_in_log_stream_output585 = frozenset([14]) FOLLOW_C_STRING_in_log_stream_output587 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("GDBMILexer", GDBMIParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ryansturmer/cuttlebug", "path": "cuttlebug/gdb/GDBMIParser.py", "copies": "1", "size": "69341", "license": "mit", "hash": 1753036949008737500, "line_mean": 30.1767981439, "line_max": 190, "alpha_frac": 0.4901861813, "autogenerated": false, "ratio": 3.892937345609701, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4883123526909701, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.2 GDBMI.g 2010-06-08 01:02:51 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types CONSOLE=15 T__24=24 T__23=23 LOG=17 T__22=22 T__21=21 STATUS=11 T__20=20 RESULT=5 EXEC=10 TARGET=16 EOF=-1 TOKEN=4 T__19=19 WS=8 EOM=18 COMMA=7 NOTIFY=12 RESULT_CLASS=6 NL=9 C_STRING=14 STRING=13 class GDBMILexer(Lexer): grammarFileName = "GDBMI.g" antlr_version = version_str_to_tuple("3.1.2") antlr_version_str = "3.1.2" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() Lexer.__init__(self, input, state) self.dfa2 = self.DFA2( self, 2, eot = self.DFA2_eot, eof = self.DFA2_eof, min = self.DFA2_min, max = self.DFA2_max, accept = self.DFA2_accept, special = self.DFA2_special, transition = self.DFA2_transition ) self.dfa6 = self.DFA6( self, 6, eot = self.DFA6_eot, eof = self.DFA6_eof, min = self.DFA6_min, max = self.DFA6_max, accept = self.DFA6_accept, special = self.DFA6_special, transition = self.DFA6_transition ) # $ANTLR start "T__19" def mT__19(self, ): try: _type = T__19 _channel = DEFAULT_CHANNEL # GDBMI.g:7:7: ( '{}' ) # GDBMI.g:7:9: '{}' pass self.match("{}") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__19" # $ANTLR start "T__20" def mT__20(self, ): try: _type = T__20 _channel = DEFAULT_CHANNEL # GDBMI.g:8:7: ( '{' ) # GDBMI.g:8:9: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__20" # $ANTLR start "T__21" def mT__21(self, ): try: _type = T__21 _channel = DEFAULT_CHANNEL # GDBMI.g:9:7: ( '}' ) # GDBMI.g:9:9: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__21" # $ANTLR start "T__22" def mT__22(self, ): try: _type = T__22 _channel = DEFAULT_CHANNEL # GDBMI.g:10:7: ( '[]' ) # GDBMI.g:10:9: '[]' pass self.match("[]") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__22" # $ANTLR start "T__23" def mT__23(self, ): try: _type = T__23 _channel = DEFAULT_CHANNEL # GDBMI.g:11:7: ( '[' ) # GDBMI.g:11:9: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__23" # $ANTLR start "T__24" def mT__24(self, ): try: _type = T__24 _channel = DEFAULT_CHANNEL # GDBMI.g:12:7: ( ']' ) # GDBMI.g:12:9: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__24" # $ANTLR start "C_STRING" def mC_STRING(self, ): try: _type = C_STRING _channel = DEFAULT_CHANNEL # GDBMI.g:177:2: ( '\"' ( '\\\\' '\"' | ~ ( '\"' | '\\n' | '\\r' ) )* '\"' ) # GDBMI.g:177:4: '\"' ( '\\\\' '\"' | ~ ( '\"' | '\\n' | '\\r' ) )* '\"' pass self.match(34) # GDBMI.g:177:8: ( '\\\\' '\"' | ~ ( '\"' | '\\n' | '\\r' ) )* while True: #loop1 alt1 = 3 LA1_0 = self.input.LA(1) if (LA1_0 == 92) : LA1_2 = self.input.LA(2) if (LA1_2 == 34) : LA1_4 = self.input.LA(3) if ((0 <= LA1_4 <= 9) or (11 <= LA1_4 <= 12) or (14 <= LA1_4 <= 65535)) : alt1 = 1 else: alt1 = 2 elif ((0 <= LA1_2 <= 9) or (11 <= LA1_2 <= 12) or (14 <= LA1_2 <= 33) or (35 <= LA1_2 <= 65535)) : alt1 = 2 elif ((0 <= LA1_0 <= 9) or (11 <= LA1_0 <= 12) or (14 <= LA1_0 <= 33) or (35 <= LA1_0 <= 91) or (93 <= LA1_0 <= 65535)) : alt1 = 2 if alt1 == 1: # GDBMI.g:177:9: '\\\\' '\"' pass self.match(92) self.match(34) elif alt1 == 2: # GDBMI.g:177:19: ~ ( '\"' | '\\n' | '\\r' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 self.match(34) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "C_STRING" # $ANTLR start "RESULT_CLASS" def mRESULT_CLASS(self, ): try: _type = RESULT_CLASS _channel = DEFAULT_CHANNEL # GDBMI.g:180:2: ( 'done' | 'running' | 'connected' | 'error' | 'exit' | 'stopped' | 'thread-group-created' | 'thread-created' | 'download' | 'thread-group-exited' ) alt2 = 10 alt2 = self.dfa2.predict(self.input) if alt2 == 1: # GDBMI.g:180:4: 'done' pass self.match("done") elif alt2 == 2: # GDBMI.g:181:4: 'running' pass self.match("running") elif alt2 == 3: # GDBMI.g:182:4: 'connected' pass self.match("connected") elif alt2 == 4: # GDBMI.g:183:4: 'error' pass self.match("error") elif alt2 == 5: # GDBMI.g:184:4: 'exit' pass self.match("exit") elif alt2 == 6: # GDBMI.g:185:4: 'stopped' pass self.match("stopped") elif alt2 == 7: # GDBMI.g:186:4: 'thread-group-created' pass self.match("thread-group-created") elif alt2 == 8: # GDBMI.g:187:4: 'thread-created' pass self.match("thread-created") elif alt2 == 9: # GDBMI.g:188:4: 'download' pass self.match("download") elif alt2 == 10: # GDBMI.g:189:4: 'thread-group-exited' pass self.match("thread-group-exited") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RESULT_CLASS" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # GDBMI.g:192:2: ( ( '_' | 'A' .. 'Z' | 'a' .. 'z' ) ( '-' | '_' | 'A' .. 'Z' | 'a' .. 'z' | '0' .. '9' )* ) # GDBMI.g:192:4: ( '_' | 'A' .. 'Z' | 'a' .. 'z' ) ( '-' | '_' | 'A' .. 'Z' | 'a' .. 'z' | '0' .. '9' )* pass if (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # GDBMI.g:192:31: ( '-' | '_' | 'A' .. 'Z' | 'a' .. 'z' | '0' .. '9' )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == 45 or (48 <= LA3_0 <= 57) or (65 <= LA3_0 <= 90) or LA3_0 == 95 or (97 <= LA3_0 <= 122)) : alt3 = 1 if alt3 == 1: # GDBMI.g: pass if self.input.LA(1) == 45 or (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop3 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "NL" def mNL(self, ): try: _type = NL _channel = DEFAULT_CHANNEL # GDBMI.g:195:2: ( ( '\\r' )? '\\n' ) # GDBMI.g:195:4: ( '\\r' )? '\\n' pass # GDBMI.g:195:4: ( '\\r' )? alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 13) : alt4 = 1 if alt4 == 1: # GDBMI.g:195:5: '\\r' pass self.match(13) self.match(10) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NL" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # GDBMI.g:198:2: ( ( ' ' | '\\t' ) ) # GDBMI.g:198:4: ( ' ' | '\\t' ) pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "TOKEN" def mTOKEN(self, ): try: _type = TOKEN _channel = DEFAULT_CHANNEL # GDBMI.g:200:2: ( ( '0' .. '9' )+ ) # GDBMI.g:200:4: ( '0' .. '9' )+ pass # GDBMI.g:200:4: ( '0' .. '9' )+ cnt5 = 0 while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if ((48 <= LA5_0 <= 57)) : alt5 = 1 if alt5 == 1: # GDBMI.g:200:5: '0' .. '9' pass self.matchRange(48, 57) else: if cnt5 >= 1: break #loop5 eee = EarlyExitException(5, self.input) raise eee cnt5 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "TOKEN" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # GDBMI.g:202:7: ( ',' ) # GDBMI.g:202:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "EOM" def mEOM(self, ): try: _type = EOM _channel = DEFAULT_CHANNEL # GDBMI.g:204:5: ( '(gdb)' ) # GDBMI.g:204:7: '(gdb)' pass self.match("(gdb)") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EOM" # $ANTLR start "CONSOLE" def mCONSOLE(self, ): try: _type = CONSOLE _channel = DEFAULT_CHANNEL # GDBMI.g:206:9: ( '~' ) # GDBMI.g:206:11: '~' pass self.match(126) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CONSOLE" # $ANTLR start "TARGET" def mTARGET(self, ): try: _type = TARGET _channel = DEFAULT_CHANNEL # GDBMI.g:207:9: ( '@' ) # GDBMI.g:207:11: '@' pass self.match(64) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "TARGET" # $ANTLR start "LOG" def mLOG(self, ): try: _type = LOG _channel = DEFAULT_CHANNEL # GDBMI.g:208:6: ( '&' ) # GDBMI.g:208:8: '&' pass self.match(38) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LOG" # $ANTLR start "EXEC" def mEXEC(self, ): try: _type = EXEC _channel = DEFAULT_CHANNEL # GDBMI.g:210:7: ( '*' ) # GDBMI.g:210:9: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EXEC" # $ANTLR start "STATUS" def mSTATUS(self, ): try: _type = STATUS _channel = DEFAULT_CHANNEL # GDBMI.g:211:9: ( '+' ) # GDBMI.g:211:11: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STATUS" # $ANTLR start "NOTIFY" def mNOTIFY(self, ): try: _type = NOTIFY _channel = DEFAULT_CHANNEL # GDBMI.g:212:9: ( '=' ) # GDBMI.g:212:11: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NOTIFY" # $ANTLR start "RESULT" def mRESULT(self, ): try: _type = RESULT _channel = DEFAULT_CHANNEL # GDBMI.g:214:8: ( '^' ) # GDBMI.g:214:10: '^' pass self.match(94) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RESULT" def mTokens(self): # GDBMI.g:1:8: ( T__19 | T__20 | T__21 | T__22 | T__23 | T__24 | C_STRING | RESULT_CLASS | STRING | NL | WS | TOKEN | COMMA | EOM | CONSOLE | TARGET | LOG | EXEC | STATUS | NOTIFY | RESULT ) alt6 = 21 alt6 = self.dfa6.predict(self.input) if alt6 == 1: # GDBMI.g:1:10: T__19 pass self.mT__19() elif alt6 == 2: # GDBMI.g:1:16: T__20 pass self.mT__20() elif alt6 == 3: # GDBMI.g:1:22: T__21 pass self.mT__21() elif alt6 == 4: # GDBMI.g:1:28: T__22 pass self.mT__22() elif alt6 == 5: # GDBMI.g:1:34: T__23 pass self.mT__23() elif alt6 == 6: # GDBMI.g:1:40: T__24 pass self.mT__24() elif alt6 == 7: # GDBMI.g:1:46: C_STRING pass self.mC_STRING() elif alt6 == 8: # GDBMI.g:1:55: RESULT_CLASS pass self.mRESULT_CLASS() elif alt6 == 9: # GDBMI.g:1:68: STRING pass self.mSTRING() elif alt6 == 10: # GDBMI.g:1:75: NL pass self.mNL() elif alt6 == 11: # GDBMI.g:1:78: WS pass self.mWS() elif alt6 == 12: # GDBMI.g:1:81: TOKEN pass self.mTOKEN() elif alt6 == 13: # GDBMI.g:1:87: COMMA pass self.mCOMMA() elif alt6 == 14: # GDBMI.g:1:93: EOM pass self.mEOM() elif alt6 == 15: # GDBMI.g:1:97: CONSOLE pass self.mCONSOLE() elif alt6 == 16: # GDBMI.g:1:105: TARGET pass self.mTARGET() elif alt6 == 17: # GDBMI.g:1:112: LOG pass self.mLOG() elif alt6 == 18: # GDBMI.g:1:116: EXEC pass self.mEXEC() elif alt6 == 19: # GDBMI.g:1:121: STATUS pass self.mSTATUS() elif alt6 == 20: # GDBMI.g:1:128: NOTIFY pass self.mNOTIFY() elif alt6 == 21: # GDBMI.g:1:135: RESULT pass self.mRESULT() # lookup tables for DFA #2 DFA2_eot = DFA.unpack( u"\33\uffff" ) DFA2_eof = DFA.unpack( u"\33\uffff" ) DFA2_min = DFA.unpack( u"\1\143\1\157\2\uffff\1\162\1\uffff\1\150\1\156\2\uffff\1\162\2" u"\uffff\1\145\1\141\1\144\1\55\1\143\1\162\1\uffff\1\157\1\165\1" u"\160\1\55\1\143\2\uffff" ) DFA2_max = DFA.unpack( u"\1\164\1\157\2\uffff\1\170\1\uffff\1\150\1\167\2\uffff\1\162\2" u"\uffff\1\145\1\141\1\144\1\55\1\147\1\162\1\uffff\1\157\1\165\1" u"\160\1\55\1\145\2\uffff" ) DFA2_accept = DFA.unpack( u"\2\uffff\1\2\1\3\1\uffff\1\6\2\uffff\1\4\1\5\1\uffff\1\1\1\11" u"\6\uffff\1\10\5\uffff\1\7\1\12" ) DFA2_special = DFA.unpack( u"\33\uffff" ) DFA2_transition = [ DFA.unpack(u"\1\3\1\1\1\4\14\uffff\1\2\1\5\1\6"), DFA.unpack(u"\1\7"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\10\5\uffff\1\11"), DFA.unpack(u""), DFA.unpack(u"\1\12"), DFA.unpack(u"\1\13\10\uffff\1\14"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\15"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\16"), DFA.unpack(u"\1\17"), DFA.unpack(u"\1\20"), DFA.unpack(u"\1\21"), DFA.unpack(u"\1\23\3\uffff\1\22"), DFA.unpack(u"\1\24"), DFA.unpack(u""), DFA.unpack(u"\1\25"), DFA.unpack(u"\1\26"), DFA.unpack(u"\1\27"), DFA.unpack(u"\1\30"), DFA.unpack(u"\1\31\1\uffff\1\32"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #2 DFA2 = DFA # lookup tables for DFA #6 DFA6_eot = DFA.unpack( u"\1\uffff\1\32\1\uffff\1\34\2\uffff\6\14\21\uffff\17\14\1\64\4" u"\14\1\64\2\14\1\uffff\3\14\1\64\10\14\1\64\1\14\1\64\1\14\1\64" u"\3\14\1\64\14\14\1\64\11\14\2\64" ) DFA6_eof = DFA.unpack( u"\142\uffff" ) DFA6_min = DFA.unpack( u"\1\11\1\175\1\uffff\1\135\2\uffff\1\157\1\165\1\157\1\162\1\164" u"\1\150\21\uffff\3\156\1\162\1\151\1\157\1\162\1\145\3\156\1\157" u"\1\164\1\160\1\145\1\55\1\154\1\151\1\145\1\162\1\55\1\160\1\141" u"\1\uffff\1\157\1\156\1\143\1\55\1\145\1\144\1\141\1\147\1\164\1" u"\144\1\55\1\144\1\55\1\145\1\55\1\143\1\55\1\144\2\162\1\55\1\157" u"\1\145\1\165\1\141\1\160\1\164\1\55\1\145\1\143\1\144\1\162\1\170" u"\1\55\1\145\1\151\1\141\2\164\2\145\2\144\2\55" ) DFA6_max = DFA.unpack( u"\1\176\1\175\1\uffff\1\135\2\uffff\1\157\1\165\1\157\1\170\1\164" u"\1\150\21\uffff\1\167\2\156\1\162\1\151\1\157\1\162\1\145\3\156" u"\1\157\1\164\1\160\1\145\1\172\1\154\1\151\1\145\1\162\1\172\1" u"\160\1\141\1\uffff\1\157\1\156\1\143\1\172\1\145\1\144\1\141\1" u"\147\1\164\1\144\1\55\1\144\1\172\1\145\1\172\1\147\1\172\1\144" u"\2\162\1\172\1\157\1\145\1\165\1\141\1\160\1\164\1\55\2\145\1\144" u"\1\162\1\170\1\172\1\145\1\151\1\141\2\164\2\145\2\144\2\172" ) DFA6_accept = DFA.unpack( u"\2\uffff\1\3\1\uffff\1\6\1\7\6\uffff\1\11\1\12\1\13\1\14\1\15" u"\1\16\1\17\1\20\1\21\1\22\1\23\1\24\1\25\1\1\1\2\1\4\1\5\27\uffff" u"\1\10\55\uffff" ) DFA6_special = DFA.unpack( u"\142\uffff" ) DFA6_transition = [ DFA.unpack(u"\1\16\1\15\2\uffff\1\15\22\uffff\1\16\1\uffff\1\5\3" u"\uffff\1\24\1\uffff\1\21\1\uffff\1\25\1\26\1\20\3\uffff\12\17\3" u"\uffff\1\27\2\uffff\1\23\32\14\1\3\1\uffff\1\4\1\30\1\14\1\uffff" u"\2\14\1\10\1\6\1\11\14\14\1\7\1\12\1\13\6\14\1\1\1\uffff\1\2\1" u"\22"), DFA.unpack(u"\1\31"), DFA.unpack(u""), DFA.unpack(u"\1\33"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\35"), DFA.unpack(u"\1\36"), DFA.unpack(u"\1\37"), DFA.unpack(u"\1\40\5\uffff\1\41"), DFA.unpack(u"\1\42"), DFA.unpack(u"\1\43"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\44\10\uffff\1\45"), DFA.unpack(u"\1\46"), DFA.unpack(u"\1\47"), DFA.unpack(u"\1\50"), DFA.unpack(u"\1\51"), DFA.unpack(u"\1\52"), DFA.unpack(u"\1\53"), DFA.unpack(u"\1\54"), DFA.unpack(u"\1\55"), DFA.unpack(u"\1\56"), DFA.unpack(u"\1\57"), DFA.unpack(u"\1\60"), DFA.unpack(u"\1\61"), DFA.unpack(u"\1\62"), DFA.unpack(u"\1\63"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\65"), DFA.unpack(u"\1\66"), DFA.unpack(u"\1\67"), DFA.unpack(u"\1\70"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\71"), DFA.unpack(u"\1\72"), DFA.unpack(u""), DFA.unpack(u"\1\73"), DFA.unpack(u"\1\74"), DFA.unpack(u"\1\75"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\76"), DFA.unpack(u"\1\77"), DFA.unpack(u"\1\100"), DFA.unpack(u"\1\101"), DFA.unpack(u"\1\102"), DFA.unpack(u"\1\103"), DFA.unpack(u"\1\104"), DFA.unpack(u"\1\105"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\106"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\110\3\uffff\1\107"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\111"), DFA.unpack(u"\1\112"), DFA.unpack(u"\1\113"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\114"), DFA.unpack(u"\1\115"), DFA.unpack(u"\1\116"), DFA.unpack(u"\1\117"), DFA.unpack(u"\1\120"), DFA.unpack(u"\1\121"), DFA.unpack(u"\1\122"), DFA.unpack(u"\1\123"), DFA.unpack(u"\1\124\1\uffff\1\125"), DFA.unpack(u"\1\126"), DFA.unpack(u"\1\127"), DFA.unpack(u"\1\130"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\131"), DFA.unpack(u"\1\132"), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134"), DFA.unpack(u"\1\135"), DFA.unpack(u"\1\136"), DFA.unpack(u"\1\137"), DFA.unpack(u"\1\140"), DFA.unpack(u"\1\141"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14"), DFA.unpack(u"\1\14\2\uffff\12\14\7\uffff\32\14\4\uffff\1\14\1\uffff" u"\32\14") ] # class definition for DFA #6 DFA6 = DFA def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(GDBMILexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ryansturmer/cuttlebug", "path": "cuttlebug/gdb/GDBMILexer.py", "copies": "1", "size": "26732", "license": "mit", "hash": 1394230063792045600, "line_mean": 21.1445887446, "line_max": 198, "alpha_frac": 0.4017656741, "autogenerated": false, "ratio": 3.03427922814983, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.8887278591344803, "avg_score": 0.009753262181005438, "num_lines": 1155 }
# $ANTLR 3.1.2 /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g 2012-10-19 23:25:10 import sys from antlr3 import * from antlr3.compat import set, frozenset #docstring __doc__ = """Parser for reading FCL by the pyfuzzy package.""" __revision__ = "$Id: FCLParser.py,v 1.9 2013-01-09 20:10:19 rliebscher Exp $" import fuzzy.System import fuzzy.InputVariable import fuzzy.OutputVariable import fuzzy.Adjective import fuzzy.set.Polygon import fuzzy.set.Singleton import fuzzy.defuzzify import fuzzy.defuzzify.Dict import fuzzy.fuzzify import fuzzy.fuzzify.Plain import fuzzy.fuzzify.Dict import fuzzy.operator.Not import fuzzy.operator.Input import fuzzy.operator.Compound import fuzzy.Rule import fuzzy.norm.Min import fuzzy.norm.Max def getNorm(name, p=None): """Get an instance of a fuzzy norm with given name. Normally looks into the fuzzy.norm package for a suitable class. """ m = __import__("fuzzy.norm."+name, fromlist=[name]) c = m.__dict__[name] if p is None: return c() else: return c(p) def getSet(name, params=[]): """Get an instance of a fuzzy set with given name. Normally looks into the fuzzy.set package for a suitable class. """ m = __import__("fuzzy.set."+name, fromlist=[name]) c = m.__dict__[name] return c(*params) def getDefuzzificationMethod(name): """Get an instance of a defuzzification method with given name. Normally looks into the fuzzy.defuzzify package for a suitable class. """ m = __import__("fuzzy.defuzzify."+name, fromlist=[name]) c = m.__dict__[name] return c() # container for definitions of operator/norm pairs _operators = { "AND":fuzzy.norm.Min.Min(), "OR":fuzzy.norm.Max.Max() } def defineOperator(name, norm): """Defines a operator (AND,OR,...) to use a given norm.""" _operators[name] = norm #print "defineOperator ",name,norm def getOperator(name): """Get the norm for previous defined operator name.""" #print "getOperator ",name import copy return copy.deepcopy(_operators[name]) _structs = {} def defineStructType(name): """Remember name of a struct definition""" _structs[name] = [] def defineStructTypeElement(name, elem): """Add a struct element""" _structs[name].append(elem) def getStructType(name): """Get list of elements of a struct definition""" return _structs[name] # pylint: disable-msg=W0107,W0301,W0401,W0614,W0621,C0103,C0111,C0301,C0302,C0322,C0324,R0904,R0912,R0915 #ID:W0107 : Unnecessary pass statement #ID:W0301 : Unnecessary semicolon #ID:W0401 : Wildcard import antlr3 #ID:W0614 : Unused import ... from wildcard import #ID:W0621 : Redefining name 'main' from outer scope #ID:C0103 : Invalid name #ID:C0111 : Missing docstring #ID:C0301 : Line too long #ID:C0302 : Too many lines in module #ID:C0322 : Operator not preceded by a space #ID:C0324 : Comma not followed by a space #ID:R0912 : Too many branches #ID:R0915 : Too many statements #ID:R0904 : Too many public methods # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types T__29=29 T__28=28 Real_literal=9 OR_=6 T__27=27 T__26=26 T__25=25 T__24=24 LETTER=10 T__23=23 T__22=22 T__21=21 T__20=20 AND_=7 EOF=-1 Identifier=4 T__55=55 T__56=56 T__19=19 T__57=57 T__58=58 T__16=16 T__51=51 T__15=15 T__52=52 T__18=18 T__53=53 T__54=54 T__17=17 Integer_literal_wo_sign=11 T__14=14 T__59=59 DIGIT=5 COMMENT=13 T__50=50 T__42=42 T__43=43 T__40=40 T__41=41 T__46=46 T__47=47 T__44=44 T__45=45 T__48=48 T__49=49 T__30=30 T__31=31 T__32=32 WS=12 T__33=33 T__34=34 Integer_literal=8 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "Identifier", "DIGIT", "OR_", "AND_", "Integer_literal", "Real_literal", "LETTER", "Integer_literal_wo_sign", "WS", "COMMENT", "'FUNCTION_BLOCK'", "'END_FUNCTION_BLOCK'", "'STRUCT'", "'END_STRUCT'", "':'", "'REAL'", "';'", "'VAR_INPUT'", "'END_VAR'", "'VAR_OUTPUT'", "'FUZZIFY'", "'END_FUZZIFY'", "'DEFUZZIFY'", "'END_DEFUZZIFY'", "'RULEBLOCK'", "'END_RULEBLOCK'", "'OPTION'", "'END_OPTION'", "'TERM'", "':='", "'('", "','", "')'", "'METHOD'", "'DEFAULT'", "'NC'", "'RANGE'", "'..'", "'['", "']'", "'MIN'", "'PROD'", "'BDIF'", "'MAX'", "'ASUM'", "'BSUM'", "'ACT'", "'ACCU'", "'NSUM'", "'NOT'", "'IS'", "'.'", "'RULE'", "'IF'", "'THEN'", "'WITH'" ] class FCLParser(Parser): grammarFileName = "/work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g" antlr_version = version_str_to_tuple("3.1.2") antlr_version_str = "3.1.2" tokenNames = tokenNames def __init__(self, input, state=None): if state is None: state = RecognizerSharedState() Parser.__init__(self, input, state) self.System = None # test # $ANTLR start "main" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:154:1: main returns [system] : function_block_declaration ; def main(self, ): system = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:154:23: ( function_block_declaration ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:154:25: function_block_declaration pass #action start self.System = None; #action end self._state.following.append(self.FOLLOW_function_block_declaration_in_main55) self.function_block_declaration() self._state.following.pop() #action start system = self.System #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return system # $ANTLR end "main" # $ANTLR start "function_block_declaration" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:156:1: function_block_declaration : 'FUNCTION_BLOCK' function_block_name ( type_definition )* ( fb_io_var_declarations )* function_block_body 'END_FUNCTION_BLOCK' EOF ; def function_block_declaration(self, ): function_block_name1 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:157:3: ( 'FUNCTION_BLOCK' function_block_name ( type_definition )* ( fb_io_var_declarations )* function_block_body 'END_FUNCTION_BLOCK' EOF ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:158:5: 'FUNCTION_BLOCK' function_block_name ( type_definition )* ( fb_io_var_declarations )* function_block_body 'END_FUNCTION_BLOCK' EOF pass self.match(self.input, 14, self.FOLLOW_14_in_function_block_declaration71) self._state.following.append(self.FOLLOW_function_block_name_in_function_block_declaration77) function_block_name1 = self.function_block_name() self._state.following.pop() #action start self.System = fuzzy.System.System(description=((function_block_name1 is not None) and [self.input.toString(function_block_name1.start,function_block_name1.stop)] or [None])[0]); #action end # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:160:5: ( type_definition )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == 16) : alt1 = 1 if alt1 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:160:5: type_definition pass self._state.following.append(self.FOLLOW_type_definition_in_function_block_declaration85) self.type_definition() self._state.following.pop() else: break #loop1 # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:161:5: ( fb_io_var_declarations )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == 21 or LA2_0 == 23) : alt2 = 1 if alt2 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:161:5: fb_io_var_declarations pass self._state.following.append(self.FOLLOW_fb_io_var_declarations_in_function_block_declaration92) self.fb_io_var_declarations() self._state.following.pop() else: break #loop2 self._state.following.append(self.FOLLOW_function_block_body_in_function_block_declaration100) self.function_block_body() self._state.following.pop() self.match(self.input, 15, self.FOLLOW_15_in_function_block_declaration106) self.match(self.input, EOF, self.FOLLOW_EOF_in_function_block_declaration112) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "function_block_declaration" # $ANTLR start "type_definition" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:168:1: type_definition : 'STRUCT' Identifier ( struct_element[$Identifier.text] )+ 'END_STRUCT' ; def type_definition(self, ): Identifier2 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:169:3: ( 'STRUCT' Identifier ( struct_element[$Identifier.text] )+ 'END_STRUCT' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:169:6: 'STRUCT' Identifier ( struct_element[$Identifier.text] )+ 'END_STRUCT' pass self.match(self.input, 16, self.FOLLOW_16_in_type_definition126) Identifier2=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_type_definition128) #action start defineStructType(Identifier2.text); #action end # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:169:66: ( struct_element[$Identifier.text] )+ cnt3 = 0 while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == Identifier) : alt3 = 1 if alt3 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:169:66: struct_element[$Identifier.text] pass self._state.following.append(self.FOLLOW_struct_element_in_type_definition132) self.struct_element(Identifier2.text) self._state.following.pop() else: if cnt3 >= 1: break #loop3 eee = EarlyExitException(3, self.input) raise eee cnt3 += 1 self.match(self.input, 17, self.FOLLOW_17_in_type_definition136) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "type_definition" # $ANTLR start "struct_element" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:172:1: struct_element[struct_name] : Identifier ':' 'REAL' ';' ; def struct_element(self, struct_name): Identifier3 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:173:3: ( Identifier ':' 'REAL' ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:173:6: Identifier ':' 'REAL' ';' pass Identifier3=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_struct_element151) self.match(self.input, 18, self.FOLLOW_18_in_struct_element153) self.match(self.input, 19, self.FOLLOW_19_in_struct_element155) self.match(self.input, 20, self.FOLLOW_20_in_struct_element157) #action start defineStructTypeElement(struct_name, Identifier3.text); #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "struct_element" # $ANTLR start "fb_io_var_declarations" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:176:1: fb_io_var_declarations : ( input_declarations | output_declarations ); def fb_io_var_declarations(self, ): try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:177:3: ( input_declarations | output_declarations ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 21) : alt4 = 1 elif (LA4_0 == 23) : alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:177:5: input_declarations pass self._state.following.append(self.FOLLOW_input_declarations_in_fb_io_var_declarations172) self.input_declarations() self._state.following.pop() elif alt4 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:178:5: output_declarations pass self._state.following.append(self.FOLLOW_output_declarations_in_fb_io_var_declarations178) self.output_declarations() self._state.following.pop() except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "fb_io_var_declarations" # $ANTLR start "input_declarations" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:181:1: input_declarations : 'VAR_INPUT' ( var_decl[0] )+ 'END_VAR' ; def input_declarations(self, ): try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:181:20: ( 'VAR_INPUT' ( var_decl[0] )+ 'END_VAR' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:181:22: 'VAR_INPUT' ( var_decl[0] )+ 'END_VAR' pass self.match(self.input, 21, self.FOLLOW_21_in_input_declarations189) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:181:34: ( var_decl[0] )+ cnt5 = 0 while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == Identifier) : alt5 = 1 if alt5 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:181:34: var_decl[0] pass self._state.following.append(self.FOLLOW_var_decl_in_input_declarations191) self.var_decl(0) self._state.following.pop() else: if cnt5 >= 1: break #loop5 eee = EarlyExitException(5, self.input) raise eee cnt5 += 1 self.match(self.input, 22, self.FOLLOW_22_in_input_declarations195) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "input_declarations" # $ANTLR start "output_declarations" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:182:1: output_declarations : 'VAR_OUTPUT' ( var_decl[1] )+ 'END_VAR' ; def output_declarations(self, ): try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:182:21: ( 'VAR_OUTPUT' ( var_decl[1] )+ 'END_VAR' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:182:23: 'VAR_OUTPUT' ( var_decl[1] )+ 'END_VAR' pass self.match(self.input, 23, self.FOLLOW_23_in_output_declarations203) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:182:36: ( var_decl[1] )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == Identifier) : alt6 = 1 if alt6 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:182:36: var_decl[1] pass self._state.following.append(self.FOLLOW_var_decl_in_output_declarations205) self.var_decl(1) self._state.following.pop() else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 self.match(self.input, 22, self.FOLLOW_22_in_output_declarations209) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "output_declarations" # $ANTLR start "var_decl" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:185:1: var_decl[output_var] : Identifier ':' type ';' ; def var_decl(self, output_var): Identifier5 = None type4 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:186:3: ( Identifier ':' type ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:187:3: Identifier ':' type ';' pass Identifier5=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_var_decl223) self.match(self.input, 18, self.FOLLOW_18_in_var_decl227) self._state.following.append(self.FOLLOW_type_in_var_decl231) type4 = self.type() self._state.following.pop() self.match(self.input, 20, self.FOLLOW_20_in_var_decl235) #action start if output_var == 0: var=fuzzy.InputVariable.InputVariable() if type4 is not None: # set fuzzification method to dictionary input var.fuzzify = fuzzy.fuzzify.Dict.Dict(); # create adjectives for all struct members for i in type4: var.adjectives[i] = fuzzy.Adjective.Adjective(fuzzy.set.Set.Set()) else: # default is the plain fuzzification var.fuzzify = fuzzy.fuzzify.Plain.Plain(); else: var = fuzzy.OutputVariable.OutputVariable() if type4 is not None: # set defuzzification method to dictionary output var.defuzzify = fuzzy.defuzzify.Dict.Dict(); # create adjectives for all struct members for i in type4: var.adjectives[i] = fuzzy.Adjective.Adjective(fuzzy.set.Set.Set()) self.System.variables[Identifier5.text]=var; #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "var_decl" # $ANTLR start "type" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:215:1: type returns [struct_type] : ( 'REAL' | Identifier ); def type(self, ): struct_type = None Identifier6 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:216:3: ( 'REAL' | Identifier ) alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 19) : alt7 = 1 elif (LA7_0 == Identifier) : alt7 = 2 else: nvae = NoViableAltException("", 7, 0, self.input) raise nvae if alt7 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:217:3: 'REAL' pass self.match(self.input, 19, self.FOLLOW_19_in_type254) #action start struct_type = None #action end elif alt7 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:219:3: Identifier pass Identifier6=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_type264) #action start struct_type = getStructType(Identifier6.text) #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return struct_type # $ANTLR end "type" # $ANTLR start "function_block_body" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:225:1: function_block_body : ( fuzzify_block )* ( defuzzify_block )* ( rule_block )* ( option_block )* ; def function_block_body(self, ): try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:226:3: ( ( fuzzify_block )* ( defuzzify_block )* ( rule_block )* ( option_block )* ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:227:5: ( fuzzify_block )* ( defuzzify_block )* ( rule_block )* ( option_block )* pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:227:5: ( fuzzify_block )* while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == 24) : alt8 = 1 if alt8 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:227:5: fuzzify_block pass self._state.following.append(self.FOLLOW_fuzzify_block_in_function_block_body286) self.fuzzify_block() self._state.following.pop() else: break #loop8 # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:228:5: ( defuzzify_block )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == 26) : alt9 = 1 if alt9 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:228:5: defuzzify_block pass self._state.following.append(self.FOLLOW_defuzzify_block_in_function_block_body293) self.defuzzify_block() self._state.following.pop() else: break #loop9 # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:229:5: ( rule_block )* while True: #loop10 alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 28) : alt10 = 1 if alt10 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:229:5: rule_block pass self._state.following.append(self.FOLLOW_rule_block_in_function_block_body300) self.rule_block() self._state.following.pop() else: break #loop10 # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:230:5: ( option_block )* while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == 30) : alt11 = 1 if alt11 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:230:5: option_block pass self._state.following.append(self.FOLLOW_option_block_in_function_block_body307) self.option_block() self._state.following.pop() else: break #loop11 except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "function_block_body" # $ANTLR start "fuzzify_block" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:233:1: fuzzify_block : 'FUZZIFY' variable_name ( linguistic_term[$variable_name.text] )* 'END_FUZZIFY' ; def fuzzify_block(self, ): variable_name7 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:234:3: ( 'FUZZIFY' variable_name ( linguistic_term[$variable_name.text] )* 'END_FUZZIFY' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:235:5: 'FUZZIFY' variable_name ( linguistic_term[$variable_name.text] )* 'END_FUZZIFY' pass self.match(self.input, 24, self.FOLLOW_24_in_fuzzify_block325) self._state.following.append(self.FOLLOW_variable_name_in_fuzzify_block331) variable_name7 = self.variable_name() self._state.following.pop() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:237:5: ( linguistic_term[$variable_name.text] )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == 32) : alt12 = 1 if alt12 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:237:5: linguistic_term[$variable_name.text] pass self._state.following.append(self.FOLLOW_linguistic_term_in_fuzzify_block337) self.linguistic_term(((variable_name7 is not None) and [self.input.toString(variable_name7.start,variable_name7.stop)] or [None])[0]) self._state.following.pop() else: break #loop12 self.match(self.input, 25, self.FOLLOW_25_in_fuzzify_block345) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "fuzzify_block" # $ANTLR start "defuzzify_block" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:241:1: defuzzify_block : 'DEFUZZIFY' f_variable_name ( linguistic_term[$f_variable_name.text] )* accumulation_method defuzzification_method[$f_variable_name.text] ( default_value[$f_variable_name.text] )? ( range )? 'END_DEFUZZIFY' ; def defuzzify_block(self, ): f_variable_name8 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:242:3: ( 'DEFUZZIFY' f_variable_name ( linguistic_term[$f_variable_name.text] )* accumulation_method defuzzification_method[$f_variable_name.text] ( default_value[$f_variable_name.text] )? ( range )? 'END_DEFUZZIFY' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:243:5: 'DEFUZZIFY' f_variable_name ( linguistic_term[$f_variable_name.text] )* accumulation_method defuzzification_method[$f_variable_name.text] ( default_value[$f_variable_name.text] )? ( range )? 'END_DEFUZZIFY' pass self.match(self.input, 26, self.FOLLOW_26_in_defuzzify_block362) self._state.following.append(self.FOLLOW_f_variable_name_in_defuzzify_block368) f_variable_name8 = self.f_variable_name() self._state.following.pop() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:245:5: ( linguistic_term[$f_variable_name.text] )* while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == 32) : alt13 = 1 if alt13 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:245:5: linguistic_term[$f_variable_name.text] pass self._state.following.append(self.FOLLOW_linguistic_term_in_defuzzify_block374) self.linguistic_term(((f_variable_name8 is not None) and [self.input.toString(f_variable_name8.start,f_variable_name8.stop)] or [None])[0]) self._state.following.pop() else: break #loop13 self._state.following.append(self.FOLLOW_accumulation_method_in_defuzzify_block382) self.accumulation_method() self._state.following.pop() self._state.following.append(self.FOLLOW_defuzzification_method_in_defuzzify_block388) self.defuzzification_method(((f_variable_name8 is not None) and [self.input.toString(f_variable_name8.start,f_variable_name8.stop)] or [None])[0]) self._state.following.pop() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:248:5: ( default_value[$f_variable_name.text] )? alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == 38) : alt14 = 1 if alt14 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:248:5: default_value[$f_variable_name.text] pass self._state.following.append(self.FOLLOW_default_value_in_defuzzify_block395) self.default_value(((f_variable_name8 is not None) and [self.input.toString(f_variable_name8.start,f_variable_name8.stop)] or [None])[0]) self._state.following.pop() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:249:5: ( range )? alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == 40) : alt15 = 1 if alt15 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:249:5: range pass self._state.following.append(self.FOLLOW_range_in_defuzzify_block403) self.range() self._state.following.pop() self.match(self.input, 27, self.FOLLOW_27_in_defuzzify_block410) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "defuzzify_block" # $ANTLR start "rule_block" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:253:1: rule_block : 'RULEBLOCK' rule_block_name ( operator_definition )* ( activation_method )? ( rule[$rule_block_name.text] )* 'END_RULEBLOCK' ; def rule_block(self, ): rule_block_name9 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:254:3: ( 'RULEBLOCK' rule_block_name ( operator_definition )* ( activation_method )? ( rule[$rule_block_name.text] )* 'END_RULEBLOCK' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:255:5: 'RULEBLOCK' rule_block_name ( operator_definition )* ( activation_method )? ( rule[$rule_block_name.text] )* 'END_RULEBLOCK' pass self.match(self.input, 28, self.FOLLOW_28_in_rule_block427) self._state.following.append(self.FOLLOW_rule_block_name_in_rule_block435) rule_block_name9 = self.rule_block_name() self._state.following.pop() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:257:7: ( operator_definition )* while True: #loop16 alt16 = 2 LA16_0 = self.input.LA(1) if ((OR_ <= LA16_0 <= AND_)) : alt16 = 1 if alt16 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:257:7: operator_definition pass self._state.following.append(self.FOLLOW_operator_definition_in_rule_block443) self.operator_definition() self._state.following.pop() else: break #loop16 # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:258:7: ( activation_method )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == 50) : alt17 = 1 if alt17 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:258:7: activation_method pass self._state.following.append(self.FOLLOW_activation_method_in_rule_block452) self.activation_method() self._state.following.pop() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:259:7: ( rule[$rule_block_name.text] )* while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == 56) : alt18 = 1 if alt18 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:259:7: rule[$rule_block_name.text] pass self._state.following.append(self.FOLLOW_rule_in_rule_block461) self.rule(((rule_block_name9 is not None) and [self.input.toString(rule_block_name9.start,rule_block_name9.stop)] or [None])[0]) self._state.following.pop() else: break #loop18 self.match(self.input, 29, self.FOLLOW_29_in_rule_block469) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "rule_block" # $ANTLR start "option_block" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:262:1: option_block : 'OPTION' 'END_OPTION' ; def option_block(self, ): try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:262:14: ( 'OPTION' 'END_OPTION' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:262:16: 'OPTION' 'END_OPTION' pass self.match(self.input, 30, self.FOLLOW_30_in_option_block477) self.match(self.input, 31, self.FOLLOW_31_in_option_block481) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "option_block" # $ANTLR start "linguistic_term" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:267:1: linguistic_term[var_name] : 'TERM' term_name ':=' membership_function ';' ; def linguistic_term(self, var_name): term_name10 = None membership_function11 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:268:3: ( 'TERM' term_name ':=' membership_function ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:269:3: 'TERM' term_name ':=' membership_function ';' pass self.match(self.input, 32, self.FOLLOW_32_in_linguistic_term496) self._state.following.append(self.FOLLOW_term_name_in_linguistic_term498) term_name10 = self.term_name() self._state.following.pop() self.match(self.input, 33, self.FOLLOW_33_in_linguistic_term500) self._state.following.append(self.FOLLOW_membership_function_in_linguistic_term502) membership_function11 = self.membership_function() self._state.following.pop() self.match(self.input, 20, self.FOLLOW_20_in_linguistic_term504) #action start self.System.variables[var_name].adjectives[((term_name10 is not None) and [self.input.toString(term_name10.start,term_name10.stop)] or [None])[0]] = fuzzy.Adjective.Adjective(membership_function11); #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "linguistic_term" # $ANTLR start "membership_function" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:276:1: membership_function returns [set] : ( singleton | points | pyfuzzy_set ); def membership_function(self, ): set = None singleton12 = None points13 = None pyfuzzy_set14 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:277:3: ( singleton | points | pyfuzzy_set ) alt19 = 3 LA19 = self.input.LA(1) if LA19 == Integer_literal or LA19 == Real_literal: alt19 = 1 elif LA19 == Identifier: LA19_2 = self.input.LA(2) if (LA19_2 == 34) : alt19 = 3 elif (LA19_2 == 20) : alt19 = 1 else: nvae = NoViableAltException("", 19, 2, self.input) raise nvae elif LA19 == 20 or LA19 == 34: alt19 = 2 else: nvae = NoViableAltException("", 19, 0, self.input) raise nvae if alt19 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:278:5: singleton pass self._state.following.append(self.FOLLOW_singleton_in_membership_function526) singleton12 = self.singleton() self._state.following.pop() #action start set = singleton12 #action end elif alt19 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:280:5: points pass self._state.following.append(self.FOLLOW_points_in_membership_function538) points13 = self.points() self._state.following.pop() #action start set = points13 #action end elif alt19 == 3: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:282:5: pyfuzzy_set pass self._state.following.append(self.FOLLOW_pyfuzzy_set_in_membership_function550) pyfuzzy_set14 = self.pyfuzzy_set() self._state.following.pop() #action start set = pyfuzzy_set14 #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return set # $ANTLR end "membership_function" # $ANTLR start "singleton" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:285:1: singleton returns [set] : ( numeric_literal | variable_name ); def singleton(self, ): set = None numeric_literal15 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:286:3: ( numeric_literal | variable_name ) alt20 = 2 LA20_0 = self.input.LA(1) if ((Integer_literal <= LA20_0 <= Real_literal)) : alt20 = 1 elif (LA20_0 == Identifier) : alt20 = 2 else: nvae = NoViableAltException("", 20, 0, self.input) raise nvae if alt20 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:287:5: numeric_literal pass self._state.following.append(self.FOLLOW_numeric_literal_in_singleton573) numeric_literal15 = self.numeric_literal() self._state.following.pop() #action start set = fuzzy.set.Singleton.Singleton(float(((numeric_literal15 is not None) and [self.input.toString(numeric_literal15.start,numeric_literal15.stop)] or [None])[0])) #action end elif alt20 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:289:5: variable_name pass self._state.following.append(self.FOLLOW_variable_name_in_singleton585) self.variable_name() self._state.following.pop() except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return set # $ANTLR end "singleton" # $ANTLR start "points" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:292:1: points returns [set] : ( '(' (x= numeric_literal | variable_name ) ',' y= numeric_literal ')' )* ; def points(self, ): set = None x = None y = None p = [] try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:296:3: ( ( '(' (x= numeric_literal | variable_name ) ',' y= numeric_literal ')' )* ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:297:4: ( '(' (x= numeric_literal | variable_name ) ',' y= numeric_literal ')' )* pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:297:4: ( '(' (x= numeric_literal | variable_name ) ',' y= numeric_literal ')' )* while True: #loop22 alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == 34) : alt22 = 1 if alt22 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:298:6: '(' (x= numeric_literal | variable_name ) ',' y= numeric_literal ')' pass self.match(self.input, 34, self.FOLLOW_34_in_points617) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:299:6: (x= numeric_literal | variable_name ) alt21 = 2 LA21_0 = self.input.LA(1) if ((Integer_literal <= LA21_0 <= Real_literal)) : alt21 = 1 elif (LA21_0 == Identifier) : alt21 = 2 else: nvae = NoViableAltException("", 21, 0, self.input) raise nvae if alt21 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:299:7: x= numeric_literal pass self._state.following.append(self.FOLLOW_numeric_literal_in_points627) x = self.numeric_literal() self._state.following.pop() elif alt21 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:299:27: variable_name pass self._state.following.append(self.FOLLOW_variable_name_in_points631) self.variable_name() self._state.following.pop() self.match(self.input, 35, self.FOLLOW_35_in_points639) self._state.following.append(self.FOLLOW_numeric_literal_in_points648) y = self.numeric_literal() self._state.following.pop() self.match(self.input, 36, self.FOLLOW_36_in_points655) #action start p.append((float(((x is not None) and [self.input.toString(x.start,x.stop)] or [None])[0]), float(((y is not None) and [self.input.toString(y.start,y.stop)] or [None])[0]))); #action end else: break #loop22 #action start set = fuzzy.set.Polygon.Polygon(p) #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return set # $ANTLR end "points" # $ANTLR start "pyfuzzy_set" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:308:1: pyfuzzy_set returns [set] : Identifier '(' (p1= numeric_literal ( ',' pn= numeric_literal )* )? ')' ; def pyfuzzy_set(self, ): set = None Identifier16 = None p1 = None pn = None p = [] try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:312:3: ( Identifier '(' (p1= numeric_literal ( ',' pn= numeric_literal )* )? ')' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:313:4: Identifier '(' (p1= numeric_literal ( ',' pn= numeric_literal )* )? ')' pass Identifier16=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_pyfuzzy_set699) self.match(self.input, 34, self.FOLLOW_34_in_pyfuzzy_set704) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:315:4: (p1= numeric_literal ( ',' pn= numeric_literal )* )? alt24 = 2 LA24_0 = self.input.LA(1) if ((Integer_literal <= LA24_0 <= Real_literal)) : alt24 = 1 if alt24 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:316:4: p1= numeric_literal ( ',' pn= numeric_literal )* pass self._state.following.append(self.FOLLOW_numeric_literal_in_pyfuzzy_set716) p1 = self.numeric_literal() self._state.following.pop() #action start p.append(float(((p1 is not None) and [self.input.toString(p1.start,p1.stop)] or [None])[0])); #action end # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:317:5: ( ',' pn= numeric_literal )* while True: #loop23 alt23 = 2 LA23_0 = self.input.LA(1) if (LA23_0 == 35) : alt23 = 1 if alt23 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:318:7: ',' pn= numeric_literal pass self.match(self.input, 35, self.FOLLOW_35_in_pyfuzzy_set732) self._state.following.append(self.FOLLOW_numeric_literal_in_pyfuzzy_set742) pn = self.numeric_literal() self._state.following.pop() #action start p.append(float(((pn is not None) and [self.input.toString(pn.start,pn.stop)] or [None])[0])); #action end else: break #loop23 self.match(self.input, 36, self.FOLLOW_36_in_pyfuzzy_set762) #action start set = getSet(Identifier16.text,p) #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return set # $ANTLR end "pyfuzzy_set" # $ANTLR start "defuzzification_method" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:328:1: defuzzification_method[var_name] : 'METHOD' ':' Identifier ';' ; def defuzzification_method(self, var_name): Identifier17 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:328:35: ( 'METHOD' ':' Identifier ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:329:3: 'METHOD' ':' Identifier ';' pass self.match(self.input, 37, self.FOLLOW_37_in_defuzzification_method785) self.match(self.input, 18, self.FOLLOW_18_in_defuzzification_method787) Identifier17=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_defuzzification_method791) #action start self.System.variables[var_name].defuzzify = getDefuzzificationMethod(Identifier17.text); #action end self.match(self.input, 20, self.FOLLOW_20_in_defuzzification_method797) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "defuzzification_method" # $ANTLR start "default_value" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:334:1: default_value[var_name] : 'DEFAULT' ':=' ( numeric_literal | 'NC' ) ';' ; def default_value(self, var_name): numeric_literal18 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:334:26: ( 'DEFAULT' ':=' ( numeric_literal | 'NC' ) ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:335:3: 'DEFAULT' ':=' ( numeric_literal | 'NC' ) ';' pass self.match(self.input, 38, self.FOLLOW_38_in_default_value812) self.match(self.input, 33, self.FOLLOW_33_in_default_value814) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:336:3: ( numeric_literal | 'NC' ) alt25 = 2 LA25_0 = self.input.LA(1) if ((Integer_literal <= LA25_0 <= Real_literal)) : alt25 = 1 elif (LA25_0 == 39) : alt25 = 2 else: nvae = NoViableAltException("", 25, 0, self.input) raise nvae if alt25 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:337:5: numeric_literal pass self._state.following.append(self.FOLLOW_numeric_literal_in_default_value824) numeric_literal18 = self.numeric_literal() self._state.following.pop() #action start self.System.variables[var_name].defuzzify.failsafe = float(((numeric_literal18 is not None) and [self.input.toString(numeric_literal18.start,numeric_literal18.stop)] or [None])[0]); #action end elif alt25 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:339:5: 'NC' pass self.match(self.input, 39, self.FOLLOW_39_in_default_value836) #action start self.System.variables[var_name].defuzzify.failsafe = None; #action end self.match(self.input, 20, self.FOLLOW_20_in_default_value846) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "default_value" # $ANTLR start "range" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:344:1: range : 'RANGE' ':=' '(' numeric_literal '..' numeric_literal ')' ';' ; def range(self, ): try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:344:7: ( 'RANGE' ':=' '(' numeric_literal '..' numeric_literal ')' ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:344:9: 'RANGE' ':=' '(' numeric_literal '..' numeric_literal ')' ';' pass self.match(self.input, 40, self.FOLLOW_40_in_range857) self.match(self.input, 33, self.FOLLOW_33_in_range859) self.match(self.input, 34, self.FOLLOW_34_in_range861) self._state.following.append(self.FOLLOW_numeric_literal_in_range863) self.numeric_literal() self._state.following.pop() self.match(self.input, 41, self.FOLLOW_41_in_range865) self._state.following.append(self.FOLLOW_numeric_literal_in_range867) self.numeric_literal() self._state.following.pop() self.match(self.input, 36, self.FOLLOW_36_in_range869) self.match(self.input, 20, self.FOLLOW_20_in_range871) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "range" # $ANTLR start "operator_name_any" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:347:1: operator_name_any returns [op] : i1= Identifier ( '[' param= numeric_literal ']' )? ; def operator_name_any(self, ): op = None i1 = None param = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:348:3: (i1= Identifier ( '[' param= numeric_literal ']' )? ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:349:3: i1= Identifier ( '[' param= numeric_literal ']' )? pass i1=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_operator_name_any890) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:349:17: ( '[' param= numeric_literal ']' )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == 42) : alt26 = 1 if alt26 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:349:18: '[' param= numeric_literal ']' pass self.match(self.input, 42, self.FOLLOW_42_in_operator_name_any893) self._state.following.append(self.FOLLOW_numeric_literal_in_operator_name_any897) param = self.numeric_literal() self._state.following.pop() self.match(self.input, 43, self.FOLLOW_43_in_operator_name_any899) #action start if ((param is not None) and [self.input.toString(param.start,param.stop)] or [None])[0] is not None: p = float(((param is not None) and [self.input.toString(param.start,param.stop)] or [None])[0]) else: p = None op = getNorm(i1.text, p) #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return op # $ANTLR end "operator_name_any" # $ANTLR start "operator_name_AND" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:359:1: operator_name_AND returns [op] : ( ( 'MIN' ) | ( 'PROD' ) | ( 'BDIF' ) | (norm= operator_name_any ) ); def operator_name_AND(self, ): op = None norm = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:360:3: ( ( 'MIN' ) | ( 'PROD' ) | ( 'BDIF' ) | (norm= operator_name_any ) ) alt27 = 4 LA27 = self.input.LA(1) if LA27 == 44: alt27 = 1 elif LA27 == 45: alt27 = 2 elif LA27 == 46: alt27 = 3 elif LA27 == Identifier: alt27 = 4 else: nvae = NoViableAltException("", 27, 0, self.input) raise nvae if alt27 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:360:5: ( 'MIN' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:360:5: ( 'MIN' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:360:6: 'MIN' pass self.match(self.input, 44, self.FOLLOW_44_in_operator_name_AND922) #action start op = getNorm("Min") #action end elif alt27 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:361:5: ( 'PROD' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:361:5: ( 'PROD' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:361:6: 'PROD' pass self.match(self.input, 45, self.FOLLOW_45_in_operator_name_AND932) #action start op = getNorm("AlgebraicProduct") #action end elif alt27 == 3: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:362:5: ( 'BDIF' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:362:5: ( 'BDIF' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:362:6: 'BDIF' pass self.match(self.input, 46, self.FOLLOW_46_in_operator_name_AND942) #action start op = getNorm("BoundedDifference") #action end elif alt27 == 4: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:363:5: (norm= operator_name_any ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:363:5: (norm= operator_name_any ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:363:6: norm= operator_name_any pass self._state.following.append(self.FOLLOW_operator_name_any_in_operator_name_AND955) norm = self.operator_name_any() self._state.following.pop() #action start op = norm #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return op # $ANTLR end "operator_name_AND" # $ANTLR start "operator_name_OR" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:366:1: operator_name_OR returns [op] : ( ( 'MAX' ) | ( 'ASUM' ) | ( 'BSUM' ) | (norm= operator_name_any ) ); def operator_name_OR(self, ): op = None norm = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:367:3: ( ( 'MAX' ) | ( 'ASUM' ) | ( 'BSUM' ) | (norm= operator_name_any ) ) alt28 = 4 LA28 = self.input.LA(1) if LA28 == 47: alt28 = 1 elif LA28 == 48: alt28 = 2 elif LA28 == 49: alt28 = 3 elif LA28 == Identifier: alt28 = 4 else: nvae = NoViableAltException("", 28, 0, self.input) raise nvae if alt28 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:367:5: ( 'MAX' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:367:5: ( 'MAX' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:367:6: 'MAX' pass self.match(self.input, 47, self.FOLLOW_47_in_operator_name_OR976) #action start op = getNorm("Max") #action end elif alt28 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:368:5: ( 'ASUM' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:368:5: ( 'ASUM' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:368:6: 'ASUM' pass self.match(self.input, 48, self.FOLLOW_48_in_operator_name_OR986) #action start op = getNorm("AlgebraicSum") #action end elif alt28 == 3: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:369:5: ( 'BSUM' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:369:5: ( 'BSUM' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:369:6: 'BSUM' pass self.match(self.input, 49, self.FOLLOW_49_in_operator_name_OR996) #action start op = getNorm("BoundedSum") #action end elif alt28 == 4: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:370:5: (norm= operator_name_any ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:370:5: (norm= operator_name_any ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:370:6: norm= operator_name_any pass self._state.following.append(self.FOLLOW_operator_name_any_in_operator_name_OR1009) norm = self.operator_name_any() self._state.following.pop() #action start op = norm #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return op # $ANTLR end "operator_name_OR" # $ANTLR start "operator_definition" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:376:1: operator_definition : ( (or_name= OR_ ':' or_op= operator_name_OR ) | (and_name= AND_ ':' and_op= operator_name_AND ) ) ';' ; def operator_definition(self, ): or_name = None and_name = None or_op = None and_op = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:376:21: ( ( (or_name= OR_ ':' or_op= operator_name_OR ) | (and_name= AND_ ':' and_op= operator_name_AND ) ) ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:377:1: ( (or_name= OR_ ':' or_op= operator_name_OR ) | (and_name= AND_ ':' and_op= operator_name_AND ) ) ';' pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:377:1: ( (or_name= OR_ ':' or_op= operator_name_OR ) | (and_name= AND_ ':' and_op= operator_name_AND ) ) alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == OR_) : alt29 = 1 elif (LA29_0 == AND_) : alt29 = 2 else: nvae = NoViableAltException("", 29, 0, self.input) raise nvae if alt29 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:378:1: (or_name= OR_ ':' or_op= operator_name_OR ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:378:1: (or_name= OR_ ':' or_op= operator_name_OR ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:378:2: or_name= OR_ ':' or_op= operator_name_OR pass or_name=self.match(self.input, OR_, self.FOLLOW_OR__in_operator_definition1053) self.match(self.input, 18, self.FOLLOW_18_in_operator_definition1055) self._state.following.append(self.FOLLOW_operator_name_OR_in_operator_definition1059) or_op = self.operator_name_OR() self._state.following.pop() #action start defineOperator(or_name.text, or_op); #action end elif alt29 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:380:1: (and_name= AND_ ':' and_op= operator_name_AND ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:380:1: (and_name= AND_ ':' and_op= operator_name_AND ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:380:2: and_name= AND_ ':' and_op= operator_name_AND pass and_name=self.match(self.input, AND_, self.FOLLOW_AND__in_operator_definition1070) self.match(self.input, 18, self.FOLLOW_18_in_operator_definition1072) self._state.following.append(self.FOLLOW_operator_name_AND_in_operator_definition1076) and_op = self.operator_name_AND() self._state.following.pop() #action start defineOperator(and_name.text, and_op); #action end self.match(self.input, 20, self.FOLLOW_20_in_operator_definition1085) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "operator_definition" # $ANTLR start "activation_method" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:385:1: activation_method : 'ACT' ':' ( 'PROD' | 'MIN' ) ';' ; def activation_method(self, ): try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:385:19: ( 'ACT' ':' ( 'PROD' | 'MIN' ) ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:385:21: 'ACT' ':' ( 'PROD' | 'MIN' ) ';' pass self.match(self.input, 50, self.FOLLOW_50_in_activation_method1094) self.match(self.input, 18, self.FOLLOW_18_in_activation_method1096) if (44 <= self.input.LA(1) <= 45): self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, 20, self.FOLLOW_20_in_activation_method1106) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "activation_method" # $ANTLR start "accumulation_method" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:387:1: accumulation_method : 'ACCU' ':' ( 'MAX' | 'BSUM' | 'NSUM' ) ';' ; def accumulation_method(self, ): try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:387:21: ( 'ACCU' ':' ( 'MAX' | 'BSUM' | 'NSUM' ) ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:387:23: 'ACCU' ':' ( 'MAX' | 'BSUM' | 'NSUM' ) ';' pass self.match(self.input, 51, self.FOLLOW_51_in_accumulation_method1114) self.match(self.input, 18, self.FOLLOW_18_in_accumulation_method1116) if self.input.LA(1) == 47 or self.input.LA(1) == 49 or self.input.LA(1) == 52: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, 20, self.FOLLOW_20_in_accumulation_method1130) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "accumulation_method" # $ANTLR start "condition" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:392:1: condition returns [input] : (s1= subcondition ) ( (op= ( AND_ | OR_ ) s2= subcondition ) )* ; def condition(self, ): input = None op = None s1 = None s2 = None op_name = None; try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:396:3: ( (s1= subcondition ) ( (op= ( AND_ | OR_ ) s2= subcondition ) )* ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:397:3: (s1= subcondition ) ( (op= ( AND_ | OR_ ) s2= subcondition ) )* pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:397:3: (s1= subcondition ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:398:5: s1= subcondition pass self._state.following.append(self.FOLLOW_subcondition_in_condition1161) s1 = self.subcondition() self._state.following.pop() #action start input = s1 #action end # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:402:3: ( (op= ( AND_ | OR_ ) s2= subcondition ) )* while True: #loop30 alt30 = 2 LA30_0 = self.input.LA(1) if ((OR_ <= LA30_0 <= AND_)) : alt30 = 1 if alt30 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:403:5: (op= ( AND_ | OR_ ) s2= subcondition ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:403:5: (op= ( AND_ | OR_ ) s2= subcondition ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:404:7: op= ( AND_ | OR_ ) s2= subcondition pass op = self.input.LT(1) if (OR_ <= self.input.LA(1) <= AND_): self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse #action start if op_name is not None and op_name != op.text: raise Exception("Don't mix different operations in an expression.") else: op_name = op.text #action end self._state.following.append(self.FOLLOW_subcondition_in_condition1211) s2 = self.subcondition() self._state.following.pop() #action start input = fuzzy.operator.Compound.Compound(getOperator(op.text), input, s2) #action end else: break #loop30 except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return input # $ANTLR end "condition" # $ANTLR start "subcondition" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:422:1: subcondition returns [input] : ( ( 'NOT' '(' condition ')' ) | ( subcondition2 ) ); def subcondition(self, ): input = None condition19 = None subcondition220 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:423:3: ( ( 'NOT' '(' condition ')' ) | ( subcondition2 ) ) alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == 53) : alt31 = 1 elif (LA31_0 == Identifier or LA31_0 == 34) : alt31 = 2 else: nvae = NoViableAltException("", 31, 0, self.input) raise nvae if alt31 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:423:5: ( 'NOT' '(' condition ')' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:423:5: ( 'NOT' '(' condition ')' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:423:6: 'NOT' '(' condition ')' pass self.match(self.input, 53, self.FOLLOW_53_in_subcondition1251) self.match(self.input, 34, self.FOLLOW_34_in_subcondition1253) self._state.following.append(self.FOLLOW_condition_in_subcondition1255) condition19 = self.condition() self._state.following.pop() self.match(self.input, 36, self.FOLLOW_36_in_subcondition1257) #action start input = fuzzy.operator.Not.Not(condition19) #action end elif alt31 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:424:5: ( subcondition2 ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:424:5: ( subcondition2 ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:424:7: subcondition2 pass self._state.following.append(self.FOLLOW_subcondition2_in_subcondition1269) subcondition220 = self.subcondition2() self._state.following.pop() #action start input = subcondition220 #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return input # $ANTLR end "subcondition" # $ANTLR start "subcondition2" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:431:1: subcondition2 returns [input] : ( ( '(' c1= condition ')' ) | ( variable_name ( 'IS' (x= 'NOT' )? | '.' ) term_name ) | (norm= operator_name_any '(' c4= condition ',' c5= condition ')' ) ); def subcondition2(self, ): input = None x = None c1 = None norm = None c4 = None c5 = None variable_name21 = None term_name22 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:432:3: ( ( '(' c1= condition ')' ) | ( variable_name ( 'IS' (x= 'NOT' )? | '.' ) term_name ) | (norm= operator_name_any '(' c4= condition ',' c5= condition ')' ) ) alt34 = 3 LA34_0 = self.input.LA(1) if (LA34_0 == 34) : alt34 = 1 elif (LA34_0 == Identifier) : LA34_2 = self.input.LA(2) if (LA34_2 == 34 or LA34_2 == 42) : alt34 = 3 elif ((54 <= LA34_2 <= 55)) : alt34 = 2 else: nvae = NoViableAltException("", 34, 2, self.input) raise nvae else: nvae = NoViableAltException("", 34, 0, self.input) raise nvae if alt34 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:433:3: ( '(' c1= condition ')' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:433:3: ( '(' c1= condition ')' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:433:4: '(' c1= condition ')' pass self.match(self.input, 34, self.FOLLOW_34_in_subcondition21296) self._state.following.append(self.FOLLOW_condition_in_subcondition21300) c1 = self.condition() self._state.following.pop() self.match(self.input, 36, self.FOLLOW_36_in_subcondition21302) #action start input = c1 #action end elif alt34 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:439:3: ( variable_name ( 'IS' (x= 'NOT' )? | '.' ) term_name ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:439:3: ( variable_name ( 'IS' (x= 'NOT' )? | '.' ) term_name ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:439:5: variable_name ( 'IS' (x= 'NOT' )? | '.' ) term_name pass self._state.following.append(self.FOLLOW_variable_name_in_subcondition21322) variable_name21 = self.variable_name() self._state.following.pop() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:439:19: ( 'IS' (x= 'NOT' )? | '.' ) alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == 54) : alt33 = 1 elif (LA33_0 == 55) : alt33 = 2 else: nvae = NoViableAltException("", 33, 0, self.input) raise nvae if alt33 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:439:20: 'IS' (x= 'NOT' )? pass self.match(self.input, 54, self.FOLLOW_54_in_subcondition21325) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:439:26: (x= 'NOT' )? alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == 53) : alt32 = 1 if alt32 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:439:26: x= 'NOT' pass x=self.match(self.input, 53, self.FOLLOW_53_in_subcondition21329) elif alt33 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:439:36: '.' pass self.match(self.input, 55, self.FOLLOW_55_in_subcondition21334) self._state.following.append(self.FOLLOW_term_name_in_subcondition21338) term_name22 = self.term_name() self._state.following.pop() #action start input = fuzzy.operator.Input.Input(self.System.variables[((variable_name21 is not None) and [self.input.toString(variable_name21.start,variable_name21.stop)] or [None])[0]].adjectives[((term_name22 is not None) and [self.input.toString(term_name22.start,term_name22.stop)] or [None])[0]]) if x is not None: input = fuzzy.operator.Not.Not(input) #action end elif alt34 == 3: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:447:3: (norm= operator_name_any '(' c4= condition ',' c5= condition ')' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:447:3: (norm= operator_name_any '(' c4= condition ',' c5= condition ')' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:447:4: norm= operator_name_any '(' c4= condition ',' c5= condition ')' pass self._state.following.append(self.FOLLOW_operator_name_any_in_subcondition21360) norm = self.operator_name_any() self._state.following.pop() self.match(self.input, 34, self.FOLLOW_34_in_subcondition21362) self._state.following.append(self.FOLLOW_condition_in_subcondition21366) c4 = self.condition() self._state.following.pop() self.match(self.input, 35, self.FOLLOW_35_in_subcondition21368) self._state.following.append(self.FOLLOW_condition_in_subcondition21372) c5 = self.condition() self._state.following.pop() self.match(self.input, 36, self.FOLLOW_36_in_subcondition21374) #action start input = fuzzy.operator.Compound.Compound(norm, c4, c5) #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return input # $ANTLR end "subcondition2" # $ANTLR start "conclusion" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:456:1: conclusion returns [adjs] : ( (c1= conclusion2 ) ( ',' c2= conclusion2 )* ) ; def conclusion(self, ): adjs = None c1 = None c2 = None _adjs = [] try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:460:3: ( ( (c1= conclusion2 ) ( ',' c2= conclusion2 )* ) ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:460:5: ( (c1= conclusion2 ) ( ',' c2= conclusion2 )* ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:460:5: ( (c1= conclusion2 ) ( ',' c2= conclusion2 )* ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:461:5: (c1= conclusion2 ) ( ',' c2= conclusion2 )* pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:461:5: (c1= conclusion2 ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:461:11: c1= conclusion2 pass self._state.following.append(self.FOLLOW_conclusion2_in_conclusion1422) c1 = self.conclusion2() self._state.following.pop() #action start _adjs.append(c1); #action end # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:462:5: ( ',' c2= conclusion2 )* while True: #loop35 alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == 35) : alt35 = 1 if alt35 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:462:8: ',' c2= conclusion2 pass self.match(self.input, 35, self.FOLLOW_35_in_conclusion1436) self._state.following.append(self.FOLLOW_conclusion2_in_conclusion1440) c2 = self.conclusion2() self._state.following.pop() #action start _adjs.append(c2); #action end else: break #loop35 #action start adjs = _adjs #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return adjs # $ANTLR end "conclusion" # $ANTLR start "conclusion2" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:466:1: conclusion2 returns [adj] : ( ( '(' c2= conclusion3 ')' ) | (c1= conclusion3 ) ); def conclusion2(self, ): adj = None c2 = None c1 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:467:3: ( ( '(' c2= conclusion3 ')' ) | (c1= conclusion3 ) ) alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == 34) : alt36 = 1 elif (LA36_0 == Identifier) : alt36 = 2 else: nvae = NoViableAltException("", 36, 0, self.input) raise nvae if alt36 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:468:3: ( '(' c2= conclusion3 ')' ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:468:3: ( '(' c2= conclusion3 ')' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:468:5: '(' c2= conclusion3 ')' pass self.match(self.input, 34, self.FOLLOW_34_in_conclusion21474) self._state.following.append(self.FOLLOW_conclusion3_in_conclusion21478) c2 = self.conclusion3() self._state.following.pop() self.match(self.input, 36, self.FOLLOW_36_in_conclusion21481) #action start adj = c2 #action end elif alt36 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:470:3: (c1= conclusion3 ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:470:3: (c1= conclusion3 ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:470:9: c1= conclusion3 pass self._state.following.append(self.FOLLOW_conclusion3_in_conclusion21501) c1 = self.conclusion3() self._state.following.pop() #action start adj = c1 #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return adj # $ANTLR end "conclusion2" # $ANTLR start "conclusion3" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:473:1: conclusion3 returns [adj] : ( (v2= variable_name 'IS' t2= term_name ) ) ; def conclusion3(self, ): adj = None v2 = None t2 = None try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:474:3: ( ( (v2= variable_name 'IS' t2= term_name ) ) ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:475:3: ( (v2= variable_name 'IS' t2= term_name ) ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:475:3: ( (v2= variable_name 'IS' t2= term_name ) ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:478:3: (v2= variable_name 'IS' t2= term_name ) pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:478:3: (v2= variable_name 'IS' t2= term_name ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:478:4: v2= variable_name 'IS' t2= term_name pass self._state.following.append(self.FOLLOW_variable_name_in_conclusion31538) v2 = self.variable_name() self._state.following.pop() self.match(self.input, 54, self.FOLLOW_54_in_conclusion31540) self._state.following.append(self.FOLLOW_term_name_in_conclusion31544) t2 = self.term_name() self._state.following.pop() #action start adj = self.System.variables[((v2 is not None) and [self.input.toString(v2.start,v2.stop)] or [None])[0]].adjectives[((t2 is not None) and [self.input.toString(t2.start,t2.stop)] or [None])[0]] #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return adj # $ANTLR end "conclusion3" # $ANTLR start "rule" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:482:1: rule[block_name] : 'RULE' Integer_literal ':' 'IF' condition 'THEN' conclusion ( 'WITH' weighting_factor )? ';' ; def rule(self, block_name): Integer_literal26 = None weighting_factor23 = None condition24 = None conclusion25 = None certainty = 1.0 try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:485:3: ( 'RULE' Integer_literal ':' 'IF' condition 'THEN' conclusion ( 'WITH' weighting_factor )? ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:485:5: 'RULE' Integer_literal ':' 'IF' condition 'THEN' conclusion ( 'WITH' weighting_factor )? ';' pass self.match(self.input, 56, self.FOLLOW_56_in_rule1568) Integer_literal26=self.match(self.input, Integer_literal, self.FOLLOW_Integer_literal_in_rule1570) self.match(self.input, 18, self.FOLLOW_18_in_rule1572) self.match(self.input, 57, self.FOLLOW_57_in_rule1574) self._state.following.append(self.FOLLOW_condition_in_rule1576) condition24 = self.condition() self._state.following.pop() self.match(self.input, 58, self.FOLLOW_58_in_rule1578) self._state.following.append(self.FOLLOW_conclusion_in_rule1580) conclusion25 = self.conclusion() self._state.following.pop() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:485:65: ( 'WITH' weighting_factor )? alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == 59) : alt37 = 1 if alt37 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:485:66: 'WITH' weighting_factor pass self.match(self.input, 59, self.FOLLOW_59_in_rule1583) self._state.following.append(self.FOLLOW_weighting_factor_in_rule1585) weighting_factor23 = self.weighting_factor() self._state.following.pop() #action start certainty = float(((weighting_factor23 is not None) and [self.input.toString(weighting_factor23.start,weighting_factor23.stop)] or [None])[0]); #action end self.match(self.input, 20, self.FOLLOW_20_in_rule1591) #action start input = condition24 adjective = conclusion25 self.System.rules[block_name+'.'+Integer_literal26.text] = fuzzy.Rule.Rule(adjective, input, certainty=certainty) #action end except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "rule" class weighting_factor_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) # $ANTLR start "weighting_factor" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:493:1: weighting_factor : numeric_literal ; def weighting_factor(self, ): retval = self.weighting_factor_return() retval.start = self.input.LT(1) try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:493:18: ( numeric_literal ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:496:3: numeric_literal pass self._state.following.append(self.FOLLOW_numeric_literal_in_weighting_factor1606) self.numeric_literal() self._state.following.pop() retval.stop = self.input.LT(-1) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "weighting_factor" class function_block_name_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) # $ANTLR start "function_block_name" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:499:1: function_block_name : Identifier ; def function_block_name(self, ): retval = self.function_block_name_return() retval.start = self.input.LT(1) try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:499:21: ( Identifier ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:499:23: Identifier pass self.match(self.input, Identifier, self.FOLLOW_Identifier_in_function_block_name1617) retval.stop = self.input.LT(-1) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "function_block_name" class rule_block_name_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) # $ANTLR start "rule_block_name" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:501:1: rule_block_name : Identifier ; def rule_block_name(self, ): retval = self.rule_block_name_return() retval.start = self.input.LT(1) try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:501:17: ( Identifier ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:501:19: Identifier pass self.match(self.input, Identifier, self.FOLLOW_Identifier_in_rule_block_name1625) retval.stop = self.input.LT(-1) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "rule_block_name" class term_name_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) # $ANTLR start "term_name" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:502:1: term_name : Identifier ; def term_name(self, ): retval = self.term_name_return() retval.start = self.input.LT(1) try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:502:11: ( Identifier ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:502:13: Identifier pass self.match(self.input, Identifier, self.FOLLOW_Identifier_in_term_name1633) retval.stop = self.input.LT(-1) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "term_name" class f_variable_name_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) # $ANTLR start "f_variable_name" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:503:1: f_variable_name : Identifier ; def f_variable_name(self, ): retval = self.f_variable_name_return() retval.start = self.input.LT(1) try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:503:17: ( Identifier ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:503:19: Identifier pass self.match(self.input, Identifier, self.FOLLOW_Identifier_in_f_variable_name1641) retval.stop = self.input.LT(-1) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "f_variable_name" class variable_name_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) # $ANTLR start "variable_name" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:504:1: variable_name : Identifier ; def variable_name(self, ): retval = self.variable_name_return() retval.start = self.input.LT(1) try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:504:15: ( Identifier ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:504:17: Identifier pass self.match(self.input, Identifier, self.FOLLOW_Identifier_in_variable_name1649) retval.stop = self.input.LT(-1) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "variable_name" class numeric_literal_return(ParserRuleReturnScope): def __init__(self): ParserRuleReturnScope.__init__(self) # $ANTLR start "numeric_literal" # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:505:1: numeric_literal : ( Integer_literal | Real_literal ); def numeric_literal(self, ): retval = self.numeric_literal_return() retval.start = self.input.LT(1) try: try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:505:17: ( Integer_literal | Real_literal ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g: pass if (Integer_literal <= self.input.LA(1) <= Real_literal): self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) except RecognitionException: re = sys.exc_info()[1] self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "numeric_literal" # Delegated rules FOLLOW_function_block_declaration_in_main55 = frozenset([1]) FOLLOW_14_in_function_block_declaration71 = frozenset([4]) FOLLOW_function_block_name_in_function_block_declaration77 = frozenset([15, 16, 21, 23, 24, 26, 28, 30]) FOLLOW_type_definition_in_function_block_declaration85 = frozenset([15, 16, 21, 23, 24, 26, 28, 30]) FOLLOW_fb_io_var_declarations_in_function_block_declaration92 = frozenset([15, 21, 23, 24, 26, 28, 30]) FOLLOW_function_block_body_in_function_block_declaration100 = frozenset([15]) FOLLOW_15_in_function_block_declaration106 = frozenset([]) FOLLOW_EOF_in_function_block_declaration112 = frozenset([1]) FOLLOW_16_in_type_definition126 = frozenset([4]) FOLLOW_Identifier_in_type_definition128 = frozenset([4]) FOLLOW_struct_element_in_type_definition132 = frozenset([4, 17]) FOLLOW_17_in_type_definition136 = frozenset([1]) FOLLOW_Identifier_in_struct_element151 = frozenset([18]) FOLLOW_18_in_struct_element153 = frozenset([19]) FOLLOW_19_in_struct_element155 = frozenset([20]) FOLLOW_20_in_struct_element157 = frozenset([1]) FOLLOW_input_declarations_in_fb_io_var_declarations172 = frozenset([1]) FOLLOW_output_declarations_in_fb_io_var_declarations178 = frozenset([1]) FOLLOW_21_in_input_declarations189 = frozenset([4]) FOLLOW_var_decl_in_input_declarations191 = frozenset([4, 22]) FOLLOW_22_in_input_declarations195 = frozenset([1]) FOLLOW_23_in_output_declarations203 = frozenset([4]) FOLLOW_var_decl_in_output_declarations205 = frozenset([4, 22]) FOLLOW_22_in_output_declarations209 = frozenset([1]) FOLLOW_Identifier_in_var_decl223 = frozenset([18]) FOLLOW_18_in_var_decl227 = frozenset([4, 19]) FOLLOW_type_in_var_decl231 = frozenset([20]) FOLLOW_20_in_var_decl235 = frozenset([1]) FOLLOW_19_in_type254 = frozenset([1]) FOLLOW_Identifier_in_type264 = frozenset([1]) FOLLOW_fuzzify_block_in_function_block_body286 = frozenset([1, 24, 26, 28, 30]) FOLLOW_defuzzify_block_in_function_block_body293 = frozenset([1, 26, 28, 30]) FOLLOW_rule_block_in_function_block_body300 = frozenset([1, 28, 30]) FOLLOW_option_block_in_function_block_body307 = frozenset([1, 30]) FOLLOW_24_in_fuzzify_block325 = frozenset([4]) FOLLOW_variable_name_in_fuzzify_block331 = frozenset([25, 32]) FOLLOW_linguistic_term_in_fuzzify_block337 = frozenset([25, 32]) FOLLOW_25_in_fuzzify_block345 = frozenset([1]) FOLLOW_26_in_defuzzify_block362 = frozenset([4]) FOLLOW_f_variable_name_in_defuzzify_block368 = frozenset([32, 51]) FOLLOW_linguistic_term_in_defuzzify_block374 = frozenset([32, 51]) FOLLOW_accumulation_method_in_defuzzify_block382 = frozenset([37]) FOLLOW_defuzzification_method_in_defuzzify_block388 = frozenset([27, 38, 40]) FOLLOW_default_value_in_defuzzify_block395 = frozenset([27, 40]) FOLLOW_range_in_defuzzify_block403 = frozenset([27]) FOLLOW_27_in_defuzzify_block410 = frozenset([1]) FOLLOW_28_in_rule_block427 = frozenset([4]) FOLLOW_rule_block_name_in_rule_block435 = frozenset([6, 7, 29, 50, 56]) FOLLOW_operator_definition_in_rule_block443 = frozenset([6, 7, 29, 50, 56]) FOLLOW_activation_method_in_rule_block452 = frozenset([29, 56]) FOLLOW_rule_in_rule_block461 = frozenset([29, 56]) FOLLOW_29_in_rule_block469 = frozenset([1]) FOLLOW_30_in_option_block477 = frozenset([31]) FOLLOW_31_in_option_block481 = frozenset([1]) FOLLOW_32_in_linguistic_term496 = frozenset([4]) FOLLOW_term_name_in_linguistic_term498 = frozenset([33]) FOLLOW_33_in_linguistic_term500 = frozenset([4, 8, 9, 34]) FOLLOW_membership_function_in_linguistic_term502 = frozenset([20]) FOLLOW_20_in_linguistic_term504 = frozenset([1]) FOLLOW_singleton_in_membership_function526 = frozenset([1]) FOLLOW_points_in_membership_function538 = frozenset([1]) FOLLOW_pyfuzzy_set_in_membership_function550 = frozenset([1]) FOLLOW_numeric_literal_in_singleton573 = frozenset([1]) FOLLOW_variable_name_in_singleton585 = frozenset([1]) FOLLOW_34_in_points617 = frozenset([4, 8, 9]) FOLLOW_numeric_literal_in_points627 = frozenset([35]) FOLLOW_variable_name_in_points631 = frozenset([35]) FOLLOW_35_in_points639 = frozenset([8, 9]) FOLLOW_numeric_literal_in_points648 = frozenset([36]) FOLLOW_36_in_points655 = frozenset([1, 34]) FOLLOW_Identifier_in_pyfuzzy_set699 = frozenset([34]) FOLLOW_34_in_pyfuzzy_set704 = frozenset([8, 9, 36]) FOLLOW_numeric_literal_in_pyfuzzy_set716 = frozenset([35, 36]) FOLLOW_35_in_pyfuzzy_set732 = frozenset([8, 9]) FOLLOW_numeric_literal_in_pyfuzzy_set742 = frozenset([35, 36]) FOLLOW_36_in_pyfuzzy_set762 = frozenset([1]) FOLLOW_37_in_defuzzification_method785 = frozenset([18]) FOLLOW_18_in_defuzzification_method787 = frozenset([4]) FOLLOW_Identifier_in_defuzzification_method791 = frozenset([20]) FOLLOW_20_in_defuzzification_method797 = frozenset([1]) FOLLOW_38_in_default_value812 = frozenset([33]) FOLLOW_33_in_default_value814 = frozenset([8, 9, 39]) FOLLOW_numeric_literal_in_default_value824 = frozenset([20]) FOLLOW_39_in_default_value836 = frozenset([20]) FOLLOW_20_in_default_value846 = frozenset([1]) FOLLOW_40_in_range857 = frozenset([33]) FOLLOW_33_in_range859 = frozenset([34]) FOLLOW_34_in_range861 = frozenset([8, 9]) FOLLOW_numeric_literal_in_range863 = frozenset([41]) FOLLOW_41_in_range865 = frozenset([8, 9]) FOLLOW_numeric_literal_in_range867 = frozenset([36]) FOLLOW_36_in_range869 = frozenset([20]) FOLLOW_20_in_range871 = frozenset([1]) FOLLOW_Identifier_in_operator_name_any890 = frozenset([1, 42]) FOLLOW_42_in_operator_name_any893 = frozenset([8, 9]) FOLLOW_numeric_literal_in_operator_name_any897 = frozenset([43]) FOLLOW_43_in_operator_name_any899 = frozenset([1]) FOLLOW_44_in_operator_name_AND922 = frozenset([1]) FOLLOW_45_in_operator_name_AND932 = frozenset([1]) FOLLOW_46_in_operator_name_AND942 = frozenset([1]) FOLLOW_operator_name_any_in_operator_name_AND955 = frozenset([1]) FOLLOW_47_in_operator_name_OR976 = frozenset([1]) FOLLOW_48_in_operator_name_OR986 = frozenset([1]) FOLLOW_49_in_operator_name_OR996 = frozenset([1]) FOLLOW_operator_name_any_in_operator_name_OR1009 = frozenset([1]) FOLLOW_OR__in_operator_definition1053 = frozenset([18]) FOLLOW_18_in_operator_definition1055 = frozenset([4, 47, 48, 49]) FOLLOW_operator_name_OR_in_operator_definition1059 = frozenset([20]) FOLLOW_AND__in_operator_definition1070 = frozenset([18]) FOLLOW_18_in_operator_definition1072 = frozenset([4, 44, 45, 46, 47, 48, 49]) FOLLOW_operator_name_AND_in_operator_definition1076 = frozenset([20]) FOLLOW_20_in_operator_definition1085 = frozenset([1]) FOLLOW_50_in_activation_method1094 = frozenset([18]) FOLLOW_18_in_activation_method1096 = frozenset([44, 45]) FOLLOW_set_in_activation_method1098 = frozenset([20]) FOLLOW_20_in_activation_method1106 = frozenset([1]) FOLLOW_51_in_accumulation_method1114 = frozenset([18]) FOLLOW_18_in_accumulation_method1116 = frozenset([47, 49, 52]) FOLLOW_set_in_accumulation_method1118 = frozenset([20]) FOLLOW_20_in_accumulation_method1130 = frozenset([1]) FOLLOW_subcondition_in_condition1161 = frozenset([1, 6, 7]) FOLLOW_set_in_condition1189 = frozenset([4, 34, 47, 48, 49, 53]) FOLLOW_subcondition_in_condition1211 = frozenset([1, 6, 7]) FOLLOW_53_in_subcondition1251 = frozenset([34]) FOLLOW_34_in_subcondition1253 = frozenset([4, 34, 47, 48, 49, 53]) FOLLOW_condition_in_subcondition1255 = frozenset([36]) FOLLOW_36_in_subcondition1257 = frozenset([1]) FOLLOW_subcondition2_in_subcondition1269 = frozenset([1]) FOLLOW_34_in_subcondition21296 = frozenset([4, 34, 47, 48, 49, 53]) FOLLOW_condition_in_subcondition21300 = frozenset([36]) FOLLOW_36_in_subcondition21302 = frozenset([1]) FOLLOW_variable_name_in_subcondition21322 = frozenset([54, 55]) FOLLOW_54_in_subcondition21325 = frozenset([4, 53]) FOLLOW_53_in_subcondition21329 = frozenset([4]) FOLLOW_55_in_subcondition21334 = frozenset([4]) FOLLOW_term_name_in_subcondition21338 = frozenset([1]) FOLLOW_operator_name_any_in_subcondition21360 = frozenset([34]) FOLLOW_34_in_subcondition21362 = frozenset([4, 34, 47, 48, 49, 53]) FOLLOW_condition_in_subcondition21366 = frozenset([35]) FOLLOW_35_in_subcondition21368 = frozenset([4, 34, 47, 48, 49, 53]) FOLLOW_condition_in_subcondition21372 = frozenset([36]) FOLLOW_36_in_subcondition21374 = frozenset([1]) FOLLOW_conclusion2_in_conclusion1422 = frozenset([1, 35]) FOLLOW_35_in_conclusion1436 = frozenset([4, 34]) FOLLOW_conclusion2_in_conclusion1440 = frozenset([1, 35]) FOLLOW_34_in_conclusion21474 = frozenset([4, 34]) FOLLOW_conclusion3_in_conclusion21478 = frozenset([36]) FOLLOW_36_in_conclusion21481 = frozenset([1]) FOLLOW_conclusion3_in_conclusion21501 = frozenset([1]) FOLLOW_variable_name_in_conclusion31538 = frozenset([54]) FOLLOW_54_in_conclusion31540 = frozenset([4]) FOLLOW_term_name_in_conclusion31544 = frozenset([1]) FOLLOW_56_in_rule1568 = frozenset([8]) FOLLOW_Integer_literal_in_rule1570 = frozenset([18]) FOLLOW_18_in_rule1572 = frozenset([57]) FOLLOW_57_in_rule1574 = frozenset([4, 34, 47, 48, 49, 53]) FOLLOW_condition_in_rule1576 = frozenset([58]) FOLLOW_58_in_rule1578 = frozenset([4, 34]) FOLLOW_conclusion_in_rule1580 = frozenset([20, 59]) FOLLOW_59_in_rule1583 = frozenset([8, 9]) FOLLOW_weighting_factor_in_rule1585 = frozenset([20]) FOLLOW_20_in_rule1591 = frozenset([1]) FOLLOW_numeric_literal_in_weighting_factor1606 = frozenset([1]) FOLLOW_Identifier_in_function_block_name1617 = frozenset([1]) FOLLOW_Identifier_in_rule_block_name1625 = frozenset([1]) FOLLOW_Identifier_in_term_name1633 = frozenset([1]) FOLLOW_Identifier_in_f_variable_name1641 = frozenset([1]) FOLLOW_Identifier_in_variable_name1649 = frozenset([1]) FOLLOW_set_in_numeric_literal0 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("FCLLexer", FCLParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "avatar29A/pyfuzzy", "path": "fuzzy/storage/fcl/FCLParser.py", "copies": "1", "size": "113649", "license": "mit", "hash": 2826394529754515500, "line_mean": 34.6043233083, "line_max": 308, "alpha_frac": 0.5283548469, "autogenerated": false, "ratio": 3.6284081476278653, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9604144371143144, "avg_score": 0.010523724676944084, "num_lines": 3192 }
# $ANTLR 3.1.2 /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g 2012-10-19 23:25:12 import sys from antlr3 import * from antlr3.compat import set, frozenset #docstring __doc__ = """Lexer for reading FCL by the pyfuzzy package.""" __revision__ = "$ Id: FCL.g,v 1.7 2009/10/20 19:15:33 rliebscher Exp $" # pylint: disable-msg=W0107,W0301,W0401,W0614,W0621,C0103,C0111,C0301,C0302,C0322,R0904,R0912,R0915 #ID:W0107 : Unnecessary pass statement #ID:W0301 : Unnecessary semicolon #ID:W0401 : Wildcard import antlr3 #ID:W0614 : Unused import ... from wildcard import #ID:W0621 : Redefining name 'main' from outer scope #ID:C0103 : Invalid name #ID:C0111 : Missing docstring #ID:C0301 : Line too long #ID:C0302 : Too many lines in module #ID:C0322 : Operator not preceded by a space #ID:R0904 : Too many public methods #ID:R0912 : Too many branches #ID:R0915 : Too many statements # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types T__29=29 T__28=28 T__27=27 Real_literal=9 OR_=6 T__26=26 T__25=25 T__24=24 T__23=23 LETTER=10 T__22=22 T__21=21 T__20=20 AND_=7 EOF=-1 Identifier=4 T__55=55 T__56=56 T__19=19 T__57=57 T__58=58 T__16=16 T__51=51 T__15=15 T__52=52 T__18=18 T__53=53 T__54=54 T__17=17 Integer_literal_wo_sign=11 T__14=14 T__59=59 DIGIT=5 COMMENT=13 T__50=50 T__42=42 T__43=43 T__40=40 T__41=41 T__46=46 T__47=47 T__44=44 T__45=45 T__48=48 T__49=49 T__30=30 T__31=31 T__32=32 T__33=33 WS=12 T__34=34 T__35=35 Integer_literal=8 T__36=36 T__37=37 T__38=38 T__39=39 class FCLLexer(Lexer): grammarFileName = "/work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g" antlr_version = version_str_to_tuple("3.1.2") antlr_version_str = "3.1.2" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() Lexer.__init__(self, input, state) self.dfa8 = self.DFA8( self, 8, eot = self.DFA8_eot, eof = self.DFA8_eof, min = self.DFA8_min, max = self.DFA8_max, accept = self.DFA8_accept, special = self.DFA8_special, transition = self.DFA8_transition ) # $ANTLR start "T__14" def mT__14(self, ): try: _type = T__14 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:30:7: ( 'FUNCTION_BLOCK' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:30:9: 'FUNCTION_BLOCK' pass self.match("FUNCTION_BLOCK") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__14" # $ANTLR start "T__15" def mT__15(self, ): try: _type = T__15 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:31:7: ( 'END_FUNCTION_BLOCK' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:31:9: 'END_FUNCTION_BLOCK' pass self.match("END_FUNCTION_BLOCK") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__15" # $ANTLR start "T__16" def mT__16(self, ): try: _type = T__16 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:32:7: ( 'STRUCT' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:32:9: 'STRUCT' pass self.match("STRUCT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__16" # $ANTLR start "T__17" def mT__17(self, ): try: _type = T__17 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:33:7: ( 'END_STRUCT' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:33:9: 'END_STRUCT' pass self.match("END_STRUCT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__17" # $ANTLR start "T__18" def mT__18(self, ): try: _type = T__18 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:34:7: ( ':' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:34:9: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__18" # $ANTLR start "T__19" def mT__19(self, ): try: _type = T__19 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:35:7: ( 'REAL' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:35:9: 'REAL' pass self.match("REAL") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__19" # $ANTLR start "T__20" def mT__20(self, ): try: _type = T__20 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:36:7: ( ';' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:36:9: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__20" # $ANTLR start "T__21" def mT__21(self, ): try: _type = T__21 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:37:7: ( 'VAR_INPUT' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:37:9: 'VAR_INPUT' pass self.match("VAR_INPUT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__21" # $ANTLR start "T__22" def mT__22(self, ): try: _type = T__22 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:38:7: ( 'END_VAR' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:38:9: 'END_VAR' pass self.match("END_VAR") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__22" # $ANTLR start "T__23" def mT__23(self, ): try: _type = T__23 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:39:7: ( 'VAR_OUTPUT' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:39:9: 'VAR_OUTPUT' pass self.match("VAR_OUTPUT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__23" # $ANTLR start "T__24" def mT__24(self, ): try: _type = T__24 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:40:7: ( 'FUZZIFY' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:40:9: 'FUZZIFY' pass self.match("FUZZIFY") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__24" # $ANTLR start "T__25" def mT__25(self, ): try: _type = T__25 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:41:7: ( 'END_FUZZIFY' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:41:9: 'END_FUZZIFY' pass self.match("END_FUZZIFY") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__25" # $ANTLR start "T__26" def mT__26(self, ): try: _type = T__26 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:42:7: ( 'DEFUZZIFY' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:42:9: 'DEFUZZIFY' pass self.match("DEFUZZIFY") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__26" # $ANTLR start "T__27" def mT__27(self, ): try: _type = T__27 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:43:7: ( 'END_DEFUZZIFY' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:43:9: 'END_DEFUZZIFY' pass self.match("END_DEFUZZIFY") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__27" # $ANTLR start "T__28" def mT__28(self, ): try: _type = T__28 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:44:7: ( 'RULEBLOCK' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:44:9: 'RULEBLOCK' pass self.match("RULEBLOCK") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__28" # $ANTLR start "T__29" def mT__29(self, ): try: _type = T__29 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:45:7: ( 'END_RULEBLOCK' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:45:9: 'END_RULEBLOCK' pass self.match("END_RULEBLOCK") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__29" # $ANTLR start "T__30" def mT__30(self, ): try: _type = T__30 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:46:7: ( 'OPTION' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:46:9: 'OPTION' pass self.match("OPTION") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__30" # $ANTLR start "T__31" def mT__31(self, ): try: _type = T__31 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:47:7: ( 'END_OPTION' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:47:9: 'END_OPTION' pass self.match("END_OPTION") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__31" # $ANTLR start "T__32" def mT__32(self, ): try: _type = T__32 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:48:7: ( 'TERM' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:48:9: 'TERM' pass self.match("TERM") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__32" # $ANTLR start "T__33" def mT__33(self, ): try: _type = T__33 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:49:7: ( ':=' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:49:9: ':=' pass self.match(":=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__33" # $ANTLR start "T__34" def mT__34(self, ): try: _type = T__34 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:50:7: ( '(' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:50:9: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__34" # $ANTLR start "T__35" def mT__35(self, ): try: _type = T__35 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:51:7: ( ',' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:51:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__35" # $ANTLR start "T__36" def mT__36(self, ): try: _type = T__36 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:52:7: ( ')' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:52:9: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__36" # $ANTLR start "T__37" def mT__37(self, ): try: _type = T__37 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:53:7: ( 'METHOD' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:53:9: 'METHOD' pass self.match("METHOD") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__37" # $ANTLR start "T__38" def mT__38(self, ): try: _type = T__38 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:54:7: ( 'DEFAULT' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:54:9: 'DEFAULT' pass self.match("DEFAULT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__38" # $ANTLR start "T__39" def mT__39(self, ): try: _type = T__39 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:55:7: ( 'NC' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:55:9: 'NC' pass self.match("NC") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__39" # $ANTLR start "T__40" def mT__40(self, ): try: _type = T__40 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:56:7: ( 'RANGE' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:56:9: 'RANGE' pass self.match("RANGE") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__40" # $ANTLR start "T__41" def mT__41(self, ): try: _type = T__41 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:57:7: ( '..' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:57:9: '..' pass self.match("..") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__41" # $ANTLR start "T__42" def mT__42(self, ): try: _type = T__42 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:58:7: ( '[' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:58:9: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__42" # $ANTLR start "T__43" def mT__43(self, ): try: _type = T__43 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:59:7: ( ']' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:59:9: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__43" # $ANTLR start "T__44" def mT__44(self, ): try: _type = T__44 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:60:7: ( 'MIN' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:60:9: 'MIN' pass self.match("MIN") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__44" # $ANTLR start "T__45" def mT__45(self, ): try: _type = T__45 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:61:7: ( 'PROD' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:61:9: 'PROD' pass self.match("PROD") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__45" # $ANTLR start "T__46" def mT__46(self, ): try: _type = T__46 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:62:7: ( 'BDIF' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:62:9: 'BDIF' pass self.match("BDIF") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__46" # $ANTLR start "T__47" def mT__47(self, ): try: _type = T__47 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:63:7: ( 'MAX' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:63:9: 'MAX' pass self.match("MAX") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__47" # $ANTLR start "T__48" def mT__48(self, ): try: _type = T__48 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:64:7: ( 'ASUM' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:64:9: 'ASUM' pass self.match("ASUM") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__48" # $ANTLR start "T__49" def mT__49(self, ): try: _type = T__49 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:65:7: ( 'BSUM' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:65:9: 'BSUM' pass self.match("BSUM") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__49" # $ANTLR start "T__50" def mT__50(self, ): try: _type = T__50 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:66:7: ( 'ACT' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:66:9: 'ACT' pass self.match("ACT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__50" # $ANTLR start "T__51" def mT__51(self, ): try: _type = T__51 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:67:7: ( 'ACCU' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:67:9: 'ACCU' pass self.match("ACCU") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__51" # $ANTLR start "T__52" def mT__52(self, ): try: _type = T__52 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:68:7: ( 'NSUM' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:68:9: 'NSUM' pass self.match("NSUM") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__52" # $ANTLR start "T__53" def mT__53(self, ): try: _type = T__53 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:69:7: ( 'NOT' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:69:9: 'NOT' pass self.match("NOT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__53" # $ANTLR start "T__54" def mT__54(self, ): try: _type = T__54 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:70:7: ( 'IS' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:70:9: 'IS' pass self.match("IS") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__54" # $ANTLR start "T__55" def mT__55(self, ): try: _type = T__55 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:71:7: ( '.' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:71:9: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__55" # $ANTLR start "T__56" def mT__56(self, ): try: _type = T__56 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:72:7: ( 'RULE' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:72:9: 'RULE' pass self.match("RULE") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__56" # $ANTLR start "T__57" def mT__57(self, ): try: _type = T__57 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:73:7: ( 'IF' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:73:9: 'IF' pass self.match("IF") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__57" # $ANTLR start "T__58" def mT__58(self, ): try: _type = T__58 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:74:7: ( 'THEN' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:74:9: 'THEN' pass self.match("THEN") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__58" # $ANTLR start "T__59" def mT__59(self, ): try: _type = T__59 _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:75:7: ( 'WITH' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:75:9: 'WITH' pass self.match("WITH") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__59" # $ANTLR start "OR_" def mOR_(self, ): try: _type = OR_ _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:373:6: ( 'OR' ( DIGIT )* ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:373:8: 'OR' ( DIGIT )* pass self.match("OR") # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:373:13: ( DIGIT )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((48 <= LA1_0 <= 57)) : alt1 = 1 if alt1 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:373:13: DIGIT pass self.mDIGIT() else: break #loop1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OR_" # $ANTLR start "AND_" def mAND_(self, ): try: _type = AND_ _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:374:6: ( 'AND' ( DIGIT )* ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:374:8: 'AND' ( DIGIT )* pass self.match("AND") # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:374:14: ( DIGIT )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((48 <= LA2_0 <= 57)) : alt2 = 1 if alt2 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:374:14: DIGIT pass self.mDIGIT() else: break #loop2 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AND_" # $ANTLR start "Identifier" def mIdentifier(self, ): try: _type = Identifier _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:510:12: ( LETTER ( LETTER | DIGIT )* ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:510:14: LETTER ( LETTER | DIGIT )* pass self.mLETTER() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:510:21: ( LETTER | DIGIT )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if ((48 <= LA3_0 <= 57) or (65 <= LA3_0 <= 90) or LA3_0 == 95 or (97 <= LA3_0 <= 122)) : alt3 = 1 if alt3 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop3 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "Identifier" # $ANTLR start "Integer_literal_wo_sign" def mInteger_literal_wo_sign(self, ): try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:513:3: ( ( DIGIT )+ ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:513:5: ( DIGIT )+ pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:513:5: ( DIGIT )+ cnt4 = 0 while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if ((48 <= LA4_0 <= 57)) : alt4 = 1 if alt4 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:513:5: DIGIT pass self.mDIGIT() else: if cnt4 >= 1: break #loop4 eee = EarlyExitException(4, self.input) raise eee cnt4 += 1 finally: pass # $ANTLR end "Integer_literal_wo_sign" # $ANTLR start "Integer_literal" def mInteger_literal(self, ): try: _type = Integer_literal _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:515:3: ( ( '+' | '-' )? Integer_literal_wo_sign ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:516:5: ( '+' | '-' )? Integer_literal_wo_sign pass # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:516:5: ( '+' | '-' )? alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == 43 or LA5_0 == 45) : alt5 = 1 if alt5 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g: pass if self.input.LA(1) == 43 or self.input.LA(1) == 45: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.mInteger_literal_wo_sign() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "Integer_literal" # $ANTLR start "LETTER" def mLETTER(self, ): try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:518:18: ( 'A' .. 'Z' | 'a' .. 'z' | '_' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g: pass if (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "LETTER" # $ANTLR start "DIGIT" def mDIGIT(self, ): try: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:519:17: ( '0' .. '9' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:519:19: '0' .. '9' pass self.matchRange(48, 57) finally: pass # $ANTLR end "DIGIT" # $ANTLR start "Real_literal" def mReal_literal(self, ): try: _type = Real_literal _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:522:3: ( Integer_literal '.' Integer_literal_wo_sign ( ( 'e' | 'E' ) Integer_literal )? ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:522:6: Integer_literal '.' Integer_literal_wo_sign ( ( 'e' | 'E' ) Integer_literal )? pass self.mInteger_literal() self.match(46) self.mInteger_literal_wo_sign() # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:522:50: ( ( 'e' | 'E' ) Integer_literal )? alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == 69 or LA6_0 == 101) : alt6 = 1 if alt6 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:522:51: ( 'e' | 'E' ) Integer_literal pass if self.input.LA(1) == 69 or self.input.LA(1) == 101: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.mInteger_literal() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "Real_literal" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:524:5: ( ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:524:8: ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:528:5: ( '(*' ( options {greedy=false; } : . )* '*)' ) # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:528:9: '(*' ( options {greedy=false; } : . )* '*)' pass self.match("(*") # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:528:14: ( options {greedy=false; } : . )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 42) : LA7_1 = self.input.LA(2) if (LA7_1 == 41) : alt7 = 2 elif ((0 <= LA7_1 <= 40) or (42 <= LA7_1 <= 65535)) : alt7 = 1 elif ((0 <= LA7_0 <= 41) or (43 <= LA7_0 <= 65535)) : alt7 = 1 if alt7 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:528:42: . pass self.matchAny() else: break #loop7 self.match("*)") #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" def mTokens(self): # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:8: ( T__14 | T__15 | T__16 | T__17 | T__18 | T__19 | T__20 | T__21 | T__22 | T__23 | T__24 | T__25 | T__26 | T__27 | T__28 | T__29 | T__30 | T__31 | T__32 | T__33 | T__34 | T__35 | T__36 | T__37 | T__38 | T__39 | T__40 | T__41 | T__42 | T__43 | T__44 | T__45 | T__46 | T__47 | T__48 | T__49 | T__50 | T__51 | T__52 | T__53 | T__54 | T__55 | T__56 | T__57 | T__58 | T__59 | OR_ | AND_ | Identifier | Integer_literal | Real_literal | WS | COMMENT ) alt8 = 53 alt8 = self.dfa8.predict(self.input) if alt8 == 1: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:10: T__14 pass self.mT__14() elif alt8 == 2: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:16: T__15 pass self.mT__15() elif alt8 == 3: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:22: T__16 pass self.mT__16() elif alt8 == 4: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:28: T__17 pass self.mT__17() elif alt8 == 5: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:34: T__18 pass self.mT__18() elif alt8 == 6: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:40: T__19 pass self.mT__19() elif alt8 == 7: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:46: T__20 pass self.mT__20() elif alt8 == 8: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:52: T__21 pass self.mT__21() elif alt8 == 9: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:58: T__22 pass self.mT__22() elif alt8 == 10: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:64: T__23 pass self.mT__23() elif alt8 == 11: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:70: T__24 pass self.mT__24() elif alt8 == 12: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:76: T__25 pass self.mT__25() elif alt8 == 13: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:82: T__26 pass self.mT__26() elif alt8 == 14: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:88: T__27 pass self.mT__27() elif alt8 == 15: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:94: T__28 pass self.mT__28() elif alt8 == 16: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:100: T__29 pass self.mT__29() elif alt8 == 17: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:106: T__30 pass self.mT__30() elif alt8 == 18: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:112: T__31 pass self.mT__31() elif alt8 == 19: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:118: T__32 pass self.mT__32() elif alt8 == 20: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:124: T__33 pass self.mT__33() elif alt8 == 21: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:130: T__34 pass self.mT__34() elif alt8 == 22: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:136: T__35 pass self.mT__35() elif alt8 == 23: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:142: T__36 pass self.mT__36() elif alt8 == 24: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:148: T__37 pass self.mT__37() elif alt8 == 25: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:154: T__38 pass self.mT__38() elif alt8 == 26: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:160: T__39 pass self.mT__39() elif alt8 == 27: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:166: T__40 pass self.mT__40() elif alt8 == 28: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:172: T__41 pass self.mT__41() elif alt8 == 29: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:178: T__42 pass self.mT__42() elif alt8 == 30: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:184: T__43 pass self.mT__43() elif alt8 == 31: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:190: T__44 pass self.mT__44() elif alt8 == 32: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:196: T__45 pass self.mT__45() elif alt8 == 33: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:202: T__46 pass self.mT__46() elif alt8 == 34: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:208: T__47 pass self.mT__47() elif alt8 == 35: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:214: T__48 pass self.mT__48() elif alt8 == 36: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:220: T__49 pass self.mT__49() elif alt8 == 37: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:226: T__50 pass self.mT__50() elif alt8 == 38: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:232: T__51 pass self.mT__51() elif alt8 == 39: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:238: T__52 pass self.mT__52() elif alt8 == 40: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:244: T__53 pass self.mT__53() elif alt8 == 41: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:250: T__54 pass self.mT__54() elif alt8 == 42: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:256: T__55 pass self.mT__55() elif alt8 == 43: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:262: T__56 pass self.mT__56() elif alt8 == 44: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:268: T__57 pass self.mT__57() elif alt8 == 45: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:274: T__58 pass self.mT__58() elif alt8 == 46: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:280: T__59 pass self.mT__59() elif alt8 == 47: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:286: OR_ pass self.mOR_() elif alt8 == 48: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:290: AND_ pass self.mAND_() elif alt8 == 49: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:295: Identifier pass self.mIdentifier() elif alt8 == 50: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:306: Integer_literal pass self.mInteger_literal() elif alt8 == 51: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:322: Real_literal pass self.mReal_literal() elif alt8 == 52: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:335: WS pass self.mWS() elif alt8 == 53: # /work/projects/pyfuzzy/pyfuzzy/fuzzy/storage/fcl/FCL.g:1:338: COMMENT pass self.mCOMMENT() # lookup tables for DFA #8 DFA8_eot = DFA.unpack( u"\1\uffff\3\30\1\40\1\30\1\uffff\4\30\1\53\2\uffff\2\30\1\63\2\uffff" u"\5\30\2\uffff\1\75\1\uffff\3\30\2\uffff\6\30\1\111\2\30\2\uffff" u"\3\30\1\120\2\30\2\uffff\6\30\1\132\1\133\1\30\2\uffff\12\30\1" u"\uffff\1\111\3\30\1\153\1\154\1\uffff\1\30\1\156\4\30\1\163\1\30" u"\1\165\2\uffff\5\30\1\u0081\1\u0083\5\30\1\u008a\1\u008b\1\30\2" u"\uffff\1\u008d\1\uffff\1\u008e\1\u008f\1\u0090\1\u0091\1\uffff" u"\1\u0092\1\uffff\1\165\1\u0093\11\30\1\uffff\1\30\1\uffff\1\u009e" u"\5\30\2\uffff\1\30\7\uffff\10\30\1\u00ae\1\30\1\uffff\4\30\1\u00b4" u"\1\u00b5\1\30\1\u00b7\3\30\1\u00bb\3\30\1\uffff\4\30\1\u00c3\2" u"\uffff\1\30\1\uffff\3\30\1\uffff\7\30\1\uffff\7\30\1\u00d6\1\u00d7" u"\1\30\1\u00d9\3\30\1\u00dd\2\30\1\u00e0\2\uffff\1\u00e1\1\uffff" u"\2\30\1\u00e4\1\uffff\2\30\2\uffff\2\30\1\uffff\4\30\1\u00ed\1" u"\u00ee\1\u00ef\1\30\3\uffff\3\30\1\u00f4\1\uffff" ) DFA8_eof = DFA.unpack( u"\u00f5\uffff" ) DFA8_min = DFA.unpack( u"\1\11\1\125\1\116\1\124\1\75\1\101\1\uffff\1\101\1\105\1\120\1" u"\105\1\52\2\uffff\1\101\1\103\1\56\2\uffff\1\122\1\104\1\103\1" u"\106\1\111\1\uffff\1\60\1\56\1\uffff\1\116\1\104\1\122\2\uffff" u"\1\101\1\114\1\116\1\122\1\106\1\124\1\60\1\122\1\105\2\uffff\1" u"\124\1\116\1\130\1\60\1\125\1\124\2\uffff\1\117\1\111\2\125\1\103" u"\1\104\2\60\1\124\2\uffff\1\103\1\132\1\137\1\125\1\114\1\105\1" u"\107\1\137\1\101\1\111\1\uffff\1\60\1\115\1\116\1\110\2\60\1\uffff" u"\1\115\1\60\1\104\1\106\2\115\1\60\1\125\1\60\2\uffff\1\110\1\124" u"\1\111\1\104\1\103\2\60\1\105\1\111\1\132\1\125\1\117\2\60\1\117" u"\2\uffff\1\60\1\uffff\4\60\1\uffff\1\60\1\uffff\2\60\1\111\1\106" u"\1\125\1\124\1\101\1\105\1\125\1\120\1\124\1\uffff\1\114\1\uffff" u"\1\60\1\116\1\125\1\132\1\114\1\116\2\uffff\1\104\7\uffff\1\117" u"\1\131\1\116\2\122\1\106\1\114\1\124\1\60\1\117\1\uffff\1\120\1" u"\124\1\111\1\124\2\60\1\116\1\60\1\103\1\132\1\125\1\60\1\125\1" u"\105\1\111\1\uffff\1\103\1\125\1\120\1\106\1\60\2\uffff\1\137\1" u"\uffff\1\124\1\111\1\103\1\uffff\1\132\1\102\1\117\1\113\1\124" u"\1\125\1\131\1\uffff\1\102\1\111\1\106\1\124\1\132\1\114\1\116" u"\2\60\1\124\1\60\1\114\1\117\1\131\1\60\1\111\1\117\1\60\2\uffff" u"\1\60\1\uffff\1\117\1\116\1\60\1\uffff\1\106\1\103\2\uffff\1\103" u"\1\137\1\uffff\1\131\2\113\1\102\3\60\1\114\3\uffff\1\117\1\103" u"\1\113\1\60\1\uffff" ) DFA8_max = DFA.unpack( u"\1\172\1\125\1\116\1\124\1\75\1\125\1\uffff\1\101\1\105\1\122\1" u"\110\1\52\2\uffff\1\111\1\123\1\56\2\uffff\1\122\3\123\1\111\1" u"\uffff\2\71\1\uffff\1\132\1\104\1\122\2\uffff\1\101\1\114\1\116" u"\1\122\1\106\1\124\1\172\1\122\1\105\2\uffff\1\124\1\116\1\130" u"\1\172\1\125\1\124\2\uffff\1\117\1\111\2\125\1\124\1\104\2\172" u"\1\124\2\uffff\1\103\1\132\1\137\1\125\1\114\1\105\1\107\1\137" u"\1\125\1\111\1\uffff\1\172\1\115\1\116\1\110\2\172\1\uffff\1\115" u"\1\172\1\104\1\106\2\115\1\172\1\125\1\172\2\uffff\1\110\1\124" u"\1\111\1\126\1\103\2\172\1\105\1\117\1\132\1\125\1\117\2\172\1" u"\117\2\uffff\1\172\1\uffff\4\172\1\uffff\1\172\1\uffff\2\172\1" u"\111\1\106\1\125\1\124\1\101\1\105\1\125\1\120\1\124\1\uffff\1" u"\114\1\uffff\1\172\1\116\1\125\1\132\1\114\1\116\2\uffff\1\104" u"\7\uffff\1\117\1\131\1\132\2\122\1\106\1\114\1\124\1\172\1\117" u"\1\uffff\1\120\1\124\1\111\1\124\2\172\1\116\1\172\1\103\1\132" u"\1\125\1\172\1\125\1\105\1\111\1\uffff\1\103\1\125\1\120\1\106" u"\1\172\2\uffff\1\137\1\uffff\1\124\1\111\1\103\1\uffff\1\132\1" u"\102\1\117\1\113\1\124\1\125\1\131\1\uffff\1\102\1\111\1\106\1" u"\124\1\132\1\114\1\116\2\172\1\124\1\172\1\114\1\117\1\131\1\172" u"\1\111\1\117\1\172\2\uffff\1\172\1\uffff\1\117\1\116\1\172\1\uffff" u"\1\106\1\103\2\uffff\1\103\1\137\1\uffff\1\131\2\113\1\102\3\172" u"\1\114\3\uffff\1\117\1\103\1\113\1\172\1\uffff" ) DFA8_accept = DFA.unpack( u"\6\uffff\1\7\5\uffff\1\26\1\27\3\uffff\1\35\1\36\5\uffff\1\61\2" u"\uffff\1\64\3\uffff\1\24\1\5\11\uffff\1\65\1\25\6\uffff\1\34\1" u"\52\11\uffff\1\62\1\63\12\uffff\1\57\6\uffff\1\32\11\uffff\1\51" u"\1\54\17\uffff\1\37\1\42\1\uffff\1\50\4\uffff\1\45\1\uffff\1\60" u"\13\uffff\1\6\1\uffff\1\53\6\uffff\1\23\1\55\1\uffff\1\47\1\40" u"\1\41\1\44\1\43\1\46\1\56\12\uffff\1\33\17\uffff\1\3\5\uffff\1" u"\21\1\30\1\uffff\1\13\3\uffff\1\11\7\uffff\1\31\22\uffff\1\17\1" u"\10\1\uffff\1\15\3\uffff\1\4\2\uffff\1\22\1\12\2\uffff\1\14\10" u"\uffff\1\16\1\20\1\1\4\uffff\1\2" ) DFA8_special = DFA.unpack( u"\u00f5\uffff" ) DFA8_transition = [ DFA.unpack(u"\2\33\1\uffff\2\33\22\uffff\1\33\7\uffff\1\13\1\15\1" u"\uffff\1\31\1\14\1\31\1\20\1\uffff\12\32\1\4\1\6\5\uffff\1\25\1" u"\24\1\30\1\10\1\2\1\1\2\30\1\26\3\30\1\16\1\17\1\11\1\23\1\30\1" u"\5\1\3\1\12\1\30\1\7\1\27\3\30\1\21\1\uffff\1\22\1\uffff\1\30\1" u"\uffff\32\30"), DFA.unpack(u"\1\34"), DFA.unpack(u"\1\35"), DFA.unpack(u"\1\36"), DFA.unpack(u"\1\37"), DFA.unpack(u"\1\43\3\uffff\1\41\17\uffff\1\42"), DFA.unpack(u""), DFA.unpack(u"\1\44"), DFA.unpack(u"\1\45"), DFA.unpack(u"\1\46\1\uffff\1\47"), DFA.unpack(u"\1\50\2\uffff\1\51"), DFA.unpack(u"\1\52"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\56\3\uffff\1\54\3\uffff\1\55"), DFA.unpack(u"\1\57\13\uffff\1\61\3\uffff\1\60"), DFA.unpack(u"\1\62"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\64"), DFA.unpack(u"\1\65\16\uffff\1\66"), DFA.unpack(u"\1\70\12\uffff\1\71\4\uffff\1\67"), DFA.unpack(u"\1\73\14\uffff\1\72"), DFA.unpack(u"\1\74"), DFA.unpack(u""), DFA.unpack(u"\12\32"), DFA.unpack(u"\1\76\1\uffff\12\32"), DFA.unpack(u""), DFA.unpack(u"\1\77\13\uffff\1\100"), DFA.unpack(u"\1\101"), DFA.unpack(u"\1\102"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\103"), DFA.unpack(u"\1\104"), DFA.unpack(u"\1\105"), DFA.unpack(u"\1\106"), DFA.unpack(u"\1\107"), DFA.unpack(u"\1\110"), DFA.unpack(u"\12\112\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\113"), DFA.unpack(u"\1\114"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\115"), DFA.unpack(u"\1\116"), DFA.unpack(u"\1\117"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\121"), DFA.unpack(u"\1\122"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\123"), DFA.unpack(u"\1\124"), DFA.unpack(u"\1\125"), DFA.unpack(u"\1\126"), DFA.unpack(u"\1\130\20\uffff\1\127"), DFA.unpack(u"\1\131"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\134"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\135"), DFA.unpack(u"\1\136"), DFA.unpack(u"\1\137"), DFA.unpack(u"\1\140"), DFA.unpack(u"\1\141"), DFA.unpack(u"\1\142"), DFA.unpack(u"\1\143"), DFA.unpack(u"\1\144"), DFA.unpack(u"\1\146\23\uffff\1\145"), DFA.unpack(u"\1\147"), DFA.unpack(u""), DFA.unpack(u"\12\112\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\150"), DFA.unpack(u"\1\151"), DFA.unpack(u"\1\152"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u"\1\155"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\157"), DFA.unpack(u"\1\160"), DFA.unpack(u"\1\161"), DFA.unpack(u"\1\162"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\164"), DFA.unpack(u"\12\166\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\167"), DFA.unpack(u"\1\170"), DFA.unpack(u"\1\171"), DFA.unpack(u"\1\175\1\uffff\1\172\10\uffff\1\177\2\uffff\1\176\1" u"\173\2\uffff\1\174"), DFA.unpack(u"\1\u0080"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\1\30\1\u0082\30\30\4\uffff\1\30\1\uffff" u"\32\30"), DFA.unpack(u"\1\u0084"), DFA.unpack(u"\1\u0085\5\uffff\1\u0086"), DFA.unpack(u"\1\u0087"), DFA.unpack(u"\1\u0088"), DFA.unpack(u"\1\u0089"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u008c"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u"\12\166\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u0094"), DFA.unpack(u"\1\u0095"), DFA.unpack(u"\1\u0096"), DFA.unpack(u"\1\u0097"), DFA.unpack(u"\1\u0098"), DFA.unpack(u"\1\u0099"), DFA.unpack(u"\1\u009a"), DFA.unpack(u"\1\u009b"), DFA.unpack(u"\1\u009c"), DFA.unpack(u""), DFA.unpack(u"\1\u009d"), DFA.unpack(u""), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u009f"), DFA.unpack(u"\1\u00a0"), DFA.unpack(u"\1\u00a1"), DFA.unpack(u"\1\u00a2"), DFA.unpack(u"\1\u00a3"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00a4"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00a5"), DFA.unpack(u"\1\u00a6"), DFA.unpack(u"\1\u00a7\13\uffff\1\u00a8"), DFA.unpack(u"\1\u00a9"), DFA.unpack(u"\1\u00aa"), DFA.unpack(u"\1\u00ab"), DFA.unpack(u"\1\u00ac"), DFA.unpack(u"\1\u00ad"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u00af"), DFA.unpack(u""), DFA.unpack(u"\1\u00b0"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\1\u00b2"), DFA.unpack(u"\1\u00b3"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u00b6"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u00b8"), DFA.unpack(u"\1\u00b9"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\1\u00bd"), DFA.unpack(u"\1\u00be"), DFA.unpack(u""), DFA.unpack(u"\1\u00bf"), DFA.unpack(u"\1\u00c0"), DFA.unpack(u"\1\u00c1"), DFA.unpack(u"\1\u00c2"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00c4"), DFA.unpack(u""), DFA.unpack(u"\1\u00c5"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u"\1\u00c7"), DFA.unpack(u""), DFA.unpack(u"\1\u00c8"), DFA.unpack(u"\1\u00c9"), DFA.unpack(u"\1\u00ca"), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\1\u00cc"), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u""), DFA.unpack(u"\1\u00cf"), DFA.unpack(u"\1\u00d0"), DFA.unpack(u"\1\u00d1"), DFA.unpack(u"\1\u00d2"), DFA.unpack(u"\1\u00d3"), DFA.unpack(u"\1\u00d4"), DFA.unpack(u"\1\u00d5"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u00d8"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u00da"), DFA.unpack(u"\1\u00db"), DFA.unpack(u"\1\u00dc"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u00de"), DFA.unpack(u"\1\u00df"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u"\1\u00e2"), DFA.unpack(u"\1\u00e3"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u""), DFA.unpack(u"\1\u00e5"), DFA.unpack(u"\1\u00e6"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00e7"), DFA.unpack(u"\1\u00e8"), DFA.unpack(u""), DFA.unpack(u"\1\u00e9"), DFA.unpack(u"\1\u00ea"), DFA.unpack(u"\1\u00eb"), DFA.unpack(u"\1\u00ec"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"\1\u00f0"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00f1"), DFA.unpack(u"\1\u00f2"), DFA.unpack(u"\1\u00f3"), DFA.unpack(u"\12\30\7\uffff\32\30\4\uffff\1\30\1\uffff\32\30"), DFA.unpack(u"") ] # class definition for DFA #8 DFA8 = DFA def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(FCLLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "avatar29A/pyfuzzy", "path": "fuzzy/storage/fcl/FCLLexer.py", "copies": "1", "size": "59631", "license": "mit", "hash": 8790102979027069000, "line_mean": 24.2032967033, "line_max": 513, "alpha_frac": 0.4954973084, "autogenerated": false, "ratio": 2.806164705882353, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.3801662014282353, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 17, 2009 19:23:44 /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g 2013-03-25 15:29:47 import sys from antlr3 import * from antlr3.compat import set, frozenset from intellect.Node import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types SLASHEQUAL=38 BACKQUOTE=80 EXPONENT=84 STAR=64 CIRCUMFLEXEQUAL=42 LETTER=82 TRIAPOS=85 GREATEREQUAL=52 COMPLEX=77 ASSIGNEQUAL=24 NOT=21 EOF=-1 NOTEQUAL=55 LEADING_WS=90 MINUSEQUAL=36 VBAR=58 RPAREN=10 IMPORT=7 NAME=12 GREATER=50 INSERT=31 DOUBLESTAREQUAL=45 LESS=49 COMMENT=91 RBRACK=71 RULE=15 LCURLY=72 INT=74 DELETE=29 RIGHTSHIFT=27 DOUBLESLASHEQUAL=46 WS=89 VBAREQUAL=41 OR=47 LONGINT=75 FORGET=28 FROM=8 PERCENTEQUAL=39 LESSEQUAL=53 DOLLAR=79 MODIFY=32 DOUBLESLASH=67 LBRACK=70 CONTINUED_LINE=88 OBJECTBINDING=23 DOUBLESTAR=69 HALT=33 ESC=87 ATTRIBUTE=25 DEDENT=5 FLOAT=76 RIGHTSHIFTEQUAL=44 AND=48 LEARN=30 INDENT=4 LPAREN=9 PLUSEQUAL=35 AS=13 SLASH=65 THEN=20 IN=56 COMMA=11 IS=57 AMPER=60 EQUAL=51 TILDE=68 LEFTSHIFTEQUAL=43 LEFTSHIFT=61 PLUS=62 EXISTS=22 DIGIT=83 DOT=14 AGENDAGROUP=18 PERCENT=66 MINUS=63 SEMI=78 PRINT=26 COLON=16 TRIQUOTE=86 AMPEREQUAL=40 NEWLINE=6 WHEN=19 RCURLY=73 ASSIGN=34 GLOBAL=81 STAREQUAL=37 CIRCUMFLEX=59 STRING=17 ALT_NOTEQUAL=54 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "INDENT", "DEDENT", "NEWLINE", "IMPORT", "FROM", "LPAREN", "RPAREN", "COMMA", "NAME", "AS", "DOT", "RULE", "COLON", "STRING", "AGENDAGROUP", "WHEN", "THEN", "NOT", "EXISTS", "OBJECTBINDING", "ASSIGNEQUAL", "ATTRIBUTE", "PRINT", "RIGHTSHIFT", "FORGET", "DELETE", "LEARN", "INSERT", "MODIFY", "HALT", "ASSIGN", "PLUSEQUAL", "MINUSEQUAL", "STAREQUAL", "SLASHEQUAL", "PERCENTEQUAL", "AMPEREQUAL", "VBAREQUAL", "CIRCUMFLEXEQUAL", "LEFTSHIFTEQUAL", "RIGHTSHIFTEQUAL", "DOUBLESTAREQUAL", "DOUBLESLASHEQUAL", "OR", "AND", "LESS", "GREATER", "EQUAL", "GREATEREQUAL", "LESSEQUAL", "ALT_NOTEQUAL", "NOTEQUAL", "IN", "IS", "VBAR", "CIRCUMFLEX", "AMPER", "LEFTSHIFT", "PLUS", "MINUS", "STAR", "SLASH", "PERCENT", "DOUBLESLASH", "TILDE", "DOUBLESTAR", "LBRACK", "RBRACK", "LCURLY", "RCURLY", "INT", "LONGINT", "FLOAT", "COMPLEX", "SEMI", "DOLLAR", "BACKQUOTE", "GLOBAL", "LETTER", "DIGIT", "EXPONENT", "TRIAPOS", "TRIQUOTE", "ESC", "CONTINUED_LINE", "WS", "LEADING_WS", "COMMENT" ] class PolicyParser(Parser): grammarFileName = "/Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g" antlr_version = version_str_to_tuple("3.1.3 Mar 17, 2009 19:23:44") antlr_version_str = "3.1.3 Mar 17, 2009 19:23:44" tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(PolicyParser, self).__init__(input, state, *args, **kwargs) self.dfa34 = self.DFA34( self, 34, eot = self.DFA34_eot, eof = self.DFA34_eof, min = self.DFA34_min, max = self.DFA34_max, accept = self.DFA34_accept, special = self.DFA34_special, transition = self.DFA34_transition ) self.dfa54 = self.DFA54( self, 54, eot = self.DFA54_eot, eof = self.DFA54_eof, min = self.DFA54_min, max = self.DFA54_max, accept = self.DFA54_accept, special = self.DFA54_special, transition = self.DFA54_transition ) self.dfa59 = self.DFA59( self, 59, eot = self.DFA59_eot, eof = self.DFA59_eof, min = self.DFA59_min, max = self.DFA59_max, accept = self.DFA59_accept, special = self.DFA59_special, transition = self.DFA59_transition ) self.dfa61 = self.DFA61( self, 61, eot = self.DFA61_eot, eof = self.DFA61_eof, min = self.DFA61_min, max = self.DFA61_max, accept = self.DFA61_accept, special = self.DFA61_special, transition = self.DFA61_transition ) # $ANTLR start "file" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:61:1: file returns [object] : ( ( NEWLINE | statement )+ | EOF ); def file(self, ): object = None statement1 = None object = File() try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:63:3: ( ( NEWLINE | statement )+ | EOF ) alt2 = 2 LA2_0 = self.input.LA(1) if ((NEWLINE <= LA2_0 <= LPAREN) or LA2_0 == NAME or LA2_0 == RULE or LA2_0 == STRING or LA2_0 == NOT or LA2_0 == OBJECTBINDING or (PLUS <= LA2_0 <= MINUS) or LA2_0 == TILDE or LA2_0 == LBRACK or LA2_0 == LCURLY or (INT <= LA2_0 <= COMPLEX)) : alt2 = 1 elif (LA2_0 == EOF) : alt2 = 2 else: nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:63:5: ( NEWLINE | statement )+ pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:63:5: ( NEWLINE | statement )+ cnt1 = 0 while True: #loop1 alt1 = 3 LA1_0 = self.input.LA(1) if (LA1_0 == NEWLINE) : alt1 = 1 elif ((IMPORT <= LA1_0 <= LPAREN) or LA1_0 == NAME or LA1_0 == RULE or LA1_0 == STRING or LA1_0 == NOT or LA1_0 == OBJECTBINDING or (PLUS <= LA1_0 <= MINUS) or LA1_0 == TILDE or LA1_0 == LBRACK or LA1_0 == LCURLY or (INT <= LA1_0 <= COMPLEX)) : alt1 = 2 if alt1 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:63:7: NEWLINE pass self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_file78) elif alt1 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:63:17: statement pass self._state.following.append(self.FOLLOW_statement_in_file82) statement1 = self.statement() self._state.following.pop() #action start object.append_child( statement1 ) #action end else: if cnt1 >= 1: break #loop1 eee = EarlyExitException(1, self.input) raise eee cnt1 += 1 elif alt2 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:64:5: EOF pass self.match(self.input, EOF, self.FOLLOW_EOF_in_file93) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "file" # $ANTLR start "statement" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:67:1: statement returns [object] : ( importStmt | attributeStmt | ruleStmt ); def statement(self, ): object = None importStmt2 = None attributeStmt3 = None ruleStmt4 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:68:3: ( importStmt | attributeStmt | ruleStmt ) alt3 = 3 LA3 = self.input.LA(1) if LA3 == IMPORT or LA3 == FROM: alt3 = 1 elif LA3 == LPAREN or LA3 == NAME or LA3 == STRING or LA3 == NOT or LA3 == OBJECTBINDING or LA3 == PLUS or LA3 == MINUS or LA3 == TILDE or LA3 == LBRACK or LA3 == LCURLY or LA3 == INT or LA3 == LONGINT or LA3 == FLOAT or LA3 == COMPLEX: alt3 = 2 elif LA3 == RULE: alt3 = 3 else: nvae = NoViableAltException("", 3, 0, self.input) raise nvae if alt3 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:68:5: importStmt pass self._state.following.append(self.FOLLOW_importStmt_in_statement111) importStmt2 = self.importStmt() self._state.following.pop() #action start object = Statement( importStmt2, importStmt2.line, importStmt2.column ) #action end elif alt3 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:69:5: attributeStmt pass self._state.following.append(self.FOLLOW_attributeStmt_in_statement120) attributeStmt3 = self.attributeStmt() self._state.following.pop() #action start object = Statement( attributeStmt3 ) #action end elif alt3 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:70:5: ruleStmt pass self._state.following.append(self.FOLLOW_ruleStmt_in_statement129) ruleStmt4 = self.ruleStmt() self._state.following.pop() #action start object = Statement( ruleStmt4, ruleStmt4.line, ruleStmt4.column ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "statement" # $ANTLR start "importStmt" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:73:1: importStmt returns [object] : ( importName | importFrom ); def importStmt(self, ): object = None importName5 = None importFrom6 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:74:3: ( importName | importFrom ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == IMPORT) : alt4 = 1 elif (LA4_0 == FROM) : alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:74:5: importName pass self._state.following.append(self.FOLLOW_importName_in_importStmt152) importName5 = self.importName() self._state.following.pop() #action start object = ImportStmt( children = importName5, line = importName5.line ) #action end elif alt4 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:75:5: importFrom pass self._state.following.append(self.FOLLOW_importFrom_in_importStmt160) importFrom6 = self.importFrom() self._state.following.pop() #action start object = ImportStmt( children = importFrom6, line = importFrom6.line ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "importStmt" # $ANTLR start "importName" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:78:1: importName returns [object] : IMPORT dottedAsNames NEWLINE ; def importName(self, ): object = None IMPORT7 = None dottedAsNames8 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:79:3: ( IMPORT dottedAsNames NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:79:5: IMPORT dottedAsNames NEWLINE pass IMPORT7=self.match(self.input, IMPORT, self.FOLLOW_IMPORT_in_importName180) self._state.following.append(self.FOLLOW_dottedAsNames_in_importName182) dottedAsNames8 = self.dottedAsNames() self._state.following.pop() #action start object = ImportName( children = [IMPORT7.text, dottedAsNames8], line = IMPORT7.getLine() ) #action end self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_importName186) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "importName" # $ANTLR start "importFrom" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:82:1: importFrom returns [object] : FROM dottedName IMPORT (importAsNames1= importAsNames | LPAREN importAsNames2= importAsNames RPAREN ) NEWLINE ; def importFrom(self, ): object = None FROM9 = None IMPORT11 = None LPAREN12 = None RPAREN13 = None importAsNames1 = None importAsNames2 = None dottedName10 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:83:3: ( FROM dottedName IMPORT (importAsNames1= importAsNames | LPAREN importAsNames2= importAsNames RPAREN ) NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:83:5: FROM dottedName IMPORT (importAsNames1= importAsNames | LPAREN importAsNames2= importAsNames RPAREN ) NEWLINE pass FROM9=self.match(self.input, FROM, self.FOLLOW_FROM_in_importFrom204) #action start object = ImportFrom( children = FROM9.text, line = FROM9.getLine() ) #action end self._state.following.append(self.FOLLOW_dottedName_in_importFrom208) dottedName10 = self.dottedName() self._state.following.pop() #action start object.append_child( dottedName10 ) #action end IMPORT11=self.match(self.input, IMPORT, self.FOLLOW_IMPORT_in_importFrom212) #action start object.append_child( IMPORT11.text ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:84:7: (importAsNames1= importAsNames | LPAREN importAsNames2= importAsNames RPAREN ) alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == NAME) : alt5 = 1 elif (LA5_0 == LPAREN) : alt5 = 2 else: nvae = NoViableAltException("", 5, 0, self.input) raise nvae if alt5 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:84:9: importAsNames1= importAsNames pass self._state.following.append(self.FOLLOW_importAsNames_in_importFrom226) importAsNames1 = self.importAsNames() self._state.following.pop() #action start object.append_child( importAsNames1 ) #action end elif alt5 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:85:9: LPAREN importAsNames2= importAsNames RPAREN pass LPAREN12=self.match(self.input, LPAREN, self.FOLLOW_LPAREN_in_importFrom238) self._state.following.append(self.FOLLOW_importAsNames_in_importFrom243) importAsNames2 = self.importAsNames() self._state.following.pop() RPAREN13=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_importFrom245) #action start object.append_children( [LPAREN12.text, importAsNames2, RPAREN13.text] ) #action end self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_importFrom257) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "importFrom" # $ANTLR start "importAsNames" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:89:1: importAsNames returns [object] : importAsName1= importAsName ( COMMA importAsName2= importAsName )* ( COMMA )? ; def importAsNames(self, ): object = None importAsName1 = None importAsName2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:90:3: (importAsName1= importAsName ( COMMA importAsName2= importAsName )* ( COMMA )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:90:5: importAsName1= importAsName ( COMMA importAsName2= importAsName )* ( COMMA )? pass self._state.following.append(self.FOLLOW_importAsName_in_importAsNames276) importAsName1 = self.importAsName() self._state.following.pop() #action start object=ImportAsNames( importAsName1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:91:7: ( COMMA importAsName2= importAsName )* while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == COMMA) : LA6_1 = self.input.LA(2) if (LA6_1 == NAME) : alt6 = 1 if alt6 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:91:9: COMMA importAsName2= importAsName pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_importAsNames288) self._state.following.append(self.FOLLOW_importAsName_in_importAsNames292) importAsName2 = self.importAsName() self._state.following.pop() #action start object.append_children( [",", importAsName2] ) #action end else: break #loop6 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:91:105: ( COMMA )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == COMMA) : alt7 = 1 if alt7 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:91:107: COMMA pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_importAsNames301) #action start object.append_child( "," ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "importAsNames" # $ANTLR start "importAsName" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:94:1: importAsName returns [object] : name1= NAME ( AS name2= NAME )? ; def importAsName(self, ): object = None name1 = None name2 = None AS14 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:95:3: (name1= NAME ( AS name2= NAME )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:95:5: name1= NAME ( AS name2= NAME )? pass name1=self.match(self.input, NAME, self.FOLLOW_NAME_in_importAsName325) #action start object=ImportAsName( name1.text ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:95:56: ( AS name2= NAME )? alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == AS) : alt8 = 1 if alt8 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:95:58: AS name2= NAME pass AS14=self.match(self.input, AS, self.FOLLOW_AS_in_importAsName331) name2=self.match(self.input, NAME, self.FOLLOW_NAME_in_importAsName335) #action start object.append_children( [AS14.text, name2.text] ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "importAsName" # $ANTLR start "dottedAsNames" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:98:1: dottedAsNames returns [object] : dottedAsName1= dottedAsName ( COMMA dottedAsName2= dottedAsName )* ; def dottedAsNames(self, ): object = None COMMA15 = None dottedAsName1 = None dottedAsName2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:99:3: (dottedAsName1= dottedAsName ( COMMA dottedAsName2= dottedAsName )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:99:5: dottedAsName1= dottedAsName ( COMMA dottedAsName2= dottedAsName )* pass self._state.following.append(self.FOLLOW_dottedAsName_in_dottedAsNames359) dottedAsName1 = self.dottedAsName() self._state.following.pop() #action start object = DottedAsNames( dottedAsName1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:100:7: ( COMMA dottedAsName2= dottedAsName )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == COMMA) : alt9 = 1 if alt9 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:100:9: COMMA dottedAsName2= dottedAsName pass COMMA15=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_dottedAsNames371) self._state.following.append(self.FOLLOW_dottedAsName_in_dottedAsNames375) dottedAsName2 = self.dottedAsName() self._state.following.pop() #action start object.append_children( [COMMA15.text, dottedAsName2] ) #action end else: break #loop9 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "dottedAsNames" # $ANTLR start "dottedAsName" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:103:1: dottedAsName returns [object] : dottedName ( AS NAME )? ; def dottedAsName(self, ): object = None AS17 = None NAME18 = None dottedName16 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:104:3: ( dottedName ( AS NAME )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:104:5: dottedName ( AS NAME )? pass self._state.following.append(self.FOLLOW_dottedName_in_dottedAsName397) dottedName16 = self.dottedName() self._state.following.pop() #action start object = DottedAsName( dottedName16 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:104:65: ( AS NAME )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == AS) : alt10 = 1 if alt10 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:104:67: AS NAME pass AS17=self.match(self.input, AS, self.FOLLOW_AS_in_dottedAsName403) NAME18=self.match(self.input, NAME, self.FOLLOW_NAME_in_dottedAsName405) #action start object.append_children( [AS17.text, NAME18.text] ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "dottedAsName" # $ANTLR start "dottedName" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:107:1: dottedName returns [object] : name1= NAME ( DOT name2= NAME )* ; def dottedName(self, ): object = None name1 = None name2 = None DOT19 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:108:3: (name1= NAME ( DOT name2= NAME )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:108:5: name1= NAME ( DOT name2= NAME )* pass name1=self.match(self.input, NAME, self.FOLLOW_NAME_in_dottedName430) #action start object = DottedName( name1.text ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:109:7: ( DOT name2= NAME )* while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == DOT) : alt11 = 1 if alt11 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:109:9: DOT name2= NAME pass DOT19=self.match(self.input, DOT, self.FOLLOW_DOT_in_dottedName442) name2=self.match(self.input, NAME, self.FOLLOW_NAME_in_dottedName446) #action start object.append_children( [DOT19.text, name2.text] ) #action end else: break #loop11 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "dottedName" # $ANTLR start "attributeStmt" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:112:1: attributeStmt returns [object] : expressionStmt ; def attributeStmt(self, ): object = None expressionStmt20 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:113:3: ( expressionStmt ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:113:5: expressionStmt pass self._state.following.append(self.FOLLOW_expressionStmt_in_attributeStmt469) expressionStmt20 = self.expressionStmt() self._state.following.pop() #action start object = AttributeStmt( expressionStmt20 ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "attributeStmt" # $ANTLR start "ruleStmt" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:116:1: ruleStmt returns [object] : RULE id COLON NEWLINE INDENT ( ruleAttribute )* ( when )? then DEDENT ; def ruleStmt(self, ): object = None RULE21 = None COLON23 = None id22 = None ruleAttribute24 = None when25 = None then26 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:117:3: ( RULE id COLON NEWLINE INDENT ( ruleAttribute )* ( when )? then DEDENT ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:117:5: RULE id COLON NEWLINE INDENT ( ruleAttribute )* ( when )? then DEDENT pass RULE21=self.match(self.input, RULE, self.FOLLOW_RULE_in_ruleStmt489) self._state.following.append(self.FOLLOW_id_in_ruleStmt491) id22 = self.id() self._state.following.pop() COLON23=self.match(self.input, COLON, self.FOLLOW_COLON_in_ruleStmt493) self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_ruleStmt495) #action start object = RuleStmt( [ RULE21.text, id22, COLON23.text ], RULE21.getLine(), RULE21.getCharPositionInLine() ) #action end self.match(self.input, INDENT, self.FOLLOW_INDENT_in_ruleStmt505) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:118:14: ( ruleAttribute )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == AGENDAGROUP) : alt12 = 1 if alt12 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:118:16: ruleAttribute pass self._state.following.append(self.FOLLOW_ruleAttribute_in_ruleStmt509) ruleAttribute24 = self.ruleAttribute() self._state.following.pop() #action start object.append_child( ruleAttribute24 ) #action end else: break #loop12 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:119:14: ( when )? alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == WHEN) : alt13 = 1 if alt13 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:119:16: when pass self._state.following.append(self.FOLLOW_when_in_ruleStmt531) when25 = self.when() self._state.following.pop() #action start object.append_child( when25 ) #action end self._state.following.append(self.FOLLOW_then_in_ruleStmt551) then26 = self.then() self._state.following.pop() #action start object.append_child( then26 ) #action end self.match(self.input, DEDENT, self.FOLLOW_DEDENT_in_ruleStmt556) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "ruleStmt" # $ANTLR start "id" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:123:1: id returns [object] : ( NAME | STRING ); def id(self, ): object = None NAME27 = None STRING28 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:124:3: ( NAME | STRING ) alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == NAME) : alt14 = 1 elif (LA14_0 == STRING) : alt14 = 2 else: nvae = NoViableAltException("", 14, 0, self.input) raise nvae if alt14 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:124:5: NAME pass NAME27=self.match(self.input, NAME, self.FOLLOW_NAME_in_id574) #action start object = Id( NAME27.text ) #action end elif alt14 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:125:5: STRING pass STRING28=self.match(self.input, STRING, self.FOLLOW_STRING_in_id585) #action start object = Id( STRING28.text ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "id" # $ANTLR start "ruleAttribute" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:128:1: ruleAttribute returns [object] : agendaGroup ; def ruleAttribute(self, ): object = None agendaGroup29 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:129:3: ( agendaGroup ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:129:5: agendaGroup pass self._state.following.append(self.FOLLOW_agendaGroup_in_ruleAttribute606) agendaGroup29 = self.agendaGroup() self._state.following.pop() #action start object = RuleAttribute( agendaGroup29, agendaGroup29.line, agendaGroup29.column ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "ruleAttribute" # $ANTLR start "agendaGroup" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:132:1: agendaGroup returns [object] : AGENDAGROUP id NEWLINE ; def agendaGroup(self, ): object = None AGENDAGROUP30 = None id31 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:133:3: ( AGENDAGROUP id NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:133:5: AGENDAGROUP id NEWLINE pass AGENDAGROUP30=self.match(self.input, AGENDAGROUP, self.FOLLOW_AGENDAGROUP_in_agendaGroup626) self._state.following.append(self.FOLLOW_id_in_agendaGroup628) id31 = self.id() self._state.following.pop() self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_agendaGroup630) #action start object = AgendaGroup( [ AGENDAGROUP30.text, id31 ], AGENDAGROUP30.getLine(), AGENDAGROUP30.getCharPositionInLine() ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "agendaGroup" # $ANTLR start "when" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:136:1: when returns [object] : WHEN COLON NEWLINE INDENT ( ruleCondition )? DEDENT ; def when(self, ): object = None WHEN32 = None COLON33 = None ruleCondition34 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:137:3: ( WHEN COLON NEWLINE INDENT ( ruleCondition )? DEDENT ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:137:5: WHEN COLON NEWLINE INDENT ( ruleCondition )? DEDENT pass WHEN32=self.match(self.input, WHEN, self.FOLLOW_WHEN_in_when650) COLON33=self.match(self.input, COLON, self.FOLLOW_COLON_in_when652) self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_when654) #action start object = When( [WHEN32.text, COLON33.text], WHEN32.getLine(), WHEN32.getCharPositionInLine() ) #action end self.match(self.input, INDENT, self.FOLLOW_INDENT_in_when664) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:138:14: ( ruleCondition )? alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == NAME or (NOT <= LA15_0 <= OBJECTBINDING)) : alt15 = 1 if alt15 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:138:16: ruleCondition pass self._state.following.append(self.FOLLOW_ruleCondition_in_when668) ruleCondition34 = self.ruleCondition() self._state.following.pop() #action start object.append_child( ruleCondition34 ) #action end self.match(self.input, DEDENT, self.FOLLOW_DEDENT_in_when675) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "when" # $ANTLR start "then" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:141:1: then returns [object] : THEN COLON NEWLINE INDENT ( action )+ DEDENT ; def then(self, ): object = None THEN35 = None COLON36 = None action37 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:142:3: ( THEN COLON NEWLINE INDENT ( action )+ DEDENT ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:142:5: THEN COLON NEWLINE INDENT ( action )+ DEDENT pass THEN35=self.match(self.input, THEN, self.FOLLOW_THEN_in_then693) COLON36=self.match(self.input, COLON, self.FOLLOW_COLON_in_then695) self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_then697) #action start object = Then( [THEN35.text, COLON36.text], THEN35.getLine(), THEN35.getCharPositionInLine() ) #action end self.match(self.input, INDENT, self.FOLLOW_INDENT_in_then707) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:143:14: ( action )+ cnt16 = 0 while True: #loop16 alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == LPAREN or LA16_0 == NAME or LA16_0 == STRING or LA16_0 == NOT or LA16_0 == OBJECTBINDING or (ATTRIBUTE <= LA16_0 <= PRINT) or (FORGET <= LA16_0 <= HALT) or (PLUS <= LA16_0 <= MINUS) or LA16_0 == TILDE or LA16_0 == LBRACK or LA16_0 == LCURLY or (INT <= LA16_0 <= COMPLEX)) : alt16 = 1 if alt16 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:143:16: action pass self._state.following.append(self.FOLLOW_action_in_then711) action37 = self.action() self._state.following.pop() #action start object.append_child( action37 ) #action end else: if cnt16 >= 1: break #loop16 eee = EarlyExitException(16, self.input) raise eee cnt16 += 1 self.match(self.input, DEDENT, self.FOLLOW_DEDENT_in_then718) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "then" # $ANTLR start "ruleCondition" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:146:1: ruleCondition returns [object] : notCondition NEWLINE ; def ruleCondition(self, ): object = None notCondition38 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:147:3: ( notCondition NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:147:5: notCondition NEWLINE pass self._state.following.append(self.FOLLOW_notCondition_in_ruleCondition736) notCondition38 = self.notCondition() self._state.following.pop() self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_ruleCondition738) #action start object = RuleCondition(notCondition38) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "ruleCondition" # $ANTLR start "notCondition" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:150:1: notCondition returns [object] : ( NOT )* condition ; def notCondition(self, ): object = None NOT39 = None condition40 = None object = NotCondition() try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:152:3: ( ( NOT )* condition ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:152:5: ( NOT )* condition pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:152:5: ( NOT )* while True: #loop17 alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == NOT) : alt17 = 1 if alt17 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:152:7: NOT pass NOT39=self.match(self.input, NOT, self.FOLLOW_NOT_in_notCondition766) #action start object.append_child( NOT39.text ) #action end else: break #loop17 self._state.following.append(self.FOLLOW_condition_in_notCondition773) condition40 = self.condition() self._state.following.pop() #action start object.append_child( condition40 ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "notCondition" # $ANTLR start "condition" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:155:1: condition returns [object] : ( EXISTS )? classConstraint ; def condition(self, ): object = None EXISTS41 = None classConstraint42 = None object = Condition() try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:157:3: ( ( EXISTS )? classConstraint ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:157:5: ( EXISTS )? classConstraint pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:157:5: ( EXISTS )? alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == EXISTS) : alt18 = 1 if alt18 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:157:7: EXISTS pass EXISTS41=self.match(self.input, EXISTS, self.FOLLOW_EXISTS_in_condition801) #action start object.append_child( EXISTS41.text ) #action end self._state.following.append(self.FOLLOW_classConstraint_in_condition808) classConstraint42 = self.classConstraint() self._state.following.pop() #action start object.append_child( classConstraint42 ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "condition" # $ANTLR start "classConstraint" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:160:1: classConstraint returns [object] : ( OBJECTBINDING ASSIGNEQUAL )? NAME LPAREN ( constraint )? RPAREN ; def classConstraint(self, ): object = None OBJECTBINDING43 = None ASSIGNEQUAL44 = None NAME45 = None LPAREN46 = None RPAREN48 = None constraint47 = None object = ClassConstraint() try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:162:3: ( ( OBJECTBINDING ASSIGNEQUAL )? NAME LPAREN ( constraint )? RPAREN ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:162:5: ( OBJECTBINDING ASSIGNEQUAL )? NAME LPAREN ( constraint )? RPAREN pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:162:5: ( OBJECTBINDING ASSIGNEQUAL )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == OBJECTBINDING) : alt19 = 1 if alt19 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:162:7: OBJECTBINDING ASSIGNEQUAL pass OBJECTBINDING43=self.match(self.input, OBJECTBINDING, self.FOLLOW_OBJECTBINDING_in_classConstraint836) ASSIGNEQUAL44=self.match(self.input, ASSIGNEQUAL, self.FOLLOW_ASSIGNEQUAL_in_classConstraint838) #action start object.append_children( [ OBJECTBINDING43.text, ASSIGNEQUAL44.text] ) #action end NAME45=self.match(self.input, NAME, self.FOLLOW_NAME_in_classConstraint851) LPAREN46=self.match(self.input, LPAREN, self.FOLLOW_LPAREN_in_classConstraint853) #action start object.append_children( [NAME45.text, LPAREN46.text] ); #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:163:78: ( constraint )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == LPAREN or LA20_0 == NAME or LA20_0 == STRING or LA20_0 == NOT or LA20_0 == OBJECTBINDING or (PLUS <= LA20_0 <= MINUS) or LA20_0 == TILDE or LA20_0 == LBRACK or LA20_0 == LCURLY or (INT <= LA20_0 <= COMPLEX)) : alt20 = 1 if alt20 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:163:80: constraint pass self._state.following.append(self.FOLLOW_constraint_in_classConstraint859) constraint47 = self.constraint() self._state.following.pop() #action start object.append_child( constraint47 ) #action end RPAREN48=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_classConstraint866) #action start object.append_child( RPAREN48.text ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "classConstraint" # $ANTLR start "action" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:166:1: action returns [object] : ( simpleStmt | attributeAction | learnAction | forgetAction | modifyAction | haltAction ); def action(self, ): object = None simpleStmt49 = None attributeAction50 = None learnAction51 = None forgetAction52 = None modifyAction53 = None haltAction54 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:167:3: ( simpleStmt | attributeAction | learnAction | forgetAction | modifyAction | haltAction ) alt21 = 6 LA21 = self.input.LA(1) if LA21 == LPAREN or LA21 == NAME or LA21 == STRING or LA21 == NOT or LA21 == OBJECTBINDING or LA21 == PRINT or LA21 == PLUS or LA21 == MINUS or LA21 == TILDE or LA21 == LBRACK or LA21 == LCURLY or LA21 == INT or LA21 == LONGINT or LA21 == FLOAT or LA21 == COMPLEX: alt21 = 1 elif LA21 == ATTRIBUTE: alt21 = 2 elif LA21 == LEARN or LA21 == INSERT: alt21 = 3 elif LA21 == FORGET or LA21 == DELETE: alt21 = 4 elif LA21 == MODIFY: alt21 = 5 elif LA21 == HALT: alt21 = 6 else: nvae = NoViableAltException("", 21, 0, self.input) raise nvae if alt21 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:167:5: simpleStmt pass self._state.following.append(self.FOLLOW_simpleStmt_in_action886) simpleStmt49 = self.simpleStmt() self._state.following.pop() #action start object = Action( simpleStmt49, simpleStmt49.line, simpleStmt49.column ) #action end elif alt21 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:168:5: attributeAction pass self._state.following.append(self.FOLLOW_attributeAction_in_action900) attributeAction50 = self.attributeAction() self._state.following.pop() #action start object = Action( attributeAction50, attributeAction50.line, attributeAction50.column ) #action end elif alt21 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:169:5: learnAction pass self._state.following.append(self.FOLLOW_learnAction_in_action909) learnAction51 = self.learnAction() self._state.following.pop() #action start object = Action( learnAction51, learnAction51.line, learnAction51.column ) #action end elif alt21 == 4: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:170:5: forgetAction pass self._state.following.append(self.FOLLOW_forgetAction_in_action921) forgetAction52 = self.forgetAction() self._state.following.pop() #action start object = Action( forgetAction52, forgetAction52.line, forgetAction52.column ) #action end elif alt21 == 5: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:171:5: modifyAction pass self._state.following.append(self.FOLLOW_modifyAction_in_action933) modifyAction53 = self.modifyAction() self._state.following.pop() #action start object = Action( modifyAction53, modifyAction53.line, modifyAction53.column ) #action end elif alt21 == 6: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:172:5: haltAction pass self._state.following.append(self.FOLLOW_haltAction_in_action945) haltAction54 = self.haltAction() self._state.following.pop() #action start object = Action( haltAction54, haltAction54.line, haltAction54.column ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "action" # $ANTLR start "simpleStmt" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:175:1: simpleStmt returns [object] : ( expressionStmt | printStmt ); def simpleStmt(self, ): object = None expressionStmt55 = None printStmt56 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:176:3: ( expressionStmt | printStmt ) alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == LPAREN or LA22_0 == NAME or LA22_0 == STRING or LA22_0 == NOT or LA22_0 == OBJECTBINDING or (PLUS <= LA22_0 <= MINUS) or LA22_0 == TILDE or LA22_0 == LBRACK or LA22_0 == LCURLY or (INT <= LA22_0 <= COMPLEX)) : alt22 = 1 elif (LA22_0 == PRINT) : alt22 = 2 else: nvae = NoViableAltException("", 22, 0, self.input) raise nvae if alt22 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:176:5: expressionStmt pass self._state.following.append(self.FOLLOW_expressionStmt_in_simpleStmt971) expressionStmt55 = self.expressionStmt() self._state.following.pop() #action start object = SimpleStmt( expressionStmt55 ) #action end elif alt22 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:177:5: printStmt pass self._state.following.append(self.FOLLOW_printStmt_in_simpleStmt985) printStmt56 = self.printStmt() self._state.following.pop() #action start object = SimpleStmt( printStmt56, printStmt56.line, printStmt56.column ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "simpleStmt" # $ANTLR start "attributeAction" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:180:1: attributeAction returns [object] : ATTRIBUTE expressionStmt ; def attributeAction(self, ): object = None ATTRIBUTE57 = None expressionStmt58 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:181:3: ( ATTRIBUTE expressionStmt ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:181:5: ATTRIBUTE expressionStmt pass ATTRIBUTE57=self.match(self.input, ATTRIBUTE, self.FOLLOW_ATTRIBUTE_in_attributeAction1016) self._state.following.append(self.FOLLOW_expressionStmt_in_attributeAction1018) expressionStmt58 = self.expressionStmt() self._state.following.pop() #action start object = AttributeAction( [ ATTRIBUTE57.text, expressionStmt58 ] , ATTRIBUTE57.getLine(), ATTRIBUTE57.getCharPositionInLine() ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "attributeAction" # $ANTLR start "printStmt" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:184:1: printStmt returns [object] : PRINT (comparisonList1= comparisonList | RIGHTSHIFT comparisonList2= comparisonList )? NEWLINE ; def printStmt(self, ): object = None PRINT59 = None RIGHTSHIFT60 = None comparisonList1 = None comparisonList2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:185:3: ( PRINT (comparisonList1= comparisonList | RIGHTSHIFT comparisonList2= comparisonList )? NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:185:5: PRINT (comparisonList1= comparisonList | RIGHTSHIFT comparisonList2= comparisonList )? NEWLINE pass PRINT59=self.match(self.input, PRINT, self.FOLLOW_PRINT_in_printStmt1038) #action start object = PrintStmt( PRINT59.text, PRINT59.getLine(), PRINT59.getCharPositionInLine() ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:186:7: (comparisonList1= comparisonList | RIGHTSHIFT comparisonList2= comparisonList )? alt23 = 3 LA23_0 = self.input.LA(1) if (LA23_0 == LPAREN or LA23_0 == NAME or LA23_0 == STRING or LA23_0 == NOT or LA23_0 == OBJECTBINDING or (PLUS <= LA23_0 <= MINUS) or LA23_0 == TILDE or LA23_0 == LBRACK or LA23_0 == LCURLY or (INT <= LA23_0 <= COMPLEX)) : alt23 = 1 elif (LA23_0 == RIGHTSHIFT) : alt23 = 2 if alt23 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:186:9: comparisonList1= comparisonList pass self._state.following.append(self.FOLLOW_comparisonList_in_printStmt1052) comparisonList1 = self.comparisonList() self._state.following.pop() #action start object.append_child( comparisonList1 ) #action end elif alt23 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:187:9: RIGHTSHIFT comparisonList2= comparisonList pass RIGHTSHIFT60=self.match(self.input, RIGHTSHIFT, self.FOLLOW_RIGHTSHIFT_in_printStmt1064) self._state.following.append(self.FOLLOW_comparisonList_in_printStmt1068) comparisonList2 = self.comparisonList() self._state.following.pop() #action start object.append_children( [RIGHTSHIFT60.text, comparisonList2] ) #action end self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_printStmt1075) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "printStmt" # $ANTLR start "forgetAction" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:190:1: forgetAction returns [object] : ( FORGET | DELETE ) OBJECTBINDING NEWLINE ; def forgetAction(self, ): object = None FORGET61 = None DELETE62 = None OBJECTBINDING63 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:191:3: ( ( FORGET | DELETE ) OBJECTBINDING NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:191:5: ( FORGET | DELETE ) OBJECTBINDING NEWLINE pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:191:5: ( FORGET | DELETE ) alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == FORGET) : alt24 = 1 elif (LA24_0 == DELETE) : alt24 = 2 else: nvae = NoViableAltException("", 24, 0, self.input) raise nvae if alt24 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:191:7: FORGET pass FORGET61=self.match(self.input, FORGET, self.FOLLOW_FORGET_in_forgetAction1095) #action start object = ForgetAction( FORGET61.text, FORGET61.getLine(), FORGET61.getCharPositionInLine() ) #action end elif alt24 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:192:9: DELETE pass DELETE62=self.match(self.input, DELETE, self.FOLLOW_DELETE_in_forgetAction1107) #action start object = ForgetAction( DELETE62.text, DELETE62.getLine(), DELETE62.getCharPositionInLine() ) #action end OBJECTBINDING63=self.match(self.input, OBJECTBINDING, self.FOLLOW_OBJECTBINDING_in_forgetAction1120) #action start object.append_child( OBJECTBINDING63.text ) #action end self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_forgetAction1124) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "forgetAction" # $ANTLR start "learnAction" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:196:1: learnAction returns [object] : ( LEARN | INSERT ) NAME LPAREN ( argumentList )? RPAREN NEWLINE ; def learnAction(self, ): object = None LEARN64 = None INSERT65 = None NAME66 = None LPAREN67 = None RPAREN69 = None argumentList68 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:197:3: ( ( LEARN | INSERT ) NAME LPAREN ( argumentList )? RPAREN NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:197:5: ( LEARN | INSERT ) NAME LPAREN ( argumentList )? RPAREN NEWLINE pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:197:5: ( LEARN | INSERT ) alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == LEARN) : alt25 = 1 elif (LA25_0 == INSERT) : alt25 = 2 else: nvae = NoViableAltException("", 25, 0, self.input) raise nvae if alt25 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:197:7: LEARN pass LEARN64=self.match(self.input, LEARN, self.FOLLOW_LEARN_in_learnAction1144) #action start object = LearnAction( LEARN64.text, LEARN64.getLine(), LEARN64.getCharPositionInLine() ) #action end elif alt25 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:198:9: INSERT pass INSERT65=self.match(self.input, INSERT, self.FOLLOW_INSERT_in_learnAction1156) #action start object = LearnAction( INSERT65.text, INSERT65.getLine(), INSERT65.getCharPositionInLine() ) #action end NAME66=self.match(self.input, NAME, self.FOLLOW_NAME_in_learnAction1171) LPAREN67=self.match(self.input, LPAREN, self.FOLLOW_LPAREN_in_learnAction1173) #action start object.append_children( [NAME66.text, LPAREN67.text] ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:200:9: ( argumentList )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == LPAREN or LA26_0 == NAME or LA26_0 == STRING or LA26_0 == NOT or LA26_0 == OBJECTBINDING or (PLUS <= LA26_0 <= MINUS) or LA26_0 == TILDE or LA26_0 == LBRACK or LA26_0 == LCURLY or (INT <= LA26_0 <= COMPLEX)) : alt26 = 1 if alt26 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:200:11: argumentList pass self._state.following.append(self.FOLLOW_argumentList_in_learnAction1187) argumentList68 = self.argumentList() self._state.following.pop() #action start object.append_child( argumentList68 ) #action end RPAREN69=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_learnAction1194) #action start object.append_child( RPAREN69.text ) #action end self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_learnAction1198) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "learnAction" # $ANTLR start "modifyAction" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:203:1: modifyAction returns [object] : MODIFY OBJECTBINDING COLON NEWLINE INDENT ( propertyAssignment )+ DEDENT ; def modifyAction(self, ): object = None MODIFY70 = None OBJECTBINDING71 = None COLON72 = None propertyAssignment73 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:204:3: ( MODIFY OBJECTBINDING COLON NEWLINE INDENT ( propertyAssignment )+ DEDENT ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:204:5: MODIFY OBJECTBINDING COLON NEWLINE INDENT ( propertyAssignment )+ DEDENT pass MODIFY70=self.match(self.input, MODIFY, self.FOLLOW_MODIFY_in_modifyAction1216) OBJECTBINDING71=self.match(self.input, OBJECTBINDING, self.FOLLOW_OBJECTBINDING_in_modifyAction1218) COLON72=self.match(self.input, COLON, self.FOLLOW_COLON_in_modifyAction1220) self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_modifyAction1222) #action start object = ModifyAction( [MODIFY70.text, OBJECTBINDING71.text, COLON72.text], MODIFY70.getLine(), MODIFY70.getCharPositionInLine() ) #action end self.match(self.input, INDENT, self.FOLLOW_INDENT_in_modifyAction1232) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:205:14: ( propertyAssignment )+ cnt27 = 0 while True: #loop27 alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == NAME) : alt27 = 1 if alt27 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:205:16: propertyAssignment pass self._state.following.append(self.FOLLOW_propertyAssignment_in_modifyAction1236) propertyAssignment73 = self.propertyAssignment() self._state.following.pop() #action start object.append_child( propertyAssignment73 ) #action end else: if cnt27 >= 1: break #loop27 eee = EarlyExitException(27, self.input) raise eee cnt27 += 1 self.match(self.input, DEDENT, self.FOLLOW_DEDENT_in_modifyAction1243) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "modifyAction" # $ANTLR start "haltAction" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:208:1: haltAction returns [object] : HALT NEWLINE ; def haltAction(self, ): object = None HALT74 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:209:3: ( HALT NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:209:5: HALT NEWLINE pass HALT74=self.match(self.input, HALT, self.FOLLOW_HALT_in_haltAction1261) #action start object = HaltAction( HALT74.text, HALT74.getLine(), HALT74.getCharPositionInLine() ) #action end self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_haltAction1265) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "haltAction" # $ANTLR start "propertyAssignment" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:212:1: propertyAssignment returns [object] : NAME assignment constraint NEWLINE ; def propertyAssignment(self, ): object = None NAME75 = None assignment76 = None constraint77 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:213:3: ( NAME assignment constraint NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:213:5: NAME assignment constraint NEWLINE pass NAME75=self.match(self.input, NAME, self.FOLLOW_NAME_in_propertyAssignment1283) self._state.following.append(self.FOLLOW_assignment_in_propertyAssignment1285) assignment76 = self.assignment() self._state.following.pop() self._state.following.append(self.FOLLOW_constraint_in_propertyAssignment1287) constraint77 = self.constraint() self._state.following.pop() #action start object = PropertyAssignment( [NAME75.text, assignment76, constraint77] ) #action end self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_propertyAssignment1291) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "propertyAssignment" # $ANTLR start "expressionStmt" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:216:1: expressionStmt returns [object] : comparisonList1= comparisonList ( assignment comparisonList2= comparisonList )? NEWLINE ; def expressionStmt(self, ): object = None comparisonList1 = None comparisonList2 = None assignment78 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:217:3: (comparisonList1= comparisonList ( assignment comparisonList2= comparisonList )? NEWLINE ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:217:5: comparisonList1= comparisonList ( assignment comparisonList2= comparisonList )? NEWLINE pass self._state.following.append(self.FOLLOW_comparisonList_in_expressionStmt1311) comparisonList1 = self.comparisonList() self._state.following.pop() #action start object = ExpressionStmt( comparisonList1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:218:7: ( assignment comparisonList2= comparisonList )? alt28 = 2 LA28_0 = self.input.LA(1) if ((ASSIGN <= LA28_0 <= DOUBLESLASHEQUAL)) : alt28 = 1 if alt28 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:218:9: assignment comparisonList2= comparisonList pass self._state.following.append(self.FOLLOW_assignment_in_expressionStmt1323) assignment78 = self.assignment() self._state.following.pop() self._state.following.append(self.FOLLOW_comparisonList_in_expressionStmt1327) comparisonList2 = self.comparisonList() self._state.following.pop() #action start object.append_children( [assignment78, comparisonList2] ) #action end self.match(self.input, NEWLINE, self.FOLLOW_NEWLINE_in_expressionStmt1334) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "expressionStmt" # $ANTLR start "assignment" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:221:1: assignment returns [object] : ( ASSIGN | PLUSEQUAL | MINUSEQUAL | STAREQUAL | SLASHEQUAL | PERCENTEQUAL | AMPEREQUAL | VBAREQUAL | CIRCUMFLEXEQUAL | LEFTSHIFTEQUAL | RIGHTSHIFTEQUAL | DOUBLESTAREQUAL | DOUBLESLASHEQUAL ); def assignment(self, ): object = None ASSIGN79 = None PLUSEQUAL80 = None MINUSEQUAL81 = None STAREQUAL82 = None SLASHEQUAL83 = None PERCENTEQUAL84 = None AMPEREQUAL85 = None VBAREQUAL86 = None CIRCUMFLEXEQUAL87 = None LEFTSHIFTEQUAL88 = None RIGHTSHIFTEQUAL89 = None DOUBLESTAREQUAL90 = None DOUBLESLASHEQUAL91 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:222:3: ( ASSIGN | PLUSEQUAL | MINUSEQUAL | STAREQUAL | SLASHEQUAL | PERCENTEQUAL | AMPEREQUAL | VBAREQUAL | CIRCUMFLEXEQUAL | LEFTSHIFTEQUAL | RIGHTSHIFTEQUAL | DOUBLESTAREQUAL | DOUBLESLASHEQUAL ) alt29 = 13 LA29 = self.input.LA(1) if LA29 == ASSIGN: alt29 = 1 elif LA29 == PLUSEQUAL: alt29 = 2 elif LA29 == MINUSEQUAL: alt29 = 3 elif LA29 == STAREQUAL: alt29 = 4 elif LA29 == SLASHEQUAL: alt29 = 5 elif LA29 == PERCENTEQUAL: alt29 = 6 elif LA29 == AMPEREQUAL: alt29 = 7 elif LA29 == VBAREQUAL: alt29 = 8 elif LA29 == CIRCUMFLEXEQUAL: alt29 = 9 elif LA29 == LEFTSHIFTEQUAL: alt29 = 10 elif LA29 == RIGHTSHIFTEQUAL: alt29 = 11 elif LA29 == DOUBLESTAREQUAL: alt29 = 12 elif LA29 == DOUBLESLASHEQUAL: alt29 = 13 else: nvae = NoViableAltException("", 29, 0, self.input) raise nvae if alt29 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:222:5: ASSIGN pass ASSIGN79=self.match(self.input, ASSIGN, self.FOLLOW_ASSIGN_in_assignment1352) #action start object = Assignment( ASSIGN79.text ) #action end elif alt29 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:223:5: PLUSEQUAL pass PLUSEQUAL80=self.match(self.input, PLUSEQUAL, self.FOLLOW_PLUSEQUAL_in_assignment1371) #action start object = Assignment( PLUSEQUAL80.text ) #action end elif alt29 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:224:5: MINUSEQUAL pass MINUSEQUAL81=self.match(self.input, MINUSEQUAL, self.FOLLOW_MINUSEQUAL_in_assignment1387) #action start object = Assignment( MINUSEQUAL81.text ) #action end elif alt29 == 4: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:225:5: STAREQUAL pass STAREQUAL82=self.match(self.input, STAREQUAL, self.FOLLOW_STAREQUAL_in_assignment1402) #action start object = Assignment( STAREQUAL82.text ) #action end elif alt29 == 5: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:226:5: SLASHEQUAL pass SLASHEQUAL83=self.match(self.input, SLASHEQUAL, self.FOLLOW_SLASHEQUAL_in_assignment1418) #action start object = Assignment( SLASHEQUAL83.text ) #action end elif alt29 == 6: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:227:5: PERCENTEQUAL pass PERCENTEQUAL84=self.match(self.input, PERCENTEQUAL, self.FOLLOW_PERCENTEQUAL_in_assignment1433) #action start object = Assignment( PERCENTEQUAL84.text ) #action end elif alt29 == 7: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:228:5: AMPEREQUAL pass AMPEREQUAL85=self.match(self.input, AMPEREQUAL, self.FOLLOW_AMPEREQUAL_in_assignment1446) #action start object = Assignment( AMPEREQUAL85.text ) #action end elif alt29 == 8: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:229:5: VBAREQUAL pass VBAREQUAL86=self.match(self.input, VBAREQUAL, self.FOLLOW_VBAREQUAL_in_assignment1461) #action start object = Assignment( VBAREQUAL86.text ) #action end elif alt29 == 9: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:230:5: CIRCUMFLEXEQUAL pass CIRCUMFLEXEQUAL87=self.match(self.input, CIRCUMFLEXEQUAL, self.FOLLOW_CIRCUMFLEXEQUAL_in_assignment1477) #action start object = Assignment( CIRCUMFLEXEQUAL87.text ) #action end elif alt29 == 10: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:231:5: LEFTSHIFTEQUAL pass LEFTSHIFTEQUAL88=self.match(self.input, LEFTSHIFTEQUAL, self.FOLLOW_LEFTSHIFTEQUAL_in_assignment1487) #action start object = Assignment( LEFTSHIFTEQUAL88.text ) #action end elif alt29 == 11: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:232:5: RIGHTSHIFTEQUAL pass RIGHTSHIFTEQUAL89=self.match(self.input, RIGHTSHIFTEQUAL, self.FOLLOW_RIGHTSHIFTEQUAL_in_assignment1498) #action start object = Assignment( RIGHTSHIFTEQUAL89.text ) #action end elif alt29 == 12: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:233:5: DOUBLESTAREQUAL pass DOUBLESTAREQUAL90=self.match(self.input, DOUBLESTAREQUAL, self.FOLLOW_DOUBLESTAREQUAL_in_assignment1508) #action start object = Assignment( DOUBLESTAREQUAL90.text ) #action end elif alt29 == 13: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:234:5: DOUBLESLASHEQUAL pass DOUBLESLASHEQUAL91=self.match(self.input, DOUBLESLASHEQUAL, self.FOLLOW_DOUBLESLASHEQUAL_in_assignment1518) #action start object = Assignment( DOUBLESLASHEQUAL91.text ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "assignment" # $ANTLR start "constraint" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:237:1: constraint returns [object] : orConstraint ; def constraint(self, ): object = None orConstraint92 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:238:3: ( orConstraint ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:238:5: orConstraint pass self._state.following.append(self.FOLLOW_orConstraint_in_constraint1539) orConstraint92 = self.orConstraint() self._state.following.pop() #action start object = Constraint( orConstraint92 ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "constraint" # $ANTLR start "orConstraint" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:241:1: orConstraint returns [object] : constraint1= andConstraint ( OR constraint2= andConstraint )* ; def orConstraint(self, ): object = None OR93 = None constraint1 = None constraint2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:242:3: (constraint1= andConstraint ( OR constraint2= andConstraint )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:242:5: constraint1= andConstraint ( OR constraint2= andConstraint )* pass self._state.following.append(self.FOLLOW_andConstraint_in_orConstraint1561) constraint1 = self.andConstraint() self._state.following.pop() #action start object = OrConstraint( constraint1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:243:7: ( OR constraint2= andConstraint )* while True: #loop30 alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == OR) : alt30 = 1 if alt30 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:243:9: OR constraint2= andConstraint pass OR93=self.match(self.input, OR, self.FOLLOW_OR_in_orConstraint1573) self._state.following.append(self.FOLLOW_andConstraint_in_orConstraint1577) constraint2 = self.andConstraint() self._state.following.pop() #action start object.append_children( [OR93.text, constraint2] ) #action end else: break #loop30 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "orConstraint" # $ANTLR start "andConstraint" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:246:1: andConstraint returns [object] : constraint1= notConstraint ( AND constraint2= notConstraint )* ; def andConstraint(self, ): object = None AND94 = None constraint1 = None constraint2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:247:3: (constraint1= notConstraint ( AND constraint2= notConstraint )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:247:5: constraint1= notConstraint ( AND constraint2= notConstraint )* pass self._state.following.append(self.FOLLOW_notConstraint_in_andConstraint1602) constraint1 = self.notConstraint() self._state.following.pop() #action start object = AndConstraint( constraint1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:248:7: ( AND constraint2= notConstraint )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == AND) : alt31 = 1 if alt31 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:248:9: AND constraint2= notConstraint pass AND94=self.match(self.input, AND, self.FOLLOW_AND_in_andConstraint1614) self._state.following.append(self.FOLLOW_notConstraint_in_andConstraint1618) constraint2 = self.notConstraint() self._state.following.pop() #action start object.append_children( [AND94.text, constraint2] ) #action end else: break #loop31 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "andConstraint" # $ANTLR start "notConstraint" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:251:1: notConstraint returns [object] : ( NOT )* comparison ; def notConstraint(self, ): object = None NOT95 = None comparison96 = None object = NotConstraint() try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:253:3: ( ( NOT )* comparison ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:253:5: ( NOT )* comparison pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:253:5: ( NOT )* while True: #loop32 alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == NOT) : alt32 = 1 if alt32 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:253:7: NOT pass NOT95=self.match(self.input, NOT, self.FOLLOW_NOT_in_notConstraint1649) #action start object.append_child( NOT95.text ) #action end else: break #loop32 self._state.following.append(self.FOLLOW_comparison_in_notConstraint1656) comparison96 = self.comparison() self._state.following.pop() #action start object.append_child( comparison96 ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "notConstraint" # $ANTLR start "comparison" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:256:1: comparison returns [object] : expression1= expression ( comparisonOperation expression2= expression )* ; def comparison(self, ): object = None expression1 = None expression2 = None comparisonOperation97 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:257:3: (expression1= expression ( comparisonOperation expression2= expression )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:257:5: expression1= expression ( comparisonOperation expression2= expression )* pass self._state.following.append(self.FOLLOW_expression_in_comparison1678) expression1 = self.expression() self._state.following.pop() #action start object = Comparison( expression1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:258:5: ( comparisonOperation expression2= expression )* while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == NOT or (LESS <= LA33_0 <= IS)) : alt33 = 1 if alt33 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:258:7: comparisonOperation expression2= expression pass self._state.following.append(self.FOLLOW_comparisonOperation_in_comparison1688) comparisonOperation97 = self.comparisonOperation() self._state.following.pop() self._state.following.append(self.FOLLOW_expression_in_comparison1692) expression2 = self.expression() self._state.following.pop() #action start object.append_children( [ comparisonOperation97, expression2] ) #action end else: break #loop33 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "comparison" # $ANTLR start "comparisonOperation" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:261:1: comparisonOperation returns [object] : ( LESS | GREATER | EQUAL | GREATEREQUAL | LESSEQUAL | ALT_NOTEQUAL | NOTEQUAL | IN | NOT IN | IS | IS NOT ) ; def comparisonOperation(self, ): object = None LESS98 = None GREATER99 = None EQUAL100 = None GREATEREQUAL101 = None LESSEQUAL102 = None ALT_NOTEQUAL103 = None NOTEQUAL104 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:262:3: ( ( LESS | GREATER | EQUAL | GREATEREQUAL | LESSEQUAL | ALT_NOTEQUAL | NOTEQUAL | IN | NOT IN | IS | IS NOT ) ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:262:5: ( LESS | GREATER | EQUAL | GREATEREQUAL | LESSEQUAL | ALT_NOTEQUAL | NOTEQUAL | IN | NOT IN | IS | IS NOT ) pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:262:5: ( LESS | GREATER | EQUAL | GREATEREQUAL | LESSEQUAL | ALT_NOTEQUAL | NOTEQUAL | IN | NOT IN | IS | IS NOT ) alt34 = 11 alt34 = self.dfa34.predict(self.input) if alt34 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:262:7: LESS pass LESS98=self.match(self.input, LESS, self.FOLLOW_LESS_in_comparisonOperation1717) #action start object = ComparisonOperation( LESS98.text ) #action end elif alt34 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:263:7: GREATER pass GREATER99=self.match(self.input, GREATER, self.FOLLOW_GREATER_in_comparisonOperation1736) #action start object = ComparisonOperation( GREATER99.text ) #action end elif alt34 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:264:7: EQUAL pass EQUAL100=self.match(self.input, EQUAL, self.FOLLOW_EQUAL_in_comparisonOperation1752) #action start object = ComparisonOperation( EQUAL100.text ) #action end elif alt34 == 4: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:265:7: GREATEREQUAL pass GREATEREQUAL101=self.match(self.input, GREATEREQUAL, self.FOLLOW_GREATEREQUAL_in_comparisonOperation1770) #action start object = ComparisonOperation( GREATEREQUAL101.text ) #action end elif alt34 == 5: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:266:7: LESSEQUAL pass LESSEQUAL102=self.match(self.input, LESSEQUAL, self.FOLLOW_LESSEQUAL_in_comparisonOperation1781) #action start object = ComparisonOperation( LESSEQUAL102.text ) #action end elif alt34 == 6: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:267:7: ALT_NOTEQUAL pass ALT_NOTEQUAL103=self.match(self.input, ALT_NOTEQUAL, self.FOLLOW_ALT_NOTEQUAL_in_comparisonOperation1795) #action start object = ComparisonOperation( ALT_NOTEQUAL103.text ) #action end elif alt34 == 7: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:268:7: NOTEQUAL pass NOTEQUAL104=self.match(self.input, NOTEQUAL, self.FOLLOW_NOTEQUAL_in_comparisonOperation1806) #action start object = ComparisonOperation( NOTEQUAL104.text ) #action end elif alt34 == 8: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:269:7: IN pass self.match(self.input, IN, self.FOLLOW_IN_in_comparisonOperation1821) #action start object = ComparisonOperation( "in" ) #action end elif alt34 == 9: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:270:7: NOT IN pass self.match(self.input, NOT, self.FOLLOW_NOT_in_comparisonOperation1842) self.match(self.input, IN, self.FOLLOW_IN_in_comparisonOperation1844) #action start object = ComparisonOperation( "not in" ) #action end elif alt34 == 10: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:271:7: IS pass self.match(self.input, IS, self.FOLLOW_IS_in_comparisonOperation1861) #action start object = ComparisonOperation( "is" ) #action end elif alt34 == 11: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:272:7: IS NOT pass self.match(self.input, IS, self.FOLLOW_IS_in_comparisonOperation1882) self.match(self.input, NOT, self.FOLLOW_NOT_in_comparisonOperation1884) #action start object = ComparisonOperation( "is not" ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "comparisonOperation" # $ANTLR start "expression" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:275:1: expression returns [object] : bitwiseOrExpr ; def expression(self, ): object = None bitwiseOrExpr105 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:276:3: ( bitwiseOrExpr ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:276:5: bitwiseOrExpr pass self._state.following.append(self.FOLLOW_bitwiseOrExpr_in_expression1913) bitwiseOrExpr105 = self.bitwiseOrExpr() self._state.following.pop() #action start object = Expression( bitwiseOrExpr105 ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "expression" # $ANTLR start "bitwiseOrExpr" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:279:1: bitwiseOrExpr returns [object] : expr1= bitwiseXorExpr ( VBAR expr2= bitwiseXorExpr )* ; def bitwiseOrExpr(self, ): object = None VBAR106 = None expr1 = None expr2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:280:3: (expr1= bitwiseXorExpr ( VBAR expr2= bitwiseXorExpr )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:280:5: expr1= bitwiseXorExpr ( VBAR expr2= bitwiseXorExpr )* pass self._state.following.append(self.FOLLOW_bitwiseXorExpr_in_bitwiseOrExpr1935) expr1 = self.bitwiseXorExpr() self._state.following.pop() #action start object = BitwiseOrExpr( expr1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:281:7: ( VBAR expr2= bitwiseXorExpr )* while True: #loop35 alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == VBAR) : alt35 = 1 if alt35 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:281:9: VBAR expr2= bitwiseXorExpr pass VBAR106=self.match(self.input, VBAR, self.FOLLOW_VBAR_in_bitwiseOrExpr1947) self._state.following.append(self.FOLLOW_bitwiseXorExpr_in_bitwiseOrExpr1951) expr2 = self.bitwiseXorExpr() self._state.following.pop() #action start object.append_children( [VBAR106.text, expr2] ) #action end else: break #loop35 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "bitwiseOrExpr" # $ANTLR start "bitwiseXorExpr" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:284:1: bitwiseXorExpr returns [object] : expr1= bitwiseAndExpr ( CIRCUMFLEX expr2= bitwiseAndExpr )* ; def bitwiseXorExpr(self, ): object = None CIRCUMFLEX107 = None expr1 = None expr2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:285:3: (expr1= bitwiseAndExpr ( CIRCUMFLEX expr2= bitwiseAndExpr )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:285:5: expr1= bitwiseAndExpr ( CIRCUMFLEX expr2= bitwiseAndExpr )* pass self._state.following.append(self.FOLLOW_bitwiseAndExpr_in_bitwiseXorExpr1976) expr1 = self.bitwiseAndExpr() self._state.following.pop() #action start object = BitwiseXorExpr( expr1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:286:7: ( CIRCUMFLEX expr2= bitwiseAndExpr )* while True: #loop36 alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == CIRCUMFLEX) : alt36 = 1 if alt36 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:286:9: CIRCUMFLEX expr2= bitwiseAndExpr pass CIRCUMFLEX107=self.match(self.input, CIRCUMFLEX, self.FOLLOW_CIRCUMFLEX_in_bitwiseXorExpr1988) self._state.following.append(self.FOLLOW_bitwiseAndExpr_in_bitwiseXorExpr1992) expr2 = self.bitwiseAndExpr() self._state.following.pop() #action start object.append_children( [CIRCUMFLEX107.text, expr2] ) #action end else: break #loop36 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "bitwiseXorExpr" # $ANTLR start "bitwiseAndExpr" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:289:1: bitwiseAndExpr returns [object] : expr1= shiftExpr ( AMPER expr2= shiftExpr )* ; def bitwiseAndExpr(self, ): object = None AMPER108 = None expr1 = None expr2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:290:3: (expr1= shiftExpr ( AMPER expr2= shiftExpr )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:290:5: expr1= shiftExpr ( AMPER expr2= shiftExpr )* pass self._state.following.append(self.FOLLOW_shiftExpr_in_bitwiseAndExpr2017) expr1 = self.shiftExpr() self._state.following.pop() #action start object = BitwiseAndExpr( expr1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:291:7: ( AMPER expr2= shiftExpr )* while True: #loop37 alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == AMPER) : alt37 = 1 if alt37 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:291:9: AMPER expr2= shiftExpr pass AMPER108=self.match(self.input, AMPER, self.FOLLOW_AMPER_in_bitwiseAndExpr2029) self._state.following.append(self.FOLLOW_shiftExpr_in_bitwiseAndExpr2033) expr2 = self.shiftExpr() self._state.following.pop() #action start object.append_children( [AMPER108.text, expr2] ) #action end else: break #loop37 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "bitwiseAndExpr" # $ANTLR start "shiftExpr" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:294:1: shiftExpr returns [object] : expr1= arithExpr ( ( LEFTSHIFT | RIGHTSHIFT ) expr2= arithExpr )* ; def shiftExpr(self, ): object = None LEFTSHIFT109 = None RIGHTSHIFT110 = None expr1 = None expr2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:295:3: (expr1= arithExpr ( ( LEFTSHIFT | RIGHTSHIFT ) expr2= arithExpr )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:295:5: expr1= arithExpr ( ( LEFTSHIFT | RIGHTSHIFT ) expr2= arithExpr )* pass self._state.following.append(self.FOLLOW_arithExpr_in_shiftExpr2058) expr1 = self.arithExpr() self._state.following.pop() #action start object = ShiftExpr( expr1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:296:7: ( ( LEFTSHIFT | RIGHTSHIFT ) expr2= arithExpr )* while True: #loop39 alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == RIGHTSHIFT or LA39_0 == LEFTSHIFT) : alt39 = 1 if alt39 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:296:9: ( LEFTSHIFT | RIGHTSHIFT ) expr2= arithExpr pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:296:9: ( LEFTSHIFT | RIGHTSHIFT ) alt38 = 2 LA38_0 = self.input.LA(1) if (LA38_0 == LEFTSHIFT) : alt38 = 1 elif (LA38_0 == RIGHTSHIFT) : alt38 = 2 else: nvae = NoViableAltException("", 38, 0, self.input) raise nvae if alt38 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:296:11: LEFTSHIFT pass LEFTSHIFT109=self.match(self.input, LEFTSHIFT, self.FOLLOW_LEFTSHIFT_in_shiftExpr2072) #action start object.append_child( LEFTSHIFT109.text ) #action end elif alt38 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:296:67: RIGHTSHIFT pass RIGHTSHIFT110=self.match(self.input, RIGHTSHIFT, self.FOLLOW_RIGHTSHIFT_in_shiftExpr2078) #action start object.append_child( RIGHTSHIFT110.text ) #action end self._state.following.append(self.FOLLOW_arithExpr_in_shiftExpr2096) expr2 = self.arithExpr() self._state.following.pop() #action start object.append_child( expr2 ) #action end else: break #loop39 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "shiftExpr" # $ANTLR start "arithExpr" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:300:1: arithExpr returns [object] : term1= term ( ( PLUS | MINUS ) term2= term )* ; def arithExpr(self, ): object = None PLUS111 = None MINUS112 = None term1 = None term2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:301:3: (term1= term ( ( PLUS | MINUS ) term2= term )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:301:5: term1= term ( ( PLUS | MINUS ) term2= term )* pass self._state.following.append(self.FOLLOW_term_in_arithExpr2121) term1 = self.term() self._state.following.pop() #action start object = ArithExpr( term1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:302:7: ( ( PLUS | MINUS ) term2= term )* while True: #loop41 alt41 = 2 LA41_0 = self.input.LA(1) if ((PLUS <= LA41_0 <= MINUS)) : alt41 = 1 if alt41 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:302:9: ( PLUS | MINUS ) term2= term pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:302:9: ( PLUS | MINUS ) alt40 = 2 LA40_0 = self.input.LA(1) if (LA40_0 == PLUS) : alt40 = 1 elif (LA40_0 == MINUS) : alt40 = 2 else: nvae = NoViableAltException("", 40, 0, self.input) raise nvae if alt40 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:302:11: PLUS pass PLUS111=self.match(self.input, PLUS, self.FOLLOW_PLUS_in_arithExpr2135) #action start object.append_child( PLUS111.text ) #action end elif alt40 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:302:57: MINUS pass MINUS112=self.match(self.input, MINUS, self.FOLLOW_MINUS_in_arithExpr2141) #action start object.append_child( MINUS112.text ) #action end self._state.following.append(self.FOLLOW_term_in_arithExpr2159) term2 = self.term() self._state.following.pop() #action start object.append_child( term2 ) #action end else: break #loop41 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "arithExpr" # $ANTLR start "term" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:306:1: term returns [object] : factor1= factor ( ( STAR | SLASH | PERCENT | DOUBLESLASH ) factor2= factor )* ; def term(self, ): object = None STAR113 = None SLASH114 = None PERCENT115 = None DOUBLESLASH116 = None factor1 = None factor2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:307:3: (factor1= factor ( ( STAR | SLASH | PERCENT | DOUBLESLASH ) factor2= factor )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:307:5: factor1= factor ( ( STAR | SLASH | PERCENT | DOUBLESLASH ) factor2= factor )* pass self._state.following.append(self.FOLLOW_factor_in_term2184) factor1 = self.factor() self._state.following.pop() #action start object = Term( factor1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:308:7: ( ( STAR | SLASH | PERCENT | DOUBLESLASH ) factor2= factor )* while True: #loop43 alt43 = 2 LA43_0 = self.input.LA(1) if ((STAR <= LA43_0 <= DOUBLESLASH)) : alt43 = 1 if alt43 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:308:9: ( STAR | SLASH | PERCENT | DOUBLESLASH ) factor2= factor pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:308:9: ( STAR | SLASH | PERCENT | DOUBLESLASH ) alt42 = 4 LA42 = self.input.LA(1) if LA42 == STAR: alt42 = 1 elif LA42 == SLASH: alt42 = 2 elif LA42 == PERCENT: alt42 = 3 elif LA42 == DOUBLESLASH: alt42 = 4 else: nvae = NoViableAltException("", 42, 0, self.input) raise nvae if alt42 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:308:10: STAR pass STAR113=self.match(self.input, STAR, self.FOLLOW_STAR_in_term2197) #action start object.append_child( STAR113.text ) #action end elif alt42 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:308:56: SLASH pass SLASH114=self.match(self.input, SLASH, self.FOLLOW_SLASH_in_term2203) #action start object.append_child( SLASH114.text ) #action end elif alt42 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:309:13: PERCENT pass PERCENT115=self.match(self.input, PERCENT, self.FOLLOW_PERCENT_in_term2219) #action start object.append_child( PERCENT115.text ) #action end elif alt42 == 4: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:309:65: DOUBLESLASH pass DOUBLESLASH116=self.match(self.input, DOUBLESLASH, self.FOLLOW_DOUBLESLASH_in_term2225) #action start object.append_child( DOUBLESLASH116.text ) #action end self._state.following.append(self.FOLLOW_factor_in_term2247) factor2 = self.factor() self._state.following.pop() #action start object.append_child( factor2 ) #action end else: break #loop43 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "term" # $ANTLR start "factor" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:313:1: factor returns [object] : ( PLUS factor1= factor | MINUS factor2= factor | TILDE factor3= factor | power ); def factor(self, ): object = None PLUS117 = None MINUS118 = None TILDE119 = None factor1 = None factor2 = None factor3 = None power120 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:314:3: ( PLUS factor1= factor | MINUS factor2= factor | TILDE factor3= factor | power ) alt44 = 4 LA44 = self.input.LA(1) if LA44 == PLUS: alt44 = 1 elif LA44 == MINUS: alt44 = 2 elif LA44 == TILDE: alt44 = 3 elif LA44 == LPAREN or LA44 == NAME or LA44 == STRING or LA44 == OBJECTBINDING or LA44 == LBRACK or LA44 == LCURLY or LA44 == INT or LA44 == LONGINT or LA44 == FLOAT or LA44 == COMPLEX: alt44 = 4 else: nvae = NoViableAltException("", 44, 0, self.input) raise nvae if alt44 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:314:5: PLUS factor1= factor pass PLUS117=self.match(self.input, PLUS, self.FOLLOW_PLUS_in_factor2270) self._state.following.append(self.FOLLOW_factor_in_factor2275) factor1 = self.factor() self._state.following.pop() #action start object = Factor( [PLUS117.text, factor1] ) #action end elif alt44 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:315:5: MINUS factor2= factor pass MINUS118=self.match(self.input, MINUS, self.FOLLOW_MINUS_in_factor2283) self._state.following.append(self.FOLLOW_factor_in_factor2287) factor2 = self.factor() self._state.following.pop() #action start object = Factor( [MINUS118.text, factor2] ) #action end elif alt44 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:316:5: TILDE factor3= factor pass TILDE119=self.match(self.input, TILDE, self.FOLLOW_TILDE_in_factor2295) self._state.following.append(self.FOLLOW_factor_in_factor2299) factor3 = self.factor() self._state.following.pop() #action start object = Factor( [TILDE119.text, factor3] ) #action end elif alt44 == 4: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:317:5: power pass self._state.following.append(self.FOLLOW_power_in_factor2307) power120 = self.power() self._state.following.pop() #action start object = Factor( power120 ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "factor" # $ANTLR start "power" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:320:1: power returns [object] : atom ( trailer )* ( options {greedy=true; } : DOUBLESTAR factor )? ; def power(self, ): object = None DOUBLESTAR123 = None atom121 = None trailer122 = None factor124 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:321:3: ( atom ( trailer )* ( options {greedy=true; } : DOUBLESTAR factor )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:321:5: atom ( trailer )* ( options {greedy=true; } : DOUBLESTAR factor )? pass self._state.following.append(self.FOLLOW_atom_in_power2327) atom121 = self.atom() self._state.following.pop() #action start object = Power( atom121 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:322:7: ( trailer )* while True: #loop45 alt45 = 2 LA45_0 = self.input.LA(1) if (LA45_0 == LPAREN or LA45_0 == DOT or LA45_0 == LBRACK) : alt45 = 1 if alt45 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:322:9: trailer pass self._state.following.append(self.FOLLOW_trailer_in_power2339) trailer122 = self.trailer() self._state.following.pop() #action start object.append_child( trailer122 ) #action end else: break #loop45 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:323:7: ( options {greedy=true; } : DOUBLESTAR factor )? alt46 = 2 LA46_0 = self.input.LA(1) if (LA46_0 == DOUBLESTAR) : alt46 = 1 if alt46 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:323:31: DOUBLESTAR factor pass DOUBLESTAR123=self.match(self.input, DOUBLESTAR, self.FOLLOW_DOUBLESTAR_in_power2360) self._state.following.append(self.FOLLOW_factor_in_power2362) factor124 = self.factor() self._state.following.pop() #action start object.append_children( [DOUBLESTAR123.text, factor124] ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "power" # $ANTLR start "atom" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:326:1: atom returns [object] : ( LPAREN (comparisonList1= comparisonList )? RPAREN | LBRACK ( listmaker )? RBRACK | LCURLY ( dictmaker )? RCURLY | NAME | OBJECTBINDING | INT | LONGINT | FLOAT | COMPLEX | ( STRING )+ ); def atom(self, ): object = None LPAREN125 = None RPAREN126 = None LBRACK127 = None RBRACK129 = None LCURLY130 = None RCURLY132 = None NAME133 = None OBJECTBINDING134 = None INT135 = None LONGINT136 = None FLOAT137 = None COMPLEX138 = None STRING139 = None comparisonList1 = None listmaker128 = None dictmaker131 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:327:3: ( LPAREN (comparisonList1= comparisonList )? RPAREN | LBRACK ( listmaker )? RBRACK | LCURLY ( dictmaker )? RCURLY | NAME | OBJECTBINDING | INT | LONGINT | FLOAT | COMPLEX | ( STRING )+ ) alt51 = 10 LA51 = self.input.LA(1) if LA51 == LPAREN: alt51 = 1 elif LA51 == LBRACK: alt51 = 2 elif LA51 == LCURLY: alt51 = 3 elif LA51 == NAME: alt51 = 4 elif LA51 == OBJECTBINDING: alt51 = 5 elif LA51 == INT: alt51 = 6 elif LA51 == LONGINT: alt51 = 7 elif LA51 == FLOAT: alt51 = 8 elif LA51 == COMPLEX: alt51 = 9 elif LA51 == STRING: alt51 = 10 else: nvae = NoViableAltException("", 51, 0, self.input) raise nvae if alt51 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:327:5: LPAREN (comparisonList1= comparisonList )? RPAREN pass LPAREN125=self.match(self.input, LPAREN, self.FOLLOW_LPAREN_in_atom2385) #action start object = Atom( LPAREN125.text ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:328:23: (comparisonList1= comparisonList )? alt47 = 2 LA47_0 = self.input.LA(1) if (LA47_0 == LPAREN or LA47_0 == NAME or LA47_0 == STRING or LA47_0 == NOT or LA47_0 == OBJECTBINDING or (PLUS <= LA47_0 <= MINUS) or LA47_0 == TILDE or LA47_0 == LBRACK or LA47_0 == LCURLY or (INT <= LA47_0 <= COMPLEX)) : alt47 = 1 if alt47 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:328:25: comparisonList1= comparisonList pass self._state.following.append(self.FOLLOW_comparisonList_in_atom2424) comparisonList1 = self.comparisonList() self._state.following.pop() #action start object.append_child( comparisonList1 ) #action end RPAREN126=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_atom2453) #action start object.append_child( RPAREN126.text ) #action end elif alt51 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:330:5: LBRACK ( listmaker )? RBRACK pass LBRACK127=self.match(self.input, LBRACK, self.FOLLOW_LBRACK_in_atom2461) #action start object = Atom( LBRACK127.text ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:331:23: ( listmaker )? alt48 = 2 LA48_0 = self.input.LA(1) if (LA48_0 == LPAREN or LA48_0 == NAME or LA48_0 == STRING or LA48_0 == NOT or LA48_0 == OBJECTBINDING or (PLUS <= LA48_0 <= MINUS) or LA48_0 == TILDE or LA48_0 == LBRACK or LA48_0 == LCURLY or (INT <= LA48_0 <= COMPLEX)) : alt48 = 1 if alt48 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:331:25: listmaker pass self._state.following.append(self.FOLLOW_listmaker_in_atom2498) listmaker128 = self.listmaker() self._state.following.pop() #action start object.append_child( listmaker128 ) #action end RBRACK129=self.match(self.input, RBRACK, self.FOLLOW_RBRACK_in_atom2527) #action start object.append_child( RBRACK129.text ) #action end elif alt51 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:333:5: LCURLY ( dictmaker )? RCURLY pass LCURLY130=self.match(self.input, LCURLY, self.FOLLOW_LCURLY_in_atom2535) #action start object = Atom( LCURLY130.text ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:334:23: ( dictmaker )? alt49 = 2 LA49_0 = self.input.LA(1) if (LA49_0 == LPAREN or LA49_0 == NAME or LA49_0 == STRING or LA49_0 == NOT or LA49_0 == OBJECTBINDING or (PLUS <= LA49_0 <= MINUS) or LA49_0 == TILDE or LA49_0 == LBRACK or LA49_0 == LCURLY or (INT <= LA49_0 <= COMPLEX)) : alt49 = 1 if alt49 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:334:25: dictmaker pass self._state.following.append(self.FOLLOW_dictmaker_in_atom2572) dictmaker131 = self.dictmaker() self._state.following.pop() #action start object.append_child( dictmaker131 ) #action end RCURLY132=self.match(self.input, RCURLY, self.FOLLOW_RCURLY_in_atom2601) #action start object.append_child( RCURLY132.text ) #action end elif alt51 == 4: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:337:5: NAME pass NAME133=self.match(self.input, NAME, self.FOLLOW_NAME_in_atom2610) #action start object = Atom( NAME133.text ) #action end elif alt51 == 5: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:338:5: OBJECTBINDING pass OBJECTBINDING134=self.match(self.input, OBJECTBINDING, self.FOLLOW_OBJECTBINDING_in_atom2629) #action start object = Atom( OBJECTBINDING134.text ) #action end elif alt51 == 6: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:339:5: INT pass INT135=self.match(self.input, INT, self.FOLLOW_INT_in_atom2639) #action start object = Atom( INT135.text ) #action end elif alt51 == 7: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:340:5: LONGINT pass LONGINT136=self.match(self.input, LONGINT, self.FOLLOW_LONGINT_in_atom2659) #action start object = Atom( LONGINT136.text ) #action end elif alt51 == 8: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:341:5: FLOAT pass FLOAT137=self.match(self.input, FLOAT, self.FOLLOW_FLOAT_in_atom2675) #action start object = Atom( FLOAT137.text ) #action end elif alt51 == 9: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:342:5: COMPLEX pass COMPLEX138=self.match(self.input, COMPLEX, self.FOLLOW_COMPLEX_in_atom2693) #action start object = Atom( COMPLEX138.text ) #action end elif alt51 == 10: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:343:5: ( STRING )+ pass #action start object = Atom() #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:343:25: ( STRING )+ cnt50 = 0 while True: #loop50 alt50 = 2 LA50_0 = self.input.LA(1) if (LA50_0 == STRING) : alt50 = 1 if alt50 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:343:27: STRING pass STRING139=self.match(self.input, STRING, self.FOLLOW_STRING_in_atom2713) #action start object.append_child( STRING139.text ) #action end else: if cnt50 >= 1: break #loop50 eee = EarlyExitException(50, self.input) raise eee cnt50 += 1 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "atom" # $ANTLR start "listmaker" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:346:1: listmaker returns [object] : constraint1= constraint ( options {greedy=true; } : COMMA constraint2= constraint )* ( COMMA )? ; def listmaker(self, ): object = None constraint1 = None constraint2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:347:3: (constraint1= constraint ( options {greedy=true; } : COMMA constraint2= constraint )* ( COMMA )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:347:5: constraint1= constraint ( options {greedy=true; } : COMMA constraint2= constraint )* ( COMMA )? pass self._state.following.append(self.FOLLOW_constraint_in_listmaker2738) constraint1 = self.constraint() self._state.following.pop() #action start object = ListMaker( constraint1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:348:7: ( options {greedy=true; } : COMMA constraint2= constraint )* while True: #loop52 alt52 = 2 LA52_0 = self.input.LA(1) if (LA52_0 == COMMA) : LA52_1 = self.input.LA(2) if (LA52_1 == LPAREN or LA52_1 == NAME or LA52_1 == STRING or LA52_1 == NOT or LA52_1 == OBJECTBINDING or (PLUS <= LA52_1 <= MINUS) or LA52_1 == TILDE or LA52_1 == LBRACK or LA52_1 == LCURLY or (INT <= LA52_1 <= COMPLEX)) : alt52 = 1 if alt52 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:348:31: COMMA constraint2= constraint pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_listmaker2756) self._state.following.append(self.FOLLOW_constraint_in_listmaker2760) constraint2 = self.constraint() self._state.following.pop() #action start object.append_children( [ ",", constraint2] ) #action end else: break #loop52 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:349:7: ( COMMA )? alt53 = 2 LA53_0 = self.input.LA(1) if (LA53_0 == COMMA) : alt53 = 1 if alt53 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:349:9: COMMA pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_listmaker2775) #action start object.append_child( "," ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "listmaker" # $ANTLR start "comparisonList" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:352:1: comparisonList returns [object] : constraint1= constraint ( options {k=2; } : COMMA constraint2= constraint )* ( COMMA )? ; def comparisonList(self, ): object = None constraint1 = None constraint2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:353:3: (constraint1= constraint ( options {k=2; } : COMMA constraint2= constraint )* ( COMMA )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:353:5: constraint1= constraint ( options {k=2; } : COMMA constraint2= constraint )* ( COMMA )? pass self._state.following.append(self.FOLLOW_constraint_in_comparisonList2800) constraint1 = self.constraint() self._state.following.pop() #action start object = ComparisonList( constraint1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:354:7: ( options {k=2; } : COMMA constraint2= constraint )* while True: #loop54 alt54 = 2 alt54 = self.dfa54.predict(self.input) if alt54 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:354:23: COMMA constraint2= constraint pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_comparisonList2818) self._state.following.append(self.FOLLOW_constraint_in_comparisonList2822) constraint2 = self.constraint() self._state.following.pop() #action start object.append_children( [",", constraint2] ) #action end else: break #loop54 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:355:7: ( COMMA )? alt55 = 2 LA55_0 = self.input.LA(1) if (LA55_0 == COMMA) : alt55 = 1 if alt55 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:355:9: COMMA pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_comparisonList2837) #action start object.append_child( "," ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "comparisonList" # $ANTLR start "trailer" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:358:1: trailer returns [object] : ( LPAREN ( argumentList )? RPAREN | LBRACK ( constraint )? RBRACK | DOT NAME ); def trailer(self, ): object = None LPAREN140 = None RPAREN142 = None LBRACK143 = None RBRACK145 = None DOT146 = None NAME147 = None argumentList141 = None constraint144 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:359:3: ( LPAREN ( argumentList )? RPAREN | LBRACK ( constraint )? RBRACK | DOT NAME ) alt58 = 3 LA58 = self.input.LA(1) if LA58 == LPAREN: alt58 = 1 elif LA58 == LBRACK: alt58 = 2 elif LA58 == DOT: alt58 = 3 else: nvae = NoViableAltException("", 58, 0, self.input) raise nvae if alt58 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:359:5: LPAREN ( argumentList )? RPAREN pass LPAREN140=self.match(self.input, LPAREN, self.FOLLOW_LPAREN_in_trailer2860) #action start object = Trailer( LPAREN140.text ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:359:49: ( argumentList )? alt56 = 2 LA56_0 = self.input.LA(1) if (LA56_0 == LPAREN or LA56_0 == NAME or LA56_0 == STRING or LA56_0 == NOT or LA56_0 == OBJECTBINDING or (PLUS <= LA56_0 <= MINUS) or LA56_0 == TILDE or LA56_0 == LBRACK or LA56_0 == LCURLY or (INT <= LA56_0 <= COMPLEX)) : alt56 = 1 if alt56 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:359:50: argumentList pass self._state.following.append(self.FOLLOW_argumentList_in_trailer2865) argumentList141 = self.argumentList() self._state.following.pop() #action start object.append_child( argumentList141 ) #action end RPAREN142=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_trailer2872) #action start object.append_child( RPAREN142.text ) #action end elif alt58 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:360:5: LBRACK ( constraint )? RBRACK pass LBRACK143=self.match(self.input, LBRACK, self.FOLLOW_LBRACK_in_trailer2880) #action start object = Trailer( LBRACK143.text ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:360:49: ( constraint )? alt57 = 2 LA57_0 = self.input.LA(1) if (LA57_0 == LPAREN or LA57_0 == NAME or LA57_0 == STRING or LA57_0 == NOT or LA57_0 == OBJECTBINDING or (PLUS <= LA57_0 <= MINUS) or LA57_0 == TILDE or LA57_0 == LBRACK or LA57_0 == LCURLY or (INT <= LA57_0 <= COMPLEX)) : alt57 = 1 if alt57 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:360:50: constraint pass self._state.following.append(self.FOLLOW_constraint_in_trailer2885) constraint144 = self.constraint() self._state.following.pop() #action start object.append_child( constraint144 ) #action end RBRACK145=self.match(self.input, RBRACK, self.FOLLOW_RBRACK_in_trailer2892) #action start object.append_child( RBRACK145.text ) #action end elif alt58 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:361:5: DOT NAME pass DOT146=self.match(self.input, DOT, self.FOLLOW_DOT_in_trailer2900) NAME147=self.match(self.input, NAME, self.FOLLOW_NAME_in_trailer2902) #action start object = Trailer( [DOT146.text, NAME147.text] ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "trailer" # $ANTLR start "expressionList" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:364:1: expressionList returns [object] : expression1= expression ( options {k=2; } : COMMA expression2= expression )* ( COMMA )? ; def expressionList(self, ): object = None expression1 = None expression2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:365:3: (expression1= expression ( options {k=2; } : COMMA expression2= expression )* ( COMMA )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:365:5: expression1= expression ( options {k=2; } : COMMA expression2= expression )* ( COMMA )? pass self._state.following.append(self.FOLLOW_expression_in_expressionList2925) expression1 = self.expression() self._state.following.pop() #action start object = ExpressionList( expression1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:366:7: ( options {k=2; } : COMMA expression2= expression )* while True: #loop59 alt59 = 2 alt59 = self.dfa59.predict(self.input) if alt59 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:366:25: COMMA expression2= expression pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_expressionList2945) self._state.following.append(self.FOLLOW_expression_in_expressionList2949) expression2 = self.expression() self._state.following.pop() #action start object.append_children( [ ",", expression2 ] ) #action end else: break #loop59 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:367:7: ( COMMA )? alt60 = 2 LA60_0 = self.input.LA(1) if (LA60_0 == COMMA) : alt60 = 1 if alt60 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:367:9: COMMA pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_expressionList2964) #action start object.append_child( "," ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "expressionList" # $ANTLR start "dictmaker" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:370:1: dictmaker returns [object] : constraint1= constraint COLON constraint2= constraint ( options {k=2; } : COMMA constraint3= constraint COLON constraint4= constraint )* ( COMMA )? ; def dictmaker(self, ): object = None constraint1 = None constraint2 = None constraint3 = None constraint4 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:371:3: (constraint1= constraint COLON constraint2= constraint ( options {k=2; } : COMMA constraint3= constraint COLON constraint4= constraint )* ( COMMA )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:371:5: constraint1= constraint COLON constraint2= constraint ( options {k=2; } : COMMA constraint3= constraint COLON constraint4= constraint )* ( COMMA )? pass self._state.following.append(self.FOLLOW_constraint_in_dictmaker2989) constraint1 = self.constraint() self._state.following.pop() #action start object = DictMaker( constraint1 ) #action end self.match(self.input, COLON, self.FOLLOW_COLON_in_dictmaker2999) self._state.following.append(self.FOLLOW_constraint_in_dictmaker3003) constraint2 = self.constraint() self._state.following.pop() #action start object.append_children( [":", constraint2] ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:373:9: ( options {k=2; } : COMMA constraint3= constraint COLON constraint4= constraint )* while True: #loop61 alt61 = 2 alt61 = self.dfa61.predict(self.input) if alt61 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:373:26: COMMA constraint3= constraint COLON constraint4= constraint pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_dictmaker3024) self._state.following.append(self.FOLLOW_constraint_in_dictmaker3028) constraint3 = self.constraint() self._state.following.pop() self.match(self.input, COLON, self.FOLLOW_COLON_in_dictmaker3030) self._state.following.append(self.FOLLOW_constraint_in_dictmaker3034) constraint4 = self.constraint() self._state.following.pop() #action start object.append_children( [",", constraint3, ":", constraint4] ) #action end else: break #loop61 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:374:9: ( COMMA )? alt62 = 2 LA62_0 = self.input.LA(1) if (LA62_0 == COMMA) : alt62 = 1 if alt62 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:374:11: COMMA pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_dictmaker3051) #action start object.append_child( "," ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "dictmaker" # $ANTLR start "argumentList" # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:377:1: argumentList returns [object] : constraint1= constraint ( COMMA constraint2= constraint )* ( COMMA )? ; def argumentList(self, ): object = None constraint1 = None constraint2 = None try: try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:378:3: (constraint1= constraint ( COMMA constraint2= constraint )* ( COMMA )? ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:378:5: constraint1= constraint ( COMMA constraint2= constraint )* ( COMMA )? pass self._state.following.append(self.FOLLOW_constraint_in_argumentList3076) constraint1 = self.constraint() self._state.following.pop() #action start object = ArgumentList( constraint1 ) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:379:7: ( COMMA constraint2= constraint )* while True: #loop63 alt63 = 2 LA63_0 = self.input.LA(1) if (LA63_0 == COMMA) : LA63_1 = self.input.LA(2) if (LA63_1 == LPAREN or LA63_1 == NAME or LA63_1 == STRING or LA63_1 == NOT or LA63_1 == OBJECTBINDING or (PLUS <= LA63_1 <= MINUS) or LA63_1 == TILDE or LA63_1 == LBRACK or LA63_1 == LCURLY or (INT <= LA63_1 <= COMPLEX)) : alt63 = 1 if alt63 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:379:9: COMMA constraint2= constraint pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_argumentList3088) self._state.following.append(self.FOLLOW_constraint_in_argumentList3092) constraint2 = self.constraint() self._state.following.pop() #action start object.append_children( [",", constraint2] ) #action end else: break #loop63 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:380:7: ( COMMA )? alt64 = 2 LA64_0 = self.input.LA(1) if (LA64_0 == COMMA) : alt64 = 1 if alt64 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:380:9: COMMA pass self.match(self.input, COMMA, self.FOLLOW_COMMA_in_argumentList3107) #action start object.append_child( "," ) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return object # $ANTLR end "argumentList" # Delegated rules # lookup tables for DFA #34 DFA34_eot = DFA.unpack( u"\15\uffff" ) DFA34_eof = DFA.unpack( u"\15\uffff" ) DFA34_min = DFA.unpack( u"\1\25\11\uffff\1\11\2\uffff" ) DFA34_max = DFA.unpack( u"\1\71\11\uffff\1\115\2\uffff" ) DFA34_accept = DFA.unpack( u"\1\uffff\1\1\1\2\1\3\1\4\1\5\1\6\1\7\1\10\1\11\1\uffff\1\13\1\12" ) DFA34_special = DFA.unpack( u"\15\uffff" ) DFA34_transition = [ DFA.unpack(u"\1\11\33\uffff\1\1\1\2\1\3\1\4\1\5\1\6\1\7\1\10\1\12"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\14\2\uffff\1\14\4\uffff\1\14\3\uffff\1\13\1\uffff" u"\1\14\46\uffff\2\14\4\uffff\1\14\1\uffff\1\14\1\uffff\1\14\1\uffff" u"\4\14"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #34 class DFA34(DFA): pass # lookup tables for DFA #54 DFA54_eot = DFA.unpack( u"\56\uffff" ) DFA54_eof = DFA.unpack( u"\56\uffff" ) DFA54_min = DFA.unpack( u"\2\6\54\uffff" ) DFA54_max = DFA.unpack( u"\1\56\1\115\54\uffff" ) DFA54_accept = DFA.unpack( u"\2\uffff\1\2\16\uffff\1\1\34\uffff" ) DFA54_special = DFA.unpack( u"\56\uffff" ) DFA54_transition = [ DFA.unpack(u"\1\2\3\uffff\1\2\1\1\26\uffff\15\2"), DFA.unpack(u"\1\2\2\uffff\1\21\1\2\1\uffff\1\21\4\uffff\1\21\3\uffff" u"\1\21\1\uffff\1\21\12\uffff\15\2\17\uffff\2\21\4\uffff\1\21\1\uffff" u"\1\21\1\uffff\1\21\1\uffff\4\21"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #54 class DFA54(DFA): pass # lookup tables for DFA #59 DFA59_eot = DFA.unpack( u"\21\uffff" ) DFA59_eof = DFA.unpack( u"\2\2\17\uffff" ) DFA59_min = DFA.unpack( u"\1\13\1\11\17\uffff" ) DFA59_max = DFA.unpack( u"\1\13\1\115\17\uffff" ) DFA59_accept = DFA.unpack( u"\2\uffff\1\2\1\uffff\1\1\14\uffff" ) DFA59_special = DFA.unpack( u"\21\uffff" ) DFA59_transition = [ DFA.unpack(u"\1\1"), DFA.unpack(u"\1\4\2\uffff\1\4\4\uffff\1\4\5\uffff\1\4\46\uffff\2" u"\4\4\uffff\1\4\1\uffff\1\4\1\uffff\1\4\1\uffff\4\4"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #59 class DFA59(DFA): pass # lookup tables for DFA #61 DFA61_eot = DFA.unpack( u"\22\uffff" ) DFA61_eof = DFA.unpack( u"\22\uffff" ) DFA61_min = DFA.unpack( u"\1\13\1\11\20\uffff" ) DFA61_max = DFA.unpack( u"\1\111\1\115\20\uffff" ) DFA61_accept = DFA.unpack( u"\2\uffff\1\2\1\1\16\uffff" ) DFA61_special = DFA.unpack( u"\22\uffff" ) DFA61_transition = [ DFA.unpack(u"\1\1\75\uffff\1\2"), DFA.unpack(u"\1\3\2\uffff\1\3\4\uffff\1\3\3\uffff\1\3\1\uffff\1" u"\3\46\uffff\2\3\4\uffff\1\3\1\uffff\1\3\1\uffff\1\3\1\2\4\3"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #61 class DFA61(DFA): pass FOLLOW_NEWLINE_in_file78 = frozenset([1, 6, 7, 8, 9, 12, 15, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_statement_in_file82 = frozenset([1, 6, 7, 8, 9, 12, 15, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_EOF_in_file93 = frozenset([1]) FOLLOW_importStmt_in_statement111 = frozenset([1]) FOLLOW_attributeStmt_in_statement120 = frozenset([1]) FOLLOW_ruleStmt_in_statement129 = frozenset([1]) FOLLOW_importName_in_importStmt152 = frozenset([1]) FOLLOW_importFrom_in_importStmt160 = frozenset([1]) FOLLOW_IMPORT_in_importName180 = frozenset([12]) FOLLOW_dottedAsNames_in_importName182 = frozenset([6]) FOLLOW_NEWLINE_in_importName186 = frozenset([1]) FOLLOW_FROM_in_importFrom204 = frozenset([12]) FOLLOW_dottedName_in_importFrom208 = frozenset([7]) FOLLOW_IMPORT_in_importFrom212 = frozenset([9, 12]) FOLLOW_importAsNames_in_importFrom226 = frozenset([6]) FOLLOW_LPAREN_in_importFrom238 = frozenset([12]) FOLLOW_importAsNames_in_importFrom243 = frozenset([10]) FOLLOW_RPAREN_in_importFrom245 = frozenset([6]) FOLLOW_NEWLINE_in_importFrom257 = frozenset([1]) FOLLOW_importAsName_in_importAsNames276 = frozenset([1, 11]) FOLLOW_COMMA_in_importAsNames288 = frozenset([12]) FOLLOW_importAsName_in_importAsNames292 = frozenset([1, 11]) FOLLOW_COMMA_in_importAsNames301 = frozenset([1]) FOLLOW_NAME_in_importAsName325 = frozenset([1, 13]) FOLLOW_AS_in_importAsName331 = frozenset([12]) FOLLOW_NAME_in_importAsName335 = frozenset([1]) FOLLOW_dottedAsName_in_dottedAsNames359 = frozenset([1, 11]) FOLLOW_COMMA_in_dottedAsNames371 = frozenset([12]) FOLLOW_dottedAsName_in_dottedAsNames375 = frozenset([1, 11]) FOLLOW_dottedName_in_dottedAsName397 = frozenset([1, 13]) FOLLOW_AS_in_dottedAsName403 = frozenset([12]) FOLLOW_NAME_in_dottedAsName405 = frozenset([1]) FOLLOW_NAME_in_dottedName430 = frozenset([1, 14]) FOLLOW_DOT_in_dottedName442 = frozenset([12]) FOLLOW_NAME_in_dottedName446 = frozenset([1, 14]) FOLLOW_expressionStmt_in_attributeStmt469 = frozenset([1]) FOLLOW_RULE_in_ruleStmt489 = frozenset([12, 17]) FOLLOW_id_in_ruleStmt491 = frozenset([16]) FOLLOW_COLON_in_ruleStmt493 = frozenset([6]) FOLLOW_NEWLINE_in_ruleStmt495 = frozenset([4]) FOLLOW_INDENT_in_ruleStmt505 = frozenset([18, 19, 20]) FOLLOW_ruleAttribute_in_ruleStmt509 = frozenset([18, 19, 20]) FOLLOW_when_in_ruleStmt531 = frozenset([18, 19, 20]) FOLLOW_then_in_ruleStmt551 = frozenset([5]) FOLLOW_DEDENT_in_ruleStmt556 = frozenset([1]) FOLLOW_NAME_in_id574 = frozenset([1]) FOLLOW_STRING_in_id585 = frozenset([1]) FOLLOW_agendaGroup_in_ruleAttribute606 = frozenset([1]) FOLLOW_AGENDAGROUP_in_agendaGroup626 = frozenset([12, 17]) FOLLOW_id_in_agendaGroup628 = frozenset([6]) FOLLOW_NEWLINE_in_agendaGroup630 = frozenset([1]) FOLLOW_WHEN_in_when650 = frozenset([16]) FOLLOW_COLON_in_when652 = frozenset([6]) FOLLOW_NEWLINE_in_when654 = frozenset([4]) FOLLOW_INDENT_in_when664 = frozenset([5, 12, 21, 22, 23]) FOLLOW_ruleCondition_in_when668 = frozenset([5]) FOLLOW_DEDENT_in_when675 = frozenset([1]) FOLLOW_THEN_in_then693 = frozenset([16]) FOLLOW_COLON_in_then695 = frozenset([6]) FOLLOW_NEWLINE_in_then697 = frozenset([4]) FOLLOW_INDENT_in_then707 = frozenset([9, 12, 17, 21, 23, 25, 26, 28, 29, 30, 31, 32, 33, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_action_in_then711 = frozenset([5, 9, 12, 17, 21, 23, 25, 26, 28, 29, 30, 31, 32, 33, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_DEDENT_in_then718 = frozenset([1]) FOLLOW_notCondition_in_ruleCondition736 = frozenset([6]) FOLLOW_NEWLINE_in_ruleCondition738 = frozenset([1]) FOLLOW_NOT_in_notCondition766 = frozenset([12, 21, 22, 23]) FOLLOW_condition_in_notCondition773 = frozenset([1]) FOLLOW_EXISTS_in_condition801 = frozenset([12, 21, 22, 23]) FOLLOW_classConstraint_in_condition808 = frozenset([1]) FOLLOW_OBJECTBINDING_in_classConstraint836 = frozenset([24]) FOLLOW_ASSIGNEQUAL_in_classConstraint838 = frozenset([12]) FOLLOW_NAME_in_classConstraint851 = frozenset([9]) FOLLOW_LPAREN_in_classConstraint853 = frozenset([9, 10, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_classConstraint859 = frozenset([10]) FOLLOW_RPAREN_in_classConstraint866 = frozenset([1]) FOLLOW_simpleStmt_in_action886 = frozenset([1]) FOLLOW_attributeAction_in_action900 = frozenset([1]) FOLLOW_learnAction_in_action909 = frozenset([1]) FOLLOW_forgetAction_in_action921 = frozenset([1]) FOLLOW_modifyAction_in_action933 = frozenset([1]) FOLLOW_haltAction_in_action945 = frozenset([1]) FOLLOW_expressionStmt_in_simpleStmt971 = frozenset([1]) FOLLOW_printStmt_in_simpleStmt985 = frozenset([1]) FOLLOW_ATTRIBUTE_in_attributeAction1016 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_expressionStmt_in_attributeAction1018 = frozenset([1]) FOLLOW_PRINT_in_printStmt1038 = frozenset([6, 9, 12, 17, 21, 23, 27, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_comparisonList_in_printStmt1052 = frozenset([6]) FOLLOW_RIGHTSHIFT_in_printStmt1064 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_comparisonList_in_printStmt1068 = frozenset([6]) FOLLOW_NEWLINE_in_printStmt1075 = frozenset([1]) FOLLOW_FORGET_in_forgetAction1095 = frozenset([23]) FOLLOW_DELETE_in_forgetAction1107 = frozenset([23]) FOLLOW_OBJECTBINDING_in_forgetAction1120 = frozenset([6]) FOLLOW_NEWLINE_in_forgetAction1124 = frozenset([1]) FOLLOW_LEARN_in_learnAction1144 = frozenset([12]) FOLLOW_INSERT_in_learnAction1156 = frozenset([12]) FOLLOW_NAME_in_learnAction1171 = frozenset([9]) FOLLOW_LPAREN_in_learnAction1173 = frozenset([9, 10, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_argumentList_in_learnAction1187 = frozenset([10]) FOLLOW_RPAREN_in_learnAction1194 = frozenset([6]) FOLLOW_NEWLINE_in_learnAction1198 = frozenset([1]) FOLLOW_MODIFY_in_modifyAction1216 = frozenset([23]) FOLLOW_OBJECTBINDING_in_modifyAction1218 = frozenset([16]) FOLLOW_COLON_in_modifyAction1220 = frozenset([6]) FOLLOW_NEWLINE_in_modifyAction1222 = frozenset([4]) FOLLOW_INDENT_in_modifyAction1232 = frozenset([12]) FOLLOW_propertyAssignment_in_modifyAction1236 = frozenset([5, 12]) FOLLOW_DEDENT_in_modifyAction1243 = frozenset([1]) FOLLOW_HALT_in_haltAction1261 = frozenset([6]) FOLLOW_NEWLINE_in_haltAction1265 = frozenset([1]) FOLLOW_NAME_in_propertyAssignment1283 = frozenset([34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46]) FOLLOW_assignment_in_propertyAssignment1285 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_propertyAssignment1287 = frozenset([6]) FOLLOW_NEWLINE_in_propertyAssignment1291 = frozenset([1]) FOLLOW_comparisonList_in_expressionStmt1311 = frozenset([6, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46]) FOLLOW_assignment_in_expressionStmt1323 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_comparisonList_in_expressionStmt1327 = frozenset([6]) FOLLOW_NEWLINE_in_expressionStmt1334 = frozenset([1]) FOLLOW_ASSIGN_in_assignment1352 = frozenset([1]) FOLLOW_PLUSEQUAL_in_assignment1371 = frozenset([1]) FOLLOW_MINUSEQUAL_in_assignment1387 = frozenset([1]) FOLLOW_STAREQUAL_in_assignment1402 = frozenset([1]) FOLLOW_SLASHEQUAL_in_assignment1418 = frozenset([1]) FOLLOW_PERCENTEQUAL_in_assignment1433 = frozenset([1]) FOLLOW_AMPEREQUAL_in_assignment1446 = frozenset([1]) FOLLOW_VBAREQUAL_in_assignment1461 = frozenset([1]) FOLLOW_CIRCUMFLEXEQUAL_in_assignment1477 = frozenset([1]) FOLLOW_LEFTSHIFTEQUAL_in_assignment1487 = frozenset([1]) FOLLOW_RIGHTSHIFTEQUAL_in_assignment1498 = frozenset([1]) FOLLOW_DOUBLESTAREQUAL_in_assignment1508 = frozenset([1]) FOLLOW_DOUBLESLASHEQUAL_in_assignment1518 = frozenset([1]) FOLLOW_orConstraint_in_constraint1539 = frozenset([1]) FOLLOW_andConstraint_in_orConstraint1561 = frozenset([1, 47]) FOLLOW_OR_in_orConstraint1573 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_andConstraint_in_orConstraint1577 = frozenset([1, 47]) FOLLOW_notConstraint_in_andConstraint1602 = frozenset([1, 48]) FOLLOW_AND_in_andConstraint1614 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_notConstraint_in_andConstraint1618 = frozenset([1, 48]) FOLLOW_NOT_in_notConstraint1649 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_comparison_in_notConstraint1656 = frozenset([1]) FOLLOW_expression_in_comparison1678 = frozenset([1, 21, 49, 50, 51, 52, 53, 54, 55, 56, 57]) FOLLOW_comparisonOperation_in_comparison1688 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_expression_in_comparison1692 = frozenset([1, 21, 49, 50, 51, 52, 53, 54, 55, 56, 57]) FOLLOW_LESS_in_comparisonOperation1717 = frozenset([1]) FOLLOW_GREATER_in_comparisonOperation1736 = frozenset([1]) FOLLOW_EQUAL_in_comparisonOperation1752 = frozenset([1]) FOLLOW_GREATEREQUAL_in_comparisonOperation1770 = frozenset([1]) FOLLOW_LESSEQUAL_in_comparisonOperation1781 = frozenset([1]) FOLLOW_ALT_NOTEQUAL_in_comparisonOperation1795 = frozenset([1]) FOLLOW_NOTEQUAL_in_comparisonOperation1806 = frozenset([1]) FOLLOW_IN_in_comparisonOperation1821 = frozenset([1]) FOLLOW_NOT_in_comparisonOperation1842 = frozenset([56]) FOLLOW_IN_in_comparisonOperation1844 = frozenset([1]) FOLLOW_IS_in_comparisonOperation1861 = frozenset([1]) FOLLOW_IS_in_comparisonOperation1882 = frozenset([21]) FOLLOW_NOT_in_comparisonOperation1884 = frozenset([1]) FOLLOW_bitwiseOrExpr_in_expression1913 = frozenset([1]) FOLLOW_bitwiseXorExpr_in_bitwiseOrExpr1935 = frozenset([1, 58]) FOLLOW_VBAR_in_bitwiseOrExpr1947 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_bitwiseXorExpr_in_bitwiseOrExpr1951 = frozenset([1, 58]) FOLLOW_bitwiseAndExpr_in_bitwiseXorExpr1976 = frozenset([1, 59]) FOLLOW_CIRCUMFLEX_in_bitwiseXorExpr1988 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_bitwiseAndExpr_in_bitwiseXorExpr1992 = frozenset([1, 59]) FOLLOW_shiftExpr_in_bitwiseAndExpr2017 = frozenset([1, 60]) FOLLOW_AMPER_in_bitwiseAndExpr2029 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_shiftExpr_in_bitwiseAndExpr2033 = frozenset([1, 60]) FOLLOW_arithExpr_in_shiftExpr2058 = frozenset([1, 27, 61]) FOLLOW_LEFTSHIFT_in_shiftExpr2072 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_RIGHTSHIFT_in_shiftExpr2078 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_arithExpr_in_shiftExpr2096 = frozenset([1, 27, 61]) FOLLOW_term_in_arithExpr2121 = frozenset([1, 62, 63]) FOLLOW_PLUS_in_arithExpr2135 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_MINUS_in_arithExpr2141 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_term_in_arithExpr2159 = frozenset([1, 62, 63]) FOLLOW_factor_in_term2184 = frozenset([1, 64, 65, 66, 67]) FOLLOW_STAR_in_term2197 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_SLASH_in_term2203 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_PERCENT_in_term2219 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_DOUBLESLASH_in_term2225 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_factor_in_term2247 = frozenset([1, 64, 65, 66, 67]) FOLLOW_PLUS_in_factor2270 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_factor_in_factor2275 = frozenset([1]) FOLLOW_MINUS_in_factor2283 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_factor_in_factor2287 = frozenset([1]) FOLLOW_TILDE_in_factor2295 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_factor_in_factor2299 = frozenset([1]) FOLLOW_power_in_factor2307 = frozenset([1]) FOLLOW_atom_in_power2327 = frozenset([1, 9, 14, 69, 70]) FOLLOW_trailer_in_power2339 = frozenset([1, 9, 14, 69, 70]) FOLLOW_DOUBLESTAR_in_power2360 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_factor_in_power2362 = frozenset([1]) FOLLOW_LPAREN_in_atom2385 = frozenset([9, 10, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_comparisonList_in_atom2424 = frozenset([10]) FOLLOW_RPAREN_in_atom2453 = frozenset([1]) FOLLOW_LBRACK_in_atom2461 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 71, 72, 74, 75, 76, 77]) FOLLOW_listmaker_in_atom2498 = frozenset([71]) FOLLOW_RBRACK_in_atom2527 = frozenset([1]) FOLLOW_LCURLY_in_atom2535 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 73, 74, 75, 76, 77]) FOLLOW_dictmaker_in_atom2572 = frozenset([73]) FOLLOW_RCURLY_in_atom2601 = frozenset([1]) FOLLOW_NAME_in_atom2610 = frozenset([1]) FOLLOW_OBJECTBINDING_in_atom2629 = frozenset([1]) FOLLOW_INT_in_atom2639 = frozenset([1]) FOLLOW_LONGINT_in_atom2659 = frozenset([1]) FOLLOW_FLOAT_in_atom2675 = frozenset([1]) FOLLOW_COMPLEX_in_atom2693 = frozenset([1]) FOLLOW_STRING_in_atom2713 = frozenset([1, 17]) FOLLOW_constraint_in_listmaker2738 = frozenset([1, 11]) FOLLOW_COMMA_in_listmaker2756 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_listmaker2760 = frozenset([1, 11]) FOLLOW_COMMA_in_listmaker2775 = frozenset([1]) FOLLOW_constraint_in_comparisonList2800 = frozenset([1, 11]) FOLLOW_COMMA_in_comparisonList2818 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_comparisonList2822 = frozenset([1, 11]) FOLLOW_COMMA_in_comparisonList2837 = frozenset([1]) FOLLOW_LPAREN_in_trailer2860 = frozenset([9, 10, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_argumentList_in_trailer2865 = frozenset([10]) FOLLOW_RPAREN_in_trailer2872 = frozenset([1]) FOLLOW_LBRACK_in_trailer2880 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 71, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_trailer2885 = frozenset([71]) FOLLOW_RBRACK_in_trailer2892 = frozenset([1]) FOLLOW_DOT_in_trailer2900 = frozenset([12]) FOLLOW_NAME_in_trailer2902 = frozenset([1]) FOLLOW_expression_in_expressionList2925 = frozenset([1, 11]) FOLLOW_COMMA_in_expressionList2945 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_expression_in_expressionList2949 = frozenset([1, 11]) FOLLOW_COMMA_in_expressionList2964 = frozenset([1]) FOLLOW_constraint_in_dictmaker2989 = frozenset([16]) FOLLOW_COLON_in_dictmaker2999 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_dictmaker3003 = frozenset([1, 11]) FOLLOW_COMMA_in_dictmaker3024 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_dictmaker3028 = frozenset([16]) FOLLOW_COLON_in_dictmaker3030 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_dictmaker3034 = frozenset([1, 11]) FOLLOW_COMMA_in_dictmaker3051 = frozenset([1]) FOLLOW_constraint_in_argumentList3076 = frozenset([1, 11]) FOLLOW_COMMA_in_argumentList3088 = frozenset([9, 12, 17, 21, 23, 62, 63, 68, 70, 72, 74, 75, 76, 77]) FOLLOW_constraint_in_argumentList3092 = frozenset([1, 11]) FOLLOW_COMMA_in_argumentList3107 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("PolicyLexer", PolicyParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "r0k3/Intellect", "path": "intellect/grammar/PolicyParser.py", "copies": "2", "size": "180891", "license": "bsd-3-clause", "hash": 2298840445090487000, "line_mean": 37.0662878788, "line_max": 307, "alpha_frac": 0.5431115976, "autogenerated": false, "ratio": 3.9325840253924085, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5475695622992408, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 17, 2009 19:23:44 /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g 2013-03-25 15:29:48 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types DOLLAR=79 DOUBLESLASH=67 MODIFY=32 SLASHEQUAL=38 BACKQUOTE=80 EXPONENT=84 CONTINUED_LINE=88 LBRACK=70 STAR=64 CIRCUMFLEXEQUAL=42 DOUBLESTAR=69 OBJECTBINDING=23 HALT=33 LETTER=82 ESC=87 TRIAPOS=85 ATTRIBUTE=25 GREATEREQUAL=52 COMPLEX=77 FLOAT=76 DEDENT=5 NOT=21 ASSIGNEQUAL=24 AND=48 RIGHTSHIFTEQUAL=44 LEARN=30 EOF=-1 LPAREN=9 INDENT=4 PLUSEQUAL=35 LEADING_WS=90 NOTEQUAL=55 AS=13 VBAR=58 MINUSEQUAL=36 RPAREN=10 IMPORT=7 NAME=12 SLASH=65 GREATER=50 IN=56 THEN=20 INSERT=31 COMMA=11 IS=57 AMPER=60 EQUAL=51 DOUBLESTAREQUAL=45 TILDE=68 LESS=49 LEFTSHIFTEQUAL=43 PLUS=62 LEFTSHIFT=61 DIGIT=83 EXISTS=22 DOT=14 COMMENT=91 AGENDAGROUP=18 RBRACK=71 PERCENT=66 RULE=15 LCURLY=72 INT=74 DELETE=29 MINUS=63 RIGHTSHIFT=27 SEMI=78 PRINT=26 TRIQUOTE=86 COLON=16 DOUBLESLASHEQUAL=46 WS=89 NEWLINE=6 AMPEREQUAL=40 WHEN=19 VBAREQUAL=41 RCURLY=73 OR=47 ASSIGN=34 LONGINT=75 FORGET=28 GLOBAL=81 FROM=8 PERCENTEQUAL=39 LESSEQUAL=53 STAREQUAL=37 CIRCUMFLEX=59 STRING=17 ALT_NOTEQUAL=54 class PolicyLexer(Lexer): grammarFileName = "/Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g" antlr_version = version_str_to_tuple("3.1.3 Mar 17, 2009 19:23:44") antlr_version_str = "3.1.3 Mar 17, 2009 19:23:44" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(PolicyLexer, self).__init__(input, state) self.dfa9 = self.DFA9( self, 9, eot = self.DFA9_eot, eof = self.DFA9_eof, min = self.DFA9_min, max = self.DFA9_max, accept = self.DFA9_accept, special = self.DFA9_special, transition = self.DFA9_transition ) self.dfa16 = self.DFA16( self, 16, eot = self.DFA16_eot, eof = self.DFA16_eof, min = self.DFA16_min, max = self.DFA16_max, accept = self.DFA16_accept, special = self.DFA16_special, transition = self.DFA16_transition ) self.dfa46 = self.DFA46( self, 46, eot = self.DFA46_eot, eof = self.DFA46_eof, min = self.DFA46_min, max = self.DFA46_max, accept = self.DFA46_accept, special = self.DFA46_special, transition = self.DFA46_transition ) self.dfa47 = self.DFA47( self, 47, eot = self.DFA47_eot, eof = self.DFA47_eof, min = self.DFA47_min, max = self.DFA47_max, accept = self.DFA47_accept, special = self.DFA47_special, transition = self.DFA47_transition ) self.implicitLineJoiningLevel = 0 self.startPosition = -1 # $ANTLR start "LPAREN" def mLPAREN(self, ): try: _type = LPAREN _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:388:3: ( '(' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:388:5: '(' pass self.match(40) #action start self.implicitLineJoiningLevel += 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LPAREN" # $ANTLR start "RPAREN" def mRPAREN(self, ): try: _type = RPAREN _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:392:3: ( ')' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:392:5: ')' pass self.match(41) #action start self.implicitLineJoiningLevel -= 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RPAREN" # $ANTLR start "LBRACK" def mLBRACK(self, ): try: _type = LBRACK _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:396:3: ( '[' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:396:5: '[' pass self.match(91) #action start self.implicitLineJoiningLevel += 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LBRACK" # $ANTLR start "RBRACK" def mRBRACK(self, ): try: _type = RBRACK _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:400:3: ( ']' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:400:5: ']' pass self.match(93) #action start self.implicitLineJoiningLevel -= 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RBRACK" # $ANTLR start "LCURLY" def mLCURLY(self, ): try: _type = LCURLY _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:404:3: ( '{' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:404:5: '{' pass self.match(123) #action start self.implicitLineJoiningLevel += 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LCURLY" # $ANTLR start "RCURLY" def mRCURLY(self, ): try: _type = RCURLY _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:408:3: ( '}' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:408:5: '}' pass self.match(125) #action start self.implicitLineJoiningLevel -= 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RCURLY" # $ANTLR start "COLON" def mCOLON(self, ): try: _type = COLON _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:412:3: ( ':' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:412:5: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COLON" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:416:3: ( ',' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:416:5: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "DOT" def mDOT(self, ): try: _type = DOT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:420:3: ( '.' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:420:5: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOT" # $ANTLR start "SEMI" def mSEMI(self, ): try: _type = SEMI _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:424:3: ( ';' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:424:5: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SEMI" # $ANTLR start "PLUS" def mPLUS(self, ): try: _type = PLUS _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:428:3: ( '+' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:428:5: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUS" # $ANTLR start "MINUS" def mMINUS(self, ): try: _type = MINUS _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:432:3: ( '-' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:432:5: '-' pass self.match(45) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MINUS" # $ANTLR start "STAR" def mSTAR(self, ): try: _type = STAR _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:436:3: ( '*' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:436:5: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STAR" # $ANTLR start "DOLLAR" def mDOLLAR(self, ): try: _type = DOLLAR _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:440:3: ( '$' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:440:5: '$' pass self.match(36) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOLLAR" # $ANTLR start "SLASH" def mSLASH(self, ): try: _type = SLASH _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:444:3: ( '/' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:444:5: '/' pass self.match(47) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SLASH" # $ANTLR start "VBAR" def mVBAR(self, ): try: _type = VBAR _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:448:3: ( '|' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:448:5: '|' pass self.match(124) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "VBAR" # $ANTLR start "AMPER" def mAMPER(self, ): try: _type = AMPER _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:452:3: ( '&' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:452:5: '&' pass self.match(38) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AMPER" # $ANTLR start "LESS" def mLESS(self, ): try: _type = LESS _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:456:3: ( '<' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:456:5: '<' pass self.match(60) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LESS" # $ANTLR start "GREATER" def mGREATER(self, ): try: _type = GREATER _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:460:3: ( '>' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:460:5: '>' pass self.match(62) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "GREATER" # $ANTLR start "ASSIGN" def mASSIGN(self, ): try: _type = ASSIGN _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:464:3: ( '=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:464:5: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ASSIGN" # $ANTLR start "PERCENT" def mPERCENT(self, ): try: _type = PERCENT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:468:3: ( '%' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:468:5: '%' pass self.match(37) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PERCENT" # $ANTLR start "BACKQUOTE" def mBACKQUOTE(self, ): try: _type = BACKQUOTE _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:472:3: ( '`' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:472:5: '`' pass self.match(96) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BACKQUOTE" # $ANTLR start "CIRCUMFLEX" def mCIRCUMFLEX(self, ): try: _type = CIRCUMFLEX _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:476:3: ( '^' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:476:5: '^' pass self.match(94) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CIRCUMFLEX" # $ANTLR start "TILDE" def mTILDE(self, ): try: _type = TILDE _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:480:3: ( '~' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:480:5: '~' pass self.match(126) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "TILDE" # $ANTLR start "EQUAL" def mEQUAL(self, ): try: _type = EQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:484:3: ( '==' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:484:5: '==' pass self.match("==") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EQUAL" # $ANTLR start "ASSIGNEQUAL" def mASSIGNEQUAL(self, ): try: _type = ASSIGNEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:488:3: ( ':=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:488:5: ':=' pass self.match(":=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ASSIGNEQUAL" # $ANTLR start "NOTEQUAL" def mNOTEQUAL(self, ): try: _type = NOTEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:492:3: ( '!=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:492:5: '!=' pass self.match("!=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NOTEQUAL" # $ANTLR start "ALT_NOTEQUAL" def mALT_NOTEQUAL(self, ): try: _type = ALT_NOTEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:496:3: ( '<>' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:496:5: '<>' pass self.match("<>") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ALT_NOTEQUAL" # $ANTLR start "LESSEQUAL" def mLESSEQUAL(self, ): try: _type = LESSEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:500:3: ( '<=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:500:5: '<=' pass self.match("<=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LESSEQUAL" # $ANTLR start "LEFTSHIFT" def mLEFTSHIFT(self, ): try: _type = LEFTSHIFT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:504:3: ( '<<' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:504:5: '<<' pass self.match("<<") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LEFTSHIFT" # $ANTLR start "GREATEREQUAL" def mGREATEREQUAL(self, ): try: _type = GREATEREQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:508:3: ( '>=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:508:5: '>=' pass self.match(">=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "GREATEREQUAL" # $ANTLR start "RIGHTSHIFT" def mRIGHTSHIFT(self, ): try: _type = RIGHTSHIFT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:512:3: ( '>>' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:512:5: '>>' pass self.match(">>") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RIGHTSHIFT" # $ANTLR start "PLUSEQUAL" def mPLUSEQUAL(self, ): try: _type = PLUSEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:516:3: ( '+=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:516:5: '+=' pass self.match("+=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUSEQUAL" # $ANTLR start "MINUSEQUAL" def mMINUSEQUAL(self, ): try: _type = MINUSEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:520:3: ( '-=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:520:5: '-=' pass self.match("-=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MINUSEQUAL" # $ANTLR start "DOUBLESTAR" def mDOUBLESTAR(self, ): try: _type = DOUBLESTAR _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:524:3: ( '**' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:524:5: '**' pass self.match("**") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOUBLESTAR" # $ANTLR start "STAREQUAL" def mSTAREQUAL(self, ): try: _type = STAREQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:528:3: ( '*=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:528:5: '*=' pass self.match("*=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STAREQUAL" # $ANTLR start "DOUBLESLASH" def mDOUBLESLASH(self, ): try: _type = DOUBLESLASH _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:532:3: ( '//' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:532:5: '//' pass self.match("//") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOUBLESLASH" # $ANTLR start "SLASHEQUAL" def mSLASHEQUAL(self, ): try: _type = SLASHEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:536:3: ( '/=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:536:5: '/=' pass self.match("/=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SLASHEQUAL" # $ANTLR start "VBAREQUAL" def mVBAREQUAL(self, ): try: _type = VBAREQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:540:3: ( '|=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:540:5: '|=' pass self.match("|=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "VBAREQUAL" # $ANTLR start "PERCENTEQUAL" def mPERCENTEQUAL(self, ): try: _type = PERCENTEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:544:3: ( '%=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:544:5: '%=' pass self.match("%=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PERCENTEQUAL" # $ANTLR start "AMPEREQUAL" def mAMPEREQUAL(self, ): try: _type = AMPEREQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:548:3: ( '&=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:548:5: '&=' pass self.match("&=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AMPEREQUAL" # $ANTLR start "CIRCUMFLEXEQUAL" def mCIRCUMFLEXEQUAL(self, ): try: _type = CIRCUMFLEXEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:552:3: ( '^=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:552:5: '^=' pass self.match("^=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CIRCUMFLEXEQUAL" # $ANTLR start "LEFTSHIFTEQUAL" def mLEFTSHIFTEQUAL(self, ): try: _type = LEFTSHIFTEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:556:3: ( '<<=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:556:5: '<<=' pass self.match("<<=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LEFTSHIFTEQUAL" # $ANTLR start "RIGHTSHIFTEQUAL" def mRIGHTSHIFTEQUAL(self, ): try: _type = RIGHTSHIFTEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:560:3: ( '>>=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:560:5: '>>=' pass self.match(">>=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RIGHTSHIFTEQUAL" # $ANTLR start "DOUBLESTAREQUAL" def mDOUBLESTAREQUAL(self, ): try: _type = DOUBLESTAREQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:564:3: ( '**=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:564:5: '**=' pass self.match("**=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOUBLESTAREQUAL" # $ANTLR start "DOUBLESLASHEQUAL" def mDOUBLESLASHEQUAL(self, ): try: _type = DOUBLESLASHEQUAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:568:3: ( '//=' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:568:5: '//=' pass self.match("//=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOUBLESLASHEQUAL" # $ANTLR start "GLOBAL" def mGLOBAL(self, ): try: _type = GLOBAL _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:572:3: ( 'global' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:572:5: 'global' pass self.match("global") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "GLOBAL" # $ANTLR start "ATTRIBUTE" def mATTRIBUTE(self, ): try: _type = ATTRIBUTE _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:576:3: ( 'attribute' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:576:5: 'attribute' pass self.match("attribute") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ATTRIBUTE" # $ANTLR start "RULE" def mRULE(self, ): try: _type = RULE _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:580:3: ( 'rule' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:580:5: 'rule' pass self.match("rule") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RULE" # $ANTLR start "AGENDAGROUP" def mAGENDAGROUP(self, ): try: _type = AGENDAGROUP _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:584:3: ( 'agenda-group' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:584:5: 'agenda-group' pass self.match("agenda-group") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AGENDAGROUP" # $ANTLR start "WHEN" def mWHEN(self, ): try: _type = WHEN _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:588:3: ( 'when' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:588:5: 'when' pass self.match("when") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WHEN" # $ANTLR start "EXISTS" def mEXISTS(self, ): try: _type = EXISTS _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:592:3: ( 'exists' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:592:5: 'exists' pass self.match("exists") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EXISTS" # $ANTLR start "THEN" def mTHEN(self, ): try: _type = THEN _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:596:3: ( 'then' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:596:5: 'then' pass self.match("then") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "THEN" # $ANTLR start "MODIFY" def mMODIFY(self, ): try: _type = MODIFY _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:600:3: ( 'modify' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:600:5: 'modify' pass self.match("modify") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MODIFY" # $ANTLR start "INSERT" def mINSERT(self, ): try: _type = INSERT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:604:3: ( 'insert' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:604:5: 'insert' pass self.match("insert") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INSERT" # $ANTLR start "LEARN" def mLEARN(self, ): try: _type = LEARN _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:608:3: ( 'learn' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:608:5: 'learn' pass self.match("learn") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LEARN" # $ANTLR start "DELETE" def mDELETE(self, ): try: _type = DELETE _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:612:3: ( 'delete' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:612:5: 'delete' pass self.match("delete") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DELETE" # $ANTLR start "FORGET" def mFORGET(self, ): try: _type = FORGET _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:616:3: ( 'forget' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:616:5: 'forget' pass self.match("forget") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FORGET" # $ANTLR start "HALT" def mHALT(self, ): try: _type = HALT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:620:3: ( 'halt' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:620:5: 'halt' pass self.match("halt") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "HALT" # $ANTLR start "PRINT" def mPRINT(self, ): try: _type = PRINT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:624:3: ( 'print' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:624:5: 'print' pass self.match("print") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PRINT" # $ANTLR start "IMPORT" def mIMPORT(self, ): try: _type = IMPORT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:628:3: ( 'import' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:628:5: 'import' pass self.match("import") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IMPORT" # $ANTLR start "FROM" def mFROM(self, ): try: _type = FROM _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:632:3: ( 'from' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:632:5: 'from' pass self.match("from") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FROM" # $ANTLR start "AND" def mAND(self, ): try: _type = AND _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:636:3: ( 'and' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:636:5: 'and' pass self.match("and") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AND" # $ANTLR start "OR" def mOR(self, ): try: _type = OR _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:640:3: ( 'or' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:640:5: 'or' pass self.match("or") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OR" # $ANTLR start "IN" def mIN(self, ): try: _type = IN _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:644:3: ( 'in' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:644:5: 'in' pass self.match("in") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IN" # $ANTLR start "IS" def mIS(self, ): try: _type = IS _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:648:3: ( 'is' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:648:5: 'is' pass self.match("is") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IS" # $ANTLR start "AS" def mAS(self, ): try: _type = AS _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:652:3: ( 'as' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:652:5: 'as' pass self.match("as") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AS" # $ANTLR start "NOT" def mNOT(self, ): try: _type = NOT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:656:3: ( 'not' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:656:5: 'not' pass self.match("not") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NOT" # $ANTLR start "LETTER" def mLETTER(self, ): try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:661:3: ( ( 'a' .. 'z' | 'A' .. 'Z' ) ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:661:5: ( 'a' .. 'z' | 'A' .. 'Z' ) pass if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "LETTER" # $ANTLR start "DIGIT" def mDIGIT(self, ): try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:666:3: ( ( '0' .. '9' ) ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:666:5: ( '0' .. '9' ) pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:666:5: ( '0' .. '9' ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:666:6: '0' .. '9' pass self.matchRange(48, 57) finally: pass # $ANTLR end "DIGIT" # $ANTLR start "FLOAT" def mFLOAT(self, ): try: _type = FLOAT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:670:3: ( '.' ( DIGIT )+ ( EXPONENT )? | ( DIGIT )+ '.' EXPONENT | ( DIGIT )+ ( '.' ( ( DIGIT )+ ( EXPONENT )? )? | EXPONENT ) ) alt9 = 3 alt9 = self.dfa9.predict(self.input) if alt9 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:670:5: '.' ( DIGIT )+ ( EXPONENT )? pass self.match(46) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:670:9: ( DIGIT )+ cnt1 = 0 while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((48 <= LA1_0 <= 57)) : alt1 = 1 if alt1 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:670:9: DIGIT pass self.mDIGIT() else: if cnt1 >= 1: break #loop1 eee = EarlyExitException(1, self.input) raise eee cnt1 += 1 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:670:16: ( EXPONENT )? alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == 69 or LA2_0 == 101) : alt2 = 1 if alt2 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:670:17: EXPONENT pass self.mEXPONENT() elif alt9 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:671:5: ( DIGIT )+ '.' EXPONENT pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:671:5: ( DIGIT )+ cnt3 = 0 while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if ((48 <= LA3_0 <= 57)) : alt3 = 1 if alt3 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:671:5: DIGIT pass self.mDIGIT() else: if cnt3 >= 1: break #loop3 eee = EarlyExitException(3, self.input) raise eee cnt3 += 1 self.match(46) self.mEXPONENT() elif alt9 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:5: ( DIGIT )+ ( '.' ( ( DIGIT )+ ( EXPONENT )? )? | EXPONENT ) pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:5: ( DIGIT )+ cnt4 = 0 while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if ((48 <= LA4_0 <= 57)) : alt4 = 1 if alt4 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:5: DIGIT pass self.mDIGIT() else: if cnt4 >= 1: break #loop4 eee = EarlyExitException(4, self.input) raise eee cnt4 += 1 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:12: ( '.' ( ( DIGIT )+ ( EXPONENT )? )? | EXPONENT ) alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == 46) : alt8 = 1 elif (LA8_0 == 69 or LA8_0 == 101) : alt8 = 2 else: nvae = NoViableAltException("", 8, 0, self.input) raise nvae if alt8 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:13: '.' ( ( DIGIT )+ ( EXPONENT )? )? pass self.match(46) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:17: ( ( DIGIT )+ ( EXPONENT )? )? alt7 = 2 LA7_0 = self.input.LA(1) if ((48 <= LA7_0 <= 57)) : alt7 = 1 if alt7 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:18: ( DIGIT )+ ( EXPONENT )? pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:18: ( DIGIT )+ cnt5 = 0 while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if ((48 <= LA5_0 <= 57)) : alt5 = 1 if alt5 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:18: DIGIT pass self.mDIGIT() else: if cnt5 >= 1: break #loop5 eee = EarlyExitException(5, self.input) raise eee cnt5 += 1 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:25: ( EXPONENT )? alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == 69 or LA6_0 == 101) : alt6 = 1 if alt6 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:26: EXPONENT pass self.mEXPONENT() elif alt8 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:672:41: EXPONENT pass self.mEXPONENT() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FLOAT" # $ANTLR start "LONGINT" def mLONGINT(self, ): try: _type = LONGINT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:676:3: ( INT ( 'l' | 'L' ) ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:676:5: INT ( 'l' | 'L' ) pass self.mINT() if self.input.LA(1) == 76 or self.input.LA(1) == 108: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LONGINT" # $ANTLR start "EXPONENT" def mEXPONENT(self, ): try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:681:3: ( ( 'e' | 'E' ) ( '+' | '-' )? ( DIGIT )+ ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:681:5: ( 'e' | 'E' ) ( '+' | '-' )? ( DIGIT )+ pass if self.input.LA(1) == 69 or self.input.LA(1) == 101: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:681:17: ( '+' | '-' )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 43 or LA10_0 == 45) : alt10 = 1 if alt10 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g: pass if self.input.LA(1) == 43 or self.input.LA(1) == 45: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:681:32: ( DIGIT )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((48 <= LA11_0 <= 57)) : alt11 = 1 if alt11 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:681:32: DIGIT pass self.mDIGIT() else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 finally: pass # $ANTLR end "EXPONENT" # $ANTLR start "INT" def mINT(self, ): try: _type = INT _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:685:3: ( '0' ( 'x' | 'X' ) ( DIGIT | 'a' .. 'f' | 'A' .. 'F' )+ | '0' ( DIGIT )* | '1' .. '9' ( DIGIT )* ) alt15 = 3 LA15_0 = self.input.LA(1) if (LA15_0 == 48) : LA15_1 = self.input.LA(2) if (LA15_1 == 88 or LA15_1 == 120) : alt15 = 1 else: alt15 = 2 elif ((49 <= LA15_0 <= 57)) : alt15 = 3 else: nvae = NoViableAltException("", 15, 0, self.input) raise nvae if alt15 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:685:5: '0' ( 'x' | 'X' ) ( DIGIT | 'a' .. 'f' | 'A' .. 'F' )+ pass self.match(48) if self.input.LA(1) == 88 or self.input.LA(1) == 120: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:685:21: ( DIGIT | 'a' .. 'f' | 'A' .. 'F' )+ cnt12 = 0 while True: #loop12 alt12 = 4 LA12 = self.input.LA(1) if LA12 == 48 or LA12 == 49 or LA12 == 50 or LA12 == 51 or LA12 == 52 or LA12 == 53 or LA12 == 54 or LA12 == 55 or LA12 == 56 or LA12 == 57: alt12 = 1 elif LA12 == 97 or LA12 == 98 or LA12 == 99 or LA12 == 100 or LA12 == 101 or LA12 == 102: alt12 = 2 elif LA12 == 65 or LA12 == 66 or LA12 == 67 or LA12 == 68 or LA12 == 69 or LA12 == 70: alt12 = 3 if alt12 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:685:23: DIGIT pass self.mDIGIT() elif alt12 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:685:31: 'a' .. 'f' pass self.matchRange(97, 102) elif alt12 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:685:44: 'A' .. 'F' pass self.matchRange(65, 70) else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 elif alt15 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:686:5: '0' ( DIGIT )* pass self.match(48) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:686:9: ( DIGIT )* while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if ((48 <= LA13_0 <= 57)) : alt13 = 1 if alt13 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:686:9: DIGIT pass self.mDIGIT() else: break #loop13 elif alt15 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:687:5: '1' .. '9' ( DIGIT )* pass self.matchRange(49, 57) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:687:14: ( DIGIT )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if ((48 <= LA14_0 <= 57)) : alt14 = 1 if alt14 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:687:14: DIGIT pass self.mDIGIT() else: break #loop14 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INT" # $ANTLR start "COMPLEX" def mCOMPLEX(self, ): try: _type = COMPLEX _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:691:3: ( INT ( 'j' | 'J' ) | FLOAT ( 'j' | 'J' ) ) alt16 = 2 alt16 = self.dfa16.predict(self.input) if alt16 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:691:5: INT ( 'j' | 'J' ) pass self.mINT() if self.input.LA(1) == 74 or self.input.LA(1) == 106: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt16 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:692:5: FLOAT ( 'j' | 'J' ) pass self.mFLOAT() if self.input.LA(1) == 74 or self.input.LA(1) == 106: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMPLEX" # $ANTLR start "NAME" def mNAME(self, ): try: _type = NAME _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:696:3: ( ( LETTER | '_' ) ( LETTER | '_' | DIGIT )* ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:696:5: ( LETTER | '_' ) ( LETTER | '_' | DIGIT )* pass if (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:696:21: ( LETTER | '_' | DIGIT )* while True: #loop17 alt17 = 4 LA17 = self.input.LA(1) if LA17 == 65 or LA17 == 66 or LA17 == 67 or LA17 == 68 or LA17 == 69 or LA17 == 70 or LA17 == 71 or LA17 == 72 or LA17 == 73 or LA17 == 74 or LA17 == 75 or LA17 == 76 or LA17 == 77 or LA17 == 78 or LA17 == 79 or LA17 == 80 or LA17 == 81 or LA17 == 82 or LA17 == 83 or LA17 == 84 or LA17 == 85 or LA17 == 86 or LA17 == 87 or LA17 == 88 or LA17 == 89 or LA17 == 90 or LA17 == 97 or LA17 == 98 or LA17 == 99 or LA17 == 100 or LA17 == 101 or LA17 == 102 or LA17 == 103 or LA17 == 104 or LA17 == 105 or LA17 == 106 or LA17 == 107 or LA17 == 108 or LA17 == 109 or LA17 == 110 or LA17 == 111 or LA17 == 112 or LA17 == 113 or LA17 == 114 or LA17 == 115 or LA17 == 116 or LA17 == 117 or LA17 == 118 or LA17 == 119 or LA17 == 120 or LA17 == 121 or LA17 == 122: alt17 = 1 elif LA17 == 95: alt17 = 2 elif LA17 == 48 or LA17 == 49 or LA17 == 50 or LA17 == 51 or LA17 == 52 or LA17 == 53 or LA17 == 54 or LA17 == 55 or LA17 == 56 or LA17 == 57: alt17 = 3 if alt17 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:696:23: LETTER pass self.mLETTER() elif alt17 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:696:32: '_' pass self.match(95) elif alt17 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:696:38: DIGIT pass self.mDIGIT() else: break #loop17 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NAME" # $ANTLR start "OBJECTBINDING" def mOBJECTBINDING(self, ): try: _type = OBJECTBINDING _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:700:3: ( DOLLAR NAME ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:700:5: DOLLAR NAME pass self.mDOLLAR() self.mNAME() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OBJECTBINDING" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:704:3: ( ( 'r' | 'u' | 'ur' )? ( '\\'\\'\\'' ( options {greedy=false; } : TRIAPOS )* '\\'\\'\\'' | '\"\"\"' ( options {greedy=false; } : TRIQUOTE )* '\"\"\"' | '\"' ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* '\"' | '\\'' ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* '\\'' ) ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:704:5: ( 'r' | 'u' | 'ur' )? ( '\\'\\'\\'' ( options {greedy=false; } : TRIAPOS )* '\\'\\'\\'' | '\"\"\"' ( options {greedy=false; } : TRIQUOTE )* '\"\"\"' | '\"' ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* '\"' | '\\'' ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* '\\'' ) pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:704:5: ( 'r' | 'u' | 'ur' )? alt18 = 4 LA18_0 = self.input.LA(1) if (LA18_0 == 114) : alt18 = 1 elif (LA18_0 == 117) : LA18_2 = self.input.LA(2) if (LA18_2 == 114) : alt18 = 3 elif (LA18_2 == 34 or LA18_2 == 39) : alt18 = 2 if alt18 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:704:6: 'r' pass self.match(114) elif alt18 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:704:10: 'u' pass self.match(117) elif alt18 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:704:14: 'ur' pass self.match("ur") # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:705:5: ( '\\'\\'\\'' ( options {greedy=false; } : TRIAPOS )* '\\'\\'\\'' | '\"\"\"' ( options {greedy=false; } : TRIQUOTE )* '\"\"\"' | '\"' ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* '\"' | '\\'' ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* '\\'' ) alt23 = 4 LA23_0 = self.input.LA(1) if (LA23_0 == 39) : LA23_1 = self.input.LA(2) if (LA23_1 == 39) : LA23_3 = self.input.LA(3) if (LA23_3 == 39) : alt23 = 1 else: alt23 = 4 elif ((0 <= LA23_1 <= 9) or (11 <= LA23_1 <= 38) or (40 <= LA23_1 <= 65535)) : alt23 = 4 else: nvae = NoViableAltException("", 23, 1, self.input) raise nvae elif (LA23_0 == 34) : LA23_2 = self.input.LA(2) if (LA23_2 == 34) : LA23_5 = self.input.LA(3) if (LA23_5 == 34) : alt23 = 2 else: alt23 = 3 elif ((0 <= LA23_2 <= 9) or (11 <= LA23_2 <= 33) or (35 <= LA23_2 <= 65535)) : alt23 = 3 else: nvae = NoViableAltException("", 23, 2, self.input) raise nvae else: nvae = NoViableAltException("", 23, 0, self.input) raise nvae if alt23 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:705:9: '\\'\\'\\'' ( options {greedy=false; } : TRIAPOS )* '\\'\\'\\'' pass self.match("'''") # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:705:18: ( options {greedy=false; } : TRIAPOS )* while True: #loop19 alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == 39) : LA19_1 = self.input.LA(2) if (LA19_1 == 39) : LA19_3 = self.input.LA(3) if (LA19_3 == 39) : alt19 = 2 elif ((0 <= LA19_3 <= 38) or (40 <= LA19_3 <= 65535)) : alt19 = 1 elif ((0 <= LA19_1 <= 38) or (40 <= LA19_1 <= 65535)) : alt19 = 1 elif ((0 <= LA19_0 <= 38) or (40 <= LA19_0 <= 65535)) : alt19 = 1 if alt19 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:705:43: TRIAPOS pass self.mTRIAPOS() else: break #loop19 self.match("'''") elif alt23 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:706:9: '\"\"\"' ( options {greedy=false; } : TRIQUOTE )* '\"\"\"' pass self.match("\"\"\"") # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:706:15: ( options {greedy=false; } : TRIQUOTE )* while True: #loop20 alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == 34) : LA20_1 = self.input.LA(2) if (LA20_1 == 34) : LA20_3 = self.input.LA(3) if (LA20_3 == 34) : alt20 = 2 elif ((0 <= LA20_3 <= 33) or (35 <= LA20_3 <= 65535)) : alt20 = 1 elif ((0 <= LA20_1 <= 33) or (35 <= LA20_1 <= 65535)) : alt20 = 1 elif ((0 <= LA20_0 <= 33) or (35 <= LA20_0 <= 65535)) : alt20 = 1 if alt20 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:706:40: TRIQUOTE pass self.mTRIQUOTE() else: break #loop20 self.match("\"\"\"") elif alt23 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:707:9: '\"' ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* '\"' pass self.match(34) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:707:13: ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* while True: #loop21 alt21 = 3 LA21_0 = self.input.LA(1) if (LA21_0 == 92) : alt21 = 1 elif ((0 <= LA21_0 <= 9) or (11 <= LA21_0 <= 33) or (35 <= LA21_0 <= 91) or (93 <= LA21_0 <= 65535)) : alt21 = 2 if alt21 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:707:14: ESC pass self.mESC() elif alt21 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:707:18: ~ ( '\\\\' | '\\n' | '\"' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop21 self.match(34) elif alt23 == 4: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:708:9: '\\'' ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* '\\'' pass self.match(39) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:708:14: ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* while True: #loop22 alt22 = 3 LA22_0 = self.input.LA(1) if (LA22_0 == 92) : alt22 = 1 elif ((0 <= LA22_0 <= 9) or (11 <= LA22_0 <= 38) or (40 <= LA22_0 <= 91) or (93 <= LA22_0 <= 65535)) : alt22 = 2 if alt22 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:708:15: ESC pass self.mESC() elif alt22 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:708:19: ~ ( '\\\\' | '\\n' | '\\'' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop22 self.match(39) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "TRIQUOTE" def mTRIQUOTE(self, ): try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:2: ( ( '\"' )? ( '\"' )? ( ESC | ~ ( '\\\\' | '\"' ) )+ ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:4: ( '\"' )? ( '\"' )? ( ESC | ~ ( '\\\\' | '\"' ) )+ pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:4: ( '\"' )? alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == 34) : alt24 = 1 if alt24 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:4: '\"' pass self.match(34) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:9: ( '\"' )? alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == 34) : alt25 = 1 if alt25 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:9: '\"' pass self.match(34) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:14: ( ESC | ~ ( '\\\\' | '\"' ) )+ cnt26 = 0 while True: #loop26 alt26 = 3 LA26_0 = self.input.LA(1) if (LA26_0 == 92) : alt26 = 1 elif ((0 <= LA26_0 <= 33) or (35 <= LA26_0 <= 91) or (93 <= LA26_0 <= 65535)) : alt26 = 2 if alt26 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:15: ESC pass self.mESC() elif alt26 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:714:19: ~ ( '\\\\' | '\"' ) pass if (0 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt26 >= 1: break #loop26 eee = EarlyExitException(26, self.input) raise eee cnt26 += 1 finally: pass # $ANTLR end "TRIQUOTE" # $ANTLR start "TRIAPOS" def mTRIAPOS(self, ): try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:3: ( ( '\\'' )? ( '\\'' )? ( ESC | ~ ( '\\\\' | '\\'' ) )+ ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:5: ( '\\'' )? ( '\\'' )? ( ESC | ~ ( '\\\\' | '\\'' ) )+ pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:5: ( '\\'' )? alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == 39) : alt27 = 1 if alt27 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:5: '\\'' pass self.match(39) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:11: ( '\\'' )? alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == 39) : alt28 = 1 if alt28 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:11: '\\'' pass self.match(39) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:17: ( ESC | ~ ( '\\\\' | '\\'' ) )+ cnt29 = 0 while True: #loop29 alt29 = 3 LA29_0 = self.input.LA(1) if (LA29_0 == 92) : alt29 = 1 elif ((0 <= LA29_0 <= 38) or (40 <= LA29_0 <= 91) or (93 <= LA29_0 <= 65535)) : alt29 = 2 if alt29 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:18: ESC pass self.mESC() elif alt29 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:719:22: ~ ( '\\\\' | '\\'' ) pass if (0 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt29 >= 1: break #loop29 eee = EarlyExitException(29, self.input) raise eee cnt29 += 1 finally: pass # $ANTLR end "TRIAPOS" # $ANTLR start "ESC" def mESC(self, ): try: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:724:5: ( '\\\\' . ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:724:10: '\\\\' . pass self.match(92) self.matchAny() finally: pass # $ANTLR end "ESC" # $ANTLR start "CONTINUED_LINE" def mCONTINUED_LINE(self, ): try: _type = CONTINUED_LINE _channel = DEFAULT_CHANNEL newline = None # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:728:3: ( '\\\\' ( '\\r' )? '\\n' ( ' ' | '\\t' )* (newline= NEWLINE | ) ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:728:5: '\\\\' ( '\\r' )? '\\n' ( ' ' | '\\t' )* (newline= NEWLINE | ) pass self.match(92) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:728:10: ( '\\r' )? alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == 13) : alt30 = 1 if alt30 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:728:12: '\\r' pass self.match(13) self.match(10) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:728:25: ( ' ' | '\\t' )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == 9 or LA31_0 == 32) : alt31 = 1 if alt31 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g: pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop31 #action start _channel=HIDDEN #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:729:7: (newline= NEWLINE | ) alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == 10 or (12 <= LA32_0 <= 13)) : alt32 = 1 else: alt32 = 2 if alt32 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:729:9: newline= NEWLINE pass newlineStart1557 = self.getCharIndex() self.mNEWLINE() newline = CommonToken( input=self.input, type=INVALID_TOKEN_TYPE, channel=DEFAULT_CHANNEL, start=newlineStart1557, stop=self.getCharIndex()-1 ) #action start self.emit( ClassicToken( NEWLINE, newline.text ) ) #action end elif alt32 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:731:9: pass self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CONTINUED_LINE" # $ANTLR start "NEWLINE" def mNEWLINE(self, ): try: _type = NEWLINE _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:735:3: ( ( ( '\\u000C' )? ( '\\r' )? '\\n' )+ ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:735:5: ( ( '\\u000C' )? ( '\\r' )? '\\n' )+ pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:735:5: ( ( '\\u000C' )? ( '\\r' )? '\\n' )+ cnt35 = 0 while True: #loop35 alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == 10 or (12 <= LA35_0 <= 13)) : alt35 = 1 if alt35 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:735:7: ( '\\u000C' )? ( '\\r' )? '\\n' pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:735:7: ( '\\u000C' )? alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == 12) : alt33 = 1 if alt33 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:735:9: '\\u000C' pass self.match(12) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:735:21: ( '\\r' )? alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == 13) : alt34 = 1 if alt34 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:735:23: '\\r' pass self.match(13) self.match(10) else: if cnt35 >= 1: break #loop35 eee = EarlyExitException(35, self.input) raise eee cnt35 += 1 #action start if self.startPosition == 0 or self.implicitLineJoiningLevel > 0: _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NEWLINE" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:742:3: ({...}? => ( ' ' | '\\t' )+ ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:742:5: {...}? => ( ' ' | '\\t' )+ pass if not ((self.startPosition > 0 )): raise FailedPredicateException(self.input, "WS", " self.startPosition > 0 ") # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:742:36: ( ' ' | '\\t' )+ cnt36 = 0 while True: #loop36 alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == 9 or LA36_0 == 32) : alt36 = 1 if alt36 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g: pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt36 >= 1: break #loop36 eee = EarlyExitException(36, self.input) raise eee cnt36 += 1 #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "LEADING_WS" def mLEADING_WS(self, ): try: _type = LEADING_WS _channel = DEFAULT_CHANNEL spaces = 0 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:747:3: ({...}? => ({...}? ( ' ' | '\\t' )+ | ( ' ' | '\\t' )+ ( ( '\\r' )? '\\n' )* ) ) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:747:5: {...}? => ({...}? ( ' ' | '\\t' )+ | ( ' ' | '\\t' )+ ( ( '\\r' )? '\\n' )* ) pass if not ((self.startPosition == 0 )): raise FailedPredicateException(self.input, "LEADING_WS", " self.startPosition == 0 ") # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:748:7: ({...}? ( ' ' | '\\t' )+ | ( ' ' | '\\t' )+ ( ( '\\r' )? '\\n' )* ) alt41 = 2 LA41_0 = self.input.LA(1) if (LA41_0 == 32) : LA41_1 = self.input.LA(2) if ((self.implicitLineJoiningLevel > 0)) : alt41 = 1 elif (True) : alt41 = 2 else: nvae = NoViableAltException("", 41, 1, self.input) raise nvae elif (LA41_0 == 9) : LA41_2 = self.input.LA(2) if ((self.implicitLineJoiningLevel > 0)) : alt41 = 1 elif (True) : alt41 = 2 else: nvae = NoViableAltException("", 41, 2, self.input) raise nvae else: nvae = NoViableAltException("", 41, 0, self.input) raise nvae if alt41 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:748:9: {...}? ( ' ' | '\\t' )+ pass if not ((self.implicitLineJoiningLevel > 0)): raise FailedPredicateException(self.input, "LEADING_WS", "self.implicitLineJoiningLevel > 0") # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:748:46: ( ' ' | '\\t' )+ cnt37 = 0 while True: #loop37 alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == 9 or LA37_0 == 32) : alt37 = 1 if alt37 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g: pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt37 >= 1: break #loop37 eee = EarlyExitException(37, self.input) raise eee cnt37 += 1 #action start _channel=HIDDEN #action end elif alt41 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:749:11: ( ' ' | '\\t' )+ ( ( '\\r' )? '\\n' )* pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:749:11: ( ' ' | '\\t' )+ cnt38 = 0 while True: #loop38 alt38 = 3 LA38_0 = self.input.LA(1) if (LA38_0 == 32) : alt38 = 1 elif (LA38_0 == 9) : alt38 = 2 if alt38 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:749:16: ' ' pass self.match(32) #action start spaces += 1 #action end elif alt38 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:750:15: '\\t' pass self.match(9) #action start spaces += 8 spaces -= (spaces % 8) #action end else: if cnt38 >= 1: break #loop38 eee = EarlyExitException(38, self.input) raise eee cnt38 += 1 #action start self.emit(ClassicToken(LEADING_WS, ' '*spaces)) #action end # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:755:16: ( ( '\\r' )? '\\n' )* while True: #loop40 alt40 = 2 LA40_0 = self.input.LA(1) if (LA40_0 == 10 or LA40_0 == 13) : alt40 = 1 if alt40 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:755:18: ( '\\r' )? '\\n' pass # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:755:18: ( '\\r' )? alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == 13) : alt39 = 1 if alt39 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:755:19: '\\r' pass self.match(13) self.match(10) #action start if self._state.token is not None: self._state.token.setChannel(99) else: _channel=HIDDEN #action end else: break #loop40 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LEADING_WS" # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL _channel=HIDDEN # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:767:3: ({...}? => ( ' ' | '\\t' )* '#' (~ '\\n' )* ( '\\n' )+ | {...}? => '#' (~ '\\n' )* ) alt46 = 2 alt46 = self.dfa46.predict(self.input) if alt46 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:767:5: {...}? => ( ' ' | '\\t' )* '#' (~ '\\n' )* ( '\\n' )+ pass if not ((self.startPosition == 0 )): raise FailedPredicateException(self.input, "COMMENT", " self.startPosition == 0 ") # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:767:37: ( ' ' | '\\t' )* while True: #loop42 alt42 = 2 LA42_0 = self.input.LA(1) if (LA42_0 == 9 or LA42_0 == 32) : alt42 = 1 if alt42 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g: pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop42 self.match(35) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:767:53: (~ '\\n' )* while True: #loop43 alt43 = 2 LA43_0 = self.input.LA(1) if ((0 <= LA43_0 <= 9) or (11 <= LA43_0 <= 65535)) : alt43 = 1 if alt43 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:767:54: ~ '\\n' pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop43 # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:767:62: ( '\\n' )+ cnt44 = 0 while True: #loop44 alt44 = 2 LA44_0 = self.input.LA(1) if (LA44_0 == 10) : alt44 = 1 if alt44 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:767:62: '\\n' pass self.match(10) else: if cnt44 >= 1: break #loop44 eee = EarlyExitException(44, self.input) raise eee cnt44 += 1 elif alt46 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:768:7: {...}? => '#' (~ '\\n' )* pass if not ((self.startPosition > 0 )): raise FailedPredicateException(self.input, "COMMENT", " self.startPosition > 0 ") self.match(35) # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:768:42: (~ '\\n' )* while True: #loop45 alt45 = 2 LA45_0 = self.input.LA(1) if ((0 <= LA45_0 <= 9) or (11 <= LA45_0 <= 65535)) : alt45 = 1 if alt45 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:768:43: ~ '\\n' pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop45 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" def mTokens(self): # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:8: ( LPAREN | RPAREN | LBRACK | RBRACK | LCURLY | RCURLY | COLON | COMMA | DOT | SEMI | PLUS | MINUS | STAR | DOLLAR | SLASH | VBAR | AMPER | LESS | GREATER | ASSIGN | PERCENT | BACKQUOTE | CIRCUMFLEX | TILDE | EQUAL | ASSIGNEQUAL | NOTEQUAL | ALT_NOTEQUAL | LESSEQUAL | LEFTSHIFT | GREATEREQUAL | RIGHTSHIFT | PLUSEQUAL | MINUSEQUAL | DOUBLESTAR | STAREQUAL | DOUBLESLASH | SLASHEQUAL | VBAREQUAL | PERCENTEQUAL | AMPEREQUAL | CIRCUMFLEXEQUAL | LEFTSHIFTEQUAL | RIGHTSHIFTEQUAL | DOUBLESTAREQUAL | DOUBLESLASHEQUAL | GLOBAL | ATTRIBUTE | RULE | AGENDAGROUP | WHEN | EXISTS | THEN | MODIFY | INSERT | LEARN | DELETE | FORGET | HALT | PRINT | IMPORT | FROM | AND | OR | IN | IS | AS | NOT | FLOAT | LONGINT | INT | COMPLEX | NAME | OBJECTBINDING | STRING | CONTINUED_LINE | NEWLINE | WS | LEADING_WS | COMMENT ) alt47 = 80 alt47 = self.dfa47.predict(self.input) if alt47 == 1: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:10: LPAREN pass self.mLPAREN() elif alt47 == 2: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:17: RPAREN pass self.mRPAREN() elif alt47 == 3: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:24: LBRACK pass self.mLBRACK() elif alt47 == 4: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:31: RBRACK pass self.mRBRACK() elif alt47 == 5: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:38: LCURLY pass self.mLCURLY() elif alt47 == 6: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:45: RCURLY pass self.mRCURLY() elif alt47 == 7: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:52: COLON pass self.mCOLON() elif alt47 == 8: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:58: COMMA pass self.mCOMMA() elif alt47 == 9: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:64: DOT pass self.mDOT() elif alt47 == 10: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:68: SEMI pass self.mSEMI() elif alt47 == 11: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:73: PLUS pass self.mPLUS() elif alt47 == 12: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:78: MINUS pass self.mMINUS() elif alt47 == 13: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:84: STAR pass self.mSTAR() elif alt47 == 14: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:89: DOLLAR pass self.mDOLLAR() elif alt47 == 15: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:96: SLASH pass self.mSLASH() elif alt47 == 16: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:102: VBAR pass self.mVBAR() elif alt47 == 17: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:107: AMPER pass self.mAMPER() elif alt47 == 18: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:113: LESS pass self.mLESS() elif alt47 == 19: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:118: GREATER pass self.mGREATER() elif alt47 == 20: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:126: ASSIGN pass self.mASSIGN() elif alt47 == 21: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:133: PERCENT pass self.mPERCENT() elif alt47 == 22: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:141: BACKQUOTE pass self.mBACKQUOTE() elif alt47 == 23: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:151: CIRCUMFLEX pass self.mCIRCUMFLEX() elif alt47 == 24: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:162: TILDE pass self.mTILDE() elif alt47 == 25: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:168: EQUAL pass self.mEQUAL() elif alt47 == 26: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:174: ASSIGNEQUAL pass self.mASSIGNEQUAL() elif alt47 == 27: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:186: NOTEQUAL pass self.mNOTEQUAL() elif alt47 == 28: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:195: ALT_NOTEQUAL pass self.mALT_NOTEQUAL() elif alt47 == 29: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:208: LESSEQUAL pass self.mLESSEQUAL() elif alt47 == 30: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:218: LEFTSHIFT pass self.mLEFTSHIFT() elif alt47 == 31: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:228: GREATEREQUAL pass self.mGREATEREQUAL() elif alt47 == 32: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:241: RIGHTSHIFT pass self.mRIGHTSHIFT() elif alt47 == 33: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:252: PLUSEQUAL pass self.mPLUSEQUAL() elif alt47 == 34: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:262: MINUSEQUAL pass self.mMINUSEQUAL() elif alt47 == 35: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:273: DOUBLESTAR pass self.mDOUBLESTAR() elif alt47 == 36: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:284: STAREQUAL pass self.mSTAREQUAL() elif alt47 == 37: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:294: DOUBLESLASH pass self.mDOUBLESLASH() elif alt47 == 38: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:306: SLASHEQUAL pass self.mSLASHEQUAL() elif alt47 == 39: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:317: VBAREQUAL pass self.mVBAREQUAL() elif alt47 == 40: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:327: PERCENTEQUAL pass self.mPERCENTEQUAL() elif alt47 == 41: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:340: AMPEREQUAL pass self.mAMPEREQUAL() elif alt47 == 42: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:351: CIRCUMFLEXEQUAL pass self.mCIRCUMFLEXEQUAL() elif alt47 == 43: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:367: LEFTSHIFTEQUAL pass self.mLEFTSHIFTEQUAL() elif alt47 == 44: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:382: RIGHTSHIFTEQUAL pass self.mRIGHTSHIFTEQUAL() elif alt47 == 45: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:398: DOUBLESTAREQUAL pass self.mDOUBLESTAREQUAL() elif alt47 == 46: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:414: DOUBLESLASHEQUAL pass self.mDOUBLESLASHEQUAL() elif alt47 == 47: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:431: GLOBAL pass self.mGLOBAL() elif alt47 == 48: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:438: ATTRIBUTE pass self.mATTRIBUTE() elif alt47 == 49: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:448: RULE pass self.mRULE() elif alt47 == 50: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:453: AGENDAGROUP pass self.mAGENDAGROUP() elif alt47 == 51: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:465: WHEN pass self.mWHEN() elif alt47 == 52: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:470: EXISTS pass self.mEXISTS() elif alt47 == 53: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:477: THEN pass self.mTHEN() elif alt47 == 54: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:482: MODIFY pass self.mMODIFY() elif alt47 == 55: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:489: INSERT pass self.mINSERT() elif alt47 == 56: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:496: LEARN pass self.mLEARN() elif alt47 == 57: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:502: DELETE pass self.mDELETE() elif alt47 == 58: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:509: FORGET pass self.mFORGET() elif alt47 == 59: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:516: HALT pass self.mHALT() elif alt47 == 60: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:521: PRINT pass self.mPRINT() elif alt47 == 61: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:527: IMPORT pass self.mIMPORT() elif alt47 == 62: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:534: FROM pass self.mFROM() elif alt47 == 63: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:539: AND pass self.mAND() elif alt47 == 64: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:543: OR pass self.mOR() elif alt47 == 65: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:546: IN pass self.mIN() elif alt47 == 66: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:549: IS pass self.mIS() elif alt47 == 67: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:552: AS pass self.mAS() elif alt47 == 68: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:555: NOT pass self.mNOT() elif alt47 == 69: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:559: FLOAT pass self.mFLOAT() elif alt47 == 70: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:565: LONGINT pass self.mLONGINT() elif alt47 == 71: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:573: INT pass self.mINT() elif alt47 == 72: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:577: COMPLEX pass self.mCOMPLEX() elif alt47 == 73: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:585: NAME pass self.mNAME() elif alt47 == 74: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:590: OBJECTBINDING pass self.mOBJECTBINDING() elif alt47 == 75: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:604: STRING pass self.mSTRING() elif alt47 == 76: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:611: CONTINUED_LINE pass self.mCONTINUED_LINE() elif alt47 == 77: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:626: NEWLINE pass self.mNEWLINE() elif alt47 == 78: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:634: WS pass self.mWS() elif alt47 == 79: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:637: LEADING_WS pass self.mLEADING_WS() elif alt47 == 80: # /Users/walsh/Development/workspace/Intellect/intellect/grammar/Policy.g:1:648: COMMENT pass self.mCOMMENT() # lookup tables for DFA #9 DFA9_eot = DFA.unpack( u"\3\uffff\1\4\2\uffff" ) DFA9_eof = DFA.unpack( u"\6\uffff" ) DFA9_min = DFA.unpack( u"\1\56\1\uffff\1\56\1\105\2\uffff" ) DFA9_max = DFA.unpack( u"\1\71\1\uffff\2\145\2\uffff" ) DFA9_accept = DFA.unpack( u"\1\uffff\1\1\2\uffff\1\3\1\2" ) DFA9_special = DFA.unpack( u"\6\uffff" ) DFA9_transition = [ DFA.unpack(u"\1\1\1\uffff\12\2"), DFA.unpack(u""), DFA.unpack(u"\1\3\1\uffff\12\2\13\uffff\1\4\37\uffff\1\4"), DFA.unpack(u"\1\5\37\uffff\1\5"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #9 class DFA9(DFA): pass # lookup tables for DFA #16 DFA16_eot = DFA.unpack( u"\7\uffff" ) DFA16_eof = DFA.unpack( u"\7\uffff" ) DFA16_min = DFA.unpack( u"\3\56\2\uffff\2\56" ) DFA16_max = DFA.unpack( u"\1\71\1\170\1\152\2\uffff\2\152" ) DFA16_accept = DFA.unpack( u"\3\uffff\1\2\1\1\2\uffff" ) DFA16_special = DFA.unpack( u"\7\uffff" ) DFA16_transition = [ DFA.unpack(u"\1\3\1\uffff\1\1\11\2"), DFA.unpack(u"\1\3\1\uffff\12\5\13\uffff\1\3\4\uffff\1\4\15\uffff" u"\1\4\14\uffff\1\3\4\uffff\1\4\15\uffff\1\4"), DFA.unpack(u"\1\3\1\uffff\12\6\13\uffff\1\3\4\uffff\1\4\32\uffff" u"\1\3\4\uffff\1\4"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\3\1\uffff\12\5\13\uffff\1\3\4\uffff\1\4\32\uffff" u"\1\3\4\uffff\1\4"), DFA.unpack(u"\1\3\1\uffff\12\6\13\uffff\1\3\4\uffff\1\4\32\uffff" u"\1\3\4\uffff\1\4") ] # class definition for DFA #16 class DFA16(DFA): pass # lookup tables for DFA #46 DFA46_eot = DFA.unpack( u"\2\uffff\2\4\1\uffff" ) DFA46_eof = DFA.unpack( u"\5\uffff" ) DFA46_min = DFA.unpack( u"\1\11\1\uffff\2\0\1\uffff" ) DFA46_max = DFA.unpack( u"\1\43\1\uffff\2\uffff\1\uffff" ) DFA46_accept = DFA.unpack( u"\1\uffff\1\1\2\uffff\1\2" ) DFA46_special = DFA.unpack( u"\1\2\1\uffff\1\1\1\0\1\uffff" ) DFA46_transition = [ DFA.unpack(u"\1\1\26\uffff\1\1\2\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"\12\3\1\1\ufff5\3"), DFA.unpack(u"\12\3\1\1\ufff5\3"), DFA.unpack(u"") ] # class definition for DFA #46 class DFA46(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA46_3 = input.LA(1) index46_3 = input.index() input.rewind() s = -1 if (LA46_3 == 10) and ((self.startPosition == 0 )): s = 1 elif ((0 <= LA46_3 <= 9) or (11 <= LA46_3 <= 65535)) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 3 else: s = 4 input.seek(index46_3) if s >= 0: return s elif s == 1: LA46_2 = input.LA(1) index46_2 = input.index() input.rewind() s = -1 if ((0 <= LA46_2 <= 9) or (11 <= LA46_2 <= 65535)) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 3 elif (LA46_2 == 10) and ((self.startPosition == 0 )): s = 1 else: s = 4 input.seek(index46_2) if s >= 0: return s elif s == 2: LA46_0 = input.LA(1) index46_0 = input.index() input.rewind() s = -1 if (LA46_0 == 9 or LA46_0 == 32) and ((self.startPosition == 0 )): s = 1 elif (LA46_0 == 35) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 2 input.seek(index46_0) if s >= 0: return s nvae = NoViableAltException(self_.getDescription(), 46, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #47 DFA47_eot = DFA.unpack( u"\7\uffff\1\64\1\uffff\1\66\1\uffff\1\70\1\72\1\75\1\76\1\102\1" u"\104\1\106\1\112\1\115\1\117\1\121\1\uffff\1\123\2\uffff\17\54" u"\2\152\1\54\4\uffff\1\163\1\165\3\uffff\1\166\5\uffff\1\171\4\uffff" u"\1\173\10\uffff\1\175\2\uffff\1\177\7\uffff\4\54\1\u0084\5\54\1" u"\u008b\1\54\1\u008d\6\54\1\u0094\1\54\2\uffff\1\166\1\152\3\uffff" u"\1\152\1\54\16\uffff\3\54\1\u00a3\1\uffff\6\54\1\uffff\1\54\1\uffff" u"\6\54\1\uffff\1\u00b1\3\152\1\166\2\uffff\1\166\2\uffff\1\166\3" u"\54\1\uffff\1\u00b8\1\u00b9\1\54\1\u00bb\6\54\1\u00c2\1\u00c3\1" u"\54\3\uffff\1\166\3\54\2\uffff\1\54\1\uffff\3\54\1\u00ce\2\54\2" u"\uffff\1\u00d1\1\uffff\1\166\1\u00d2\2\54\1\u00d5\1\u00d6\1\u00d7" u"\1\u00d8\1\uffff\1\u00d9\1\u00da\2\uffff\1\54\7\uffff\1\54\1\u00dd" u"\1\uffff" ) DFA47_eof = DFA.unpack( u"\u00de\uffff" ) DFA47_min = DFA.unpack( u"\1\11\6\uffff\1\75\1\uffff\1\60\1\uffff\2\75\1\52\1\101\1\57\2" u"\75\1\74\3\75\1\uffff\1\75\2\uffff\1\154\1\147\1\42\1\150\1\170" u"\1\150\1\157\1\155\2\145\1\157\1\141\2\162\1\157\2\56\1\42\4\uffff" u"\2\11\3\uffff\1\60\5\uffff\1\75\4\uffff\1\75\10\uffff\1\75\2\uffff" u"\1\75\7\uffff\1\157\1\164\1\145\1\144\1\60\1\154\1\145\1\151\1" u"\145\1\144\1\60\1\160\1\60\1\141\1\154\1\162\1\157\1\154\1\151" u"\1\60\1\164\1\60\1\uffff\1\60\1\56\1\uffff\1\53\1\uffff\1\56\1" u"\42\1\uffff\1\0\1\uffff\1\0\1\uffff\1\53\10\uffff\1\142\1\162\1" u"\156\1\60\1\uffff\1\145\1\156\1\163\1\156\1\151\1\145\1\uffff\1" u"\157\1\uffff\1\162\1\145\1\147\1\155\1\164\1\156\1\uffff\5\60\1" u"\53\2\60\1\uffff\2\60\1\141\1\151\1\144\1\uffff\2\60\1\164\1\60" u"\1\146\2\162\1\156\1\164\1\145\2\60\1\164\1\uffff\1\53\2\60\1\154" u"\1\142\1\141\2\uffff\1\163\1\uffff\1\171\2\164\1\60\1\145\1\164" u"\2\uffff\4\60\1\165\1\55\4\60\1\uffff\2\60\2\uffff\1\164\7\uffff" u"\1\145\1\60\1\uffff" ) DFA47_max = DFA.unpack( u"\1\176\6\uffff\1\75\1\uffff\1\71\1\uffff\3\75\1\172\3\75\2\76\2" u"\75\1\uffff\1\75\2\uffff\1\154\1\164\1\165\1\150\1\170\1\150\1" u"\157\1\163\2\145\1\162\1\141\2\162\1\157\1\170\1\154\1\162\4\uffff" u"\2\43\3\uffff\1\152\5\uffff\1\75\4\uffff\1\75\10\uffff\1\75\2\uffff" u"\1\75\7\uffff\1\157\1\164\1\145\1\144\1\172\1\154\1\145\1\151\1" u"\145\1\144\1\172\1\160\1\172\1\141\1\154\1\162\1\157\1\154\1\151" u"\1\172\1\164\1\146\1\uffff\1\152\1\154\1\uffff\1\71\1\uffff\1\154" u"\1\47\1\uffff\1\0\1\uffff\1\0\1\uffff\1\71\10\uffff\1\142\1\162" u"\1\156\1\172\1\uffff\1\145\1\156\1\163\1\156\1\151\1\145\1\uffff" u"\1\157\1\uffff\1\162\1\145\1\147\1\155\1\164\1\156\1\uffff\1\172" u"\3\154\1\152\2\71\1\152\1\uffff\1\71\1\152\1\141\1\151\1\144\1" u"\uffff\2\172\1\164\1\172\1\146\2\162\1\156\1\164\1\145\2\172\1" u"\164\1\uffff\2\71\1\152\1\154\1\142\1\141\2\uffff\1\163\1\uffff" u"\1\171\2\164\1\172\1\145\1\164\2\uffff\1\172\1\71\1\152\1\172\1" u"\165\1\55\4\172\1\uffff\2\172\2\uffff\1\164\7\uffff\1\145\1\172" u"\1\uffff" ) DFA47_accept = DFA.unpack( u"\1\uffff\1\1\1\2\1\3\1\4\1\5\1\6\1\uffff\1\10\1\uffff\1\12\13\uffff" u"\1\26\1\uffff\1\30\1\33\22\uffff\1\111\1\113\1\114\1\115\2\uffff" u"\1\120\1\32\1\7\1\uffff\1\11\1\41\1\13\1\42\1\14\1\uffff\1\44\1" u"\15\1\16\1\112\1\uffff\1\46\1\17\1\47\1\20\1\51\1\21\1\34\1\35" u"\1\uffff\1\22\1\37\1\uffff\1\23\1\31\1\24\1\50\1\25\1\52\1\27\26" u"\uffff\1\107\2\uffff\1\106\1\uffff\1\110\2\uffff\1\120\1\uffff" u"\1\117\1\uffff\1\105\1\uffff\1\55\1\43\1\56\1\45\1\53\1\36\1\54" u"\1\40\4\uffff\1\103\6\uffff\1\101\1\uffff\1\102\6\uffff\1\100\10" u"\uffff\1\116\5\uffff\1\77\15\uffff\1\104\6\uffff\1\61\1\63\1\uffff" u"\1\65\6\uffff\1\76\1\73\12\uffff\1\70\2\uffff\1\74\1\57\1\uffff" u"\1\62\1\64\1\66\1\67\1\75\1\71\1\72\2\uffff\1\60" ) DFA47_special = DFA.unpack( u"\1\2\57\uffff\1\0\1\1\101\uffff\1\3\1\uffff\1\4\150\uffff" ) DFA47_transition = [ DFA.unpack(u"\1\61\1\57\1\uffff\2\57\22\uffff\1\60\1\31\1\55\1\62" u"\1\16\1\25\1\21\1\55\1\1\1\2\1\15\1\13\1\10\1\14\1\11\1\17\1\51" u"\11\52\1\7\1\12\1\22\1\24\1\23\2\uffff\32\54\1\3\1\56\1\4\1\27" u"\1\54\1\26\1\33\2\54\1\43\1\36\1\44\1\32\1\45\1\41\2\54\1\42\1" u"\40\1\50\1\47\1\46\1\54\1\34\1\54\1\37\1\53\1\54\1\35\3\54\1\5" u"\1\20\1\6\1\30"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\63"), DFA.unpack(u""), DFA.unpack(u"\12\65"), DFA.unpack(u""), DFA.unpack(u"\1\67"), DFA.unpack(u"\1\71"), DFA.unpack(u"\1\73\22\uffff\1\74"), DFA.unpack(u"\32\77\4\uffff\1\77\1\uffff\32\77"), DFA.unpack(u"\1\100\15\uffff\1\101"), DFA.unpack(u"\1\103"), DFA.unpack(u"\1\105"), DFA.unpack(u"\1\111\1\110\1\107"), DFA.unpack(u"\1\113\1\114"), DFA.unpack(u"\1\116"), DFA.unpack(u"\1\120"), DFA.unpack(u""), DFA.unpack(u"\1\122"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\124"), DFA.unpack(u"\1\126\6\uffff\1\127\4\uffff\1\130\1\125"), DFA.unpack(u"\1\55\4\uffff\1\55\115\uffff\1\131"), DFA.unpack(u"\1\132"), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134"), DFA.unpack(u"\1\135"), DFA.unpack(u"\1\137\1\136\4\uffff\1\140"), DFA.unpack(u"\1\141"), DFA.unpack(u"\1\142"), DFA.unpack(u"\1\143\2\uffff\1\144"), DFA.unpack(u"\1\145"), DFA.unpack(u"\1\146"), DFA.unpack(u"\1\147"), DFA.unpack(u"\1\150"), DFA.unpack(u"\1\153\1\uffff\12\154\13\uffff\1\156\4\uffff\1\157" u"\1\uffff\1\155\13\uffff\1\151\14\uffff\1\156\4\uffff\1\157\1\uffff" u"\1\155\13\uffff\1\151"), DFA.unpack(u"\1\153\1\uffff\12\160\13\uffff\1\156\4\uffff\1\157" u"\1\uffff\1\155\30\uffff\1\156\4\uffff\1\157\1\uffff\1\155"), DFA.unpack(u"\1\55\4\uffff\1\55\112\uffff\1\161"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\61\1\164\2\uffff\1\164\22\uffff\1\60\2\uffff\1\162"), DFA.unpack(u"\1\61\1\164\2\uffff\1\164\22\uffff\1\60\2\uffff\1\162"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\65\13\uffff\1\167\4\uffff\1\157\32\uffff\1\167" u"\4\uffff\1\157"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\170"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\172"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\174"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\176"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0080"), DFA.unpack(u"\1\u0081"), DFA.unpack(u"\1\u0082"), DFA.unpack(u"\1\u0083"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\1\u0085"), DFA.unpack(u"\1\u0086"), DFA.unpack(u"\1\u0087"), DFA.unpack(u"\1\u0088"), DFA.unpack(u"\1\u0089"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\22\54\1\u008a" u"\7\54"), DFA.unpack(u"\1\u008c"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\1\u008e"), DFA.unpack(u"\1\u008f"), DFA.unpack(u"\1\u0090"), DFA.unpack(u"\1\u0091"), DFA.unpack(u"\1\u0092"), DFA.unpack(u"\1\u0093"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\1\u0095"), DFA.unpack(u"\12\u0096\7\uffff\6\u0098\32\uffff\6\u0097"), DFA.unpack(u""), DFA.unpack(u"\12\u0099\13\uffff\1\u009a\4\uffff\1\157\32\uffff\1" u"\u009a\4\uffff\1\157"), DFA.unpack(u"\1\153\1\uffff\12\154\13\uffff\1\156\4\uffff\1\157" u"\1\uffff\1\155\30\uffff\1\156\4\uffff\1\157\1\uffff\1\155"), DFA.unpack(u""), DFA.unpack(u"\1\u009b\1\uffff\1\u009b\2\uffff\12\u009c"), DFA.unpack(u""), DFA.unpack(u"\1\153\1\uffff\12\160\13\uffff\1\156\4\uffff\1\157" u"\1\uffff\1\155\30\uffff\1\156\4\uffff\1\157\1\uffff\1\155"), DFA.unpack(u"\1\55\4\uffff\1\55"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"\1\u009e\1\uffff\1\u009e\2\uffff\12\u009f"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00a0"), DFA.unpack(u"\1\u00a1"), DFA.unpack(u"\1\u00a2"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u""), DFA.unpack(u"\1\u00a4"), DFA.unpack(u"\1\u00a5"), DFA.unpack(u"\1\u00a6"), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\1\u00a8"), DFA.unpack(u"\1\u00a9"), DFA.unpack(u""), DFA.unpack(u"\1\u00aa"), DFA.unpack(u""), DFA.unpack(u"\1\u00ab"), DFA.unpack(u"\1\u00ac"), DFA.unpack(u"\1\u00ad"), DFA.unpack(u"\1\u00ae"), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\1\u00b0"), DFA.unpack(u""), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\12\u0096\7\uffff\6\u0098\3\uffff\1\157\1\uffff\1\155" u"\24\uffff\6\u0097\3\uffff\1\157\1\uffff\1\155"), DFA.unpack(u"\12\u0096\7\uffff\6\u0098\3\uffff\1\157\1\uffff\1\155" u"\24\uffff\6\u0097\3\uffff\1\157\1\uffff\1\155"), DFA.unpack(u"\12\u0096\7\uffff\6\u0098\3\uffff\1\157\1\uffff\1\155" u"\24\uffff\6\u0097\3\uffff\1\157\1\uffff\1\155"), DFA.unpack(u"\12\u0099\13\uffff\1\u00b2\4\uffff\1\157\32\uffff\1" u"\u00b2\4\uffff\1\157"), DFA.unpack(u"\1\u00b3\1\uffff\1\u00b3\2\uffff\12\u00b4"), DFA.unpack(u"\12\u009c"), DFA.unpack(u"\12\u009c\20\uffff\1\157\37\uffff\1\157"), DFA.unpack(u""), DFA.unpack(u"\12\u009f"), DFA.unpack(u"\12\u009f\20\uffff\1\157\37\uffff\1\157"), DFA.unpack(u"\1\u00b5"), DFA.unpack(u"\1\u00b6"), DFA.unpack(u"\1\u00b7"), DFA.unpack(u""), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\1\u00bd"), DFA.unpack(u"\1\u00be"), DFA.unpack(u"\1\u00bf"), DFA.unpack(u"\1\u00c0"), DFA.unpack(u"\1\u00c1"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\1\u00c4"), DFA.unpack(u""), DFA.unpack(u"\1\u00c5\1\uffff\1\u00c5\2\uffff\12\u00c6"), DFA.unpack(u"\12\u00b4"), DFA.unpack(u"\12\u00b4\20\uffff\1\157\37\uffff\1\157"), DFA.unpack(u"\1\u00c7"), DFA.unpack(u"\1\u00c8"), DFA.unpack(u"\1\u00c9"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ca"), DFA.unpack(u""), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\1\u00cc"), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\1\u00cf"), DFA.unpack(u"\1\u00d0"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\12\u00c6"), DFA.unpack(u"\12\u00c6\20\uffff\1\157\37\uffff\1\157"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\1\u00d3"), DFA.unpack(u"\1\u00d4"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u""), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00db"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00dc"), DFA.unpack(u"\12\54\7\uffff\32\54\4\uffff\1\54\1\uffff\32\54"), DFA.unpack(u"") ] # class definition for DFA #47 class DFA47(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA47_48 = input.LA(1) index47_48 = input.index() input.rewind() s = -1 if (LA47_48 == 35) and ((self.startPosition == 0 )): s = 114 elif (LA47_48 == 32) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 48 elif (LA47_48 == 10 or LA47_48 == 13) and ((self.startPosition == 0 )): s = 116 elif (LA47_48 == 9) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 49 else: s = 115 input.seek(index47_48) if s >= 0: return s elif s == 1: LA47_49 = input.LA(1) index47_49 = input.index() input.rewind() s = -1 if (LA47_49 == 35) and ((self.startPosition == 0 )): s = 114 elif (LA47_49 == 32) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 48 elif (LA47_49 == 10 or LA47_49 == 13) and ((self.startPosition == 0 )): s = 116 elif (LA47_49 == 9) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 49 else: s = 117 input.seek(index47_49) if s >= 0: return s elif s == 2: LA47_0 = input.LA(1) index47_0 = input.index() input.rewind() s = -1 if (LA47_0 == 40): s = 1 elif (LA47_0 == 41): s = 2 elif (LA47_0 == 91): s = 3 elif (LA47_0 == 93): s = 4 elif (LA47_0 == 123): s = 5 elif (LA47_0 == 125): s = 6 elif (LA47_0 == 58): s = 7 elif (LA47_0 == 44): s = 8 elif (LA47_0 == 46): s = 9 elif (LA47_0 == 59): s = 10 elif (LA47_0 == 43): s = 11 elif (LA47_0 == 45): s = 12 elif (LA47_0 == 42): s = 13 elif (LA47_0 == 36): s = 14 elif (LA47_0 == 47): s = 15 elif (LA47_0 == 124): s = 16 elif (LA47_0 == 38): s = 17 elif (LA47_0 == 60): s = 18 elif (LA47_0 == 62): s = 19 elif (LA47_0 == 61): s = 20 elif (LA47_0 == 37): s = 21 elif (LA47_0 == 96): s = 22 elif (LA47_0 == 94): s = 23 elif (LA47_0 == 126): s = 24 elif (LA47_0 == 33): s = 25 elif (LA47_0 == 103): s = 26 elif (LA47_0 == 97): s = 27 elif (LA47_0 == 114): s = 28 elif (LA47_0 == 119): s = 29 elif (LA47_0 == 101): s = 30 elif (LA47_0 == 116): s = 31 elif (LA47_0 == 109): s = 32 elif (LA47_0 == 105): s = 33 elif (LA47_0 == 108): s = 34 elif (LA47_0 == 100): s = 35 elif (LA47_0 == 102): s = 36 elif (LA47_0 == 104): s = 37 elif (LA47_0 == 112): s = 38 elif (LA47_0 == 111): s = 39 elif (LA47_0 == 110): s = 40 elif (LA47_0 == 48): s = 41 elif ((49 <= LA47_0 <= 57)): s = 42 elif (LA47_0 == 117): s = 43 elif ((65 <= LA47_0 <= 90) or LA47_0 == 95 or (98 <= LA47_0 <= 99) or (106 <= LA47_0 <= 107) or LA47_0 == 113 or LA47_0 == 115 or LA47_0 == 118 or (120 <= LA47_0 <= 122)): s = 44 elif (LA47_0 == 34 or LA47_0 == 39): s = 45 elif (LA47_0 == 92): s = 46 elif (LA47_0 == 10 or (12 <= LA47_0 <= 13)): s = 47 elif (LA47_0 == 32) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 48 elif (LA47_0 == 9) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 49 elif (LA47_0 == 35) and (((self.startPosition > 0 ) or (self.startPosition == 0 ))): s = 50 input.seek(index47_0) if s >= 0: return s elif s == 3: LA47_115 = input.LA(1) index47_115 = input.index() input.rewind() s = -1 if ((self.startPosition > 0 )): s = 157 elif (((self.startPosition == 0 ) or (((self.startPosition == 0 )) and ((self.implicitLineJoiningLevel > 0))))): s = 116 input.seek(index47_115) if s >= 0: return s elif s == 4: LA47_117 = input.LA(1) index47_117 = input.index() input.rewind() s = -1 if ((self.startPosition > 0 )): s = 157 elif (((self.startPosition == 0 ) or (((self.startPosition == 0 )) and ((self.implicitLineJoiningLevel > 0))))): s = 116 input.seek(index47_117) if s >= 0: return s nvae = NoViableAltException(self_.getDescription(), 47, _s, input) self_.error(nvae) raise nvae def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(PolicyLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "nemonik/Intellect", "path": "intellect/grammar/PolicyLexer.py", "copies": "2", "size": "135998", "license": "bsd-3-clause", "hash": 3362097317030140400, "line_mean": 27.3388205876, "line_max": 894, "alpha_frac": 0.4777055545, "autogenerated": false, "ratio": 3.4754542434387057, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.49531597979387054, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 JavaScript.g 2009-04-05 22:38:00 import sys from antlr3 import * from antlr3.compat import set, frozenset from antlr3.tree import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types LT=4 DecimalDigit=17 EOF=-1 Identifier=5 SingleStringCharacter=9 T__93=93 T__94=94 T__91=91 T__92=92 T__90=90 Comment=28 SingleEscapeCharacter=14 UnicodeLetter=24 ExponentPart=21 WhiteSpace=30 T__99=99 T__98=98 T__97=97 T__96=96 UnicodeCombiningMark=27 T__95=95 UnicodeDigit=25 T__80=80 T__81=81 NumericLiteral=7 T__82=82 T__83=83 IdentifierStart=22 DoubleStringCharacter=8 T__85=85 T__84=84 T__87=87 T__86=86 T__89=89 T__88=88 T__71=71 T__72=72 T__70=70 CharacterEscapeSequence=11 T__76=76 T__75=75 T__74=74 T__73=73 EscapeSequence=10 T__79=79 UnicodeConnectorPunctuation=26 T__78=78 T__77=77 T__68=68 T__69=69 T__66=66 T__67=67 T__64=64 T__65=65 T__62=62 T__63=63 HexEscapeSequence=12 LineComment=29 T__61=61 T__60=60 HexDigit=18 T__55=55 T__56=56 T__57=57 T__58=58 T__51=51 T__52=52 T__53=53 T__54=54 T__59=59 T__103=103 T__104=104 T__105=105 T__106=106 EscapeCharacter=16 T__50=50 IdentifierPart=23 T__42=42 T__43=43 T__40=40 T__41=41 T__46=46 T__47=47 T__44=44 T__45=45 T__48=48 T__49=49 UnicodeEscapeSequence=13 T__102=102 T__101=101 T__100=100 DecimalLiteral=19 StringLiteral=6 T__31=31 T__32=32 T__33=33 T__34=34 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 HexIntegerLiteral=20 NonEscapeCharacter=15 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "LT", "Identifier", "StringLiteral", "NumericLiteral", "DoubleStringCharacter", "SingleStringCharacter", "EscapeSequence", "CharacterEscapeSequence", "HexEscapeSequence", "UnicodeEscapeSequence", "SingleEscapeCharacter", "NonEscapeCharacter", "EscapeCharacter", "DecimalDigit", "HexDigit", "DecimalLiteral", "HexIntegerLiteral", "ExponentPart", "IdentifierStart", "IdentifierPart", "UnicodeLetter", "UnicodeDigit", "UnicodeConnectorPunctuation", "UnicodeCombiningMark", "Comment", "LineComment", "WhiteSpace", "'function'", "'('", "','", "')'", "'{'", "'}'", "'var'", "';'", "'='", "'if'", "'else'", "'do'", "'while'", "'for'", "'in'", "'continue'", "'break'", "'return'", "'with'", "':'", "'switch'", "'case'", "'default'", "'throw'", "'try'", "'catch'", "'finally'", "'new'", "'['", "']'", "'.'", "'*='", "'/='", "'%='", "'+='", "'-='", "'<<='", "'>>='", "'>>>='", "'&='", "'^='", "'|='", "'?'", "'||'", "'&&'", "'|'", "'^'", "'&'", "'=='", "'!='", "'==='", "'!=='", "'<'", "'>'", "'<='", "'>='", "'instanceof'", "'<<'", "'>>'", "'>>>'", "'+'", "'-'", "'*'", "'/'", "'%'", "'delete'", "'void'", "'typeof'", "'++'", "'--'", "'~'", "'!'", "'this'", "'null'", "'true'", "'false'" ] class JavaScriptParser(Parser): grammarFileName = "JavaScript.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(JavaScriptParser, self).__init__(input, state, *args, **kwargs) self._state.ruleMemo = {} self.dfa4 = self.DFA4( self, 4, eot = self.DFA4_eot, eof = self.DFA4_eof, min = self.DFA4_min, max = self.DFA4_max, accept = self.DFA4_accept, special = self.DFA4_special, transition = self.DFA4_transition ) self.dfa5 = self.DFA5( self, 5, eot = self.DFA5_eot, eof = self.DFA5_eof, min = self.DFA5_min, max = self.DFA5_max, accept = self.DFA5_accept, special = self.DFA5_special, transition = self.DFA5_transition ) self.dfa17 = self.DFA17( self, 17, eot = self.DFA17_eot, eof = self.DFA17_eof, min = self.DFA17_min, max = self.DFA17_max, accept = self.DFA17_accept, special = self.DFA17_special, transition = self.DFA17_transition ) self.dfa16 = self.DFA16( self, 16, eot = self.DFA16_eot, eof = self.DFA16_eof, min = self.DFA16_min, max = self.DFA16_max, accept = self.DFA16_accept, special = self.DFA16_special, transition = self.DFA16_transition ) self.dfa21 = self.DFA21( self, 21, eot = self.DFA21_eot, eof = self.DFA21_eof, min = self.DFA21_min, max = self.DFA21_max, accept = self.DFA21_accept, special = self.DFA21_special, transition = self.DFA21_transition ) self.dfa26 = self.DFA26( self, 26, eot = self.DFA26_eot, eof = self.DFA26_eof, min = self.DFA26_min, max = self.DFA26_max, accept = self.DFA26_accept, special = self.DFA26_special, transition = self.DFA26_transition ) self.dfa30 = self.DFA30( self, 30, eot = self.DFA30_eot, eof = self.DFA30_eof, min = self.DFA30_min, max = self.DFA30_max, accept = self.DFA30_accept, special = self.DFA30_special, transition = self.DFA30_transition ) self.dfa33 = self.DFA33( self, 33, eot = self.DFA33_eot, eof = self.DFA33_eof, min = self.DFA33_min, max = self.DFA33_max, accept = self.DFA33_accept, special = self.DFA33_special, transition = self.DFA33_transition ) self.dfa57 = self.DFA57( self, 57, eot = self.DFA57_eot, eof = self.DFA57_eof, min = self.DFA57_min, max = self.DFA57_max, accept = self.DFA57_accept, special = self.DFA57_special, transition = self.DFA57_transition ) self.dfa60 = self.DFA60( self, 60, eot = self.DFA60_eot, eof = self.DFA60_eof, min = self.DFA60_min, max = self.DFA60_max, accept = self.DFA60_accept, special = self.DFA60_special, transition = self.DFA60_transition ) self.dfa63 = self.DFA63( self, 63, eot = self.DFA63_eot, eof = self.DFA63_eof, min = self.DFA63_min, max = self.DFA63_max, accept = self.DFA63_accept, special = self.DFA63_special, transition = self.DFA63_transition ) self.dfa90 = self.DFA90( self, 90, eot = self.DFA90_eot, eof = self.DFA90_eof, min = self.DFA90_min, max = self.DFA90_max, accept = self.DFA90_accept, special = self.DFA90_special, transition = self.DFA90_transition ) self.dfa94 = self.DFA94( self, 94, eot = self.DFA94_eot, eof = self.DFA94_eof, min = self.DFA94_min, max = self.DFA94_max, accept = self.DFA94_accept, special = self.DFA94_special, transition = self.DFA94_transition ) self.dfa93 = self.DFA93( self, 93, eot = self.DFA93_eot, eof = self.DFA93_eof, min = self.DFA93_min, max = self.DFA93_max, accept = self.DFA93_accept, special = self.DFA93_special, transition = self.DFA93_transition ) self.dfa106 = self.DFA106( self, 106, eot = self.DFA106_eot, eof = self.DFA106_eof, min = self.DFA106_min, max = self.DFA106_max, accept = self.DFA106_accept, special = self.DFA106_special, transition = self.DFA106_transition ) self.dfa115 = self.DFA115( self, 115, eot = self.DFA115_eot, eof = self.DFA115_eof, min = self.DFA115_min, max = self.DFA115_max, accept = self.DFA115_accept, special = self.DFA115_special, transition = self.DFA115_transition ) self.dfa118 = self.DFA118( self, 118, eot = self.DFA118_eot, eof = self.DFA118_eof, min = self.DFA118_min, max = self.DFA118_max, accept = self.DFA118_accept, special = self.DFA118_special, transition = self.DFA118_transition ) self.dfa121 = self.DFA121( self, 121, eot = self.DFA121_eot, eof = self.DFA121_eof, min = self.DFA121_min, max = self.DFA121_max, accept = self.DFA121_accept, special = self.DFA121_special, transition = self.DFA121_transition ) self.dfa124 = self.DFA124( self, 124, eot = self.DFA124_eot, eof = self.DFA124_eof, min = self.DFA124_min, max = self.DFA124_max, accept = self.DFA124_accept, special = self.DFA124_special, transition = self.DFA124_transition ) self.dfa125 = self.DFA125( self, 125, eot = self.DFA125_eot, eof = self.DFA125_eof, min = self.DFA125_min, max = self.DFA125_max, accept = self.DFA125_accept, special = self.DFA125_special, transition = self.DFA125_transition ) self.dfa127 = self.DFA127( self, 127, eot = self.DFA127_eot, eof = self.DFA127_eof, min = self.DFA127_min, max = self.DFA127_max, accept = self.DFA127_accept, special = self.DFA127_special, transition = self.DFA127_transition ) self.dfa132 = self.DFA132( self, 132, eot = self.DFA132_eot, eof = self.DFA132_eof, min = self.DFA132_min, max = self.DFA132_max, accept = self.DFA132_accept, special = self.DFA132_special, transition = self.DFA132_transition ) self.dfa136 = self.DFA136( self, 136, eot = self.DFA136_eot, eof = self.DFA136_eof, min = self.DFA136_min, max = self.DFA136_max, accept = self.DFA136_accept, special = self.DFA136_special, transition = self.DFA136_transition ) self.dfa142 = self.DFA142( self, 142, eot = self.DFA142_eot, eof = self.DFA142_eof, min = self.DFA142_min, max = self.DFA142_max, accept = self.DFA142_accept, special = self.DFA142_special, transition = self.DFA142_transition ) self.dfa141 = self.DFA141( self, 141, eot = self.DFA141_eot, eof = self.DFA141_eof, min = self.DFA141_min, max = self.DFA141_max, accept = self.DFA141_accept, special = self.DFA141_special, transition = self.DFA141_transition ) self.dfa151 = self.DFA151( self, 151, eot = self.DFA151_eot, eof = self.DFA151_eof, min = self.DFA151_min, max = self.DFA151_max, accept = self.DFA151_accept, special = self.DFA151_special, transition = self.DFA151_transition ) self.dfa156 = self.DFA156( self, 156, eot = self.DFA156_eot, eof = self.DFA156_eof, min = self.DFA156_min, max = self.DFA156_max, accept = self.DFA156_accept, special = self.DFA156_special, transition = self.DFA156_transition ) self.dfa159 = self.DFA159( self, 159, eot = self.DFA159_eot, eof = self.DFA159_eof, min = self.DFA159_min, max = self.DFA159_max, accept = self.DFA159_accept, special = self.DFA159_special, transition = self.DFA159_transition ) self.dfa162 = self.DFA162( self, 162, eot = self.DFA162_eot, eof = self.DFA162_eof, min = self.DFA162_min, max = self.DFA162_max, accept = self.DFA162_accept, special = self.DFA162_special, transition = self.DFA162_transition ) self.dfa165 = self.DFA165( self, 165, eot = self.DFA165_eot, eof = self.DFA165_eof, min = self.DFA165_min, max = self.DFA165_max, accept = self.DFA165_accept, special = self.DFA165_special, transition = self.DFA165_transition ) self.dfa168 = self.DFA168( self, 168, eot = self.DFA168_eot, eof = self.DFA168_eof, min = self.DFA168_min, max = self.DFA168_max, accept = self.DFA168_accept, special = self.DFA168_special, transition = self.DFA168_transition ) self.dfa171 = self.DFA171( self, 171, eot = self.DFA171_eot, eof = self.DFA171_eof, min = self.DFA171_min, max = self.DFA171_max, accept = self.DFA171_accept, special = self.DFA171_special, transition = self.DFA171_transition ) self.dfa174 = self.DFA174( self, 174, eot = self.DFA174_eot, eof = self.DFA174_eof, min = self.DFA174_min, max = self.DFA174_max, accept = self.DFA174_accept, special = self.DFA174_special, transition = self.DFA174_transition ) self.dfa177 = self.DFA177( self, 177, eot = self.DFA177_eot, eof = self.DFA177_eof, min = self.DFA177_min, max = self.DFA177_max, accept = self.DFA177_accept, special = self.DFA177_special, transition = self.DFA177_transition ) self.dfa180 = self.DFA180( self, 180, eot = self.DFA180_eot, eof = self.DFA180_eof, min = self.DFA180_min, max = self.DFA180_max, accept = self.DFA180_accept, special = self.DFA180_special, transition = self.DFA180_transition ) self.dfa183 = self.DFA183( self, 183, eot = self.DFA183_eot, eof = self.DFA183_eof, min = self.DFA183_min, max = self.DFA183_max, accept = self.DFA183_accept, special = self.DFA183_special, transition = self.DFA183_transition ) self.dfa186 = self.DFA186( self, 186, eot = self.DFA186_eot, eof = self.DFA186_eof, min = self.DFA186_min, max = self.DFA186_max, accept = self.DFA186_accept, special = self.DFA186_special, transition = self.DFA186_transition ) self.dfa189 = self.DFA189( self, 189, eot = self.DFA189_eot, eof = self.DFA189_eof, min = self.DFA189_min, max = self.DFA189_max, accept = self.DFA189_accept, special = self.DFA189_special, transition = self.DFA189_transition ) self.dfa192 = self.DFA192( self, 192, eot = self.DFA192_eot, eof = self.DFA192_eof, min = self.DFA192_min, max = self.DFA192_max, accept = self.DFA192_accept, special = self.DFA192_special, transition = self.DFA192_transition ) self.dfa195 = self.DFA195( self, 195, eot = self.DFA195_eot, eof = self.DFA195_eof, min = self.DFA195_min, max = self.DFA195_max, accept = self.DFA195_accept, special = self.DFA195_special, transition = self.DFA195_transition ) self.dfa198 = self.DFA198( self, 198, eot = self.DFA198_eot, eof = self.DFA198_eof, min = self.DFA198_min, max = self.DFA198_max, accept = self.DFA198_accept, special = self.DFA198_special, transition = self.DFA198_transition ) self.dfa201 = self.DFA201( self, 201, eot = self.DFA201_eot, eof = self.DFA201_eof, min = self.DFA201_min, max = self.DFA201_max, accept = self.DFA201_accept, special = self.DFA201_special, transition = self.DFA201_transition ) self.dfa204 = self.DFA204( self, 204, eot = self.DFA204_eot, eof = self.DFA204_eof, min = self.DFA204_min, max = self.DFA204_max, accept = self.DFA204_accept, special = self.DFA204_special, transition = self.DFA204_transition ) self.dfa207 = self.DFA207( self, 207, eot = self.DFA207_eot, eof = self.DFA207_eof, min = self.DFA207_min, max = self.DFA207_max, accept = self.DFA207_accept, special = self.DFA207_special, transition = self.DFA207_transition ) self.dfa218 = self.DFA218( self, 218, eot = self.DFA218_eot, eof = self.DFA218_eof, min = self.DFA218_min, max = self.DFA218_max, accept = self.DFA218_accept, special = self.DFA218_special, transition = self.DFA218_transition ) self.dfa217 = self.DFA217( self, 217, eot = self.DFA217_eot, eof = self.DFA217_eof, min = self.DFA217_min, max = self.DFA217_max, accept = self.DFA217_accept, special = self.DFA217_special, transition = self.DFA217_transition ) self.dfa223 = self.DFA223( self, 223, eot = self.DFA223_eot, eof = self.DFA223_eof, min = self.DFA223_min, max = self.DFA223_max, accept = self.DFA223_accept, special = self.DFA223_special, transition = self.DFA223_transition ) self._adaptor = None self.adaptor = CommonTreeAdaptor() def getTreeAdaptor(self): return self._adaptor def setTreeAdaptor(self, adaptor): self._adaptor = adaptor adaptor = property(getTreeAdaptor, setTreeAdaptor) class program_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.program_return, self).__init__() self.tree = None # $ANTLR start "program" # JavaScript.g:23:1: program : ( LT )* sourceElements ( LT )* EOF ; def program(self, ): retval = self.program_return() retval.start = self.input.LT(1) program_StartIndex = self.input.index() root_0 = None LT1 = None LT3 = None EOF4 = None sourceElements2 = None LT1_tree = None LT3_tree = None EOF4_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 1): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:24:2: ( ( LT )* sourceElements ( LT )* EOF ) # JavaScript.g:24:4: ( LT )* sourceElements ( LT )* EOF pass root_0 = self._adaptor.nil() # JavaScript.g:24:6: ( LT )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == LT) : alt1 = 1 if alt1 == 1: # JavaScript.g:0:0: LT pass LT1=self.match(self.input, LT, self.FOLLOW_LT_in_program46) else: break #loop1 self._state.following.append(self.FOLLOW_sourceElements_in_program50) sourceElements2 = self.sourceElements() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, sourceElements2.tree) # JavaScript.g:24:26: ( LT )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == LT) : alt2 = 1 if alt2 == 1: # JavaScript.g:0:0: LT pass LT3=self.match(self.input, LT, self.FOLLOW_LT_in_program52) else: break #loop2 EOF4=self.match(self.input, EOF, self.FOLLOW_EOF_in_program56) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 1, program_StartIndex, success) pass return retval # $ANTLR end "program" class sourceElements_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.sourceElements_return, self).__init__() self.tree = None # $ANTLR start "sourceElements" # JavaScript.g:27:1: sourceElements : sourceElement ( ( LT )* sourceElement )* ; def sourceElements(self, ): retval = self.sourceElements_return() retval.start = self.input.LT(1) sourceElements_StartIndex = self.input.index() root_0 = None LT6 = None sourceElement5 = None sourceElement7 = None LT6_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 2): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:28:2: ( sourceElement ( ( LT )* sourceElement )* ) # JavaScript.g:28:4: sourceElement ( ( LT )* sourceElement )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_sourceElement_in_sourceElements69) sourceElement5 = self.sourceElement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, sourceElement5.tree) # JavaScript.g:28:18: ( ( LT )* sourceElement )* while True: #loop4 alt4 = 2 alt4 = self.dfa4.predict(self.input) if alt4 == 1: # JavaScript.g:28:19: ( LT )* sourceElement pass # JavaScript.g:28:21: ( LT )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == LT) : alt3 = 1 if alt3 == 1: # JavaScript.g:0:0: LT pass LT6=self.match(self.input, LT, self.FOLLOW_LT_in_sourceElements72) else: break #loop3 self._state.following.append(self.FOLLOW_sourceElement_in_sourceElements76) sourceElement7 = self.sourceElement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, sourceElement7.tree) else: break #loop4 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 2, sourceElements_StartIndex, success) pass return retval # $ANTLR end "sourceElements" class sourceElement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.sourceElement_return, self).__init__() self.tree = None # $ANTLR start "sourceElement" # JavaScript.g:31:1: sourceElement : ( functionDeclaration | statement ); def sourceElement(self, ): retval = self.sourceElement_return() retval.start = self.input.LT(1) sourceElement_StartIndex = self.input.index() root_0 = None functionDeclaration8 = None statement9 = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 3): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:32:2: ( functionDeclaration | statement ) alt5 = 2 alt5 = self.dfa5.predict(self.input) if alt5 == 1: # JavaScript.g:32:4: functionDeclaration pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_functionDeclaration_in_sourceElement90) functionDeclaration8 = self.functionDeclaration() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, functionDeclaration8.tree) elif alt5 == 2: # JavaScript.g:33:4: statement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_statement_in_sourceElement95) statement9 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement9.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 3, sourceElement_StartIndex, success) pass return retval # $ANTLR end "sourceElement" class functionDeclaration_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.functionDeclaration_return, self).__init__() self.tree = None # $ANTLR start "functionDeclaration" # JavaScript.g:37:1: functionDeclaration : 'function' ( LT )* Identifier ( LT )* formalParameterList ( LT )* functionBody ; def functionDeclaration(self, ): retval = self.functionDeclaration_return() retval.start = self.input.LT(1) functionDeclaration_StartIndex = self.input.index() root_0 = None string_literal10 = None LT11 = None Identifier12 = None LT13 = None LT15 = None formalParameterList14 = None functionBody16 = None string_literal10_tree = None LT11_tree = None Identifier12_tree = None LT13_tree = None LT15_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 4): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:38:2: ( 'function' ( LT )* Identifier ( LT )* formalParameterList ( LT )* functionBody ) # JavaScript.g:38:4: 'function' ( LT )* Identifier ( LT )* formalParameterList ( LT )* functionBody pass root_0 = self._adaptor.nil() string_literal10=self.match(self.input, 31, self.FOLLOW_31_in_functionDeclaration108) if self._state.backtracking == 0: string_literal10_tree = self._adaptor.createWithPayload(string_literal10) self._adaptor.addChild(root_0, string_literal10_tree) # JavaScript.g:38:17: ( LT )* while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == LT) : alt6 = 1 if alt6 == 1: # JavaScript.g:0:0: LT pass LT11=self.match(self.input, LT, self.FOLLOW_LT_in_functionDeclaration110) else: break #loop6 Identifier12=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_functionDeclaration114) if self._state.backtracking == 0: Identifier12_tree = self._adaptor.createWithPayload(Identifier12) self._adaptor.addChild(root_0, Identifier12_tree) # JavaScript.g:38:33: ( LT )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == LT) : alt7 = 1 if alt7 == 1: # JavaScript.g:0:0: LT pass LT13=self.match(self.input, LT, self.FOLLOW_LT_in_functionDeclaration116) else: break #loop7 self._state.following.append(self.FOLLOW_formalParameterList_in_functionDeclaration120) formalParameterList14 = self.formalParameterList() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, formalParameterList14.tree) # JavaScript.g:38:58: ( LT )* while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == LT) : alt8 = 1 if alt8 == 1: # JavaScript.g:0:0: LT pass LT15=self.match(self.input, LT, self.FOLLOW_LT_in_functionDeclaration122) else: break #loop8 self._state.following.append(self.FOLLOW_functionBody_in_functionDeclaration126) functionBody16 = self.functionBody() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, functionBody16.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 4, functionDeclaration_StartIndex, success) pass return retval # $ANTLR end "functionDeclaration" class functionExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.functionExpression_return, self).__init__() self.tree = None # $ANTLR start "functionExpression" # JavaScript.g:41:1: functionExpression : 'function' ( LT )* ( Identifier )? ( LT )* formalParameterList ( LT )* functionBody ; def functionExpression(self, ): retval = self.functionExpression_return() retval.start = self.input.LT(1) functionExpression_StartIndex = self.input.index() root_0 = None string_literal17 = None LT18 = None Identifier19 = None LT20 = None LT22 = None formalParameterList21 = None functionBody23 = None string_literal17_tree = None LT18_tree = None Identifier19_tree = None LT20_tree = None LT22_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 5): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:42:2: ( 'function' ( LT )* ( Identifier )? ( LT )* formalParameterList ( LT )* functionBody ) # JavaScript.g:42:4: 'function' ( LT )* ( Identifier )? ( LT )* formalParameterList ( LT )* functionBody pass root_0 = self._adaptor.nil() string_literal17=self.match(self.input, 31, self.FOLLOW_31_in_functionExpression138) if self._state.backtracking == 0: string_literal17_tree = self._adaptor.createWithPayload(string_literal17) self._adaptor.addChild(root_0, string_literal17_tree) # JavaScript.g:42:17: ( LT )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == LT) : LA9_2 = self.input.LA(2) if (self.synpred9_JavaScript()) : alt9 = 1 if alt9 == 1: # JavaScript.g:0:0: LT pass LT18=self.match(self.input, LT, self.FOLLOW_LT_in_functionExpression140) else: break #loop9 # JavaScript.g:42:20: ( Identifier )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == Identifier) : alt10 = 1 if alt10 == 1: # JavaScript.g:0:0: Identifier pass Identifier19=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_functionExpression144) if self._state.backtracking == 0: Identifier19_tree = self._adaptor.createWithPayload(Identifier19) self._adaptor.addChild(root_0, Identifier19_tree) # JavaScript.g:42:34: ( LT )* while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == LT) : alt11 = 1 if alt11 == 1: # JavaScript.g:0:0: LT pass LT20=self.match(self.input, LT, self.FOLLOW_LT_in_functionExpression147) else: break #loop11 self._state.following.append(self.FOLLOW_formalParameterList_in_functionExpression151) formalParameterList21 = self.formalParameterList() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, formalParameterList21.tree) # JavaScript.g:42:59: ( LT )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == LT) : alt12 = 1 if alt12 == 1: # JavaScript.g:0:0: LT pass LT22=self.match(self.input, LT, self.FOLLOW_LT_in_functionExpression153) else: break #loop12 self._state.following.append(self.FOLLOW_functionBody_in_functionExpression157) functionBody23 = self.functionBody() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, functionBody23.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 5, functionExpression_StartIndex, success) pass return retval # $ANTLR end "functionExpression" class formalParameterList_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.formalParameterList_return, self).__init__() self.tree = None # $ANTLR start "formalParameterList" # JavaScript.g:45:1: formalParameterList : '(' ( ( LT )* Identifier ( ( LT )* ',' ( LT )* Identifier )* )? ( LT )* ')' ; def formalParameterList(self, ): retval = self.formalParameterList_return() retval.start = self.input.LT(1) formalParameterList_StartIndex = self.input.index() root_0 = None char_literal24 = None LT25 = None Identifier26 = None LT27 = None char_literal28 = None LT29 = None Identifier30 = None LT31 = None char_literal32 = None char_literal24_tree = None LT25_tree = None Identifier26_tree = None LT27_tree = None char_literal28_tree = None LT29_tree = None Identifier30_tree = None LT31_tree = None char_literal32_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 6): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:46:2: ( '(' ( ( LT )* Identifier ( ( LT )* ',' ( LT )* Identifier )* )? ( LT )* ')' ) # JavaScript.g:46:4: '(' ( ( LT )* Identifier ( ( LT )* ',' ( LT )* Identifier )* )? ( LT )* ')' pass root_0 = self._adaptor.nil() char_literal24=self.match(self.input, 32, self.FOLLOW_32_in_formalParameterList169) if self._state.backtracking == 0: char_literal24_tree = self._adaptor.createWithPayload(char_literal24) self._adaptor.addChild(root_0, char_literal24_tree) # JavaScript.g:46:8: ( ( LT )* Identifier ( ( LT )* ',' ( LT )* Identifier )* )? alt17 = 2 alt17 = self.dfa17.predict(self.input) if alt17 == 1: # JavaScript.g:46:9: ( LT )* Identifier ( ( LT )* ',' ( LT )* Identifier )* pass # JavaScript.g:46:11: ( LT )* while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == LT) : alt13 = 1 if alt13 == 1: # JavaScript.g:0:0: LT pass LT25=self.match(self.input, LT, self.FOLLOW_LT_in_formalParameterList172) else: break #loop13 Identifier26=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_formalParameterList176) if self._state.backtracking == 0: Identifier26_tree = self._adaptor.createWithPayload(Identifier26) self._adaptor.addChild(root_0, Identifier26_tree) # JavaScript.g:46:25: ( ( LT )* ',' ( LT )* Identifier )* while True: #loop16 alt16 = 2 alt16 = self.dfa16.predict(self.input) if alt16 == 1: # JavaScript.g:46:26: ( LT )* ',' ( LT )* Identifier pass # JavaScript.g:46:28: ( LT )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == LT) : alt14 = 1 if alt14 == 1: # JavaScript.g:0:0: LT pass LT27=self.match(self.input, LT, self.FOLLOW_LT_in_formalParameterList179) else: break #loop14 char_literal28=self.match(self.input, 33, self.FOLLOW_33_in_formalParameterList183) if self._state.backtracking == 0: char_literal28_tree = self._adaptor.createWithPayload(char_literal28) self._adaptor.addChild(root_0, char_literal28_tree) # JavaScript.g:46:37: ( LT )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == LT) : alt15 = 1 if alt15 == 1: # JavaScript.g:0:0: LT pass LT29=self.match(self.input, LT, self.FOLLOW_LT_in_formalParameterList185) else: break #loop15 Identifier30=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_formalParameterList189) if self._state.backtracking == 0: Identifier30_tree = self._adaptor.createWithPayload(Identifier30) self._adaptor.addChild(root_0, Identifier30_tree) else: break #loop16 # JavaScript.g:46:57: ( LT )* while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == LT) : alt18 = 1 if alt18 == 1: # JavaScript.g:0:0: LT pass LT31=self.match(self.input, LT, self.FOLLOW_LT_in_formalParameterList195) else: break #loop18 char_literal32=self.match(self.input, 34, self.FOLLOW_34_in_formalParameterList199) if self._state.backtracking == 0: char_literal32_tree = self._adaptor.createWithPayload(char_literal32) self._adaptor.addChild(root_0, char_literal32_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 6, formalParameterList_StartIndex, success) pass return retval # $ANTLR end "formalParameterList" class functionBody_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.functionBody_return, self).__init__() self.tree = None # $ANTLR start "functionBody" # JavaScript.g:49:1: functionBody : '{' ( LT )* sourceElements ( LT )* '}' ; def functionBody(self, ): retval = self.functionBody_return() retval.start = self.input.LT(1) functionBody_StartIndex = self.input.index() root_0 = None char_literal33 = None LT34 = None LT36 = None char_literal37 = None sourceElements35 = None char_literal33_tree = None LT34_tree = None LT36_tree = None char_literal37_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 7): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:50:2: ( '{' ( LT )* sourceElements ( LT )* '}' ) # JavaScript.g:50:4: '{' ( LT )* sourceElements ( LT )* '}' pass root_0 = self._adaptor.nil() char_literal33=self.match(self.input, 35, self.FOLLOW_35_in_functionBody210) if self._state.backtracking == 0: char_literal33_tree = self._adaptor.createWithPayload(char_literal33) self._adaptor.addChild(root_0, char_literal33_tree) # JavaScript.g:50:10: ( LT )* while True: #loop19 alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == LT) : alt19 = 1 if alt19 == 1: # JavaScript.g:0:0: LT pass LT34=self.match(self.input, LT, self.FOLLOW_LT_in_functionBody212) else: break #loop19 self._state.following.append(self.FOLLOW_sourceElements_in_functionBody216) sourceElements35 = self.sourceElements() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, sourceElements35.tree) # JavaScript.g:50:30: ( LT )* while True: #loop20 alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == LT) : alt20 = 1 if alt20 == 1: # JavaScript.g:0:0: LT pass LT36=self.match(self.input, LT, self.FOLLOW_LT_in_functionBody218) else: break #loop20 char_literal37=self.match(self.input, 36, self.FOLLOW_36_in_functionBody222) if self._state.backtracking == 0: char_literal37_tree = self._adaptor.createWithPayload(char_literal37) self._adaptor.addChild(root_0, char_literal37_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 7, functionBody_StartIndex, success) pass return retval # $ANTLR end "functionBody" class statement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.statement_return, self).__init__() self.tree = None # $ANTLR start "statement" # JavaScript.g:54:1: statement : ( statementBlock | variableStatement | emptyStatement | expressionStatement | ifStatement | iterationStatement | continueStatement | breakStatement | returnStatement | withStatement | labelledStatement | switchStatement | throwStatement | tryStatement ); def statement(self, ): retval = self.statement_return() retval.start = self.input.LT(1) statement_StartIndex = self.input.index() root_0 = None statementBlock38 = None variableStatement39 = None emptyStatement40 = None expressionStatement41 = None ifStatement42 = None iterationStatement43 = None continueStatement44 = None breakStatement45 = None returnStatement46 = None withStatement47 = None labelledStatement48 = None switchStatement49 = None throwStatement50 = None tryStatement51 = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 8): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:55:2: ( statementBlock | variableStatement | emptyStatement | expressionStatement | ifStatement | iterationStatement | continueStatement | breakStatement | returnStatement | withStatement | labelledStatement | switchStatement | throwStatement | tryStatement ) alt21 = 14 alt21 = self.dfa21.predict(self.input) if alt21 == 1: # JavaScript.g:55:4: statementBlock pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_statementBlock_in_statement234) statementBlock38 = self.statementBlock() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statementBlock38.tree) elif alt21 == 2: # JavaScript.g:56:4: variableStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_variableStatement_in_statement239) variableStatement39 = self.variableStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, variableStatement39.tree) elif alt21 == 3: # JavaScript.g:57:4: emptyStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_emptyStatement_in_statement244) emptyStatement40 = self.emptyStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, emptyStatement40.tree) elif alt21 == 4: # JavaScript.g:58:4: expressionStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_expressionStatement_in_statement249) expressionStatement41 = self.expressionStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expressionStatement41.tree) elif alt21 == 5: # JavaScript.g:59:4: ifStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_ifStatement_in_statement254) ifStatement42 = self.ifStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, ifStatement42.tree) elif alt21 == 6: # JavaScript.g:60:4: iterationStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_iterationStatement_in_statement259) iterationStatement43 = self.iterationStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, iterationStatement43.tree) elif alt21 == 7: # JavaScript.g:61:4: continueStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_continueStatement_in_statement264) continueStatement44 = self.continueStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, continueStatement44.tree) elif alt21 == 8: # JavaScript.g:62:4: breakStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_breakStatement_in_statement269) breakStatement45 = self.breakStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, breakStatement45.tree) elif alt21 == 9: # JavaScript.g:63:4: returnStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_returnStatement_in_statement274) returnStatement46 = self.returnStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, returnStatement46.tree) elif alt21 == 10: # JavaScript.g:64:4: withStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_withStatement_in_statement279) withStatement47 = self.withStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, withStatement47.tree) elif alt21 == 11: # JavaScript.g:65:4: labelledStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_labelledStatement_in_statement284) labelledStatement48 = self.labelledStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, labelledStatement48.tree) elif alt21 == 12: # JavaScript.g:66:4: switchStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_switchStatement_in_statement289) switchStatement49 = self.switchStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, switchStatement49.tree) elif alt21 == 13: # JavaScript.g:67:4: throwStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_throwStatement_in_statement294) throwStatement50 = self.throwStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, throwStatement50.tree) elif alt21 == 14: # JavaScript.g:68:4: tryStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_tryStatement_in_statement299) tryStatement51 = self.tryStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, tryStatement51.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 8, statement_StartIndex, success) pass return retval # $ANTLR end "statement" class statementBlock_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.statementBlock_return, self).__init__() self.tree = None # $ANTLR start "statementBlock" # JavaScript.g:71:1: statementBlock : '{' ( LT )* ( statementList )? ( LT )* '}' ; def statementBlock(self, ): retval = self.statementBlock_return() retval.start = self.input.LT(1) statementBlock_StartIndex = self.input.index() root_0 = None char_literal52 = None LT53 = None LT55 = None char_literal56 = None statementList54 = None char_literal52_tree = None LT53_tree = None LT55_tree = None char_literal56_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 9): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:72:2: ( '{' ( LT )* ( statementList )? ( LT )* '}' ) # JavaScript.g:72:4: '{' ( LT )* ( statementList )? ( LT )* '}' pass root_0 = self._adaptor.nil() char_literal52=self.match(self.input, 35, self.FOLLOW_35_in_statementBlock311) if self._state.backtracking == 0: char_literal52_tree = self._adaptor.createWithPayload(char_literal52) self._adaptor.addChild(root_0, char_literal52_tree) # JavaScript.g:72:10: ( LT )* while True: #loop22 alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == LT) : LA22_2 = self.input.LA(2) if (self.synpred34_JavaScript()) : alt22 = 1 if alt22 == 1: # JavaScript.g:0:0: LT pass LT53=self.match(self.input, LT, self.FOLLOW_LT_in_statementBlock313) else: break #loop22 # JavaScript.g:72:13: ( statementList )? alt23 = 2 LA23_0 = self.input.LA(1) if ((Identifier <= LA23_0 <= NumericLiteral) or (31 <= LA23_0 <= 32) or LA23_0 == 35 or (37 <= LA23_0 <= 38) or LA23_0 == 40 or (42 <= LA23_0 <= 44) or (46 <= LA23_0 <= 49) or LA23_0 == 51 or (54 <= LA23_0 <= 55) or (58 <= LA23_0 <= 59) or (91 <= LA23_0 <= 92) or (96 <= LA23_0 <= 106)) : alt23 = 1 if alt23 == 1: # JavaScript.g:0:0: statementList pass self._state.following.append(self.FOLLOW_statementList_in_statementBlock317) statementList54 = self.statementList() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statementList54.tree) # JavaScript.g:72:30: ( LT )* while True: #loop24 alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == LT) : alt24 = 1 if alt24 == 1: # JavaScript.g:0:0: LT pass LT55=self.match(self.input, LT, self.FOLLOW_LT_in_statementBlock320) else: break #loop24 char_literal56=self.match(self.input, 36, self.FOLLOW_36_in_statementBlock324) if self._state.backtracking == 0: char_literal56_tree = self._adaptor.createWithPayload(char_literal56) self._adaptor.addChild(root_0, char_literal56_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 9, statementBlock_StartIndex, success) pass return retval # $ANTLR end "statementBlock" class statementList_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.statementList_return, self).__init__() self.tree = None # $ANTLR start "statementList" # JavaScript.g:75:1: statementList : statement ( ( LT )* statement )* ; def statementList(self, ): retval = self.statementList_return() retval.start = self.input.LT(1) statementList_StartIndex = self.input.index() root_0 = None LT58 = None statement57 = None statement59 = None LT58_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 10): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:76:2: ( statement ( ( LT )* statement )* ) # JavaScript.g:76:4: statement ( ( LT )* statement )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_statement_in_statementList336) statement57 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement57.tree) # JavaScript.g:76:14: ( ( LT )* statement )* while True: #loop26 alt26 = 2 alt26 = self.dfa26.predict(self.input) if alt26 == 1: # JavaScript.g:76:15: ( LT )* statement pass # JavaScript.g:76:17: ( LT )* while True: #loop25 alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == LT) : alt25 = 1 if alt25 == 1: # JavaScript.g:0:0: LT pass LT58=self.match(self.input, LT, self.FOLLOW_LT_in_statementList339) else: break #loop25 self._state.following.append(self.FOLLOW_statement_in_statementList343) statement59 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement59.tree) else: break #loop26 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 10, statementList_StartIndex, success) pass return retval # $ANTLR end "statementList" class variableStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.variableStatement_return, self).__init__() self.tree = None # $ANTLR start "variableStatement" # JavaScript.g:79:1: variableStatement : 'var' ( LT )* variableDeclarationList ( LT | ';' ) ; def variableStatement(self, ): retval = self.variableStatement_return() retval.start = self.input.LT(1) variableStatement_StartIndex = self.input.index() root_0 = None string_literal60 = None LT61 = None set63 = None variableDeclarationList62 = None string_literal60_tree = None LT61_tree = None set63_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 11): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:80:2: ( 'var' ( LT )* variableDeclarationList ( LT | ';' ) ) # JavaScript.g:80:4: 'var' ( LT )* variableDeclarationList ( LT | ';' ) pass root_0 = self._adaptor.nil() string_literal60=self.match(self.input, 37, self.FOLLOW_37_in_variableStatement357) if self._state.backtracking == 0: string_literal60_tree = self._adaptor.createWithPayload(string_literal60) self._adaptor.addChild(root_0, string_literal60_tree) # JavaScript.g:80:12: ( LT )* while True: #loop27 alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == LT) : alt27 = 1 if alt27 == 1: # JavaScript.g:0:0: LT pass LT61=self.match(self.input, LT, self.FOLLOW_LT_in_variableStatement359) else: break #loop27 self._state.following.append(self.FOLLOW_variableDeclarationList_in_variableStatement363) variableDeclarationList62 = self.variableDeclarationList() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, variableDeclarationList62.tree) set63 = self.input.LT(1) if self.input.LA(1) == LT or self.input.LA(1) == 38: self.input.consume() self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 11, variableStatement_StartIndex, success) pass return retval # $ANTLR end "variableStatement" class variableDeclarationList_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.variableDeclarationList_return, self).__init__() self.tree = None # $ANTLR start "variableDeclarationList" # JavaScript.g:83:1: variableDeclarationList : variableDeclaration ( ( LT )* ',' ( LT )* variableDeclaration )* ; def variableDeclarationList(self, ): retval = self.variableDeclarationList_return() retval.start = self.input.LT(1) variableDeclarationList_StartIndex = self.input.index() root_0 = None LT65 = None char_literal66 = None LT67 = None variableDeclaration64 = None variableDeclaration68 = None LT65_tree = None char_literal66_tree = None LT67_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 12): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:84:2: ( variableDeclaration ( ( LT )* ',' ( LT )* variableDeclaration )* ) # JavaScript.g:84:4: variableDeclaration ( ( LT )* ',' ( LT )* variableDeclaration )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_variableDeclaration_in_variableDeclarationList384) variableDeclaration64 = self.variableDeclaration() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, variableDeclaration64.tree) # JavaScript.g:84:24: ( ( LT )* ',' ( LT )* variableDeclaration )* while True: #loop30 alt30 = 2 alt30 = self.dfa30.predict(self.input) if alt30 == 1: # JavaScript.g:84:25: ( LT )* ',' ( LT )* variableDeclaration pass # JavaScript.g:84:27: ( LT )* while True: #loop28 alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == LT) : alt28 = 1 if alt28 == 1: # JavaScript.g:0:0: LT pass LT65=self.match(self.input, LT, self.FOLLOW_LT_in_variableDeclarationList387) else: break #loop28 char_literal66=self.match(self.input, 33, self.FOLLOW_33_in_variableDeclarationList391) if self._state.backtracking == 0: char_literal66_tree = self._adaptor.createWithPayload(char_literal66) self._adaptor.addChild(root_0, char_literal66_tree) # JavaScript.g:84:36: ( LT )* while True: #loop29 alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == LT) : alt29 = 1 if alt29 == 1: # JavaScript.g:0:0: LT pass LT67=self.match(self.input, LT, self.FOLLOW_LT_in_variableDeclarationList393) else: break #loop29 self._state.following.append(self.FOLLOW_variableDeclaration_in_variableDeclarationList397) variableDeclaration68 = self.variableDeclaration() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, variableDeclaration68.tree) else: break #loop30 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 12, variableDeclarationList_StartIndex, success) pass return retval # $ANTLR end "variableDeclarationList" class variableDeclarationListNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.variableDeclarationListNoIn_return, self).__init__() self.tree = None # $ANTLR start "variableDeclarationListNoIn" # JavaScript.g:87:1: variableDeclarationListNoIn : variableDeclarationNoIn ( ( LT )* ',' ( LT )* variableDeclarationNoIn )* ; def variableDeclarationListNoIn(self, ): retval = self.variableDeclarationListNoIn_return() retval.start = self.input.LT(1) variableDeclarationListNoIn_StartIndex = self.input.index() root_0 = None LT70 = None char_literal71 = None LT72 = None variableDeclarationNoIn69 = None variableDeclarationNoIn73 = None LT70_tree = None char_literal71_tree = None LT72_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 13): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:88:2: ( variableDeclarationNoIn ( ( LT )* ',' ( LT )* variableDeclarationNoIn )* ) # JavaScript.g:88:4: variableDeclarationNoIn ( ( LT )* ',' ( LT )* variableDeclarationNoIn )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_variableDeclarationNoIn_in_variableDeclarationListNoIn411) variableDeclarationNoIn69 = self.variableDeclarationNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, variableDeclarationNoIn69.tree) # JavaScript.g:88:28: ( ( LT )* ',' ( LT )* variableDeclarationNoIn )* while True: #loop33 alt33 = 2 alt33 = self.dfa33.predict(self.input) if alt33 == 1: # JavaScript.g:88:29: ( LT )* ',' ( LT )* variableDeclarationNoIn pass # JavaScript.g:88:31: ( LT )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == LT) : alt31 = 1 if alt31 == 1: # JavaScript.g:0:0: LT pass LT70=self.match(self.input, LT, self.FOLLOW_LT_in_variableDeclarationListNoIn414) else: break #loop31 char_literal71=self.match(self.input, 33, self.FOLLOW_33_in_variableDeclarationListNoIn418) if self._state.backtracking == 0: char_literal71_tree = self._adaptor.createWithPayload(char_literal71) self._adaptor.addChild(root_0, char_literal71_tree) # JavaScript.g:88:40: ( LT )* while True: #loop32 alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == LT) : alt32 = 1 if alt32 == 1: # JavaScript.g:0:0: LT pass LT72=self.match(self.input, LT, self.FOLLOW_LT_in_variableDeclarationListNoIn420) else: break #loop32 self._state.following.append(self.FOLLOW_variableDeclarationNoIn_in_variableDeclarationListNoIn424) variableDeclarationNoIn73 = self.variableDeclarationNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, variableDeclarationNoIn73.tree) else: break #loop33 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 13, variableDeclarationListNoIn_StartIndex, success) pass return retval # $ANTLR end "variableDeclarationListNoIn" class variableDeclaration_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.variableDeclaration_return, self).__init__() self.tree = None # $ANTLR start "variableDeclaration" # JavaScript.g:91:1: variableDeclaration : Identifier ( LT )* ( initialiser )? ; def variableDeclaration(self, ): retval = self.variableDeclaration_return() retval.start = self.input.LT(1) variableDeclaration_StartIndex = self.input.index() root_0 = None Identifier74 = None LT75 = None initialiser76 = None Identifier74_tree = None LT75_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 14): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:92:2: ( Identifier ( LT )* ( initialiser )? ) # JavaScript.g:92:4: Identifier ( LT )* ( initialiser )? pass root_0 = self._adaptor.nil() Identifier74=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_variableDeclaration438) if self._state.backtracking == 0: Identifier74_tree = self._adaptor.createWithPayload(Identifier74) self._adaptor.addChild(root_0, Identifier74_tree) # JavaScript.g:92:17: ( LT )* while True: #loop34 alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == LT) : LA34_2 = self.input.LA(2) if (self.synpred47_JavaScript()) : alt34 = 1 if alt34 == 1: # JavaScript.g:0:0: LT pass LT75=self.match(self.input, LT, self.FOLLOW_LT_in_variableDeclaration440) else: break #loop34 # JavaScript.g:92:20: ( initialiser )? alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == 39) : alt35 = 1 if alt35 == 1: # JavaScript.g:0:0: initialiser pass self._state.following.append(self.FOLLOW_initialiser_in_variableDeclaration444) initialiser76 = self.initialiser() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, initialiser76.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 14, variableDeclaration_StartIndex, success) pass return retval # $ANTLR end "variableDeclaration" class variableDeclarationNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.variableDeclarationNoIn_return, self).__init__() self.tree = None # $ANTLR start "variableDeclarationNoIn" # JavaScript.g:95:1: variableDeclarationNoIn : Identifier ( LT )* ( initialiserNoIn )? ; def variableDeclarationNoIn(self, ): retval = self.variableDeclarationNoIn_return() retval.start = self.input.LT(1) variableDeclarationNoIn_StartIndex = self.input.index() root_0 = None Identifier77 = None LT78 = None initialiserNoIn79 = None Identifier77_tree = None LT78_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 15): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:96:2: ( Identifier ( LT )* ( initialiserNoIn )? ) # JavaScript.g:96:4: Identifier ( LT )* ( initialiserNoIn )? pass root_0 = self._adaptor.nil() Identifier77=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_variableDeclarationNoIn457) if self._state.backtracking == 0: Identifier77_tree = self._adaptor.createWithPayload(Identifier77) self._adaptor.addChild(root_0, Identifier77_tree) # JavaScript.g:96:17: ( LT )* while True: #loop36 alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == LT) : LA36_2 = self.input.LA(2) if (self.synpred49_JavaScript()) : alt36 = 1 if alt36 == 1: # JavaScript.g:0:0: LT pass LT78=self.match(self.input, LT, self.FOLLOW_LT_in_variableDeclarationNoIn459) else: break #loop36 # JavaScript.g:96:20: ( initialiserNoIn )? alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == 39) : alt37 = 1 if alt37 == 1: # JavaScript.g:0:0: initialiserNoIn pass self._state.following.append(self.FOLLOW_initialiserNoIn_in_variableDeclarationNoIn463) initialiserNoIn79 = self.initialiserNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, initialiserNoIn79.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 15, variableDeclarationNoIn_StartIndex, success) pass return retval # $ANTLR end "variableDeclarationNoIn" class initialiser_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.initialiser_return, self).__init__() self.tree = None # $ANTLR start "initialiser" # JavaScript.g:99:1: initialiser : '=' ( LT )* assignmentExpression ; def initialiser(self, ): retval = self.initialiser_return() retval.start = self.input.LT(1) initialiser_StartIndex = self.input.index() root_0 = None char_literal80 = None LT81 = None assignmentExpression82 = None char_literal80_tree = None LT81_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 16): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:100:2: ( '=' ( LT )* assignmentExpression ) # JavaScript.g:100:4: '=' ( LT )* assignmentExpression pass root_0 = self._adaptor.nil() char_literal80=self.match(self.input, 39, self.FOLLOW_39_in_initialiser476) if self._state.backtracking == 0: char_literal80_tree = self._adaptor.createWithPayload(char_literal80) self._adaptor.addChild(root_0, char_literal80_tree) # JavaScript.g:100:10: ( LT )* while True: #loop38 alt38 = 2 LA38_0 = self.input.LA(1) if (LA38_0 == LT) : alt38 = 1 if alt38 == 1: # JavaScript.g:0:0: LT pass LT81=self.match(self.input, LT, self.FOLLOW_LT_in_initialiser478) else: break #loop38 self._state.following.append(self.FOLLOW_assignmentExpression_in_initialiser482) assignmentExpression82 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression82.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 16, initialiser_StartIndex, success) pass return retval # $ANTLR end "initialiser" class initialiserNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.initialiserNoIn_return, self).__init__() self.tree = None # $ANTLR start "initialiserNoIn" # JavaScript.g:103:1: initialiserNoIn : '=' ( LT )* assignmentExpressionNoIn ; def initialiserNoIn(self, ): retval = self.initialiserNoIn_return() retval.start = self.input.LT(1) initialiserNoIn_StartIndex = self.input.index() root_0 = None char_literal83 = None LT84 = None assignmentExpressionNoIn85 = None char_literal83_tree = None LT84_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 17): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:104:2: ( '=' ( LT )* assignmentExpressionNoIn ) # JavaScript.g:104:4: '=' ( LT )* assignmentExpressionNoIn pass root_0 = self._adaptor.nil() char_literal83=self.match(self.input, 39, self.FOLLOW_39_in_initialiserNoIn494) if self._state.backtracking == 0: char_literal83_tree = self._adaptor.createWithPayload(char_literal83) self._adaptor.addChild(root_0, char_literal83_tree) # JavaScript.g:104:10: ( LT )* while True: #loop39 alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == LT) : alt39 = 1 if alt39 == 1: # JavaScript.g:0:0: LT pass LT84=self.match(self.input, LT, self.FOLLOW_LT_in_initialiserNoIn496) else: break #loop39 self._state.following.append(self.FOLLOW_assignmentExpressionNoIn_in_initialiserNoIn500) assignmentExpressionNoIn85 = self.assignmentExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpressionNoIn85.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 17, initialiserNoIn_StartIndex, success) pass return retval # $ANTLR end "initialiserNoIn" class emptyStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.emptyStatement_return, self).__init__() self.tree = None # $ANTLR start "emptyStatement" # JavaScript.g:107:1: emptyStatement : ';' ; def emptyStatement(self, ): retval = self.emptyStatement_return() retval.start = self.input.LT(1) emptyStatement_StartIndex = self.input.index() root_0 = None char_literal86 = None char_literal86_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 18): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:108:2: ( ';' ) # JavaScript.g:108:4: ';' pass root_0 = self._adaptor.nil() char_literal86=self.match(self.input, 38, self.FOLLOW_38_in_emptyStatement512) if self._state.backtracking == 0: char_literal86_tree = self._adaptor.createWithPayload(char_literal86) self._adaptor.addChild(root_0, char_literal86_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 18, emptyStatement_StartIndex, success) pass return retval # $ANTLR end "emptyStatement" class expressionStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.expressionStatement_return, self).__init__() self.tree = None # $ANTLR start "expressionStatement" # JavaScript.g:111:1: expressionStatement : expression ( LT | ';' ) ; def expressionStatement(self, ): retval = self.expressionStatement_return() retval.start = self.input.LT(1) expressionStatement_StartIndex = self.input.index() root_0 = None set88 = None expression87 = None set88_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 19): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:112:2: ( expression ( LT | ';' ) ) # JavaScript.g:112:4: expression ( LT | ';' ) pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_expression_in_expressionStatement524) expression87 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression87.tree) set88 = self.input.LT(1) if self.input.LA(1) == LT or self.input.LA(1) == 38: self.input.consume() self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 19, expressionStatement_StartIndex, success) pass return retval # $ANTLR end "expressionStatement" class ifStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.ifStatement_return, self).__init__() self.tree = None # $ANTLR start "ifStatement" # JavaScript.g:115:1: ifStatement : 'if' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement ( ( LT )* 'else' ( LT )* statement )? ; def ifStatement(self, ): retval = self.ifStatement_return() retval.start = self.input.LT(1) ifStatement_StartIndex = self.input.index() root_0 = None string_literal89 = None LT90 = None char_literal91 = None LT92 = None LT94 = None char_literal95 = None LT96 = None LT98 = None string_literal99 = None LT100 = None expression93 = None statement97 = None statement101 = None string_literal89_tree = None LT90_tree = None char_literal91_tree = None LT92_tree = None LT94_tree = None char_literal95_tree = None LT96_tree = None LT98_tree = None string_literal99_tree = None LT100_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 20): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:116:2: ( 'if' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement ( ( LT )* 'else' ( LT )* statement )? ) # JavaScript.g:116:4: 'if' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement ( ( LT )* 'else' ( LT )* statement )? pass root_0 = self._adaptor.nil() string_literal89=self.match(self.input, 40, self.FOLLOW_40_in_ifStatement545) if self._state.backtracking == 0: string_literal89_tree = self._adaptor.createWithPayload(string_literal89) self._adaptor.addChild(root_0, string_literal89_tree) # JavaScript.g:116:11: ( LT )* while True: #loop40 alt40 = 2 LA40_0 = self.input.LA(1) if (LA40_0 == LT) : alt40 = 1 if alt40 == 1: # JavaScript.g:0:0: LT pass LT90=self.match(self.input, LT, self.FOLLOW_LT_in_ifStatement547) else: break #loop40 char_literal91=self.match(self.input, 32, self.FOLLOW_32_in_ifStatement551) if self._state.backtracking == 0: char_literal91_tree = self._adaptor.createWithPayload(char_literal91) self._adaptor.addChild(root_0, char_literal91_tree) # JavaScript.g:116:20: ( LT )* while True: #loop41 alt41 = 2 LA41_0 = self.input.LA(1) if (LA41_0 == LT) : alt41 = 1 if alt41 == 1: # JavaScript.g:0:0: LT pass LT92=self.match(self.input, LT, self.FOLLOW_LT_in_ifStatement553) else: break #loop41 self._state.following.append(self.FOLLOW_expression_in_ifStatement557) expression93 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression93.tree) # JavaScript.g:116:36: ( LT )* while True: #loop42 alt42 = 2 LA42_0 = self.input.LA(1) if (LA42_0 == LT) : alt42 = 1 if alt42 == 1: # JavaScript.g:0:0: LT pass LT94=self.match(self.input, LT, self.FOLLOW_LT_in_ifStatement559) else: break #loop42 char_literal95=self.match(self.input, 34, self.FOLLOW_34_in_ifStatement563) if self._state.backtracking == 0: char_literal95_tree = self._adaptor.createWithPayload(char_literal95) self._adaptor.addChild(root_0, char_literal95_tree) # JavaScript.g:116:45: ( LT )* while True: #loop43 alt43 = 2 LA43_0 = self.input.LA(1) if (LA43_0 == LT) : alt43 = 1 if alt43 == 1: # JavaScript.g:0:0: LT pass LT96=self.match(self.input, LT, self.FOLLOW_LT_in_ifStatement565) else: break #loop43 self._state.following.append(self.FOLLOW_statement_in_ifStatement569) statement97 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement97.tree) # JavaScript.g:116:58: ( ( LT )* 'else' ( LT )* statement )? alt46 = 2 LA46_0 = self.input.LA(1) if (LA46_0 == LT) : LA46_1 = self.input.LA(2) if (self.synpred60_JavaScript()) : alt46 = 1 elif (LA46_0 == 41) : LA46_2 = self.input.LA(2) if (self.synpred60_JavaScript()) : alt46 = 1 if alt46 == 1: # JavaScript.g:116:59: ( LT )* 'else' ( LT )* statement pass # JavaScript.g:116:61: ( LT )* while True: #loop44 alt44 = 2 LA44_0 = self.input.LA(1) if (LA44_0 == LT) : alt44 = 1 if alt44 == 1: # JavaScript.g:0:0: LT pass LT98=self.match(self.input, LT, self.FOLLOW_LT_in_ifStatement572) else: break #loop44 string_literal99=self.match(self.input, 41, self.FOLLOW_41_in_ifStatement576) if self._state.backtracking == 0: string_literal99_tree = self._adaptor.createWithPayload(string_literal99) self._adaptor.addChild(root_0, string_literal99_tree) # JavaScript.g:116:73: ( LT )* while True: #loop45 alt45 = 2 LA45_0 = self.input.LA(1) if (LA45_0 == LT) : alt45 = 1 if alt45 == 1: # JavaScript.g:0:0: LT pass LT100=self.match(self.input, LT, self.FOLLOW_LT_in_ifStatement578) else: break #loop45 self._state.following.append(self.FOLLOW_statement_in_ifStatement582) statement101 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement101.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 20, ifStatement_StartIndex, success) pass return retval # $ANTLR end "ifStatement" class iterationStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.iterationStatement_return, self).__init__() self.tree = None # $ANTLR start "iterationStatement" # JavaScript.g:119:1: iterationStatement : ( doWhileStatement | whileStatement | forStatement | forInStatement ); def iterationStatement(self, ): retval = self.iterationStatement_return() retval.start = self.input.LT(1) iterationStatement_StartIndex = self.input.index() root_0 = None doWhileStatement102 = None whileStatement103 = None forStatement104 = None forInStatement105 = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 21): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:120:2: ( doWhileStatement | whileStatement | forStatement | forInStatement ) alt47 = 4 LA47 = self.input.LA(1) if LA47 == 42: alt47 = 1 elif LA47 == 43: alt47 = 2 elif LA47 == 44: LA47_3 = self.input.LA(2) if (self.synpred63_JavaScript()) : alt47 = 3 elif (True) : alt47 = 4 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 47, 3, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 47, 0, self.input) raise nvae if alt47 == 1: # JavaScript.g:120:4: doWhileStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_doWhileStatement_in_iterationStatement596) doWhileStatement102 = self.doWhileStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, doWhileStatement102.tree) elif alt47 == 2: # JavaScript.g:121:4: whileStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_whileStatement_in_iterationStatement601) whileStatement103 = self.whileStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, whileStatement103.tree) elif alt47 == 3: # JavaScript.g:122:4: forStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_forStatement_in_iterationStatement606) forStatement104 = self.forStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, forStatement104.tree) elif alt47 == 4: # JavaScript.g:123:4: forInStatement pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_forInStatement_in_iterationStatement611) forInStatement105 = self.forInStatement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, forInStatement105.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 21, iterationStatement_StartIndex, success) pass return retval # $ANTLR end "iterationStatement" class doWhileStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.doWhileStatement_return, self).__init__() self.tree = None # $ANTLR start "doWhileStatement" # JavaScript.g:126:1: doWhileStatement : 'do' ( LT )* statement ( LT )* 'while' ( LT )* '(' expression ')' ( LT | ';' ) ; def doWhileStatement(self, ): retval = self.doWhileStatement_return() retval.start = self.input.LT(1) doWhileStatement_StartIndex = self.input.index() root_0 = None string_literal106 = None LT107 = None LT109 = None string_literal110 = None LT111 = None char_literal112 = None char_literal114 = None set115 = None statement108 = None expression113 = None string_literal106_tree = None LT107_tree = None LT109_tree = None string_literal110_tree = None LT111_tree = None char_literal112_tree = None char_literal114_tree = None set115_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 22): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:127:2: ( 'do' ( LT )* statement ( LT )* 'while' ( LT )* '(' expression ')' ( LT | ';' ) ) # JavaScript.g:127:4: 'do' ( LT )* statement ( LT )* 'while' ( LT )* '(' expression ')' ( LT | ';' ) pass root_0 = self._adaptor.nil() string_literal106=self.match(self.input, 42, self.FOLLOW_42_in_doWhileStatement623) if self._state.backtracking == 0: string_literal106_tree = self._adaptor.createWithPayload(string_literal106) self._adaptor.addChild(root_0, string_literal106_tree) # JavaScript.g:127:11: ( LT )* while True: #loop48 alt48 = 2 LA48_0 = self.input.LA(1) if (LA48_0 == LT) : alt48 = 1 if alt48 == 1: # JavaScript.g:0:0: LT pass LT107=self.match(self.input, LT, self.FOLLOW_LT_in_doWhileStatement625) else: break #loop48 self._state.following.append(self.FOLLOW_statement_in_doWhileStatement629) statement108 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement108.tree) # JavaScript.g:127:26: ( LT )* while True: #loop49 alt49 = 2 LA49_0 = self.input.LA(1) if (LA49_0 == LT) : alt49 = 1 if alt49 == 1: # JavaScript.g:0:0: LT pass LT109=self.match(self.input, LT, self.FOLLOW_LT_in_doWhileStatement631) else: break #loop49 string_literal110=self.match(self.input, 43, self.FOLLOW_43_in_doWhileStatement635) if self._state.backtracking == 0: string_literal110_tree = self._adaptor.createWithPayload(string_literal110) self._adaptor.addChild(root_0, string_literal110_tree) # JavaScript.g:127:39: ( LT )* while True: #loop50 alt50 = 2 LA50_0 = self.input.LA(1) if (LA50_0 == LT) : alt50 = 1 if alt50 == 1: # JavaScript.g:0:0: LT pass LT111=self.match(self.input, LT, self.FOLLOW_LT_in_doWhileStatement637) else: break #loop50 char_literal112=self.match(self.input, 32, self.FOLLOW_32_in_doWhileStatement641) if self._state.backtracking == 0: char_literal112_tree = self._adaptor.createWithPayload(char_literal112) self._adaptor.addChild(root_0, char_literal112_tree) self._state.following.append(self.FOLLOW_expression_in_doWhileStatement643) expression113 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression113.tree) char_literal114=self.match(self.input, 34, self.FOLLOW_34_in_doWhileStatement645) if self._state.backtracking == 0: char_literal114_tree = self._adaptor.createWithPayload(char_literal114) self._adaptor.addChild(root_0, char_literal114_tree) set115 = self.input.LT(1) if self.input.LA(1) == LT or self.input.LA(1) == 38: self.input.consume() self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 22, doWhileStatement_StartIndex, success) pass return retval # $ANTLR end "doWhileStatement" class whileStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.whileStatement_return, self).__init__() self.tree = None # $ANTLR start "whileStatement" # JavaScript.g:130:1: whileStatement : 'while' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement ; def whileStatement(self, ): retval = self.whileStatement_return() retval.start = self.input.LT(1) whileStatement_StartIndex = self.input.index() root_0 = None string_literal116 = None LT117 = None char_literal118 = None LT119 = None LT121 = None char_literal122 = None LT123 = None expression120 = None statement124 = None string_literal116_tree = None LT117_tree = None char_literal118_tree = None LT119_tree = None LT121_tree = None char_literal122_tree = None LT123_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 23): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:131:2: ( 'while' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement ) # JavaScript.g:131:4: 'while' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement pass root_0 = self._adaptor.nil() string_literal116=self.match(self.input, 43, self.FOLLOW_43_in_whileStatement666) if self._state.backtracking == 0: string_literal116_tree = self._adaptor.createWithPayload(string_literal116) self._adaptor.addChild(root_0, string_literal116_tree) # JavaScript.g:131:14: ( LT )* while True: #loop51 alt51 = 2 LA51_0 = self.input.LA(1) if (LA51_0 == LT) : alt51 = 1 if alt51 == 1: # JavaScript.g:0:0: LT pass LT117=self.match(self.input, LT, self.FOLLOW_LT_in_whileStatement668) else: break #loop51 char_literal118=self.match(self.input, 32, self.FOLLOW_32_in_whileStatement672) if self._state.backtracking == 0: char_literal118_tree = self._adaptor.createWithPayload(char_literal118) self._adaptor.addChild(root_0, char_literal118_tree) # JavaScript.g:131:23: ( LT )* while True: #loop52 alt52 = 2 LA52_0 = self.input.LA(1) if (LA52_0 == LT) : alt52 = 1 if alt52 == 1: # JavaScript.g:0:0: LT pass LT119=self.match(self.input, LT, self.FOLLOW_LT_in_whileStatement674) else: break #loop52 self._state.following.append(self.FOLLOW_expression_in_whileStatement678) expression120 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression120.tree) # JavaScript.g:131:39: ( LT )* while True: #loop53 alt53 = 2 LA53_0 = self.input.LA(1) if (LA53_0 == LT) : alt53 = 1 if alt53 == 1: # JavaScript.g:0:0: LT pass LT121=self.match(self.input, LT, self.FOLLOW_LT_in_whileStatement680) else: break #loop53 char_literal122=self.match(self.input, 34, self.FOLLOW_34_in_whileStatement684) if self._state.backtracking == 0: char_literal122_tree = self._adaptor.createWithPayload(char_literal122) self._adaptor.addChild(root_0, char_literal122_tree) # JavaScript.g:131:48: ( LT )* while True: #loop54 alt54 = 2 LA54_0 = self.input.LA(1) if (LA54_0 == LT) : alt54 = 1 if alt54 == 1: # JavaScript.g:0:0: LT pass LT123=self.match(self.input, LT, self.FOLLOW_LT_in_whileStatement686) else: break #loop54 self._state.following.append(self.FOLLOW_statement_in_whileStatement690) statement124 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement124.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 23, whileStatement_StartIndex, success) pass return retval # $ANTLR end "whileStatement" class forStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.forStatement_return, self).__init__() self.tree = None # $ANTLR start "forStatement" # JavaScript.g:134:1: forStatement : 'for' ( LT )* '(' ( ( LT )* forStatementInitialiserPart )? ( LT )* ';' ( ( LT )* expression )? ( LT )* ';' ( ( LT )* expression )? ( LT )* ')' ( LT )* statement ; def forStatement(self, ): retval = self.forStatement_return() retval.start = self.input.LT(1) forStatement_StartIndex = self.input.index() root_0 = None string_literal125 = None LT126 = None char_literal127 = None LT128 = None LT130 = None char_literal131 = None LT132 = None LT134 = None char_literal135 = None LT136 = None LT138 = None char_literal139 = None LT140 = None forStatementInitialiserPart129 = None expression133 = None expression137 = None statement141 = None string_literal125_tree = None LT126_tree = None char_literal127_tree = None LT128_tree = None LT130_tree = None char_literal131_tree = None LT132_tree = None LT134_tree = None char_literal135_tree = None LT136_tree = None LT138_tree = None char_literal139_tree = None LT140_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 24): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:135:2: ( 'for' ( LT )* '(' ( ( LT )* forStatementInitialiserPart )? ( LT )* ';' ( ( LT )* expression )? ( LT )* ';' ( ( LT )* expression )? ( LT )* ')' ( LT )* statement ) # JavaScript.g:135:4: 'for' ( LT )* '(' ( ( LT )* forStatementInitialiserPart )? ( LT )* ';' ( ( LT )* expression )? ( LT )* ';' ( ( LT )* expression )? ( LT )* ')' ( LT )* statement pass root_0 = self._adaptor.nil() string_literal125=self.match(self.input, 44, self.FOLLOW_44_in_forStatement702) if self._state.backtracking == 0: string_literal125_tree = self._adaptor.createWithPayload(string_literal125) self._adaptor.addChild(root_0, string_literal125_tree) # JavaScript.g:135:12: ( LT )* while True: #loop55 alt55 = 2 LA55_0 = self.input.LA(1) if (LA55_0 == LT) : alt55 = 1 if alt55 == 1: # JavaScript.g:0:0: LT pass LT126=self.match(self.input, LT, self.FOLLOW_LT_in_forStatement704) else: break #loop55 char_literal127=self.match(self.input, 32, self.FOLLOW_32_in_forStatement708) if self._state.backtracking == 0: char_literal127_tree = self._adaptor.createWithPayload(char_literal127) self._adaptor.addChild(root_0, char_literal127_tree) # JavaScript.g:135:19: ( ( LT )* forStatementInitialiserPart )? alt57 = 2 alt57 = self.dfa57.predict(self.input) if alt57 == 1: # JavaScript.g:135:20: ( LT )* forStatementInitialiserPart pass # JavaScript.g:135:22: ( LT )* while True: #loop56 alt56 = 2 LA56_0 = self.input.LA(1) if (LA56_0 == LT) : alt56 = 1 if alt56 == 1: # JavaScript.g:0:0: LT pass LT128=self.match(self.input, LT, self.FOLLOW_LT_in_forStatement711) else: break #loop56 self._state.following.append(self.FOLLOW_forStatementInitialiserPart_in_forStatement715) forStatementInitialiserPart129 = self.forStatementInitialiserPart() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, forStatementInitialiserPart129.tree) # JavaScript.g:135:57: ( LT )* while True: #loop58 alt58 = 2 LA58_0 = self.input.LA(1) if (LA58_0 == LT) : alt58 = 1 if alt58 == 1: # JavaScript.g:0:0: LT pass LT130=self.match(self.input, LT, self.FOLLOW_LT_in_forStatement719) else: break #loop58 char_literal131=self.match(self.input, 38, self.FOLLOW_38_in_forStatement723) if self._state.backtracking == 0: char_literal131_tree = self._adaptor.createWithPayload(char_literal131) self._adaptor.addChild(root_0, char_literal131_tree) # JavaScript.g:135:64: ( ( LT )* expression )? alt60 = 2 alt60 = self.dfa60.predict(self.input) if alt60 == 1: # JavaScript.g:135:65: ( LT )* expression pass # JavaScript.g:135:67: ( LT )* while True: #loop59 alt59 = 2 LA59_0 = self.input.LA(1) if (LA59_0 == LT) : alt59 = 1 if alt59 == 1: # JavaScript.g:0:0: LT pass LT132=self.match(self.input, LT, self.FOLLOW_LT_in_forStatement726) else: break #loop59 self._state.following.append(self.FOLLOW_expression_in_forStatement730) expression133 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression133.tree) # JavaScript.g:135:85: ( LT )* while True: #loop61 alt61 = 2 LA61_0 = self.input.LA(1) if (LA61_0 == LT) : alt61 = 1 if alt61 == 1: # JavaScript.g:0:0: LT pass LT134=self.match(self.input, LT, self.FOLLOW_LT_in_forStatement734) else: break #loop61 char_literal135=self.match(self.input, 38, self.FOLLOW_38_in_forStatement738) if self._state.backtracking == 0: char_literal135_tree = self._adaptor.createWithPayload(char_literal135) self._adaptor.addChild(root_0, char_literal135_tree) # JavaScript.g:135:92: ( ( LT )* expression )? alt63 = 2 alt63 = self.dfa63.predict(self.input) if alt63 == 1: # JavaScript.g:135:93: ( LT )* expression pass # JavaScript.g:135:95: ( LT )* while True: #loop62 alt62 = 2 LA62_0 = self.input.LA(1) if (LA62_0 == LT) : alt62 = 1 if alt62 == 1: # JavaScript.g:0:0: LT pass LT136=self.match(self.input, LT, self.FOLLOW_LT_in_forStatement741) else: break #loop62 self._state.following.append(self.FOLLOW_expression_in_forStatement745) expression137 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression137.tree) # JavaScript.g:135:113: ( LT )* while True: #loop64 alt64 = 2 LA64_0 = self.input.LA(1) if (LA64_0 == LT) : alt64 = 1 if alt64 == 1: # JavaScript.g:0:0: LT pass LT138=self.match(self.input, LT, self.FOLLOW_LT_in_forStatement749) else: break #loop64 char_literal139=self.match(self.input, 34, self.FOLLOW_34_in_forStatement753) if self._state.backtracking == 0: char_literal139_tree = self._adaptor.createWithPayload(char_literal139) self._adaptor.addChild(root_0, char_literal139_tree) # JavaScript.g:135:122: ( LT )* while True: #loop65 alt65 = 2 LA65_0 = self.input.LA(1) if (LA65_0 == LT) : alt65 = 1 if alt65 == 1: # JavaScript.g:0:0: LT pass LT140=self.match(self.input, LT, self.FOLLOW_LT_in_forStatement755) else: break #loop65 self._state.following.append(self.FOLLOW_statement_in_forStatement759) statement141 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement141.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 24, forStatement_StartIndex, success) pass return retval # $ANTLR end "forStatement" class forStatementInitialiserPart_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.forStatementInitialiserPart_return, self).__init__() self.tree = None # $ANTLR start "forStatementInitialiserPart" # JavaScript.g:138:1: forStatementInitialiserPart : ( expressionNoIn | 'var' ( LT )* variableDeclarationListNoIn ); def forStatementInitialiserPart(self, ): retval = self.forStatementInitialiserPart_return() retval.start = self.input.LT(1) forStatementInitialiserPart_StartIndex = self.input.index() root_0 = None string_literal143 = None LT144 = None expressionNoIn142 = None variableDeclarationListNoIn145 = None string_literal143_tree = None LT144_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 25): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:139:2: ( expressionNoIn | 'var' ( LT )* variableDeclarationListNoIn ) alt67 = 2 LA67_0 = self.input.LA(1) if ((Identifier <= LA67_0 <= NumericLiteral) or (31 <= LA67_0 <= 32) or LA67_0 == 35 or (58 <= LA67_0 <= 59) or (91 <= LA67_0 <= 92) or (96 <= LA67_0 <= 106)) : alt67 = 1 elif (LA67_0 == 37) : alt67 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 67, 0, self.input) raise nvae if alt67 == 1: # JavaScript.g:139:4: expressionNoIn pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_expressionNoIn_in_forStatementInitialiserPart771) expressionNoIn142 = self.expressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expressionNoIn142.tree) elif alt67 == 2: # JavaScript.g:140:4: 'var' ( LT )* variableDeclarationListNoIn pass root_0 = self._adaptor.nil() string_literal143=self.match(self.input, 37, self.FOLLOW_37_in_forStatementInitialiserPart776) if self._state.backtracking == 0: string_literal143_tree = self._adaptor.createWithPayload(string_literal143) self._adaptor.addChild(root_0, string_literal143_tree) # JavaScript.g:140:12: ( LT )* while True: #loop66 alt66 = 2 LA66_0 = self.input.LA(1) if (LA66_0 == LT) : alt66 = 1 if alt66 == 1: # JavaScript.g:0:0: LT pass LT144=self.match(self.input, LT, self.FOLLOW_LT_in_forStatementInitialiserPart778) else: break #loop66 self._state.following.append(self.FOLLOW_variableDeclarationListNoIn_in_forStatementInitialiserPart782) variableDeclarationListNoIn145 = self.variableDeclarationListNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, variableDeclarationListNoIn145.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 25, forStatementInitialiserPart_StartIndex, success) pass return retval # $ANTLR end "forStatementInitialiserPart" class forInStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.forInStatement_return, self).__init__() self.tree = None # $ANTLR start "forInStatement" # JavaScript.g:143:1: forInStatement : 'for' ( LT )* '(' ( LT )* forInStatementInitialiserPart ( LT )* 'in' ( LT )* expression ( LT )* ')' ( LT )* statement ; def forInStatement(self, ): retval = self.forInStatement_return() retval.start = self.input.LT(1) forInStatement_StartIndex = self.input.index() root_0 = None string_literal146 = None LT147 = None char_literal148 = None LT149 = None LT151 = None string_literal152 = None LT153 = None LT155 = None char_literal156 = None LT157 = None forInStatementInitialiserPart150 = None expression154 = None statement158 = None string_literal146_tree = None LT147_tree = None char_literal148_tree = None LT149_tree = None LT151_tree = None string_literal152_tree = None LT153_tree = None LT155_tree = None char_literal156_tree = None LT157_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 26): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:144:2: ( 'for' ( LT )* '(' ( LT )* forInStatementInitialiserPart ( LT )* 'in' ( LT )* expression ( LT )* ')' ( LT )* statement ) # JavaScript.g:144:4: 'for' ( LT )* '(' ( LT )* forInStatementInitialiserPart ( LT )* 'in' ( LT )* expression ( LT )* ')' ( LT )* statement pass root_0 = self._adaptor.nil() string_literal146=self.match(self.input, 44, self.FOLLOW_44_in_forInStatement794) if self._state.backtracking == 0: string_literal146_tree = self._adaptor.createWithPayload(string_literal146) self._adaptor.addChild(root_0, string_literal146_tree) # JavaScript.g:144:12: ( LT )* while True: #loop68 alt68 = 2 LA68_0 = self.input.LA(1) if (LA68_0 == LT) : alt68 = 1 if alt68 == 1: # JavaScript.g:0:0: LT pass LT147=self.match(self.input, LT, self.FOLLOW_LT_in_forInStatement796) else: break #loop68 char_literal148=self.match(self.input, 32, self.FOLLOW_32_in_forInStatement800) if self._state.backtracking == 0: char_literal148_tree = self._adaptor.createWithPayload(char_literal148) self._adaptor.addChild(root_0, char_literal148_tree) # JavaScript.g:144:21: ( LT )* while True: #loop69 alt69 = 2 LA69_0 = self.input.LA(1) if (LA69_0 == LT) : alt69 = 1 if alt69 == 1: # JavaScript.g:0:0: LT pass LT149=self.match(self.input, LT, self.FOLLOW_LT_in_forInStatement802) else: break #loop69 self._state.following.append(self.FOLLOW_forInStatementInitialiserPart_in_forInStatement806) forInStatementInitialiserPart150 = self.forInStatementInitialiserPart() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, forInStatementInitialiserPart150.tree) # JavaScript.g:144:56: ( LT )* while True: #loop70 alt70 = 2 LA70_0 = self.input.LA(1) if (LA70_0 == LT) : alt70 = 1 if alt70 == 1: # JavaScript.g:0:0: LT pass LT151=self.match(self.input, LT, self.FOLLOW_LT_in_forInStatement808) else: break #loop70 string_literal152=self.match(self.input, 45, self.FOLLOW_45_in_forInStatement812) if self._state.backtracking == 0: string_literal152_tree = self._adaptor.createWithPayload(string_literal152) self._adaptor.addChild(root_0, string_literal152_tree) # JavaScript.g:144:66: ( LT )* while True: #loop71 alt71 = 2 LA71_0 = self.input.LA(1) if (LA71_0 == LT) : alt71 = 1 if alt71 == 1: # JavaScript.g:0:0: LT pass LT153=self.match(self.input, LT, self.FOLLOW_LT_in_forInStatement814) else: break #loop71 self._state.following.append(self.FOLLOW_expression_in_forInStatement818) expression154 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression154.tree) # JavaScript.g:144:82: ( LT )* while True: #loop72 alt72 = 2 LA72_0 = self.input.LA(1) if (LA72_0 == LT) : alt72 = 1 if alt72 == 1: # JavaScript.g:0:0: LT pass LT155=self.match(self.input, LT, self.FOLLOW_LT_in_forInStatement820) else: break #loop72 char_literal156=self.match(self.input, 34, self.FOLLOW_34_in_forInStatement824) if self._state.backtracking == 0: char_literal156_tree = self._adaptor.createWithPayload(char_literal156) self._adaptor.addChild(root_0, char_literal156_tree) # JavaScript.g:144:91: ( LT )* while True: #loop73 alt73 = 2 LA73_0 = self.input.LA(1) if (LA73_0 == LT) : alt73 = 1 if alt73 == 1: # JavaScript.g:0:0: LT pass LT157=self.match(self.input, LT, self.FOLLOW_LT_in_forInStatement826) else: break #loop73 self._state.following.append(self.FOLLOW_statement_in_forInStatement830) statement158 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement158.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 26, forInStatement_StartIndex, success) pass return retval # $ANTLR end "forInStatement" class forInStatementInitialiserPart_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.forInStatementInitialiserPart_return, self).__init__() self.tree = None # $ANTLR start "forInStatementInitialiserPart" # JavaScript.g:147:1: forInStatementInitialiserPart : ( leftHandSideExpression | 'var' ( LT )* variableDeclarationNoIn ); def forInStatementInitialiserPart(self, ): retval = self.forInStatementInitialiserPart_return() retval.start = self.input.LT(1) forInStatementInitialiserPart_StartIndex = self.input.index() root_0 = None string_literal160 = None LT161 = None leftHandSideExpression159 = None variableDeclarationNoIn162 = None string_literal160_tree = None LT161_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 27): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:148:2: ( leftHandSideExpression | 'var' ( LT )* variableDeclarationNoIn ) alt75 = 2 LA75_0 = self.input.LA(1) if ((Identifier <= LA75_0 <= NumericLiteral) or (31 <= LA75_0 <= 32) or LA75_0 == 35 or (58 <= LA75_0 <= 59) or (103 <= LA75_0 <= 106)) : alt75 = 1 elif (LA75_0 == 37) : alt75 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 75, 0, self.input) raise nvae if alt75 == 1: # JavaScript.g:148:4: leftHandSideExpression pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_leftHandSideExpression_in_forInStatementInitialiserPart842) leftHandSideExpression159 = self.leftHandSideExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, leftHandSideExpression159.tree) elif alt75 == 2: # JavaScript.g:149:4: 'var' ( LT )* variableDeclarationNoIn pass root_0 = self._adaptor.nil() string_literal160=self.match(self.input, 37, self.FOLLOW_37_in_forInStatementInitialiserPart847) if self._state.backtracking == 0: string_literal160_tree = self._adaptor.createWithPayload(string_literal160) self._adaptor.addChild(root_0, string_literal160_tree) # JavaScript.g:149:12: ( LT )* while True: #loop74 alt74 = 2 LA74_0 = self.input.LA(1) if (LA74_0 == LT) : alt74 = 1 if alt74 == 1: # JavaScript.g:0:0: LT pass LT161=self.match(self.input, LT, self.FOLLOW_LT_in_forInStatementInitialiserPart849) else: break #loop74 self._state.following.append(self.FOLLOW_variableDeclarationNoIn_in_forInStatementInitialiserPart853) variableDeclarationNoIn162 = self.variableDeclarationNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, variableDeclarationNoIn162.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 27, forInStatementInitialiserPart_StartIndex, success) pass return retval # $ANTLR end "forInStatementInitialiserPart" class continueStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.continueStatement_return, self).__init__() self.tree = None # $ANTLR start "continueStatement" # JavaScript.g:152:1: continueStatement : 'continue' ( Identifier )? ( LT | ';' ) ; def continueStatement(self, ): retval = self.continueStatement_return() retval.start = self.input.LT(1) continueStatement_StartIndex = self.input.index() root_0 = None string_literal163 = None Identifier164 = None set165 = None string_literal163_tree = None Identifier164_tree = None set165_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 28): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:153:2: ( 'continue' ( Identifier )? ( LT | ';' ) ) # JavaScript.g:153:4: 'continue' ( Identifier )? ( LT | ';' ) pass root_0 = self._adaptor.nil() string_literal163=self.match(self.input, 46, self.FOLLOW_46_in_continueStatement864) if self._state.backtracking == 0: string_literal163_tree = self._adaptor.createWithPayload(string_literal163) self._adaptor.addChild(root_0, string_literal163_tree) # JavaScript.g:153:15: ( Identifier )? alt76 = 2 LA76_0 = self.input.LA(1) if (LA76_0 == Identifier) : alt76 = 1 if alt76 == 1: # JavaScript.g:0:0: Identifier pass Identifier164=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_continueStatement866) if self._state.backtracking == 0: Identifier164_tree = self._adaptor.createWithPayload(Identifier164) self._adaptor.addChild(root_0, Identifier164_tree) set165 = self.input.LT(1) if self.input.LA(1) == LT or self.input.LA(1) == 38: self.input.consume() self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 28, continueStatement_StartIndex, success) pass return retval # $ANTLR end "continueStatement" class breakStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.breakStatement_return, self).__init__() self.tree = None # $ANTLR start "breakStatement" # JavaScript.g:156:1: breakStatement : 'break' ( Identifier )? ( LT | ';' ) ; def breakStatement(self, ): retval = self.breakStatement_return() retval.start = self.input.LT(1) breakStatement_StartIndex = self.input.index() root_0 = None string_literal166 = None Identifier167 = None set168 = None string_literal166_tree = None Identifier167_tree = None set168_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 29): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:157:2: ( 'break' ( Identifier )? ( LT | ';' ) ) # JavaScript.g:157:4: 'break' ( Identifier )? ( LT | ';' ) pass root_0 = self._adaptor.nil() string_literal166=self.match(self.input, 47, self.FOLLOW_47_in_breakStatement887) if self._state.backtracking == 0: string_literal166_tree = self._adaptor.createWithPayload(string_literal166) self._adaptor.addChild(root_0, string_literal166_tree) # JavaScript.g:157:12: ( Identifier )? alt77 = 2 LA77_0 = self.input.LA(1) if (LA77_0 == Identifier) : alt77 = 1 if alt77 == 1: # JavaScript.g:0:0: Identifier pass Identifier167=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_breakStatement889) if self._state.backtracking == 0: Identifier167_tree = self._adaptor.createWithPayload(Identifier167) self._adaptor.addChild(root_0, Identifier167_tree) set168 = self.input.LT(1) if self.input.LA(1) == LT or self.input.LA(1) == 38: self.input.consume() self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 29, breakStatement_StartIndex, success) pass return retval # $ANTLR end "breakStatement" class returnStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.returnStatement_return, self).__init__() self.tree = None # $ANTLR start "returnStatement" # JavaScript.g:160:1: returnStatement : 'return' ( expression )? ( LT | ';' ) ; def returnStatement(self, ): retval = self.returnStatement_return() retval.start = self.input.LT(1) returnStatement_StartIndex = self.input.index() root_0 = None string_literal169 = None set171 = None expression170 = None string_literal169_tree = None set171_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 30): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:161:2: ( 'return' ( expression )? ( LT | ';' ) ) # JavaScript.g:161:4: 'return' ( expression )? ( LT | ';' ) pass root_0 = self._adaptor.nil() string_literal169=self.match(self.input, 48, self.FOLLOW_48_in_returnStatement910) if self._state.backtracking == 0: string_literal169_tree = self._adaptor.createWithPayload(string_literal169) self._adaptor.addChild(root_0, string_literal169_tree) # JavaScript.g:161:13: ( expression )? alt78 = 2 LA78_0 = self.input.LA(1) if ((Identifier <= LA78_0 <= NumericLiteral) or (31 <= LA78_0 <= 32) or LA78_0 == 35 or (58 <= LA78_0 <= 59) or (91 <= LA78_0 <= 92) or (96 <= LA78_0 <= 106)) : alt78 = 1 if alt78 == 1: # JavaScript.g:0:0: expression pass self._state.following.append(self.FOLLOW_expression_in_returnStatement912) expression170 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression170.tree) set171 = self.input.LT(1) if self.input.LA(1) == LT or self.input.LA(1) == 38: self.input.consume() self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 30, returnStatement_StartIndex, success) pass return retval # $ANTLR end "returnStatement" class withStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.withStatement_return, self).__init__() self.tree = None # $ANTLR start "withStatement" # JavaScript.g:164:1: withStatement : 'with' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement ; def withStatement(self, ): retval = self.withStatement_return() retval.start = self.input.LT(1) withStatement_StartIndex = self.input.index() root_0 = None string_literal172 = None LT173 = None char_literal174 = None LT175 = None LT177 = None char_literal178 = None LT179 = None expression176 = None statement180 = None string_literal172_tree = None LT173_tree = None char_literal174_tree = None LT175_tree = None LT177_tree = None char_literal178_tree = None LT179_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 31): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:165:2: ( 'with' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement ) # JavaScript.g:165:4: 'with' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* statement pass root_0 = self._adaptor.nil() string_literal172=self.match(self.input, 49, self.FOLLOW_49_in_withStatement934) if self._state.backtracking == 0: string_literal172_tree = self._adaptor.createWithPayload(string_literal172) self._adaptor.addChild(root_0, string_literal172_tree) # JavaScript.g:165:13: ( LT )* while True: #loop79 alt79 = 2 LA79_0 = self.input.LA(1) if (LA79_0 == LT) : alt79 = 1 if alt79 == 1: # JavaScript.g:0:0: LT pass LT173=self.match(self.input, LT, self.FOLLOW_LT_in_withStatement936) else: break #loop79 char_literal174=self.match(self.input, 32, self.FOLLOW_32_in_withStatement940) if self._state.backtracking == 0: char_literal174_tree = self._adaptor.createWithPayload(char_literal174) self._adaptor.addChild(root_0, char_literal174_tree) # JavaScript.g:165:22: ( LT )* while True: #loop80 alt80 = 2 LA80_0 = self.input.LA(1) if (LA80_0 == LT) : alt80 = 1 if alt80 == 1: # JavaScript.g:0:0: LT pass LT175=self.match(self.input, LT, self.FOLLOW_LT_in_withStatement942) else: break #loop80 self._state.following.append(self.FOLLOW_expression_in_withStatement946) expression176 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression176.tree) # JavaScript.g:165:38: ( LT )* while True: #loop81 alt81 = 2 LA81_0 = self.input.LA(1) if (LA81_0 == LT) : alt81 = 1 if alt81 == 1: # JavaScript.g:0:0: LT pass LT177=self.match(self.input, LT, self.FOLLOW_LT_in_withStatement948) else: break #loop81 char_literal178=self.match(self.input, 34, self.FOLLOW_34_in_withStatement952) if self._state.backtracking == 0: char_literal178_tree = self._adaptor.createWithPayload(char_literal178) self._adaptor.addChild(root_0, char_literal178_tree) # JavaScript.g:165:47: ( LT )* while True: #loop82 alt82 = 2 LA82_0 = self.input.LA(1) if (LA82_0 == LT) : alt82 = 1 if alt82 == 1: # JavaScript.g:0:0: LT pass LT179=self.match(self.input, LT, self.FOLLOW_LT_in_withStatement954) else: break #loop82 self._state.following.append(self.FOLLOW_statement_in_withStatement958) statement180 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement180.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 31, withStatement_StartIndex, success) pass return retval # $ANTLR end "withStatement" class labelledStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.labelledStatement_return, self).__init__() self.tree = None # $ANTLR start "labelledStatement" # JavaScript.g:168:1: labelledStatement : Identifier ( LT )* ':' ( LT )* statement ; def labelledStatement(self, ): retval = self.labelledStatement_return() retval.start = self.input.LT(1) labelledStatement_StartIndex = self.input.index() root_0 = None Identifier181 = None LT182 = None char_literal183 = None LT184 = None statement185 = None Identifier181_tree = None LT182_tree = None char_literal183_tree = None LT184_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 32): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:169:2: ( Identifier ( LT )* ':' ( LT )* statement ) # JavaScript.g:169:4: Identifier ( LT )* ':' ( LT )* statement pass root_0 = self._adaptor.nil() Identifier181=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_labelledStatement969) if self._state.backtracking == 0: Identifier181_tree = self._adaptor.createWithPayload(Identifier181) self._adaptor.addChild(root_0, Identifier181_tree) # JavaScript.g:169:17: ( LT )* while True: #loop83 alt83 = 2 LA83_0 = self.input.LA(1) if (LA83_0 == LT) : alt83 = 1 if alt83 == 1: # JavaScript.g:0:0: LT pass LT182=self.match(self.input, LT, self.FOLLOW_LT_in_labelledStatement971) else: break #loop83 char_literal183=self.match(self.input, 50, self.FOLLOW_50_in_labelledStatement975) if self._state.backtracking == 0: char_literal183_tree = self._adaptor.createWithPayload(char_literal183) self._adaptor.addChild(root_0, char_literal183_tree) # JavaScript.g:169:26: ( LT )* while True: #loop84 alt84 = 2 LA84_0 = self.input.LA(1) if (LA84_0 == LT) : alt84 = 1 if alt84 == 1: # JavaScript.g:0:0: LT pass LT184=self.match(self.input, LT, self.FOLLOW_LT_in_labelledStatement977) else: break #loop84 self._state.following.append(self.FOLLOW_statement_in_labelledStatement981) statement185 = self.statement() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statement185.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 32, labelledStatement_StartIndex, success) pass return retval # $ANTLR end "labelledStatement" class switchStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.switchStatement_return, self).__init__() self.tree = None # $ANTLR start "switchStatement" # JavaScript.g:172:1: switchStatement : 'switch' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* caseBlock ; def switchStatement(self, ): retval = self.switchStatement_return() retval.start = self.input.LT(1) switchStatement_StartIndex = self.input.index() root_0 = None string_literal186 = None LT187 = None char_literal188 = None LT189 = None LT191 = None char_literal192 = None LT193 = None expression190 = None caseBlock194 = None string_literal186_tree = None LT187_tree = None char_literal188_tree = None LT189_tree = None LT191_tree = None char_literal192_tree = None LT193_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 33): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:173:2: ( 'switch' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* caseBlock ) # JavaScript.g:173:4: 'switch' ( LT )* '(' ( LT )* expression ( LT )* ')' ( LT )* caseBlock pass root_0 = self._adaptor.nil() string_literal186=self.match(self.input, 51, self.FOLLOW_51_in_switchStatement993) if self._state.backtracking == 0: string_literal186_tree = self._adaptor.createWithPayload(string_literal186) self._adaptor.addChild(root_0, string_literal186_tree) # JavaScript.g:173:15: ( LT )* while True: #loop85 alt85 = 2 LA85_0 = self.input.LA(1) if (LA85_0 == LT) : alt85 = 1 if alt85 == 1: # JavaScript.g:0:0: LT pass LT187=self.match(self.input, LT, self.FOLLOW_LT_in_switchStatement995) else: break #loop85 char_literal188=self.match(self.input, 32, self.FOLLOW_32_in_switchStatement999) if self._state.backtracking == 0: char_literal188_tree = self._adaptor.createWithPayload(char_literal188) self._adaptor.addChild(root_0, char_literal188_tree) # JavaScript.g:173:24: ( LT )* while True: #loop86 alt86 = 2 LA86_0 = self.input.LA(1) if (LA86_0 == LT) : alt86 = 1 if alt86 == 1: # JavaScript.g:0:0: LT pass LT189=self.match(self.input, LT, self.FOLLOW_LT_in_switchStatement1001) else: break #loop86 self._state.following.append(self.FOLLOW_expression_in_switchStatement1005) expression190 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression190.tree) # JavaScript.g:173:40: ( LT )* while True: #loop87 alt87 = 2 LA87_0 = self.input.LA(1) if (LA87_0 == LT) : alt87 = 1 if alt87 == 1: # JavaScript.g:0:0: LT pass LT191=self.match(self.input, LT, self.FOLLOW_LT_in_switchStatement1007) else: break #loop87 char_literal192=self.match(self.input, 34, self.FOLLOW_34_in_switchStatement1011) if self._state.backtracking == 0: char_literal192_tree = self._adaptor.createWithPayload(char_literal192) self._adaptor.addChild(root_0, char_literal192_tree) # JavaScript.g:173:49: ( LT )* while True: #loop88 alt88 = 2 LA88_0 = self.input.LA(1) if (LA88_0 == LT) : alt88 = 1 if alt88 == 1: # JavaScript.g:0:0: LT pass LT193=self.match(self.input, LT, self.FOLLOW_LT_in_switchStatement1013) else: break #loop88 self._state.following.append(self.FOLLOW_caseBlock_in_switchStatement1017) caseBlock194 = self.caseBlock() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, caseBlock194.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 33, switchStatement_StartIndex, success) pass return retval # $ANTLR end "switchStatement" class caseBlock_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.caseBlock_return, self).__init__() self.tree = None # $ANTLR start "caseBlock" # JavaScript.g:176:1: caseBlock : '{' ( ( LT )* caseClause )* ( ( LT )* defaultClause ( ( LT )* caseClause )* )? ( LT )* '}' ; def caseBlock(self, ): retval = self.caseBlock_return() retval.start = self.input.LT(1) caseBlock_StartIndex = self.input.index() root_0 = None char_literal195 = None LT196 = None LT198 = None LT200 = None LT202 = None char_literal203 = None caseClause197 = None defaultClause199 = None caseClause201 = None char_literal195_tree = None LT196_tree = None LT198_tree = None LT200_tree = None LT202_tree = None char_literal203_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 34): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:177:2: ( '{' ( ( LT )* caseClause )* ( ( LT )* defaultClause ( ( LT )* caseClause )* )? ( LT )* '}' ) # JavaScript.g:177:4: '{' ( ( LT )* caseClause )* ( ( LT )* defaultClause ( ( LT )* caseClause )* )? ( LT )* '}' pass root_0 = self._adaptor.nil() char_literal195=self.match(self.input, 35, self.FOLLOW_35_in_caseBlock1029) if self._state.backtracking == 0: char_literal195_tree = self._adaptor.createWithPayload(char_literal195) self._adaptor.addChild(root_0, char_literal195_tree) # JavaScript.g:177:8: ( ( LT )* caseClause )* while True: #loop90 alt90 = 2 alt90 = self.dfa90.predict(self.input) if alt90 == 1: # JavaScript.g:177:9: ( LT )* caseClause pass # JavaScript.g:177:11: ( LT )* while True: #loop89 alt89 = 2 LA89_0 = self.input.LA(1) if (LA89_0 == LT) : alt89 = 1 if alt89 == 1: # JavaScript.g:0:0: LT pass LT196=self.match(self.input, LT, self.FOLLOW_LT_in_caseBlock1032) else: break #loop89 self._state.following.append(self.FOLLOW_caseClause_in_caseBlock1036) caseClause197 = self.caseClause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, caseClause197.tree) else: break #loop90 # JavaScript.g:177:27: ( ( LT )* defaultClause ( ( LT )* caseClause )* )? alt94 = 2 alt94 = self.dfa94.predict(self.input) if alt94 == 1: # JavaScript.g:177:28: ( LT )* defaultClause ( ( LT )* caseClause )* pass # JavaScript.g:177:30: ( LT )* while True: #loop91 alt91 = 2 LA91_0 = self.input.LA(1) if (LA91_0 == LT) : alt91 = 1 if alt91 == 1: # JavaScript.g:0:0: LT pass LT198=self.match(self.input, LT, self.FOLLOW_LT_in_caseBlock1041) else: break #loop91 self._state.following.append(self.FOLLOW_defaultClause_in_caseBlock1045) defaultClause199 = self.defaultClause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, defaultClause199.tree) # JavaScript.g:177:47: ( ( LT )* caseClause )* while True: #loop93 alt93 = 2 alt93 = self.dfa93.predict(self.input) if alt93 == 1: # JavaScript.g:177:48: ( LT )* caseClause pass # JavaScript.g:177:50: ( LT )* while True: #loop92 alt92 = 2 LA92_0 = self.input.LA(1) if (LA92_0 == LT) : alt92 = 1 if alt92 == 1: # JavaScript.g:0:0: LT pass LT200=self.match(self.input, LT, self.FOLLOW_LT_in_caseBlock1048) else: break #loop92 self._state.following.append(self.FOLLOW_caseClause_in_caseBlock1052) caseClause201 = self.caseClause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, caseClause201.tree) else: break #loop93 # JavaScript.g:177:70: ( LT )* while True: #loop95 alt95 = 2 LA95_0 = self.input.LA(1) if (LA95_0 == LT) : alt95 = 1 if alt95 == 1: # JavaScript.g:0:0: LT pass LT202=self.match(self.input, LT, self.FOLLOW_LT_in_caseBlock1058) else: break #loop95 char_literal203=self.match(self.input, 36, self.FOLLOW_36_in_caseBlock1062) if self._state.backtracking == 0: char_literal203_tree = self._adaptor.createWithPayload(char_literal203) self._adaptor.addChild(root_0, char_literal203_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 34, caseBlock_StartIndex, success) pass return retval # $ANTLR end "caseBlock" class caseClause_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.caseClause_return, self).__init__() self.tree = None # $ANTLR start "caseClause" # JavaScript.g:180:1: caseClause : 'case' ( LT )* expression ( LT )* ':' ( LT )* ( statementList )? ; def caseClause(self, ): retval = self.caseClause_return() retval.start = self.input.LT(1) caseClause_StartIndex = self.input.index() root_0 = None string_literal204 = None LT205 = None LT207 = None char_literal208 = None LT209 = None expression206 = None statementList210 = None string_literal204_tree = None LT205_tree = None LT207_tree = None char_literal208_tree = None LT209_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 35): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:181:2: ( 'case' ( LT )* expression ( LT )* ':' ( LT )* ( statementList )? ) # JavaScript.g:181:4: 'case' ( LT )* expression ( LT )* ':' ( LT )* ( statementList )? pass root_0 = self._adaptor.nil() string_literal204=self.match(self.input, 52, self.FOLLOW_52_in_caseClause1073) if self._state.backtracking == 0: string_literal204_tree = self._adaptor.createWithPayload(string_literal204) self._adaptor.addChild(root_0, string_literal204_tree) # JavaScript.g:181:13: ( LT )* while True: #loop96 alt96 = 2 LA96_0 = self.input.LA(1) if (LA96_0 == LT) : alt96 = 1 if alt96 == 1: # JavaScript.g:0:0: LT pass LT205=self.match(self.input, LT, self.FOLLOW_LT_in_caseClause1075) else: break #loop96 self._state.following.append(self.FOLLOW_expression_in_caseClause1079) expression206 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression206.tree) # JavaScript.g:181:29: ( LT )* while True: #loop97 alt97 = 2 LA97_0 = self.input.LA(1) if (LA97_0 == LT) : alt97 = 1 if alt97 == 1: # JavaScript.g:0:0: LT pass LT207=self.match(self.input, LT, self.FOLLOW_LT_in_caseClause1081) else: break #loop97 char_literal208=self.match(self.input, 50, self.FOLLOW_50_in_caseClause1085) if self._state.backtracking == 0: char_literal208_tree = self._adaptor.createWithPayload(char_literal208) self._adaptor.addChild(root_0, char_literal208_tree) # JavaScript.g:181:38: ( LT )* while True: #loop98 alt98 = 2 LA98_0 = self.input.LA(1) if (LA98_0 == LT) : LA98_2 = self.input.LA(2) if (self.synpred118_JavaScript()) : alt98 = 1 if alt98 == 1: # JavaScript.g:0:0: LT pass LT209=self.match(self.input, LT, self.FOLLOW_LT_in_caseClause1087) else: break #loop98 # JavaScript.g:181:41: ( statementList )? alt99 = 2 LA99_0 = self.input.LA(1) if ((Identifier <= LA99_0 <= NumericLiteral) or (31 <= LA99_0 <= 32) or LA99_0 == 35 or (37 <= LA99_0 <= 38) or LA99_0 == 40 or (42 <= LA99_0 <= 44) or (46 <= LA99_0 <= 49) or LA99_0 == 51 or (54 <= LA99_0 <= 55) or (58 <= LA99_0 <= 59) or (91 <= LA99_0 <= 92) or (96 <= LA99_0 <= 106)) : alt99 = 1 if alt99 == 1: # JavaScript.g:0:0: statementList pass self._state.following.append(self.FOLLOW_statementList_in_caseClause1091) statementList210 = self.statementList() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statementList210.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 35, caseClause_StartIndex, success) pass return retval # $ANTLR end "caseClause" class defaultClause_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.defaultClause_return, self).__init__() self.tree = None # $ANTLR start "defaultClause" # JavaScript.g:184:1: defaultClause : 'default' ( LT )* ':' ( LT )* ( statementList )? ; def defaultClause(self, ): retval = self.defaultClause_return() retval.start = self.input.LT(1) defaultClause_StartIndex = self.input.index() root_0 = None string_literal211 = None LT212 = None char_literal213 = None LT214 = None statementList215 = None string_literal211_tree = None LT212_tree = None char_literal213_tree = None LT214_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 36): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:185:2: ( 'default' ( LT )* ':' ( LT )* ( statementList )? ) # JavaScript.g:185:4: 'default' ( LT )* ':' ( LT )* ( statementList )? pass root_0 = self._adaptor.nil() string_literal211=self.match(self.input, 53, self.FOLLOW_53_in_defaultClause1104) if self._state.backtracking == 0: string_literal211_tree = self._adaptor.createWithPayload(string_literal211) self._adaptor.addChild(root_0, string_literal211_tree) # JavaScript.g:185:16: ( LT )* while True: #loop100 alt100 = 2 LA100_0 = self.input.LA(1) if (LA100_0 == LT) : alt100 = 1 if alt100 == 1: # JavaScript.g:0:0: LT pass LT212=self.match(self.input, LT, self.FOLLOW_LT_in_defaultClause1106) else: break #loop100 char_literal213=self.match(self.input, 50, self.FOLLOW_50_in_defaultClause1110) if self._state.backtracking == 0: char_literal213_tree = self._adaptor.createWithPayload(char_literal213) self._adaptor.addChild(root_0, char_literal213_tree) # JavaScript.g:185:25: ( LT )* while True: #loop101 alt101 = 2 LA101_0 = self.input.LA(1) if (LA101_0 == LT) : LA101_2 = self.input.LA(2) if (self.synpred121_JavaScript()) : alt101 = 1 if alt101 == 1: # JavaScript.g:0:0: LT pass LT214=self.match(self.input, LT, self.FOLLOW_LT_in_defaultClause1112) else: break #loop101 # JavaScript.g:185:28: ( statementList )? alt102 = 2 LA102_0 = self.input.LA(1) if ((Identifier <= LA102_0 <= NumericLiteral) or (31 <= LA102_0 <= 32) or LA102_0 == 35 or (37 <= LA102_0 <= 38) or LA102_0 == 40 or (42 <= LA102_0 <= 44) or (46 <= LA102_0 <= 49) or LA102_0 == 51 or (54 <= LA102_0 <= 55) or (58 <= LA102_0 <= 59) or (91 <= LA102_0 <= 92) or (96 <= LA102_0 <= 106)) : alt102 = 1 if alt102 == 1: # JavaScript.g:0:0: statementList pass self._state.following.append(self.FOLLOW_statementList_in_defaultClause1116) statementList215 = self.statementList() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statementList215.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 36, defaultClause_StartIndex, success) pass return retval # $ANTLR end "defaultClause" class throwStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.throwStatement_return, self).__init__() self.tree = None # $ANTLR start "throwStatement" # JavaScript.g:188:1: throwStatement : 'throw' expression ( LT | ';' ) ; def throwStatement(self, ): retval = self.throwStatement_return() retval.start = self.input.LT(1) throwStatement_StartIndex = self.input.index() root_0 = None string_literal216 = None set218 = None expression217 = None string_literal216_tree = None set218_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 37): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:189:2: ( 'throw' expression ( LT | ';' ) ) # JavaScript.g:189:4: 'throw' expression ( LT | ';' ) pass root_0 = self._adaptor.nil() string_literal216=self.match(self.input, 54, self.FOLLOW_54_in_throwStatement1129) if self._state.backtracking == 0: string_literal216_tree = self._adaptor.createWithPayload(string_literal216) self._adaptor.addChild(root_0, string_literal216_tree) self._state.following.append(self.FOLLOW_expression_in_throwStatement1131) expression217 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression217.tree) set218 = self.input.LT(1) if self.input.LA(1) == LT or self.input.LA(1) == 38: self.input.consume() self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 37, throwStatement_StartIndex, success) pass return retval # $ANTLR end "throwStatement" class tryStatement_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.tryStatement_return, self).__init__() self.tree = None # $ANTLR start "tryStatement" # JavaScript.g:192:1: tryStatement : 'try' ( LT )* statementBlock ( LT )* ( finallyClause | catchClause ( ( LT )* finallyClause )? ) ; def tryStatement(self, ): retval = self.tryStatement_return() retval.start = self.input.LT(1) tryStatement_StartIndex = self.input.index() root_0 = None string_literal219 = None LT220 = None LT222 = None LT225 = None statementBlock221 = None finallyClause223 = None catchClause224 = None finallyClause226 = None string_literal219_tree = None LT220_tree = None LT222_tree = None LT225_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 38): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:193:2: ( 'try' ( LT )* statementBlock ( LT )* ( finallyClause | catchClause ( ( LT )* finallyClause )? ) ) # JavaScript.g:193:4: 'try' ( LT )* statementBlock ( LT )* ( finallyClause | catchClause ( ( LT )* finallyClause )? ) pass root_0 = self._adaptor.nil() string_literal219=self.match(self.input, 55, self.FOLLOW_55_in_tryStatement1151) if self._state.backtracking == 0: string_literal219_tree = self._adaptor.createWithPayload(string_literal219) self._adaptor.addChild(root_0, string_literal219_tree) # JavaScript.g:193:12: ( LT )* while True: #loop103 alt103 = 2 LA103_0 = self.input.LA(1) if (LA103_0 == LT) : alt103 = 1 if alt103 == 1: # JavaScript.g:0:0: LT pass LT220=self.match(self.input, LT, self.FOLLOW_LT_in_tryStatement1153) else: break #loop103 self._state.following.append(self.FOLLOW_statementBlock_in_tryStatement1157) statementBlock221 = self.statementBlock() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statementBlock221.tree) # JavaScript.g:193:32: ( LT )* while True: #loop104 alt104 = 2 LA104_0 = self.input.LA(1) if (LA104_0 == LT) : alt104 = 1 if alt104 == 1: # JavaScript.g:0:0: LT pass LT222=self.match(self.input, LT, self.FOLLOW_LT_in_tryStatement1159) else: break #loop104 # JavaScript.g:193:35: ( finallyClause | catchClause ( ( LT )* finallyClause )? ) alt107 = 2 LA107_0 = self.input.LA(1) if (LA107_0 == 57) : alt107 = 1 elif (LA107_0 == 56) : alt107 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 107, 0, self.input) raise nvae if alt107 == 1: # JavaScript.g:193:36: finallyClause pass self._state.following.append(self.FOLLOW_finallyClause_in_tryStatement1164) finallyClause223 = self.finallyClause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, finallyClause223.tree) elif alt107 == 2: # JavaScript.g:193:52: catchClause ( ( LT )* finallyClause )? pass self._state.following.append(self.FOLLOW_catchClause_in_tryStatement1168) catchClause224 = self.catchClause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, catchClause224.tree) # JavaScript.g:193:64: ( ( LT )* finallyClause )? alt106 = 2 alt106 = self.dfa106.predict(self.input) if alt106 == 1: # JavaScript.g:193:65: ( LT )* finallyClause pass # JavaScript.g:193:67: ( LT )* while True: #loop105 alt105 = 2 LA105_0 = self.input.LA(1) if (LA105_0 == LT) : alt105 = 1 if alt105 == 1: # JavaScript.g:0:0: LT pass LT225=self.match(self.input, LT, self.FOLLOW_LT_in_tryStatement1171) else: break #loop105 self._state.following.append(self.FOLLOW_finallyClause_in_tryStatement1175) finallyClause226 = self.finallyClause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, finallyClause226.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 38, tryStatement_StartIndex, success) pass return retval # $ANTLR end "tryStatement" class catchClause_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.catchClause_return, self).__init__() self.tree = None # $ANTLR start "catchClause" # JavaScript.g:196:1: catchClause : 'catch' ( LT )* '(' ( LT )* Identifier ( LT )* ')' ( LT )* statementBlock ; def catchClause(self, ): retval = self.catchClause_return() retval.start = self.input.LT(1) catchClause_StartIndex = self.input.index() root_0 = None string_literal227 = None LT228 = None char_literal229 = None LT230 = None Identifier231 = None LT232 = None char_literal233 = None LT234 = None statementBlock235 = None string_literal227_tree = None LT228_tree = None char_literal229_tree = None LT230_tree = None Identifier231_tree = None LT232_tree = None char_literal233_tree = None LT234_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 39): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:197:2: ( 'catch' ( LT )* '(' ( LT )* Identifier ( LT )* ')' ( LT )* statementBlock ) # JavaScript.g:197:4: 'catch' ( LT )* '(' ( LT )* Identifier ( LT )* ')' ( LT )* statementBlock pass root_0 = self._adaptor.nil() string_literal227=self.match(self.input, 56, self.FOLLOW_56_in_catchClause1196) if self._state.backtracking == 0: string_literal227_tree = self._adaptor.createWithPayload(string_literal227) self._adaptor.addChild(root_0, string_literal227_tree) # JavaScript.g:197:14: ( LT )* while True: #loop108 alt108 = 2 LA108_0 = self.input.LA(1) if (LA108_0 == LT) : alt108 = 1 if alt108 == 1: # JavaScript.g:0:0: LT pass LT228=self.match(self.input, LT, self.FOLLOW_LT_in_catchClause1198) else: break #loop108 char_literal229=self.match(self.input, 32, self.FOLLOW_32_in_catchClause1202) if self._state.backtracking == 0: char_literal229_tree = self._adaptor.createWithPayload(char_literal229) self._adaptor.addChild(root_0, char_literal229_tree) # JavaScript.g:197:23: ( LT )* while True: #loop109 alt109 = 2 LA109_0 = self.input.LA(1) if (LA109_0 == LT) : alt109 = 1 if alt109 == 1: # JavaScript.g:0:0: LT pass LT230=self.match(self.input, LT, self.FOLLOW_LT_in_catchClause1204) else: break #loop109 Identifier231=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_catchClause1208) if self._state.backtracking == 0: Identifier231_tree = self._adaptor.createWithPayload(Identifier231) self._adaptor.addChild(root_0, Identifier231_tree) # JavaScript.g:197:39: ( LT )* while True: #loop110 alt110 = 2 LA110_0 = self.input.LA(1) if (LA110_0 == LT) : alt110 = 1 if alt110 == 1: # JavaScript.g:0:0: LT pass LT232=self.match(self.input, LT, self.FOLLOW_LT_in_catchClause1210) else: break #loop110 char_literal233=self.match(self.input, 34, self.FOLLOW_34_in_catchClause1214) if self._state.backtracking == 0: char_literal233_tree = self._adaptor.createWithPayload(char_literal233) self._adaptor.addChild(root_0, char_literal233_tree) # JavaScript.g:197:48: ( LT )* while True: #loop111 alt111 = 2 LA111_0 = self.input.LA(1) if (LA111_0 == LT) : alt111 = 1 if alt111 == 1: # JavaScript.g:0:0: LT pass LT234=self.match(self.input, LT, self.FOLLOW_LT_in_catchClause1216) else: break #loop111 self._state.following.append(self.FOLLOW_statementBlock_in_catchClause1220) statementBlock235 = self.statementBlock() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statementBlock235.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 39, catchClause_StartIndex, success) pass return retval # $ANTLR end "catchClause" class finallyClause_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.finallyClause_return, self).__init__() self.tree = None # $ANTLR start "finallyClause" # JavaScript.g:200:1: finallyClause : 'finally' ( LT )* statementBlock ; def finallyClause(self, ): retval = self.finallyClause_return() retval.start = self.input.LT(1) finallyClause_StartIndex = self.input.index() root_0 = None string_literal236 = None LT237 = None statementBlock238 = None string_literal236_tree = None LT237_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 40): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:201:2: ( 'finally' ( LT )* statementBlock ) # JavaScript.g:201:4: 'finally' ( LT )* statementBlock pass root_0 = self._adaptor.nil() string_literal236=self.match(self.input, 57, self.FOLLOW_57_in_finallyClause1232) if self._state.backtracking == 0: string_literal236_tree = self._adaptor.createWithPayload(string_literal236) self._adaptor.addChild(root_0, string_literal236_tree) # JavaScript.g:201:16: ( LT )* while True: #loop112 alt112 = 2 LA112_0 = self.input.LA(1) if (LA112_0 == LT) : alt112 = 1 if alt112 == 1: # JavaScript.g:0:0: LT pass LT237=self.match(self.input, LT, self.FOLLOW_LT_in_finallyClause1234) else: break #loop112 self._state.following.append(self.FOLLOW_statementBlock_in_finallyClause1238) statementBlock238 = self.statementBlock() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, statementBlock238.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 40, finallyClause_StartIndex, success) pass return retval # $ANTLR end "finallyClause" class expression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.expression_return, self).__init__() self.tree = None # $ANTLR start "expression" # JavaScript.g:205:1: expression : assignmentExpression ( ( LT )* ',' ( LT )* assignmentExpression )* ; def expression(self, ): retval = self.expression_return() retval.start = self.input.LT(1) expression_StartIndex = self.input.index() root_0 = None LT240 = None char_literal241 = None LT242 = None assignmentExpression239 = None assignmentExpression243 = None LT240_tree = None char_literal241_tree = None LT242_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 41): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:206:2: ( assignmentExpression ( ( LT )* ',' ( LT )* assignmentExpression )* ) # JavaScript.g:206:4: assignmentExpression ( ( LT )* ',' ( LT )* assignmentExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_assignmentExpression_in_expression1250) assignmentExpression239 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression239.tree) # JavaScript.g:206:25: ( ( LT )* ',' ( LT )* assignmentExpression )* while True: #loop115 alt115 = 2 alt115 = self.dfa115.predict(self.input) if alt115 == 1: # JavaScript.g:206:26: ( LT )* ',' ( LT )* assignmentExpression pass # JavaScript.g:206:28: ( LT )* while True: #loop113 alt113 = 2 LA113_0 = self.input.LA(1) if (LA113_0 == LT) : alt113 = 1 if alt113 == 1: # JavaScript.g:0:0: LT pass LT240=self.match(self.input, LT, self.FOLLOW_LT_in_expression1253) else: break #loop113 char_literal241=self.match(self.input, 33, self.FOLLOW_33_in_expression1257) if self._state.backtracking == 0: char_literal241_tree = self._adaptor.createWithPayload(char_literal241) self._adaptor.addChild(root_0, char_literal241_tree) # JavaScript.g:206:37: ( LT )* while True: #loop114 alt114 = 2 LA114_0 = self.input.LA(1) if (LA114_0 == LT) : alt114 = 1 if alt114 == 1: # JavaScript.g:0:0: LT pass LT242=self.match(self.input, LT, self.FOLLOW_LT_in_expression1259) else: break #loop114 self._state.following.append(self.FOLLOW_assignmentExpression_in_expression1263) assignmentExpression243 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression243.tree) else: break #loop115 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 41, expression_StartIndex, success) pass return retval # $ANTLR end "expression" class expressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.expressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "expressionNoIn" # JavaScript.g:209:1: expressionNoIn : assignmentExpressionNoIn ( ( LT )* ',' ( LT )* assignmentExpressionNoIn )* ; def expressionNoIn(self, ): retval = self.expressionNoIn_return() retval.start = self.input.LT(1) expressionNoIn_StartIndex = self.input.index() root_0 = None LT245 = None char_literal246 = None LT247 = None assignmentExpressionNoIn244 = None assignmentExpressionNoIn248 = None LT245_tree = None char_literal246_tree = None LT247_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 42): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:210:2: ( assignmentExpressionNoIn ( ( LT )* ',' ( LT )* assignmentExpressionNoIn )* ) # JavaScript.g:210:4: assignmentExpressionNoIn ( ( LT )* ',' ( LT )* assignmentExpressionNoIn )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_assignmentExpressionNoIn_in_expressionNoIn1277) assignmentExpressionNoIn244 = self.assignmentExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpressionNoIn244.tree) # JavaScript.g:210:29: ( ( LT )* ',' ( LT )* assignmentExpressionNoIn )* while True: #loop118 alt118 = 2 alt118 = self.dfa118.predict(self.input) if alt118 == 1: # JavaScript.g:210:30: ( LT )* ',' ( LT )* assignmentExpressionNoIn pass # JavaScript.g:210:32: ( LT )* while True: #loop116 alt116 = 2 LA116_0 = self.input.LA(1) if (LA116_0 == LT) : alt116 = 1 if alt116 == 1: # JavaScript.g:0:0: LT pass LT245=self.match(self.input, LT, self.FOLLOW_LT_in_expressionNoIn1280) else: break #loop116 char_literal246=self.match(self.input, 33, self.FOLLOW_33_in_expressionNoIn1284) if self._state.backtracking == 0: char_literal246_tree = self._adaptor.createWithPayload(char_literal246) self._adaptor.addChild(root_0, char_literal246_tree) # JavaScript.g:210:41: ( LT )* while True: #loop117 alt117 = 2 LA117_0 = self.input.LA(1) if (LA117_0 == LT) : alt117 = 1 if alt117 == 1: # JavaScript.g:0:0: LT pass LT247=self.match(self.input, LT, self.FOLLOW_LT_in_expressionNoIn1286) else: break #loop117 self._state.following.append(self.FOLLOW_assignmentExpressionNoIn_in_expressionNoIn1290) assignmentExpressionNoIn248 = self.assignmentExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpressionNoIn248.tree) else: break #loop118 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 42, expressionNoIn_StartIndex, success) pass return retval # $ANTLR end "expressionNoIn" class assignmentExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.assignmentExpression_return, self).__init__() self.tree = None # $ANTLR start "assignmentExpression" # JavaScript.g:213:1: assignmentExpression : ( conditionalExpression | leftHandSideExpression ( LT )* assignmentOperator ( LT )* assignmentExpression ); def assignmentExpression(self, ): retval = self.assignmentExpression_return() retval.start = self.input.LT(1) assignmentExpression_StartIndex = self.input.index() root_0 = None LT251 = None LT253 = None conditionalExpression249 = None leftHandSideExpression250 = None assignmentOperator252 = None assignmentExpression254 = None LT251_tree = None LT253_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 43): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:214:2: ( conditionalExpression | leftHandSideExpression ( LT )* assignmentOperator ( LT )* assignmentExpression ) alt121 = 2 alt121 = self.dfa121.predict(self.input) if alt121 == 1: # JavaScript.g:214:4: conditionalExpression pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_conditionalExpression_in_assignmentExpression1304) conditionalExpression249 = self.conditionalExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, conditionalExpression249.tree) elif alt121 == 2: # JavaScript.g:215:4: leftHandSideExpression ( LT )* assignmentOperator ( LT )* assignmentExpression pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_leftHandSideExpression_in_assignmentExpression1309) leftHandSideExpression250 = self.leftHandSideExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, leftHandSideExpression250.tree) # JavaScript.g:215:29: ( LT )* while True: #loop119 alt119 = 2 LA119_0 = self.input.LA(1) if (LA119_0 == LT) : alt119 = 1 if alt119 == 1: # JavaScript.g:0:0: LT pass LT251=self.match(self.input, LT, self.FOLLOW_LT_in_assignmentExpression1311) else: break #loop119 self._state.following.append(self.FOLLOW_assignmentOperator_in_assignmentExpression1315) assignmentOperator252 = self.assignmentOperator() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentOperator252.tree) # JavaScript.g:215:53: ( LT )* while True: #loop120 alt120 = 2 LA120_0 = self.input.LA(1) if (LA120_0 == LT) : alt120 = 1 if alt120 == 1: # JavaScript.g:0:0: LT pass LT253=self.match(self.input, LT, self.FOLLOW_LT_in_assignmentExpression1317) else: break #loop120 self._state.following.append(self.FOLLOW_assignmentExpression_in_assignmentExpression1321) assignmentExpression254 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression254.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 43, assignmentExpression_StartIndex, success) pass return retval # $ANTLR end "assignmentExpression" class assignmentExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.assignmentExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "assignmentExpressionNoIn" # JavaScript.g:218:1: assignmentExpressionNoIn : ( conditionalExpressionNoIn | leftHandSideExpression ( LT )* assignmentOperator ( LT )* assignmentExpressionNoIn ); def assignmentExpressionNoIn(self, ): retval = self.assignmentExpressionNoIn_return() retval.start = self.input.LT(1) assignmentExpressionNoIn_StartIndex = self.input.index() root_0 = None LT257 = None LT259 = None conditionalExpressionNoIn255 = None leftHandSideExpression256 = None assignmentOperator258 = None assignmentExpressionNoIn260 = None LT257_tree = None LT259_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 44): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:219:2: ( conditionalExpressionNoIn | leftHandSideExpression ( LT )* assignmentOperator ( LT )* assignmentExpressionNoIn ) alt124 = 2 alt124 = self.dfa124.predict(self.input) if alt124 == 1: # JavaScript.g:219:4: conditionalExpressionNoIn pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_conditionalExpressionNoIn_in_assignmentExpressionNoIn1333) conditionalExpressionNoIn255 = self.conditionalExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, conditionalExpressionNoIn255.tree) elif alt124 == 2: # JavaScript.g:220:4: leftHandSideExpression ( LT )* assignmentOperator ( LT )* assignmentExpressionNoIn pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_leftHandSideExpression_in_assignmentExpressionNoIn1338) leftHandSideExpression256 = self.leftHandSideExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, leftHandSideExpression256.tree) # JavaScript.g:220:29: ( LT )* while True: #loop122 alt122 = 2 LA122_0 = self.input.LA(1) if (LA122_0 == LT) : alt122 = 1 if alt122 == 1: # JavaScript.g:0:0: LT pass LT257=self.match(self.input, LT, self.FOLLOW_LT_in_assignmentExpressionNoIn1340) else: break #loop122 self._state.following.append(self.FOLLOW_assignmentOperator_in_assignmentExpressionNoIn1344) assignmentOperator258 = self.assignmentOperator() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentOperator258.tree) # JavaScript.g:220:53: ( LT )* while True: #loop123 alt123 = 2 LA123_0 = self.input.LA(1) if (LA123_0 == LT) : alt123 = 1 if alt123 == 1: # JavaScript.g:0:0: LT pass LT259=self.match(self.input, LT, self.FOLLOW_LT_in_assignmentExpressionNoIn1346) else: break #loop123 self._state.following.append(self.FOLLOW_assignmentExpressionNoIn_in_assignmentExpressionNoIn1350) assignmentExpressionNoIn260 = self.assignmentExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpressionNoIn260.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 44, assignmentExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "assignmentExpressionNoIn" class leftHandSideExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.leftHandSideExpression_return, self).__init__() self.tree = None # $ANTLR start "leftHandSideExpression" # JavaScript.g:223:1: leftHandSideExpression : ( callExpression | newExpression ); def leftHandSideExpression(self, ): retval = self.leftHandSideExpression_return() retval.start = self.input.LT(1) leftHandSideExpression_StartIndex = self.input.index() root_0 = None callExpression261 = None newExpression262 = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 45): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:224:2: ( callExpression | newExpression ) alt125 = 2 alt125 = self.dfa125.predict(self.input) if alt125 == 1: # JavaScript.g:224:4: callExpression pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_callExpression_in_leftHandSideExpression1362) callExpression261 = self.callExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, callExpression261.tree) elif alt125 == 2: # JavaScript.g:225:4: newExpression pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_newExpression_in_leftHandSideExpression1367) newExpression262 = self.newExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, newExpression262.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 45, leftHandSideExpression_StartIndex, success) pass return retval # $ANTLR end "leftHandSideExpression" class newExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.newExpression_return, self).__init__() self.tree = None # $ANTLR start "newExpression" # JavaScript.g:228:1: newExpression : ( memberExpression | 'new' ( LT )* newExpression ); def newExpression(self, ): retval = self.newExpression_return() retval.start = self.input.LT(1) newExpression_StartIndex = self.input.index() root_0 = None string_literal264 = None LT265 = None memberExpression263 = None newExpression266 = None string_literal264_tree = None LT265_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 46): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:229:2: ( memberExpression | 'new' ( LT )* newExpression ) alt127 = 2 alt127 = self.dfa127.predict(self.input) if alt127 == 1: # JavaScript.g:229:4: memberExpression pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_memberExpression_in_newExpression1379) memberExpression263 = self.memberExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, memberExpression263.tree) elif alt127 == 2: # JavaScript.g:230:4: 'new' ( LT )* newExpression pass root_0 = self._adaptor.nil() string_literal264=self.match(self.input, 58, self.FOLLOW_58_in_newExpression1384) if self._state.backtracking == 0: string_literal264_tree = self._adaptor.createWithPayload(string_literal264) self._adaptor.addChild(root_0, string_literal264_tree) # JavaScript.g:230:12: ( LT )* while True: #loop126 alt126 = 2 LA126_0 = self.input.LA(1) if (LA126_0 == LT) : alt126 = 1 if alt126 == 1: # JavaScript.g:0:0: LT pass LT265=self.match(self.input, LT, self.FOLLOW_LT_in_newExpression1386) else: break #loop126 self._state.following.append(self.FOLLOW_newExpression_in_newExpression1390) newExpression266 = self.newExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, newExpression266.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 46, newExpression_StartIndex, success) pass return retval # $ANTLR end "newExpression" class memberExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.memberExpression_return, self).__init__() self.tree = None # $ANTLR start "memberExpression" # JavaScript.g:233:1: memberExpression : ( primaryExpression | functionExpression | 'new' ( LT )* memberExpression ( LT )* arguments ) ( ( LT )* memberExpressionSuffix )* ; def memberExpression(self, ): retval = self.memberExpression_return() retval.start = self.input.LT(1) memberExpression_StartIndex = self.input.index() root_0 = None string_literal269 = None LT270 = None LT272 = None LT274 = None primaryExpression267 = None functionExpression268 = None memberExpression271 = None arguments273 = None memberExpressionSuffix275 = None string_literal269_tree = None LT270_tree = None LT272_tree = None LT274_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 47): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:234:2: ( ( primaryExpression | functionExpression | 'new' ( LT )* memberExpression ( LT )* arguments ) ( ( LT )* memberExpressionSuffix )* ) # JavaScript.g:234:4: ( primaryExpression | functionExpression | 'new' ( LT )* memberExpression ( LT )* arguments ) ( ( LT )* memberExpressionSuffix )* pass root_0 = self._adaptor.nil() # JavaScript.g:234:4: ( primaryExpression | functionExpression | 'new' ( LT )* memberExpression ( LT )* arguments ) alt130 = 3 LA130 = self.input.LA(1) if LA130 == Identifier or LA130 == StringLiteral or LA130 == NumericLiteral or LA130 == 32 or LA130 == 35 or LA130 == 59 or LA130 == 103 or LA130 == 104 or LA130 == 105 or LA130 == 106: alt130 = 1 elif LA130 == 31: alt130 = 2 elif LA130 == 58: alt130 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 130, 0, self.input) raise nvae if alt130 == 1: # JavaScript.g:234:5: primaryExpression pass self._state.following.append(self.FOLLOW_primaryExpression_in_memberExpression1403) primaryExpression267 = self.primaryExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, primaryExpression267.tree) elif alt130 == 2: # JavaScript.g:234:25: functionExpression pass self._state.following.append(self.FOLLOW_functionExpression_in_memberExpression1407) functionExpression268 = self.functionExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, functionExpression268.tree) elif alt130 == 3: # JavaScript.g:234:46: 'new' ( LT )* memberExpression ( LT )* arguments pass string_literal269=self.match(self.input, 58, self.FOLLOW_58_in_memberExpression1411) if self._state.backtracking == 0: string_literal269_tree = self._adaptor.createWithPayload(string_literal269) self._adaptor.addChild(root_0, string_literal269_tree) # JavaScript.g:234:54: ( LT )* while True: #loop128 alt128 = 2 LA128_0 = self.input.LA(1) if (LA128_0 == LT) : alt128 = 1 if alt128 == 1: # JavaScript.g:0:0: LT pass LT270=self.match(self.input, LT, self.FOLLOW_LT_in_memberExpression1413) else: break #loop128 self._state.following.append(self.FOLLOW_memberExpression_in_memberExpression1417) memberExpression271 = self.memberExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, memberExpression271.tree) # JavaScript.g:234:76: ( LT )* while True: #loop129 alt129 = 2 LA129_0 = self.input.LA(1) if (LA129_0 == LT) : alt129 = 1 if alt129 == 1: # JavaScript.g:0:0: LT pass LT272=self.match(self.input, LT, self.FOLLOW_LT_in_memberExpression1419) else: break #loop129 self._state.following.append(self.FOLLOW_arguments_in_memberExpression1423) arguments273 = self.arguments() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, arguments273.tree) # JavaScript.g:234:90: ( ( LT )* memberExpressionSuffix )* while True: #loop132 alt132 = 2 alt132 = self.dfa132.predict(self.input) if alt132 == 1: # JavaScript.g:234:91: ( LT )* memberExpressionSuffix pass # JavaScript.g:234:93: ( LT )* while True: #loop131 alt131 = 2 LA131_0 = self.input.LA(1) if (LA131_0 == LT) : alt131 = 1 if alt131 == 1: # JavaScript.g:0:0: LT pass LT274=self.match(self.input, LT, self.FOLLOW_LT_in_memberExpression1427) else: break #loop131 self._state.following.append(self.FOLLOW_memberExpressionSuffix_in_memberExpression1431) memberExpressionSuffix275 = self.memberExpressionSuffix() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, memberExpressionSuffix275.tree) else: break #loop132 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 47, memberExpression_StartIndex, success) pass return retval # $ANTLR end "memberExpression" class memberExpressionSuffix_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.memberExpressionSuffix_return, self).__init__() self.tree = None # $ANTLR start "memberExpressionSuffix" # JavaScript.g:237:1: memberExpressionSuffix : ( indexSuffix | propertyReferenceSuffix ); def memberExpressionSuffix(self, ): retval = self.memberExpressionSuffix_return() retval.start = self.input.LT(1) memberExpressionSuffix_StartIndex = self.input.index() root_0 = None indexSuffix276 = None propertyReferenceSuffix277 = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 48): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:238:2: ( indexSuffix | propertyReferenceSuffix ) alt133 = 2 LA133_0 = self.input.LA(1) if (LA133_0 == 59) : alt133 = 1 elif (LA133_0 == 61) : alt133 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 133, 0, self.input) raise nvae if alt133 == 1: # JavaScript.g:238:4: indexSuffix pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_indexSuffix_in_memberExpressionSuffix1445) indexSuffix276 = self.indexSuffix() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, indexSuffix276.tree) elif alt133 == 2: # JavaScript.g:239:4: propertyReferenceSuffix pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_propertyReferenceSuffix_in_memberExpressionSuffix1450) propertyReferenceSuffix277 = self.propertyReferenceSuffix() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, propertyReferenceSuffix277.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 48, memberExpressionSuffix_StartIndex, success) pass return retval # $ANTLR end "memberExpressionSuffix" class callExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.callExpression_return, self).__init__() self.tree = None # $ANTLR start "callExpression" # JavaScript.g:242:1: callExpression : memberExpression ( LT )* arguments ( ( LT )* callExpressionSuffix )* ; def callExpression(self, ): retval = self.callExpression_return() retval.start = self.input.LT(1) callExpression_StartIndex = self.input.index() root_0 = None LT279 = None LT281 = None memberExpression278 = None arguments280 = None callExpressionSuffix282 = None LT279_tree = None LT281_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 49): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:243:2: ( memberExpression ( LT )* arguments ( ( LT )* callExpressionSuffix )* ) # JavaScript.g:243:4: memberExpression ( LT )* arguments ( ( LT )* callExpressionSuffix )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_memberExpression_in_callExpression1461) memberExpression278 = self.memberExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, memberExpression278.tree) # JavaScript.g:243:23: ( LT )* while True: #loop134 alt134 = 2 LA134_0 = self.input.LA(1) if (LA134_0 == LT) : alt134 = 1 if alt134 == 1: # JavaScript.g:0:0: LT pass LT279=self.match(self.input, LT, self.FOLLOW_LT_in_callExpression1463) else: break #loop134 self._state.following.append(self.FOLLOW_arguments_in_callExpression1467) arguments280 = self.arguments() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, arguments280.tree) # JavaScript.g:243:36: ( ( LT )* callExpressionSuffix )* while True: #loop136 alt136 = 2 alt136 = self.dfa136.predict(self.input) if alt136 == 1: # JavaScript.g:243:37: ( LT )* callExpressionSuffix pass # JavaScript.g:243:39: ( LT )* while True: #loop135 alt135 = 2 LA135_0 = self.input.LA(1) if (LA135_0 == LT) : alt135 = 1 if alt135 == 1: # JavaScript.g:0:0: LT pass LT281=self.match(self.input, LT, self.FOLLOW_LT_in_callExpression1470) else: break #loop135 self._state.following.append(self.FOLLOW_callExpressionSuffix_in_callExpression1474) callExpressionSuffix282 = self.callExpressionSuffix() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, callExpressionSuffix282.tree) else: break #loop136 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 49, callExpression_StartIndex, success) pass return retval # $ANTLR end "callExpression" class callExpressionSuffix_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.callExpressionSuffix_return, self).__init__() self.tree = None # $ANTLR start "callExpressionSuffix" # JavaScript.g:246:1: callExpressionSuffix : ( arguments | indexSuffix | propertyReferenceSuffix ); def callExpressionSuffix(self, ): retval = self.callExpressionSuffix_return() retval.start = self.input.LT(1) callExpressionSuffix_StartIndex = self.input.index() root_0 = None arguments283 = None indexSuffix284 = None propertyReferenceSuffix285 = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 50): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:247:2: ( arguments | indexSuffix | propertyReferenceSuffix ) alt137 = 3 LA137 = self.input.LA(1) if LA137 == 32: alt137 = 1 elif LA137 == 59: alt137 = 2 elif LA137 == 61: alt137 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 137, 0, self.input) raise nvae if alt137 == 1: # JavaScript.g:247:4: arguments pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_arguments_in_callExpressionSuffix1488) arguments283 = self.arguments() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, arguments283.tree) elif alt137 == 2: # JavaScript.g:248:4: indexSuffix pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_indexSuffix_in_callExpressionSuffix1493) indexSuffix284 = self.indexSuffix() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, indexSuffix284.tree) elif alt137 == 3: # JavaScript.g:249:4: propertyReferenceSuffix pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_propertyReferenceSuffix_in_callExpressionSuffix1498) propertyReferenceSuffix285 = self.propertyReferenceSuffix() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, propertyReferenceSuffix285.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 50, callExpressionSuffix_StartIndex, success) pass return retval # $ANTLR end "callExpressionSuffix" class arguments_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.arguments_return, self).__init__() self.tree = None # $ANTLR start "arguments" # JavaScript.g:252:1: arguments : '(' ( ( LT )* assignmentExpression ( ( LT )* ',' ( LT )* assignmentExpression )* )? ( LT )* ')' ; def arguments(self, ): retval = self.arguments_return() retval.start = self.input.LT(1) arguments_StartIndex = self.input.index() root_0 = None char_literal286 = None LT287 = None LT289 = None char_literal290 = None LT291 = None LT293 = None char_literal294 = None assignmentExpression288 = None assignmentExpression292 = None char_literal286_tree = None LT287_tree = None LT289_tree = None char_literal290_tree = None LT291_tree = None LT293_tree = None char_literal294_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 51): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:253:2: ( '(' ( ( LT )* assignmentExpression ( ( LT )* ',' ( LT )* assignmentExpression )* )? ( LT )* ')' ) # JavaScript.g:253:4: '(' ( ( LT )* assignmentExpression ( ( LT )* ',' ( LT )* assignmentExpression )* )? ( LT )* ')' pass root_0 = self._adaptor.nil() char_literal286=self.match(self.input, 32, self.FOLLOW_32_in_arguments1509) if self._state.backtracking == 0: char_literal286_tree = self._adaptor.createWithPayload(char_literal286) self._adaptor.addChild(root_0, char_literal286_tree) # JavaScript.g:253:8: ( ( LT )* assignmentExpression ( ( LT )* ',' ( LT )* assignmentExpression )* )? alt142 = 2 alt142 = self.dfa142.predict(self.input) if alt142 == 1: # JavaScript.g:253:9: ( LT )* assignmentExpression ( ( LT )* ',' ( LT )* assignmentExpression )* pass # JavaScript.g:253:11: ( LT )* while True: #loop138 alt138 = 2 LA138_0 = self.input.LA(1) if (LA138_0 == LT) : alt138 = 1 if alt138 == 1: # JavaScript.g:0:0: LT pass LT287=self.match(self.input, LT, self.FOLLOW_LT_in_arguments1512) else: break #loop138 self._state.following.append(self.FOLLOW_assignmentExpression_in_arguments1516) assignmentExpression288 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression288.tree) # JavaScript.g:253:35: ( ( LT )* ',' ( LT )* assignmentExpression )* while True: #loop141 alt141 = 2 alt141 = self.dfa141.predict(self.input) if alt141 == 1: # JavaScript.g:253:36: ( LT )* ',' ( LT )* assignmentExpression pass # JavaScript.g:253:38: ( LT )* while True: #loop139 alt139 = 2 LA139_0 = self.input.LA(1) if (LA139_0 == LT) : alt139 = 1 if alt139 == 1: # JavaScript.g:0:0: LT pass LT289=self.match(self.input, LT, self.FOLLOW_LT_in_arguments1519) else: break #loop139 char_literal290=self.match(self.input, 33, self.FOLLOW_33_in_arguments1523) if self._state.backtracking == 0: char_literal290_tree = self._adaptor.createWithPayload(char_literal290) self._adaptor.addChild(root_0, char_literal290_tree) # JavaScript.g:253:47: ( LT )* while True: #loop140 alt140 = 2 LA140_0 = self.input.LA(1) if (LA140_0 == LT) : alt140 = 1 if alt140 == 1: # JavaScript.g:0:0: LT pass LT291=self.match(self.input, LT, self.FOLLOW_LT_in_arguments1525) else: break #loop140 self._state.following.append(self.FOLLOW_assignmentExpression_in_arguments1529) assignmentExpression292 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression292.tree) else: break #loop141 # JavaScript.g:253:77: ( LT )* while True: #loop143 alt143 = 2 LA143_0 = self.input.LA(1) if (LA143_0 == LT) : alt143 = 1 if alt143 == 1: # JavaScript.g:0:0: LT pass LT293=self.match(self.input, LT, self.FOLLOW_LT_in_arguments1535) else: break #loop143 char_literal294=self.match(self.input, 34, self.FOLLOW_34_in_arguments1539) if self._state.backtracking == 0: char_literal294_tree = self._adaptor.createWithPayload(char_literal294) self._adaptor.addChild(root_0, char_literal294_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 51, arguments_StartIndex, success) pass return retval # $ANTLR end "arguments" class indexSuffix_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.indexSuffix_return, self).__init__() self.tree = None # $ANTLR start "indexSuffix" # JavaScript.g:256:1: indexSuffix : '[' ( LT )* expression ( LT )* ']' ; def indexSuffix(self, ): retval = self.indexSuffix_return() retval.start = self.input.LT(1) indexSuffix_StartIndex = self.input.index() root_0 = None char_literal295 = None LT296 = None LT298 = None char_literal299 = None expression297 = None char_literal295_tree = None LT296_tree = None LT298_tree = None char_literal299_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 52): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:257:2: ( '[' ( LT )* expression ( LT )* ']' ) # JavaScript.g:257:4: '[' ( LT )* expression ( LT )* ']' pass root_0 = self._adaptor.nil() char_literal295=self.match(self.input, 59, self.FOLLOW_59_in_indexSuffix1551) if self._state.backtracking == 0: char_literal295_tree = self._adaptor.createWithPayload(char_literal295) self._adaptor.addChild(root_0, char_literal295_tree) # JavaScript.g:257:10: ( LT )* while True: #loop144 alt144 = 2 LA144_0 = self.input.LA(1) if (LA144_0 == LT) : alt144 = 1 if alt144 == 1: # JavaScript.g:0:0: LT pass LT296=self.match(self.input, LT, self.FOLLOW_LT_in_indexSuffix1553) else: break #loop144 self._state.following.append(self.FOLLOW_expression_in_indexSuffix1557) expression297 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression297.tree) # JavaScript.g:257:26: ( LT )* while True: #loop145 alt145 = 2 LA145_0 = self.input.LA(1) if (LA145_0 == LT) : alt145 = 1 if alt145 == 1: # JavaScript.g:0:0: LT pass LT298=self.match(self.input, LT, self.FOLLOW_LT_in_indexSuffix1559) else: break #loop145 char_literal299=self.match(self.input, 60, self.FOLLOW_60_in_indexSuffix1563) if self._state.backtracking == 0: char_literal299_tree = self._adaptor.createWithPayload(char_literal299) self._adaptor.addChild(root_0, char_literal299_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 52, indexSuffix_StartIndex, success) pass return retval # $ANTLR end "indexSuffix" class propertyReferenceSuffix_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.propertyReferenceSuffix_return, self).__init__() self.tree = None # $ANTLR start "propertyReferenceSuffix" # JavaScript.g:260:1: propertyReferenceSuffix : '.' ( LT )* Identifier ; def propertyReferenceSuffix(self, ): retval = self.propertyReferenceSuffix_return() retval.start = self.input.LT(1) propertyReferenceSuffix_StartIndex = self.input.index() root_0 = None char_literal300 = None LT301 = None Identifier302 = None char_literal300_tree = None LT301_tree = None Identifier302_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 53): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:261:2: ( '.' ( LT )* Identifier ) # JavaScript.g:261:4: '.' ( LT )* Identifier pass root_0 = self._adaptor.nil() char_literal300=self.match(self.input, 61, self.FOLLOW_61_in_propertyReferenceSuffix1576) if self._state.backtracking == 0: char_literal300_tree = self._adaptor.createWithPayload(char_literal300) self._adaptor.addChild(root_0, char_literal300_tree) # JavaScript.g:261:10: ( LT )* while True: #loop146 alt146 = 2 LA146_0 = self.input.LA(1) if (LA146_0 == LT) : alt146 = 1 if alt146 == 1: # JavaScript.g:0:0: LT pass LT301=self.match(self.input, LT, self.FOLLOW_LT_in_propertyReferenceSuffix1578) else: break #loop146 Identifier302=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_propertyReferenceSuffix1582) if self._state.backtracking == 0: Identifier302_tree = self._adaptor.createWithPayload(Identifier302) self._adaptor.addChild(root_0, Identifier302_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 53, propertyReferenceSuffix_StartIndex, success) pass return retval # $ANTLR end "propertyReferenceSuffix" class assignmentOperator_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.assignmentOperator_return, self).__init__() self.tree = None # $ANTLR start "assignmentOperator" # JavaScript.g:264:1: assignmentOperator : ( '=' | '*=' | '/=' | '%=' | '+=' | '-=' | '<<=' | '>>=' | '>>>=' | '&=' | '^=' | '|=' ); def assignmentOperator(self, ): retval = self.assignmentOperator_return() retval.start = self.input.LT(1) assignmentOperator_StartIndex = self.input.index() root_0 = None set303 = None set303_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 54): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:265:2: ( '=' | '*=' | '/=' | '%=' | '+=' | '-=' | '<<=' | '>>=' | '>>>=' | '&=' | '^=' | '|=' ) # JavaScript.g: pass root_0 = self._adaptor.nil() set303 = self.input.LT(1) if self.input.LA(1) == 39 or (62 <= self.input.LA(1) <= 72): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set303)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 54, assignmentOperator_StartIndex, success) pass return retval # $ANTLR end "assignmentOperator" class conditionalExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.conditionalExpression_return, self).__init__() self.tree = None # $ANTLR start "conditionalExpression" # JavaScript.g:268:1: conditionalExpression : logicalORExpression ( ( LT )* '?' ( LT )* assignmentExpression ( LT )* ':' ( LT )* assignmentExpression )? ; def conditionalExpression(self, ): retval = self.conditionalExpression_return() retval.start = self.input.LT(1) conditionalExpression_StartIndex = self.input.index() root_0 = None LT305 = None char_literal306 = None LT307 = None LT309 = None char_literal310 = None LT311 = None logicalORExpression304 = None assignmentExpression308 = None assignmentExpression312 = None LT305_tree = None char_literal306_tree = None LT307_tree = None LT309_tree = None char_literal310_tree = None LT311_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 55): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:269:2: ( logicalORExpression ( ( LT )* '?' ( LT )* assignmentExpression ( LT )* ':' ( LT )* assignmentExpression )? ) # JavaScript.g:269:4: logicalORExpression ( ( LT )* '?' ( LT )* assignmentExpression ( LT )* ':' ( LT )* assignmentExpression )? pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_logicalORExpression_in_conditionalExpression1649) logicalORExpression304 = self.logicalORExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logicalORExpression304.tree) # JavaScript.g:269:24: ( ( LT )* '?' ( LT )* assignmentExpression ( LT )* ':' ( LT )* assignmentExpression )? alt151 = 2 alt151 = self.dfa151.predict(self.input) if alt151 == 1: # JavaScript.g:269:25: ( LT )* '?' ( LT )* assignmentExpression ( LT )* ':' ( LT )* assignmentExpression pass # JavaScript.g:269:27: ( LT )* while True: #loop147 alt147 = 2 LA147_0 = self.input.LA(1) if (LA147_0 == LT) : alt147 = 1 if alt147 == 1: # JavaScript.g:0:0: LT pass LT305=self.match(self.input, LT, self.FOLLOW_LT_in_conditionalExpression1652) else: break #loop147 char_literal306=self.match(self.input, 73, self.FOLLOW_73_in_conditionalExpression1656) if self._state.backtracking == 0: char_literal306_tree = self._adaptor.createWithPayload(char_literal306) self._adaptor.addChild(root_0, char_literal306_tree) # JavaScript.g:269:36: ( LT )* while True: #loop148 alt148 = 2 LA148_0 = self.input.LA(1) if (LA148_0 == LT) : alt148 = 1 if alt148 == 1: # JavaScript.g:0:0: LT pass LT307=self.match(self.input, LT, self.FOLLOW_LT_in_conditionalExpression1658) else: break #loop148 self._state.following.append(self.FOLLOW_assignmentExpression_in_conditionalExpression1662) assignmentExpression308 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression308.tree) # JavaScript.g:269:62: ( LT )* while True: #loop149 alt149 = 2 LA149_0 = self.input.LA(1) if (LA149_0 == LT) : alt149 = 1 if alt149 == 1: # JavaScript.g:0:0: LT pass LT309=self.match(self.input, LT, self.FOLLOW_LT_in_conditionalExpression1664) else: break #loop149 char_literal310=self.match(self.input, 50, self.FOLLOW_50_in_conditionalExpression1668) if self._state.backtracking == 0: char_literal310_tree = self._adaptor.createWithPayload(char_literal310) self._adaptor.addChild(root_0, char_literal310_tree) # JavaScript.g:269:71: ( LT )* while True: #loop150 alt150 = 2 LA150_0 = self.input.LA(1) if (LA150_0 == LT) : alt150 = 1 if alt150 == 1: # JavaScript.g:0:0: LT pass LT311=self.match(self.input, LT, self.FOLLOW_LT_in_conditionalExpression1670) else: break #loop150 self._state.following.append(self.FOLLOW_assignmentExpression_in_conditionalExpression1674) assignmentExpression312 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression312.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 55, conditionalExpression_StartIndex, success) pass return retval # $ANTLR end "conditionalExpression" class conditionalExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.conditionalExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "conditionalExpressionNoIn" # JavaScript.g:272:1: conditionalExpressionNoIn : logicalORExpressionNoIn ( ( LT )* '?' ( LT )* assignmentExpressionNoIn ( LT )* ':' ( LT )* assignmentExpressionNoIn )? ; def conditionalExpressionNoIn(self, ): retval = self.conditionalExpressionNoIn_return() retval.start = self.input.LT(1) conditionalExpressionNoIn_StartIndex = self.input.index() root_0 = None LT314 = None char_literal315 = None LT316 = None LT318 = None char_literal319 = None LT320 = None logicalORExpressionNoIn313 = None assignmentExpressionNoIn317 = None assignmentExpressionNoIn321 = None LT314_tree = None char_literal315_tree = None LT316_tree = None LT318_tree = None char_literal319_tree = None LT320_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 56): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:273:2: ( logicalORExpressionNoIn ( ( LT )* '?' ( LT )* assignmentExpressionNoIn ( LT )* ':' ( LT )* assignmentExpressionNoIn )? ) # JavaScript.g:273:4: logicalORExpressionNoIn ( ( LT )* '?' ( LT )* assignmentExpressionNoIn ( LT )* ':' ( LT )* assignmentExpressionNoIn )? pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_logicalORExpressionNoIn_in_conditionalExpressionNoIn1687) logicalORExpressionNoIn313 = self.logicalORExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logicalORExpressionNoIn313.tree) # JavaScript.g:273:28: ( ( LT )* '?' ( LT )* assignmentExpressionNoIn ( LT )* ':' ( LT )* assignmentExpressionNoIn )? alt156 = 2 alt156 = self.dfa156.predict(self.input) if alt156 == 1: # JavaScript.g:273:29: ( LT )* '?' ( LT )* assignmentExpressionNoIn ( LT )* ':' ( LT )* assignmentExpressionNoIn pass # JavaScript.g:273:31: ( LT )* while True: #loop152 alt152 = 2 LA152_0 = self.input.LA(1) if (LA152_0 == LT) : alt152 = 1 if alt152 == 1: # JavaScript.g:0:0: LT pass LT314=self.match(self.input, LT, self.FOLLOW_LT_in_conditionalExpressionNoIn1690) else: break #loop152 char_literal315=self.match(self.input, 73, self.FOLLOW_73_in_conditionalExpressionNoIn1694) if self._state.backtracking == 0: char_literal315_tree = self._adaptor.createWithPayload(char_literal315) self._adaptor.addChild(root_0, char_literal315_tree) # JavaScript.g:273:40: ( LT )* while True: #loop153 alt153 = 2 LA153_0 = self.input.LA(1) if (LA153_0 == LT) : alt153 = 1 if alt153 == 1: # JavaScript.g:0:0: LT pass LT316=self.match(self.input, LT, self.FOLLOW_LT_in_conditionalExpressionNoIn1696) else: break #loop153 self._state.following.append(self.FOLLOW_assignmentExpressionNoIn_in_conditionalExpressionNoIn1700) assignmentExpressionNoIn317 = self.assignmentExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpressionNoIn317.tree) # JavaScript.g:273:70: ( LT )* while True: #loop154 alt154 = 2 LA154_0 = self.input.LA(1) if (LA154_0 == LT) : alt154 = 1 if alt154 == 1: # JavaScript.g:0:0: LT pass LT318=self.match(self.input, LT, self.FOLLOW_LT_in_conditionalExpressionNoIn1702) else: break #loop154 char_literal319=self.match(self.input, 50, self.FOLLOW_50_in_conditionalExpressionNoIn1706) if self._state.backtracking == 0: char_literal319_tree = self._adaptor.createWithPayload(char_literal319) self._adaptor.addChild(root_0, char_literal319_tree) # JavaScript.g:273:79: ( LT )* while True: #loop155 alt155 = 2 LA155_0 = self.input.LA(1) if (LA155_0 == LT) : alt155 = 1 if alt155 == 1: # JavaScript.g:0:0: LT pass LT320=self.match(self.input, LT, self.FOLLOW_LT_in_conditionalExpressionNoIn1708) else: break #loop155 self._state.following.append(self.FOLLOW_assignmentExpressionNoIn_in_conditionalExpressionNoIn1712) assignmentExpressionNoIn321 = self.assignmentExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpressionNoIn321.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 56, conditionalExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "conditionalExpressionNoIn" class logicalORExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.logicalORExpression_return, self).__init__() self.tree = None # $ANTLR start "logicalORExpression" # JavaScript.g:276:1: logicalORExpression : logicalANDExpression ( ( LT )* '||' ( LT )* logicalANDExpression )* ; def logicalORExpression(self, ): retval = self.logicalORExpression_return() retval.start = self.input.LT(1) logicalORExpression_StartIndex = self.input.index() root_0 = None LT323 = None string_literal324 = None LT325 = None logicalANDExpression322 = None logicalANDExpression326 = None LT323_tree = None string_literal324_tree = None LT325_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 57): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:277:2: ( logicalANDExpression ( ( LT )* '||' ( LT )* logicalANDExpression )* ) # JavaScript.g:277:4: logicalANDExpression ( ( LT )* '||' ( LT )* logicalANDExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_logicalANDExpression_in_logicalORExpression1725) logicalANDExpression322 = self.logicalANDExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logicalANDExpression322.tree) # JavaScript.g:277:25: ( ( LT )* '||' ( LT )* logicalANDExpression )* while True: #loop159 alt159 = 2 alt159 = self.dfa159.predict(self.input) if alt159 == 1: # JavaScript.g:277:26: ( LT )* '||' ( LT )* logicalANDExpression pass # JavaScript.g:277:28: ( LT )* while True: #loop157 alt157 = 2 LA157_0 = self.input.LA(1) if (LA157_0 == LT) : alt157 = 1 if alt157 == 1: # JavaScript.g:0:0: LT pass LT323=self.match(self.input, LT, self.FOLLOW_LT_in_logicalORExpression1728) else: break #loop157 string_literal324=self.match(self.input, 74, self.FOLLOW_74_in_logicalORExpression1732) if self._state.backtracking == 0: string_literal324_tree = self._adaptor.createWithPayload(string_literal324) self._adaptor.addChild(root_0, string_literal324_tree) # JavaScript.g:277:38: ( LT )* while True: #loop158 alt158 = 2 LA158_0 = self.input.LA(1) if (LA158_0 == LT) : alt158 = 1 if alt158 == 1: # JavaScript.g:0:0: LT pass LT325=self.match(self.input, LT, self.FOLLOW_LT_in_logicalORExpression1734) else: break #loop158 self._state.following.append(self.FOLLOW_logicalANDExpression_in_logicalORExpression1738) logicalANDExpression326 = self.logicalANDExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logicalANDExpression326.tree) else: break #loop159 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 57, logicalORExpression_StartIndex, success) pass return retval # $ANTLR end "logicalORExpression" class logicalORExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.logicalORExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "logicalORExpressionNoIn" # JavaScript.g:280:1: logicalORExpressionNoIn : logicalANDExpressionNoIn ( ( LT )* '||' ( LT )* logicalANDExpressionNoIn )* ; def logicalORExpressionNoIn(self, ): retval = self.logicalORExpressionNoIn_return() retval.start = self.input.LT(1) logicalORExpressionNoIn_StartIndex = self.input.index() root_0 = None LT328 = None string_literal329 = None LT330 = None logicalANDExpressionNoIn327 = None logicalANDExpressionNoIn331 = None LT328_tree = None string_literal329_tree = None LT330_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 58): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:281:2: ( logicalANDExpressionNoIn ( ( LT )* '||' ( LT )* logicalANDExpressionNoIn )* ) # JavaScript.g:281:4: logicalANDExpressionNoIn ( ( LT )* '||' ( LT )* logicalANDExpressionNoIn )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_logicalANDExpressionNoIn_in_logicalORExpressionNoIn1752) logicalANDExpressionNoIn327 = self.logicalANDExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logicalANDExpressionNoIn327.tree) # JavaScript.g:281:29: ( ( LT )* '||' ( LT )* logicalANDExpressionNoIn )* while True: #loop162 alt162 = 2 alt162 = self.dfa162.predict(self.input) if alt162 == 1: # JavaScript.g:281:30: ( LT )* '||' ( LT )* logicalANDExpressionNoIn pass # JavaScript.g:281:32: ( LT )* while True: #loop160 alt160 = 2 LA160_0 = self.input.LA(1) if (LA160_0 == LT) : alt160 = 1 if alt160 == 1: # JavaScript.g:0:0: LT pass LT328=self.match(self.input, LT, self.FOLLOW_LT_in_logicalORExpressionNoIn1755) else: break #loop160 string_literal329=self.match(self.input, 74, self.FOLLOW_74_in_logicalORExpressionNoIn1759) if self._state.backtracking == 0: string_literal329_tree = self._adaptor.createWithPayload(string_literal329) self._adaptor.addChild(root_0, string_literal329_tree) # JavaScript.g:281:42: ( LT )* while True: #loop161 alt161 = 2 LA161_0 = self.input.LA(1) if (LA161_0 == LT) : alt161 = 1 if alt161 == 1: # JavaScript.g:0:0: LT pass LT330=self.match(self.input, LT, self.FOLLOW_LT_in_logicalORExpressionNoIn1761) else: break #loop161 self._state.following.append(self.FOLLOW_logicalANDExpressionNoIn_in_logicalORExpressionNoIn1765) logicalANDExpressionNoIn331 = self.logicalANDExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logicalANDExpressionNoIn331.tree) else: break #loop162 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 58, logicalORExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "logicalORExpressionNoIn" class logicalANDExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.logicalANDExpression_return, self).__init__() self.tree = None # $ANTLR start "logicalANDExpression" # JavaScript.g:284:1: logicalANDExpression : bitwiseORExpression ( ( LT )* '&&' ( LT )* bitwiseORExpression )* ; def logicalANDExpression(self, ): retval = self.logicalANDExpression_return() retval.start = self.input.LT(1) logicalANDExpression_StartIndex = self.input.index() root_0 = None LT333 = None string_literal334 = None LT335 = None bitwiseORExpression332 = None bitwiseORExpression336 = None LT333_tree = None string_literal334_tree = None LT335_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 59): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:285:2: ( bitwiseORExpression ( ( LT )* '&&' ( LT )* bitwiseORExpression )* ) # JavaScript.g:285:4: bitwiseORExpression ( ( LT )* '&&' ( LT )* bitwiseORExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwiseORExpression_in_logicalANDExpression1779) bitwiseORExpression332 = self.bitwiseORExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseORExpression332.tree) # JavaScript.g:285:24: ( ( LT )* '&&' ( LT )* bitwiseORExpression )* while True: #loop165 alt165 = 2 alt165 = self.dfa165.predict(self.input) if alt165 == 1: # JavaScript.g:285:25: ( LT )* '&&' ( LT )* bitwiseORExpression pass # JavaScript.g:285:27: ( LT )* while True: #loop163 alt163 = 2 LA163_0 = self.input.LA(1) if (LA163_0 == LT) : alt163 = 1 if alt163 == 1: # JavaScript.g:0:0: LT pass LT333=self.match(self.input, LT, self.FOLLOW_LT_in_logicalANDExpression1782) else: break #loop163 string_literal334=self.match(self.input, 75, self.FOLLOW_75_in_logicalANDExpression1786) if self._state.backtracking == 0: string_literal334_tree = self._adaptor.createWithPayload(string_literal334) self._adaptor.addChild(root_0, string_literal334_tree) # JavaScript.g:285:37: ( LT )* while True: #loop164 alt164 = 2 LA164_0 = self.input.LA(1) if (LA164_0 == LT) : alt164 = 1 if alt164 == 1: # JavaScript.g:0:0: LT pass LT335=self.match(self.input, LT, self.FOLLOW_LT_in_logicalANDExpression1788) else: break #loop164 self._state.following.append(self.FOLLOW_bitwiseORExpression_in_logicalANDExpression1792) bitwiseORExpression336 = self.bitwiseORExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseORExpression336.tree) else: break #loop165 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 59, logicalANDExpression_StartIndex, success) pass return retval # $ANTLR end "logicalANDExpression" class logicalANDExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.logicalANDExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "logicalANDExpressionNoIn" # JavaScript.g:288:1: logicalANDExpressionNoIn : bitwiseORExpressionNoIn ( ( LT )* '&&' ( LT )* bitwiseORExpressionNoIn )* ; def logicalANDExpressionNoIn(self, ): retval = self.logicalANDExpressionNoIn_return() retval.start = self.input.LT(1) logicalANDExpressionNoIn_StartIndex = self.input.index() root_0 = None LT338 = None string_literal339 = None LT340 = None bitwiseORExpressionNoIn337 = None bitwiseORExpressionNoIn341 = None LT338_tree = None string_literal339_tree = None LT340_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 60): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:289:2: ( bitwiseORExpressionNoIn ( ( LT )* '&&' ( LT )* bitwiseORExpressionNoIn )* ) # JavaScript.g:289:4: bitwiseORExpressionNoIn ( ( LT )* '&&' ( LT )* bitwiseORExpressionNoIn )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwiseORExpressionNoIn_in_logicalANDExpressionNoIn1806) bitwiseORExpressionNoIn337 = self.bitwiseORExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseORExpressionNoIn337.tree) # JavaScript.g:289:28: ( ( LT )* '&&' ( LT )* bitwiseORExpressionNoIn )* while True: #loop168 alt168 = 2 alt168 = self.dfa168.predict(self.input) if alt168 == 1: # JavaScript.g:289:29: ( LT )* '&&' ( LT )* bitwiseORExpressionNoIn pass # JavaScript.g:289:31: ( LT )* while True: #loop166 alt166 = 2 LA166_0 = self.input.LA(1) if (LA166_0 == LT) : alt166 = 1 if alt166 == 1: # JavaScript.g:0:0: LT pass LT338=self.match(self.input, LT, self.FOLLOW_LT_in_logicalANDExpressionNoIn1809) else: break #loop166 string_literal339=self.match(self.input, 75, self.FOLLOW_75_in_logicalANDExpressionNoIn1813) if self._state.backtracking == 0: string_literal339_tree = self._adaptor.createWithPayload(string_literal339) self._adaptor.addChild(root_0, string_literal339_tree) # JavaScript.g:289:41: ( LT )* while True: #loop167 alt167 = 2 LA167_0 = self.input.LA(1) if (LA167_0 == LT) : alt167 = 1 if alt167 == 1: # JavaScript.g:0:0: LT pass LT340=self.match(self.input, LT, self.FOLLOW_LT_in_logicalANDExpressionNoIn1815) else: break #loop167 self._state.following.append(self.FOLLOW_bitwiseORExpressionNoIn_in_logicalANDExpressionNoIn1819) bitwiseORExpressionNoIn341 = self.bitwiseORExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseORExpressionNoIn341.tree) else: break #loop168 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 60, logicalANDExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "logicalANDExpressionNoIn" class bitwiseORExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.bitwiseORExpression_return, self).__init__() self.tree = None # $ANTLR start "bitwiseORExpression" # JavaScript.g:292:1: bitwiseORExpression : bitwiseXORExpression ( ( LT )* '|' ( LT )* bitwiseXORExpression )* ; def bitwiseORExpression(self, ): retval = self.bitwiseORExpression_return() retval.start = self.input.LT(1) bitwiseORExpression_StartIndex = self.input.index() root_0 = None LT343 = None char_literal344 = None LT345 = None bitwiseXORExpression342 = None bitwiseXORExpression346 = None LT343_tree = None char_literal344_tree = None LT345_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 61): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:293:2: ( bitwiseXORExpression ( ( LT )* '|' ( LT )* bitwiseXORExpression )* ) # JavaScript.g:293:4: bitwiseXORExpression ( ( LT )* '|' ( LT )* bitwiseXORExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwiseXORExpression_in_bitwiseORExpression1833) bitwiseXORExpression342 = self.bitwiseXORExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseXORExpression342.tree) # JavaScript.g:293:25: ( ( LT )* '|' ( LT )* bitwiseXORExpression )* while True: #loop171 alt171 = 2 alt171 = self.dfa171.predict(self.input) if alt171 == 1: # JavaScript.g:293:26: ( LT )* '|' ( LT )* bitwiseXORExpression pass # JavaScript.g:293:28: ( LT )* while True: #loop169 alt169 = 2 LA169_0 = self.input.LA(1) if (LA169_0 == LT) : alt169 = 1 if alt169 == 1: # JavaScript.g:0:0: LT pass LT343=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseORExpression1836) else: break #loop169 char_literal344=self.match(self.input, 76, self.FOLLOW_76_in_bitwiseORExpression1840) if self._state.backtracking == 0: char_literal344_tree = self._adaptor.createWithPayload(char_literal344) self._adaptor.addChild(root_0, char_literal344_tree) # JavaScript.g:293:37: ( LT )* while True: #loop170 alt170 = 2 LA170_0 = self.input.LA(1) if (LA170_0 == LT) : alt170 = 1 if alt170 == 1: # JavaScript.g:0:0: LT pass LT345=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseORExpression1842) else: break #loop170 self._state.following.append(self.FOLLOW_bitwiseXORExpression_in_bitwiseORExpression1846) bitwiseXORExpression346 = self.bitwiseXORExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseXORExpression346.tree) else: break #loop171 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 61, bitwiseORExpression_StartIndex, success) pass return retval # $ANTLR end "bitwiseORExpression" class bitwiseORExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.bitwiseORExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "bitwiseORExpressionNoIn" # JavaScript.g:296:1: bitwiseORExpressionNoIn : bitwiseXORExpressionNoIn ( ( LT )* '|' ( LT )* bitwiseXORExpressionNoIn )* ; def bitwiseORExpressionNoIn(self, ): retval = self.bitwiseORExpressionNoIn_return() retval.start = self.input.LT(1) bitwiseORExpressionNoIn_StartIndex = self.input.index() root_0 = None LT348 = None char_literal349 = None LT350 = None bitwiseXORExpressionNoIn347 = None bitwiseXORExpressionNoIn351 = None LT348_tree = None char_literal349_tree = None LT350_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 62): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:297:2: ( bitwiseXORExpressionNoIn ( ( LT )* '|' ( LT )* bitwiseXORExpressionNoIn )* ) # JavaScript.g:297:4: bitwiseXORExpressionNoIn ( ( LT )* '|' ( LT )* bitwiseXORExpressionNoIn )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwiseXORExpressionNoIn_in_bitwiseORExpressionNoIn1860) bitwiseXORExpressionNoIn347 = self.bitwiseXORExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseXORExpressionNoIn347.tree) # JavaScript.g:297:29: ( ( LT )* '|' ( LT )* bitwiseXORExpressionNoIn )* while True: #loop174 alt174 = 2 alt174 = self.dfa174.predict(self.input) if alt174 == 1: # JavaScript.g:297:30: ( LT )* '|' ( LT )* bitwiseXORExpressionNoIn pass # JavaScript.g:297:32: ( LT )* while True: #loop172 alt172 = 2 LA172_0 = self.input.LA(1) if (LA172_0 == LT) : alt172 = 1 if alt172 == 1: # JavaScript.g:0:0: LT pass LT348=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseORExpressionNoIn1863) else: break #loop172 char_literal349=self.match(self.input, 76, self.FOLLOW_76_in_bitwiseORExpressionNoIn1867) if self._state.backtracking == 0: char_literal349_tree = self._adaptor.createWithPayload(char_literal349) self._adaptor.addChild(root_0, char_literal349_tree) # JavaScript.g:297:41: ( LT )* while True: #loop173 alt173 = 2 LA173_0 = self.input.LA(1) if (LA173_0 == LT) : alt173 = 1 if alt173 == 1: # JavaScript.g:0:0: LT pass LT350=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseORExpressionNoIn1869) else: break #loop173 self._state.following.append(self.FOLLOW_bitwiseXORExpressionNoIn_in_bitwiseORExpressionNoIn1873) bitwiseXORExpressionNoIn351 = self.bitwiseXORExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseXORExpressionNoIn351.tree) else: break #loop174 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 62, bitwiseORExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "bitwiseORExpressionNoIn" class bitwiseXORExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.bitwiseXORExpression_return, self).__init__() self.tree = None # $ANTLR start "bitwiseXORExpression" # JavaScript.g:300:1: bitwiseXORExpression : bitwiseANDExpression ( ( LT )* '^' ( LT )* bitwiseANDExpression )* ; def bitwiseXORExpression(self, ): retval = self.bitwiseXORExpression_return() retval.start = self.input.LT(1) bitwiseXORExpression_StartIndex = self.input.index() root_0 = None LT353 = None char_literal354 = None LT355 = None bitwiseANDExpression352 = None bitwiseANDExpression356 = None LT353_tree = None char_literal354_tree = None LT355_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 63): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:301:2: ( bitwiseANDExpression ( ( LT )* '^' ( LT )* bitwiseANDExpression )* ) # JavaScript.g:301:4: bitwiseANDExpression ( ( LT )* '^' ( LT )* bitwiseANDExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwiseANDExpression_in_bitwiseXORExpression1887) bitwiseANDExpression352 = self.bitwiseANDExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseANDExpression352.tree) # JavaScript.g:301:25: ( ( LT )* '^' ( LT )* bitwiseANDExpression )* while True: #loop177 alt177 = 2 alt177 = self.dfa177.predict(self.input) if alt177 == 1: # JavaScript.g:301:26: ( LT )* '^' ( LT )* bitwiseANDExpression pass # JavaScript.g:301:28: ( LT )* while True: #loop175 alt175 = 2 LA175_0 = self.input.LA(1) if (LA175_0 == LT) : alt175 = 1 if alt175 == 1: # JavaScript.g:0:0: LT pass LT353=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseXORExpression1890) else: break #loop175 char_literal354=self.match(self.input, 77, self.FOLLOW_77_in_bitwiseXORExpression1894) if self._state.backtracking == 0: char_literal354_tree = self._adaptor.createWithPayload(char_literal354) self._adaptor.addChild(root_0, char_literal354_tree) # JavaScript.g:301:37: ( LT )* while True: #loop176 alt176 = 2 LA176_0 = self.input.LA(1) if (LA176_0 == LT) : alt176 = 1 if alt176 == 1: # JavaScript.g:0:0: LT pass LT355=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseXORExpression1896) else: break #loop176 self._state.following.append(self.FOLLOW_bitwiseANDExpression_in_bitwiseXORExpression1900) bitwiseANDExpression356 = self.bitwiseANDExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseANDExpression356.tree) else: break #loop177 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 63, bitwiseXORExpression_StartIndex, success) pass return retval # $ANTLR end "bitwiseXORExpression" class bitwiseXORExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.bitwiseXORExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "bitwiseXORExpressionNoIn" # JavaScript.g:304:1: bitwiseXORExpressionNoIn : bitwiseANDExpressionNoIn ( ( LT )* '^' ( LT )* bitwiseANDExpressionNoIn )* ; def bitwiseXORExpressionNoIn(self, ): retval = self.bitwiseXORExpressionNoIn_return() retval.start = self.input.LT(1) bitwiseXORExpressionNoIn_StartIndex = self.input.index() root_0 = None LT358 = None char_literal359 = None LT360 = None bitwiseANDExpressionNoIn357 = None bitwiseANDExpressionNoIn361 = None LT358_tree = None char_literal359_tree = None LT360_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 64): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:305:2: ( bitwiseANDExpressionNoIn ( ( LT )* '^' ( LT )* bitwiseANDExpressionNoIn )* ) # JavaScript.g:305:4: bitwiseANDExpressionNoIn ( ( LT )* '^' ( LT )* bitwiseANDExpressionNoIn )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwiseANDExpressionNoIn_in_bitwiseXORExpressionNoIn1914) bitwiseANDExpressionNoIn357 = self.bitwiseANDExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseANDExpressionNoIn357.tree) # JavaScript.g:305:29: ( ( LT )* '^' ( LT )* bitwiseANDExpressionNoIn )* while True: #loop180 alt180 = 2 alt180 = self.dfa180.predict(self.input) if alt180 == 1: # JavaScript.g:305:30: ( LT )* '^' ( LT )* bitwiseANDExpressionNoIn pass # JavaScript.g:305:32: ( LT )* while True: #loop178 alt178 = 2 LA178_0 = self.input.LA(1) if (LA178_0 == LT) : alt178 = 1 if alt178 == 1: # JavaScript.g:0:0: LT pass LT358=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseXORExpressionNoIn1917) else: break #loop178 char_literal359=self.match(self.input, 77, self.FOLLOW_77_in_bitwiseXORExpressionNoIn1921) if self._state.backtracking == 0: char_literal359_tree = self._adaptor.createWithPayload(char_literal359) self._adaptor.addChild(root_0, char_literal359_tree) # JavaScript.g:305:41: ( LT )* while True: #loop179 alt179 = 2 LA179_0 = self.input.LA(1) if (LA179_0 == LT) : alt179 = 1 if alt179 == 1: # JavaScript.g:0:0: LT pass LT360=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseXORExpressionNoIn1923) else: break #loop179 self._state.following.append(self.FOLLOW_bitwiseANDExpressionNoIn_in_bitwiseXORExpressionNoIn1927) bitwiseANDExpressionNoIn361 = self.bitwiseANDExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwiseANDExpressionNoIn361.tree) else: break #loop180 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 64, bitwiseXORExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "bitwiseXORExpressionNoIn" class bitwiseANDExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.bitwiseANDExpression_return, self).__init__() self.tree = None # $ANTLR start "bitwiseANDExpression" # JavaScript.g:308:1: bitwiseANDExpression : equalityExpression ( ( LT )* '&' ( LT )* equalityExpression )* ; def bitwiseANDExpression(self, ): retval = self.bitwiseANDExpression_return() retval.start = self.input.LT(1) bitwiseANDExpression_StartIndex = self.input.index() root_0 = None LT363 = None char_literal364 = None LT365 = None equalityExpression362 = None equalityExpression366 = None LT363_tree = None char_literal364_tree = None LT365_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 65): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:309:2: ( equalityExpression ( ( LT )* '&' ( LT )* equalityExpression )* ) # JavaScript.g:309:4: equalityExpression ( ( LT )* '&' ( LT )* equalityExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_equalityExpression_in_bitwiseANDExpression1941) equalityExpression362 = self.equalityExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, equalityExpression362.tree) # JavaScript.g:309:23: ( ( LT )* '&' ( LT )* equalityExpression )* while True: #loop183 alt183 = 2 alt183 = self.dfa183.predict(self.input) if alt183 == 1: # JavaScript.g:309:24: ( LT )* '&' ( LT )* equalityExpression pass # JavaScript.g:309:26: ( LT )* while True: #loop181 alt181 = 2 LA181_0 = self.input.LA(1) if (LA181_0 == LT) : alt181 = 1 if alt181 == 1: # JavaScript.g:0:0: LT pass LT363=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseANDExpression1944) else: break #loop181 char_literal364=self.match(self.input, 78, self.FOLLOW_78_in_bitwiseANDExpression1948) if self._state.backtracking == 0: char_literal364_tree = self._adaptor.createWithPayload(char_literal364) self._adaptor.addChild(root_0, char_literal364_tree) # JavaScript.g:309:35: ( LT )* while True: #loop182 alt182 = 2 LA182_0 = self.input.LA(1) if (LA182_0 == LT) : alt182 = 1 if alt182 == 1: # JavaScript.g:0:0: LT pass LT365=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseANDExpression1950) else: break #loop182 self._state.following.append(self.FOLLOW_equalityExpression_in_bitwiseANDExpression1954) equalityExpression366 = self.equalityExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, equalityExpression366.tree) else: break #loop183 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 65, bitwiseANDExpression_StartIndex, success) pass return retval # $ANTLR end "bitwiseANDExpression" class bitwiseANDExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.bitwiseANDExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "bitwiseANDExpressionNoIn" # JavaScript.g:312:1: bitwiseANDExpressionNoIn : equalityExpressionNoIn ( ( LT )* '&' ( LT )* equalityExpressionNoIn )* ; def bitwiseANDExpressionNoIn(self, ): retval = self.bitwiseANDExpressionNoIn_return() retval.start = self.input.LT(1) bitwiseANDExpressionNoIn_StartIndex = self.input.index() root_0 = None LT368 = None char_literal369 = None LT370 = None equalityExpressionNoIn367 = None equalityExpressionNoIn371 = None LT368_tree = None char_literal369_tree = None LT370_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 66): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:313:2: ( equalityExpressionNoIn ( ( LT )* '&' ( LT )* equalityExpressionNoIn )* ) # JavaScript.g:313:4: equalityExpressionNoIn ( ( LT )* '&' ( LT )* equalityExpressionNoIn )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_equalityExpressionNoIn_in_bitwiseANDExpressionNoIn1968) equalityExpressionNoIn367 = self.equalityExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, equalityExpressionNoIn367.tree) # JavaScript.g:313:27: ( ( LT )* '&' ( LT )* equalityExpressionNoIn )* while True: #loop186 alt186 = 2 alt186 = self.dfa186.predict(self.input) if alt186 == 1: # JavaScript.g:313:28: ( LT )* '&' ( LT )* equalityExpressionNoIn pass # JavaScript.g:313:30: ( LT )* while True: #loop184 alt184 = 2 LA184_0 = self.input.LA(1) if (LA184_0 == LT) : alt184 = 1 if alt184 == 1: # JavaScript.g:0:0: LT pass LT368=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseANDExpressionNoIn1971) else: break #loop184 char_literal369=self.match(self.input, 78, self.FOLLOW_78_in_bitwiseANDExpressionNoIn1975) if self._state.backtracking == 0: char_literal369_tree = self._adaptor.createWithPayload(char_literal369) self._adaptor.addChild(root_0, char_literal369_tree) # JavaScript.g:313:39: ( LT )* while True: #loop185 alt185 = 2 LA185_0 = self.input.LA(1) if (LA185_0 == LT) : alt185 = 1 if alt185 == 1: # JavaScript.g:0:0: LT pass LT370=self.match(self.input, LT, self.FOLLOW_LT_in_bitwiseANDExpressionNoIn1977) else: break #loop185 self._state.following.append(self.FOLLOW_equalityExpressionNoIn_in_bitwiseANDExpressionNoIn1981) equalityExpressionNoIn371 = self.equalityExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, equalityExpressionNoIn371.tree) else: break #loop186 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 66, bitwiseANDExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "bitwiseANDExpressionNoIn" class equalityExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.equalityExpression_return, self).__init__() self.tree = None # $ANTLR start "equalityExpression" # JavaScript.g:316:1: equalityExpression : relationalExpression ( ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpression )* ; def equalityExpression(self, ): retval = self.equalityExpression_return() retval.start = self.input.LT(1) equalityExpression_StartIndex = self.input.index() root_0 = None LT373 = None set374 = None LT375 = None relationalExpression372 = None relationalExpression376 = None LT373_tree = None set374_tree = None LT375_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 67): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:317:2: ( relationalExpression ( ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpression )* ) # JavaScript.g:317:4: relationalExpression ( ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_relationalExpression_in_equalityExpression1995) relationalExpression372 = self.relationalExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, relationalExpression372.tree) # JavaScript.g:317:25: ( ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpression )* while True: #loop189 alt189 = 2 alt189 = self.dfa189.predict(self.input) if alt189 == 1: # JavaScript.g:317:26: ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpression pass # JavaScript.g:317:28: ( LT )* while True: #loop187 alt187 = 2 LA187_0 = self.input.LA(1) if (LA187_0 == LT) : alt187 = 1 if alt187 == 1: # JavaScript.g:0:0: LT pass LT373=self.match(self.input, LT, self.FOLLOW_LT_in_equalityExpression1998) else: break #loop187 set374 = self.input.LT(1) if (79 <= self.input.LA(1) <= 82): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set374)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse # JavaScript.g:317:63: ( LT )* while True: #loop188 alt188 = 2 LA188_0 = self.input.LA(1) if (LA188_0 == LT) : alt188 = 1 if alt188 == 1: # JavaScript.g:0:0: LT pass LT375=self.match(self.input, LT, self.FOLLOW_LT_in_equalityExpression2018) else: break #loop188 self._state.following.append(self.FOLLOW_relationalExpression_in_equalityExpression2022) relationalExpression376 = self.relationalExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, relationalExpression376.tree) else: break #loop189 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 67, equalityExpression_StartIndex, success) pass return retval # $ANTLR end "equalityExpression" class equalityExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.equalityExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "equalityExpressionNoIn" # JavaScript.g:320:1: equalityExpressionNoIn : relationalExpressionNoIn ( ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpressionNoIn )* ; def equalityExpressionNoIn(self, ): retval = self.equalityExpressionNoIn_return() retval.start = self.input.LT(1) equalityExpressionNoIn_StartIndex = self.input.index() root_0 = None LT378 = None set379 = None LT380 = None relationalExpressionNoIn377 = None relationalExpressionNoIn381 = None LT378_tree = None set379_tree = None LT380_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 68): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:321:2: ( relationalExpressionNoIn ( ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpressionNoIn )* ) # JavaScript.g:321:4: relationalExpressionNoIn ( ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpressionNoIn )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_relationalExpressionNoIn_in_equalityExpressionNoIn2035) relationalExpressionNoIn377 = self.relationalExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, relationalExpressionNoIn377.tree) # JavaScript.g:321:29: ( ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpressionNoIn )* while True: #loop192 alt192 = 2 alt192 = self.dfa192.predict(self.input) if alt192 == 1: # JavaScript.g:321:30: ( LT )* ( '==' | '!=' | '===' | '!==' ) ( LT )* relationalExpressionNoIn pass # JavaScript.g:321:32: ( LT )* while True: #loop190 alt190 = 2 LA190_0 = self.input.LA(1) if (LA190_0 == LT) : alt190 = 1 if alt190 == 1: # JavaScript.g:0:0: LT pass LT378=self.match(self.input, LT, self.FOLLOW_LT_in_equalityExpressionNoIn2038) else: break #loop190 set379 = self.input.LT(1) if (79 <= self.input.LA(1) <= 82): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set379)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse # JavaScript.g:321:67: ( LT )* while True: #loop191 alt191 = 2 LA191_0 = self.input.LA(1) if (LA191_0 == LT) : alt191 = 1 if alt191 == 1: # JavaScript.g:0:0: LT pass LT380=self.match(self.input, LT, self.FOLLOW_LT_in_equalityExpressionNoIn2058) else: break #loop191 self._state.following.append(self.FOLLOW_relationalExpressionNoIn_in_equalityExpressionNoIn2062) relationalExpressionNoIn381 = self.relationalExpressionNoIn() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, relationalExpressionNoIn381.tree) else: break #loop192 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 68, equalityExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "equalityExpressionNoIn" class relationalExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.relationalExpression_return, self).__init__() self.tree = None # $ANTLR start "relationalExpression" # JavaScript.g:324:1: relationalExpression : shiftExpression ( ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' | 'in' ) ( LT )* shiftExpression )* ; def relationalExpression(self, ): retval = self.relationalExpression_return() retval.start = self.input.LT(1) relationalExpression_StartIndex = self.input.index() root_0 = None LT383 = None set384 = None LT385 = None shiftExpression382 = None shiftExpression386 = None LT383_tree = None set384_tree = None LT385_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 69): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:325:2: ( shiftExpression ( ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' | 'in' ) ( LT )* shiftExpression )* ) # JavaScript.g:325:4: shiftExpression ( ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' | 'in' ) ( LT )* shiftExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_shiftExpression_in_relationalExpression2076) shiftExpression382 = self.shiftExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, shiftExpression382.tree) # JavaScript.g:325:20: ( ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' | 'in' ) ( LT )* shiftExpression )* while True: #loop195 alt195 = 2 alt195 = self.dfa195.predict(self.input) if alt195 == 1: # JavaScript.g:325:21: ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' | 'in' ) ( LT )* shiftExpression pass # JavaScript.g:325:23: ( LT )* while True: #loop193 alt193 = 2 LA193_0 = self.input.LA(1) if (LA193_0 == LT) : alt193 = 1 if alt193 == 1: # JavaScript.g:0:0: LT pass LT383=self.match(self.input, LT, self.FOLLOW_LT_in_relationalExpression2079) else: break #loop193 set384 = self.input.LT(1) if self.input.LA(1) == 45 or (83 <= self.input.LA(1) <= 87): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set384)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse # JavaScript.g:325:76: ( LT )* while True: #loop194 alt194 = 2 LA194_0 = self.input.LA(1) if (LA194_0 == LT) : alt194 = 1 if alt194 == 1: # JavaScript.g:0:0: LT pass LT385=self.match(self.input, LT, self.FOLLOW_LT_in_relationalExpression2107) else: break #loop194 self._state.following.append(self.FOLLOW_shiftExpression_in_relationalExpression2111) shiftExpression386 = self.shiftExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, shiftExpression386.tree) else: break #loop195 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 69, relationalExpression_StartIndex, success) pass return retval # $ANTLR end "relationalExpression" class relationalExpressionNoIn_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.relationalExpressionNoIn_return, self).__init__() self.tree = None # $ANTLR start "relationalExpressionNoIn" # JavaScript.g:328:1: relationalExpressionNoIn : shiftExpression ( ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' ) ( LT )* shiftExpression )* ; def relationalExpressionNoIn(self, ): retval = self.relationalExpressionNoIn_return() retval.start = self.input.LT(1) relationalExpressionNoIn_StartIndex = self.input.index() root_0 = None LT388 = None set389 = None LT390 = None shiftExpression387 = None shiftExpression391 = None LT388_tree = None set389_tree = None LT390_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 70): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:329:2: ( shiftExpression ( ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' ) ( LT )* shiftExpression )* ) # JavaScript.g:329:4: shiftExpression ( ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' ) ( LT )* shiftExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_shiftExpression_in_relationalExpressionNoIn2124) shiftExpression387 = self.shiftExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, shiftExpression387.tree) # JavaScript.g:329:20: ( ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' ) ( LT )* shiftExpression )* while True: #loop198 alt198 = 2 alt198 = self.dfa198.predict(self.input) if alt198 == 1: # JavaScript.g:329:21: ( LT )* ( '<' | '>' | '<=' | '>=' | 'instanceof' ) ( LT )* shiftExpression pass # JavaScript.g:329:23: ( LT )* while True: #loop196 alt196 = 2 LA196_0 = self.input.LA(1) if (LA196_0 == LT) : alt196 = 1 if alt196 == 1: # JavaScript.g:0:0: LT pass LT388=self.match(self.input, LT, self.FOLLOW_LT_in_relationalExpressionNoIn2127) else: break #loop196 set389 = self.input.LT(1) if (83 <= self.input.LA(1) <= 87): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set389)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse # JavaScript.g:329:69: ( LT )* while True: #loop197 alt197 = 2 LA197_0 = self.input.LA(1) if (LA197_0 == LT) : alt197 = 1 if alt197 == 1: # JavaScript.g:0:0: LT pass LT390=self.match(self.input, LT, self.FOLLOW_LT_in_relationalExpressionNoIn2151) else: break #loop197 self._state.following.append(self.FOLLOW_shiftExpression_in_relationalExpressionNoIn2155) shiftExpression391 = self.shiftExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, shiftExpression391.tree) else: break #loop198 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 70, relationalExpressionNoIn_StartIndex, success) pass return retval # $ANTLR end "relationalExpressionNoIn" class shiftExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.shiftExpression_return, self).__init__() self.tree = None # $ANTLR start "shiftExpression" # JavaScript.g:332:1: shiftExpression : additiveExpression ( ( LT )* ( '<<' | '>>' | '>>>' ) ( LT )* additiveExpression )* ; def shiftExpression(self, ): retval = self.shiftExpression_return() retval.start = self.input.LT(1) shiftExpression_StartIndex = self.input.index() root_0 = None LT393 = None set394 = None LT395 = None additiveExpression392 = None additiveExpression396 = None LT393_tree = None set394_tree = None LT395_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 71): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:333:2: ( additiveExpression ( ( LT )* ( '<<' | '>>' | '>>>' ) ( LT )* additiveExpression )* ) # JavaScript.g:333:4: additiveExpression ( ( LT )* ( '<<' | '>>' | '>>>' ) ( LT )* additiveExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_additiveExpression_in_shiftExpression2168) additiveExpression392 = self.additiveExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, additiveExpression392.tree) # JavaScript.g:333:23: ( ( LT )* ( '<<' | '>>' | '>>>' ) ( LT )* additiveExpression )* while True: #loop201 alt201 = 2 alt201 = self.dfa201.predict(self.input) if alt201 == 1: # JavaScript.g:333:24: ( LT )* ( '<<' | '>>' | '>>>' ) ( LT )* additiveExpression pass # JavaScript.g:333:26: ( LT )* while True: #loop199 alt199 = 2 LA199_0 = self.input.LA(1) if (LA199_0 == LT) : alt199 = 1 if alt199 == 1: # JavaScript.g:0:0: LT pass LT393=self.match(self.input, LT, self.FOLLOW_LT_in_shiftExpression2171) else: break #loop199 set394 = self.input.LT(1) if (88 <= self.input.LA(1) <= 90): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set394)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse # JavaScript.g:333:53: ( LT )* while True: #loop200 alt200 = 2 LA200_0 = self.input.LA(1) if (LA200_0 == LT) : alt200 = 1 if alt200 == 1: # JavaScript.g:0:0: LT pass LT395=self.match(self.input, LT, self.FOLLOW_LT_in_shiftExpression2187) else: break #loop200 self._state.following.append(self.FOLLOW_additiveExpression_in_shiftExpression2191) additiveExpression396 = self.additiveExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, additiveExpression396.tree) else: break #loop201 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 71, shiftExpression_StartIndex, success) pass return retval # $ANTLR end "shiftExpression" class additiveExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.additiveExpression_return, self).__init__() self.tree = None # $ANTLR start "additiveExpression" # JavaScript.g:336:1: additiveExpression : multiplicativeExpression ( ( LT )* ( '+' | '-' ) ( LT )* multiplicativeExpression )* ; def additiveExpression(self, ): retval = self.additiveExpression_return() retval.start = self.input.LT(1) additiveExpression_StartIndex = self.input.index() root_0 = None LT398 = None set399 = None LT400 = None multiplicativeExpression397 = None multiplicativeExpression401 = None LT398_tree = None set399_tree = None LT400_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 72): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:337:2: ( multiplicativeExpression ( ( LT )* ( '+' | '-' ) ( LT )* multiplicativeExpression )* ) # JavaScript.g:337:4: multiplicativeExpression ( ( LT )* ( '+' | '-' ) ( LT )* multiplicativeExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_multiplicativeExpression_in_additiveExpression2204) multiplicativeExpression397 = self.multiplicativeExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, multiplicativeExpression397.tree) # JavaScript.g:337:29: ( ( LT )* ( '+' | '-' ) ( LT )* multiplicativeExpression )* while True: #loop204 alt204 = 2 alt204 = self.dfa204.predict(self.input) if alt204 == 1: # JavaScript.g:337:30: ( LT )* ( '+' | '-' ) ( LT )* multiplicativeExpression pass # JavaScript.g:337:32: ( LT )* while True: #loop202 alt202 = 2 LA202_0 = self.input.LA(1) if (LA202_0 == LT) : alt202 = 1 if alt202 == 1: # JavaScript.g:0:0: LT pass LT398=self.match(self.input, LT, self.FOLLOW_LT_in_additiveExpression2207) else: break #loop202 set399 = self.input.LT(1) if (91 <= self.input.LA(1) <= 92): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set399)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse # JavaScript.g:337:49: ( LT )* while True: #loop203 alt203 = 2 LA203_0 = self.input.LA(1) if (LA203_0 == LT) : alt203 = 1 if alt203 == 1: # JavaScript.g:0:0: LT pass LT400=self.match(self.input, LT, self.FOLLOW_LT_in_additiveExpression2219) else: break #loop203 self._state.following.append(self.FOLLOW_multiplicativeExpression_in_additiveExpression2223) multiplicativeExpression401 = self.multiplicativeExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, multiplicativeExpression401.tree) else: break #loop204 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 72, additiveExpression_StartIndex, success) pass return retval # $ANTLR end "additiveExpression" class multiplicativeExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.multiplicativeExpression_return, self).__init__() self.tree = None # $ANTLR start "multiplicativeExpression" # JavaScript.g:340:1: multiplicativeExpression : unaryExpression ( ( LT )* ( '*' | '/' | '%' ) ( LT )* unaryExpression )* ; def multiplicativeExpression(self, ): retval = self.multiplicativeExpression_return() retval.start = self.input.LT(1) multiplicativeExpression_StartIndex = self.input.index() root_0 = None LT403 = None set404 = None LT405 = None unaryExpression402 = None unaryExpression406 = None LT403_tree = None set404_tree = None LT405_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 73): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:341:2: ( unaryExpression ( ( LT )* ( '*' | '/' | '%' ) ( LT )* unaryExpression )* ) # JavaScript.g:341:4: unaryExpression ( ( LT )* ( '*' | '/' | '%' ) ( LT )* unaryExpression )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_unaryExpression_in_multiplicativeExpression2236) unaryExpression402 = self.unaryExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, unaryExpression402.tree) # JavaScript.g:341:20: ( ( LT )* ( '*' | '/' | '%' ) ( LT )* unaryExpression )* while True: #loop207 alt207 = 2 alt207 = self.dfa207.predict(self.input) if alt207 == 1: # JavaScript.g:341:21: ( LT )* ( '*' | '/' | '%' ) ( LT )* unaryExpression pass # JavaScript.g:341:23: ( LT )* while True: #loop205 alt205 = 2 LA205_0 = self.input.LA(1) if (LA205_0 == LT) : alt205 = 1 if alt205 == 1: # JavaScript.g:0:0: LT pass LT403=self.match(self.input, LT, self.FOLLOW_LT_in_multiplicativeExpression2239) else: break #loop205 set404 = self.input.LT(1) if (93 <= self.input.LA(1) <= 95): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set404)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse # JavaScript.g:341:46: ( LT )* while True: #loop206 alt206 = 2 LA206_0 = self.input.LA(1) if (LA206_0 == LT) : alt206 = 1 if alt206 == 1: # JavaScript.g:0:0: LT pass LT405=self.match(self.input, LT, self.FOLLOW_LT_in_multiplicativeExpression2255) else: break #loop206 self._state.following.append(self.FOLLOW_unaryExpression_in_multiplicativeExpression2259) unaryExpression406 = self.unaryExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, unaryExpression406.tree) else: break #loop207 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 73, multiplicativeExpression_StartIndex, success) pass return retval # $ANTLR end "multiplicativeExpression" class unaryExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.unaryExpression_return, self).__init__() self.tree = None # $ANTLR start "unaryExpression" # JavaScript.g:344:1: unaryExpression : ( postfixExpression | ( 'delete' | 'void' | 'typeof' | '++' | '--' | '+' | '-' | '~' | '!' ) unaryExpression ); def unaryExpression(self, ): retval = self.unaryExpression_return() retval.start = self.input.LT(1) unaryExpression_StartIndex = self.input.index() root_0 = None set408 = None postfixExpression407 = None unaryExpression409 = None set408_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 74): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:345:2: ( postfixExpression | ( 'delete' | 'void' | 'typeof' | '++' | '--' | '+' | '-' | '~' | '!' ) unaryExpression ) alt208 = 2 LA208_0 = self.input.LA(1) if ((Identifier <= LA208_0 <= NumericLiteral) or (31 <= LA208_0 <= 32) or LA208_0 == 35 or (58 <= LA208_0 <= 59) or (103 <= LA208_0 <= 106)) : alt208 = 1 elif ((91 <= LA208_0 <= 92) or (96 <= LA208_0 <= 102)) : alt208 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 208, 0, self.input) raise nvae if alt208 == 1: # JavaScript.g:345:4: postfixExpression pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_postfixExpression_in_unaryExpression2272) postfixExpression407 = self.postfixExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, postfixExpression407.tree) elif alt208 == 2: # JavaScript.g:346:4: ( 'delete' | 'void' | 'typeof' | '++' | '--' | '+' | '-' | '~' | '!' ) unaryExpression pass root_0 = self._adaptor.nil() set408 = self.input.LT(1) if (91 <= self.input.LA(1) <= 92) or (96 <= self.input.LA(1) <= 102): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set408)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_unaryExpression_in_unaryExpression2313) unaryExpression409 = self.unaryExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, unaryExpression409.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 74, unaryExpression_StartIndex, success) pass return retval # $ANTLR end "unaryExpression" class postfixExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.postfixExpression_return, self).__init__() self.tree = None # $ANTLR start "postfixExpression" # JavaScript.g:349:1: postfixExpression : leftHandSideExpression ( '++' | '--' )? ; def postfixExpression(self, ): retval = self.postfixExpression_return() retval.start = self.input.LT(1) postfixExpression_StartIndex = self.input.index() root_0 = None set411 = None leftHandSideExpression410 = None set411_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 75): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:350:2: ( leftHandSideExpression ( '++' | '--' )? ) # JavaScript.g:350:4: leftHandSideExpression ( '++' | '--' )? pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_leftHandSideExpression_in_postfixExpression2325) leftHandSideExpression410 = self.leftHandSideExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, leftHandSideExpression410.tree) # JavaScript.g:350:27: ( '++' | '--' )? alt209 = 2 LA209_0 = self.input.LA(1) if ((99 <= LA209_0 <= 100)) : alt209 = 1 if alt209 == 1: # JavaScript.g: pass set411 = self.input.LT(1) if (99 <= self.input.LA(1) <= 100): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set411)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 75, postfixExpression_StartIndex, success) pass return retval # $ANTLR end "postfixExpression" class primaryExpression_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.primaryExpression_return, self).__init__() self.tree = None # $ANTLR start "primaryExpression" # JavaScript.g:353:1: primaryExpression : ( 'this' | Identifier | literal | arrayLiteral | objectLiteral | '(' ( LT )* expression ( LT )* ')' ); def primaryExpression(self, ): retval = self.primaryExpression_return() retval.start = self.input.LT(1) primaryExpression_StartIndex = self.input.index() root_0 = None string_literal412 = None Identifier413 = None char_literal417 = None LT418 = None LT420 = None char_literal421 = None literal414 = None arrayLiteral415 = None objectLiteral416 = None expression419 = None string_literal412_tree = None Identifier413_tree = None char_literal417_tree = None LT418_tree = None LT420_tree = None char_literal421_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 76): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:354:2: ( 'this' | Identifier | literal | arrayLiteral | objectLiteral | '(' ( LT )* expression ( LT )* ')' ) alt212 = 6 LA212 = self.input.LA(1) if LA212 == 103: alt212 = 1 elif LA212 == Identifier: alt212 = 2 elif LA212 == StringLiteral or LA212 == NumericLiteral or LA212 == 104 or LA212 == 105 or LA212 == 106: alt212 = 3 elif LA212 == 59: alt212 = 4 elif LA212 == 35: alt212 = 5 elif LA212 == 32: alt212 = 6 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 212, 0, self.input) raise nvae if alt212 == 1: # JavaScript.g:354:4: 'this' pass root_0 = self._adaptor.nil() string_literal412=self.match(self.input, 103, self.FOLLOW_103_in_primaryExpression2345) if self._state.backtracking == 0: string_literal412_tree = self._adaptor.createWithPayload(string_literal412) self._adaptor.addChild(root_0, string_literal412_tree) elif alt212 == 2: # JavaScript.g:355:4: Identifier pass root_0 = self._adaptor.nil() Identifier413=self.match(self.input, Identifier, self.FOLLOW_Identifier_in_primaryExpression2350) if self._state.backtracking == 0: Identifier413_tree = self._adaptor.createWithPayload(Identifier413) self._adaptor.addChild(root_0, Identifier413_tree) elif alt212 == 3: # JavaScript.g:356:4: literal pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_literal_in_primaryExpression2355) literal414 = self.literal() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, literal414.tree) elif alt212 == 4: # JavaScript.g:357:4: arrayLiteral pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_arrayLiteral_in_primaryExpression2360) arrayLiteral415 = self.arrayLiteral() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, arrayLiteral415.tree) elif alt212 == 5: # JavaScript.g:358:4: objectLiteral pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_objectLiteral_in_primaryExpression2365) objectLiteral416 = self.objectLiteral() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, objectLiteral416.tree) elif alt212 == 6: # JavaScript.g:359:4: '(' ( LT )* expression ( LT )* ')' pass root_0 = self._adaptor.nil() char_literal417=self.match(self.input, 32, self.FOLLOW_32_in_primaryExpression2370) if self._state.backtracking == 0: char_literal417_tree = self._adaptor.createWithPayload(char_literal417) self._adaptor.addChild(root_0, char_literal417_tree) # JavaScript.g:359:10: ( LT )* while True: #loop210 alt210 = 2 LA210_0 = self.input.LA(1) if (LA210_0 == LT) : alt210 = 1 if alt210 == 1: # JavaScript.g:0:0: LT pass LT418=self.match(self.input, LT, self.FOLLOW_LT_in_primaryExpression2372) else: break #loop210 self._state.following.append(self.FOLLOW_expression_in_primaryExpression2376) expression419 = self.expression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expression419.tree) # JavaScript.g:359:26: ( LT )* while True: #loop211 alt211 = 2 LA211_0 = self.input.LA(1) if (LA211_0 == LT) : alt211 = 1 if alt211 == 1: # JavaScript.g:0:0: LT pass LT420=self.match(self.input, LT, self.FOLLOW_LT_in_primaryExpression2378) else: break #loop211 char_literal421=self.match(self.input, 34, self.FOLLOW_34_in_primaryExpression2382) if self._state.backtracking == 0: char_literal421_tree = self._adaptor.createWithPayload(char_literal421) self._adaptor.addChild(root_0, char_literal421_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 76, primaryExpression_StartIndex, success) pass return retval # $ANTLR end "primaryExpression" class arrayLiteral_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.arrayLiteral_return, self).__init__() self.tree = None # $ANTLR start "arrayLiteral" # JavaScript.g:363:1: arrayLiteral : '[' ( LT )* ( assignmentExpression )? ( ( LT )* ',' ( ( LT )* assignmentExpression )? )* ( LT )* ']' ; def arrayLiteral(self, ): retval = self.arrayLiteral_return() retval.start = self.input.LT(1) arrayLiteral_StartIndex = self.input.index() root_0 = None char_literal422 = None LT423 = None LT425 = None char_literal426 = None LT427 = None LT429 = None char_literal430 = None assignmentExpression424 = None assignmentExpression428 = None char_literal422_tree = None LT423_tree = None LT425_tree = None char_literal426_tree = None LT427_tree = None LT429_tree = None char_literal430_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 77): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:364:2: ( '[' ( LT )* ( assignmentExpression )? ( ( LT )* ',' ( ( LT )* assignmentExpression )? )* ( LT )* ']' ) # JavaScript.g:364:4: '[' ( LT )* ( assignmentExpression )? ( ( LT )* ',' ( ( LT )* assignmentExpression )? )* ( LT )* ']' pass root_0 = self._adaptor.nil() char_literal422=self.match(self.input, 59, self.FOLLOW_59_in_arrayLiteral2395) if self._state.backtracking == 0: char_literal422_tree = self._adaptor.createWithPayload(char_literal422) self._adaptor.addChild(root_0, char_literal422_tree) # JavaScript.g:364:10: ( LT )* while True: #loop213 alt213 = 2 LA213_0 = self.input.LA(1) if (LA213_0 == LT) : LA213_2 = self.input.LA(2) if (self.synpred280_JavaScript()) : alt213 = 1 if alt213 == 1: # JavaScript.g:0:0: LT pass LT423=self.match(self.input, LT, self.FOLLOW_LT_in_arrayLiteral2397) else: break #loop213 # JavaScript.g:364:13: ( assignmentExpression )? alt214 = 2 LA214_0 = self.input.LA(1) if ((Identifier <= LA214_0 <= NumericLiteral) or (31 <= LA214_0 <= 32) or LA214_0 == 35 or (58 <= LA214_0 <= 59) or (91 <= LA214_0 <= 92) or (96 <= LA214_0 <= 106)) : alt214 = 1 if alt214 == 1: # JavaScript.g:0:0: assignmentExpression pass self._state.following.append(self.FOLLOW_assignmentExpression_in_arrayLiteral2401) assignmentExpression424 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression424.tree) # JavaScript.g:364:35: ( ( LT )* ',' ( ( LT )* assignmentExpression )? )* while True: #loop218 alt218 = 2 alt218 = self.dfa218.predict(self.input) if alt218 == 1: # JavaScript.g:364:36: ( LT )* ',' ( ( LT )* assignmentExpression )? pass # JavaScript.g:364:38: ( LT )* while True: #loop215 alt215 = 2 LA215_0 = self.input.LA(1) if (LA215_0 == LT) : alt215 = 1 if alt215 == 1: # JavaScript.g:0:0: LT pass LT425=self.match(self.input, LT, self.FOLLOW_LT_in_arrayLiteral2405) else: break #loop215 char_literal426=self.match(self.input, 33, self.FOLLOW_33_in_arrayLiteral2409) if self._state.backtracking == 0: char_literal426_tree = self._adaptor.createWithPayload(char_literal426) self._adaptor.addChild(root_0, char_literal426_tree) # JavaScript.g:364:45: ( ( LT )* assignmentExpression )? alt217 = 2 alt217 = self.dfa217.predict(self.input) if alt217 == 1: # JavaScript.g:364:46: ( LT )* assignmentExpression pass # JavaScript.g:364:48: ( LT )* while True: #loop216 alt216 = 2 LA216_0 = self.input.LA(1) if (LA216_0 == LT) : alt216 = 1 if alt216 == 1: # JavaScript.g:0:0: LT pass LT427=self.match(self.input, LT, self.FOLLOW_LT_in_arrayLiteral2412) else: break #loop216 self._state.following.append(self.FOLLOW_assignmentExpression_in_arrayLiteral2416) assignmentExpression428 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression428.tree) else: break #loop218 # JavaScript.g:364:78: ( LT )* while True: #loop219 alt219 = 2 LA219_0 = self.input.LA(1) if (LA219_0 == LT) : alt219 = 1 if alt219 == 1: # JavaScript.g:0:0: LT pass LT429=self.match(self.input, LT, self.FOLLOW_LT_in_arrayLiteral2422) else: break #loop219 char_literal430=self.match(self.input, 60, self.FOLLOW_60_in_arrayLiteral2426) if self._state.backtracking == 0: char_literal430_tree = self._adaptor.createWithPayload(char_literal430) self._adaptor.addChild(root_0, char_literal430_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 77, arrayLiteral_StartIndex, success) pass return retval # $ANTLR end "arrayLiteral" class objectLiteral_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.objectLiteral_return, self).__init__() self.tree = None # $ANTLR start "objectLiteral" # JavaScript.g:368:1: objectLiteral : '{' ( LT )* propertyNameAndValue ( ( LT )* ',' ( LT )* propertyNameAndValue )* ( LT )* '}' ; def objectLiteral(self, ): retval = self.objectLiteral_return() retval.start = self.input.LT(1) objectLiteral_StartIndex = self.input.index() root_0 = None char_literal431 = None LT432 = None LT434 = None char_literal435 = None LT436 = None LT438 = None char_literal439 = None propertyNameAndValue433 = None propertyNameAndValue437 = None char_literal431_tree = None LT432_tree = None LT434_tree = None char_literal435_tree = None LT436_tree = None LT438_tree = None char_literal439_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 78): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:369:2: ( '{' ( LT )* propertyNameAndValue ( ( LT )* ',' ( LT )* propertyNameAndValue )* ( LT )* '}' ) # JavaScript.g:369:4: '{' ( LT )* propertyNameAndValue ( ( LT )* ',' ( LT )* propertyNameAndValue )* ( LT )* '}' pass root_0 = self._adaptor.nil() char_literal431=self.match(self.input, 35, self.FOLLOW_35_in_objectLiteral2445) if self._state.backtracking == 0: char_literal431_tree = self._adaptor.createWithPayload(char_literal431) self._adaptor.addChild(root_0, char_literal431_tree) # JavaScript.g:369:10: ( LT )* while True: #loop220 alt220 = 2 LA220_0 = self.input.LA(1) if (LA220_0 == LT) : alt220 = 1 if alt220 == 1: # JavaScript.g:0:0: LT pass LT432=self.match(self.input, LT, self.FOLLOW_LT_in_objectLiteral2447) else: break #loop220 self._state.following.append(self.FOLLOW_propertyNameAndValue_in_objectLiteral2451) propertyNameAndValue433 = self.propertyNameAndValue() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, propertyNameAndValue433.tree) # JavaScript.g:369:34: ( ( LT )* ',' ( LT )* propertyNameAndValue )* while True: #loop223 alt223 = 2 alt223 = self.dfa223.predict(self.input) if alt223 == 1: # JavaScript.g:369:35: ( LT )* ',' ( LT )* propertyNameAndValue pass # JavaScript.g:369:37: ( LT )* while True: #loop221 alt221 = 2 LA221_0 = self.input.LA(1) if (LA221_0 == LT) : alt221 = 1 if alt221 == 1: # JavaScript.g:0:0: LT pass LT434=self.match(self.input, LT, self.FOLLOW_LT_in_objectLiteral2454) else: break #loop221 char_literal435=self.match(self.input, 33, self.FOLLOW_33_in_objectLiteral2458) if self._state.backtracking == 0: char_literal435_tree = self._adaptor.createWithPayload(char_literal435) self._adaptor.addChild(root_0, char_literal435_tree) # JavaScript.g:369:46: ( LT )* while True: #loop222 alt222 = 2 LA222_0 = self.input.LA(1) if (LA222_0 == LT) : alt222 = 1 if alt222 == 1: # JavaScript.g:0:0: LT pass LT436=self.match(self.input, LT, self.FOLLOW_LT_in_objectLiteral2460) else: break #loop222 self._state.following.append(self.FOLLOW_propertyNameAndValue_in_objectLiteral2464) propertyNameAndValue437 = self.propertyNameAndValue() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, propertyNameAndValue437.tree) else: break #loop223 # JavaScript.g:369:74: ( LT )* while True: #loop224 alt224 = 2 LA224_0 = self.input.LA(1) if (LA224_0 == LT) : alt224 = 1 if alt224 == 1: # JavaScript.g:0:0: LT pass LT438=self.match(self.input, LT, self.FOLLOW_LT_in_objectLiteral2468) else: break #loop224 char_literal439=self.match(self.input, 36, self.FOLLOW_36_in_objectLiteral2472) if self._state.backtracking == 0: char_literal439_tree = self._adaptor.createWithPayload(char_literal439) self._adaptor.addChild(root_0, char_literal439_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 78, objectLiteral_StartIndex, success) pass return retval # $ANTLR end "objectLiteral" class propertyNameAndValue_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.propertyNameAndValue_return, self).__init__() self.tree = None # $ANTLR start "propertyNameAndValue" # JavaScript.g:372:1: propertyNameAndValue : propertyName ( LT )* ':' ( LT )* assignmentExpression ; def propertyNameAndValue(self, ): retval = self.propertyNameAndValue_return() retval.start = self.input.LT(1) propertyNameAndValue_StartIndex = self.input.index() root_0 = None LT441 = None char_literal442 = None LT443 = None propertyName440 = None assignmentExpression444 = None LT441_tree = None char_literal442_tree = None LT443_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 79): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:373:2: ( propertyName ( LT )* ':' ( LT )* assignmentExpression ) # JavaScript.g:373:4: propertyName ( LT )* ':' ( LT )* assignmentExpression pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_propertyName_in_propertyNameAndValue2484) propertyName440 = self.propertyName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, propertyName440.tree) # JavaScript.g:373:19: ( LT )* while True: #loop225 alt225 = 2 LA225_0 = self.input.LA(1) if (LA225_0 == LT) : alt225 = 1 if alt225 == 1: # JavaScript.g:0:0: LT pass LT441=self.match(self.input, LT, self.FOLLOW_LT_in_propertyNameAndValue2486) else: break #loop225 char_literal442=self.match(self.input, 50, self.FOLLOW_50_in_propertyNameAndValue2490) if self._state.backtracking == 0: char_literal442_tree = self._adaptor.createWithPayload(char_literal442) self._adaptor.addChild(root_0, char_literal442_tree) # JavaScript.g:373:28: ( LT )* while True: #loop226 alt226 = 2 LA226_0 = self.input.LA(1) if (LA226_0 == LT) : alt226 = 1 if alt226 == 1: # JavaScript.g:0:0: LT pass LT443=self.match(self.input, LT, self.FOLLOW_LT_in_propertyNameAndValue2492) else: break #loop226 self._state.following.append(self.FOLLOW_assignmentExpression_in_propertyNameAndValue2496) assignmentExpression444 = self.assignmentExpression() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, assignmentExpression444.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 79, propertyNameAndValue_StartIndex, success) pass return retval # $ANTLR end "propertyNameAndValue" class propertyName_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.propertyName_return, self).__init__() self.tree = None # $ANTLR start "propertyName" # JavaScript.g:376:1: propertyName : ( Identifier | StringLiteral | NumericLiteral ); def propertyName(self, ): retval = self.propertyName_return() retval.start = self.input.LT(1) propertyName_StartIndex = self.input.index() root_0 = None set445 = None set445_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 80): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:377:2: ( Identifier | StringLiteral | NumericLiteral ) # JavaScript.g: pass root_0 = self._adaptor.nil() set445 = self.input.LT(1) if (Identifier <= self.input.LA(1) <= NumericLiteral): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set445)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 80, propertyName_StartIndex, success) pass return retval # $ANTLR end "propertyName" class literal_return(ParserRuleReturnScope): def __init__(self): super(JavaScriptParser.literal_return, self).__init__() self.tree = None # $ANTLR start "literal" # JavaScript.g:383:1: literal : ( 'null' | 'true' | 'false' | StringLiteral | NumericLiteral ); def literal(self, ): retval = self.literal_return() retval.start = self.input.LT(1) literal_StartIndex = self.input.index() root_0 = None set446 = None set446_tree = None success = False try: try: if self._state.backtracking > 0 and self.alreadyParsedRule(self.input, 81): # for cached failed rules, alreadyParsedRule will raise an exception success = True return retval # JavaScript.g:384:2: ( 'null' | 'true' | 'false' | StringLiteral | NumericLiteral ) # JavaScript.g: pass root_0 = self._adaptor.nil() set446 = self.input.LT(1) if (StringLiteral <= self.input.LA(1) <= NumericLiteral) or (104 <= self.input.LA(1) <= 106): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set446)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) success = True except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: if self._state.backtracking > 0: self.memoize(self.input, 81, literal_StartIndex, success) pass return retval # $ANTLR end "literal" # $ANTLR start "synpred5_JavaScript" def synpred5_JavaScript_fragment(self, ): # JavaScript.g:32:4: ( functionDeclaration ) # JavaScript.g:32:4: functionDeclaration pass self._state.following.append(self.FOLLOW_functionDeclaration_in_synpred5_JavaScript90) self.functionDeclaration() self._state.following.pop() # $ANTLR end "synpred5_JavaScript" # $ANTLR start "synpred9_JavaScript" def synpred9_JavaScript_fragment(self, ): # JavaScript.g:42:15: ( LT ) # JavaScript.g:42:15: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred9_JavaScript140) # $ANTLR end "synpred9_JavaScript" # $ANTLR start "synpred21_JavaScript" def synpred21_JavaScript_fragment(self, ): # JavaScript.g:55:4: ( statementBlock ) # JavaScript.g:55:4: statementBlock pass self._state.following.append(self.FOLLOW_statementBlock_in_synpred21_JavaScript234) self.statementBlock() self._state.following.pop() # $ANTLR end "synpred21_JavaScript" # $ANTLR start "synpred24_JavaScript" def synpred24_JavaScript_fragment(self, ): # JavaScript.g:58:4: ( expressionStatement ) # JavaScript.g:58:4: expressionStatement pass self._state.following.append(self.FOLLOW_expressionStatement_in_synpred24_JavaScript249) self.expressionStatement() self._state.following.pop() # $ANTLR end "synpred24_JavaScript" # $ANTLR start "synpred31_JavaScript" def synpred31_JavaScript_fragment(self, ): # JavaScript.g:65:4: ( labelledStatement ) # JavaScript.g:65:4: labelledStatement pass self._state.following.append(self.FOLLOW_labelledStatement_in_synpred31_JavaScript284) self.labelledStatement() self._state.following.pop() # $ANTLR end "synpred31_JavaScript" # $ANTLR start "synpred34_JavaScript" def synpred34_JavaScript_fragment(self, ): # JavaScript.g:72:8: ( LT ) # JavaScript.g:72:8: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred34_JavaScript313) # $ANTLR end "synpred34_JavaScript" # $ANTLR start "synpred47_JavaScript" def synpred47_JavaScript_fragment(self, ): # JavaScript.g:92:15: ( LT ) # JavaScript.g:92:15: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred47_JavaScript440) # $ANTLR end "synpred47_JavaScript" # $ANTLR start "synpred49_JavaScript" def synpred49_JavaScript_fragment(self, ): # JavaScript.g:96:15: ( LT ) # JavaScript.g:96:15: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred49_JavaScript459) # $ANTLR end "synpred49_JavaScript" # $ANTLR start "synpred60_JavaScript" def synpred60_JavaScript_fragment(self, ): # JavaScript.g:116:59: ( ( LT )* 'else' ( LT )* statement ) # JavaScript.g:116:59: ( LT )* 'else' ( LT )* statement pass # JavaScript.g:116:61: ( LT )* while True: #loop239 alt239 = 2 LA239_0 = self.input.LA(1) if (LA239_0 == LT) : alt239 = 1 if alt239 == 1: # JavaScript.g:0:0: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred60_JavaScript572) else: break #loop239 self.match(self.input, 41, self.FOLLOW_41_in_synpred60_JavaScript576) # JavaScript.g:116:73: ( LT )* while True: #loop240 alt240 = 2 LA240_0 = self.input.LA(1) if (LA240_0 == LT) : alt240 = 1 if alt240 == 1: # JavaScript.g:0:0: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred60_JavaScript578) else: break #loop240 self._state.following.append(self.FOLLOW_statement_in_synpred60_JavaScript582) self.statement() self._state.following.pop() # $ANTLR end "synpred60_JavaScript" # $ANTLR start "synpred63_JavaScript" def synpred63_JavaScript_fragment(self, ): # JavaScript.g:122:4: ( forStatement ) # JavaScript.g:122:4: forStatement pass self._state.following.append(self.FOLLOW_forStatement_in_synpred63_JavaScript606) self.forStatement() self._state.following.pop() # $ANTLR end "synpred63_JavaScript" # $ANTLR start "synpred118_JavaScript" def synpred118_JavaScript_fragment(self, ): # JavaScript.g:181:36: ( LT ) # JavaScript.g:181:36: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred118_JavaScript1087) # $ANTLR end "synpred118_JavaScript" # $ANTLR start "synpred121_JavaScript" def synpred121_JavaScript_fragment(self, ): # JavaScript.g:185:23: ( LT ) # JavaScript.g:185:23: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred121_JavaScript1112) # $ANTLR end "synpred121_JavaScript" # $ANTLR start "synpred140_JavaScript" def synpred140_JavaScript_fragment(self, ): # JavaScript.g:214:4: ( conditionalExpression ) # JavaScript.g:214:4: conditionalExpression pass self._state.following.append(self.FOLLOW_conditionalExpression_in_synpred140_JavaScript1304) self.conditionalExpression() self._state.following.pop() # $ANTLR end "synpred140_JavaScript" # $ANTLR start "synpred143_JavaScript" def synpred143_JavaScript_fragment(self, ): # JavaScript.g:219:4: ( conditionalExpressionNoIn ) # JavaScript.g:219:4: conditionalExpressionNoIn pass self._state.following.append(self.FOLLOW_conditionalExpressionNoIn_in_synpred143_JavaScript1333) self.conditionalExpressionNoIn() self._state.following.pop() # $ANTLR end "synpred143_JavaScript" # $ANTLR start "synpred146_JavaScript" def synpred146_JavaScript_fragment(self, ): # JavaScript.g:224:4: ( callExpression ) # JavaScript.g:224:4: callExpression pass self._state.following.append(self.FOLLOW_callExpression_in_synpred146_JavaScript1362) self.callExpression() self._state.following.pop() # $ANTLR end "synpred146_JavaScript" # $ANTLR start "synpred147_JavaScript" def synpred147_JavaScript_fragment(self, ): # JavaScript.g:229:4: ( memberExpression ) # JavaScript.g:229:4: memberExpression pass self._state.following.append(self.FOLLOW_memberExpression_in_synpred147_JavaScript1379) self.memberExpression() self._state.following.pop() # $ANTLR end "synpred147_JavaScript" # $ANTLR start "synpred154_JavaScript" def synpred154_JavaScript_fragment(self, ): # JavaScript.g:234:91: ( ( LT )* memberExpressionSuffix ) # JavaScript.g:234:91: ( LT )* memberExpressionSuffix pass # JavaScript.g:234:93: ( LT )* while True: #loop254 alt254 = 2 LA254_0 = self.input.LA(1) if (LA254_0 == LT) : alt254 = 1 if alt254 == 1: # JavaScript.g:0:0: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred154_JavaScript1427) else: break #loop254 self._state.following.append(self.FOLLOW_memberExpressionSuffix_in_synpred154_JavaScript1431) self.memberExpressionSuffix() self._state.following.pop() # $ANTLR end "synpred154_JavaScript" # $ANTLR start "synpred158_JavaScript" def synpred158_JavaScript_fragment(self, ): # JavaScript.g:243:37: ( ( LT )* callExpressionSuffix ) # JavaScript.g:243:37: ( LT )* callExpressionSuffix pass # JavaScript.g:243:39: ( LT )* while True: #loop255 alt255 = 2 LA255_0 = self.input.LA(1) if (LA255_0 == LT) : alt255 = 1 if alt255 == 1: # JavaScript.g:0:0: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred158_JavaScript1470) else: break #loop255 self._state.following.append(self.FOLLOW_callExpressionSuffix_in_synpred158_JavaScript1474) self.callExpressionSuffix() self._state.following.pop() # $ANTLR end "synpred158_JavaScript" # $ANTLR start "synpred256_JavaScript" def synpred256_JavaScript_fragment(self, ): # JavaScript.g:337:30: ( ( LT )* ( '+' | '-' ) ( LT )* multiplicativeExpression ) # JavaScript.g:337:30: ( LT )* ( '+' | '-' ) ( LT )* multiplicativeExpression pass # JavaScript.g:337:32: ( LT )* while True: #loop300 alt300 = 2 LA300_0 = self.input.LA(1) if (LA300_0 == LT) : alt300 = 1 if alt300 == 1: # JavaScript.g:0:0: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred256_JavaScript2207) else: break #loop300 if (91 <= self.input.LA(1) <= 92): self.input.consume() self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse # JavaScript.g:337:49: ( LT )* while True: #loop301 alt301 = 2 LA301_0 = self.input.LA(1) if (LA301_0 == LT) : alt301 = 1 if alt301 == 1: # JavaScript.g:0:0: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred256_JavaScript2219) else: break #loop301 self._state.following.append(self.FOLLOW_multiplicativeExpression_in_synpred256_JavaScript2223) self.multiplicativeExpression() self._state.following.pop() # $ANTLR end "synpred256_JavaScript" # $ANTLR start "synpred280_JavaScript" def synpred280_JavaScript_fragment(self, ): # JavaScript.g:364:8: ( LT ) # JavaScript.g:364:8: LT pass self.match(self.input, LT, self.FOLLOW_LT_in_synpred280_JavaScript2397) # $ANTLR end "synpred280_JavaScript" # Delegated rules def synpred60_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred60_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred121_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred121_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred146_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred146_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred154_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred154_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred34_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred34_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred147_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred147_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred63_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred63_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred47_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred47_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred256_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred256_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred280_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred280_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred118_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred118_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred158_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred158_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred9_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred9_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred21_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred21_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred31_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred31_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred49_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred49_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred24_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred24_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred143_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred143_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred140_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred140_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred5_JavaScript(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred5_JavaScript_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success # lookup tables for DFA #4 DFA4_eot = DFA.unpack( u"\4\uffff" ) DFA4_eof = DFA.unpack( u"\2\2\2\uffff" ) DFA4_min = DFA.unpack( u"\2\4\2\uffff" ) DFA4_max = DFA.unpack( u"\2\152\2\uffff" ) DFA4_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA4_special = DFA.unpack( u"\4\uffff" ) DFA4_transition = [ DFA.unpack(u"\1\1\3\3\27\uffff\2\3\2\uffff\1\3\1\2\2\3\1\uffff\1" u"\3\1\uffff\3\3\1\uffff\4\3\1\uffff\1\3\2\uffff\2\3\2\uffff\2\3" u"\37\uffff\2\3\3\uffff\13\3"), DFA.unpack(u"\1\1\3\3\27\uffff\2\3\2\uffff\1\3\1\2\2\3\1\uffff\1" u"\3\1\uffff\3\3\1\uffff\4\3\1\uffff\1\3\2\uffff\2\3\2\uffff\2\3" u"\37\uffff\2\3\3\uffff\13\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #4 class DFA4(DFA): pass # lookup tables for DFA #5 DFA5_eot = DFA.unpack( u"\30\uffff" ) DFA5_eof = DFA.unpack( u"\30\uffff" ) DFA5_min = DFA.unpack( u"\1\5\1\0\26\uffff" ) DFA5_max = DFA.unpack( u"\1\152\1\0\26\uffff" ) DFA5_accept = DFA.unpack( u"\2\uffff\1\2\24\uffff\1\1" ) DFA5_special = DFA.unpack( u"\1\uffff\1\0\26\uffff" ) DFA5_transition = [ DFA.unpack(u"\3\2\27\uffff\1\1\1\2\2\uffff\1\2\1\uffff\2\2\1\uffff" u"\1\2\1\uffff\3\2\1\uffff\4\2\1\uffff\1\2\2\uffff\2\2\2\uffff\2" u"\2\37\uffff\2\2\3\uffff\13\2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #5 class DFA5(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA5_1 = input.LA(1) index5_1 = input.index() input.rewind() s = -1 if (self.synpred5_JavaScript()): s = 23 elif (True): s = 2 input.seek(index5_1) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 5, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #17 DFA17_eot = DFA.unpack( u"\4\uffff" ) DFA17_eof = DFA.unpack( u"\4\uffff" ) DFA17_min = DFA.unpack( u"\2\4\2\uffff" ) DFA17_max = DFA.unpack( u"\2\42\2\uffff" ) DFA17_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA17_special = DFA.unpack( u"\4\uffff" ) DFA17_transition = [ DFA.unpack(u"\1\1\1\2\34\uffff\1\3"), DFA.unpack(u"\1\1\1\2\34\uffff\1\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #17 class DFA17(DFA): pass # lookup tables for DFA #16 DFA16_eot = DFA.unpack( u"\4\uffff" ) DFA16_eof = DFA.unpack( u"\4\uffff" ) DFA16_min = DFA.unpack( u"\2\4\2\uffff" ) DFA16_max = DFA.unpack( u"\2\42\2\uffff" ) DFA16_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA16_special = DFA.unpack( u"\4\uffff" ) DFA16_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\1\2"), DFA.unpack(u"\1\1\34\uffff\1\3\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #16 class DFA16(DFA): pass # lookup tables for DFA #21 DFA21_eot = DFA.unpack( u"\31\uffff" ) DFA21_eof = DFA.unpack( u"\31\uffff" ) DFA21_min = DFA.unpack( u"\1\5\1\0\3\uffff\1\0\23\uffff" ) DFA21_max = DFA.unpack( u"\1\152\1\0\3\uffff\1\0\23\uffff" ) DFA21_accept = DFA.unpack( u"\2\uffff\1\2\1\3\1\4\7\uffff\1\5\1\6\2\uffff\1\7\1\10\1\11\1\12" u"\1\14\1\15\1\16\1\1\1\13" ) DFA21_special = DFA.unpack( u"\1\uffff\1\0\3\uffff\1\1\23\uffff" ) DFA21_transition = [ DFA.unpack(u"\1\5\2\4\27\uffff\2\4\2\uffff\1\1\1\uffff\1\2\1\3\1" u"\uffff\1\14\1\uffff\3\15\1\uffff\1\20\1\21\1\22\1\23\1\uffff\1" u"\24\2\uffff\1\25\1\26\2\uffff\2\4\37\uffff\2\4\3\uffff\13\4"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #21 class DFA21(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA21_1 = input.LA(1) index21_1 = input.index() input.rewind() s = -1 if (self.synpred21_JavaScript()): s = 23 elif (self.synpred24_JavaScript()): s = 4 input.seek(index21_1) if s >= 0: return s elif s == 1: LA21_5 = input.LA(1) index21_5 = input.index() input.rewind() s = -1 if (self.synpred24_JavaScript()): s = 4 elif (self.synpred31_JavaScript()): s = 24 input.seek(index21_5) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 21, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #26 DFA26_eot = DFA.unpack( u"\4\uffff" ) DFA26_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA26_min = DFA.unpack( u"\2\4\2\uffff" ) DFA26_max = DFA.unpack( u"\2\152\2\uffff" ) DFA26_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA26_special = DFA.unpack( u"\4\uffff" ) DFA26_transition = [ DFA.unpack(u"\1\1\3\3\27\uffff\2\3\2\uffff\1\3\1\2\2\3\1\uffff\1" u"\3\1\uffff\3\3\1\uffff\4\3\1\uffff\1\3\2\2\2\3\2\uffff\2\3\37\uffff" u"\2\3\3\uffff\13\3"), DFA.unpack(u"\1\1\3\3\27\uffff\2\3\2\uffff\1\3\1\2\2\3\1\uffff\1" u"\3\1\uffff\3\3\1\uffff\4\3\1\uffff\1\3\2\2\2\3\2\uffff\2\3\37\uffff" u"\2\3\3\uffff\13\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #26 class DFA26(DFA): pass # lookup tables for DFA #30 DFA30_eot = DFA.unpack( u"\5\uffff" ) DFA30_eof = DFA.unpack( u"\1\uffff\1\2\2\uffff\1\2" ) DFA30_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA30_max = DFA.unpack( u"\1\46\1\152\2\uffff\1\152" ) DFA30_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA30_special = DFA.unpack( u"\5\uffff" ) DFA30_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\4\uffff\1\2"), DFA.unpack(u"\1\4\3\2\27\uffff\2\2\1\3\1\uffff\4\2\1\uffff\5\2\1" u"\uffff\4\2\1\uffff\5\2\2\uffff\2\2\37\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\2\2\1\3\1\uffff\4\2\1\uffff\5\2\1" u"\uffff\4\2\1\uffff\5\2\2\uffff\2\2\37\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #30 class DFA30(DFA): pass # lookup tables for DFA #33 DFA33_eot = DFA.unpack( u"\4\uffff" ) DFA33_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA33_min = DFA.unpack( u"\2\4\2\uffff" ) DFA33_max = DFA.unpack( u"\2\46\2\uffff" ) DFA33_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA33_special = DFA.unpack( u"\4\uffff" ) DFA33_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\4\uffff\1\2"), DFA.unpack(u"\1\1\34\uffff\1\3\4\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #33 class DFA33(DFA): pass # lookup tables for DFA #57 DFA57_eot = DFA.unpack( u"\4\uffff" ) DFA57_eof = DFA.unpack( u"\4\uffff" ) DFA57_min = DFA.unpack( u"\2\4\2\uffff" ) DFA57_max = DFA.unpack( u"\2\152\2\uffff" ) DFA57_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA57_special = DFA.unpack( u"\4\uffff" ) DFA57_transition = [ DFA.unpack(u"\1\1\3\2\27\uffff\2\2\2\uffff\1\2\1\uffff\1\2\1\3\23" u"\uffff\2\2\37\uffff\2\2\3\uffff\13\2"), DFA.unpack(u"\1\1\3\2\27\uffff\2\2\2\uffff\1\2\1\uffff\1\2\1\3\23" u"\uffff\2\2\37\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #57 class DFA57(DFA): pass # lookup tables for DFA #60 DFA60_eot = DFA.unpack( u"\4\uffff" ) DFA60_eof = DFA.unpack( u"\4\uffff" ) DFA60_min = DFA.unpack( u"\2\4\2\uffff" ) DFA60_max = DFA.unpack( u"\2\152\2\uffff" ) DFA60_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA60_special = DFA.unpack( u"\4\uffff" ) DFA60_transition = [ DFA.unpack(u"\1\1\3\2\27\uffff\2\2\2\uffff\1\2\2\uffff\1\3\23\uffff" u"\2\2\37\uffff\2\2\3\uffff\13\2"), DFA.unpack(u"\1\1\3\2\27\uffff\2\2\2\uffff\1\2\2\uffff\1\3\23\uffff" u"\2\2\37\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #60 class DFA60(DFA): pass # lookup tables for DFA #63 DFA63_eot = DFA.unpack( u"\4\uffff" ) DFA63_eof = DFA.unpack( u"\4\uffff" ) DFA63_min = DFA.unpack( u"\2\4\2\uffff" ) DFA63_max = DFA.unpack( u"\2\152\2\uffff" ) DFA63_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA63_special = DFA.unpack( u"\4\uffff" ) DFA63_transition = [ DFA.unpack(u"\1\1\3\2\27\uffff\2\2\1\uffff\1\3\1\2\26\uffff\2\2\37" u"\uffff\2\2\3\uffff\13\2"), DFA.unpack(u"\1\1\3\2\27\uffff\2\2\1\uffff\1\3\1\2\26\uffff\2\2" u"\37\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #63 class DFA63(DFA): pass # lookup tables for DFA #90 DFA90_eot = DFA.unpack( u"\4\uffff" ) DFA90_eof = DFA.unpack( u"\4\uffff" ) DFA90_min = DFA.unpack( u"\2\4\2\uffff" ) DFA90_max = DFA.unpack( u"\2\65\2\uffff" ) DFA90_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA90_special = DFA.unpack( u"\4\uffff" ) DFA90_transition = [ DFA.unpack(u"\1\1\37\uffff\1\2\17\uffff\1\3\1\2"), DFA.unpack(u"\1\1\37\uffff\1\2\17\uffff\1\3\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #90 class DFA90(DFA): pass # lookup tables for DFA #94 DFA94_eot = DFA.unpack( u"\4\uffff" ) DFA94_eof = DFA.unpack( u"\4\uffff" ) DFA94_min = DFA.unpack( u"\2\4\2\uffff" ) DFA94_max = DFA.unpack( u"\2\65\2\uffff" ) DFA94_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA94_special = DFA.unpack( u"\4\uffff" ) DFA94_transition = [ DFA.unpack(u"\1\1\37\uffff\1\3\20\uffff\1\2"), DFA.unpack(u"\1\1\37\uffff\1\3\20\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #94 class DFA94(DFA): pass # lookup tables for DFA #93 DFA93_eot = DFA.unpack( u"\4\uffff" ) DFA93_eof = DFA.unpack( u"\4\uffff" ) DFA93_min = DFA.unpack( u"\2\4\2\uffff" ) DFA93_max = DFA.unpack( u"\2\64\2\uffff" ) DFA93_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA93_special = DFA.unpack( u"\4\uffff" ) DFA93_transition = [ DFA.unpack(u"\1\1\37\uffff\1\2\17\uffff\1\3"), DFA.unpack(u"\1\1\37\uffff\1\2\17\uffff\1\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #93 class DFA93(DFA): pass # lookup tables for DFA #106 DFA106_eot = DFA.unpack( u"\4\uffff" ) DFA106_eof = DFA.unpack( u"\2\3\2\uffff" ) DFA106_min = DFA.unpack( u"\2\4\2\uffff" ) DFA106_max = DFA.unpack( u"\2\152\2\uffff" ) DFA106_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA106_special = DFA.unpack( u"\4\uffff" ) DFA106_transition = [ DFA.unpack(u"\1\1\3\3\27\uffff\2\3\2\uffff\4\3\1\uffff\5\3\1\uffff" u"\4\3\1\uffff\5\3\1\uffff\1\2\2\3\37\uffff\2\3\3\uffff\13\3"), DFA.unpack(u"\1\1\3\3\27\uffff\2\3\2\uffff\4\3\1\uffff\5\3\1\uffff" u"\4\3\1\uffff\5\3\1\uffff\1\2\2\3\37\uffff\2\3\3\uffff\13\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #106 class DFA106(DFA): pass # lookup tables for DFA #115 DFA115_eot = DFA.unpack( u"\5\uffff" ) DFA115_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA115_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA115_max = DFA.unpack( u"\1\74\1\152\2\uffff\1\152" ) DFA115_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA115_special = DFA.unpack( u"\5\uffff" ) DFA115_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\1\2\3\uffff\1\2\13\uffff\1\2\11\uffff" u"\1\2"), DFA.unpack(u"\1\4\3\2\27\uffff\2\2\1\3\5\2\1\uffff\5\2\1\uffff\12" u"\2\2\uffff\3\2\36\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\2\2\1\3\5\2\1\uffff\5\2\1\uffff\12" u"\2\2\uffff\3\2\36\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #115 class DFA115(DFA): pass # lookup tables for DFA #118 DFA118_eot = DFA.unpack( u"\4\uffff" ) DFA118_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA118_min = DFA.unpack( u"\2\4\2\uffff" ) DFA118_max = DFA.unpack( u"\2\46\2\uffff" ) DFA118_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA118_special = DFA.unpack( u"\4\uffff" ) DFA118_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\4\uffff\1\2"), DFA.unpack(u"\1\1\34\uffff\1\3\4\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #118 class DFA118(DFA): pass # lookup tables for DFA #121 DFA121_eot = DFA.unpack( u"\13\uffff" ) DFA121_eof = DFA.unpack( u"\13\uffff" ) DFA121_min = DFA.unpack( u"\1\5\10\0\2\uffff" ) DFA121_max = DFA.unpack( u"\1\152\10\0\2\uffff" ) DFA121_accept = DFA.unpack( u"\11\uffff\1\1\1\2" ) DFA121_special = DFA.unpack( u"\1\uffff\1\0\1\1\1\2\1\3\1\4\1\5\1\6\1\7\2\uffff" ) DFA121_transition = [ DFA.unpack(u"\1\2\2\3\27\uffff\1\7\1\6\2\uffff\1\5\26\uffff\1\10" u"\1\4\37\uffff\2\11\3\uffff\7\11\1\1\3\3"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #121 class DFA121(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA121_1 = input.LA(1) index121_1 = input.index() input.rewind() s = -1 if (self.synpred140_JavaScript()): s = 9 elif (True): s = 10 input.seek(index121_1) if s >= 0: return s elif s == 1: LA121_2 = input.LA(1) index121_2 = input.index() input.rewind() s = -1 if (self.synpred140_JavaScript()): s = 9 elif (True): s = 10 input.seek(index121_2) if s >= 0: return s elif s == 2: LA121_3 = input.LA(1) index121_3 = input.index() input.rewind() s = -1 if (self.synpred140_JavaScript()): s = 9 elif (True): s = 10 input.seek(index121_3) if s >= 0: return s elif s == 3: LA121_4 = input.LA(1) index121_4 = input.index() input.rewind() s = -1 if (self.synpred140_JavaScript()): s = 9 elif (True): s = 10 input.seek(index121_4) if s >= 0: return s elif s == 4: LA121_5 = input.LA(1) index121_5 = input.index() input.rewind() s = -1 if (self.synpred140_JavaScript()): s = 9 elif (True): s = 10 input.seek(index121_5) if s >= 0: return s elif s == 5: LA121_6 = input.LA(1) index121_6 = input.index() input.rewind() s = -1 if (self.synpred140_JavaScript()): s = 9 elif (True): s = 10 input.seek(index121_6) if s >= 0: return s elif s == 6: LA121_7 = input.LA(1) index121_7 = input.index() input.rewind() s = -1 if (self.synpred140_JavaScript()): s = 9 elif (True): s = 10 input.seek(index121_7) if s >= 0: return s elif s == 7: LA121_8 = input.LA(1) index121_8 = input.index() input.rewind() s = -1 if (self.synpred140_JavaScript()): s = 9 elif (True): s = 10 input.seek(index121_8) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 121, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #124 DFA124_eot = DFA.unpack( u"\13\uffff" ) DFA124_eof = DFA.unpack( u"\13\uffff" ) DFA124_min = DFA.unpack( u"\1\5\10\0\2\uffff" ) DFA124_max = DFA.unpack( u"\1\152\10\0\2\uffff" ) DFA124_accept = DFA.unpack( u"\11\uffff\1\1\1\2" ) DFA124_special = DFA.unpack( u"\1\uffff\1\0\1\1\1\2\1\3\1\4\1\5\1\6\1\7\2\uffff" ) DFA124_transition = [ DFA.unpack(u"\1\2\2\3\27\uffff\1\7\1\6\2\uffff\1\5\26\uffff\1\10" u"\1\4\37\uffff\2\11\3\uffff\7\11\1\1\3\3"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #124 class DFA124(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA124_1 = input.LA(1) index124_1 = input.index() input.rewind() s = -1 if (self.synpred143_JavaScript()): s = 9 elif (True): s = 10 input.seek(index124_1) if s >= 0: return s elif s == 1: LA124_2 = input.LA(1) index124_2 = input.index() input.rewind() s = -1 if (self.synpred143_JavaScript()): s = 9 elif (True): s = 10 input.seek(index124_2) if s >= 0: return s elif s == 2: LA124_3 = input.LA(1) index124_3 = input.index() input.rewind() s = -1 if (self.synpred143_JavaScript()): s = 9 elif (True): s = 10 input.seek(index124_3) if s >= 0: return s elif s == 3: LA124_4 = input.LA(1) index124_4 = input.index() input.rewind() s = -1 if (self.synpred143_JavaScript()): s = 9 elif (True): s = 10 input.seek(index124_4) if s >= 0: return s elif s == 4: LA124_5 = input.LA(1) index124_5 = input.index() input.rewind() s = -1 if (self.synpred143_JavaScript()): s = 9 elif (True): s = 10 input.seek(index124_5) if s >= 0: return s elif s == 5: LA124_6 = input.LA(1) index124_6 = input.index() input.rewind() s = -1 if (self.synpred143_JavaScript()): s = 9 elif (True): s = 10 input.seek(index124_6) if s >= 0: return s elif s == 6: LA124_7 = input.LA(1) index124_7 = input.index() input.rewind() s = -1 if (self.synpred143_JavaScript()): s = 9 elif (True): s = 10 input.seek(index124_7) if s >= 0: return s elif s == 7: LA124_8 = input.LA(1) index124_8 = input.index() input.rewind() s = -1 if (self.synpred143_JavaScript()): s = 9 elif (True): s = 10 input.seek(index124_8) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 124, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #125 DFA125_eot = DFA.unpack( u"\13\uffff" ) DFA125_eof = DFA.unpack( u"\13\uffff" ) DFA125_min = DFA.unpack( u"\1\5\10\0\2\uffff" ) DFA125_max = DFA.unpack( u"\1\152\10\0\2\uffff" ) DFA125_accept = DFA.unpack( u"\11\uffff\1\1\1\2" ) DFA125_special = DFA.unpack( u"\1\uffff\1\0\1\1\1\2\1\3\1\4\1\5\1\6\1\7\2\uffff" ) DFA125_transition = [ DFA.unpack(u"\1\2\2\3\27\uffff\1\7\1\6\2\uffff\1\5\26\uffff\1\10" u"\1\4\53\uffff\1\1\3\3"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #125 class DFA125(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA125_1 = input.LA(1) index125_1 = input.index() input.rewind() s = -1 if (self.synpred146_JavaScript()): s = 9 elif (True): s = 10 input.seek(index125_1) if s >= 0: return s elif s == 1: LA125_2 = input.LA(1) index125_2 = input.index() input.rewind() s = -1 if (self.synpred146_JavaScript()): s = 9 elif (True): s = 10 input.seek(index125_2) if s >= 0: return s elif s == 2: LA125_3 = input.LA(1) index125_3 = input.index() input.rewind() s = -1 if (self.synpred146_JavaScript()): s = 9 elif (True): s = 10 input.seek(index125_3) if s >= 0: return s elif s == 3: LA125_4 = input.LA(1) index125_4 = input.index() input.rewind() s = -1 if (self.synpred146_JavaScript()): s = 9 elif (True): s = 10 input.seek(index125_4) if s >= 0: return s elif s == 4: LA125_5 = input.LA(1) index125_5 = input.index() input.rewind() s = -1 if (self.synpred146_JavaScript()): s = 9 elif (True): s = 10 input.seek(index125_5) if s >= 0: return s elif s == 5: LA125_6 = input.LA(1) index125_6 = input.index() input.rewind() s = -1 if (self.synpred146_JavaScript()): s = 9 elif (True): s = 10 input.seek(index125_6) if s >= 0: return s elif s == 6: LA125_7 = input.LA(1) index125_7 = input.index() input.rewind() s = -1 if (self.synpred146_JavaScript()): s = 9 elif (True): s = 10 input.seek(index125_7) if s >= 0: return s elif s == 7: LA125_8 = input.LA(1) index125_8 = input.index() input.rewind() s = -1 if (self.synpred146_JavaScript()): s = 9 elif (True): s = 10 input.seek(index125_8) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 125, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #127 DFA127_eot = DFA.unpack( u"\12\uffff" ) DFA127_eof = DFA.unpack( u"\12\uffff" ) DFA127_min = DFA.unpack( u"\1\5\7\uffff\1\0\1\uffff" ) DFA127_max = DFA.unpack( u"\1\152\7\uffff\1\0\1\uffff" ) DFA127_accept = DFA.unpack( u"\1\uffff\1\1\7\uffff\1\2" ) DFA127_special = DFA.unpack( u"\10\uffff\1\0\1\uffff" ) DFA127_transition = [ DFA.unpack(u"\3\1\27\uffff\2\1\2\uffff\1\1\26\uffff\1\10\1\1\53\uffff" u"\4\1"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"") ] # class definition for DFA #127 class DFA127(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA127_8 = input.LA(1) index127_8 = input.index() input.rewind() s = -1 if (self.synpred147_JavaScript()): s = 1 elif (True): s = 9 input.seek(index127_8) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 127, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #132 DFA132_eot = DFA.unpack( u"\32\uffff" ) DFA132_eof = DFA.unpack( u"\1\2\31\uffff" ) DFA132_min = DFA.unpack( u"\1\4\1\0\30\uffff" ) DFA132_max = DFA.unpack( u"\1\144\1\0\30\uffff" ) DFA132_accept = DFA.unpack( u"\2\uffff\1\2\25\uffff\1\1\1\uffff" ) DFA132_special = DFA.unpack( u"\1\uffff\1\0\30\uffff" ) DFA132_transition = [ DFA.unpack(u"\1\1\33\uffff\3\2\1\uffff\1\2\1\uffff\2\2\5\uffff\1" u"\2\4\uffff\1\2\10\uffff\1\30\1\2\1\30\42\2\3\uffff\2\2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #132 class DFA132(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA132_1 = input.LA(1) index132_1 = input.index() input.rewind() s = -1 if (self.synpred154_JavaScript()): s = 24 elif (True): s = 2 input.seek(index132_1) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 132, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #136 DFA136_eot = DFA.unpack( u"\32\uffff" ) DFA136_eof = DFA.unpack( u"\1\2\31\uffff" ) DFA136_min = DFA.unpack( u"\1\4\1\0\30\uffff" ) DFA136_max = DFA.unpack( u"\1\144\1\0\30\uffff" ) DFA136_accept = DFA.unpack( u"\2\uffff\1\2\24\uffff\1\1\2\uffff" ) DFA136_special = DFA.unpack( u"\1\uffff\1\0\30\uffff" ) DFA136_transition = [ DFA.unpack(u"\1\1\33\uffff\1\27\2\2\1\uffff\1\2\1\uffff\2\2\5\uffff" u"\1\2\4\uffff\1\2\10\uffff\1\27\1\2\1\27\42\2\3\uffff\2\2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #136 class DFA136(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA136_1 = input.LA(1) index136_1 = input.index() input.rewind() s = -1 if (self.synpred158_JavaScript()): s = 23 elif (True): s = 2 input.seek(index136_1) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 136, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #142 DFA142_eot = DFA.unpack( u"\4\uffff" ) DFA142_eof = DFA.unpack( u"\4\uffff" ) DFA142_min = DFA.unpack( u"\2\4\2\uffff" ) DFA142_max = DFA.unpack( u"\2\152\2\uffff" ) DFA142_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA142_special = DFA.unpack( u"\4\uffff" ) DFA142_transition = [ DFA.unpack(u"\1\1\3\2\27\uffff\2\2\1\uffff\1\3\1\2\26\uffff\2\2\37" u"\uffff\2\2\3\uffff\13\2"), DFA.unpack(u"\1\1\3\2\27\uffff\2\2\1\uffff\1\3\1\2\26\uffff\2\2" u"\37\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #142 class DFA142(DFA): pass # lookup tables for DFA #141 DFA141_eot = DFA.unpack( u"\4\uffff" ) DFA141_eof = DFA.unpack( u"\4\uffff" ) DFA141_min = DFA.unpack( u"\2\4\2\uffff" ) DFA141_max = DFA.unpack( u"\2\42\2\uffff" ) DFA141_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA141_special = DFA.unpack( u"\4\uffff" ) DFA141_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\1\2"), DFA.unpack(u"\1\1\34\uffff\1\3\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #141 class DFA141(DFA): pass # lookup tables for DFA #151 DFA151_eot = DFA.unpack( u"\5\uffff" ) DFA151_eof = DFA.unpack( u"\2\3\2\uffff\1\3" ) DFA151_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA151_max = DFA.unpack( u"\1\111\1\152\2\uffff\1\152" ) DFA151_accept = DFA.unpack( u"\2\uffff\1\1\1\2\1\uffff" ) DFA151_special = DFA.unpack( u"\5\uffff" ) DFA151_transition = [ DFA.unpack(u"\1\1\34\uffff\2\3\1\uffff\1\3\1\uffff\1\3\13\uffff\1" u"\3\11\uffff\1\3\14\uffff\1\2"), DFA.unpack(u"\1\4\3\3\27\uffff\10\3\1\uffff\5\3\1\uffff\12\3\2\uffff" u"\3\3\14\uffff\1\2\21\uffff\2\3\3\uffff\13\3"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\3\27\uffff\10\3\1\uffff\5\3\1\uffff\12\3\2\uffff" u"\3\3\14\uffff\1\2\21\uffff\2\3\3\uffff\13\3") ] # class definition for DFA #151 class DFA151(DFA): pass # lookup tables for DFA #156 DFA156_eot = DFA.unpack( u"\4\uffff" ) DFA156_eof = DFA.unpack( u"\1\3\3\uffff" ) DFA156_min = DFA.unpack( u"\2\4\2\uffff" ) DFA156_max = DFA.unpack( u"\2\111\2\uffff" ) DFA156_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA156_special = DFA.unpack( u"\4\uffff" ) DFA156_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\4\uffff\1\3\6\uffff\1\3\4\uffff\1" u"\3\26\uffff\1\2"), DFA.unpack(u"\1\1\34\uffff\1\3\4\uffff\1\3\6\uffff\1\3\4\uffff\1" u"\3\26\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #156 class DFA156(DFA): pass # lookup tables for DFA #159 DFA159_eot = DFA.unpack( u"\5\uffff" ) DFA159_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA159_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA159_max = DFA.unpack( u"\1\112\1\152\2\uffff\1\152" ) DFA159_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA159_special = DFA.unpack( u"\5\uffff" ) DFA159_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\13\uffff\1" u"\2\11\uffff\1\2\14\uffff\1\2\1\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\1\2\1\3\20\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\1\2\1\3\20\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #159 class DFA159(DFA): pass # lookup tables for DFA #162 DFA162_eot = DFA.unpack( u"\4\uffff" ) DFA162_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA162_min = DFA.unpack( u"\2\4\2\uffff" ) DFA162_max = DFA.unpack( u"\2\112\2\uffff" ) DFA162_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA162_special = DFA.unpack( u"\4\uffff" ) DFA162_transition = [ DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\1\2\1\3"), DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\1\2\1\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #162 class DFA162(DFA): pass # lookup tables for DFA #165 DFA165_eot = DFA.unpack( u"\5\uffff" ) DFA165_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA165_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA165_max = DFA.unpack( u"\1\113\1\152\2\uffff\1\152" ) DFA165_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA165_special = DFA.unpack( u"\5\uffff" ) DFA165_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\13\uffff\1" u"\2\11\uffff\1\2\14\uffff\2\2\1\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\2\2\1\3\17\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\2\2\1\3\17\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #165 class DFA165(DFA): pass # lookup tables for DFA #168 DFA168_eot = DFA.unpack( u"\4\uffff" ) DFA168_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA168_min = DFA.unpack( u"\2\4\2\uffff" ) DFA168_max = DFA.unpack( u"\2\113\2\uffff" ) DFA168_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA168_special = DFA.unpack( u"\4\uffff" ) DFA168_transition = [ DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\2\2\1\3"), DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\2\2\1\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #168 class DFA168(DFA): pass # lookup tables for DFA #171 DFA171_eot = DFA.unpack( u"\5\uffff" ) DFA171_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA171_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA171_max = DFA.unpack( u"\1\114\1\152\2\uffff\1\152" ) DFA171_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA171_special = DFA.unpack( u"\5\uffff" ) DFA171_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\13\uffff\1" u"\2\11\uffff\1\2\14\uffff\3\2\1\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\3\2\1\3\16\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\3\2\1\3\16\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #171 class DFA171(DFA): pass # lookup tables for DFA #174 DFA174_eot = DFA.unpack( u"\4\uffff" ) DFA174_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA174_min = DFA.unpack( u"\2\4\2\uffff" ) DFA174_max = DFA.unpack( u"\2\114\2\uffff" ) DFA174_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA174_special = DFA.unpack( u"\4\uffff" ) DFA174_transition = [ DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\3\2\1\3"), DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\3\2\1\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #174 class DFA174(DFA): pass # lookup tables for DFA #177 DFA177_eot = DFA.unpack( u"\5\uffff" ) DFA177_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA177_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA177_max = DFA.unpack( u"\1\115\1\152\2\uffff\1\152" ) DFA177_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA177_special = DFA.unpack( u"\5\uffff" ) DFA177_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\13\uffff\1" u"\2\11\uffff\1\2\14\uffff\4\2\1\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\4\2\1\3\15\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\4\2\1\3\15\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #177 class DFA177(DFA): pass # lookup tables for DFA #180 DFA180_eot = DFA.unpack( u"\4\uffff" ) DFA180_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA180_min = DFA.unpack( u"\2\4\2\uffff" ) DFA180_max = DFA.unpack( u"\2\115\2\uffff" ) DFA180_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA180_special = DFA.unpack( u"\4\uffff" ) DFA180_transition = [ DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\4\2\1\3"), DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\4\2\1\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #180 class DFA180(DFA): pass # lookup tables for DFA #183 DFA183_eot = DFA.unpack( u"\5\uffff" ) DFA183_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA183_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA183_max = DFA.unpack( u"\1\116\1\152\2\uffff\1\152" ) DFA183_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA183_special = DFA.unpack( u"\5\uffff" ) DFA183_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\13\uffff\1" u"\2\11\uffff\1\2\14\uffff\5\2\1\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\5\2\1\3\14\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\5\2\1\3\14\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #183 class DFA183(DFA): pass # lookup tables for DFA #186 DFA186_eot = DFA.unpack( u"\4\uffff" ) DFA186_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA186_min = DFA.unpack( u"\2\4\2\uffff" ) DFA186_max = DFA.unpack( u"\2\116\2\uffff" ) DFA186_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA186_special = DFA.unpack( u"\4\uffff" ) DFA186_transition = [ DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\5\2\1\3"), DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\5\2\1\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #186 class DFA186(DFA): pass # lookup tables for DFA #189 DFA189_eot = DFA.unpack( u"\5\uffff" ) DFA189_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA189_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA189_max = DFA.unpack( u"\1\122\1\152\2\uffff\1\152" ) DFA189_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA189_special = DFA.unpack( u"\5\uffff" ) DFA189_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\13\uffff\1" u"\2\11\uffff\1\2\14\uffff\6\2\4\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\6\2\4\3\10\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\uffff\12\2\2\uffff" u"\3\2\14\uffff\6\2\4\3\10\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #189 class DFA189(DFA): pass # lookup tables for DFA #192 DFA192_eot = DFA.unpack( u"\4\uffff" ) DFA192_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA192_min = DFA.unpack( u"\2\4\2\uffff" ) DFA192_max = DFA.unpack( u"\2\122\2\uffff" ) DFA192_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA192_special = DFA.unpack( u"\4\uffff" ) DFA192_transition = [ DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\6\2\4\3"), DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\6\2\4\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #192 class DFA192(DFA): pass # lookup tables for DFA #195 DFA195_eot = DFA.unpack( u"\5\uffff" ) DFA195_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA195_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA195_max = DFA.unpack( u"\1\127\1\152\2\uffff\1\152" ) DFA195_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA195_special = DFA.unpack( u"\5\uffff" ) DFA195_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\6\uffff\1" u"\3\4\uffff\1\2\11\uffff\1\2\14\uffff\12\2\5\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\3\12\2\2\uffff" u"\3\2\14\uffff\12\2\5\3\3\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\5\2\1\3\12\2\2\uffff" u"\3\2\14\uffff\12\2\5\3\3\uffff\2\2\3\uffff\13\2") ] # class definition for DFA #195 class DFA195(DFA): pass # lookup tables for DFA #198 DFA198_eot = DFA.unpack( u"\4\uffff" ) DFA198_eof = DFA.unpack( u"\1\2\3\uffff" ) DFA198_min = DFA.unpack( u"\2\4\2\uffff" ) DFA198_max = DFA.unpack( u"\2\127\2\uffff" ) DFA198_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA198_special = DFA.unpack( u"\4\uffff" ) DFA198_transition = [ DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\12\2\5\3"), DFA.unpack(u"\1\1\34\uffff\1\2\4\uffff\1\2\6\uffff\1\2\4\uffff\1" u"\2\26\uffff\12\2\5\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #198 class DFA198(DFA): pass # lookup tables for DFA #201 DFA201_eot = DFA.unpack( u"\5\uffff" ) DFA201_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA201_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA201_max = DFA.unpack( u"\1\132\1\152\2\uffff\1\152" ) DFA201_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA201_special = DFA.unpack( u"\5\uffff" ) DFA201_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\6\uffff\1" u"\2\4\uffff\1\2\11\uffff\1\2\14\uffff\17\2\3\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\20\2\2\uffff\3\2\14" u"\uffff\17\2\3\3\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\20\2\2\uffff\3\2\14" u"\uffff\17\2\3\3\2\2\3\uffff\13\2") ] # class definition for DFA #201 class DFA201(DFA): pass # lookup tables for DFA #204 DFA204_eot = DFA.unpack( u"\24\uffff" ) DFA204_eof = DFA.unpack( u"\1\2\23\uffff" ) DFA204_min = DFA.unpack( u"\1\4\1\0\22\uffff" ) DFA204_max = DFA.unpack( u"\1\134\1\0\22\uffff" ) DFA204_accept = DFA.unpack( u"\2\uffff\1\2\20\uffff\1\1" ) DFA204_special = DFA.unpack( u"\1\uffff\1\0\22\uffff" ) DFA204_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\6\uffff\1" u"\2\4\uffff\1\2\11\uffff\1\2\14\uffff\22\2\2\23"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #204 class DFA204(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA204_1 = input.LA(1) index204_1 = input.index() input.rewind() s = -1 if (self.synpred256_JavaScript()): s = 19 elif (True): s = 2 input.seek(index204_1) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 204, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #207 DFA207_eot = DFA.unpack( u"\5\uffff" ) DFA207_eof = DFA.unpack( u"\2\2\2\uffff\1\2" ) DFA207_min = DFA.unpack( u"\2\4\2\uffff\1\4" ) DFA207_max = DFA.unpack( u"\1\137\1\152\2\uffff\1\152" ) DFA207_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\uffff" ) DFA207_special = DFA.unpack( u"\5\uffff" ) DFA207_transition = [ DFA.unpack(u"\1\1\34\uffff\2\2\1\uffff\1\2\1\uffff\1\2\6\uffff\1" u"\2\4\uffff\1\2\11\uffff\1\2\14\uffff\24\2\3\3"), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\20\2\2\uffff\3\2\14" u"\uffff\24\2\3\3\13\2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\4\3\2\27\uffff\10\2\1\uffff\20\2\2\uffff\3\2\14" u"\uffff\24\2\3\3\13\2") ] # class definition for DFA #207 class DFA207(DFA): pass # lookup tables for DFA #218 DFA218_eot = DFA.unpack( u"\4\uffff" ) DFA218_eof = DFA.unpack( u"\4\uffff" ) DFA218_min = DFA.unpack( u"\2\4\2\uffff" ) DFA218_max = DFA.unpack( u"\2\74\2\uffff" ) DFA218_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA218_special = DFA.unpack( u"\4\uffff" ) DFA218_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\32\uffff\1\2"), DFA.unpack(u"\1\1\34\uffff\1\3\32\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #218 class DFA218(DFA): pass # lookup tables for DFA #217 DFA217_eot = DFA.unpack( u"\4\uffff" ) DFA217_eof = DFA.unpack( u"\4\uffff" ) DFA217_min = DFA.unpack( u"\2\4\2\uffff" ) DFA217_max = DFA.unpack( u"\2\152\2\uffff" ) DFA217_accept = DFA.unpack( u"\2\uffff\1\1\1\2" ) DFA217_special = DFA.unpack( u"\4\uffff" ) DFA217_transition = [ DFA.unpack(u"\1\1\3\2\27\uffff\2\2\1\3\1\uffff\1\2\26\uffff\2\2\1" u"\3\36\uffff\2\2\3\uffff\13\2"), DFA.unpack(u"\1\1\3\2\27\uffff\2\2\1\3\1\uffff\1\2\26\uffff\2\2" u"\1\3\36\uffff\2\2\3\uffff\13\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #217 class DFA217(DFA): pass # lookup tables for DFA #223 DFA223_eot = DFA.unpack( u"\4\uffff" ) DFA223_eof = DFA.unpack( u"\4\uffff" ) DFA223_min = DFA.unpack( u"\2\4\2\uffff" ) DFA223_max = DFA.unpack( u"\2\44\2\uffff" ) DFA223_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA223_special = DFA.unpack( u"\4\uffff" ) DFA223_transition = [ DFA.unpack(u"\1\1\34\uffff\1\3\2\uffff\1\2"), DFA.unpack(u"\1\1\34\uffff\1\3\2\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #223 class DFA223(DFA): pass FOLLOW_LT_in_program46 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_sourceElements_in_program50 = frozenset([4]) FOLLOW_LT_in_program52 = frozenset([4]) FOLLOW_EOF_in_program56 = frozenset([1]) FOLLOW_sourceElement_in_sourceElements69 = frozenset([1, 4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_sourceElements72 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_sourceElement_in_sourceElements76 = frozenset([1, 4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_functionDeclaration_in_sourceElement90 = frozenset([1]) FOLLOW_statement_in_sourceElement95 = frozenset([1]) FOLLOW_31_in_functionDeclaration108 = frozenset([4, 5]) FOLLOW_LT_in_functionDeclaration110 = frozenset([4, 5]) FOLLOW_Identifier_in_functionDeclaration114 = frozenset([4, 32]) FOLLOW_LT_in_functionDeclaration116 = frozenset([4, 32]) FOLLOW_formalParameterList_in_functionDeclaration120 = frozenset([4, 35]) FOLLOW_LT_in_functionDeclaration122 = frozenset([4, 35]) FOLLOW_functionBody_in_functionDeclaration126 = frozenset([1]) FOLLOW_31_in_functionExpression138 = frozenset([4, 5, 32]) FOLLOW_LT_in_functionExpression140 = frozenset([4, 5, 32]) FOLLOW_Identifier_in_functionExpression144 = frozenset([4, 32]) FOLLOW_LT_in_functionExpression147 = frozenset([4, 32]) FOLLOW_formalParameterList_in_functionExpression151 = frozenset([4, 35]) FOLLOW_LT_in_functionExpression153 = frozenset([4, 35]) FOLLOW_functionBody_in_functionExpression157 = frozenset([1]) FOLLOW_32_in_formalParameterList169 = frozenset([4, 5, 34]) FOLLOW_LT_in_formalParameterList172 = frozenset([4, 5]) FOLLOW_Identifier_in_formalParameterList176 = frozenset([4, 33, 34]) FOLLOW_LT_in_formalParameterList179 = frozenset([4, 33]) FOLLOW_33_in_formalParameterList183 = frozenset([4, 5]) FOLLOW_LT_in_formalParameterList185 = frozenset([4, 5]) FOLLOW_Identifier_in_formalParameterList189 = frozenset([4, 33, 34]) FOLLOW_LT_in_formalParameterList195 = frozenset([4, 34]) FOLLOW_34_in_formalParameterList199 = frozenset([1]) FOLLOW_35_in_functionBody210 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_functionBody212 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_sourceElements_in_functionBody216 = frozenset([4, 36]) FOLLOW_LT_in_functionBody218 = frozenset([4, 36]) FOLLOW_36_in_functionBody222 = frozenset([1]) FOLLOW_statementBlock_in_statement234 = frozenset([1]) FOLLOW_variableStatement_in_statement239 = frozenset([1]) FOLLOW_emptyStatement_in_statement244 = frozenset([1]) FOLLOW_expressionStatement_in_statement249 = frozenset([1]) FOLLOW_ifStatement_in_statement254 = frozenset([1]) FOLLOW_iterationStatement_in_statement259 = frozenset([1]) FOLLOW_continueStatement_in_statement264 = frozenset([1]) FOLLOW_breakStatement_in_statement269 = frozenset([1]) FOLLOW_returnStatement_in_statement274 = frozenset([1]) FOLLOW_withStatement_in_statement279 = frozenset([1]) FOLLOW_labelledStatement_in_statement284 = frozenset([1]) FOLLOW_switchStatement_in_statement289 = frozenset([1]) FOLLOW_throwStatement_in_statement294 = frozenset([1]) FOLLOW_tryStatement_in_statement299 = frozenset([1]) FOLLOW_35_in_statementBlock311 = frozenset([4, 5, 6, 7, 31, 32, 35, 36, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_statementBlock313 = frozenset([4, 5, 6, 7, 31, 32, 35, 36, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statementList_in_statementBlock317 = frozenset([4, 36]) FOLLOW_LT_in_statementBlock320 = frozenset([4, 36]) FOLLOW_36_in_statementBlock324 = frozenset([1]) FOLLOW_statement_in_statementList336 = frozenset([1, 4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_statementList339 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_statementList343 = frozenset([1, 4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_37_in_variableStatement357 = frozenset([4, 5]) FOLLOW_LT_in_variableStatement359 = frozenset([4, 5]) FOLLOW_variableDeclarationList_in_variableStatement363 = frozenset([4, 38]) FOLLOW_set_in_variableStatement365 = frozenset([1]) FOLLOW_variableDeclaration_in_variableDeclarationList384 = frozenset([1, 4, 33]) FOLLOW_LT_in_variableDeclarationList387 = frozenset([4, 33]) FOLLOW_33_in_variableDeclarationList391 = frozenset([4, 5]) FOLLOW_LT_in_variableDeclarationList393 = frozenset([4, 5]) FOLLOW_variableDeclaration_in_variableDeclarationList397 = frozenset([1, 4, 33]) FOLLOW_variableDeclarationNoIn_in_variableDeclarationListNoIn411 = frozenset([1, 4, 33]) FOLLOW_LT_in_variableDeclarationListNoIn414 = frozenset([4, 33]) FOLLOW_33_in_variableDeclarationListNoIn418 = frozenset([4, 5]) FOLLOW_LT_in_variableDeclarationListNoIn420 = frozenset([4, 5]) FOLLOW_variableDeclarationNoIn_in_variableDeclarationListNoIn424 = frozenset([1, 4, 33]) FOLLOW_Identifier_in_variableDeclaration438 = frozenset([1, 4, 39]) FOLLOW_LT_in_variableDeclaration440 = frozenset([1, 4, 39]) FOLLOW_initialiser_in_variableDeclaration444 = frozenset([1]) FOLLOW_Identifier_in_variableDeclarationNoIn457 = frozenset([1, 4, 39]) FOLLOW_LT_in_variableDeclarationNoIn459 = frozenset([1, 4, 39]) FOLLOW_initialiserNoIn_in_variableDeclarationNoIn463 = frozenset([1]) FOLLOW_39_in_initialiser476 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_initialiser478 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_initialiser482 = frozenset([1]) FOLLOW_39_in_initialiserNoIn494 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_initialiserNoIn496 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpressionNoIn_in_initialiserNoIn500 = frozenset([1]) FOLLOW_38_in_emptyStatement512 = frozenset([1]) FOLLOW_expression_in_expressionStatement524 = frozenset([4, 38]) FOLLOW_set_in_expressionStatement526 = frozenset([1]) FOLLOW_40_in_ifStatement545 = frozenset([4, 32]) FOLLOW_LT_in_ifStatement547 = frozenset([4, 32]) FOLLOW_32_in_ifStatement551 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_ifStatement553 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_ifStatement557 = frozenset([4, 34]) FOLLOW_LT_in_ifStatement559 = frozenset([4, 34]) FOLLOW_34_in_ifStatement563 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_ifStatement565 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_ifStatement569 = frozenset([1, 4, 41]) FOLLOW_LT_in_ifStatement572 = frozenset([4, 41]) FOLLOW_41_in_ifStatement576 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_ifStatement578 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_ifStatement582 = frozenset([1]) FOLLOW_doWhileStatement_in_iterationStatement596 = frozenset([1]) FOLLOW_whileStatement_in_iterationStatement601 = frozenset([1]) FOLLOW_forStatement_in_iterationStatement606 = frozenset([1]) FOLLOW_forInStatement_in_iterationStatement611 = frozenset([1]) FOLLOW_42_in_doWhileStatement623 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_doWhileStatement625 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_doWhileStatement629 = frozenset([4, 43]) FOLLOW_LT_in_doWhileStatement631 = frozenset([4, 43]) FOLLOW_43_in_doWhileStatement635 = frozenset([4, 32]) FOLLOW_LT_in_doWhileStatement637 = frozenset([4, 32]) FOLLOW_32_in_doWhileStatement641 = frozenset([5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_doWhileStatement643 = frozenset([34]) FOLLOW_34_in_doWhileStatement645 = frozenset([4, 38]) FOLLOW_set_in_doWhileStatement647 = frozenset([1]) FOLLOW_43_in_whileStatement666 = frozenset([4, 32]) FOLLOW_LT_in_whileStatement668 = frozenset([4, 32]) FOLLOW_32_in_whileStatement672 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_whileStatement674 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_whileStatement678 = frozenset([4, 34]) FOLLOW_LT_in_whileStatement680 = frozenset([4, 34]) FOLLOW_34_in_whileStatement684 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_whileStatement686 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_whileStatement690 = frozenset([1]) FOLLOW_44_in_forStatement702 = frozenset([4, 32]) FOLLOW_LT_in_forStatement704 = frozenset([4, 32]) FOLLOW_32_in_forStatement708 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_forStatement711 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_forStatementInitialiserPart_in_forStatement715 = frozenset([4, 38]) FOLLOW_LT_in_forStatement719 = frozenset([4, 38]) FOLLOW_38_in_forStatement723 = frozenset([4, 5, 6, 7, 31, 32, 35, 38, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_forStatement726 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_forStatement730 = frozenset([4, 38]) FOLLOW_LT_in_forStatement734 = frozenset([4, 38]) FOLLOW_38_in_forStatement738 = frozenset([4, 5, 6, 7, 31, 32, 34, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_forStatement741 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_forStatement745 = frozenset([4, 34]) FOLLOW_LT_in_forStatement749 = frozenset([4, 34]) FOLLOW_34_in_forStatement753 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_forStatement755 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_forStatement759 = frozenset([1]) FOLLOW_expressionNoIn_in_forStatementInitialiserPart771 = frozenset([1]) FOLLOW_37_in_forStatementInitialiserPart776 = frozenset([4, 5]) FOLLOW_LT_in_forStatementInitialiserPart778 = frozenset([4, 5]) FOLLOW_variableDeclarationListNoIn_in_forStatementInitialiserPart782 = frozenset([1]) FOLLOW_44_in_forInStatement794 = frozenset([4, 32]) FOLLOW_LT_in_forInStatement796 = frozenset([4, 32]) FOLLOW_32_in_forInStatement800 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 58, 59, 103, 104, 105, 106]) FOLLOW_LT_in_forInStatement802 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 58, 59, 103, 104, 105, 106]) FOLLOW_forInStatementInitialiserPart_in_forInStatement806 = frozenset([4, 45]) FOLLOW_LT_in_forInStatement808 = frozenset([4, 45]) FOLLOW_45_in_forInStatement812 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_forInStatement814 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_forInStatement818 = frozenset([4, 34]) FOLLOW_LT_in_forInStatement820 = frozenset([4, 34]) FOLLOW_34_in_forInStatement824 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_forInStatement826 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_forInStatement830 = frozenset([1]) FOLLOW_leftHandSideExpression_in_forInStatementInitialiserPart842 = frozenset([1]) FOLLOW_37_in_forInStatementInitialiserPart847 = frozenset([4, 5]) FOLLOW_LT_in_forInStatementInitialiserPart849 = frozenset([4, 5]) FOLLOW_variableDeclarationNoIn_in_forInStatementInitialiserPart853 = frozenset([1]) FOLLOW_46_in_continueStatement864 = frozenset([4, 5, 38]) FOLLOW_Identifier_in_continueStatement866 = frozenset([4, 38]) FOLLOW_set_in_continueStatement869 = frozenset([1]) FOLLOW_47_in_breakStatement887 = frozenset([4, 5, 38]) FOLLOW_Identifier_in_breakStatement889 = frozenset([4, 38]) FOLLOW_set_in_breakStatement892 = frozenset([1]) FOLLOW_48_in_returnStatement910 = frozenset([4, 5, 6, 7, 31, 32, 35, 38, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_returnStatement912 = frozenset([4, 38]) FOLLOW_set_in_returnStatement915 = frozenset([1]) FOLLOW_49_in_withStatement934 = frozenset([4, 32]) FOLLOW_LT_in_withStatement936 = frozenset([4, 32]) FOLLOW_32_in_withStatement940 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_withStatement942 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_withStatement946 = frozenset([4, 34]) FOLLOW_LT_in_withStatement948 = frozenset([4, 34]) FOLLOW_34_in_withStatement952 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_withStatement954 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_withStatement958 = frozenset([1]) FOLLOW_Identifier_in_labelledStatement969 = frozenset([4, 50]) FOLLOW_LT_in_labelledStatement971 = frozenset([4, 50]) FOLLOW_50_in_labelledStatement975 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_labelledStatement977 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_labelledStatement981 = frozenset([1]) FOLLOW_51_in_switchStatement993 = frozenset([4, 32]) FOLLOW_LT_in_switchStatement995 = frozenset([4, 32]) FOLLOW_32_in_switchStatement999 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_switchStatement1001 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_switchStatement1005 = frozenset([4, 34]) FOLLOW_LT_in_switchStatement1007 = frozenset([4, 34]) FOLLOW_34_in_switchStatement1011 = frozenset([4, 35]) FOLLOW_LT_in_switchStatement1013 = frozenset([4, 35]) FOLLOW_caseBlock_in_switchStatement1017 = frozenset([1]) FOLLOW_35_in_caseBlock1029 = frozenset([4, 36, 52, 53]) FOLLOW_LT_in_caseBlock1032 = frozenset([4, 52]) FOLLOW_caseClause_in_caseBlock1036 = frozenset([4, 36, 52, 53]) FOLLOW_LT_in_caseBlock1041 = frozenset([4, 53]) FOLLOW_defaultClause_in_caseBlock1045 = frozenset([4, 36, 52]) FOLLOW_LT_in_caseBlock1048 = frozenset([4, 52]) FOLLOW_caseClause_in_caseBlock1052 = frozenset([4, 36, 52]) FOLLOW_LT_in_caseBlock1058 = frozenset([4, 36]) FOLLOW_36_in_caseBlock1062 = frozenset([1]) FOLLOW_52_in_caseClause1073 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_caseClause1075 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_caseClause1079 = frozenset([4, 50]) FOLLOW_LT_in_caseClause1081 = frozenset([4, 50]) FOLLOW_50_in_caseClause1085 = frozenset([1, 4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_caseClause1087 = frozenset([1, 4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statementList_in_caseClause1091 = frozenset([1]) FOLLOW_53_in_defaultClause1104 = frozenset([4, 50]) FOLLOW_LT_in_defaultClause1106 = frozenset([4, 50]) FOLLOW_50_in_defaultClause1110 = frozenset([1, 4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_defaultClause1112 = frozenset([1, 4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statementList_in_defaultClause1116 = frozenset([1]) FOLLOW_54_in_throwStatement1129 = frozenset([5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_throwStatement1131 = frozenset([4, 38]) FOLLOW_set_in_throwStatement1133 = frozenset([1]) FOLLOW_55_in_tryStatement1151 = frozenset([4, 35]) FOLLOW_LT_in_tryStatement1153 = frozenset([4, 35]) FOLLOW_statementBlock_in_tryStatement1157 = frozenset([4, 56, 57]) FOLLOW_LT_in_tryStatement1159 = frozenset([4, 56, 57]) FOLLOW_finallyClause_in_tryStatement1164 = frozenset([1]) FOLLOW_catchClause_in_tryStatement1168 = frozenset([1, 4, 57]) FOLLOW_LT_in_tryStatement1171 = frozenset([4, 57]) FOLLOW_finallyClause_in_tryStatement1175 = frozenset([1]) FOLLOW_56_in_catchClause1196 = frozenset([4, 32]) FOLLOW_LT_in_catchClause1198 = frozenset([4, 32]) FOLLOW_32_in_catchClause1202 = frozenset([4, 5]) FOLLOW_LT_in_catchClause1204 = frozenset([4, 5]) FOLLOW_Identifier_in_catchClause1208 = frozenset([4, 34]) FOLLOW_LT_in_catchClause1210 = frozenset([4, 34]) FOLLOW_34_in_catchClause1214 = frozenset([4, 35]) FOLLOW_LT_in_catchClause1216 = frozenset([4, 35]) FOLLOW_statementBlock_in_catchClause1220 = frozenset([1]) FOLLOW_57_in_finallyClause1232 = frozenset([4, 35]) FOLLOW_LT_in_finallyClause1234 = frozenset([4, 35]) FOLLOW_statementBlock_in_finallyClause1238 = frozenset([1]) FOLLOW_assignmentExpression_in_expression1250 = frozenset([1, 4, 33]) FOLLOW_LT_in_expression1253 = frozenset([4, 33]) FOLLOW_33_in_expression1257 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_expression1259 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_expression1263 = frozenset([1, 4, 33]) FOLLOW_assignmentExpressionNoIn_in_expressionNoIn1277 = frozenset([1, 4, 33]) FOLLOW_LT_in_expressionNoIn1280 = frozenset([4, 33]) FOLLOW_33_in_expressionNoIn1284 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_expressionNoIn1286 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpressionNoIn_in_expressionNoIn1290 = frozenset([1, 4, 33]) FOLLOW_conditionalExpression_in_assignmentExpression1304 = frozenset([1]) FOLLOW_leftHandSideExpression_in_assignmentExpression1309 = frozenset([4, 39, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72]) FOLLOW_LT_in_assignmentExpression1311 = frozenset([4, 39, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72]) FOLLOW_assignmentOperator_in_assignmentExpression1315 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_assignmentExpression1317 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_assignmentExpression1321 = frozenset([1]) FOLLOW_conditionalExpressionNoIn_in_assignmentExpressionNoIn1333 = frozenset([1]) FOLLOW_leftHandSideExpression_in_assignmentExpressionNoIn1338 = frozenset([4, 39, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72]) FOLLOW_LT_in_assignmentExpressionNoIn1340 = frozenset([4, 39, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72]) FOLLOW_assignmentOperator_in_assignmentExpressionNoIn1344 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_assignmentExpressionNoIn1346 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpressionNoIn_in_assignmentExpressionNoIn1350 = frozenset([1]) FOLLOW_callExpression_in_leftHandSideExpression1362 = frozenset([1]) FOLLOW_newExpression_in_leftHandSideExpression1367 = frozenset([1]) FOLLOW_memberExpression_in_newExpression1379 = frozenset([1]) FOLLOW_58_in_newExpression1384 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 103, 104, 105, 106]) FOLLOW_LT_in_newExpression1386 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 103, 104, 105, 106]) FOLLOW_newExpression_in_newExpression1390 = frozenset([1]) FOLLOW_primaryExpression_in_memberExpression1403 = frozenset([1, 4, 59, 61]) FOLLOW_functionExpression_in_memberExpression1407 = frozenset([1, 4, 59, 61]) FOLLOW_58_in_memberExpression1411 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 103, 104, 105, 106]) FOLLOW_LT_in_memberExpression1413 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 103, 104, 105, 106]) FOLLOW_memberExpression_in_memberExpression1417 = frozenset([4, 32]) FOLLOW_LT_in_memberExpression1419 = frozenset([4, 32]) FOLLOW_arguments_in_memberExpression1423 = frozenset([1, 4, 59, 61]) FOLLOW_LT_in_memberExpression1427 = frozenset([4, 59, 61]) FOLLOW_memberExpressionSuffix_in_memberExpression1431 = frozenset([1, 4, 59, 61]) FOLLOW_indexSuffix_in_memberExpressionSuffix1445 = frozenset([1]) FOLLOW_propertyReferenceSuffix_in_memberExpressionSuffix1450 = frozenset([1]) FOLLOW_memberExpression_in_callExpression1461 = frozenset([4, 32]) FOLLOW_LT_in_callExpression1463 = frozenset([4, 32]) FOLLOW_arguments_in_callExpression1467 = frozenset([1, 4, 32, 59, 61]) FOLLOW_LT_in_callExpression1470 = frozenset([4, 32, 59, 61]) FOLLOW_callExpressionSuffix_in_callExpression1474 = frozenset([1, 4, 32, 59, 61]) FOLLOW_arguments_in_callExpressionSuffix1488 = frozenset([1]) FOLLOW_indexSuffix_in_callExpressionSuffix1493 = frozenset([1]) FOLLOW_propertyReferenceSuffix_in_callExpressionSuffix1498 = frozenset([1]) FOLLOW_32_in_arguments1509 = frozenset([4, 5, 6, 7, 31, 32, 34, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_arguments1512 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_arguments1516 = frozenset([4, 33, 34]) FOLLOW_LT_in_arguments1519 = frozenset([4, 33]) FOLLOW_33_in_arguments1523 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_arguments1525 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_arguments1529 = frozenset([4, 33, 34]) FOLLOW_LT_in_arguments1535 = frozenset([4, 34]) FOLLOW_34_in_arguments1539 = frozenset([1]) FOLLOW_59_in_indexSuffix1551 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_indexSuffix1553 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_indexSuffix1557 = frozenset([4, 60]) FOLLOW_LT_in_indexSuffix1559 = frozenset([4, 60]) FOLLOW_60_in_indexSuffix1563 = frozenset([1]) FOLLOW_61_in_propertyReferenceSuffix1576 = frozenset([4, 5]) FOLLOW_LT_in_propertyReferenceSuffix1578 = frozenset([4, 5]) FOLLOW_Identifier_in_propertyReferenceSuffix1582 = frozenset([1]) FOLLOW_set_in_assignmentOperator0 = frozenset([1]) FOLLOW_logicalORExpression_in_conditionalExpression1649 = frozenset([1, 4, 73]) FOLLOW_LT_in_conditionalExpression1652 = frozenset([4, 73]) FOLLOW_73_in_conditionalExpression1656 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_conditionalExpression1658 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_conditionalExpression1662 = frozenset([4, 50]) FOLLOW_LT_in_conditionalExpression1664 = frozenset([4, 50]) FOLLOW_50_in_conditionalExpression1668 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_conditionalExpression1670 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_conditionalExpression1674 = frozenset([1]) FOLLOW_logicalORExpressionNoIn_in_conditionalExpressionNoIn1687 = frozenset([1, 4, 73]) FOLLOW_LT_in_conditionalExpressionNoIn1690 = frozenset([4, 73]) FOLLOW_73_in_conditionalExpressionNoIn1694 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_conditionalExpressionNoIn1696 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpressionNoIn_in_conditionalExpressionNoIn1700 = frozenset([4, 50]) FOLLOW_LT_in_conditionalExpressionNoIn1702 = frozenset([4, 50]) FOLLOW_50_in_conditionalExpressionNoIn1706 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_conditionalExpressionNoIn1708 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpressionNoIn_in_conditionalExpressionNoIn1712 = frozenset([1]) FOLLOW_logicalANDExpression_in_logicalORExpression1725 = frozenset([1, 4, 74]) FOLLOW_LT_in_logicalORExpression1728 = frozenset([4, 74]) FOLLOW_74_in_logicalORExpression1732 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_logicalORExpression1734 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_logicalANDExpression_in_logicalORExpression1738 = frozenset([1, 4, 74]) FOLLOW_logicalANDExpressionNoIn_in_logicalORExpressionNoIn1752 = frozenset([1, 4, 74]) FOLLOW_LT_in_logicalORExpressionNoIn1755 = frozenset([4, 74]) FOLLOW_74_in_logicalORExpressionNoIn1759 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_logicalORExpressionNoIn1761 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_logicalANDExpressionNoIn_in_logicalORExpressionNoIn1765 = frozenset([1, 4, 74]) FOLLOW_bitwiseORExpression_in_logicalANDExpression1779 = frozenset([1, 4, 75]) FOLLOW_LT_in_logicalANDExpression1782 = frozenset([4, 75]) FOLLOW_75_in_logicalANDExpression1786 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_logicalANDExpression1788 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_bitwiseORExpression_in_logicalANDExpression1792 = frozenset([1, 4, 75]) FOLLOW_bitwiseORExpressionNoIn_in_logicalANDExpressionNoIn1806 = frozenset([1, 4, 75]) FOLLOW_LT_in_logicalANDExpressionNoIn1809 = frozenset([4, 75]) FOLLOW_75_in_logicalANDExpressionNoIn1813 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_logicalANDExpressionNoIn1815 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_bitwiseORExpressionNoIn_in_logicalANDExpressionNoIn1819 = frozenset([1, 4, 75]) FOLLOW_bitwiseXORExpression_in_bitwiseORExpression1833 = frozenset([1, 4, 76]) FOLLOW_LT_in_bitwiseORExpression1836 = frozenset([4, 76]) FOLLOW_76_in_bitwiseORExpression1840 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_bitwiseORExpression1842 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_bitwiseXORExpression_in_bitwiseORExpression1846 = frozenset([1, 4, 76]) FOLLOW_bitwiseXORExpressionNoIn_in_bitwiseORExpressionNoIn1860 = frozenset([1, 4, 76]) FOLLOW_LT_in_bitwiseORExpressionNoIn1863 = frozenset([4, 76]) FOLLOW_76_in_bitwiseORExpressionNoIn1867 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_bitwiseORExpressionNoIn1869 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_bitwiseXORExpressionNoIn_in_bitwiseORExpressionNoIn1873 = frozenset([1, 4, 76]) FOLLOW_bitwiseANDExpression_in_bitwiseXORExpression1887 = frozenset([1, 4, 77]) FOLLOW_LT_in_bitwiseXORExpression1890 = frozenset([4, 77]) FOLLOW_77_in_bitwiseXORExpression1894 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_bitwiseXORExpression1896 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_bitwiseANDExpression_in_bitwiseXORExpression1900 = frozenset([1, 4, 77]) FOLLOW_bitwiseANDExpressionNoIn_in_bitwiseXORExpressionNoIn1914 = frozenset([1, 4, 77]) FOLLOW_LT_in_bitwiseXORExpressionNoIn1917 = frozenset([4, 77]) FOLLOW_77_in_bitwiseXORExpressionNoIn1921 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_bitwiseXORExpressionNoIn1923 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_bitwiseANDExpressionNoIn_in_bitwiseXORExpressionNoIn1927 = frozenset([1, 4, 77]) FOLLOW_equalityExpression_in_bitwiseANDExpression1941 = frozenset([1, 4, 78]) FOLLOW_LT_in_bitwiseANDExpression1944 = frozenset([4, 78]) FOLLOW_78_in_bitwiseANDExpression1948 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_bitwiseANDExpression1950 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_equalityExpression_in_bitwiseANDExpression1954 = frozenset([1, 4, 78]) FOLLOW_equalityExpressionNoIn_in_bitwiseANDExpressionNoIn1968 = frozenset([1, 4, 78]) FOLLOW_LT_in_bitwiseANDExpressionNoIn1971 = frozenset([4, 78]) FOLLOW_78_in_bitwiseANDExpressionNoIn1975 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_bitwiseANDExpressionNoIn1977 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_equalityExpressionNoIn_in_bitwiseANDExpressionNoIn1981 = frozenset([1, 4, 78]) FOLLOW_relationalExpression_in_equalityExpression1995 = frozenset([1, 4, 79, 80, 81, 82]) FOLLOW_LT_in_equalityExpression1998 = frozenset([4, 79, 80, 81, 82]) FOLLOW_set_in_equalityExpression2002 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_equalityExpression2018 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_relationalExpression_in_equalityExpression2022 = frozenset([1, 4, 79, 80, 81, 82]) FOLLOW_relationalExpressionNoIn_in_equalityExpressionNoIn2035 = frozenset([1, 4, 79, 80, 81, 82]) FOLLOW_LT_in_equalityExpressionNoIn2038 = frozenset([4, 79, 80, 81, 82]) FOLLOW_set_in_equalityExpressionNoIn2042 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_equalityExpressionNoIn2058 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_relationalExpressionNoIn_in_equalityExpressionNoIn2062 = frozenset([1, 4, 79, 80, 81, 82]) FOLLOW_shiftExpression_in_relationalExpression2076 = frozenset([1, 4, 45, 83, 84, 85, 86, 87]) FOLLOW_LT_in_relationalExpression2079 = frozenset([4, 45, 83, 84, 85, 86, 87]) FOLLOW_set_in_relationalExpression2083 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_relationalExpression2107 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_shiftExpression_in_relationalExpression2111 = frozenset([1, 4, 45, 83, 84, 85, 86, 87]) FOLLOW_shiftExpression_in_relationalExpressionNoIn2124 = frozenset([1, 4, 83, 84, 85, 86, 87]) FOLLOW_LT_in_relationalExpressionNoIn2127 = frozenset([4, 83, 84, 85, 86, 87]) FOLLOW_set_in_relationalExpressionNoIn2131 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_relationalExpressionNoIn2151 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_shiftExpression_in_relationalExpressionNoIn2155 = frozenset([1, 4, 83, 84, 85, 86, 87]) FOLLOW_additiveExpression_in_shiftExpression2168 = frozenset([1, 4, 88, 89, 90]) FOLLOW_LT_in_shiftExpression2171 = frozenset([4, 88, 89, 90]) FOLLOW_set_in_shiftExpression2175 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_shiftExpression2187 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_additiveExpression_in_shiftExpression2191 = frozenset([1, 4, 88, 89, 90]) FOLLOW_multiplicativeExpression_in_additiveExpression2204 = frozenset([1, 4, 91, 92]) FOLLOW_LT_in_additiveExpression2207 = frozenset([4, 91, 92]) FOLLOW_set_in_additiveExpression2211 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_additiveExpression2219 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_multiplicativeExpression_in_additiveExpression2223 = frozenset([1, 4, 91, 92]) FOLLOW_unaryExpression_in_multiplicativeExpression2236 = frozenset([1, 4, 93, 94, 95]) FOLLOW_LT_in_multiplicativeExpression2239 = frozenset([4, 93, 94, 95]) FOLLOW_set_in_multiplicativeExpression2243 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_multiplicativeExpression2255 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_unaryExpression_in_multiplicativeExpression2259 = frozenset([1, 4, 93, 94, 95]) FOLLOW_postfixExpression_in_unaryExpression2272 = frozenset([1]) FOLLOW_set_in_unaryExpression2277 = frozenset([5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_unaryExpression_in_unaryExpression2313 = frozenset([1]) FOLLOW_leftHandSideExpression_in_postfixExpression2325 = frozenset([1, 99, 100]) FOLLOW_set_in_postfixExpression2327 = frozenset([1]) FOLLOW_103_in_primaryExpression2345 = frozenset([1]) FOLLOW_Identifier_in_primaryExpression2350 = frozenset([1]) FOLLOW_literal_in_primaryExpression2355 = frozenset([1]) FOLLOW_arrayLiteral_in_primaryExpression2360 = frozenset([1]) FOLLOW_objectLiteral_in_primaryExpression2365 = frozenset([1]) FOLLOW_32_in_primaryExpression2370 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_primaryExpression2372 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_expression_in_primaryExpression2376 = frozenset([4, 34]) FOLLOW_LT_in_primaryExpression2378 = frozenset([4, 34]) FOLLOW_34_in_primaryExpression2382 = frozenset([1]) FOLLOW_59_in_arrayLiteral2395 = frozenset([4, 5, 6, 7, 31, 32, 33, 35, 58, 59, 60, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_arrayLiteral2397 = frozenset([4, 5, 6, 7, 31, 32, 33, 35, 58, 59, 60, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_arrayLiteral2401 = frozenset([4, 33, 60]) FOLLOW_LT_in_arrayLiteral2405 = frozenset([4, 33]) FOLLOW_33_in_arrayLiteral2409 = frozenset([4, 5, 6, 7, 31, 32, 33, 35, 58, 59, 60, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_arrayLiteral2412 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_arrayLiteral2416 = frozenset([4, 33, 60]) FOLLOW_LT_in_arrayLiteral2422 = frozenset([4, 60]) FOLLOW_60_in_arrayLiteral2426 = frozenset([1]) FOLLOW_35_in_objectLiteral2445 = frozenset([4, 5, 6, 7]) FOLLOW_LT_in_objectLiteral2447 = frozenset([4, 5, 6, 7]) FOLLOW_propertyNameAndValue_in_objectLiteral2451 = frozenset([4, 33, 36]) FOLLOW_LT_in_objectLiteral2454 = frozenset([4, 33]) FOLLOW_33_in_objectLiteral2458 = frozenset([4, 5, 6, 7]) FOLLOW_LT_in_objectLiteral2460 = frozenset([4, 5, 6, 7]) FOLLOW_propertyNameAndValue_in_objectLiteral2464 = frozenset([4, 33, 36]) FOLLOW_LT_in_objectLiteral2468 = frozenset([4, 36]) FOLLOW_36_in_objectLiteral2472 = frozenset([1]) FOLLOW_propertyName_in_propertyNameAndValue2484 = frozenset([4, 50]) FOLLOW_LT_in_propertyNameAndValue2486 = frozenset([4, 50]) FOLLOW_50_in_propertyNameAndValue2490 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_propertyNameAndValue2492 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_assignmentExpression_in_propertyNameAndValue2496 = frozenset([1]) FOLLOW_set_in_propertyName0 = frozenset([1]) FOLLOW_set_in_literal0 = frozenset([1]) FOLLOW_functionDeclaration_in_synpred5_JavaScript90 = frozenset([1]) FOLLOW_LT_in_synpred9_JavaScript140 = frozenset([1]) FOLLOW_statementBlock_in_synpred21_JavaScript234 = frozenset([1]) FOLLOW_expressionStatement_in_synpred24_JavaScript249 = frozenset([1]) FOLLOW_labelledStatement_in_synpred31_JavaScript284 = frozenset([1]) FOLLOW_LT_in_synpred34_JavaScript313 = frozenset([1]) FOLLOW_LT_in_synpred47_JavaScript440 = frozenset([1]) FOLLOW_LT_in_synpred49_JavaScript459 = frozenset([1]) FOLLOW_LT_in_synpred60_JavaScript572 = frozenset([4, 41]) FOLLOW_41_in_synpred60_JavaScript576 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_synpred60_JavaScript578 = frozenset([4, 5, 6, 7, 31, 32, 35, 37, 38, 40, 42, 43, 44, 46, 47, 48, 49, 51, 54, 55, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_statement_in_synpred60_JavaScript582 = frozenset([1]) FOLLOW_forStatement_in_synpred63_JavaScript606 = frozenset([1]) FOLLOW_LT_in_synpred118_JavaScript1087 = frozenset([1]) FOLLOW_LT_in_synpred121_JavaScript1112 = frozenset([1]) FOLLOW_conditionalExpression_in_synpred140_JavaScript1304 = frozenset([1]) FOLLOW_conditionalExpressionNoIn_in_synpred143_JavaScript1333 = frozenset([1]) FOLLOW_callExpression_in_synpred146_JavaScript1362 = frozenset([1]) FOLLOW_memberExpression_in_synpred147_JavaScript1379 = frozenset([1]) FOLLOW_LT_in_synpred154_JavaScript1427 = frozenset([4, 59, 61]) FOLLOW_memberExpressionSuffix_in_synpred154_JavaScript1431 = frozenset([1]) FOLLOW_LT_in_synpred158_JavaScript1470 = frozenset([4, 32, 59, 61]) FOLLOW_callExpressionSuffix_in_synpred158_JavaScript1474 = frozenset([1]) FOLLOW_LT_in_synpred256_JavaScript2207 = frozenset([4, 91, 92]) FOLLOW_set_in_synpred256_JavaScript2211 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_LT_in_synpred256_JavaScript2219 = frozenset([4, 5, 6, 7, 31, 32, 35, 58, 59, 91, 92, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106]) FOLLOW_multiplicativeExpression_in_synpred256_JavaScript2223 = frozenset([1]) FOLLOW_LT_in_synpred280_JavaScript2397 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("JavaScriptLexer", JavaScriptParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "isislovecruft/torflow", "path": "NetworkScanners/libs/jsparser/JavaScriptParser.py", "copies": "2", "size": "544540", "license": "bsd-3-clause", "hash": 4226806052322537000, "line_mean": 33.4340457822, "line_max": 316, "alpha_frac": 0.5030925185, "autogenerated": false, "ratio": 3.87865578301067, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.007851430788748946, "num_lines": 15814 }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 kv.g 2015-05-23 22:28:38 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types INSTRUCTION=18 SLASHEQUAL=42 BACKQUOTE=74 STAR=34 CIRCUMFLEXEQUAL=46 GREATEREQUAL=58 COMPLEX=79 WIDGET=9 NOT=54 EOF=-1 CANVAS=30 NOTEQUAL=61 T__93=93 T__94=94 MINUSEQUAL=40 VBAR=62 RPAREN=38 T__91=91 NAME=31 T__92=92 GREATER=56 T__90=90 DOUBLESTAREQUAL=49 LESS=55 TEMPLATERULE=13 COMMENT=7 T__99=99 T__98=98 T__97=97 T__96=96 T__95=95 RBRACK=71 LCURLY=72 INT=76 RIGHTSHIFT=51 T__87=87 T__86=86 T__89=89 T__88=88 DOUBLESLASHEQUAL=50 WS=32 PROPERTY=10 NONE=75 VBAREQUAL=45 OR=52 RESETRULE=19 CLASSRULE=12 LONGINT=77 MULTICLASSRULE=15 PERCENTEQUAL=43 LESSEQUAL=59 DOUBLESLASH=68 LBRACK=70 DOUBLESTAR=35 ESC=84 DIGITS=82 Exponent=83 FLOAT=78 DEDENT=5 WNAME=24 RIGHTSHIFTEQUAL=48 AND=53 DIRECTIVE=8 BLANKLINE=6 INDENT=4 LPAREN=37 PLUSEQUAL=39 COMMENTTEXT=23 AT=26 MULTITEMPLATERULE=14 SLASH=66 DIRECTIVETEXT=22 T__107=107 COMMA=27 AMPER=64 PYTHON=17 T__103=103 T__104=104 EQUAL=57 T__105=105 T__106=106 TILDE=69 LEFTSHIFTEQUAL=47 PLUS=28 LEFTSHIFT=65 DOT=81 PERCENT=67 CLASSLIST=16 HASH=85 T__102=102 T__101=101 T__100=100 MINUS=29 SEMI=33 COLON=25 CANVASRULE=11 AMPEREQUAL=44 NEWLINE=21 RCURLY=73 ASSIGN=36 STAREQUAL=41 CIRCUMFLEX=63 STRING=80 ALT_NOTEQUAL=60 AUTOCLASS=20 class kvLexer(Lexer): grammarFileName = "kv.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(kvLexer, self).__init__(input, state) self.dfa5 = self.DFA5( self, 5, eot = self.DFA5_eot, eof = self.DFA5_eof, min = self.DFA5_min, max = self.DFA5_max, accept = self.DFA5_accept, special = self.DFA5_special, transition = self.DFA5_transition ) self.dfa11 = self.DFA11( self, 11, eot = self.DFA11_eot, eof = self.DFA11_eof, min = self.DFA11_min, max = self.DFA11_max, accept = self.DFA11_accept, special = self.DFA11_special, transition = self.DFA11_transition ) self.dfa21 = self.DFA21( self, 21, eot = self.DFA21_eot, eof = self.DFA21_eof, min = self.DFA21_min, max = self.DFA21_max, accept = self.DFA21_accept, special = self.DFA21_special, transition = self.DFA21_transition ) self.dfa25 = self.DFA25( self, 25, eot = self.DFA25_eot, eof = self.DFA25_eof, min = self.DFA25_min, max = self.DFA25_max, accept = self.DFA25_accept, special = self.DFA25_special, transition = self.DFA25_transition ) self.startPos = -1 self.nested = 0 def nextToken(): self.startPos = self.getCharPositionInLine() return Lexer.nextToken(self) self.nextToken = nextToken # $ANTLR start "T__86" def mT__86(self, ): try: _type = T__86 _channel = DEFAULT_CHANNEL # kv.g:16:7: ( 'print' ) # kv.g:16:9: 'print' pass self.match("print") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__86" # $ANTLR start "T__87" def mT__87(self, ): try: _type = T__87 _channel = DEFAULT_CHANNEL # kv.g:17:7: ( 'del' ) # kv.g:17:9: 'del' pass self.match("del") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__87" # $ANTLR start "T__88" def mT__88(self, ): try: _type = T__88 _channel = DEFAULT_CHANNEL # kv.g:18:7: ( 'pass' ) # kv.g:18:9: 'pass' pass self.match("pass") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__88" # $ANTLR start "T__89" def mT__89(self, ): try: _type = T__89 _channel = DEFAULT_CHANNEL # kv.g:19:7: ( 'break' ) # kv.g:19:9: 'break' pass self.match("break") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__89" # $ANTLR start "T__90" def mT__90(self, ): try: _type = T__90 _channel = DEFAULT_CHANNEL # kv.g:20:7: ( 'continue' ) # kv.g:20:9: 'continue' pass self.match("continue") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__90" # $ANTLR start "T__91" def mT__91(self, ): try: _type = T__91 _channel = DEFAULT_CHANNEL # kv.g:21:7: ( 'raise' ) # kv.g:21:9: 'raise' pass self.match("raise") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__91" # $ANTLR start "T__92" def mT__92(self, ): try: _type = T__92 _channel = DEFAULT_CHANNEL # kv.g:22:7: ( 'exec' ) # kv.g:22:9: 'exec' pass self.match("exec") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__92" # $ANTLR start "T__93" def mT__93(self, ): try: _type = T__93 _channel = DEFAULT_CHANNEL # kv.g:23:7: ( 'in' ) # kv.g:23:9: 'in' pass self.match("in") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__93" # $ANTLR start "T__94" def mT__94(self, ): try: _type = T__94 _channel = DEFAULT_CHANNEL # kv.g:24:7: ( 'assert' ) # kv.g:24:9: 'assert' pass self.match("assert") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__94" # $ANTLR start "T__95" def mT__95(self, ): try: _type = T__95 _channel = DEFAULT_CHANNEL # kv.g:25:7: ( 'if' ) # kv.g:25:9: 'if' pass self.match("if") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__95" # $ANTLR start "T__96" def mT__96(self, ): try: _type = T__96 _channel = DEFAULT_CHANNEL # kv.g:26:7: ( 'else' ) # kv.g:26:9: 'else' pass self.match("else") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__96" # $ANTLR start "T__97" def mT__97(self, ): try: _type = T__97 _channel = DEFAULT_CHANNEL # kv.g:27:7: ( 'elif' ) # kv.g:27:9: 'elif' pass self.match("elif") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__97" # $ANTLR start "T__98" def mT__98(self, ): try: _type = T__98 _channel = DEFAULT_CHANNEL # kv.g:28:7: ( 'while' ) # kv.g:28:9: 'while' pass self.match("while") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__98" # $ANTLR start "T__99" def mT__99(self, ): try: _type = T__99 _channel = DEFAULT_CHANNEL # kv.g:29:7: ( 'for' ) # kv.g:29:9: 'for' pass self.match("for") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__99" # $ANTLR start "T__100" def mT__100(self, ): try: _type = T__100 _channel = DEFAULT_CHANNEL # kv.g:30:8: ( 'try' ) # kv.g:30:10: 'try' pass self.match("try") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__100" # $ANTLR start "T__101" def mT__101(self, ): try: _type = T__101 _channel = DEFAULT_CHANNEL # kv.g:31:8: ( 'finally' ) # kv.g:31:10: 'finally' pass self.match("finally") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__101" # $ANTLR start "T__102" def mT__102(self, ): try: _type = T__102 _channel = DEFAULT_CHANNEL # kv.g:32:8: ( 'with' ) # kv.g:32:10: 'with' pass self.match("with") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__102" # $ANTLR start "T__103" def mT__103(self, ): try: _type = T__103 _channel = DEFAULT_CHANNEL # kv.g:33:8: ( 'as' ) # kv.g:33:10: 'as' pass self.match("as") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__103" # $ANTLR start "T__104" def mT__104(self, ): try: _type = T__104 _channel = DEFAULT_CHANNEL # kv.g:34:8: ( 'except' ) # kv.g:34:10: 'except' pass self.match("except") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__104" # $ANTLR start "T__105" def mT__105(self, ): try: _type = T__105 _channel = DEFAULT_CHANNEL # kv.g:35:8: ( 'is' ) # kv.g:35:10: 'is' pass self.match("is") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__105" # $ANTLR start "T__106" def mT__106(self, ): try: _type = T__106 _channel = DEFAULT_CHANNEL # kv.g:36:8: ( 'lambda' ) # kv.g:36:10: 'lambda' pass self.match("lambda") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__106" # $ANTLR start "T__107" def mT__107(self, ): try: _type = T__107 _channel = DEFAULT_CHANNEL # kv.g:37:8: ( 'yield' ) # kv.g:37:10: 'yield' pass self.match("yield") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__107" # $ANTLR start "LPAREN" def mLPAREN(self, ): try: _type = LPAREN _channel = DEFAULT_CHANNEL # kv.g:462:8: ( '(' ) # kv.g:462:11: '(' pass self.match(40) #action start self.nested += 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LPAREN" # $ANTLR start "RPAREN" def mRPAREN(self, ): try: _type = RPAREN _channel = DEFAULT_CHANNEL # kv.g:463:8: ( ')' ) # kv.g:463:11: ')' pass self.match(41) #action start self.nested -= 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RPAREN" # $ANTLR start "LBRACK" def mLBRACK(self, ): try: _type = LBRACK _channel = DEFAULT_CHANNEL # kv.g:464:8: ( '[' ) # kv.g:464:11: '[' pass self.match(91) #action start self.nested += 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LBRACK" # $ANTLR start "RBRACK" def mRBRACK(self, ): try: _type = RBRACK _channel = DEFAULT_CHANNEL # kv.g:465:8: ( ']' ) # kv.g:465:11: ']' pass self.match(93) #action start self.nested -= 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RBRACK" # $ANTLR start "COLON" def mCOLON(self, ): try: _type = COLON _channel = DEFAULT_CHANNEL # kv.g:466:7: ( ':' ) # kv.g:466:11: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COLON" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # kv.g:467:7: ( ',' ) # kv.g:467:11: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "SEMI" def mSEMI(self, ): try: _type = SEMI _channel = DEFAULT_CHANNEL # kv.g:468:6: ( ';' ) # kv.g:468:10: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SEMI" # $ANTLR start "PLUS" def mPLUS(self, ): try: _type = PLUS _channel = DEFAULT_CHANNEL # kv.g:469:6: ( '+' ) # kv.g:469:10: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUS" # $ANTLR start "MINUS" def mMINUS(self, ): try: _type = MINUS _channel = DEFAULT_CHANNEL # kv.g:470:7: ( '-' ) # kv.g:470:11: '-' pass self.match(45) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MINUS" # $ANTLR start "STAR" def mSTAR(self, ): try: _type = STAR _channel = DEFAULT_CHANNEL # kv.g:471:6: ( '*' ) # kv.g:471:10: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STAR" # $ANTLR start "SLASH" def mSLASH(self, ): try: _type = SLASH _channel = DEFAULT_CHANNEL # kv.g:472:7: ( '/' ) # kv.g:472:11: '/' pass self.match(47) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SLASH" # $ANTLR start "VBAR" def mVBAR(self, ): try: _type = VBAR _channel = DEFAULT_CHANNEL # kv.g:473:6: ( '|' ) # kv.g:473:10: '|' pass self.match(124) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "VBAR" # $ANTLR start "AMPER" def mAMPER(self, ): try: _type = AMPER _channel = DEFAULT_CHANNEL # kv.g:474:7: ( '&' ) # kv.g:474:11: '&' pass self.match(38) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AMPER" # $ANTLR start "LESS" def mLESS(self, ): try: _type = LESS _channel = DEFAULT_CHANNEL # kv.g:475:6: ( '<' ) # kv.g:475:10: '<' pass self.match(60) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LESS" # $ANTLR start "GREATER" def mGREATER(self, ): try: _type = GREATER _channel = DEFAULT_CHANNEL # kv.g:476:9: ( '>' ) # kv.g:476:12: '>' pass self.match(62) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "GREATER" # $ANTLR start "ASSIGN" def mASSIGN(self, ): try: _type = ASSIGN _channel = DEFAULT_CHANNEL # kv.g:477:8: ( '=' ) # kv.g:477:11: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ASSIGN" # $ANTLR start "PERCENT" def mPERCENT(self, ): try: _type = PERCENT _channel = DEFAULT_CHANNEL # kv.g:478:9: ( '%' ) # kv.g:478:12: '%' pass self.match(37) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PERCENT" # $ANTLR start "BACKQUOTE" def mBACKQUOTE(self, ): try: _type = BACKQUOTE _channel = DEFAULT_CHANNEL # kv.g:479:11: ( '`' ) # kv.g:479:14: '`' pass self.match(96) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BACKQUOTE" # $ANTLR start "LCURLY" def mLCURLY(self, ): try: _type = LCURLY _channel = DEFAULT_CHANNEL # kv.g:480:8: ( '{' ) # kv.g:480:11: '{' pass self.match(123) #action start self.nested += 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LCURLY" # $ANTLR start "RCURLY" def mRCURLY(self, ): try: _type = RCURLY _channel = DEFAULT_CHANNEL # kv.g:481:8: ( '}' ) # kv.g:481:11: '}' pass self.match(125) #action start self.nested -= 1 #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RCURLY" # $ANTLR start "CIRCUMFLEX" def mCIRCUMFLEX(self, ): try: _type = CIRCUMFLEX _channel = DEFAULT_CHANNEL # kv.g:482:12: ( '^' ) # kv.g:482:14: '^' pass self.match(94) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CIRCUMFLEX" # $ANTLR start "TILDE" def mTILDE(self, ): try: _type = TILDE _channel = DEFAULT_CHANNEL # kv.g:483:7: ( '~' ) # kv.g:483:11: '~' pass self.match(126) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "TILDE" # $ANTLR start "EQUAL" def mEQUAL(self, ): try: _type = EQUAL _channel = DEFAULT_CHANNEL # kv.g:484:7: ( '==' ) # kv.g:484:11: '==' pass self.match("==") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EQUAL" # $ANTLR start "NOTEQUAL" def mNOTEQUAL(self, ): try: _type = NOTEQUAL _channel = DEFAULT_CHANNEL # kv.g:485:10: ( '!=' ) # kv.g:485:13: '!=' pass self.match("!=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NOTEQUAL" # $ANTLR start "ALT_NOTEQUAL" def mALT_NOTEQUAL(self, ): try: _type = ALT_NOTEQUAL _channel = DEFAULT_CHANNEL # kv.g:486:14: ( '<>' ) # kv.g:486:16: '<>' pass self.match("<>") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ALT_NOTEQUAL" # $ANTLR start "LESSEQUAL" def mLESSEQUAL(self, ): try: _type = LESSEQUAL _channel = DEFAULT_CHANNEL # kv.g:487:11: ( '<=' ) # kv.g:487:14: '<=' pass self.match("<=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LESSEQUAL" # $ANTLR start "LEFTSHIFT" def mLEFTSHIFT(self, ): try: _type = LEFTSHIFT _channel = DEFAULT_CHANNEL # kv.g:488:11: ( '<<' ) # kv.g:488:14: '<<' pass self.match("<<") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LEFTSHIFT" # $ANTLR start "GREATEREQUAL" def mGREATEREQUAL(self, ): try: _type = GREATEREQUAL _channel = DEFAULT_CHANNEL # kv.g:489:14: ( '>=' ) # kv.g:489:16: '>=' pass self.match(">=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "GREATEREQUAL" # $ANTLR start "RIGHTSHIFT" def mRIGHTSHIFT(self, ): try: _type = RIGHTSHIFT _channel = DEFAULT_CHANNEL # kv.g:490:12: ( '>>' ) # kv.g:490:14: '>>' pass self.match(">>") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RIGHTSHIFT" # $ANTLR start "PLUSEQUAL" def mPLUSEQUAL(self, ): try: _type = PLUSEQUAL _channel = DEFAULT_CHANNEL # kv.g:491:11: ( '+=' ) # kv.g:491:14: '+=' pass self.match("+=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUSEQUAL" # $ANTLR start "MINUSEQUAL" def mMINUSEQUAL(self, ): try: _type = MINUSEQUAL _channel = DEFAULT_CHANNEL # kv.g:492:12: ( '-=' ) # kv.g:492:14: '-=' pass self.match("-=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MINUSEQUAL" # $ANTLR start "DOUBLESTAR" def mDOUBLESTAR(self, ): try: _type = DOUBLESTAR _channel = DEFAULT_CHANNEL # kv.g:493:12: ( '**' ) # kv.g:493:14: '**' pass self.match("**") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOUBLESTAR" # $ANTLR start "STAREQUAL" def mSTAREQUAL(self, ): try: _type = STAREQUAL _channel = DEFAULT_CHANNEL # kv.g:494:11: ( '*=' ) # kv.g:494:14: '*=' pass self.match("*=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STAREQUAL" # $ANTLR start "DOUBLESLASH" def mDOUBLESLASH(self, ): try: _type = DOUBLESLASH _channel = DEFAULT_CHANNEL # kv.g:495:13: ( '//' ) # kv.g:495:15: '//' pass self.match("//") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOUBLESLASH" # $ANTLR start "SLASHEQUAL" def mSLASHEQUAL(self, ): try: _type = SLASHEQUAL _channel = DEFAULT_CHANNEL # kv.g:496:12: ( '/=' ) # kv.g:496:14: '/=' pass self.match("/=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SLASHEQUAL" # $ANTLR start "VBAREQUAL" def mVBAREQUAL(self, ): try: _type = VBAREQUAL _channel = DEFAULT_CHANNEL # kv.g:497:11: ( '|=' ) # kv.g:497:14: '|=' pass self.match("|=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "VBAREQUAL" # $ANTLR start "PERCENTEQUAL" def mPERCENTEQUAL(self, ): try: _type = PERCENTEQUAL _channel = DEFAULT_CHANNEL # kv.g:498:14: ( '%=' ) # kv.g:498:16: '%=' pass self.match("%=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PERCENTEQUAL" # $ANTLR start "AMPEREQUAL" def mAMPEREQUAL(self, ): try: _type = AMPEREQUAL _channel = DEFAULT_CHANNEL # kv.g:499:12: ( '&=' ) # kv.g:499:14: '&=' pass self.match("&=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AMPEREQUAL" # $ANTLR start "CIRCUMFLEXEQUAL" def mCIRCUMFLEXEQUAL(self, ): try: _type = CIRCUMFLEXEQUAL _channel = DEFAULT_CHANNEL # kv.g:500:17: ( '^=' ) # kv.g:500:19: '^=' pass self.match("^=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CIRCUMFLEXEQUAL" # $ANTLR start "LEFTSHIFTEQUAL" def mLEFTSHIFTEQUAL(self, ): try: _type = LEFTSHIFTEQUAL _channel = DEFAULT_CHANNEL # kv.g:501:16: ( '<<=' ) # kv.g:501:18: '<<=' pass self.match("<<=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LEFTSHIFTEQUAL" # $ANTLR start "RIGHTSHIFTEQUAL" def mRIGHTSHIFTEQUAL(self, ): try: _type = RIGHTSHIFTEQUAL _channel = DEFAULT_CHANNEL # kv.g:502:17: ( '>>=' ) # kv.g:502:19: '>>=' pass self.match(">>=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RIGHTSHIFTEQUAL" # $ANTLR start "DOUBLESTAREQUAL" def mDOUBLESTAREQUAL(self, ): try: _type = DOUBLESTAREQUAL _channel = DEFAULT_CHANNEL # kv.g:503:17: ( '**=' ) # kv.g:503:19: '**=' pass self.match("**=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOUBLESTAREQUAL" # $ANTLR start "DOUBLESLASHEQUAL" def mDOUBLESLASHEQUAL(self, ): try: _type = DOUBLESLASHEQUAL _channel = DEFAULT_CHANNEL # kv.g:504:18: ( '//=' ) # kv.g:504:20: '//=' pass self.match("//=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOUBLESLASHEQUAL" # $ANTLR start "DOT" def mDOT(self, ): try: _type = DOT _channel = DEFAULT_CHANNEL # kv.g:505:5: ( '.' ) # kv.g:505:9: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOT" # $ANTLR start "AT" def mAT(self, ): try: _type = AT _channel = DEFAULT_CHANNEL # kv.g:506:4: ( '@' ) # kv.g:506:8: '@' pass self.match(64) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT" # $ANTLR start "AND" def mAND(self, ): try: _type = AND _channel = DEFAULT_CHANNEL # kv.g:507:5: ( 'and' ) # kv.g:507:9: 'and' pass self.match("and") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AND" # $ANTLR start "OR" def mOR(self, ): try: _type = OR _channel = DEFAULT_CHANNEL # kv.g:508:4: ( 'or' ) # kv.g:508:8: 'or' pass self.match("or") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OR" # $ANTLR start "NOT" def mNOT(self, ): try: _type = NOT _channel = DEFAULT_CHANNEL # kv.g:509:5: ( 'not' ) # kv.g:509:9: 'not' pass self.match("not") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NOT" # $ANTLR start "FLOAT" def mFLOAT(self, ): try: _type = FLOAT _channel = DEFAULT_CHANNEL # kv.g:512:2: ( '.' DIGITS ( Exponent )? | DIGITS '.' Exponent | DIGITS ( '.' ( DIGITS ( Exponent )? )? | Exponent ) ) alt5 = 3 alt5 = self.dfa5.predict(self.input) if alt5 == 1: # kv.g:512:4: '.' DIGITS ( Exponent )? pass self.match(46) self.mDIGITS() # kv.g:512:15: ( Exponent )? alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == 69 or LA1_0 == 101) : alt1 = 1 if alt1 == 1: # kv.g:512:16: Exponent pass self.mExponent() elif alt5 == 2: # kv.g:513:4: DIGITS '.' Exponent pass self.mDIGITS() self.match(46) self.mExponent() elif alt5 == 3: # kv.g:514:4: DIGITS ( '.' ( DIGITS ( Exponent )? )? | Exponent ) pass self.mDIGITS() # kv.g:514:11: ( '.' ( DIGITS ( Exponent )? )? | Exponent ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 46) : alt4 = 1 elif (LA4_0 == 69 or LA4_0 == 101) : alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # kv.g:514:12: '.' ( DIGITS ( Exponent )? )? pass self.match(46) # kv.g:514:16: ( DIGITS ( Exponent )? )? alt3 = 2 LA3_0 = self.input.LA(1) if ((48 <= LA3_0 <= 57)) : alt3 = 1 if alt3 == 1: # kv.g:514:17: DIGITS ( Exponent )? pass self.mDIGITS() # kv.g:514:24: ( Exponent )? alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == 69 or LA2_0 == 101) : alt2 = 1 if alt2 == 1: # kv.g:514:25: Exponent pass self.mExponent() elif alt4 == 2: # kv.g:514:40: Exponent pass self.mExponent() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FLOAT" # $ANTLR start "LONGINT" def mLONGINT(self, ): try: _type = LONGINT _channel = DEFAULT_CHANNEL # kv.g:517:2: ( INT ( 'l' | 'L' ) ) # kv.g:517:4: INT ( 'l' | 'L' ) pass self.mINT() if self.input.LA(1) == 76 or self.input.LA(1) == 108: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LONGINT" # $ANTLR start "Exponent" def mExponent(self, ): try: # kv.g:521:2: ( ( 'e' | 'E' ) ( '+' | '-' )? DIGITS ) # kv.g:521:4: ( 'e' | 'E' ) ( '+' | '-' )? DIGITS pass if self.input.LA(1) == 69 or self.input.LA(1) == 101: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # kv.g:521:16: ( '+' | '-' )? alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == 43 or LA6_0 == 45) : alt6 = 1 if alt6 == 1: # kv.g: pass if self.input.LA(1) == 43 or self.input.LA(1) == 45: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.mDIGITS() finally: pass # $ANTLR end "Exponent" # $ANTLR start "INT" def mINT(self, ): try: _type = INT _channel = DEFAULT_CHANNEL # kv.g:523:5: ( '0' ( 'x' | 'X' ) ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' )+ | '0' ( DIGITS )* | '1' .. '9' ( DIGITS )* ) alt10 = 3 LA10_0 = self.input.LA(1) if (LA10_0 == 48) : LA10_1 = self.input.LA(2) if (LA10_1 == 88 or LA10_1 == 120) : alt10 = 1 else: alt10 = 2 elif ((49 <= LA10_0 <= 57)) : alt10 = 3 else: nvae = NoViableAltException("", 10, 0, self.input) raise nvae if alt10 == 1: # kv.g:523:7: '0' ( 'x' | 'X' ) ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' )+ pass self.match(48) if self.input.LA(1) == 88 or self.input.LA(1) == 120: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # kv.g:523:23: ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' )+ cnt7 = 0 while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if ((48 <= LA7_0 <= 57) or (65 <= LA7_0 <= 70) or (97 <= LA7_0 <= 102)) : alt7 = 1 if alt7 == 1: # kv.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt7 >= 1: break #loop7 eee = EarlyExitException(7, self.input) raise eee cnt7 += 1 elif alt10 == 2: # kv.g:524:4: '0' ( DIGITS )* pass self.match(48) # kv.g:524:8: ( DIGITS )* while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if ((48 <= LA8_0 <= 57)) : alt8 = 1 if alt8 == 1: # kv.g:524:8: DIGITS pass self.mDIGITS() else: break #loop8 elif alt10 == 3: # kv.g:525:4: '1' .. '9' ( DIGITS )* pass self.matchRange(49, 57) # kv.g:525:15: ( DIGITS )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if ((48 <= LA9_0 <= 57)) : alt9 = 1 if alt9 == 1: # kv.g:525:15: DIGITS pass self.mDIGITS() else: break #loop9 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INT" # $ANTLR start "COMPLEX" def mCOMPLEX(self, ): try: _type = COMPLEX _channel = DEFAULT_CHANNEL # kv.g:528:2: ( INT ( 'j' | 'J' ) | FLOAT ( 'j' | 'J' ) ) alt11 = 2 alt11 = self.dfa11.predict(self.input) if alt11 == 1: # kv.g:528:4: INT ( 'j' | 'J' ) pass self.mINT() if self.input.LA(1) == 74 or self.input.LA(1) == 106: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt11 == 2: # kv.g:529:4: FLOAT ( 'j' | 'J' ) pass self.mFLOAT() if self.input.LA(1) == 74 or self.input.LA(1) == 106: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMPLEX" # $ANTLR start "DIGITS" def mDIGITS(self, ): try: # kv.g:533:2: ( ( '0' .. '9' )+ ) # kv.g:533:4: ( '0' .. '9' )+ pass # kv.g:533:4: ( '0' .. '9' )+ cnt12 = 0 while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if ((48 <= LA12_0 <= 57)) : alt12 = 1 if alt12 == 1: # kv.g:533:6: '0' .. '9' pass self.matchRange(48, 57) else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 finally: pass # $ANTLR end "DIGITS" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # kv.g:536:2: ( ( 'r' | 'u' | 'ur' )? ( '\"' ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* '\"' | '\\'' ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* '\\'' ) ) # kv.g:536:4: ( 'r' | 'u' | 'ur' )? ( '\"' ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* '\"' | '\\'' ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* '\\'' ) pass # kv.g:536:4: ( 'r' | 'u' | 'ur' )? alt13 = 4 LA13_0 = self.input.LA(1) if (LA13_0 == 114) : alt13 = 1 elif (LA13_0 == 117) : LA13_2 = self.input.LA(2) if (LA13_2 == 114) : alt13 = 3 elif (LA13_2 == 34 or LA13_2 == 39) : alt13 = 2 if alt13 == 1: # kv.g:536:5: 'r' pass self.match(114) elif alt13 == 2: # kv.g:536:11: 'u' pass self.match(117) elif alt13 == 3: # kv.g:536:17: 'ur' pass self.match("ur") # kv.g:537:3: ( '\"' ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* '\"' | '\\'' ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* '\\'' ) alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == 34) : alt16 = 1 elif (LA16_0 == 39) : alt16 = 2 else: nvae = NoViableAltException("", 16, 0, self.input) raise nvae if alt16 == 1: # kv.g:537:5: '\"' ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* '\"' pass self.match(34) # kv.g:537:9: ( ESC | ~ ( '\\\\' | '\\n' | '\"' ) )* while True: #loop14 alt14 = 3 LA14_0 = self.input.LA(1) if (LA14_0 == 92) : alt14 = 1 elif ((0 <= LA14_0 <= 9) or (11 <= LA14_0 <= 33) or (35 <= LA14_0 <= 91) or (93 <= LA14_0 <= 65535)) : alt14 = 2 if alt14 == 1: # kv.g:537:10: ESC pass self.mESC() elif alt14 == 2: # kv.g:537:14: ~ ( '\\\\' | '\\n' | '\"' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop14 self.match(34) elif alt16 == 2: # kv.g:538:5: '\\'' ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* '\\'' pass self.match(39) # kv.g:538:10: ( ESC | ~ ( '\\\\' | '\\n' | '\\'' ) )* while True: #loop15 alt15 = 3 LA15_0 = self.input.LA(1) if (LA15_0 == 92) : alt15 = 1 elif ((0 <= LA15_0 <= 9) or (11 <= LA15_0 <= 38) or (40 <= LA15_0 <= 91) or (93 <= LA15_0 <= 65535)) : alt15 = 2 if alt15 == 1: # kv.g:538:11: ESC pass self.mESC() elif alt15 == 2: # kv.g:538:15: ~ ( '\\\\' | '\\n' | '\\'' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop15 self.match(39) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "ESC" def mESC(self, ): try: # kv.g:542:5: ( '\\\\' . ) # kv.g:542:7: '\\\\' . pass self.match(92) self.matchAny() finally: pass # $ANTLR end "ESC" # $ANTLR start "NEWLINE" def mNEWLINE(self, ): try: _type = NEWLINE _channel = DEFAULT_CHANNEL # kv.g:544:9: ( ( ( '\\u000C' )? ( '\\r' )? '\\n' ) ) # kv.g:544:17: ( ( '\\u000C' )? ( '\\r' )? '\\n' ) pass # kv.g:544:17: ( ( '\\u000C' )? ( '\\r' )? '\\n' ) # kv.g:544:18: ( '\\u000C' )? ( '\\r' )? '\\n' pass # kv.g:544:18: ( '\\u000C' )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == 12) : alt17 = 1 if alt17 == 1: # kv.g:544:19: '\\u000C' pass self.match(12) # kv.g:544:29: ( '\\r' )? alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == 13) : alt18 = 1 if alt18 == 1: # kv.g:544:30: '\\r' pass self.match(13) self.match(10) #action start if self.nested > 0: _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NEWLINE" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # kv.g:545:5: ( ( ' ' | '\\t' )+ ) # kv.g:545:9: ( ' ' | '\\t' )+ pass # kv.g:545:9: ( ' ' | '\\t' )+ cnt19 = 0 while True: #loop19 alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == 9 or LA19_0 == 32) : alt19 = 1 if alt19 == 1: # kv.g: pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt19 >= 1: break #loop19 eee = EarlyExitException(19, self.input) raise eee cnt19 += 1 #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "NONE" def mNONE(self, ): try: _type = NONE _channel = DEFAULT_CHANNEL # kv.g:555:2: ( 'None' ) # kv.g:555:6: 'None' pass self.match("None") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NONE" # $ANTLR start "WNAME" def mWNAME(self, ): try: _type = WNAME _channel = DEFAULT_CHANNEL # kv.g:558:2: ( ( 'A' .. 'Z' ) ( 'A' .. 'Z' | 'a' .. 'z' | '_' | '0' .. '9' )* ) # kv.g:558:4: ( 'A' .. 'Z' ) ( 'A' .. 'Z' | 'a' .. 'z' | '_' | '0' .. '9' )* pass # kv.g:558:4: ( 'A' .. 'Z' ) # kv.g:558:6: 'A' .. 'Z' pass self.matchRange(65, 90) # kv.g:558:19: ( 'A' .. 'Z' | 'a' .. 'z' | '_' | '0' .. '9' )* while True: #loop20 alt20 = 2 LA20_0 = self.input.LA(1) if ((48 <= LA20_0 <= 57) or (65 <= LA20_0 <= 90) or LA20_0 == 95 or (97 <= LA20_0 <= 122)) : alt20 = 1 if alt20 == 1: # kv.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop20 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WNAME" # $ANTLR start "CANVAS" def mCANVAS(self, ): try: _type = CANVAS _channel = DEFAULT_CHANNEL # kv.g:561:2: ( 'canvas' | 'canvas.before' | 'canvas.after' ) alt21 = 3 alt21 = self.dfa21.predict(self.input) if alt21 == 1: # kv.g:561:4: 'canvas' pass self.match("canvas") elif alt21 == 2: # kv.g:561:15: 'canvas.before' pass self.match("canvas.before") elif alt21 == 3: # kv.g:561:33: 'canvas.after' pass self.match("canvas.after") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CANVAS" # $ANTLR start "NAME" def mNAME(self, ): try: _type = NAME _channel = DEFAULT_CHANNEL # kv.g:564:2: ( ( 'a' .. 'z' | '_' ) ( 'A' .. 'Z' | 'a' .. 'z' | '_' | '0' .. '9' )* ) # kv.g:564:4: ( 'a' .. 'z' | '_' ) ( 'A' .. 'Z' | 'a' .. 'z' | '_' | '0' .. '9' )* pass if self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # kv.g:564:25: ( 'A' .. 'Z' | 'a' .. 'z' | '_' | '0' .. '9' )* while True: #loop22 alt22 = 2 LA22_0 = self.input.LA(1) if ((48 <= LA22_0 <= 57) or (65 <= LA22_0 <= 90) or LA22_0 == 95 or (97 <= LA22_0 <= 122)) : alt22 = 1 if alt22 == 1: # kv.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop22 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NAME" # $ANTLR start "DIRECTIVETEXT" def mDIRECTIVETEXT(self, ): try: _type = DIRECTIVETEXT _channel = DEFAULT_CHANNEL # kv.g:567:2: ( HASH COLON (~ '\\n' )* ) # kv.g:567:4: HASH COLON (~ '\\n' )* pass self.mHASH() self.mCOLON() # kv.g:567:15: (~ '\\n' )* while True: #loop23 alt23 = 2 LA23_0 = self.input.LA(1) if ((0 <= LA23_0 <= 9) or (11 <= LA23_0 <= 65535)) : alt23 = 1 if alt23 == 1: # kv.g:567:16: ~ '\\n' pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop23 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DIRECTIVETEXT" # $ANTLR start "COMMENTTEXT" def mCOMMENTTEXT(self, ): try: _type = COMMENTTEXT _channel = DEFAULT_CHANNEL # kv.g:570:2: ( HASH (~ '\\n' )* ) # kv.g:570:4: HASH (~ '\\n' )* pass self.mHASH() # kv.g:570:9: (~ '\\n' )* while True: #loop24 alt24 = 2 LA24_0 = self.input.LA(1) if ((0 <= LA24_0 <= 9) or (11 <= LA24_0 <= 65535)) : alt24 = 1 if alt24 == 1: # kv.g:570:10: ~ '\\n' pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop24 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENTTEXT" # $ANTLR start "HASH" def mHASH(self, ): try: # kv.g:573:6: ( '#' ) # kv.g:573:17: '#' pass self.match(35) finally: pass # $ANTLR end "HASH" def mTokens(self): # kv.g:1:8: ( T__86 | T__87 | T__88 | T__89 | T__90 | T__91 | T__92 | T__93 | T__94 | T__95 | T__96 | T__97 | T__98 | T__99 | T__100 | T__101 | T__102 | T__103 | T__104 | T__105 | T__106 | T__107 | LPAREN | RPAREN | LBRACK | RBRACK | COLON | COMMA | SEMI | PLUS | MINUS | STAR | SLASH | VBAR | AMPER | LESS | GREATER | ASSIGN | PERCENT | BACKQUOTE | LCURLY | RCURLY | CIRCUMFLEX | TILDE | EQUAL | NOTEQUAL | ALT_NOTEQUAL | LESSEQUAL | LEFTSHIFT | GREATEREQUAL | RIGHTSHIFT | PLUSEQUAL | MINUSEQUAL | DOUBLESTAR | STAREQUAL | DOUBLESLASH | SLASHEQUAL | VBAREQUAL | PERCENTEQUAL | AMPEREQUAL | CIRCUMFLEXEQUAL | LEFTSHIFTEQUAL | RIGHTSHIFTEQUAL | DOUBLESTAREQUAL | DOUBLESLASHEQUAL | DOT | AT | AND | OR | NOT | FLOAT | LONGINT | INT | COMPLEX | STRING | NEWLINE | WS | NONE | WNAME | CANVAS | NAME | DIRECTIVETEXT | COMMENTTEXT ) alt25 = 83 alt25 = self.dfa25.predict(self.input) if alt25 == 1: # kv.g:1:10: T__86 pass self.mT__86() elif alt25 == 2: # kv.g:1:16: T__87 pass self.mT__87() elif alt25 == 3: # kv.g:1:22: T__88 pass self.mT__88() elif alt25 == 4: # kv.g:1:28: T__89 pass self.mT__89() elif alt25 == 5: # kv.g:1:34: T__90 pass self.mT__90() elif alt25 == 6: # kv.g:1:40: T__91 pass self.mT__91() elif alt25 == 7: # kv.g:1:46: T__92 pass self.mT__92() elif alt25 == 8: # kv.g:1:52: T__93 pass self.mT__93() elif alt25 == 9: # kv.g:1:58: T__94 pass self.mT__94() elif alt25 == 10: # kv.g:1:64: T__95 pass self.mT__95() elif alt25 == 11: # kv.g:1:70: T__96 pass self.mT__96() elif alt25 == 12: # kv.g:1:76: T__97 pass self.mT__97() elif alt25 == 13: # kv.g:1:82: T__98 pass self.mT__98() elif alt25 == 14: # kv.g:1:88: T__99 pass self.mT__99() elif alt25 == 15: # kv.g:1:94: T__100 pass self.mT__100() elif alt25 == 16: # kv.g:1:101: T__101 pass self.mT__101() elif alt25 == 17: # kv.g:1:108: T__102 pass self.mT__102() elif alt25 == 18: # kv.g:1:115: T__103 pass self.mT__103() elif alt25 == 19: # kv.g:1:122: T__104 pass self.mT__104() elif alt25 == 20: # kv.g:1:129: T__105 pass self.mT__105() elif alt25 == 21: # kv.g:1:136: T__106 pass self.mT__106() elif alt25 == 22: # kv.g:1:143: T__107 pass self.mT__107() elif alt25 == 23: # kv.g:1:150: LPAREN pass self.mLPAREN() elif alt25 == 24: # kv.g:1:157: RPAREN pass self.mRPAREN() elif alt25 == 25: # kv.g:1:164: LBRACK pass self.mLBRACK() elif alt25 == 26: # kv.g:1:171: RBRACK pass self.mRBRACK() elif alt25 == 27: # kv.g:1:178: COLON pass self.mCOLON() elif alt25 == 28: # kv.g:1:184: COMMA pass self.mCOMMA() elif alt25 == 29: # kv.g:1:190: SEMI pass self.mSEMI() elif alt25 == 30: # kv.g:1:195: PLUS pass self.mPLUS() elif alt25 == 31: # kv.g:1:200: MINUS pass self.mMINUS() elif alt25 == 32: # kv.g:1:206: STAR pass self.mSTAR() elif alt25 == 33: # kv.g:1:211: SLASH pass self.mSLASH() elif alt25 == 34: # kv.g:1:217: VBAR pass self.mVBAR() elif alt25 == 35: # kv.g:1:222: AMPER pass self.mAMPER() elif alt25 == 36: # kv.g:1:228: LESS pass self.mLESS() elif alt25 == 37: # kv.g:1:233: GREATER pass self.mGREATER() elif alt25 == 38: # kv.g:1:241: ASSIGN pass self.mASSIGN() elif alt25 == 39: # kv.g:1:248: PERCENT pass self.mPERCENT() elif alt25 == 40: # kv.g:1:256: BACKQUOTE pass self.mBACKQUOTE() elif alt25 == 41: # kv.g:1:266: LCURLY pass self.mLCURLY() elif alt25 == 42: # kv.g:1:273: RCURLY pass self.mRCURLY() elif alt25 == 43: # kv.g:1:280: CIRCUMFLEX pass self.mCIRCUMFLEX() elif alt25 == 44: # kv.g:1:291: TILDE pass self.mTILDE() elif alt25 == 45: # kv.g:1:297: EQUAL pass self.mEQUAL() elif alt25 == 46: # kv.g:1:303: NOTEQUAL pass self.mNOTEQUAL() elif alt25 == 47: # kv.g:1:312: ALT_NOTEQUAL pass self.mALT_NOTEQUAL() elif alt25 == 48: # kv.g:1:325: LESSEQUAL pass self.mLESSEQUAL() elif alt25 == 49: # kv.g:1:335: LEFTSHIFT pass self.mLEFTSHIFT() elif alt25 == 50: # kv.g:1:345: GREATEREQUAL pass self.mGREATEREQUAL() elif alt25 == 51: # kv.g:1:358: RIGHTSHIFT pass self.mRIGHTSHIFT() elif alt25 == 52: # kv.g:1:369: PLUSEQUAL pass self.mPLUSEQUAL() elif alt25 == 53: # kv.g:1:379: MINUSEQUAL pass self.mMINUSEQUAL() elif alt25 == 54: # kv.g:1:390: DOUBLESTAR pass self.mDOUBLESTAR() elif alt25 == 55: # kv.g:1:401: STAREQUAL pass self.mSTAREQUAL() elif alt25 == 56: # kv.g:1:411: DOUBLESLASH pass self.mDOUBLESLASH() elif alt25 == 57: # kv.g:1:423: SLASHEQUAL pass self.mSLASHEQUAL() elif alt25 == 58: # kv.g:1:434: VBAREQUAL pass self.mVBAREQUAL() elif alt25 == 59: # kv.g:1:444: PERCENTEQUAL pass self.mPERCENTEQUAL() elif alt25 == 60: # kv.g:1:457: AMPEREQUAL pass self.mAMPEREQUAL() elif alt25 == 61: # kv.g:1:468: CIRCUMFLEXEQUAL pass self.mCIRCUMFLEXEQUAL() elif alt25 == 62: # kv.g:1:484: LEFTSHIFTEQUAL pass self.mLEFTSHIFTEQUAL() elif alt25 == 63: # kv.g:1:499: RIGHTSHIFTEQUAL pass self.mRIGHTSHIFTEQUAL() elif alt25 == 64: # kv.g:1:515: DOUBLESTAREQUAL pass self.mDOUBLESTAREQUAL() elif alt25 == 65: # kv.g:1:531: DOUBLESLASHEQUAL pass self.mDOUBLESLASHEQUAL() elif alt25 == 66: # kv.g:1:548: DOT pass self.mDOT() elif alt25 == 67: # kv.g:1:552: AT pass self.mAT() elif alt25 == 68: # kv.g:1:555: AND pass self.mAND() elif alt25 == 69: # kv.g:1:559: OR pass self.mOR() elif alt25 == 70: # kv.g:1:562: NOT pass self.mNOT() elif alt25 == 71: # kv.g:1:566: FLOAT pass self.mFLOAT() elif alt25 == 72: # kv.g:1:572: LONGINT pass self.mLONGINT() elif alt25 == 73: # kv.g:1:580: INT pass self.mINT() elif alt25 == 74: # kv.g:1:584: COMPLEX pass self.mCOMPLEX() elif alt25 == 75: # kv.g:1:592: STRING pass self.mSTRING() elif alt25 == 76: # kv.g:1:599: NEWLINE pass self.mNEWLINE() elif alt25 == 77: # kv.g:1:607: WS pass self.mWS() elif alt25 == 78: # kv.g:1:610: NONE pass self.mNONE() elif alt25 == 79: # kv.g:1:615: WNAME pass self.mWNAME() elif alt25 == 80: # kv.g:1:621: CANVAS pass self.mCANVAS() elif alt25 == 81: # kv.g:1:628: NAME pass self.mNAME() elif alt25 == 82: # kv.g:1:633: DIRECTIVETEXT pass self.mDIRECTIVETEXT() elif alt25 == 83: # kv.g:1:647: COMMENTTEXT pass self.mCOMMENTTEXT() # lookup tables for DFA #5 DFA5_eot = DFA.unpack( u"\3\uffff\1\4\2\uffff" ) DFA5_eof = DFA.unpack( u"\6\uffff" ) DFA5_min = DFA.unpack( u"\1\56\1\uffff\1\56\1\105\2\uffff" ) DFA5_max = DFA.unpack( u"\1\71\1\uffff\2\145\2\uffff" ) DFA5_accept = DFA.unpack( u"\1\uffff\1\1\2\uffff\1\3\1\2" ) DFA5_special = DFA.unpack( u"\6\uffff" ) DFA5_transition = [ DFA.unpack(u"\1\1\1\uffff\12\2"), DFA.unpack(u""), DFA.unpack(u"\1\3\1\uffff\12\2\13\uffff\1\4\37\uffff\1\4"), DFA.unpack(u"\1\5\37\uffff\1\5"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #5 class DFA5(DFA): pass # lookup tables for DFA #11 DFA11_eot = DFA.unpack( u"\7\uffff" ) DFA11_eof = DFA.unpack( u"\7\uffff" ) DFA11_min = DFA.unpack( u"\3\56\2\uffff\2\56" ) DFA11_max = DFA.unpack( u"\1\71\1\170\1\152\2\uffff\2\152" ) DFA11_accept = DFA.unpack( u"\3\uffff\1\2\1\1\2\uffff" ) DFA11_special = DFA.unpack( u"\7\uffff" ) DFA11_transition = [ DFA.unpack(u"\1\3\1\uffff\1\1\11\2"), DFA.unpack(u"\1\3\1\uffff\12\5\13\uffff\1\3\4\uffff\1\4\15\uffff" u"\1\4\14\uffff\1\3\4\uffff\1\4\15\uffff\1\4"), DFA.unpack(u"\1\3\1\uffff\12\6\13\uffff\1\3\4\uffff\1\4\32\uffff" u"\1\3\4\uffff\1\4"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\3\1\uffff\12\5\13\uffff\1\3\4\uffff\1\4\32\uffff" u"\1\3\4\uffff\1\4"), DFA.unpack(u"\1\3\1\uffff\12\6\13\uffff\1\3\4\uffff\1\4\32\uffff" u"\1\3\4\uffff\1\4") ] # class definition for DFA #11 class DFA11(DFA): pass # lookup tables for DFA #21 DFA21_eot = DFA.unpack( u"\6\uffff\1\10\4\uffff" ) DFA21_eof = DFA.unpack( u"\13\uffff" ) DFA21_min = DFA.unpack( u"\1\143\1\141\1\156\1\166\1\141\1\163\1\56\1\141\3\uffff" ) DFA21_max = DFA.unpack( u"\1\143\1\141\1\156\1\166\1\141\1\163\1\56\1\142\3\uffff" ) DFA21_accept = DFA.unpack( u"\10\uffff\1\1\1\2\1\3" ) DFA21_special = DFA.unpack( u"\13\uffff" ) DFA21_transition = [ DFA.unpack(u"\1\1"), DFA.unpack(u"\1\2"), DFA.unpack(u"\1\3"), DFA.unpack(u"\1\4"), DFA.unpack(u"\1\5"), DFA.unpack(u"\1\6"), DFA.unpack(u"\1\7"), DFA.unpack(u"\1\12\1\11"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #21 class DFA21(DFA): pass # lookup tables for DFA #25 DFA25_eot = DFA.unpack( u"\1\uffff\15\61\7\uffff\1\111\1\113\1\116\1\121\1\123\1\125\1\131" u"\1\134\1\136\1\140\3\uffff\1\142\2\uffff\1\143\1\uffff\2\61\2\150" u"\1\61\3\uffff\1\60\2\uffff\1\161\11\61\1\176\1\177\1\u0080\1\u0082" u"\10\61\4\uffff\1\u008c\2\uffff\1\u008e\10\uffff\1\u0090\2\uffff" u"\1\u0092\10\uffff\1\u0093\1\u0095\1\61\2\uffff\1\u0093\1\150\3" u"\uffff\1\150\1\61\1\60\1\uffff\1\u009d\2\61\1\u00a1\10\61\3\uffff" u"\1\61\1\uffff\1\u00ab\2\61\1\u00ae\1\61\1\u00b0\2\61\13\uffff\1" u"\u00b5\1\150\1\uffff\1\u0093\1\uffff\1\u0093\1\60\1\uffff\1\u009d" u"\1\61\1\u00bb\1\uffff\4\61\1\u00c0\1\61\1\u00c2\1\u00c3\1\61\1" u"\uffff\1\61\1\u00c6\1\uffff\1\61\1\uffff\2\61\1\uffff\1\u0093\2" u"\uffff\1\u0093\1\uffff\1\u00cc\1\u00cd\1\uffff\1\u00ce\2\61\1\u00d1" u"\1\uffff\1\61\2\uffff\1\61\1\u00d4\1\uffff\2\61\1\u00d7\1\uffff" u"\1\u0093\3\uffff\1\61\1\u00d9\1\uffff\1\u00da\1\u00db\1\uffff\1" u"\61\1\u00dd\1\uffff\1\61\3\uffff\1\u00df\1\uffff\1\u00e0\2\uffff" ) DFA25_eof = DFA.unpack( u"\u00e1\uffff" ) DFA25_min = DFA.unpack( u"\1\11\1\141\1\145\1\162\1\141\1\42\1\154\1\146\1\156\1\150\1\151" u"\1\162\1\141\1\151\7\uffff\2\75\1\52\1\57\2\75\1\74\3\75\3\uffff" u"\1\75\2\uffff\1\60\1\uffff\1\162\1\157\2\56\1\42\3\uffff\1\157" u"\2\uffff\1\72\1\151\1\163\1\154\1\145\2\156\1\151\1\143\1\151\4" u"\60\1\144\1\151\1\164\1\162\1\156\1\171\1\155\1\145\4\uffff\1\75" u"\2\uffff\1\75\10\uffff\1\75\2\uffff\1\75\10\uffff\2\60\1\164\1" u"\60\1\uffff\1\60\1\56\2\uffff\1\53\1\56\1\42\1\156\1\uffff\1\0" u"\1\156\1\163\1\60\1\141\1\164\1\166\1\163\1\143\2\145\1\146\3\uffff" u"\1\145\1\uffff\1\60\1\154\1\150\1\60\1\141\1\60\1\142\1\154\11" u"\uffff\1\53\1\uffff\2\60\1\53\3\60\1\145\1\uffff\1\0\1\164\1\60" u"\1\uffff\1\153\1\151\1\141\1\145\1\60\1\160\2\60\1\162\1\uffff" u"\1\145\1\60\1\uffff\1\154\1\uffff\2\144\2\60\1\uffff\2\60\1\53" u"\2\60\1\uffff\1\60\1\156\1\163\1\60\1\uffff\1\164\2\uffff\1\164" u"\1\60\1\uffff\1\154\1\141\3\60\3\uffff\1\165\1\60\1\uffff\2\60" u"\1\uffff\1\171\1\60\1\uffff\1\145\3\uffff\1\60\1\uffff\1\60\2\uffff" ) DFA25_max = DFA.unpack( u"\1\176\1\162\1\145\1\162\1\157\1\141\1\170\2\163\1\151\1\157\1" u"\162\1\141\1\151\7\uffff\6\75\2\76\2\75\3\uffff\1\75\2\uffff\1" u"\71\1\uffff\1\162\1\157\1\170\1\154\1\162\3\uffff\1\157\2\uffff" u"\1\72\1\151\1\163\1\154\1\145\2\156\1\151\1\145\1\163\4\172\1\144" u"\1\151\1\164\1\162\1\156\1\171\1\155\1\145\4\uffff\1\75\2\uffff" u"\1\75\10\uffff\1\75\2\uffff\1\75\10\uffff\1\152\1\172\1\164\1\146" u"\1\uffff\1\152\1\154\2\uffff\1\71\1\154\1\47\1\156\1\uffff\1\uffff" u"\1\156\1\163\1\172\1\141\1\164\1\166\1\163\1\143\2\145\1\146\3" u"\uffff\1\145\1\uffff\1\172\1\154\1\150\1\172\1\141\1\172\1\142" u"\1\154\11\uffff\1\71\1\uffff\1\172\1\154\1\71\1\152\1\71\1\152" u"\1\145\1\uffff\1\uffff\1\164\1\172\1\uffff\1\153\1\151\1\141\1" u"\145\1\172\1\160\2\172\1\162\1\uffff\1\145\1\172\1\uffff\1\154" u"\1\uffff\2\144\1\71\1\152\1\uffff\1\71\1\152\1\71\2\172\1\uffff" u"\1\172\1\156\1\163\1\172\1\uffff\1\164\2\uffff\1\164\1\172\1\uffff" u"\1\154\1\141\1\172\1\71\1\152\3\uffff\1\165\1\172\1\uffff\2\172" u"\1\uffff\1\171\1\172\1\uffff\1\145\3\uffff\1\172\1\uffff\1\172" u"\2\uffff" ) DFA25_accept = DFA.unpack( u"\16\uffff\1\27\1\30\1\31\1\32\1\33\1\34\1\35\12\uffff\1\50\1\51" u"\1\52\1\uffff\1\54\1\56\1\uffff\1\103\5\uffff\1\113\1\114\1\115" u"\1\uffff\1\117\1\121\26\uffff\1\64\1\36\1\65\1\37\1\uffff\1\67" u"\1\40\1\uffff\1\71\1\41\1\72\1\42\1\74\1\43\1\57\1\60\1\uffff\1" u"\44\1\62\1\uffff\1\45\1\55\1\46\1\73\1\47\1\75\1\53\1\102\4\uffff" u"\1\111\2\uffff\1\110\1\112\4\uffff\1\123\14\uffff\1\10\1\12\1\24" u"\1\uffff\1\22\10\uffff\1\100\1\66\1\101\1\70\1\76\1\61\1\77\1\63" u"\1\107\1\uffff\1\105\7\uffff\1\122\3\uffff\1\2\11\uffff\1\104\2" u"\uffff\1\16\1\uffff\1\17\4\uffff\1\106\5\uffff\1\3\4\uffff\1\7" u"\1\uffff\1\13\1\14\2\uffff\1\21\5\uffff\1\116\1\1\1\4\2\uffff\1" u"\6\2\uffff\1\15\2\uffff\1\26\1\uffff\1\120\1\23\1\11\1\uffff\1" u"\25\1\uffff\1\20\1\5" ) DFA25_special = DFA.unpack( u"\162\uffff\1\1\53\uffff\1\0\102\uffff" ) DFA25_transition = [ DFA.unpack(u"\1\56\1\55\1\uffff\2\55\22\uffff\1\56\1\44\1\54\1\62" u"\1\uffff\1\36\1\32\1\54\1\16\1\17\1\27\1\25\1\23\1\26\1\45\1\30" u"\1\51\11\52\1\22\1\24\1\33\1\35\1\34\1\uffff\1\46\15\60\1\57\14" u"\60\1\20\1\uffff\1\21\1\42\1\61\1\37\1\10\1\3\1\4\1\2\1\6\1\12" u"\2\61\1\7\2\61\1\14\1\61\1\50\1\47\1\1\1\61\1\5\1\61\1\13\1\53" u"\1\61\1\11\1\61\1\15\1\61\1\40\1\31\1\41\1\43"), DFA.unpack(u"\1\64\20\uffff\1\63"), DFA.unpack(u"\1\65"), DFA.unpack(u"\1\66"), DFA.unpack(u"\1\70\15\uffff\1\67"), DFA.unpack(u"\1\54\4\uffff\1\54\71\uffff\1\71"), DFA.unpack(u"\1\73\13\uffff\1\72"), DFA.unpack(u"\1\75\7\uffff\1\74\4\uffff\1\76"), DFA.unpack(u"\1\100\4\uffff\1\77"), DFA.unpack(u"\1\101\1\102"), DFA.unpack(u"\1\104\5\uffff\1\103"), DFA.unpack(u"\1\105"), DFA.unpack(u"\1\106"), DFA.unpack(u"\1\107"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\110"), DFA.unpack(u"\1\112"), DFA.unpack(u"\1\114\22\uffff\1\115"), DFA.unpack(u"\1\117\15\uffff\1\120"), DFA.unpack(u"\1\122"), DFA.unpack(u"\1\124"), DFA.unpack(u"\1\130\1\127\1\126"), DFA.unpack(u"\1\132\1\133"), DFA.unpack(u"\1\135"), DFA.unpack(u"\1\137"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\141"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\144"), DFA.unpack(u""), DFA.unpack(u"\1\145"), DFA.unpack(u"\1\146"), DFA.unpack(u"\1\151\1\uffff\12\152\13\uffff\1\155\4\uffff\1\154" u"\1\uffff\1\153\13\uffff\1\147\14\uffff\1\155\4\uffff\1\154\1\uffff" u"\1\153\13\uffff\1\147"), DFA.unpack(u"\1\151\1\uffff\12\156\13\uffff\1\155\4\uffff\1\154" u"\1\uffff\1\153\30\uffff\1\155\4\uffff\1\154\1\uffff\1\153"), DFA.unpack(u"\1\54\4\uffff\1\54\112\uffff\1\157"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\160"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\162"), DFA.unpack(u"\1\163"), DFA.unpack(u"\1\164"), DFA.unpack(u"\1\165"), DFA.unpack(u"\1\166"), DFA.unpack(u"\1\167"), DFA.unpack(u"\1\170"), DFA.unpack(u"\1\171"), DFA.unpack(u"\1\173\1\uffff\1\172"), DFA.unpack(u"\1\175\11\uffff\1\174"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\22\61\1\u0081" u"\7\61"), DFA.unpack(u"\1\u0083"), DFA.unpack(u"\1\u0084"), DFA.unpack(u"\1\u0085"), DFA.unpack(u"\1\u0086"), DFA.unpack(u"\1\u0087"), DFA.unpack(u"\1\u0088"), DFA.unpack(u"\1\u0089"), DFA.unpack(u"\1\u008a"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u008b"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u008d"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u008f"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0091"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\144\13\uffff\1\u0094\4\uffff\1\154\32\uffff\1\u0094" u"\4\uffff\1\154"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\1\u0096"), DFA.unpack(u"\12\u0097\7\uffff\6\u0097\32\uffff\6\u0097"), DFA.unpack(u""), DFA.unpack(u"\12\u0099\13\uffff\1\u0098\4\uffff\1\154\32\uffff\1" u"\u0098\4\uffff\1\154"), DFA.unpack(u"\1\151\1\uffff\12\152\13\uffff\1\155\4\uffff\1\154" u"\1\uffff\1\153\30\uffff\1\155\4\uffff\1\154\1\uffff\1\153"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u009a\1\uffff\1\u009a\2\uffff\12\u009b"), DFA.unpack(u"\1\151\1\uffff\12\156\13\uffff\1\155\4\uffff\1\154" u"\1\uffff\1\153\30\uffff\1\155\4\uffff\1\154\1\uffff\1\153"), DFA.unpack(u"\1\54\4\uffff\1\54"), DFA.unpack(u"\1\u009c"), DFA.unpack(u""), DFA.unpack(u"\12\u009e\1\uffff\ufff5\u009e"), DFA.unpack(u"\1\u009f"), DFA.unpack(u"\1\u00a0"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\1\u00a2"), DFA.unpack(u"\1\u00a3"), DFA.unpack(u"\1\u00a4"), DFA.unpack(u"\1\u00a5"), DFA.unpack(u"\1\u00a6"), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\1\u00a8"), DFA.unpack(u"\1\u00a9"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00aa"), DFA.unpack(u""), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\1\u00ac"), DFA.unpack(u"\1\u00ad"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\1\u00b2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00b3\1\uffff\1\u00b3\2\uffff\12\u00b4"), DFA.unpack(u""), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\12\u0097\7\uffff\6\u0097\3\uffff\1\154\1\uffff\1\153" u"\24\uffff\6\u0097\3\uffff\1\154\1\uffff\1\153"), DFA.unpack(u"\1\u00b6\1\uffff\1\u00b6\2\uffff\12\u00b7"), DFA.unpack(u"\12\u0099\13\uffff\1\u00b8\4\uffff\1\154\32\uffff\1" u"\u00b8\4\uffff\1\154"), DFA.unpack(u"\12\u009b"), DFA.unpack(u"\12\u009b\20\uffff\1\154\37\uffff\1\154"), DFA.unpack(u"\1\u00b9"), DFA.unpack(u""), DFA.unpack(u"\12\u009e\1\uffff\ufff5\u009e"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\1\u00bd"), DFA.unpack(u"\1\u00be"), DFA.unpack(u"\1\u00bf"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\1\u00c1"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\1\u00c4"), DFA.unpack(u""), DFA.unpack(u"\1\u00c5"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\1\u00c7"), DFA.unpack(u""), DFA.unpack(u"\1\u00c8"), DFA.unpack(u"\1\u00c9"), DFA.unpack(u"\12\u00b4"), DFA.unpack(u"\12\u00b4\20\uffff\1\154\37\uffff\1\154"), DFA.unpack(u""), DFA.unpack(u"\12\u00b7"), DFA.unpack(u"\12\u00b7\20\uffff\1\154\37\uffff\1\154"), DFA.unpack(u"\1\u00ca\1\uffff\1\u00ca\2\uffff\12\u00cb"), DFA.unpack(u"\12\60\7\uffff\32\60\4\uffff\1\60\1\uffff\32\60"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\1\u00cf"), DFA.unpack(u"\1\u00d0"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\1\u00d2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00d3"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\1\u00d5"), DFA.unpack(u"\1\u00d6"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\12\u00cb"), DFA.unpack(u"\12\u00cb\20\uffff\1\154\37\uffff\1\154"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00d8"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\1\u00dc"), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\1\u00de"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"\12\61\7\uffff\32\61\4\uffff\1\61\1\uffff\32\61"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #25 class DFA25(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA25_158 = input.LA(1) s = -1 if ((0 <= LA25_158 <= 9) or (11 <= LA25_158 <= 65535)): s = 158 else: s = 157 if s >= 0: return s elif s == 1: LA25_114 = input.LA(1) s = -1 if ((0 <= LA25_114 <= 9) or (11 <= LA25_114 <= 65535)): s = 158 else: s = 157 if s >= 0: return s nvae = NoViableAltException(self_.getDescription(), 25, _s, input) self_.error(nvae) raise nvae def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(kvLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "kived/kvlang", "path": "kvlang/kvLexer.py", "copies": "1", "size": "84492", "license": "mit", "hash": 9083071825809299000, "line_mean": 20.3687405159, "line_max": 836, "alpha_frac": 0.4160275529, "autogenerated": false, "ratio": 3.1503355704697986, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9014719696782785, "avg_score": 0.010328685317402742, "num_lines": 3954 }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 lesscss.g 2012-12-04 00:36:14 import sys from antlr3 import * from antlr3.compat import set, frozenset from antlr3.tree import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types FUNCTION=45 UNICODE_RANGE=67 STAR=44 EOF=-1 MEDIA_SYM=26 LBRACKET=43 INCLUDES=48 RPAREN=33 NAME=75 GREATER=40 ESCAPE=72 DIMENSION=108 STRINGESC=106 NL=109 COMMENT=103 D=80 E=81 F=82 G=83 A=77 RBRACE=28 B=78 C=79 L=88 IMPORT_SYM=24 NMCHAR=74 M=89 SUBSTRINGMATCH=52 N=90 O=91 H=84 I=85 J=86 NUMBER=55 K=87 U=97 T=96 W=99 V=98 Q=93 P=92 S=95 CDO=104 R=94 CDC=105 Y=101 PERCENTAGE=37 URL=76 X=100 Z=102 URI=25 PAGE_SYM=35 WS=107 DASHMATCH=49 EMS=57 N_Less_VarDef=20 N_PseudoFunction=17 N_RuleSet=7 NONASCII=70 N_MediaQuery=5 N_Expr=19 N_Selector=10 LBRACE=27 LPAREN=31 LENGTH=56 IMPORTANT_SYM=53 N_Function=12 TIME=62 KEYFRAMES_SYM=36 COMMA=29 N_StyleSheet=4 IDENT=30 PLUS=39 FREQ=63 RBRACKET=46 DOT=42 VPORTLEN=65 CHARSET_SYM=21 ANGLE=61 REMS=59 HASH=41 HEXCHAR=69 RESOLUTION=64 PREFIXMATCH=50 MINUS=68 N_Pseudo=16 SOLIDUS=54 SEMI=23 N_Empty=14 UNICODE=71 CHS=60 COLON=32 NMSTART=73 N_Declaration=11 FONTFACE_SYM=34 OPEQ=47 N_Term=18 EXS=58 M_KeyframeSelector=9 N_Space=15 N_MediaExpr=6 N_Attrib=13 N_KeyframeBlock=8 SUFFIXMATCH=51 LESS_VARNAME=38 NTH=66 STRING=22 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "N_StyleSheet", "N_MediaQuery", "N_MediaExpr", "N_RuleSet", "N_KeyframeBlock", "M_KeyframeSelector", "N_Selector", "N_Declaration", "N_Function", "N_Attrib", "N_Empty", "N_Space", "N_Pseudo", "N_PseudoFunction", "N_Term", "N_Expr", "N_Less_VarDef", "CHARSET_SYM", "STRING", "SEMI", "IMPORT_SYM", "URI", "MEDIA_SYM", "LBRACE", "RBRACE", "COMMA", "IDENT", "LPAREN", "COLON", "RPAREN", "FONTFACE_SYM", "PAGE_SYM", "KEYFRAMES_SYM", "PERCENTAGE", "LESS_VARNAME", "PLUS", "GREATER", "HASH", "DOT", "LBRACKET", "STAR", "FUNCTION", "RBRACKET", "OPEQ", "INCLUDES", "DASHMATCH", "PREFIXMATCH", "SUFFIXMATCH", "SUBSTRINGMATCH", "IMPORTANT_SYM", "SOLIDUS", "NUMBER", "LENGTH", "EMS", "EXS", "REMS", "CHS", "ANGLE", "TIME", "FREQ", "RESOLUTION", "VPORTLEN", "NTH", "UNICODE_RANGE", "MINUS", "HEXCHAR", "NONASCII", "UNICODE", "ESCAPE", "NMSTART", "NMCHAR", "NAME", "URL", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "COMMENT", "CDO", "CDC", "STRINGESC", "WS", "DIMENSION", "NL" ] class lesscssParser(Parser): grammarFileName = "lesscss.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(lesscssParser, self).__init__(input, state, *args, **kwargs) self.dfa17 = self.DFA17( self, 17, eot = self.DFA17_eot, eof = self.DFA17_eof, min = self.DFA17_min, max = self.DFA17_max, accept = self.DFA17_accept, special = self.DFA17_special, transition = self.DFA17_transition ) self.dfa36 = self.DFA36( self, 36, eot = self.DFA36_eot, eof = self.DFA36_eof, min = self.DFA36_min, max = self.DFA36_max, accept = self.DFA36_accept, special = self.DFA36_special, transition = self.DFA36_transition ) self._adaptor = None self.adaptor = CommonTreeAdaptor() def getTreeAdaptor(self): return self._adaptor def setTreeAdaptor(self, adaptor): self._adaptor = adaptor adaptor = property(getTreeAdaptor, setTreeAdaptor) class styleSheet_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.styleSheet_return, self).__init__() self.tree = None # $ANTLR start "styleSheet" # lesscss.g:69:1: styleSheet : ( charSet )? ( imports )* ( body )* EOF -> ^( N_StyleSheet ( charSet )? ( imports )* ( body )* ) ; def styleSheet(self, ): retval = self.styleSheet_return() retval.start = self.input.LT(1) root_0 = None EOF4 = None charSet1 = None imports2 = None body3 = None EOF4_tree = None stream_EOF = RewriteRuleTokenStream(self._adaptor, "token EOF") stream_body = RewriteRuleSubtreeStream(self._adaptor, "rule body") stream_charSet = RewriteRuleSubtreeStream(self._adaptor, "rule charSet") stream_imports = RewriteRuleSubtreeStream(self._adaptor, "rule imports") try: try: # lesscss.g:70:2: ( ( charSet )? ( imports )* ( body )* EOF -> ^( N_StyleSheet ( charSet )? ( imports )* ( body )* ) ) # lesscss.g:70:4: ( charSet )? ( imports )* ( body )* EOF pass # lesscss.g:70:4: ( charSet )? alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == CHARSET_SYM) : alt1 = 1 if alt1 == 1: # lesscss.g:70:4: charSet pass self._state.following.append(self.FOLLOW_charSet_in_styleSheet147) charSet1 = self.charSet() self._state.following.pop() if self._state.backtracking == 0: stream_charSet.add(charSet1.tree) # lesscss.g:71:4: ( imports )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == IMPORT_SYM) : alt2 = 1 if alt2 == 1: # lesscss.g:71:4: imports pass self._state.following.append(self.FOLLOW_imports_in_styleSheet153) imports2 = self.imports() self._state.following.pop() if self._state.backtracking == 0: stream_imports.add(imports2.tree) else: break #loop2 # lesscss.g:72:4: ( body )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == MEDIA_SYM or LA3_0 == IDENT or LA3_0 == COLON or (FONTFACE_SYM <= LA3_0 <= KEYFRAMES_SYM) or LA3_0 == LESS_VARNAME or (HASH <= LA3_0 <= STAR)) : alt3 = 1 if alt3 == 1: # lesscss.g:72:4: body pass self._state.following.append(self.FOLLOW_body_in_styleSheet159) body3 = self.body() self._state.following.pop() if self._state.backtracking == 0: stream_body.add(body3.tree) else: break #loop3 EOF4=self.match(self.input, EOF, self.FOLLOW_EOF_in_styleSheet165) if self._state.backtracking == 0: stream_EOF.add(EOF4) # AST Rewrite # elements: body, charSet, imports # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 74:3: -> ^( N_StyleSheet ( charSet )? ( imports )* ( body )* ) # lesscss.g:74:6: ^( N_StyleSheet ( charSet )? ( imports )* ( body )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_StyleSheet, "N_StyleSheet"), root_1) # lesscss.g:74:21: ( charSet )? if stream_charSet.hasNext(): self._adaptor.addChild(root_1, stream_charSet.nextTree()) stream_charSet.reset(); # lesscss.g:74:30: ( imports )* while stream_imports.hasNext(): self._adaptor.addChild(root_1, stream_imports.nextTree()) stream_imports.reset(); # lesscss.g:74:39: ( body )* while stream_body.hasNext(): self._adaptor.addChild(root_1, stream_body.nextTree()) stream_body.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "styleSheet" class charSet_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.charSet_return, self).__init__() self.tree = None # $ANTLR start "charSet" # lesscss.g:80:1: charSet : CHARSET_SYM STRING SEMI ; def charSet(self, ): retval = self.charSet_return() retval.start = self.input.LT(1) root_0 = None CHARSET_SYM5 = None STRING6 = None SEMI7 = None CHARSET_SYM5_tree = None STRING6_tree = None SEMI7_tree = None try: try: # lesscss.g:81:2: ( CHARSET_SYM STRING SEMI ) # lesscss.g:81:4: CHARSET_SYM STRING SEMI pass root_0 = self._adaptor.nil() CHARSET_SYM5=self.match(self.input, CHARSET_SYM, self.FOLLOW_CHARSET_SYM_in_charSet197) if self._state.backtracking == 0: CHARSET_SYM5_tree = self._adaptor.createWithPayload(CHARSET_SYM5) root_0 = self._adaptor.becomeRoot(CHARSET_SYM5_tree, root_0) STRING6=self.match(self.input, STRING, self.FOLLOW_STRING_in_charSet200) if self._state.backtracking == 0: STRING6_tree = self._adaptor.createWithPayload(STRING6) self._adaptor.addChild(root_0, STRING6_tree) SEMI7=self.match(self.input, SEMI, self.FOLLOW_SEMI_in_charSet202) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "charSet" class imports_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.imports_return, self).__init__() self.tree = None # $ANTLR start "imports" # lesscss.g:87:1: imports : IMPORT_SYM importUrl ( media_query_list )? SEMI ; def imports(self, ): retval = self.imports_return() retval.start = self.input.LT(1) root_0 = None IMPORT_SYM8 = None SEMI11 = None importUrl9 = None media_query_list10 = None IMPORT_SYM8_tree = None SEMI11_tree = None try: try: # lesscss.g:88:2: ( IMPORT_SYM importUrl ( media_query_list )? SEMI ) # lesscss.g:88:4: IMPORT_SYM importUrl ( media_query_list )? SEMI pass root_0 = self._adaptor.nil() IMPORT_SYM8=self.match(self.input, IMPORT_SYM, self.FOLLOW_IMPORT_SYM_in_imports217) if self._state.backtracking == 0: IMPORT_SYM8_tree = self._adaptor.createWithPayload(IMPORT_SYM8) root_0 = self._adaptor.becomeRoot(IMPORT_SYM8_tree, root_0) self._state.following.append(self.FOLLOW_importUrl_in_imports220) importUrl9 = self.importUrl() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, importUrl9.tree) # lesscss.g:88:26: ( media_query_list )? alt4 = 2 LA4_0 = self.input.LA(1) if ((IDENT <= LA4_0 <= LPAREN)) : alt4 = 1 if alt4 == 1: # lesscss.g:88:26: media_query_list pass self._state.following.append(self.FOLLOW_media_query_list_in_imports222) media_query_list10 = self.media_query_list() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, media_query_list10.tree) SEMI11=self.match(self.input, SEMI, self.FOLLOW_SEMI_in_imports225) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "imports" class importUrl_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.importUrl_return, self).__init__() self.tree = None # $ANTLR start "importUrl" # lesscss.g:91:1: importUrl : ( STRING | URI ); def importUrl(self, ): retval = self.importUrl_return() retval.start = self.input.LT(1) root_0 = None set12 = None set12_tree = None try: try: # lesscss.g:92:2: ( STRING | URI ) # lesscss.g: pass root_0 = self._adaptor.nil() set12 = self.input.LT(1) if self.input.LA(1) == STRING or self.input.LA(1) == URI: self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set12)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "importUrl" class body_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.body_return, self).__init__() self.tree = None # $ANTLR start "body" # lesscss.g:100:1: body : ( ruleSet | media | page | fontface | keyframes | less_variable_def ); def body(self, ): retval = self.body_return() retval.start = self.input.LT(1) root_0 = None ruleSet13 = None media14 = None page15 = None fontface16 = None keyframes17 = None less_variable_def18 = None try: try: # lesscss.g:101:2: ( ruleSet | media | page | fontface | keyframes | less_variable_def ) alt5 = 6 LA5 = self.input.LA(1) if LA5 == IDENT or LA5 == COLON or LA5 == HASH or LA5 == DOT or LA5 == LBRACKET or LA5 == STAR: alt5 = 1 elif LA5 == MEDIA_SYM: alt5 = 2 elif LA5 == PAGE_SYM: alt5 = 3 elif LA5 == FONTFACE_SYM: alt5 = 4 elif LA5 == KEYFRAMES_SYM: alt5 = 5 elif LA5 == LESS_VARNAME: alt5 = 6 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 5, 0, self.input) raise nvae if alt5 == 1: # lesscss.g:101:4: ruleSet pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_ruleSet_in_body257) ruleSet13 = self.ruleSet() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, ruleSet13.tree) elif alt5 == 2: # lesscss.g:102:4: media pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_media_in_body262) media14 = self.media() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, media14.tree) elif alt5 == 3: # lesscss.g:103:4: page pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_page_in_body267) page15 = self.page() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, page15.tree) elif alt5 == 4: # lesscss.g:104:4: fontface pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_fontface_in_body272) fontface16 = self.fontface() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, fontface16.tree) elif alt5 == 5: # lesscss.g:105:4: keyframes pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_keyframes_in_body277) keyframes17 = self.keyframes() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, keyframes17.tree) elif alt5 == 6: # lesscss.g:106:4: less_variable_def pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_less_variable_def_in_body282) less_variable_def18 = self.less_variable_def() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, less_variable_def18.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "body" class media_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.media_return, self).__init__() self.tree = None # $ANTLR start "media" # lesscss.g:114:1: media : MEDIA_SYM ( media_query_list )? LBRACE ( body )* RBRACE ; def media(self, ): retval = self.media_return() retval.start = self.input.LT(1) root_0 = None MEDIA_SYM19 = None LBRACE21 = None RBRACE23 = None media_query_list20 = None body22 = None MEDIA_SYM19_tree = None LBRACE21_tree = None RBRACE23_tree = None try: try: # lesscss.g:115:2: ( MEDIA_SYM ( media_query_list )? LBRACE ( body )* RBRACE ) # lesscss.g:115:4: MEDIA_SYM ( media_query_list )? LBRACE ( body )* RBRACE pass root_0 = self._adaptor.nil() MEDIA_SYM19=self.match(self.input, MEDIA_SYM, self.FOLLOW_MEDIA_SYM_in_media301) if self._state.backtracking == 0: MEDIA_SYM19_tree = self._adaptor.createWithPayload(MEDIA_SYM19) root_0 = self._adaptor.becomeRoot(MEDIA_SYM19_tree, root_0) # lesscss.g:115:15: ( media_query_list )? alt6 = 2 LA6_0 = self.input.LA(1) if ((IDENT <= LA6_0 <= LPAREN)) : alt6 = 1 if alt6 == 1: # lesscss.g:115:15: media_query_list pass self._state.following.append(self.FOLLOW_media_query_list_in_media304) media_query_list20 = self.media_query_list() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, media_query_list20.tree) LBRACE21=self.match(self.input, LBRACE, self.FOLLOW_LBRACE_in_media309) # lesscss.g:117:4: ( body )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == MEDIA_SYM or LA7_0 == IDENT or LA7_0 == COLON or (FONTFACE_SYM <= LA7_0 <= KEYFRAMES_SYM) or LA7_0 == LESS_VARNAME or (HASH <= LA7_0 <= STAR)) : alt7 = 1 if alt7 == 1: # lesscss.g:117:4: body pass self._state.following.append(self.FOLLOW_body_in_media315) body22 = self.body() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, body22.tree) else: break #loop7 RBRACE23=self.match(self.input, RBRACE, self.FOLLOW_RBRACE_in_media324) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "media" class media_query_list_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.media_query_list_return, self).__init__() self.tree = None # $ANTLR start "media_query_list" # lesscss.g:124:1: media_query_list : media_query ( COMMA media_query )* -> ( ^( N_MediaQuery media_query ) )+ ; def media_query_list(self, ): retval = self.media_query_list_return() retval.start = self.input.LT(1) root_0 = None COMMA25 = None media_query24 = None media_query26 = None COMMA25_tree = None stream_COMMA = RewriteRuleTokenStream(self._adaptor, "token COMMA") stream_media_query = RewriteRuleSubtreeStream(self._adaptor, "rule media_query") try: try: # lesscss.g:125:2: ( media_query ( COMMA media_query )* -> ( ^( N_MediaQuery media_query ) )+ ) # lesscss.g:125:4: media_query ( COMMA media_query )* pass self._state.following.append(self.FOLLOW_media_query_in_media_query_list339) media_query24 = self.media_query() self._state.following.pop() if self._state.backtracking == 0: stream_media_query.add(media_query24.tree) # lesscss.g:125:16: ( COMMA media_query )* while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == COMMA) : alt8 = 1 if alt8 == 1: # lesscss.g:125:17: COMMA media_query pass COMMA25=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_media_query_list342) if self._state.backtracking == 0: stream_COMMA.add(COMMA25) self._state.following.append(self.FOLLOW_media_query_in_media_query_list344) media_query26 = self.media_query() self._state.following.pop() if self._state.backtracking == 0: stream_media_query.add(media_query26.tree) else: break #loop8 # AST Rewrite # elements: media_query # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 126:3: -> ( ^( N_MediaQuery media_query ) )+ # lesscss.g:126:6: ( ^( N_MediaQuery media_query ) )+ if not (stream_media_query.hasNext()): raise RewriteEarlyExitException() while stream_media_query.hasNext(): # lesscss.g:126:6: ^( N_MediaQuery media_query ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_MediaQuery, "N_MediaQuery"), root_1) self._adaptor.addChild(root_1, stream_media_query.nextTree()) self._adaptor.addChild(root_0, root_1) stream_media_query.reset() retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "media_query_list" class media_query_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.media_query_return, self).__init__() self.tree = None # $ANTLR start "media_query" # lesscss.g:131:1: media_query : ( media_stmt | media_expr )+ ; def media_query(self, ): retval = self.media_query_return() retval.start = self.input.LT(1) root_0 = None media_stmt27 = None media_expr28 = None try: try: # lesscss.g:132:2: ( ( media_stmt | media_expr )+ ) # lesscss.g:132:4: ( media_stmt | media_expr )+ pass root_0 = self._adaptor.nil() # lesscss.g:132:4: ( media_stmt | media_expr )+ cnt9 = 0 while True: #loop9 alt9 = 3 LA9_0 = self.input.LA(1) if (LA9_0 == IDENT) : alt9 = 1 elif (LA9_0 == LPAREN) : alt9 = 2 if alt9 == 1: # lesscss.g:132:6: media_stmt pass self._state.following.append(self.FOLLOW_media_stmt_in_media_query373) media_stmt27 = self.media_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, media_stmt27.tree) elif alt9 == 2: # lesscss.g:132:19: media_expr pass self._state.following.append(self.FOLLOW_media_expr_in_media_query377) media_expr28 = self.media_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, media_expr28.tree) else: if cnt9 >= 1: break #loop9 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(9, self.input) raise eee cnt9 += 1 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "media_query" class media_stmt_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.media_stmt_return, self).__init__() self.tree = None # $ANTLR start "media_stmt" # lesscss.g:135:1: media_stmt : IDENT ; def media_stmt(self, ): retval = self.media_stmt_return() retval.start = self.input.LT(1) root_0 = None IDENT29 = None IDENT29_tree = None try: try: # lesscss.g:136:2: ( IDENT ) # lesscss.g:136:4: IDENT pass root_0 = self._adaptor.nil() IDENT29=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_media_stmt391) if self._state.backtracking == 0: IDENT29_tree = self._adaptor.createWithPayload(IDENT29) self._adaptor.addChild(root_0, IDENT29_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "media_stmt" class media_expr_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.media_expr_return, self).__init__() self.tree = None # $ANTLR start "media_expr" # lesscss.g:139:1: media_expr : LPAREN media_stmt ( COLON expr )? RPAREN -> ^( N_MediaExpr media_stmt ( expr )? ) ; def media_expr(self, ): retval = self.media_expr_return() retval.start = self.input.LT(1) root_0 = None LPAREN30 = None COLON32 = None RPAREN34 = None media_stmt31 = None expr33 = None LPAREN30_tree = None COLON32_tree = None RPAREN34_tree = None stream_COLON = RewriteRuleTokenStream(self._adaptor, "token COLON") stream_RPAREN = RewriteRuleTokenStream(self._adaptor, "token RPAREN") stream_LPAREN = RewriteRuleTokenStream(self._adaptor, "token LPAREN") stream_media_stmt = RewriteRuleSubtreeStream(self._adaptor, "rule media_stmt") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # lesscss.g:140:2: ( LPAREN media_stmt ( COLON expr )? RPAREN -> ^( N_MediaExpr media_stmt ( expr )? ) ) # lesscss.g:140:4: LPAREN media_stmt ( COLON expr )? RPAREN pass LPAREN30=self.match(self.input, LPAREN, self.FOLLOW_LPAREN_in_media_expr402) if self._state.backtracking == 0: stream_LPAREN.add(LPAREN30) self._state.following.append(self.FOLLOW_media_stmt_in_media_expr404) media_stmt31 = self.media_stmt() self._state.following.pop() if self._state.backtracking == 0: stream_media_stmt.add(media_stmt31.tree) # lesscss.g:140:22: ( COLON expr )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == COLON) : alt10 = 1 if alt10 == 1: # lesscss.g:140:24: COLON expr pass COLON32=self.match(self.input, COLON, self.FOLLOW_COLON_in_media_expr408) if self._state.backtracking == 0: stream_COLON.add(COLON32) self._state.following.append(self.FOLLOW_expr_in_media_expr410) expr33 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr33.tree) RPAREN34=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_media_expr415) if self._state.backtracking == 0: stream_RPAREN.add(RPAREN34) # AST Rewrite # elements: expr, media_stmt # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 141:3: -> ^( N_MediaExpr media_stmt ( expr )? ) # lesscss.g:141:6: ^( N_MediaExpr media_stmt ( expr )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_MediaExpr, "N_MediaExpr"), root_1) self._adaptor.addChild(root_1, stream_media_stmt.nextTree()) # lesscss.g:141:31: ( expr )? if stream_expr.hasNext(): self._adaptor.addChild(root_1, stream_expr.nextTree()) stream_expr.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "media_expr" class fontface_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.fontface_return, self).__init__() self.tree = None # $ANTLR start "fontface" # lesscss.g:148:1: fontface : FONTFACE_SYM LBRACE declarationset RBRACE ; def fontface(self, ): retval = self.fontface_return() retval.start = self.input.LT(1) root_0 = None FONTFACE_SYM35 = None LBRACE36 = None RBRACE38 = None declarationset37 = None FONTFACE_SYM35_tree = None LBRACE36_tree = None RBRACE38_tree = None try: try: # lesscss.g:149:2: ( FONTFACE_SYM LBRACE declarationset RBRACE ) # lesscss.g:149:4: FONTFACE_SYM LBRACE declarationset RBRACE pass root_0 = self._adaptor.nil() FONTFACE_SYM35=self.match(self.input, FONTFACE_SYM, self.FOLLOW_FONTFACE_SYM_in_fontface444) if self._state.backtracking == 0: FONTFACE_SYM35_tree = self._adaptor.createWithPayload(FONTFACE_SYM35) root_0 = self._adaptor.becomeRoot(FONTFACE_SYM35_tree, root_0) LBRACE36=self.match(self.input, LBRACE, self.FOLLOW_LBRACE_in_fontface447) self._state.following.append(self.FOLLOW_declarationset_in_fontface450) declarationset37 = self.declarationset() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, declarationset37.tree) RBRACE38=self.match(self.input, RBRACE, self.FOLLOW_RBRACE_in_fontface452) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "fontface" class page_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.page_return, self).__init__() self.tree = None # $ANTLR start "page" # lesscss.g:155:1: page : PAGE_SYM ( pseudoPage )? LBRACE declarationset RBRACE ; def page(self, ): retval = self.page_return() retval.start = self.input.LT(1) root_0 = None PAGE_SYM39 = None LBRACE41 = None RBRACE43 = None pseudoPage40 = None declarationset42 = None PAGE_SYM39_tree = None LBRACE41_tree = None RBRACE43_tree = None try: try: # lesscss.g:156:2: ( PAGE_SYM ( pseudoPage )? LBRACE declarationset RBRACE ) # lesscss.g:156:4: PAGE_SYM ( pseudoPage )? LBRACE declarationset RBRACE pass root_0 = self._adaptor.nil() PAGE_SYM39=self.match(self.input, PAGE_SYM, self.FOLLOW_PAGE_SYM_in_page467) if self._state.backtracking == 0: PAGE_SYM39_tree = self._adaptor.createWithPayload(PAGE_SYM39) root_0 = self._adaptor.becomeRoot(PAGE_SYM39_tree, root_0) # lesscss.g:156:14: ( pseudoPage )? alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == COLON) : alt11 = 1 if alt11 == 1: # lesscss.g:156:14: pseudoPage pass self._state.following.append(self.FOLLOW_pseudoPage_in_page470) pseudoPage40 = self.pseudoPage() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, pseudoPage40.tree) LBRACE41=self.match(self.input, LBRACE, self.FOLLOW_LBRACE_in_page473) self._state.following.append(self.FOLLOW_declarationset_in_page476) declarationset42 = self.declarationset() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, declarationset42.tree) RBRACE43=self.match(self.input, RBRACE, self.FOLLOW_RBRACE_in_page478) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "page" class pseudoPage_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.pseudoPage_return, self).__init__() self.tree = None # $ANTLR start "pseudoPage" # lesscss.g:159:1: pseudoPage : COLON a= IDENT -> IDENT ; def pseudoPage(self, ): retval = self.pseudoPage_return() retval.start = self.input.LT(1) root_0 = None a = None COLON44 = None a_tree = None COLON44_tree = None stream_COLON = RewriteRuleTokenStream(self._adaptor, "token COLON") stream_IDENT = RewriteRuleTokenStream(self._adaptor, "token IDENT") try: try: # lesscss.g:160:2: ( COLON a= IDENT -> IDENT ) # lesscss.g:160:4: COLON a= IDENT pass COLON44=self.match(self.input, COLON, self.FOLLOW_COLON_in_pseudoPage490) if self._state.backtracking == 0: stream_COLON.add(COLON44) a=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_pseudoPage494) if self._state.backtracking == 0: stream_IDENT.add(a) if self._state.backtracking == 0: a.setText(':' + a.getText()); # AST Rewrite # elements: IDENT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 162:3: -> IDENT self._adaptor.addChild(root_0, stream_IDENT.nextNode()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "pseudoPage" class keyframes_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.keyframes_return, self).__init__() self.tree = None # $ANTLR start "keyframes" # lesscss.g:169:1: keyframes : KEYFRAMES_SYM IDENT LBRACE ( keyframes_block )* RBRACE ; def keyframes(self, ): retval = self.keyframes_return() retval.start = self.input.LT(1) root_0 = None KEYFRAMES_SYM45 = None IDENT46 = None LBRACE47 = None RBRACE49 = None keyframes_block48 = None KEYFRAMES_SYM45_tree = None IDENT46_tree = None LBRACE47_tree = None RBRACE49_tree = None try: try: # lesscss.g:170:2: ( KEYFRAMES_SYM IDENT LBRACE ( keyframes_block )* RBRACE ) # lesscss.g:170:4: KEYFRAMES_SYM IDENT LBRACE ( keyframes_block )* RBRACE pass root_0 = self._adaptor.nil() KEYFRAMES_SYM45=self.match(self.input, KEYFRAMES_SYM, self.FOLLOW_KEYFRAMES_SYM_in_keyframes520) if self._state.backtracking == 0: KEYFRAMES_SYM45_tree = self._adaptor.createWithPayload(KEYFRAMES_SYM45) root_0 = self._adaptor.becomeRoot(KEYFRAMES_SYM45_tree, root_0) IDENT46=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_keyframes523) if self._state.backtracking == 0: IDENT46_tree = self._adaptor.createWithPayload(IDENT46) self._adaptor.addChild(root_0, IDENT46_tree) LBRACE47=self.match(self.input, LBRACE, self.FOLLOW_LBRACE_in_keyframes525) # lesscss.g:170:33: ( keyframes_block )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == IDENT or LA12_0 == PERCENTAGE) : alt12 = 1 if alt12 == 1: # lesscss.g:170:33: keyframes_block pass self._state.following.append(self.FOLLOW_keyframes_block_in_keyframes528) keyframes_block48 = self.keyframes_block() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, keyframes_block48.tree) else: break #loop12 RBRACE49=self.match(self.input, RBRACE, self.FOLLOW_RBRACE_in_keyframes531) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "keyframes" class keyframes_block_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.keyframes_block_return, self).__init__() self.tree = None # $ANTLR start "keyframes_block" # lesscss.g:173:1: keyframes_block : keyframe_selector ( COMMA keyframe_selector )* LBRACE declarationset RBRACE -> ^( N_KeyframeBlock ( ^( M_KeyframeSelector keyframe_selector ) )+ declarationset ) ; def keyframes_block(self, ): retval = self.keyframes_block_return() retval.start = self.input.LT(1) root_0 = None COMMA51 = None LBRACE53 = None RBRACE55 = None keyframe_selector50 = None keyframe_selector52 = None declarationset54 = None COMMA51_tree = None LBRACE53_tree = None RBRACE55_tree = None stream_RBRACE = RewriteRuleTokenStream(self._adaptor, "token RBRACE") stream_COMMA = RewriteRuleTokenStream(self._adaptor, "token COMMA") stream_LBRACE = RewriteRuleTokenStream(self._adaptor, "token LBRACE") stream_declarationset = RewriteRuleSubtreeStream(self._adaptor, "rule declarationset") stream_keyframe_selector = RewriteRuleSubtreeStream(self._adaptor, "rule keyframe_selector") try: try: # lesscss.g:174:2: ( keyframe_selector ( COMMA keyframe_selector )* LBRACE declarationset RBRACE -> ^( N_KeyframeBlock ( ^( M_KeyframeSelector keyframe_selector ) )+ declarationset ) ) # lesscss.g:174:4: keyframe_selector ( COMMA keyframe_selector )* LBRACE declarationset RBRACE pass self._state.following.append(self.FOLLOW_keyframe_selector_in_keyframes_block543) keyframe_selector50 = self.keyframe_selector() self._state.following.pop() if self._state.backtracking == 0: stream_keyframe_selector.add(keyframe_selector50.tree) # lesscss.g:174:22: ( COMMA keyframe_selector )* while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == COMMA) : alt13 = 1 if alt13 == 1: # lesscss.g:174:24: COMMA keyframe_selector pass COMMA51=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_keyframes_block547) if self._state.backtracking == 0: stream_COMMA.add(COMMA51) self._state.following.append(self.FOLLOW_keyframe_selector_in_keyframes_block549) keyframe_selector52 = self.keyframe_selector() self._state.following.pop() if self._state.backtracking == 0: stream_keyframe_selector.add(keyframe_selector52.tree) else: break #loop13 LBRACE53=self.match(self.input, LBRACE, self.FOLLOW_LBRACE_in_keyframes_block554) if self._state.backtracking == 0: stream_LBRACE.add(LBRACE53) self._state.following.append(self.FOLLOW_declarationset_in_keyframes_block556) declarationset54 = self.declarationset() self._state.following.pop() if self._state.backtracking == 0: stream_declarationset.add(declarationset54.tree) RBRACE55=self.match(self.input, RBRACE, self.FOLLOW_RBRACE_in_keyframes_block558) if self._state.backtracking == 0: stream_RBRACE.add(RBRACE55) # AST Rewrite # elements: keyframe_selector, declarationset # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 175:3: -> ^( N_KeyframeBlock ( ^( M_KeyframeSelector keyframe_selector ) )+ declarationset ) # lesscss.g:175:6: ^( N_KeyframeBlock ( ^( M_KeyframeSelector keyframe_selector ) )+ declarationset ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_KeyframeBlock, "N_KeyframeBlock"), root_1) # lesscss.g:175:24: ( ^( M_KeyframeSelector keyframe_selector ) )+ if not (stream_keyframe_selector.hasNext()): raise RewriteEarlyExitException() while stream_keyframe_selector.hasNext(): # lesscss.g:175:24: ^( M_KeyframeSelector keyframe_selector ) root_2 = self._adaptor.nil() root_2 = self._adaptor.becomeRoot(self._adaptor.createFromType(M_KeyframeSelector, "M_KeyframeSelector"), root_2) self._adaptor.addChild(root_2, stream_keyframe_selector.nextTree()) self._adaptor.addChild(root_1, root_2) stream_keyframe_selector.reset() self._adaptor.addChild(root_1, stream_declarationset.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "keyframes_block" class keyframe_selector_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.keyframe_selector_return, self).__init__() self.tree = None # $ANTLR start "keyframe_selector" # lesscss.g:179:1: keyframe_selector : ( IDENT | PERCENTAGE ) ; def keyframe_selector(self, ): retval = self.keyframe_selector_return() retval.start = self.input.LT(1) root_0 = None set56 = None set56_tree = None try: try: # lesscss.g:180:2: ( ( IDENT | PERCENTAGE ) ) # lesscss.g:180:4: ( IDENT | PERCENTAGE ) pass root_0 = self._adaptor.nil() set56 = self.input.LT(1) if self.input.LA(1) == IDENT or self.input.LA(1) == PERCENTAGE: self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set56)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "keyframe_selector" class less_variable_def_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.less_variable_def_return, self).__init__() self.tree = None # $ANTLR start "less_variable_def" # lesscss.g:187:1: less_variable_def : LESS_VARNAME COLON term SEMI -> ^( N_Less_VarDef LESS_VARNAME term ) ; def less_variable_def(self, ): retval = self.less_variable_def_return() retval.start = self.input.LT(1) root_0 = None LESS_VARNAME57 = None COLON58 = None SEMI60 = None term59 = None LESS_VARNAME57_tree = None COLON58_tree = None SEMI60_tree = None stream_COLON = RewriteRuleTokenStream(self._adaptor, "token COLON") stream_LESS_VARNAME = RewriteRuleTokenStream(self._adaptor, "token LESS_VARNAME") stream_SEMI = RewriteRuleTokenStream(self._adaptor, "token SEMI") stream_term = RewriteRuleSubtreeStream(self._adaptor, "rule term") try: try: # lesscss.g:188:2: ( LESS_VARNAME COLON term SEMI -> ^( N_Less_VarDef LESS_VARNAME term ) ) # lesscss.g:188:4: LESS_VARNAME COLON term SEMI pass LESS_VARNAME57=self.match(self.input, LESS_VARNAME, self.FOLLOW_LESS_VARNAME_in_less_variable_def611) if self._state.backtracking == 0: stream_LESS_VARNAME.add(LESS_VARNAME57) COLON58=self.match(self.input, COLON, self.FOLLOW_COLON_in_less_variable_def613) if self._state.backtracking == 0: stream_COLON.add(COLON58) self._state.following.append(self.FOLLOW_term_in_less_variable_def615) term59 = self.term() self._state.following.pop() if self._state.backtracking == 0: stream_term.add(term59.tree) SEMI60=self.match(self.input, SEMI, self.FOLLOW_SEMI_in_less_variable_def617) if self._state.backtracking == 0: stream_SEMI.add(SEMI60) # AST Rewrite # elements: term, LESS_VARNAME # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 189:3: -> ^( N_Less_VarDef LESS_VARNAME term ) # lesscss.g:189:6: ^( N_Less_VarDef LESS_VARNAME term ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Less_VarDef, "N_Less_VarDef"), root_1) self._adaptor.addChild(root_1, stream_LESS_VARNAME.nextNode()) self._adaptor.addChild(root_1, stream_term.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "less_variable_def" class ruleSet_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.ruleSet_return, self).__init__() self.tree = None # $ANTLR start "ruleSet" # lesscss.g:198:1: ruleSet : selector ( COMMA selector )* LBRACE declarationset RBRACE -> ^( N_RuleSet ( ^( N_Selector selector ) )+ declarationset ) ; def ruleSet(self, ): retval = self.ruleSet_return() retval.start = self.input.LT(1) root_0 = None COMMA62 = None LBRACE64 = None RBRACE66 = None selector61 = None selector63 = None declarationset65 = None COMMA62_tree = None LBRACE64_tree = None RBRACE66_tree = None stream_RBRACE = RewriteRuleTokenStream(self._adaptor, "token RBRACE") stream_COMMA = RewriteRuleTokenStream(self._adaptor, "token COMMA") stream_LBRACE = RewriteRuleTokenStream(self._adaptor, "token LBRACE") stream_selector = RewriteRuleSubtreeStream(self._adaptor, "rule selector") stream_declarationset = RewriteRuleSubtreeStream(self._adaptor, "rule declarationset") try: try: # lesscss.g:199:2: ( selector ( COMMA selector )* LBRACE declarationset RBRACE -> ^( N_RuleSet ( ^( N_Selector selector ) )+ declarationset ) ) # lesscss.g:199:4: selector ( COMMA selector )* LBRACE declarationset RBRACE pass self._state.following.append(self.FOLLOW_selector_in_ruleSet646) selector61 = self.selector() self._state.following.pop() if self._state.backtracking == 0: stream_selector.add(selector61.tree) # lesscss.g:199:13: ( COMMA selector )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == COMMA) : alt14 = 1 if alt14 == 1: # lesscss.g:199:14: COMMA selector pass COMMA62=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_ruleSet649) if self._state.backtracking == 0: stream_COMMA.add(COMMA62) self._state.following.append(self.FOLLOW_selector_in_ruleSet651) selector63 = self.selector() self._state.following.pop() if self._state.backtracking == 0: stream_selector.add(selector63.tree) else: break #loop14 LBRACE64=self.match(self.input, LBRACE, self.FOLLOW_LBRACE_in_ruleSet655) if self._state.backtracking == 0: stream_LBRACE.add(LBRACE64) self._state.following.append(self.FOLLOW_declarationset_in_ruleSet657) declarationset65 = self.declarationset() self._state.following.pop() if self._state.backtracking == 0: stream_declarationset.add(declarationset65.tree) RBRACE66=self.match(self.input, RBRACE, self.FOLLOW_RBRACE_in_ruleSet659) if self._state.backtracking == 0: stream_RBRACE.add(RBRACE66) # AST Rewrite # elements: declarationset, selector # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 200:3: -> ^( N_RuleSet ( ^( N_Selector selector ) )+ declarationset ) # lesscss.g:200:6: ^( N_RuleSet ( ^( N_Selector selector ) )+ declarationset ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_RuleSet, "N_RuleSet"), root_1) # lesscss.g:200:18: ( ^( N_Selector selector ) )+ if not (stream_selector.hasNext()): raise RewriteEarlyExitException() while stream_selector.hasNext(): # lesscss.g:200:18: ^( N_Selector selector ) root_2 = self._adaptor.nil() root_2 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Selector, "N_Selector"), root_2) self._adaptor.addChild(root_2, stream_selector.nextTree()) self._adaptor.addChild(root_1, root_2) stream_selector.reset() self._adaptor.addChild(root_1, stream_declarationset.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "ruleSet" class selector_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.selector_return, self).__init__() self.tree = None # $ANTLR start "selector" # lesscss.g:203:1: selector : simpleSelector ( combinator simpleSelector )* ; def selector(self, ): retval = self.selector_return() retval.start = self.input.LT(1) root_0 = None simpleSelector67 = None combinator68 = None simpleSelector69 = None try: try: # lesscss.g:204:2: ( simpleSelector ( combinator simpleSelector )* ) # lesscss.g:204:4: simpleSelector ( combinator simpleSelector )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_simpleSelector_in_selector687) simpleSelector67 = self.simpleSelector() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, simpleSelector67.tree) # lesscss.g:204:19: ( combinator simpleSelector )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == IDENT or LA15_0 == COLON or (PLUS <= LA15_0 <= STAR)) : alt15 = 1 if alt15 == 1: # lesscss.g:204:20: combinator simpleSelector pass self._state.following.append(self.FOLLOW_combinator_in_selector690) combinator68 = self.combinator() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, combinator68.tree) self._state.following.append(self.FOLLOW_simpleSelector_in_selector692) simpleSelector69 = self.simpleSelector() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, simpleSelector69.tree) else: break #loop15 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "selector" class combinator_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.combinator_return, self).__init__() self.tree = None # $ANTLR start "combinator" # lesscss.g:207:1: combinator : ( PLUS | GREATER | ); def combinator(self, ): retval = self.combinator_return() retval.start = self.input.LT(1) root_0 = None PLUS70 = None GREATER71 = None PLUS70_tree = None GREATER71_tree = None try: try: # lesscss.g:208:2: ( PLUS | GREATER | ) alt16 = 3 LA16 = self.input.LA(1) if LA16 == PLUS: alt16 = 1 elif LA16 == GREATER: alt16 = 2 elif LA16 == IDENT or LA16 == COLON or LA16 == HASH or LA16 == DOT or LA16 == LBRACKET or LA16 == STAR: alt16 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 16, 0, self.input) raise nvae if alt16 == 1: # lesscss.g:208:4: PLUS pass root_0 = self._adaptor.nil() PLUS70=self.match(self.input, PLUS, self.FOLLOW_PLUS_in_combinator705) if self._state.backtracking == 0: PLUS70_tree = self._adaptor.createWithPayload(PLUS70) self._adaptor.addChild(root_0, PLUS70_tree) elif alt16 == 2: # lesscss.g:209:4: GREATER pass root_0 = self._adaptor.nil() GREATER71=self.match(self.input, GREATER, self.FOLLOW_GREATER_in_combinator710) if self._state.backtracking == 0: GREATER71_tree = self._adaptor.createWithPayload(GREATER71) self._adaptor.addChild(root_0, GREATER71_tree) elif alt16 == 3: # lesscss.g:211:2: pass root_0 = self._adaptor.nil() retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "combinator" class simpleSelector_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.simpleSelector_return, self).__init__() self.tree = None # $ANTLR start "simpleSelector" # lesscss.g:213:1: simpleSelector : ( elementName ( ( esPred )=> elementSubsequent )* | ( ( esPred )=> elementSubsequent )+ ); def simpleSelector(self, ): retval = self.simpleSelector_return() retval.start = self.input.LT(1) root_0 = None elementName72 = None elementSubsequent73 = None elementSubsequent74 = None try: try: # lesscss.g:214:2: ( elementName ( ( esPred )=> elementSubsequent )* | ( ( esPred )=> elementSubsequent )+ ) alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == IDENT or LA19_0 == STAR) : alt19 = 1 elif (LA19_0 == COLON or (HASH <= LA19_0 <= LBRACKET)) : alt19 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 19, 0, self.input) raise nvae if alt19 == 1: # lesscss.g:214:4: elementName ( ( esPred )=> elementSubsequent )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_elementName_in_simpleSelector724) elementName72 = self.elementName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, elementName72.tree) # lesscss.g:214:16: ( ( esPred )=> elementSubsequent )* while True: #loop17 alt17 = 2 alt17 = self.dfa17.predict(self.input) if alt17 == 1: # lesscss.g:214:17: ( esPred )=> elementSubsequent pass self._state.following.append(self.FOLLOW_elementSubsequent_in_simpleSelector731) elementSubsequent73 = self.elementSubsequent() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, elementSubsequent73.tree) else: break #loop17 elif alt19 == 2: # lesscss.g:215:4: ( ( esPred )=> elementSubsequent )+ pass root_0 = self._adaptor.nil() # lesscss.g:215:4: ( ( esPred )=> elementSubsequent )+ cnt18 = 0 while True: #loop18 alt18 = 2 LA18 = self.input.LA(1) if LA18 == HASH: LA18_2 = self.input.LA(2) if (self.synpred2_lesscss()) : alt18 = 1 elif LA18 == DOT: LA18_3 = self.input.LA(2) if (self.synpred2_lesscss()) : alt18 = 1 elif LA18 == COLON: LA18_4 = self.input.LA(2) if (self.synpred2_lesscss()) : alt18 = 1 elif LA18 == LBRACKET: LA18_5 = self.input.LA(2) if (self.synpred2_lesscss()) : alt18 = 1 if alt18 == 1: # lesscss.g:215:5: ( esPred )=> elementSubsequent pass self._state.following.append(self.FOLLOW_elementSubsequent_in_simpleSelector743) elementSubsequent74 = self.elementSubsequent() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, elementSubsequent74.tree) else: if cnt18 >= 1: break #loop18 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(18, self.input) raise eee cnt18 += 1 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "simpleSelector" class esPred_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.esPred_return, self).__init__() self.tree = None # $ANTLR start "esPred" # lesscss.g:218:1: esPred : ( HASH | DOT | COLON | LBRACKET ); def esPred(self, ): retval = self.esPred_return() retval.start = self.input.LT(1) root_0 = None set75 = None set75_tree = None try: try: # lesscss.g:219:2: ( HASH | DOT | COLON | LBRACKET ) # lesscss.g: pass root_0 = self._adaptor.nil() set75 = self.input.LT(1) if self.input.LA(1) == COLON or (HASH <= self.input.LA(1) <= LBRACKET): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set75)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "esPred" class elementName_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.elementName_return, self).__init__() self.tree = None # $ANTLR start "elementName" # lesscss.g:225:1: elementName : ( IDENT | STAR ); def elementName(self, ): retval = self.elementName_return() retval.start = self.input.LT(1) root_0 = None set76 = None set76_tree = None try: try: # lesscss.g:226:2: ( IDENT | STAR ) # lesscss.g: pass root_0 = self._adaptor.nil() set76 = self.input.LT(1) if self.input.LA(1) == IDENT or self.input.LA(1) == STAR: self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set76)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "elementName" class elementSubsequent_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.elementSubsequent_return, self).__init__() self.tree = None # $ANTLR start "elementSubsequent" # lesscss.g:230:1: elementSubsequent : ( HASH | cssClass | pseudo | attrib ); def elementSubsequent(self, ): retval = self.elementSubsequent_return() retval.start = self.input.LT(1) root_0 = None HASH77 = None cssClass78 = None pseudo79 = None attrib80 = None HASH77_tree = None try: try: # lesscss.g:231:2: ( HASH | cssClass | pseudo | attrib ) alt20 = 4 LA20 = self.input.LA(1) if LA20 == HASH: alt20 = 1 elif LA20 == DOT: alt20 = 2 elif LA20 == COLON: alt20 = 3 elif LA20 == LBRACKET: alt20 = 4 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 20, 0, self.input) raise nvae if alt20 == 1: # lesscss.g:231:4: HASH pass root_0 = self._adaptor.nil() HASH77=self.match(self.input, HASH, self.FOLLOW_HASH_in_elementSubsequent805) if self._state.backtracking == 0: HASH77_tree = self._adaptor.createWithPayload(HASH77) self._adaptor.addChild(root_0, HASH77_tree) elif alt20 == 2: # lesscss.g:232:4: cssClass pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_cssClass_in_elementSubsequent810) cssClass78 = self.cssClass() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, cssClass78.tree) elif alt20 == 3: # lesscss.g:233:4: pseudo pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_pseudo_in_elementSubsequent815) pseudo79 = self.pseudo() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, pseudo79.tree) elif alt20 == 4: # lesscss.g:234:4: attrib pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_attrib_in_elementSubsequent820) attrib80 = self.attrib() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, attrib80.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "elementSubsequent" class cssClass_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.cssClass_return, self).__init__() self.tree = None # $ANTLR start "cssClass" # lesscss.g:237:1: cssClass : DOT a= IDENT -> IDENT ; def cssClass(self, ): retval = self.cssClass_return() retval.start = self.input.LT(1) root_0 = None a = None DOT81 = None a_tree = None DOT81_tree = None stream_IDENT = RewriteRuleTokenStream(self._adaptor, "token IDENT") stream_DOT = RewriteRuleTokenStream(self._adaptor, "token DOT") try: try: # lesscss.g:238:2: ( DOT a= IDENT -> IDENT ) # lesscss.g:238:4: DOT a= IDENT pass DOT81=self.match(self.input, DOT, self.FOLLOW_DOT_in_cssClass832) if self._state.backtracking == 0: stream_DOT.add(DOT81) a=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_cssClass836) if self._state.backtracking == 0: stream_IDENT.add(a) if self._state.backtracking == 0: a.setText('.' + a.getText()); # AST Rewrite # elements: IDENT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 240:3: -> IDENT self._adaptor.addChild(root_0, stream_IDENT.nextNode()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "cssClass" class pseudo_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.pseudo_return, self).__init__() self.tree = None # $ANTLR start "pseudo" # lesscss.g:243:1: pseudo : a= COLON (b= COLON )? ( IDENT -> ^( N_Pseudo $a ( $b)? IDENT ) | pseudoFunction -> ^( N_Pseudo $a ( $b)? pseudoFunction ) ) ; def pseudo(self, ): retval = self.pseudo_return() retval.start = self.input.LT(1) root_0 = None a = None b = None IDENT82 = None pseudoFunction83 = None a_tree = None b_tree = None IDENT82_tree = None stream_COLON = RewriteRuleTokenStream(self._adaptor, "token COLON") stream_IDENT = RewriteRuleTokenStream(self._adaptor, "token IDENT") stream_pseudoFunction = RewriteRuleSubtreeStream(self._adaptor, "rule pseudoFunction") try: try: # lesscss.g:244:2: (a= COLON (b= COLON )? ( IDENT -> ^( N_Pseudo $a ( $b)? IDENT ) | pseudoFunction -> ^( N_Pseudo $a ( $b)? pseudoFunction ) ) ) # lesscss.g:244:4: a= COLON (b= COLON )? ( IDENT -> ^( N_Pseudo $a ( $b)? IDENT ) | pseudoFunction -> ^( N_Pseudo $a ( $b)? pseudoFunction ) ) pass a=self.match(self.input, COLON, self.FOLLOW_COLON_in_pseudo860) if self._state.backtracking == 0: stream_COLON.add(a) # lesscss.g:244:13: (b= COLON )? alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == COLON) : alt21 = 1 if alt21 == 1: # lesscss.g:244:13: b= COLON pass b=self.match(self.input, COLON, self.FOLLOW_COLON_in_pseudo864) if self._state.backtracking == 0: stream_COLON.add(b) # lesscss.g:245:2: ( IDENT -> ^( N_Pseudo $a ( $b)? IDENT ) | pseudoFunction -> ^( N_Pseudo $a ( $b)? pseudoFunction ) ) alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == IDENT) : alt22 = 1 elif (LA22_0 == FUNCTION) : alt22 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 22, 0, self.input) raise nvae if alt22 == 1: # lesscss.g:245:4: IDENT pass IDENT82=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_pseudo870) if self._state.backtracking == 0: stream_IDENT.add(IDENT82) # AST Rewrite # elements: a, IDENT, b # token labels: b, a # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 stream_b = RewriteRuleTokenStream(self._adaptor, "token b", b) stream_a = RewriteRuleTokenStream(self._adaptor, "token a", a) if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 246:3: -> ^( N_Pseudo $a ( $b)? IDENT ) # lesscss.g:246:6: ^( N_Pseudo $a ( $b)? IDENT ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Pseudo, "N_Pseudo"), root_1) self._adaptor.addChild(root_1, stream_a.nextNode()) # lesscss.g:246:20: ( $b)? if stream_b.hasNext(): self._adaptor.addChild(root_1, stream_b.nextNode()) stream_b.reset(); self._adaptor.addChild(root_1, stream_IDENT.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt22 == 2: # lesscss.g:247:4: pseudoFunction pass self._state.following.append(self.FOLLOW_pseudoFunction_in_pseudo892) pseudoFunction83 = self.pseudoFunction() self._state.following.pop() if self._state.backtracking == 0: stream_pseudoFunction.add(pseudoFunction83.tree) # AST Rewrite # elements: pseudoFunction, a, b # token labels: b, a # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 stream_b = RewriteRuleTokenStream(self._adaptor, "token b", b) stream_a = RewriteRuleTokenStream(self._adaptor, "token a", a) if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 248:3: -> ^( N_Pseudo $a ( $b)? pseudoFunction ) # lesscss.g:248:6: ^( N_Pseudo $a ( $b)? pseudoFunction ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Pseudo, "N_Pseudo"), root_1) self._adaptor.addChild(root_1, stream_a.nextNode()) # lesscss.g:248:20: ( $b)? if stream_b.hasNext(): self._adaptor.addChild(root_1, stream_b.nextNode()) stream_b.reset(); self._adaptor.addChild(root_1, stream_pseudoFunction.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "pseudo" class pseudoFunction_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.pseudoFunction_return, self).__init__() self.tree = None # $ANTLR start "pseudoFunction" # lesscss.g:252:1: pseudoFunction : ( FUNCTION expr RPAREN -> ^( N_PseudoFunction FUNCTION expr ) | FUNCTION LBRACKET attribBody RBRACKET RPAREN -> ^( N_PseudoFunction FUNCTION LBRACKET attribBody RBRACKET ) | FUNCTION pseudo RPAREN -> ^( N_PseudoFunction FUNCTION pseudo ) ); def pseudoFunction(self, ): retval = self.pseudoFunction_return() retval.start = self.input.LT(1) root_0 = None FUNCTION84 = None RPAREN86 = None FUNCTION87 = None LBRACKET88 = None RBRACKET90 = None RPAREN91 = None FUNCTION92 = None RPAREN94 = None expr85 = None attribBody89 = None pseudo93 = None FUNCTION84_tree = None RPAREN86_tree = None FUNCTION87_tree = None LBRACKET88_tree = None RBRACKET90_tree = None RPAREN91_tree = None FUNCTION92_tree = None RPAREN94_tree = None stream_LBRACKET = RewriteRuleTokenStream(self._adaptor, "token LBRACKET") stream_FUNCTION = RewriteRuleTokenStream(self._adaptor, "token FUNCTION") stream_RPAREN = RewriteRuleTokenStream(self._adaptor, "token RPAREN") stream_RBRACKET = RewriteRuleTokenStream(self._adaptor, "token RBRACKET") stream_attribBody = RewriteRuleSubtreeStream(self._adaptor, "rule attribBody") stream_pseudo = RewriteRuleSubtreeStream(self._adaptor, "rule pseudo") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # lesscss.g:253:2: ( FUNCTION expr RPAREN -> ^( N_PseudoFunction FUNCTION expr ) | FUNCTION LBRACKET attribBody RBRACKET RPAREN -> ^( N_PseudoFunction FUNCTION LBRACKET attribBody RBRACKET ) | FUNCTION pseudo RPAREN -> ^( N_PseudoFunction FUNCTION pseudo ) ) alt23 = 3 LA23_0 = self.input.LA(1) if (LA23_0 == FUNCTION) : LA23 = self.input.LA(2) if LA23 == LBRACKET: alt23 = 2 elif LA23 == COLON: alt23 = 3 elif LA23 == STRING or LA23 == URI or LA23 == IDENT or LA23 == PERCENTAGE or LA23 == LESS_VARNAME or LA23 == PLUS or LA23 == HASH or LA23 == FUNCTION or LA23 == NUMBER or LA23 == LENGTH or LA23 == EMS or LA23 == EXS or LA23 == REMS or LA23 == CHS or LA23 == ANGLE or LA23 == TIME or LA23 == FREQ or LA23 == RESOLUTION or LA23 == VPORTLEN or LA23 == NTH or LA23 == UNICODE_RANGE or LA23 == MINUS: alt23 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 23, 1, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 23, 0, self.input) raise nvae if alt23 == 1: # lesscss.g:253:4: FUNCTION expr RPAREN pass FUNCTION84=self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_pseudoFunction923) if self._state.backtracking == 0: stream_FUNCTION.add(FUNCTION84) self._state.following.append(self.FOLLOW_expr_in_pseudoFunction925) expr85 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr85.tree) RPAREN86=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_pseudoFunction927) if self._state.backtracking == 0: stream_RPAREN.add(RPAREN86) # AST Rewrite # elements: FUNCTION, expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 254:3: -> ^( N_PseudoFunction FUNCTION expr ) # lesscss.g:254:6: ^( N_PseudoFunction FUNCTION expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_PseudoFunction, "N_PseudoFunction"), root_1) self._adaptor.addChild(root_1, stream_FUNCTION.nextNode()) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt23 == 2: # lesscss.g:256:4: FUNCTION LBRACKET attribBody RBRACKET RPAREN pass FUNCTION87=self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_pseudoFunction946) if self._state.backtracking == 0: stream_FUNCTION.add(FUNCTION87) LBRACKET88=self.match(self.input, LBRACKET, self.FOLLOW_LBRACKET_in_pseudoFunction948) if self._state.backtracking == 0: stream_LBRACKET.add(LBRACKET88) self._state.following.append(self.FOLLOW_attribBody_in_pseudoFunction950) attribBody89 = self.attribBody() self._state.following.pop() if self._state.backtracking == 0: stream_attribBody.add(attribBody89.tree) RBRACKET90=self.match(self.input, RBRACKET, self.FOLLOW_RBRACKET_in_pseudoFunction952) if self._state.backtracking == 0: stream_RBRACKET.add(RBRACKET90) RPAREN91=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_pseudoFunction954) if self._state.backtracking == 0: stream_RPAREN.add(RPAREN91) # AST Rewrite # elements: LBRACKET, RBRACKET, attribBody, FUNCTION # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 257:3: -> ^( N_PseudoFunction FUNCTION LBRACKET attribBody RBRACKET ) # lesscss.g:257:6: ^( N_PseudoFunction FUNCTION LBRACKET attribBody RBRACKET ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_PseudoFunction, "N_PseudoFunction"), root_1) self._adaptor.addChild(root_1, stream_FUNCTION.nextNode()) self._adaptor.addChild(root_1, stream_LBRACKET.nextNode()) self._adaptor.addChild(root_1, stream_attribBody.nextTree()) self._adaptor.addChild(root_1, stream_RBRACKET.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt23 == 3: # lesscss.g:259:4: FUNCTION pseudo RPAREN pass FUNCTION92=self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_pseudoFunction977) if self._state.backtracking == 0: stream_FUNCTION.add(FUNCTION92) self._state.following.append(self.FOLLOW_pseudo_in_pseudoFunction979) pseudo93 = self.pseudo() self._state.following.pop() if self._state.backtracking == 0: stream_pseudo.add(pseudo93.tree) RPAREN94=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_pseudoFunction981) if self._state.backtracking == 0: stream_RPAREN.add(RPAREN94) # AST Rewrite # elements: FUNCTION, pseudo # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 260:3: -> ^( N_PseudoFunction FUNCTION pseudo ) # lesscss.g:260:6: ^( N_PseudoFunction FUNCTION pseudo ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_PseudoFunction, "N_PseudoFunction"), root_1) self._adaptor.addChild(root_1, stream_FUNCTION.nextNode()) self._adaptor.addChild(root_1, stream_pseudo.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "pseudoFunction" class attrib_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.attrib_return, self).__init__() self.tree = None # $ANTLR start "attrib" # lesscss.g:264:1: attrib : LBRACKET attribBody RBRACKET -> ^( N_Attrib attribBody ) ; def attrib(self, ): retval = self.attrib_return() retval.start = self.input.LT(1) root_0 = None LBRACKET95 = None RBRACKET97 = None attribBody96 = None LBRACKET95_tree = None RBRACKET97_tree = None stream_LBRACKET = RewriteRuleTokenStream(self._adaptor, "token LBRACKET") stream_RBRACKET = RewriteRuleTokenStream(self._adaptor, "token RBRACKET") stream_attribBody = RewriteRuleSubtreeStream(self._adaptor, "rule attribBody") try: try: # lesscss.g:265:2: ( LBRACKET attribBody RBRACKET -> ^( N_Attrib attribBody ) ) # lesscss.g:265:4: LBRACKET attribBody RBRACKET pass LBRACKET95=self.match(self.input, LBRACKET, self.FOLLOW_LBRACKET_in_attrib1006) if self._state.backtracking == 0: stream_LBRACKET.add(LBRACKET95) self._state.following.append(self.FOLLOW_attribBody_in_attrib1008) attribBody96 = self.attribBody() self._state.following.pop() if self._state.backtracking == 0: stream_attribBody.add(attribBody96.tree) RBRACKET97=self.match(self.input, RBRACKET, self.FOLLOW_RBRACKET_in_attrib1010) if self._state.backtracking == 0: stream_RBRACKET.add(RBRACKET97) # AST Rewrite # elements: attribBody # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 266:3: -> ^( N_Attrib attribBody ) # lesscss.g:266:7: ^( N_Attrib attribBody ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Attrib, "N_Attrib"), root_1) self._adaptor.addChild(root_1, stream_attribBody.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "attrib" class attribBody_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.attribBody_return, self).__init__() self.tree = None # $ANTLR start "attribBody" # lesscss.g:269:1: attribBody : ( IDENT | IDENT ( OPEQ | INCLUDES | DASHMATCH | PREFIXMATCH | SUFFIXMATCH | SUBSTRINGMATCH ) term ); def attribBody(self, ): retval = self.attribBody_return() retval.start = self.input.LT(1) root_0 = None IDENT98 = None IDENT99 = None set100 = None term101 = None IDENT98_tree = None IDENT99_tree = None set100_tree = None try: try: # lesscss.g:270:2: ( IDENT | IDENT ( OPEQ | INCLUDES | DASHMATCH | PREFIXMATCH | SUFFIXMATCH | SUBSTRINGMATCH ) term ) alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == IDENT) : LA24_1 = self.input.LA(2) if ((OPEQ <= LA24_1 <= SUBSTRINGMATCH)) : alt24 = 2 elif (LA24_1 == RBRACKET) : alt24 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 24, 1, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 24, 0, self.input) raise nvae if alt24 == 1: # lesscss.g:270:4: IDENT pass root_0 = self._adaptor.nil() IDENT98=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_attribBody1033) if self._state.backtracking == 0: IDENT98_tree = self._adaptor.createWithPayload(IDENT98) self._adaptor.addChild(root_0, IDENT98_tree) elif alt24 == 2: # lesscss.g:271:4: IDENT ( OPEQ | INCLUDES | DASHMATCH | PREFIXMATCH | SUFFIXMATCH | SUBSTRINGMATCH ) term pass root_0 = self._adaptor.nil() IDENT99=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_attribBody1038) if self._state.backtracking == 0: IDENT99_tree = self._adaptor.createWithPayload(IDENT99) self._adaptor.addChild(root_0, IDENT99_tree) set100 = self.input.LT(1) set100 = self.input.LT(1) if (OPEQ <= self.input.LA(1) <= SUBSTRINGMATCH): self.input.consume() if self._state.backtracking == 0: root_0 = self._adaptor.becomeRoot(self._adaptor.createWithPayload(set100), root_0) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_term_in_attribBody1087) term101 = self.term() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, term101.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "attribBody" class declarationset_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.declarationset_return, self).__init__() self.tree = None # $ANTLR start "declarationset" # lesscss.g:286:1: declarationset : ( declaration ( SEMI declaration )* ( SEMI )? | -> N_Empty ); def declarationset(self, ): retval = self.declarationset_return() retval.start = self.input.LT(1) root_0 = None SEMI103 = None SEMI105 = None declaration102 = None declaration104 = None SEMI103_tree = None SEMI105_tree = None try: try: # lesscss.g:287:2: ( declaration ( SEMI declaration )* ( SEMI )? | -> N_Empty ) alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == IDENT or LA27_0 == STAR) : alt27 = 1 elif (LA27_0 == RBRACE) : alt27 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 27, 0, self.input) raise nvae if alt27 == 1: # lesscss.g:287:4: declaration ( SEMI declaration )* ( SEMI )? pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_declaration_in_declarationset1102) declaration102 = self.declaration() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, declaration102.tree) # lesscss.g:287:16: ( SEMI declaration )* while True: #loop25 alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == SEMI) : LA25_1 = self.input.LA(2) if (LA25_1 == IDENT or LA25_1 == STAR) : alt25 = 1 if alt25 == 1: # lesscss.g:287:17: SEMI declaration pass SEMI103=self.match(self.input, SEMI, self.FOLLOW_SEMI_in_declarationset1105) self._state.following.append(self.FOLLOW_declaration_in_declarationset1108) declaration104 = self.declaration() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, declaration104.tree) else: break #loop25 # lesscss.g:287:41: ( SEMI )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == SEMI) : alt26 = 1 if alt26 == 1: # lesscss.g:287:41: SEMI pass SEMI105=self.match(self.input, SEMI, self.FOLLOW_SEMI_in_declarationset1112) elif alt27 == 2: # lesscss.g:288:4: pass # AST Rewrite # elements: # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 288:4: -> N_Empty self._adaptor.addChild(root_0, self._adaptor.createFromType(N_Empty, "N_Empty")) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "declarationset" class declaration_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.declaration_return, self).__init__() self.tree = None # $ANTLR start "declaration" # lesscss.g:291:1: declaration : ( property COLON expr ( prio )? -> ^( N_Declaration property expr ( prio )? ) | property COLON -> ^( N_Declaration property ) ); def declaration(self, ): retval = self.declaration_return() retval.start = self.input.LT(1) root_0 = None COLON107 = None COLON111 = None property106 = None expr108 = None prio109 = None property110 = None COLON107_tree = None COLON111_tree = None stream_COLON = RewriteRuleTokenStream(self._adaptor, "token COLON") stream_property = RewriteRuleSubtreeStream(self._adaptor, "rule property") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") stream_prio = RewriteRuleSubtreeStream(self._adaptor, "rule prio") try: try: # lesscss.g:292:2: ( property COLON expr ( prio )? -> ^( N_Declaration property expr ( prio )? ) | property COLON -> ^( N_Declaration property ) ) alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == IDENT) : LA29_1 = self.input.LA(2) if (LA29_1 == COLON) : LA29_3 = self.input.LA(3) if (LA29_3 == STRING or LA29_3 == URI or LA29_3 == IDENT or (PERCENTAGE <= LA29_3 <= PLUS) or LA29_3 == HASH or LA29_3 == FUNCTION or (NUMBER <= LA29_3 <= MINUS)) : alt29 = 1 elif (LA29_3 == SEMI or LA29_3 == RBRACE) : alt29 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 29, 3, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 29, 1, self.input) raise nvae elif (LA29_0 == STAR) : LA29_2 = self.input.LA(2) if (LA29_2 == IDENT) : LA29_4 = self.input.LA(3) if (LA29_4 == COLON) : LA29_3 = self.input.LA(4) if (LA29_3 == STRING or LA29_3 == URI or LA29_3 == IDENT or (PERCENTAGE <= LA29_3 <= PLUS) or LA29_3 == HASH or LA29_3 == FUNCTION or (NUMBER <= LA29_3 <= MINUS)) : alt29 = 1 elif (LA29_3 == SEMI or LA29_3 == RBRACE) : alt29 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 29, 3, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 29, 4, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 29, 2, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 29, 0, self.input) raise nvae if alt29 == 1: # lesscss.g:292:4: property COLON expr ( prio )? pass self._state.following.append(self.FOLLOW_property_in_declaration1132) property106 = self.property() self._state.following.pop() if self._state.backtracking == 0: stream_property.add(property106.tree) COLON107=self.match(self.input, COLON, self.FOLLOW_COLON_in_declaration1134) if self._state.backtracking == 0: stream_COLON.add(COLON107) self._state.following.append(self.FOLLOW_expr_in_declaration1136) expr108 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr108.tree) # lesscss.g:292:24: ( prio )? alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == IMPORTANT_SYM) : alt28 = 1 if alt28 == 1: # lesscss.g:292:24: prio pass self._state.following.append(self.FOLLOW_prio_in_declaration1138) prio109 = self.prio() self._state.following.pop() if self._state.backtracking == 0: stream_prio.add(prio109.tree) # AST Rewrite # elements: prio, property, expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 293:3: -> ^( N_Declaration property expr ( prio )? ) # lesscss.g:293:6: ^( N_Declaration property expr ( prio )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Declaration, "N_Declaration"), root_1) self._adaptor.addChild(root_1, stream_property.nextTree()) self._adaptor.addChild(root_1, stream_expr.nextTree()) # lesscss.g:293:36: ( prio )? if stream_prio.hasNext(): self._adaptor.addChild(root_1, stream_prio.nextTree()) stream_prio.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt29 == 2: # lesscss.g:295:5: property COLON pass self._state.following.append(self.FOLLOW_property_in_declaration1161) property110 = self.property() self._state.following.pop() if self._state.backtracking == 0: stream_property.add(property110.tree) COLON111=self.match(self.input, COLON, self.FOLLOW_COLON_in_declaration1163) if self._state.backtracking == 0: stream_COLON.add(COLON111) # AST Rewrite # elements: property # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 296:3: -> ^( N_Declaration property ) # lesscss.g:296:6: ^( N_Declaration property ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Declaration, "N_Declaration"), root_1) self._adaptor.addChild(root_1, stream_property.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "declaration" class property_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.property_return, self).__init__() self.tree = None # $ANTLR start "property" # lesscss.g:300:1: property : ( IDENT | STAR a= IDENT -> IDENT ); def property(self, ): retval = self.property_return() retval.start = self.input.LT(1) root_0 = None a = None IDENT112 = None STAR113 = None a_tree = None IDENT112_tree = None STAR113_tree = None stream_IDENT = RewriteRuleTokenStream(self._adaptor, "token IDENT") stream_STAR = RewriteRuleTokenStream(self._adaptor, "token STAR") try: try: # lesscss.g:301:2: ( IDENT | STAR a= IDENT -> IDENT ) alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == IDENT) : alt30 = 1 elif (LA30_0 == STAR) : alt30 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 30, 0, self.input) raise nvae if alt30 == 1: # lesscss.g:301:4: IDENT pass root_0 = self._adaptor.nil() IDENT112=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_property1188) if self._state.backtracking == 0: IDENT112_tree = self._adaptor.createWithPayload(IDENT112) self._adaptor.addChild(root_0, IDENT112_tree) elif alt30 == 2: # lesscss.g:305:4: STAR a= IDENT pass STAR113=self.match(self.input, STAR, self.FOLLOW_STAR_in_property1198) if self._state.backtracking == 0: stream_STAR.add(STAR113) a=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_property1202) if self._state.backtracking == 0: stream_IDENT.add(a) if self._state.backtracking == 0: a.setText('*' + a.getText()); # AST Rewrite # elements: IDENT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 307:3: -> IDENT self._adaptor.addChild(root_0, stream_IDENT.nextNode()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "property" class prio_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.prio_return, self).__init__() self.tree = None # $ANTLR start "prio" # lesscss.g:311:1: prio : IMPORTANT_SYM ; def prio(self, ): retval = self.prio_return() retval.start = self.input.LT(1) root_0 = None IMPORTANT_SYM114 = None IMPORTANT_SYM114_tree = None try: try: # lesscss.g:312:2: ( IMPORTANT_SYM ) # lesscss.g:312:4: IMPORTANT_SYM pass root_0 = self._adaptor.nil() IMPORTANT_SYM114=self.match(self.input, IMPORTANT_SYM, self.FOLLOW_IMPORTANT_SYM_in_prio1225) if self._state.backtracking == 0: IMPORTANT_SYM114_tree = self._adaptor.createWithPayload(IMPORTANT_SYM114) self._adaptor.addChild(root_0, IMPORTANT_SYM114_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "prio" class expr_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.expr_return, self).__init__() self.tree = None # $ANTLR start "expr" # lesscss.g:315:1: expr : term ( operator term )* ; def expr(self, ): retval = self.expr_return() retval.start = self.input.LT(1) root_0 = None term115 = None operator116 = None term117 = None try: try: # lesscss.g:316:2: ( term ( operator term )* ) # lesscss.g:316:4: term ( operator term )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_term_in_expr1236) term115 = self.term() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, term115.tree) # lesscss.g:316:9: ( operator term )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == COMMA) : LA31_2 = self.input.LA(2) if (LA31_2 == STRING or LA31_2 == URI or (PERCENTAGE <= LA31_2 <= PLUS) or LA31_2 == HASH or LA31_2 == FUNCTION or (NUMBER <= LA31_2 <= MINUS)) : alt31 = 1 elif (LA31_2 == IDENT) : LA31_4 = self.input.LA(3) if ((STRING <= LA31_4 <= SEMI) or LA31_4 == URI or (RBRACE <= LA31_4 <= IDENT) or (COLON <= LA31_4 <= RPAREN) or (PERCENTAGE <= LA31_4 <= PLUS) or (HASH <= LA31_4 <= DOT) or LA31_4 == FUNCTION or (IMPORTANT_SYM <= LA31_4 <= MINUS)) : alt31 = 1 elif (LA31_0 == STRING or LA31_0 == URI or LA31_0 == IDENT or (PERCENTAGE <= LA31_0 <= PLUS) or LA31_0 == HASH or LA31_0 == FUNCTION or (SOLIDUS <= LA31_0 <= MINUS)) : alt31 = 1 if alt31 == 1: # lesscss.g:316:10: operator term pass self._state.following.append(self.FOLLOW_operator_in_expr1239) operator116 = self.operator() self._state.following.pop() if self._state.backtracking == 0: root_0 = self._adaptor.becomeRoot(operator116.tree, root_0) self._state.following.append(self.FOLLOW_term_in_expr1242) term117 = self.term() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, term117.tree) else: break #loop31 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "expr" class operator_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.operator_return, self).__init__() self.tree = None # $ANTLR start "operator" # lesscss.g:319:10: fragment operator : ( SOLIDUS | COMMA | -> N_Space ); def operator(self, ): retval = self.operator_return() retval.start = self.input.LT(1) root_0 = None SOLIDUS118 = None COMMA119 = None SOLIDUS118_tree = None COMMA119_tree = None try: try: # lesscss.g:320:2: ( SOLIDUS | COMMA | -> N_Space ) alt32 = 3 LA32 = self.input.LA(1) if LA32 == SOLIDUS: alt32 = 1 elif LA32 == COMMA: alt32 = 2 elif LA32 == STRING or LA32 == URI or LA32 == IDENT or LA32 == PERCENTAGE or LA32 == LESS_VARNAME or LA32 == PLUS or LA32 == HASH or LA32 == FUNCTION or LA32 == NUMBER or LA32 == LENGTH or LA32 == EMS or LA32 == EXS or LA32 == REMS or LA32 == CHS or LA32 == ANGLE or LA32 == TIME or LA32 == FREQ or LA32 == RESOLUTION or LA32 == VPORTLEN or LA32 == NTH or LA32 == UNICODE_RANGE or LA32 == MINUS: alt32 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 32, 0, self.input) raise nvae if alt32 == 1: # lesscss.g:320:4: SOLIDUS pass root_0 = self._adaptor.nil() SOLIDUS118=self.match(self.input, SOLIDUS, self.FOLLOW_SOLIDUS_in_operator1257) if self._state.backtracking == 0: SOLIDUS118_tree = self._adaptor.createWithPayload(SOLIDUS118) self._adaptor.addChild(root_0, SOLIDUS118_tree) elif alt32 == 2: # lesscss.g:321:4: COMMA pass root_0 = self._adaptor.nil() COMMA119=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_operator1262) if self._state.backtracking == 0: COMMA119_tree = self._adaptor.createWithPayload(COMMA119) self._adaptor.addChild(root_0, COMMA119_tree) elif alt32 == 3: # lesscss.g:322:4: pass # AST Rewrite # elements: # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 322:4: -> N_Space self._adaptor.addChild(root_0, self._adaptor.createFromType(N_Space, "N_Space")) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "operator" class term_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.term_return, self).__init__() self.tree = None # $ANTLR start "term" # lesscss.g:325:1: term : ( ( unaryOperator )? ( NUMBER -> ^( N_Term ( unaryOperator )? NUMBER ) | PERCENTAGE -> ^( N_Term ( unaryOperator )? PERCENTAGE ) | LENGTH -> ^( N_Term ( unaryOperator )? LENGTH ) | EMS -> ^( N_Term ( unaryOperator )? EMS ) | EXS -> ^( N_Term ( unaryOperator )? EXS ) | REMS -> ^( N_Term ( unaryOperator )? REMS ) | CHS -> ^( N_Term ( unaryOperator )? CHS ) | ANGLE -> ^( N_Term ( unaryOperator )? ANGLE ) | TIME -> ^( N_Term ( unaryOperator )? TIME ) | FREQ -> ^( N_Term ( unaryOperator )? FREQ ) | RESOLUTION -> ^( N_Term ( unaryOperator )? RESOLUTION ) | VPORTLEN -> ^( N_Term ( unaryOperator )? VPORTLEN ) | NTH -> ^( N_Term ( unaryOperator )? NTH ) | function -> ^( N_Term ( unaryOperator )? function ) ) | STRING | IDENT | URI | hexColor -> ^( N_Term hexColor ) | UNICODE_RANGE | LESS_VARNAME ); def term(self, ): retval = self.term_return() retval.start = self.input.LT(1) root_0 = None NUMBER121 = None PERCENTAGE122 = None LENGTH123 = None EMS124 = None EXS125 = None REMS126 = None CHS127 = None ANGLE128 = None TIME129 = None FREQ130 = None RESOLUTION131 = None VPORTLEN132 = None NTH133 = None STRING135 = None IDENT136 = None URI137 = None UNICODE_RANGE139 = None LESS_VARNAME140 = None unaryOperator120 = None function134 = None hexColor138 = None NUMBER121_tree = None PERCENTAGE122_tree = None LENGTH123_tree = None EMS124_tree = None EXS125_tree = None REMS126_tree = None CHS127_tree = None ANGLE128_tree = None TIME129_tree = None FREQ130_tree = None RESOLUTION131_tree = None VPORTLEN132_tree = None NTH133_tree = None STRING135_tree = None IDENT136_tree = None URI137_tree = None UNICODE_RANGE139_tree = None LESS_VARNAME140_tree = None stream_TIME = RewriteRuleTokenStream(self._adaptor, "token TIME") stream_ANGLE = RewriteRuleTokenStream(self._adaptor, "token ANGLE") stream_EMS = RewriteRuleTokenStream(self._adaptor, "token EMS") stream_REMS = RewriteRuleTokenStream(self._adaptor, "token REMS") stream_EXS = RewriteRuleTokenStream(self._adaptor, "token EXS") stream_NUMBER = RewriteRuleTokenStream(self._adaptor, "token NUMBER") stream_RESOLUTION = RewriteRuleTokenStream(self._adaptor, "token RESOLUTION") stream_FREQ = RewriteRuleTokenStream(self._adaptor, "token FREQ") stream_NTH = RewriteRuleTokenStream(self._adaptor, "token NTH") stream_PERCENTAGE = RewriteRuleTokenStream(self._adaptor, "token PERCENTAGE") stream_VPORTLEN = RewriteRuleTokenStream(self._adaptor, "token VPORTLEN") stream_LENGTH = RewriteRuleTokenStream(self._adaptor, "token LENGTH") stream_CHS = RewriteRuleTokenStream(self._adaptor, "token CHS") stream_unaryOperator = RewriteRuleSubtreeStream(self._adaptor, "rule unaryOperator") stream_hexColor = RewriteRuleSubtreeStream(self._adaptor, "rule hexColor") stream_function = RewriteRuleSubtreeStream(self._adaptor, "rule function") try: try: # lesscss.g:326:2: ( ( unaryOperator )? ( NUMBER -> ^( N_Term ( unaryOperator )? NUMBER ) | PERCENTAGE -> ^( N_Term ( unaryOperator )? PERCENTAGE ) | LENGTH -> ^( N_Term ( unaryOperator )? LENGTH ) | EMS -> ^( N_Term ( unaryOperator )? EMS ) | EXS -> ^( N_Term ( unaryOperator )? EXS ) | REMS -> ^( N_Term ( unaryOperator )? REMS ) | CHS -> ^( N_Term ( unaryOperator )? CHS ) | ANGLE -> ^( N_Term ( unaryOperator )? ANGLE ) | TIME -> ^( N_Term ( unaryOperator )? TIME ) | FREQ -> ^( N_Term ( unaryOperator )? FREQ ) | RESOLUTION -> ^( N_Term ( unaryOperator )? RESOLUTION ) | VPORTLEN -> ^( N_Term ( unaryOperator )? VPORTLEN ) | NTH -> ^( N_Term ( unaryOperator )? NTH ) | function -> ^( N_Term ( unaryOperator )? function ) ) | STRING | IDENT | URI | hexColor -> ^( N_Term hexColor ) | UNICODE_RANGE | LESS_VARNAME ) alt35 = 7 LA35 = self.input.LA(1) if LA35 == PERCENTAGE or LA35 == PLUS or LA35 == FUNCTION or LA35 == NUMBER or LA35 == LENGTH or LA35 == EMS or LA35 == EXS or LA35 == REMS or LA35 == CHS or LA35 == ANGLE or LA35 == TIME or LA35 == FREQ or LA35 == RESOLUTION or LA35 == VPORTLEN or LA35 == NTH or LA35 == MINUS: alt35 = 1 elif LA35 == IDENT: LA35_2 = self.input.LA(2) if (LA35_2 == COLON or LA35_2 == DOT) : alt35 = 1 elif ((STRING <= LA35_2 <= SEMI) or LA35_2 == URI or (RBRACE <= LA35_2 <= IDENT) or LA35_2 == RPAREN or (PERCENTAGE <= LA35_2 <= PLUS) or LA35_2 == HASH or (FUNCTION <= LA35_2 <= RBRACKET) or (IMPORTANT_SYM <= LA35_2 <= MINUS)) : alt35 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 35, 2, self.input) raise nvae elif LA35 == STRING: alt35 = 2 elif LA35 == URI: alt35 = 4 elif LA35 == HASH: alt35 = 5 elif LA35 == UNICODE_RANGE: alt35 = 6 elif LA35 == LESS_VARNAME: alt35 = 7 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 35, 0, self.input) raise nvae if alt35 == 1: # lesscss.g:326:4: ( unaryOperator )? ( NUMBER -> ^( N_Term ( unaryOperator )? NUMBER ) | PERCENTAGE -> ^( N_Term ( unaryOperator )? PERCENTAGE ) | LENGTH -> ^( N_Term ( unaryOperator )? LENGTH ) | EMS -> ^( N_Term ( unaryOperator )? EMS ) | EXS -> ^( N_Term ( unaryOperator )? EXS ) | REMS -> ^( N_Term ( unaryOperator )? REMS ) | CHS -> ^( N_Term ( unaryOperator )? CHS ) | ANGLE -> ^( N_Term ( unaryOperator )? ANGLE ) | TIME -> ^( N_Term ( unaryOperator )? TIME ) | FREQ -> ^( N_Term ( unaryOperator )? FREQ ) | RESOLUTION -> ^( N_Term ( unaryOperator )? RESOLUTION ) | VPORTLEN -> ^( N_Term ( unaryOperator )? VPORTLEN ) | NTH -> ^( N_Term ( unaryOperator )? NTH ) | function -> ^( N_Term ( unaryOperator )? function ) ) pass # lesscss.g:326:4: ( unaryOperator )? alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == PLUS or LA33_0 == MINUS) : alt33 = 1 if alt33 == 1: # lesscss.g:326:4: unaryOperator pass self._state.following.append(self.FOLLOW_unaryOperator_in_term1281) unaryOperator120 = self.unaryOperator() self._state.following.pop() if self._state.backtracking == 0: stream_unaryOperator.add(unaryOperator120.tree) # lesscss.g:326:19: ( NUMBER -> ^( N_Term ( unaryOperator )? NUMBER ) | PERCENTAGE -> ^( N_Term ( unaryOperator )? PERCENTAGE ) | LENGTH -> ^( N_Term ( unaryOperator )? LENGTH ) | EMS -> ^( N_Term ( unaryOperator )? EMS ) | EXS -> ^( N_Term ( unaryOperator )? EXS ) | REMS -> ^( N_Term ( unaryOperator )? REMS ) | CHS -> ^( N_Term ( unaryOperator )? CHS ) | ANGLE -> ^( N_Term ( unaryOperator )? ANGLE ) | TIME -> ^( N_Term ( unaryOperator )? TIME ) | FREQ -> ^( N_Term ( unaryOperator )? FREQ ) | RESOLUTION -> ^( N_Term ( unaryOperator )? RESOLUTION ) | VPORTLEN -> ^( N_Term ( unaryOperator )? VPORTLEN ) | NTH -> ^( N_Term ( unaryOperator )? NTH ) | function -> ^( N_Term ( unaryOperator )? function ) ) alt34 = 14 LA34 = self.input.LA(1) if LA34 == NUMBER: alt34 = 1 elif LA34 == PERCENTAGE: alt34 = 2 elif LA34 == LENGTH: alt34 = 3 elif LA34 == EMS: alt34 = 4 elif LA34 == EXS: alt34 = 5 elif LA34 == REMS: alt34 = 6 elif LA34 == CHS: alt34 = 7 elif LA34 == ANGLE: alt34 = 8 elif LA34 == TIME: alt34 = 9 elif LA34 == FREQ: alt34 = 10 elif LA34 == RESOLUTION: alt34 = 11 elif LA34 == VPORTLEN: alt34 = 12 elif LA34 == NTH: alt34 = 13 elif LA34 == IDENT or LA34 == FUNCTION: alt34 = 14 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 34, 0, self.input) raise nvae if alt34 == 1: # lesscss.g:327:5: NUMBER pass NUMBER121=self.match(self.input, NUMBER, self.FOLLOW_NUMBER_in_term1290) if self._state.backtracking == 0: stream_NUMBER.add(NUMBER121) # AST Rewrite # elements: unaryOperator, NUMBER # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 327:12: -> ^( N_Term ( unaryOperator )? NUMBER ) # lesscss.g:327:15: ^( N_Term ( unaryOperator )? NUMBER ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:327:24: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_NUMBER.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 2: # lesscss.g:328:5: PERCENTAGE pass PERCENTAGE122=self.match(self.input, PERCENTAGE, self.FOLLOW_PERCENTAGE_in_term1307) if self._state.backtracking == 0: stream_PERCENTAGE.add(PERCENTAGE122) # AST Rewrite # elements: unaryOperator, PERCENTAGE # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 328:16: -> ^( N_Term ( unaryOperator )? PERCENTAGE ) # lesscss.g:328:19: ^( N_Term ( unaryOperator )? PERCENTAGE ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:328:28: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_PERCENTAGE.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 3: # lesscss.g:329:5: LENGTH pass LENGTH123=self.match(self.input, LENGTH, self.FOLLOW_LENGTH_in_term1324) if self._state.backtracking == 0: stream_LENGTH.add(LENGTH123) # AST Rewrite # elements: LENGTH, unaryOperator # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 329:12: -> ^( N_Term ( unaryOperator )? LENGTH ) # lesscss.g:329:15: ^( N_Term ( unaryOperator )? LENGTH ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:329:24: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_LENGTH.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 4: # lesscss.g:330:5: EMS pass EMS124=self.match(self.input, EMS, self.FOLLOW_EMS_in_term1341) if self._state.backtracking == 0: stream_EMS.add(EMS124) # AST Rewrite # elements: unaryOperator, EMS # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 330:11: -> ^( N_Term ( unaryOperator )? EMS ) # lesscss.g:330:14: ^( N_Term ( unaryOperator )? EMS ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:330:23: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_EMS.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 5: # lesscss.g:331:5: EXS pass EXS125=self.match(self.input, EXS, self.FOLLOW_EXS_in_term1360) if self._state.backtracking == 0: stream_EXS.add(EXS125) # AST Rewrite # elements: EXS, unaryOperator # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 331:11: -> ^( N_Term ( unaryOperator )? EXS ) # lesscss.g:331:14: ^( N_Term ( unaryOperator )? EXS ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:331:23: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_EXS.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 6: # lesscss.g:332:5: REMS pass REMS126=self.match(self.input, REMS, self.FOLLOW_REMS_in_term1379) if self._state.backtracking == 0: stream_REMS.add(REMS126) # AST Rewrite # elements: unaryOperator, REMS # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 332:12: -> ^( N_Term ( unaryOperator )? REMS ) # lesscss.g:332:15: ^( N_Term ( unaryOperator )? REMS ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:332:24: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_REMS.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 7: # lesscss.g:333:5: CHS pass CHS127=self.match(self.input, CHS, self.FOLLOW_CHS_in_term1398) if self._state.backtracking == 0: stream_CHS.add(CHS127) # AST Rewrite # elements: unaryOperator, CHS # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 333:11: -> ^( N_Term ( unaryOperator )? CHS ) # lesscss.g:333:14: ^( N_Term ( unaryOperator )? CHS ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:333:23: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_CHS.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 8: # lesscss.g:334:5: ANGLE pass ANGLE128=self.match(self.input, ANGLE, self.FOLLOW_ANGLE_in_term1417) if self._state.backtracking == 0: stream_ANGLE.add(ANGLE128) # AST Rewrite # elements: unaryOperator, ANGLE # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 334:13: -> ^( N_Term ( unaryOperator )? ANGLE ) # lesscss.g:334:16: ^( N_Term ( unaryOperator )? ANGLE ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:334:25: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_ANGLE.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 9: # lesscss.g:335:5: TIME pass TIME129=self.match(self.input, TIME, self.FOLLOW_TIME_in_term1436) if self._state.backtracking == 0: stream_TIME.add(TIME129) # AST Rewrite # elements: unaryOperator, TIME # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 335:12: -> ^( N_Term ( unaryOperator )? TIME ) # lesscss.g:335:15: ^( N_Term ( unaryOperator )? TIME ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:335:24: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_TIME.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 10: # lesscss.g:336:5: FREQ pass FREQ130=self.match(self.input, FREQ, self.FOLLOW_FREQ_in_term1455) if self._state.backtracking == 0: stream_FREQ.add(FREQ130) # AST Rewrite # elements: unaryOperator, FREQ # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 336:12: -> ^( N_Term ( unaryOperator )? FREQ ) # lesscss.g:336:15: ^( N_Term ( unaryOperator )? FREQ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:336:24: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_FREQ.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 11: # lesscss.g:337:5: RESOLUTION pass RESOLUTION131=self.match(self.input, RESOLUTION, self.FOLLOW_RESOLUTION_in_term1474) if self._state.backtracking == 0: stream_RESOLUTION.add(RESOLUTION131) # AST Rewrite # elements: unaryOperator, RESOLUTION # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 337:16: -> ^( N_Term ( unaryOperator )? RESOLUTION ) # lesscss.g:337:19: ^( N_Term ( unaryOperator )? RESOLUTION ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:337:28: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_RESOLUTION.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 12: # lesscss.g:338:5: VPORTLEN pass VPORTLEN132=self.match(self.input, VPORTLEN, self.FOLLOW_VPORTLEN_in_term1491) if self._state.backtracking == 0: stream_VPORTLEN.add(VPORTLEN132) # AST Rewrite # elements: VPORTLEN, unaryOperator # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 338:14: -> ^( N_Term ( unaryOperator )? VPORTLEN ) # lesscss.g:338:17: ^( N_Term ( unaryOperator )? VPORTLEN ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:338:26: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_VPORTLEN.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 13: # lesscss.g:339:5: NTH pass NTH133=self.match(self.input, NTH, self.FOLLOW_NTH_in_term1508) if self._state.backtracking == 0: stream_NTH.add(NTH133) # AST Rewrite # elements: NTH, unaryOperator # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 339:11: -> ^( N_Term ( unaryOperator )? NTH ) # lesscss.g:339:14: ^( N_Term ( unaryOperator )? NTH ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:339:23: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_NTH.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt34 == 14: # lesscss.g:340:5: function pass self._state.following.append(self.FOLLOW_function_in_term1527) function134 = self.function() self._state.following.pop() if self._state.backtracking == 0: stream_function.add(function134.tree) # AST Rewrite # elements: function, unaryOperator # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 340:14: -> ^( N_Term ( unaryOperator )? function ) # lesscss.g:340:17: ^( N_Term ( unaryOperator )? function ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) # lesscss.g:340:26: ( unaryOperator )? if stream_unaryOperator.hasNext(): self._adaptor.addChild(root_1, stream_unaryOperator.nextTree()) stream_unaryOperator.reset(); self._adaptor.addChild(root_1, stream_function.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt35 == 2: # lesscss.g:342:4: STRING pass root_0 = self._adaptor.nil() STRING135=self.match(self.input, STRING, self.FOLLOW_STRING_in_term1546) if self._state.backtracking == 0: STRING135_tree = self._adaptor.createWithPayload(STRING135) self._adaptor.addChild(root_0, STRING135_tree) elif alt35 == 3: # lesscss.g:343:4: IDENT pass root_0 = self._adaptor.nil() IDENT136=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_term1551) if self._state.backtracking == 0: IDENT136_tree = self._adaptor.createWithPayload(IDENT136) self._adaptor.addChild(root_0, IDENT136_tree) elif alt35 == 4: # lesscss.g:344:4: URI pass root_0 = self._adaptor.nil() URI137=self.match(self.input, URI, self.FOLLOW_URI_in_term1556) if self._state.backtracking == 0: URI137_tree = self._adaptor.createWithPayload(URI137) self._adaptor.addChild(root_0, URI137_tree) elif alt35 == 5: # lesscss.g:345:4: hexColor pass self._state.following.append(self.FOLLOW_hexColor_in_term1561) hexColor138 = self.hexColor() self._state.following.pop() if self._state.backtracking == 0: stream_hexColor.add(hexColor138.tree) # AST Rewrite # elements: hexColor # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 345:14: -> ^( N_Term hexColor ) # lesscss.g:345:17: ^( N_Term hexColor ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Term, "N_Term"), root_1) self._adaptor.addChild(root_1, stream_hexColor.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt35 == 6: # lesscss.g:346:4: UNICODE_RANGE pass root_0 = self._adaptor.nil() UNICODE_RANGE139=self.match(self.input, UNICODE_RANGE, self.FOLLOW_UNICODE_RANGE_in_term1575) if self._state.backtracking == 0: UNICODE_RANGE139_tree = self._adaptor.createWithPayload(UNICODE_RANGE139) self._adaptor.addChild(root_0, UNICODE_RANGE139_tree) elif alt35 == 7: # lesscss.g:347:4: LESS_VARNAME pass root_0 = self._adaptor.nil() LESS_VARNAME140=self.match(self.input, LESS_VARNAME, self.FOLLOW_LESS_VARNAME_in_term1580) if self._state.backtracking == 0: LESS_VARNAME140_tree = self._adaptor.createWithPayload(LESS_VARNAME140) self._adaptor.addChild(root_0, LESS_VARNAME140_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "term" class unaryOperator_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.unaryOperator_return, self).__init__() self.tree = None # $ANTLR start "unaryOperator" # lesscss.g:350:1: unaryOperator : ( MINUS | PLUS ); def unaryOperator(self, ): retval = self.unaryOperator_return() retval.start = self.input.LT(1) root_0 = None set141 = None set141_tree = None try: try: # lesscss.g:351:2: ( MINUS | PLUS ) # lesscss.g: pass root_0 = self._adaptor.nil() set141 = self.input.LT(1) if self.input.LA(1) == PLUS or self.input.LA(1) == MINUS: self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set141)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "unaryOperator" class function_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.function_return, self).__init__() self.tree = None # $ANTLR start "function" # lesscss.g:356:1: function : ( fnct_name fnct_args RPAREN -> ^( N_Function fnct_name fnct_args ) | fnct_name expr RPAREN -> ^( N_Function fnct_name ^( N_Expr expr ) ) ); def function(self, ): retval = self.function_return() retval.start = self.input.LT(1) root_0 = None RPAREN144 = None RPAREN147 = None fnct_name142 = None fnct_args143 = None fnct_name145 = None expr146 = None RPAREN144_tree = None RPAREN147_tree = None stream_RPAREN = RewriteRuleTokenStream(self._adaptor, "token RPAREN") stream_fnct_name = RewriteRuleSubtreeStream(self._adaptor, "rule fnct_name") stream_fnct_args = RewriteRuleSubtreeStream(self._adaptor, "rule fnct_args") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # lesscss.g:357:2: ( fnct_name fnct_args RPAREN -> ^( N_Function fnct_name fnct_args ) | fnct_name expr RPAREN -> ^( N_Function fnct_name ^( N_Expr expr ) ) ) alt36 = 2 alt36 = self.dfa36.predict(self.input) if alt36 == 1: # lesscss.g:357:4: fnct_name fnct_args RPAREN pass self._state.following.append(self.FOLLOW_fnct_name_in_function1608) fnct_name142 = self.fnct_name() self._state.following.pop() if self._state.backtracking == 0: stream_fnct_name.add(fnct_name142.tree) self._state.following.append(self.FOLLOW_fnct_args_in_function1610) fnct_args143 = self.fnct_args() self._state.following.pop() if self._state.backtracking == 0: stream_fnct_args.add(fnct_args143.tree) RPAREN144=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_function1612) if self._state.backtracking == 0: stream_RPAREN.add(RPAREN144) # AST Rewrite # elements: fnct_args, fnct_name # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 358:3: -> ^( N_Function fnct_name fnct_args ) # lesscss.g:358:6: ^( N_Function fnct_name fnct_args ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Function, "N_Function"), root_1) self._adaptor.addChild(root_1, stream_fnct_name.nextTree()) self._adaptor.addChild(root_1, stream_fnct_args.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt36 == 2: # lesscss.g:360:4: fnct_name expr RPAREN pass self._state.following.append(self.FOLLOW_fnct_name_in_function1630) fnct_name145 = self.fnct_name() self._state.following.pop() if self._state.backtracking == 0: stream_fnct_name.add(fnct_name145.tree) self._state.following.append(self.FOLLOW_expr_in_function1632) expr146 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr146.tree) RPAREN147=self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_function1634) if self._state.backtracking == 0: stream_RPAREN.add(RPAREN147) # AST Rewrite # elements: expr, fnct_name # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 361:3: -> ^( N_Function fnct_name ^( N_Expr expr ) ) # lesscss.g:361:6: ^( N_Function fnct_name ^( N_Expr expr ) ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Function, "N_Function"), root_1) self._adaptor.addChild(root_1, stream_fnct_name.nextTree()) # lesscss.g:361:29: ^( N_Expr expr ) root_2 = self._adaptor.nil() root_2 = self._adaptor.becomeRoot(self._adaptor.createFromType(N_Expr, "N_Expr"), root_2) self._adaptor.addChild(root_2, stream_expr.nextTree()) self._adaptor.addChild(root_1, root_2) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "function" class fnct_name_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.fnct_name_return, self).__init__() self.tree = None # $ANTLR start "fnct_name" # lesscss.g:365:1: fnct_name : ( IDENT ( COLON | DOT )+ )* FUNCTION ; def fnct_name(self, ): retval = self.fnct_name_return() retval.start = self.input.LT(1) root_0 = None IDENT148 = None set149 = None FUNCTION150 = None IDENT148_tree = None set149_tree = None FUNCTION150_tree = None try: try: # lesscss.g:366:2: ( ( IDENT ( COLON | DOT )+ )* FUNCTION ) # lesscss.g:366:4: ( IDENT ( COLON | DOT )+ )* FUNCTION pass root_0 = self._adaptor.nil() # lesscss.g:366:4: ( IDENT ( COLON | DOT )+ )* while True: #loop38 alt38 = 2 LA38_0 = self.input.LA(1) if (LA38_0 == IDENT) : alt38 = 1 if alt38 == 1: # lesscss.g:366:5: IDENT ( COLON | DOT )+ pass IDENT148=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_fnct_name1664) if self._state.backtracking == 0: IDENT148_tree = self._adaptor.createWithPayload(IDENT148) self._adaptor.addChild(root_0, IDENT148_tree) # lesscss.g:366:11: ( COLON | DOT )+ cnt37 = 0 while True: #loop37 alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == COLON or LA37_0 == DOT) : alt37 = 1 if alt37 == 1: # lesscss.g: pass set149 = self.input.LT(1) if self.input.LA(1) == COLON or self.input.LA(1) == DOT: self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set149)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse else: if cnt37 >= 1: break #loop37 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(37, self.input) raise eee cnt37 += 1 else: break #loop38 FUNCTION150=self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_fnct_name1676) if self._state.backtracking == 0: FUNCTION150_tree = self._adaptor.createWithPayload(FUNCTION150) root_0 = self._adaptor.becomeRoot(FUNCTION150_tree, root_0) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "fnct_name" class fnct_args_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.fnct_args_return, self).__init__() self.tree = None # $ANTLR start "fnct_args" # lesscss.g:369:10: fragment fnct_args : fnct_arg ( COMMA fnct_arg )* ; def fnct_args(self, ): retval = self.fnct_args_return() retval.start = self.input.LT(1) root_0 = None COMMA152 = None fnct_arg151 = None fnct_arg153 = None COMMA152_tree = None try: try: # lesscss.g:370:2: ( fnct_arg ( COMMA fnct_arg )* ) # lesscss.g:370:4: fnct_arg ( COMMA fnct_arg )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_fnct_arg_in_fnct_args1690) fnct_arg151 = self.fnct_arg() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, fnct_arg151.tree) # lesscss.g:370:13: ( COMMA fnct_arg )* while True: #loop39 alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == COMMA) : alt39 = 1 if alt39 == 1: # lesscss.g:370:14: COMMA fnct_arg pass COMMA152=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_fnct_args1693) if self._state.backtracking == 0: COMMA152_tree = self._adaptor.createWithPayload(COMMA152) root_0 = self._adaptor.becomeRoot(COMMA152_tree, root_0) self._state.following.append(self.FOLLOW_fnct_arg_in_fnct_args1696) fnct_arg153 = self.fnct_arg() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, fnct_arg153.tree) else: break #loop39 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "fnct_args" class fnct_arg_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.fnct_arg_return, self).__init__() self.tree = None # $ANTLR start "fnct_arg" # lesscss.g:373:1: fnct_arg : IDENT OPEQ expr ; def fnct_arg(self, ): retval = self.fnct_arg_return() retval.start = self.input.LT(1) root_0 = None IDENT154 = None OPEQ155 = None expr156 = None IDENT154_tree = None OPEQ155_tree = None try: try: # lesscss.g:374:2: ( IDENT OPEQ expr ) # lesscss.g:374:4: IDENT OPEQ expr pass root_0 = self._adaptor.nil() IDENT154=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_fnct_arg1709) if self._state.backtracking == 0: IDENT154_tree = self._adaptor.createWithPayload(IDENT154) self._adaptor.addChild(root_0, IDENT154_tree) OPEQ155=self.match(self.input, OPEQ, self.FOLLOW_OPEQ_in_fnct_arg1711) if self._state.backtracking == 0: OPEQ155_tree = self._adaptor.createWithPayload(OPEQ155) root_0 = self._adaptor.becomeRoot(OPEQ155_tree, root_0) self._state.following.append(self.FOLLOW_expr_in_fnct_arg1714) expr156 = self.expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expr156.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "fnct_arg" class hexColor_return(ParserRuleReturnScope): def __init__(self): super(lesscssParser.hexColor_return, self).__init__() self.tree = None # $ANTLR start "hexColor" # lesscss.g:377:1: hexColor : HASH ; def hexColor(self, ): retval = self.hexColor_return() retval.start = self.input.LT(1) root_0 = None HASH157 = None HASH157_tree = None try: try: # lesscss.g:378:2: ( HASH ) # lesscss.g:378:4: HASH pass root_0 = self._adaptor.nil() HASH157=self.match(self.input, HASH, self.FOLLOW_HASH_in_hexColor1725) if self._state.backtracking == 0: HASH157_tree = self._adaptor.createWithPayload(HASH157) self._adaptor.addChild(root_0, HASH157_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "hexColor" # $ANTLR start "synpred1_lesscss" def synpred1_lesscss_fragment(self, ): # lesscss.g:214:17: ( esPred ) # lesscss.g:214:18: esPred pass self._state.following.append(self.FOLLOW_esPred_in_synpred1_lesscss728) self.esPred() self._state.following.pop() # $ANTLR end "synpred1_lesscss" # $ANTLR start "synpred2_lesscss" def synpred2_lesscss_fragment(self, ): # lesscss.g:215:5: ( esPred ) # lesscss.g:215:6: esPred pass self._state.following.append(self.FOLLOW_esPred_in_synpred2_lesscss740) self.esPred() self._state.following.pop() # $ANTLR end "synpred2_lesscss" # Delegated rules def synpred2_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred2_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred1_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred1_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success # lookup tables for DFA #17 DFA17_eot = DFA.unpack( u"\13\uffff" ) DFA17_eof = DFA.unpack( u"\13\uffff" ) DFA17_min = DFA.unpack( u"\1\33\3\uffff\4\0\3\uffff" ) DFA17_max = DFA.unpack( u"\1\54\3\uffff\4\0\3\uffff" ) DFA17_accept = DFA.unpack( u"\1\uffff\1\2\10\uffff\1\1" ) DFA17_special = DFA.unpack( u"\4\uffff\1\0\1\1\1\2\1\3\3\uffff" ) DFA17_transition = [ DFA.unpack(u"\1\1\1\uffff\2\1\1\uffff\1\6\6\uffff\2\1\1\4\1\5\1\7" u"\1\1"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #17 class DFA17(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA17_4 = input.LA(1) index17_4 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 10 elif (True): s = 1 input.seek(index17_4) if s >= 0: return s elif s == 1: LA17_5 = input.LA(1) index17_5 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 10 elif (True): s = 1 input.seek(index17_5) if s >= 0: return s elif s == 2: LA17_6 = input.LA(1) index17_6 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 10 elif (True): s = 1 input.seek(index17_6) if s >= 0: return s elif s == 3: LA17_7 = input.LA(1) index17_7 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 10 elif (True): s = 1 input.seek(index17_7) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 17, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #36 DFA36_eot = DFA.unpack( u"\7\uffff" ) DFA36_eof = DFA.unpack( u"\7\uffff" ) DFA36_min = DFA.unpack( u"\1\36\1\40\1\26\1\36\1\26\2\uffff" ) DFA36_max = DFA.unpack( u"\1\55\1\52\1\104\1\55\1\104\2\uffff" ) DFA36_accept = DFA.unpack( u"\5\uffff\1\2\1\1" ) DFA36_special = DFA.unpack( u"\7\uffff" ) DFA36_transition = [ DFA.unpack(u"\1\1\16\uffff\1\2"), DFA.unpack(u"\1\3\11\uffff\1\3"), DFA.unpack(u"\1\5\2\uffff\1\5\4\uffff\1\4\6\uffff\3\5\1\uffff\1" u"\5\3\uffff\1\5\11\uffff\16\5"), DFA.unpack(u"\1\1\1\uffff\1\3\11\uffff\1\3\2\uffff\1\2"), DFA.unpack(u"\1\5\2\uffff\1\5\3\uffff\2\5\1\uffff\2\5\3\uffff\3" u"\5\1\uffff\2\5\2\uffff\1\5\1\uffff\1\6\6\uffff\17\5"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #36 class DFA36(DFA): pass FOLLOW_charSet_in_styleSheet147 = frozenset([24, 26, 30, 32, 34, 35, 36, 38, 41, 42, 43, 44]) FOLLOW_imports_in_styleSheet153 = frozenset([24, 26, 30, 32, 34, 35, 36, 38, 41, 42, 43, 44]) FOLLOW_body_in_styleSheet159 = frozenset([26, 30, 32, 34, 35, 36, 38, 41, 42, 43, 44]) FOLLOW_EOF_in_styleSheet165 = frozenset([1]) FOLLOW_CHARSET_SYM_in_charSet197 = frozenset([22]) FOLLOW_STRING_in_charSet200 = frozenset([23]) FOLLOW_SEMI_in_charSet202 = frozenset([1]) FOLLOW_IMPORT_SYM_in_imports217 = frozenset([22, 25]) FOLLOW_importUrl_in_imports220 = frozenset([23, 30, 31]) FOLLOW_media_query_list_in_imports222 = frozenset([23]) FOLLOW_SEMI_in_imports225 = frozenset([1]) FOLLOW_set_in_importUrl0 = frozenset([1]) FOLLOW_ruleSet_in_body257 = frozenset([1]) FOLLOW_media_in_body262 = frozenset([1]) FOLLOW_page_in_body267 = frozenset([1]) FOLLOW_fontface_in_body272 = frozenset([1]) FOLLOW_keyframes_in_body277 = frozenset([1]) FOLLOW_less_variable_def_in_body282 = frozenset([1]) FOLLOW_MEDIA_SYM_in_media301 = frozenset([27, 30, 31]) FOLLOW_media_query_list_in_media304 = frozenset([27]) FOLLOW_LBRACE_in_media309 = frozenset([26, 28, 30, 32, 34, 35, 36, 38, 41, 42, 43, 44]) FOLLOW_body_in_media315 = frozenset([26, 28, 30, 32, 34, 35, 36, 38, 41, 42, 43, 44]) FOLLOW_RBRACE_in_media324 = frozenset([1]) FOLLOW_media_query_in_media_query_list339 = frozenset([1, 29]) FOLLOW_COMMA_in_media_query_list342 = frozenset([30, 31]) FOLLOW_media_query_in_media_query_list344 = frozenset([1, 29]) FOLLOW_media_stmt_in_media_query373 = frozenset([1, 30, 31]) FOLLOW_media_expr_in_media_query377 = frozenset([1, 30, 31]) FOLLOW_IDENT_in_media_stmt391 = frozenset([1]) FOLLOW_LPAREN_in_media_expr402 = frozenset([30]) FOLLOW_media_stmt_in_media_expr404 = frozenset([32, 33]) FOLLOW_COLON_in_media_expr408 = frozenset([22, 25, 30, 37, 38, 39, 41, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_expr_in_media_expr410 = frozenset([33]) FOLLOW_RPAREN_in_media_expr415 = frozenset([1]) FOLLOW_FONTFACE_SYM_in_fontface444 = frozenset([27]) FOLLOW_LBRACE_in_fontface447 = frozenset([28, 30, 44]) FOLLOW_declarationset_in_fontface450 = frozenset([28]) FOLLOW_RBRACE_in_fontface452 = frozenset([1]) FOLLOW_PAGE_SYM_in_page467 = frozenset([27, 32]) FOLLOW_pseudoPage_in_page470 = frozenset([27]) FOLLOW_LBRACE_in_page473 = frozenset([28, 30, 44]) FOLLOW_declarationset_in_page476 = frozenset([28]) FOLLOW_RBRACE_in_page478 = frozenset([1]) FOLLOW_COLON_in_pseudoPage490 = frozenset([30]) FOLLOW_IDENT_in_pseudoPage494 = frozenset([1]) FOLLOW_KEYFRAMES_SYM_in_keyframes520 = frozenset([30]) FOLLOW_IDENT_in_keyframes523 = frozenset([27]) FOLLOW_LBRACE_in_keyframes525 = frozenset([28, 30, 37]) FOLLOW_keyframes_block_in_keyframes528 = frozenset([28, 30, 37]) FOLLOW_RBRACE_in_keyframes531 = frozenset([1]) FOLLOW_keyframe_selector_in_keyframes_block543 = frozenset([27, 29]) FOLLOW_COMMA_in_keyframes_block547 = frozenset([30, 37]) FOLLOW_keyframe_selector_in_keyframes_block549 = frozenset([27, 29]) FOLLOW_LBRACE_in_keyframes_block554 = frozenset([28, 30, 44]) FOLLOW_declarationset_in_keyframes_block556 = frozenset([28]) FOLLOW_RBRACE_in_keyframes_block558 = frozenset([1]) FOLLOW_set_in_keyframe_selector588 = frozenset([1]) FOLLOW_LESS_VARNAME_in_less_variable_def611 = frozenset([32]) FOLLOW_COLON_in_less_variable_def613 = frozenset([22, 25, 30, 37, 38, 39, 41, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_term_in_less_variable_def615 = frozenset([23]) FOLLOW_SEMI_in_less_variable_def617 = frozenset([1]) FOLLOW_selector_in_ruleSet646 = frozenset([27, 29]) FOLLOW_COMMA_in_ruleSet649 = frozenset([30, 32, 41, 42, 43, 44]) FOLLOW_selector_in_ruleSet651 = frozenset([27, 29]) FOLLOW_LBRACE_in_ruleSet655 = frozenset([28, 30, 44]) FOLLOW_declarationset_in_ruleSet657 = frozenset([28]) FOLLOW_RBRACE_in_ruleSet659 = frozenset([1]) FOLLOW_simpleSelector_in_selector687 = frozenset([1, 30, 32, 39, 40, 41, 42, 43, 44]) FOLLOW_combinator_in_selector690 = frozenset([30, 32, 41, 42, 43, 44]) FOLLOW_simpleSelector_in_selector692 = frozenset([1, 30, 32, 39, 40, 41, 42, 43, 44]) FOLLOW_PLUS_in_combinator705 = frozenset([1]) FOLLOW_GREATER_in_combinator710 = frozenset([1]) FOLLOW_elementName_in_simpleSelector724 = frozenset([1, 30, 32, 41, 42, 43, 44]) FOLLOW_elementSubsequent_in_simpleSelector731 = frozenset([1, 30, 32, 41, 42, 43, 44]) FOLLOW_elementSubsequent_in_simpleSelector743 = frozenset([1, 30, 32, 41, 42, 43, 44]) FOLLOW_set_in_esPred0 = frozenset([1]) FOLLOW_set_in_elementName0 = frozenset([1]) FOLLOW_HASH_in_elementSubsequent805 = frozenset([1]) FOLLOW_cssClass_in_elementSubsequent810 = frozenset([1]) FOLLOW_pseudo_in_elementSubsequent815 = frozenset([1]) FOLLOW_attrib_in_elementSubsequent820 = frozenset([1]) FOLLOW_DOT_in_cssClass832 = frozenset([30]) FOLLOW_IDENT_in_cssClass836 = frozenset([1]) FOLLOW_COLON_in_pseudo860 = frozenset([30, 32, 45]) FOLLOW_COLON_in_pseudo864 = frozenset([30, 32, 45]) FOLLOW_IDENT_in_pseudo870 = frozenset([1]) FOLLOW_pseudoFunction_in_pseudo892 = frozenset([1]) FOLLOW_FUNCTION_in_pseudoFunction923 = frozenset([22, 25, 30, 37, 38, 39, 41, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_expr_in_pseudoFunction925 = frozenset([33]) FOLLOW_RPAREN_in_pseudoFunction927 = frozenset([1]) FOLLOW_FUNCTION_in_pseudoFunction946 = frozenset([43]) FOLLOW_LBRACKET_in_pseudoFunction948 = frozenset([30]) FOLLOW_attribBody_in_pseudoFunction950 = frozenset([46]) FOLLOW_RBRACKET_in_pseudoFunction952 = frozenset([33]) FOLLOW_RPAREN_in_pseudoFunction954 = frozenset([1]) FOLLOW_FUNCTION_in_pseudoFunction977 = frozenset([32]) FOLLOW_pseudo_in_pseudoFunction979 = frozenset([33]) FOLLOW_RPAREN_in_pseudoFunction981 = frozenset([1]) FOLLOW_LBRACKET_in_attrib1006 = frozenset([30]) FOLLOW_attribBody_in_attrib1008 = frozenset([46]) FOLLOW_RBRACKET_in_attrib1010 = frozenset([1]) FOLLOW_IDENT_in_attribBody1033 = frozenset([1]) FOLLOW_IDENT_in_attribBody1038 = frozenset([47, 48, 49, 50, 51, 52]) FOLLOW_set_in_attribBody1043 = frozenset([22, 25, 30, 37, 38, 39, 41, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_term_in_attribBody1087 = frozenset([1]) FOLLOW_declaration_in_declarationset1102 = frozenset([1, 23]) FOLLOW_SEMI_in_declarationset1105 = frozenset([30, 44]) FOLLOW_declaration_in_declarationset1108 = frozenset([1, 23]) FOLLOW_SEMI_in_declarationset1112 = frozenset([1]) FOLLOW_property_in_declaration1132 = frozenset([32]) FOLLOW_COLON_in_declaration1134 = frozenset([22, 25, 30, 37, 38, 39, 41, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_expr_in_declaration1136 = frozenset([1, 53]) FOLLOW_prio_in_declaration1138 = frozenset([1]) FOLLOW_property_in_declaration1161 = frozenset([32]) FOLLOW_COLON_in_declaration1163 = frozenset([1]) FOLLOW_IDENT_in_property1188 = frozenset([1]) FOLLOW_STAR_in_property1198 = frozenset([30]) FOLLOW_IDENT_in_property1202 = frozenset([1]) FOLLOW_IMPORTANT_SYM_in_prio1225 = frozenset([1]) FOLLOW_term_in_expr1236 = frozenset([1, 22, 25, 29, 30, 37, 38, 39, 41, 45, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_operator_in_expr1239 = frozenset([22, 25, 30, 37, 38, 39, 41, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_term_in_expr1242 = frozenset([1, 22, 25, 29, 30, 37, 38, 39, 41, 45, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_SOLIDUS_in_operator1257 = frozenset([1]) FOLLOW_COMMA_in_operator1262 = frozenset([1]) FOLLOW_unaryOperator_in_term1281 = frozenset([30, 37, 39, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 68]) FOLLOW_NUMBER_in_term1290 = frozenset([1]) FOLLOW_PERCENTAGE_in_term1307 = frozenset([1]) FOLLOW_LENGTH_in_term1324 = frozenset([1]) FOLLOW_EMS_in_term1341 = frozenset([1]) FOLLOW_EXS_in_term1360 = frozenset([1]) FOLLOW_REMS_in_term1379 = frozenset([1]) FOLLOW_CHS_in_term1398 = frozenset([1]) FOLLOW_ANGLE_in_term1417 = frozenset([1]) FOLLOW_TIME_in_term1436 = frozenset([1]) FOLLOW_FREQ_in_term1455 = frozenset([1]) FOLLOW_RESOLUTION_in_term1474 = frozenset([1]) FOLLOW_VPORTLEN_in_term1491 = frozenset([1]) FOLLOW_NTH_in_term1508 = frozenset([1]) FOLLOW_function_in_term1527 = frozenset([1]) FOLLOW_STRING_in_term1546 = frozenset([1]) FOLLOW_IDENT_in_term1551 = frozenset([1]) FOLLOW_URI_in_term1556 = frozenset([1]) FOLLOW_hexColor_in_term1561 = frozenset([1]) FOLLOW_UNICODE_RANGE_in_term1575 = frozenset([1]) FOLLOW_LESS_VARNAME_in_term1580 = frozenset([1]) FOLLOW_set_in_unaryOperator0 = frozenset([1]) FOLLOW_fnct_name_in_function1608 = frozenset([30]) FOLLOW_fnct_args_in_function1610 = frozenset([33]) FOLLOW_RPAREN_in_function1612 = frozenset([1]) FOLLOW_fnct_name_in_function1630 = frozenset([22, 25, 30, 37, 38, 39, 41, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_expr_in_function1632 = frozenset([33]) FOLLOW_RPAREN_in_function1634 = frozenset([1]) FOLLOW_IDENT_in_fnct_name1664 = frozenset([32, 42]) FOLLOW_set_in_fnct_name1666 = frozenset([30, 32, 42, 45]) FOLLOW_FUNCTION_in_fnct_name1676 = frozenset([1]) FOLLOW_fnct_arg_in_fnct_args1690 = frozenset([1, 29]) FOLLOW_COMMA_in_fnct_args1693 = frozenset([30]) FOLLOW_fnct_arg_in_fnct_args1696 = frozenset([1, 29]) FOLLOW_IDENT_in_fnct_arg1709 = frozenset([47]) FOLLOW_OPEQ_in_fnct_arg1711 = frozenset([22, 25, 30, 37, 38, 39, 41, 45, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68]) FOLLOW_expr_in_fnct_arg1714 = frozenset([1]) FOLLOW_HASH_in_hexColor1725 = frozenset([1]) FOLLOW_esPred_in_synpred1_lesscss728 = frozenset([1]) FOLLOW_esPred_in_synpred2_lesscss740 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("lesscssLexer", lesscssParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ateska/pyless", "path": "pyless/lesscssParser.py", "copies": "1", "size": "219227", "license": "bsd-2-clause", "hash": -1851692924144149200, "line_mean": 34.6234969126, "line_max": 834, "alpha_frac": 0.4940632313, "autogenerated": false, "ratio": 4.072353389185072, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5066416620485072, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 lesscss.g 2012-12-04 00:36:16 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types FUNCTION=45 UNICODE_RANGE=67 STAR=44 EOF=-1 MEDIA_SYM=26 LBRACKET=43 INCLUDES=48 RPAREN=33 NAME=75 GREATER=40 ESCAPE=72 DIMENSION=108 STRINGESC=106 NL=109 COMMENT=103 D=80 E=81 F=82 G=83 A=77 B=78 RBRACE=28 C=79 L=88 M=89 NMCHAR=74 IMPORT_SYM=24 N=90 SUBSTRINGMATCH=52 O=91 H=84 I=85 J=86 K=87 NUMBER=55 U=97 T=96 W=99 V=98 Q=93 P=92 S=95 CDO=104 R=94 CDC=105 Y=101 PERCENTAGE=37 URL=76 X=100 Z=102 URI=25 PAGE_SYM=35 WS=107 DASHMATCH=49 EMS=57 N_Less_VarDef=20 N_PseudoFunction=17 N_RuleSet=7 NONASCII=70 N_MediaQuery=5 N_Expr=19 N_Selector=10 LBRACE=27 LPAREN=31 LENGTH=56 IMPORTANT_SYM=53 N_Function=12 TIME=62 KEYFRAMES_SYM=36 COMMA=29 N_StyleSheet=4 IDENT=30 PLUS=39 FREQ=63 RBRACKET=46 DOT=42 VPORTLEN=65 CHARSET_SYM=21 ANGLE=61 REMS=59 HASH=41 HEXCHAR=69 RESOLUTION=64 PREFIXMATCH=50 MINUS=68 N_Pseudo=16 SOLIDUS=54 SEMI=23 N_Empty=14 UNICODE=71 CHS=60 COLON=32 NMSTART=73 N_Declaration=11 OPEQ=47 FONTFACE_SYM=34 N_Term=18 EXS=58 N_Space=15 M_KeyframeSelector=9 N_MediaExpr=6 N_Attrib=13 N_KeyframeBlock=8 SUFFIXMATCH=51 LESS_VARNAME=38 NTH=66 STRING=22 class lesscssLexer(Lexer): grammarFileName = "lesscss.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(lesscssLexer, self).__init__(input, state) self.dfa198 = self.DFA198( self, 198, eot = self.DFA198_eot, eof = self.DFA198_eof, min = self.DFA198_min, max = self.DFA198_max, accept = self.DFA198_accept, special = self.DFA198_special, transition = self.DFA198_transition ) self.dfa204 = self.DFA204( self, 204, eot = self.DFA204_eot, eof = self.DFA204_eof, min = self.DFA204_min, max = self.DFA204_max, accept = self.DFA204_accept, special = self.DFA204_special, transition = self.DFA204_transition ) self.dfa207 = self.DFA207( self, 207, eot = self.DFA207_eot, eof = self.DFA207_eof, min = self.DFA207_min, max = self.DFA207_max, accept = self.DFA207_accept, special = self.DFA207_special, transition = self.DFA207_transition ) self.dfa224 = self.DFA224( self, 224, eot = self.DFA224_eot, eof = self.DFA224_eof, min = self.DFA224_min, max = self.DFA224_max, accept = self.DFA224_accept, special = self.DFA224_special, transition = self.DFA224_transition ) self.dfa217 = self.DFA217( self, 217, eot = self.DFA217_eot, eof = self.DFA217_eof, min = self.DFA217_min, max = self.DFA217_max, accept = self.DFA217_accept, special = self.DFA217_special, transition = self.DFA217_transition ) self.dfa220 = self.DFA220( self, 220, eot = self.DFA220_eot, eof = self.DFA220_eof, min = self.DFA220_min, max = self.DFA220_max, accept = self.DFA220_accept, special = self.DFA220_special, transition = self.DFA220_transition ) self.dfa221 = self.DFA221( self, 221, eot = self.DFA221_eot, eof = self.DFA221_eof, min = self.DFA221_min, max = self.DFA221_max, accept = self.DFA221_accept, special = self.DFA221_special, transition = self.DFA221_transition ) self.dfa223 = self.DFA223( self, 223, eot = self.DFA223_eot, eof = self.DFA223_eof, min = self.DFA223_min, max = self.DFA223_max, accept = self.DFA223_accept, special = self.DFA223_special, transition = self.DFA223_transition ) self.dfa231 = self.DFA231( self, 231, eot = self.DFA231_eot, eof = self.DFA231_eof, min = self.DFA231_min, max = self.DFA231_max, accept = self.DFA231_accept, special = self.DFA231_special, transition = self.DFA231_transition ) self.dfa233 = self.DFA233( self, 233, eot = self.DFA233_eot, eof = self.DFA233_eof, min = self.DFA233_min, max = self.DFA233_max, accept = self.DFA233_accept, special = self.DFA233_special, transition = self.DFA233_transition ) self.dfa236 = self.DFA236( self, 236, eot = self.DFA236_eot, eof = self.DFA236_eof, min = self.DFA236_min, max = self.DFA236_max, accept = self.DFA236_accept, special = self.DFA236_special, transition = self.DFA236_transition ) self.dfa237 = self.DFA237( self, 237, eot = self.DFA237_eot, eof = self.DFA237_eof, min = self.DFA237_min, max = self.DFA237_max, accept = self.DFA237_accept, special = self.DFA237_special, transition = self.DFA237_transition ) # $ANTLR start "HEXCHAR" def mHEXCHAR(self, ): try: # lesscss.g:425:25: ( ( 'a' .. 'f' | 'A' .. 'F' | '0' .. '9' ) ) # lesscss.g:425:27: ( 'a' .. 'f' | 'A' .. 'F' | '0' .. '9' ) pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "HEXCHAR" # $ANTLR start "NONASCII" def mNONASCII(self, ): try: # lesscss.g:429:19: ( '\\u0080' .. '\\uFFFF' ) # lesscss.g:429:21: '\\u0080' .. '\\uFFFF' pass self.matchRange(128, 65535) finally: pass # $ANTLR end "NONASCII" # $ANTLR start "UNICODE" def mUNICODE(self, ): try: # lesscss.g:431:18: ( '\\\\' HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? )? ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* ) # lesscss.g:431:20: '\\\\' HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? )? ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass self.match(92) self.mHEXCHAR() # lesscss.g:432:5: ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? )? alt5 = 2 LA5_0 = self.input.LA(1) if ((48 <= LA5_0 <= 57) or (65 <= LA5_0 <= 70) or (97 <= LA5_0 <= 102)) : alt5 = 1 if alt5 == 1: # lesscss.g:432:6: HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? pass self.mHEXCHAR() # lesscss.g:433:6: ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? alt4 = 2 LA4_0 = self.input.LA(1) if ((48 <= LA4_0 <= 57) or (65 <= LA4_0 <= 70) or (97 <= LA4_0 <= 102)) : alt4 = 1 if alt4 == 1: # lesscss.g:433:7: HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? pass self.mHEXCHAR() # lesscss.g:434:7: ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? alt3 = 2 LA3_0 = self.input.LA(1) if ((48 <= LA3_0 <= 57) or (65 <= LA3_0 <= 70) or (97 <= LA3_0 <= 102)) : alt3 = 1 if alt3 == 1: # lesscss.g:434:8: HEXCHAR ( HEXCHAR ( HEXCHAR )? )? pass self.mHEXCHAR() # lesscss.g:435:8: ( HEXCHAR ( HEXCHAR )? )? alt2 = 2 LA2_0 = self.input.LA(1) if ((48 <= LA2_0 <= 57) or (65 <= LA2_0 <= 70) or (97 <= LA2_0 <= 102)) : alt2 = 1 if alt2 == 1: # lesscss.g:435:9: HEXCHAR ( HEXCHAR )? pass self.mHEXCHAR() # lesscss.g:435:17: ( HEXCHAR )? alt1 = 2 LA1_0 = self.input.LA(1) if ((48 <= LA1_0 <= 57) or (65 <= LA1_0 <= 70) or (97 <= LA1_0 <= 102)) : alt1 = 1 if alt1 == 1: # lesscss.g:435:17: HEXCHAR pass self.mHEXCHAR() # lesscss.g:439:5: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if ((9 <= LA6_0 <= 10) or (12 <= LA6_0 <= 13) or LA6_0 == 32) : alt6 = 1 if alt6 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop6 finally: pass # $ANTLR end "UNICODE" # $ANTLR start "ESCAPE" def mESCAPE(self, ): try: # lesscss.g:441:18: ( UNICODE | '\\\\' ~ ( '\\r' | '\\n' | '\\f' | HEXCHAR ) ) alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 92) : LA7_1 = self.input.LA(2) if ((0 <= LA7_1 <= 9) or LA7_1 == 11 or (14 <= LA7_1 <= 47) or (58 <= LA7_1 <= 64) or (71 <= LA7_1 <= 96) or (103 <= LA7_1 <= 65535)) : alt7 = 2 elif ((48 <= LA7_1 <= 57) or (65 <= LA7_1 <= 70) or (97 <= LA7_1 <= 102)) : alt7 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 7, 1, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 7, 0, self.input) raise nvae if alt7 == 1: # lesscss.g:441:20: UNICODE pass self.mUNICODE() elif alt7 == 2: # lesscss.g:441:30: '\\\\' ~ ( '\\r' | '\\n' | '\\f' | HEXCHAR ) pass self.match(92) if (0 <= self.input.LA(1) <= 9) or self.input.LA(1) == 11 or (14 <= self.input.LA(1) <= 47) or (58 <= self.input.LA(1) <= 64) or (71 <= self.input.LA(1) <= 96) or (103 <= self.input.LA(1) <= 65535): self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "ESCAPE" # $ANTLR start "NMSTART" def mNMSTART(self, ): try: # lesscss.g:443:18: ( '_' | 'a' .. 'z' | 'A' .. 'Z' | ESCAPE ) alt8 = 4 LA8 = self.input.LA(1) if LA8 == 95: alt8 = 1 elif LA8 == 97 or LA8 == 98 or LA8 == 99 or LA8 == 100 or LA8 == 101 or LA8 == 102 or LA8 == 103 or LA8 == 104 or LA8 == 105 or LA8 == 106 or LA8 == 107 or LA8 == 108 or LA8 == 109 or LA8 == 110 or LA8 == 111 or LA8 == 112 or LA8 == 113 or LA8 == 114 or LA8 == 115 or LA8 == 116 or LA8 == 117 or LA8 == 118 or LA8 == 119 or LA8 == 120 or LA8 == 121 or LA8 == 122: alt8 = 2 elif LA8 == 65 or LA8 == 66 or LA8 == 67 or LA8 == 68 or LA8 == 69 or LA8 == 70 or LA8 == 71 or LA8 == 72 or LA8 == 73 or LA8 == 74 or LA8 == 75 or LA8 == 76 or LA8 == 77 or LA8 == 78 or LA8 == 79 or LA8 == 80 or LA8 == 81 or LA8 == 82 or LA8 == 83 or LA8 == 84 or LA8 == 85 or LA8 == 86 or LA8 == 87 or LA8 == 88 or LA8 == 89 or LA8 == 90: alt8 = 3 elif LA8 == 92: alt8 = 4 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 8, 0, self.input) raise nvae if alt8 == 1: # lesscss.g:443:20: '_' pass self.match(95) elif alt8 == 2: # lesscss.g:444:6: 'a' .. 'z' pass self.matchRange(97, 122) elif alt8 == 3: # lesscss.g:445:6: 'A' .. 'Z' pass self.matchRange(65, 90) elif alt8 == 4: # lesscss.g:447:6: ESCAPE pass self.mESCAPE() finally: pass # $ANTLR end "NMSTART" # $ANTLR start "NMCHAR" def mNMCHAR(self, ): try: # lesscss.g:450:18: ( '_' | 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '-' | ESCAPE ) alt9 = 6 LA9 = self.input.LA(1) if LA9 == 95: alt9 = 1 elif LA9 == 97 or LA9 == 98 or LA9 == 99 or LA9 == 100 or LA9 == 101 or LA9 == 102 or LA9 == 103 or LA9 == 104 or LA9 == 105 or LA9 == 106 or LA9 == 107 or LA9 == 108 or LA9 == 109 or LA9 == 110 or LA9 == 111 or LA9 == 112 or LA9 == 113 or LA9 == 114 or LA9 == 115 or LA9 == 116 or LA9 == 117 or LA9 == 118 or LA9 == 119 or LA9 == 120 or LA9 == 121 or LA9 == 122: alt9 = 2 elif LA9 == 65 or LA9 == 66 or LA9 == 67 or LA9 == 68 or LA9 == 69 or LA9 == 70 or LA9 == 71 or LA9 == 72 or LA9 == 73 or LA9 == 74 or LA9 == 75 or LA9 == 76 or LA9 == 77 or LA9 == 78 or LA9 == 79 or LA9 == 80 or LA9 == 81 or LA9 == 82 or LA9 == 83 or LA9 == 84 or LA9 == 85 or LA9 == 86 or LA9 == 87 or LA9 == 88 or LA9 == 89 or LA9 == 90: alt9 = 3 elif LA9 == 48 or LA9 == 49 or LA9 == 50 or LA9 == 51 or LA9 == 52 or LA9 == 53 or LA9 == 54 or LA9 == 55 or LA9 == 56 or LA9 == 57: alt9 = 4 elif LA9 == 45: alt9 = 5 elif LA9 == 92: alt9 = 6 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 9, 0, self.input) raise nvae if alt9 == 1: # lesscss.g:450:20: '_' pass self.match(95) elif alt9 == 2: # lesscss.g:451:6: 'a' .. 'z' pass self.matchRange(97, 122) elif alt9 == 3: # lesscss.g:452:6: 'A' .. 'Z' pass self.matchRange(65, 90) elif alt9 == 4: # lesscss.g:453:6: '0' .. '9' pass self.matchRange(48, 57) elif alt9 == 5: # lesscss.g:454:6: '-' pass self.match(45) elif alt9 == 6: # lesscss.g:456:6: ESCAPE pass self.mESCAPE() finally: pass # $ANTLR end "NMCHAR" # $ANTLR start "NAME" def mNAME(self, ): try: # lesscss.g:459:16: ( ( NMCHAR )+ ) # lesscss.g:459:18: ( NMCHAR )+ pass # lesscss.g:459:18: ( NMCHAR )+ cnt10 = 0 while True: #loop10 alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 45 or (48 <= LA10_0 <= 57) or (65 <= LA10_0 <= 90) or LA10_0 == 92 or LA10_0 == 95 or (97 <= LA10_0 <= 122)) : alt10 = 1 if alt10 == 1: # lesscss.g:459:18: NMCHAR pass self.mNMCHAR() else: if cnt10 >= 1: break #loop10 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(10, self.input) raise eee cnt10 += 1 finally: pass # $ANTLR end "NAME" # $ANTLR start "URL" def mURL(self, ): try: # lesscss.g:461:15: ( ( '[' | '!' | '#' | '$' | '%' | '&' | '?' | '*' | '-' | '+' | '~' | '_' | '/' | '.' | ':' | ';' | '=' | ',' | '\\r' | '\\n' | '\\t' | '\\f' | ' ' | 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* ) # lesscss.g:461:17: ( '[' | '!' | '#' | '$' | '%' | '&' | '?' | '*' | '-' | '+' | '~' | '_' | '/' | '.' | ':' | ';' | '=' | ',' | '\\r' | '\\n' | '\\t' | '\\f' | ' ' | 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* pass # lesscss.g:461:17: ( '[' | '!' | '#' | '$' | '%' | '&' | '?' | '*' | '-' | '+' | '~' | '_' | '/' | '.' | ':' | ';' | '=' | ',' | '\\r' | '\\n' | '\\t' | '\\f' | ' ' | 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((9 <= LA11_0 <= 10) or (12 <= LA11_0 <= 13) or (32 <= LA11_0 <= 33) or (35 <= LA11_0 <= 38) or (42 <= LA11_0 <= 59) or LA11_0 == 61 or LA11_0 == 63 or (65 <= LA11_0 <= 91) or LA11_0 == 95 or (97 <= LA11_0 <= 122) or LA11_0 == 126) : alt11 = 1 if alt11 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or (32 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 38) or (42 <= self.input.LA(1) <= 59) or self.input.LA(1) == 61 or self.input.LA(1) == 63 or (65 <= self.input.LA(1) <= 91) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122) or self.input.LA(1) == 126: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop11 finally: pass # $ANTLR end "URL" # $ANTLR start "A" def mA(self, ): try: # lesscss.g:475:12: ( ( 'a' | 'A' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '1' ) alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == 65 or LA17_0 == 97) : alt17 = 1 elif (LA17_0 == 92) : alt17 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 17, 0, self.input) raise nvae if alt17 == 1: # lesscss.g:475:14: ( 'a' | 'A' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 65 or self.input.LA(1) == 97: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:475:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if ((9 <= LA12_0 <= 10) or (12 <= LA12_0 <= 13) or LA12_0 == 32) : alt12 = 1 if alt12 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop12 elif alt17 == 2: # lesscss.g:476:5: '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '1' pass self.match(92) # lesscss.g:476:10: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == 48) : alt16 = 1 if alt16 == 1: # lesscss.g:476:11: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:476:15: ( '0' ( '0' ( '0' )? )? )? alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == 48) : alt15 = 1 if alt15 == 1: # lesscss.g:476:16: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:476:20: ( '0' ( '0' )? )? alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == 48) : alt14 = 1 if alt14 == 1: # lesscss.g:476:21: '0' ( '0' )? pass self.match(48) # lesscss.g:476:25: ( '0' )? alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == 48) : alt13 = 1 if alt13 == 1: # lesscss.g:476:25: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(49) finally: pass # $ANTLR end "A" # $ANTLR start "B" def mB(self, ): try: # lesscss.g:478:12: ( ( 'b' | 'B' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '2' ) alt23 = 2 LA23_0 = self.input.LA(1) if (LA23_0 == 66 or LA23_0 == 98) : alt23 = 1 elif (LA23_0 == 92) : alt23 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 23, 0, self.input) raise nvae if alt23 == 1: # lesscss.g:478:14: ( 'b' | 'B' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 66 or self.input.LA(1) == 98: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:478:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if ((9 <= LA18_0 <= 10) or (12 <= LA18_0 <= 13) or LA18_0 == 32) : alt18 = 1 if alt18 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop18 elif alt23 == 2: # lesscss.g:479:5: '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '2' pass self.match(92) # lesscss.g:479:10: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == 48) : alt22 = 1 if alt22 == 1: # lesscss.g:479:11: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:479:15: ( '0' ( '0' ( '0' )? )? )? alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == 48) : alt21 = 1 if alt21 == 1: # lesscss.g:479:16: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:479:20: ( '0' ( '0' )? )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == 48) : alt20 = 1 if alt20 == 1: # lesscss.g:479:21: '0' ( '0' )? pass self.match(48) # lesscss.g:479:25: ( '0' )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == 48) : alt19 = 1 if alt19 == 1: # lesscss.g:479:25: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(50) finally: pass # $ANTLR end "B" # $ANTLR start "C" def mC(self, ): try: # lesscss.g:481:12: ( ( 'c' | 'C' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '3' ) alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == 67 or LA29_0 == 99) : alt29 = 1 elif (LA29_0 == 92) : alt29 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 29, 0, self.input) raise nvae if alt29 == 1: # lesscss.g:481:14: ( 'c' | 'C' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 67 or self.input.LA(1) == 99: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:481:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop24 alt24 = 2 LA24_0 = self.input.LA(1) if ((9 <= LA24_0 <= 10) or (12 <= LA24_0 <= 13) or LA24_0 == 32) : alt24 = 1 if alt24 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop24 elif alt29 == 2: # lesscss.g:482:5: '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '3' pass self.match(92) # lesscss.g:482:10: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == 48) : alt28 = 1 if alt28 == 1: # lesscss.g:482:11: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:482:15: ( '0' ( '0' ( '0' )? )? )? alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == 48) : alt27 = 1 if alt27 == 1: # lesscss.g:482:16: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:482:20: ( '0' ( '0' )? )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == 48) : alt26 = 1 if alt26 == 1: # lesscss.g:482:21: '0' ( '0' )? pass self.match(48) # lesscss.g:482:25: ( '0' )? alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == 48) : alt25 = 1 if alt25 == 1: # lesscss.g:482:25: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(51) finally: pass # $ANTLR end "C" # $ANTLR start "D" def mD(self, ): try: # lesscss.g:484:12: ( ( 'd' | 'D' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '4' ) alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == 68 or LA35_0 == 100) : alt35 = 1 elif (LA35_0 == 92) : alt35 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 35, 0, self.input) raise nvae if alt35 == 1: # lesscss.g:484:14: ( 'd' | 'D' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 68 or self.input.LA(1) == 100: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:484:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop30 alt30 = 2 LA30_0 = self.input.LA(1) if ((9 <= LA30_0 <= 10) or (12 <= LA30_0 <= 13) or LA30_0 == 32) : alt30 = 1 if alt30 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop30 elif alt35 == 2: # lesscss.g:485:5: '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '4' pass self.match(92) # lesscss.g:485:10: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == 48) : alt34 = 1 if alt34 == 1: # lesscss.g:485:11: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:485:15: ( '0' ( '0' ( '0' )? )? )? alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == 48) : alt33 = 1 if alt33 == 1: # lesscss.g:485:16: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:485:20: ( '0' ( '0' )? )? alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == 48) : alt32 = 1 if alt32 == 1: # lesscss.g:485:21: '0' ( '0' )? pass self.match(48) # lesscss.g:485:25: ( '0' )? alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == 48) : alt31 = 1 if alt31 == 1: # lesscss.g:485:25: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(52) finally: pass # $ANTLR end "D" # $ANTLR start "E" def mE(self, ): try: # lesscss.g:487:12: ( ( 'e' | 'E' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '5' ) alt41 = 2 LA41_0 = self.input.LA(1) if (LA41_0 == 69 or LA41_0 == 101) : alt41 = 1 elif (LA41_0 == 92) : alt41 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 41, 0, self.input) raise nvae if alt41 == 1: # lesscss.g:487:14: ( 'e' | 'E' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 69 or self.input.LA(1) == 101: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:487:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop36 alt36 = 2 LA36_0 = self.input.LA(1) if ((9 <= LA36_0 <= 10) or (12 <= LA36_0 <= 13) or LA36_0 == 32) : alt36 = 1 if alt36 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop36 elif alt41 == 2: # lesscss.g:488:5: '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '5' pass self.match(92) # lesscss.g:488:10: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt40 = 2 LA40_0 = self.input.LA(1) if (LA40_0 == 48) : alt40 = 1 if alt40 == 1: # lesscss.g:488:11: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:488:15: ( '0' ( '0' ( '0' )? )? )? alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == 48) : alt39 = 1 if alt39 == 1: # lesscss.g:488:16: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:488:20: ( '0' ( '0' )? )? alt38 = 2 LA38_0 = self.input.LA(1) if (LA38_0 == 48) : alt38 = 1 if alt38 == 1: # lesscss.g:488:21: '0' ( '0' )? pass self.match(48) # lesscss.g:488:25: ( '0' )? alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == 48) : alt37 = 1 if alt37 == 1: # lesscss.g:488:25: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(53) finally: pass # $ANTLR end "E" # $ANTLR start "F" def mF(self, ): try: # lesscss.g:490:12: ( ( 'f' | 'F' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '6' ) alt47 = 2 LA47_0 = self.input.LA(1) if (LA47_0 == 70 or LA47_0 == 102) : alt47 = 1 elif (LA47_0 == 92) : alt47 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 47, 0, self.input) raise nvae if alt47 == 1: # lesscss.g:490:14: ( 'f' | 'F' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 70 or self.input.LA(1) == 102: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:490:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop42 alt42 = 2 LA42_0 = self.input.LA(1) if ((9 <= LA42_0 <= 10) or (12 <= LA42_0 <= 13) or LA42_0 == 32) : alt42 = 1 if alt42 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop42 elif alt47 == 2: # lesscss.g:491:5: '\\\\' ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '6' pass self.match(92) # lesscss.g:491:10: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt46 = 2 LA46_0 = self.input.LA(1) if (LA46_0 == 48) : alt46 = 1 if alt46 == 1: # lesscss.g:491:11: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:491:15: ( '0' ( '0' ( '0' )? )? )? alt45 = 2 LA45_0 = self.input.LA(1) if (LA45_0 == 48) : alt45 = 1 if alt45 == 1: # lesscss.g:491:16: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:491:20: ( '0' ( '0' )? )? alt44 = 2 LA44_0 = self.input.LA(1) if (LA44_0 == 48) : alt44 = 1 if alt44 == 1: # lesscss.g:491:21: '0' ( '0' )? pass self.match(48) # lesscss.g:491:25: ( '0' )? alt43 = 2 LA43_0 = self.input.LA(1) if (LA43_0 == 48) : alt43 = 1 if alt43 == 1: # lesscss.g:491:25: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(54) finally: pass # $ANTLR end "F" # $ANTLR start "G" def mG(self, ): try: # lesscss.g:493:12: ( ( 'g' | 'G' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'g' | 'G' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '7' ) ) alt54 = 2 LA54_0 = self.input.LA(1) if (LA54_0 == 71 or LA54_0 == 103) : alt54 = 1 elif (LA54_0 == 92) : alt54 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 54, 0, self.input) raise nvae if alt54 == 1: # lesscss.g:493:14: ( 'g' | 'G' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 71 or self.input.LA(1) == 103: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:493:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop48 alt48 = 2 LA48_0 = self.input.LA(1) if ((9 <= LA48_0 <= 10) or (12 <= LA48_0 <= 13) or LA48_0 == 32) : alt48 = 1 if alt48 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop48 elif alt54 == 2: # lesscss.g:494:5: '\\\\' ( 'g' | 'G' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '7' ) pass self.match(92) # lesscss.g:495:3: ( 'g' | 'G' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '7' ) alt53 = 3 LA53 = self.input.LA(1) if LA53 == 103: alt53 = 1 elif LA53 == 71: alt53 = 2 elif LA53 == 48 or LA53 == 52 or LA53 == 54: alt53 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 53, 0, self.input) raise nvae if alt53 == 1: # lesscss.g:496:5: 'g' pass self.match(103) elif alt53 == 2: # lesscss.g:497:6: 'G' pass self.match(71) elif alt53 == 3: # lesscss.g:498:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '7' pass # lesscss.g:498:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt52 = 2 LA52_0 = self.input.LA(1) if (LA52_0 == 48) : alt52 = 1 if alt52 == 1: # lesscss.g:498:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:498:11: ( '0' ( '0' ( '0' )? )? )? alt51 = 2 LA51_0 = self.input.LA(1) if (LA51_0 == 48) : alt51 = 1 if alt51 == 1: # lesscss.g:498:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:498:16: ( '0' ( '0' )? )? alt50 = 2 LA50_0 = self.input.LA(1) if (LA50_0 == 48) : alt50 = 1 if alt50 == 1: # lesscss.g:498:17: '0' ( '0' )? pass self.match(48) # lesscss.g:498:21: ( '0' )? alt49 = 2 LA49_0 = self.input.LA(1) if (LA49_0 == 48) : alt49 = 1 if alt49 == 1: # lesscss.g:498:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(55) finally: pass # $ANTLR end "G" # $ANTLR start "H" def mH(self, ): try: # lesscss.g:501:12: ( ( 'h' | 'H' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'h' | 'H' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '8' ) ) alt61 = 2 LA61_0 = self.input.LA(1) if (LA61_0 == 72 or LA61_0 == 104) : alt61 = 1 elif (LA61_0 == 92) : alt61 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 61, 0, self.input) raise nvae if alt61 == 1: # lesscss.g:501:14: ( 'h' | 'H' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 72 or self.input.LA(1) == 104: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:501:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop55 alt55 = 2 LA55_0 = self.input.LA(1) if ((9 <= LA55_0 <= 10) or (12 <= LA55_0 <= 13) or LA55_0 == 32) : alt55 = 1 if alt55 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop55 elif alt61 == 2: # lesscss.g:502:5: '\\\\' ( 'h' | 'H' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '8' ) pass self.match(92) # lesscss.g:503:3: ( 'h' | 'H' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '8' ) alt60 = 3 LA60 = self.input.LA(1) if LA60 == 104: alt60 = 1 elif LA60 == 72: alt60 = 2 elif LA60 == 48 or LA60 == 52 or LA60 == 54: alt60 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 60, 0, self.input) raise nvae if alt60 == 1: # lesscss.g:504:6: 'h' pass self.match(104) elif alt60 == 2: # lesscss.g:505:6: 'H' pass self.match(72) elif alt60 == 3: # lesscss.g:506:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '8' pass # lesscss.g:506:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt59 = 2 LA59_0 = self.input.LA(1) if (LA59_0 == 48) : alt59 = 1 if alt59 == 1: # lesscss.g:506:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:506:11: ( '0' ( '0' ( '0' )? )? )? alt58 = 2 LA58_0 = self.input.LA(1) if (LA58_0 == 48) : alt58 = 1 if alt58 == 1: # lesscss.g:506:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:506:16: ( '0' ( '0' )? )? alt57 = 2 LA57_0 = self.input.LA(1) if (LA57_0 == 48) : alt57 = 1 if alt57 == 1: # lesscss.g:506:17: '0' ( '0' )? pass self.match(48) # lesscss.g:506:21: ( '0' )? alt56 = 2 LA56_0 = self.input.LA(1) if (LA56_0 == 48) : alt56 = 1 if alt56 == 1: # lesscss.g:506:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(56) finally: pass # $ANTLR end "H" # $ANTLR start "I" def mI(self, ): try: # lesscss.g:509:12: ( ( 'i' | 'I' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'i' | 'I' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '9' ) ) alt68 = 2 LA68_0 = self.input.LA(1) if (LA68_0 == 73 or LA68_0 == 105) : alt68 = 1 elif (LA68_0 == 92) : alt68 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 68, 0, self.input) raise nvae if alt68 == 1: # lesscss.g:509:14: ( 'i' | 'I' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 73 or self.input.LA(1) == 105: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:509:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop62 alt62 = 2 LA62_0 = self.input.LA(1) if ((9 <= LA62_0 <= 10) or (12 <= LA62_0 <= 13) or LA62_0 == 32) : alt62 = 1 if alt62 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop62 elif alt68 == 2: # lesscss.g:510:5: '\\\\' ( 'i' | 'I' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '9' ) pass self.match(92) # lesscss.g:511:3: ( 'i' | 'I' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '9' ) alt67 = 3 LA67 = self.input.LA(1) if LA67 == 105: alt67 = 1 elif LA67 == 73: alt67 = 2 elif LA67 == 48 or LA67 == 52 or LA67 == 54: alt67 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 67, 0, self.input) raise nvae if alt67 == 1: # lesscss.g:512:6: 'i' pass self.match(105) elif alt67 == 2: # lesscss.g:513:6: 'I' pass self.match(73) elif alt67 == 3: # lesscss.g:514:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) '9' pass # lesscss.g:514:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt66 = 2 LA66_0 = self.input.LA(1) if (LA66_0 == 48) : alt66 = 1 if alt66 == 1: # lesscss.g:514:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:514:11: ( '0' ( '0' ( '0' )? )? )? alt65 = 2 LA65_0 = self.input.LA(1) if (LA65_0 == 48) : alt65 = 1 if alt65 == 1: # lesscss.g:514:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:514:16: ( '0' ( '0' )? )? alt64 = 2 LA64_0 = self.input.LA(1) if (LA64_0 == 48) : alt64 = 1 if alt64 == 1: # lesscss.g:514:17: '0' ( '0' )? pass self.match(48) # lesscss.g:514:21: ( '0' )? alt63 = 2 LA63_0 = self.input.LA(1) if (LA63_0 == 48) : alt63 = 1 if alt63 == 1: # lesscss.g:514:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(57) finally: pass # $ANTLR end "I" # $ANTLR start "J" def mJ(self, ): try: # lesscss.g:517:12: ( ( 'j' | 'J' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'j' | 'J' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'A' | 'a' ) ) ) alt75 = 2 LA75_0 = self.input.LA(1) if (LA75_0 == 74 or LA75_0 == 106) : alt75 = 1 elif (LA75_0 == 92) : alt75 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 75, 0, self.input) raise nvae if alt75 == 1: # lesscss.g:517:14: ( 'j' | 'J' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 74 or self.input.LA(1) == 106: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:517:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop69 alt69 = 2 LA69_0 = self.input.LA(1) if ((9 <= LA69_0 <= 10) or (12 <= LA69_0 <= 13) or LA69_0 == 32) : alt69 = 1 if alt69 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop69 elif alt75 == 2: # lesscss.g:518:5: '\\\\' ( 'j' | 'J' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'A' | 'a' ) ) pass self.match(92) # lesscss.g:519:3: ( 'j' | 'J' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'A' | 'a' ) ) alt74 = 3 LA74 = self.input.LA(1) if LA74 == 106: alt74 = 1 elif LA74 == 74: alt74 = 2 elif LA74 == 48 or LA74 == 52 or LA74 == 54: alt74 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 74, 0, self.input) raise nvae if alt74 == 1: # lesscss.g:520:6: 'j' pass self.match(106) elif alt74 == 2: # lesscss.g:521:6: 'J' pass self.match(74) elif alt74 == 3: # lesscss.g:522:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'A' | 'a' ) pass # lesscss.g:522:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt73 = 2 LA73_0 = self.input.LA(1) if (LA73_0 == 48) : alt73 = 1 if alt73 == 1: # lesscss.g:522:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:522:11: ( '0' ( '0' ( '0' )? )? )? alt72 = 2 LA72_0 = self.input.LA(1) if (LA72_0 == 48) : alt72 = 1 if alt72 == 1: # lesscss.g:522:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:522:16: ( '0' ( '0' )? )? alt71 = 2 LA71_0 = self.input.LA(1) if (LA71_0 == 48) : alt71 = 1 if alt71 == 1: # lesscss.g:522:17: '0' ( '0' )? pass self.match(48) # lesscss.g:522:21: ( '0' )? alt70 = 2 LA70_0 = self.input.LA(1) if (LA70_0 == 48) : alt70 = 1 if alt70 == 1: # lesscss.g:522:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == 65 or self.input.LA(1) == 97: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "J" # $ANTLR start "K" def mK(self, ): try: # lesscss.g:525:12: ( ( 'k' | 'K' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'k' | 'K' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'B' | 'b' ) ) ) alt82 = 2 LA82_0 = self.input.LA(1) if (LA82_0 == 75 or LA82_0 == 107) : alt82 = 1 elif (LA82_0 == 92) : alt82 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 82, 0, self.input) raise nvae if alt82 == 1: # lesscss.g:525:14: ( 'k' | 'K' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 75 or self.input.LA(1) == 107: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:525:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop76 alt76 = 2 LA76_0 = self.input.LA(1) if ((9 <= LA76_0 <= 10) or (12 <= LA76_0 <= 13) or LA76_0 == 32) : alt76 = 1 if alt76 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop76 elif alt82 == 2: # lesscss.g:526:5: '\\\\' ( 'k' | 'K' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'B' | 'b' ) ) pass self.match(92) # lesscss.g:527:3: ( 'k' | 'K' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'B' | 'b' ) ) alt81 = 3 LA81 = self.input.LA(1) if LA81 == 107: alt81 = 1 elif LA81 == 75: alt81 = 2 elif LA81 == 48 or LA81 == 52 or LA81 == 54: alt81 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 81, 0, self.input) raise nvae if alt81 == 1: # lesscss.g:528:6: 'k' pass self.match(107) elif alt81 == 2: # lesscss.g:529:6: 'K' pass self.match(75) elif alt81 == 3: # lesscss.g:530:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'B' | 'b' ) pass # lesscss.g:530:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt80 = 2 LA80_0 = self.input.LA(1) if (LA80_0 == 48) : alt80 = 1 if alt80 == 1: # lesscss.g:530:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:530:11: ( '0' ( '0' ( '0' )? )? )? alt79 = 2 LA79_0 = self.input.LA(1) if (LA79_0 == 48) : alt79 = 1 if alt79 == 1: # lesscss.g:530:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:530:16: ( '0' ( '0' )? )? alt78 = 2 LA78_0 = self.input.LA(1) if (LA78_0 == 48) : alt78 = 1 if alt78 == 1: # lesscss.g:530:17: '0' ( '0' )? pass self.match(48) # lesscss.g:530:21: ( '0' )? alt77 = 2 LA77_0 = self.input.LA(1) if (LA77_0 == 48) : alt77 = 1 if alt77 == 1: # lesscss.g:530:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == 66 or self.input.LA(1) == 98: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "K" # $ANTLR start "L" def mL(self, ): try: # lesscss.g:533:12: ( ( 'l' | 'L' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'l' | 'L' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'C' | 'c' ) ) ) alt89 = 2 LA89_0 = self.input.LA(1) if (LA89_0 == 76 or LA89_0 == 108) : alt89 = 1 elif (LA89_0 == 92) : alt89 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 89, 0, self.input) raise nvae if alt89 == 1: # lesscss.g:533:14: ( 'l' | 'L' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 76 or self.input.LA(1) == 108: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:533:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop83 alt83 = 2 LA83_0 = self.input.LA(1) if ((9 <= LA83_0 <= 10) or (12 <= LA83_0 <= 13) or LA83_0 == 32) : alt83 = 1 if alt83 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop83 elif alt89 == 2: # lesscss.g:534:5: '\\\\' ( 'l' | 'L' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'C' | 'c' ) ) pass self.match(92) # lesscss.g:535:3: ( 'l' | 'L' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'C' | 'c' ) ) alt88 = 3 LA88 = self.input.LA(1) if LA88 == 108: alt88 = 1 elif LA88 == 76: alt88 = 2 elif LA88 == 48 or LA88 == 52 or LA88 == 54: alt88 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 88, 0, self.input) raise nvae if alt88 == 1: # lesscss.g:536:6: 'l' pass self.match(108) elif alt88 == 2: # lesscss.g:537:6: 'L' pass self.match(76) elif alt88 == 3: # lesscss.g:538:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'C' | 'c' ) pass # lesscss.g:538:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt87 = 2 LA87_0 = self.input.LA(1) if (LA87_0 == 48) : alt87 = 1 if alt87 == 1: # lesscss.g:538:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:538:11: ( '0' ( '0' ( '0' )? )? )? alt86 = 2 LA86_0 = self.input.LA(1) if (LA86_0 == 48) : alt86 = 1 if alt86 == 1: # lesscss.g:538:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:538:16: ( '0' ( '0' )? )? alt85 = 2 LA85_0 = self.input.LA(1) if (LA85_0 == 48) : alt85 = 1 if alt85 == 1: # lesscss.g:538:17: '0' ( '0' )? pass self.match(48) # lesscss.g:538:21: ( '0' )? alt84 = 2 LA84_0 = self.input.LA(1) if (LA84_0 == 48) : alt84 = 1 if alt84 == 1: # lesscss.g:538:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == 67 or self.input.LA(1) == 99: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "L" # $ANTLR start "M" def mM(self, ): try: # lesscss.g:541:12: ( ( 'm' | 'M' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'm' | 'M' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'D' | 'd' ) ) ) alt96 = 2 LA96_0 = self.input.LA(1) if (LA96_0 == 77 or LA96_0 == 109) : alt96 = 1 elif (LA96_0 == 92) : alt96 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 96, 0, self.input) raise nvae if alt96 == 1: # lesscss.g:541:14: ( 'm' | 'M' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 77 or self.input.LA(1) == 109: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:541:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop90 alt90 = 2 LA90_0 = self.input.LA(1) if ((9 <= LA90_0 <= 10) or (12 <= LA90_0 <= 13) or LA90_0 == 32) : alt90 = 1 if alt90 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop90 elif alt96 == 2: # lesscss.g:542:5: '\\\\' ( 'm' | 'M' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'D' | 'd' ) ) pass self.match(92) # lesscss.g:543:3: ( 'm' | 'M' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'D' | 'd' ) ) alt95 = 3 LA95 = self.input.LA(1) if LA95 == 109: alt95 = 1 elif LA95 == 77: alt95 = 2 elif LA95 == 48 or LA95 == 52 or LA95 == 54: alt95 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 95, 0, self.input) raise nvae if alt95 == 1: # lesscss.g:544:6: 'm' pass self.match(109) elif alt95 == 2: # lesscss.g:545:6: 'M' pass self.match(77) elif alt95 == 3: # lesscss.g:546:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'D' | 'd' ) pass # lesscss.g:546:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt94 = 2 LA94_0 = self.input.LA(1) if (LA94_0 == 48) : alt94 = 1 if alt94 == 1: # lesscss.g:546:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:546:11: ( '0' ( '0' ( '0' )? )? )? alt93 = 2 LA93_0 = self.input.LA(1) if (LA93_0 == 48) : alt93 = 1 if alt93 == 1: # lesscss.g:546:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:546:16: ( '0' ( '0' )? )? alt92 = 2 LA92_0 = self.input.LA(1) if (LA92_0 == 48) : alt92 = 1 if alt92 == 1: # lesscss.g:546:17: '0' ( '0' )? pass self.match(48) # lesscss.g:546:21: ( '0' )? alt91 = 2 LA91_0 = self.input.LA(1) if (LA91_0 == 48) : alt91 = 1 if alt91 == 1: # lesscss.g:546:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == 68 or self.input.LA(1) == 100: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "M" # $ANTLR start "N" def mN(self, ): try: # lesscss.g:549:12: ( ( 'n' | 'N' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'n' | 'N' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'E' | 'e' ) ) ) alt103 = 2 LA103_0 = self.input.LA(1) if (LA103_0 == 78 or LA103_0 == 110) : alt103 = 1 elif (LA103_0 == 92) : alt103 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 103, 0, self.input) raise nvae if alt103 == 1: # lesscss.g:549:14: ( 'n' | 'N' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 78 or self.input.LA(1) == 110: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:549:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop97 alt97 = 2 LA97_0 = self.input.LA(1) if ((9 <= LA97_0 <= 10) or (12 <= LA97_0 <= 13) or LA97_0 == 32) : alt97 = 1 if alt97 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop97 elif alt103 == 2: # lesscss.g:550:5: '\\\\' ( 'n' | 'N' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'E' | 'e' ) ) pass self.match(92) # lesscss.g:551:3: ( 'n' | 'N' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'E' | 'e' ) ) alt102 = 3 LA102 = self.input.LA(1) if LA102 == 110: alt102 = 1 elif LA102 == 78: alt102 = 2 elif LA102 == 48 or LA102 == 52 or LA102 == 54: alt102 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 102, 0, self.input) raise nvae if alt102 == 1: # lesscss.g:552:6: 'n' pass self.match(110) elif alt102 == 2: # lesscss.g:553:6: 'N' pass self.match(78) elif alt102 == 3: # lesscss.g:554:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'E' | 'e' ) pass # lesscss.g:554:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt101 = 2 LA101_0 = self.input.LA(1) if (LA101_0 == 48) : alt101 = 1 if alt101 == 1: # lesscss.g:554:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:554:11: ( '0' ( '0' ( '0' )? )? )? alt100 = 2 LA100_0 = self.input.LA(1) if (LA100_0 == 48) : alt100 = 1 if alt100 == 1: # lesscss.g:554:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:554:16: ( '0' ( '0' )? )? alt99 = 2 LA99_0 = self.input.LA(1) if (LA99_0 == 48) : alt99 = 1 if alt99 == 1: # lesscss.g:554:17: '0' ( '0' )? pass self.match(48) # lesscss.g:554:21: ( '0' )? alt98 = 2 LA98_0 = self.input.LA(1) if (LA98_0 == 48) : alt98 = 1 if alt98 == 1: # lesscss.g:554:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == 69 or self.input.LA(1) == 101: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "N" # $ANTLR start "O" def mO(self, ): try: # lesscss.g:557:12: ( ( 'o' | 'O' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'o' | 'O' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'F' | 'f' ) ) ) alt110 = 2 LA110_0 = self.input.LA(1) if (LA110_0 == 79 or LA110_0 == 111) : alt110 = 1 elif (LA110_0 == 92) : alt110 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 110, 0, self.input) raise nvae if alt110 == 1: # lesscss.g:557:14: ( 'o' | 'O' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 79 or self.input.LA(1) == 111: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:557:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop104 alt104 = 2 LA104_0 = self.input.LA(1) if ((9 <= LA104_0 <= 10) or (12 <= LA104_0 <= 13) or LA104_0 == 32) : alt104 = 1 if alt104 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop104 elif alt110 == 2: # lesscss.g:558:5: '\\\\' ( 'o' | 'O' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'F' | 'f' ) ) pass self.match(92) # lesscss.g:559:3: ( 'o' | 'O' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'F' | 'f' ) ) alt109 = 3 LA109 = self.input.LA(1) if LA109 == 111: alt109 = 1 elif LA109 == 79: alt109 = 2 elif LA109 == 48 or LA109 == 52 or LA109 == 54: alt109 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 109, 0, self.input) raise nvae if alt109 == 1: # lesscss.g:560:6: 'o' pass self.match(111) elif alt109 == 2: # lesscss.g:561:6: 'O' pass self.match(79) elif alt109 == 3: # lesscss.g:562:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '4' | '6' ) ( 'F' | 'f' ) pass # lesscss.g:562:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt108 = 2 LA108_0 = self.input.LA(1) if (LA108_0 == 48) : alt108 = 1 if alt108 == 1: # lesscss.g:562:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:562:11: ( '0' ( '0' ( '0' )? )? )? alt107 = 2 LA107_0 = self.input.LA(1) if (LA107_0 == 48) : alt107 = 1 if alt107 == 1: # lesscss.g:562:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:562:16: ( '0' ( '0' )? )? alt106 = 2 LA106_0 = self.input.LA(1) if (LA106_0 == 48) : alt106 = 1 if alt106 == 1: # lesscss.g:562:17: '0' ( '0' )? pass self.match(48) # lesscss.g:562:21: ( '0' )? alt105 = 2 LA105_0 = self.input.LA(1) if (LA105_0 == 48) : alt105 = 1 if alt105 == 1: # lesscss.g:562:21: '0' pass self.match(48) if self.input.LA(1) == 52 or self.input.LA(1) == 54: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == 70 or self.input.LA(1) == 102: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "O" # $ANTLR start "P" def mP(self, ): try: # lesscss.g:565:12: ( ( 'p' | 'P' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'p' | 'P' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '0' ) ) ) alt117 = 2 LA117_0 = self.input.LA(1) if (LA117_0 == 80 or LA117_0 == 112) : alt117 = 1 elif (LA117_0 == 92) : alt117 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 117, 0, self.input) raise nvae if alt117 == 1: # lesscss.g:565:14: ( 'p' | 'P' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 80 or self.input.LA(1) == 112: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:565:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop111 alt111 = 2 LA111_0 = self.input.LA(1) if ((9 <= LA111_0 <= 10) or (12 <= LA111_0 <= 13) or LA111_0 == 32) : alt111 = 1 if alt111 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop111 elif alt117 == 2: # lesscss.g:566:5: '\\\\' ( 'p' | 'P' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '0' ) ) pass self.match(92) # lesscss.g:567:3: ( 'p' | 'P' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '0' ) ) alt116 = 3 LA116 = self.input.LA(1) if LA116 == 112: alt116 = 1 elif LA116 == 80: alt116 = 2 elif LA116 == 48 or LA116 == 53 or LA116 == 55: alt116 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 116, 0, self.input) raise nvae if alt116 == 1: # lesscss.g:568:6: 'p' pass self.match(112) elif alt116 == 2: # lesscss.g:569:6: 'P' pass self.match(80) elif alt116 == 3: # lesscss.g:570:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '0' ) pass # lesscss.g:570:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt115 = 2 LA115_0 = self.input.LA(1) if (LA115_0 == 48) : alt115 = 1 if alt115 == 1: # lesscss.g:570:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:570:11: ( '0' ( '0' ( '0' )? )? )? alt114 = 2 LA114_0 = self.input.LA(1) if (LA114_0 == 48) : alt114 = 1 if alt114 == 1: # lesscss.g:570:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:570:16: ( '0' ( '0' )? )? alt113 = 2 LA113_0 = self.input.LA(1) if (LA113_0 == 48) : alt113 = 1 if alt113 == 1: # lesscss.g:570:17: '0' ( '0' )? pass self.match(48) # lesscss.g:570:21: ( '0' )? alt112 = 2 LA112_0 = self.input.LA(1) if (LA112_0 == 48) : alt112 = 1 if alt112 == 1: # lesscss.g:570:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:570:41: ( '0' ) # lesscss.g:570:42: '0' pass self.match(48) finally: pass # $ANTLR end "P" # $ANTLR start "Q" def mQ(self, ): try: # lesscss.g:573:12: ( ( 'q' | 'Q' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'q' | 'Q' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '1' ) ) ) alt124 = 2 LA124_0 = self.input.LA(1) if (LA124_0 == 81 or LA124_0 == 113) : alt124 = 1 elif (LA124_0 == 92) : alt124 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 124, 0, self.input) raise nvae if alt124 == 1: # lesscss.g:573:14: ( 'q' | 'Q' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 81 or self.input.LA(1) == 113: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:573:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop118 alt118 = 2 LA118_0 = self.input.LA(1) if ((9 <= LA118_0 <= 10) or (12 <= LA118_0 <= 13) or LA118_0 == 32) : alt118 = 1 if alt118 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop118 elif alt124 == 2: # lesscss.g:574:5: '\\\\' ( 'q' | 'Q' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '1' ) ) pass self.match(92) # lesscss.g:575:3: ( 'q' | 'Q' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '1' ) ) alt123 = 3 LA123 = self.input.LA(1) if LA123 == 113: alt123 = 1 elif LA123 == 81: alt123 = 2 elif LA123 == 48 or LA123 == 53 or LA123 == 55: alt123 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 123, 0, self.input) raise nvae if alt123 == 1: # lesscss.g:576:6: 'q' pass self.match(113) elif alt123 == 2: # lesscss.g:577:6: 'Q' pass self.match(81) elif alt123 == 3: # lesscss.g:578:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '1' ) pass # lesscss.g:578:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt122 = 2 LA122_0 = self.input.LA(1) if (LA122_0 == 48) : alt122 = 1 if alt122 == 1: # lesscss.g:578:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:578:11: ( '0' ( '0' ( '0' )? )? )? alt121 = 2 LA121_0 = self.input.LA(1) if (LA121_0 == 48) : alt121 = 1 if alt121 == 1: # lesscss.g:578:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:578:16: ( '0' ( '0' )? )? alt120 = 2 LA120_0 = self.input.LA(1) if (LA120_0 == 48) : alt120 = 1 if alt120 == 1: # lesscss.g:578:17: '0' ( '0' )? pass self.match(48) # lesscss.g:578:21: ( '0' )? alt119 = 2 LA119_0 = self.input.LA(1) if (LA119_0 == 48) : alt119 = 1 if alt119 == 1: # lesscss.g:578:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:578:41: ( '1' ) # lesscss.g:578:42: '1' pass self.match(49) finally: pass # $ANTLR end "Q" # $ANTLR start "R" def mR(self, ): try: # lesscss.g:581:12: ( ( 'r' | 'R' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'r' | 'R' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '2' ) ) ) alt131 = 2 LA131_0 = self.input.LA(1) if (LA131_0 == 82 or LA131_0 == 114) : alt131 = 1 elif (LA131_0 == 92) : alt131 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 131, 0, self.input) raise nvae if alt131 == 1: # lesscss.g:581:14: ( 'r' | 'R' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 82 or self.input.LA(1) == 114: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:581:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop125 alt125 = 2 LA125_0 = self.input.LA(1) if ((9 <= LA125_0 <= 10) or (12 <= LA125_0 <= 13) or LA125_0 == 32) : alt125 = 1 if alt125 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop125 elif alt131 == 2: # lesscss.g:582:5: '\\\\' ( 'r' | 'R' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '2' ) ) pass self.match(92) # lesscss.g:583:3: ( 'r' | 'R' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '2' ) ) alt130 = 3 LA130 = self.input.LA(1) if LA130 == 114: alt130 = 1 elif LA130 == 82: alt130 = 2 elif LA130 == 48 or LA130 == 53 or LA130 == 55: alt130 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 130, 0, self.input) raise nvae if alt130 == 1: # lesscss.g:584:6: 'r' pass self.match(114) elif alt130 == 2: # lesscss.g:585:6: 'R' pass self.match(82) elif alt130 == 3: # lesscss.g:586:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '2' ) pass # lesscss.g:586:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt129 = 2 LA129_0 = self.input.LA(1) if (LA129_0 == 48) : alt129 = 1 if alt129 == 1: # lesscss.g:586:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:586:11: ( '0' ( '0' ( '0' )? )? )? alt128 = 2 LA128_0 = self.input.LA(1) if (LA128_0 == 48) : alt128 = 1 if alt128 == 1: # lesscss.g:586:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:586:16: ( '0' ( '0' )? )? alt127 = 2 LA127_0 = self.input.LA(1) if (LA127_0 == 48) : alt127 = 1 if alt127 == 1: # lesscss.g:586:17: '0' ( '0' )? pass self.match(48) # lesscss.g:586:21: ( '0' )? alt126 = 2 LA126_0 = self.input.LA(1) if (LA126_0 == 48) : alt126 = 1 if alt126 == 1: # lesscss.g:586:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:586:41: ( '2' ) # lesscss.g:586:42: '2' pass self.match(50) finally: pass # $ANTLR end "R" # $ANTLR start "S" def mS(self, ): try: # lesscss.g:589:12: ( ( 's' | 'S' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 's' | 'S' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '3' ) ) ) alt138 = 2 LA138_0 = self.input.LA(1) if (LA138_0 == 83 or LA138_0 == 115) : alt138 = 1 elif (LA138_0 == 92) : alt138 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 138, 0, self.input) raise nvae if alt138 == 1: # lesscss.g:589:14: ( 's' | 'S' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 83 or self.input.LA(1) == 115: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:589:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop132 alt132 = 2 LA132_0 = self.input.LA(1) if ((9 <= LA132_0 <= 10) or (12 <= LA132_0 <= 13) or LA132_0 == 32) : alt132 = 1 if alt132 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop132 elif alt138 == 2: # lesscss.g:590:5: '\\\\' ( 's' | 'S' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '3' ) ) pass self.match(92) # lesscss.g:591:3: ( 's' | 'S' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '3' ) ) alt137 = 3 LA137 = self.input.LA(1) if LA137 == 115: alt137 = 1 elif LA137 == 83: alt137 = 2 elif LA137 == 48 or LA137 == 53 or LA137 == 55: alt137 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 137, 0, self.input) raise nvae if alt137 == 1: # lesscss.g:592:6: 's' pass self.match(115) elif alt137 == 2: # lesscss.g:593:6: 'S' pass self.match(83) elif alt137 == 3: # lesscss.g:594:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '3' ) pass # lesscss.g:594:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt136 = 2 LA136_0 = self.input.LA(1) if (LA136_0 == 48) : alt136 = 1 if alt136 == 1: # lesscss.g:594:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:594:11: ( '0' ( '0' ( '0' )? )? )? alt135 = 2 LA135_0 = self.input.LA(1) if (LA135_0 == 48) : alt135 = 1 if alt135 == 1: # lesscss.g:594:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:594:16: ( '0' ( '0' )? )? alt134 = 2 LA134_0 = self.input.LA(1) if (LA134_0 == 48) : alt134 = 1 if alt134 == 1: # lesscss.g:594:17: '0' ( '0' )? pass self.match(48) # lesscss.g:594:21: ( '0' )? alt133 = 2 LA133_0 = self.input.LA(1) if (LA133_0 == 48) : alt133 = 1 if alt133 == 1: # lesscss.g:594:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:594:41: ( '3' ) # lesscss.g:594:42: '3' pass self.match(51) finally: pass # $ANTLR end "S" # $ANTLR start "T" def mT(self, ): try: # lesscss.g:597:12: ( ( 't' | 'T' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 't' | 'T' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '4' ) ) ) alt145 = 2 LA145_0 = self.input.LA(1) if (LA145_0 == 84 or LA145_0 == 116) : alt145 = 1 elif (LA145_0 == 92) : alt145 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 145, 0, self.input) raise nvae if alt145 == 1: # lesscss.g:597:14: ( 't' | 'T' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 84 or self.input.LA(1) == 116: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:597:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop139 alt139 = 2 LA139_0 = self.input.LA(1) if ((9 <= LA139_0 <= 10) or (12 <= LA139_0 <= 13) or LA139_0 == 32) : alt139 = 1 if alt139 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop139 elif alt145 == 2: # lesscss.g:598:5: '\\\\' ( 't' | 'T' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '4' ) ) pass self.match(92) # lesscss.g:599:3: ( 't' | 'T' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '4' ) ) alt144 = 3 LA144 = self.input.LA(1) if LA144 == 116: alt144 = 1 elif LA144 == 84: alt144 = 2 elif LA144 == 48 or LA144 == 53 or LA144 == 55: alt144 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 144, 0, self.input) raise nvae if alt144 == 1: # lesscss.g:600:6: 't' pass self.match(116) elif alt144 == 2: # lesscss.g:601:6: 'T' pass self.match(84) elif alt144 == 3: # lesscss.g:602:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '4' ) pass # lesscss.g:602:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt143 = 2 LA143_0 = self.input.LA(1) if (LA143_0 == 48) : alt143 = 1 if alt143 == 1: # lesscss.g:602:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:602:11: ( '0' ( '0' ( '0' )? )? )? alt142 = 2 LA142_0 = self.input.LA(1) if (LA142_0 == 48) : alt142 = 1 if alt142 == 1: # lesscss.g:602:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:602:16: ( '0' ( '0' )? )? alt141 = 2 LA141_0 = self.input.LA(1) if (LA141_0 == 48) : alt141 = 1 if alt141 == 1: # lesscss.g:602:17: '0' ( '0' )? pass self.match(48) # lesscss.g:602:21: ( '0' )? alt140 = 2 LA140_0 = self.input.LA(1) if (LA140_0 == 48) : alt140 = 1 if alt140 == 1: # lesscss.g:602:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:602:41: ( '4' ) # lesscss.g:602:42: '4' pass self.match(52) finally: pass # $ANTLR end "T" # $ANTLR start "U" def mU(self, ): try: # lesscss.g:605:12: ( ( 'u' | 'U' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'u' | 'U' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '5' ) ) ) alt152 = 2 LA152_0 = self.input.LA(1) if (LA152_0 == 85 or LA152_0 == 117) : alt152 = 1 elif (LA152_0 == 92) : alt152 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 152, 0, self.input) raise nvae if alt152 == 1: # lesscss.g:605:14: ( 'u' | 'U' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 85 or self.input.LA(1) == 117: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:605:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop146 alt146 = 2 LA146_0 = self.input.LA(1) if ((9 <= LA146_0 <= 10) or (12 <= LA146_0 <= 13) or LA146_0 == 32) : alt146 = 1 if alt146 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop146 elif alt152 == 2: # lesscss.g:606:5: '\\\\' ( 'u' | 'U' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '5' ) ) pass self.match(92) # lesscss.g:607:3: ( 'u' | 'U' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '5' ) ) alt151 = 3 LA151 = self.input.LA(1) if LA151 == 117: alt151 = 1 elif LA151 == 85: alt151 = 2 elif LA151 == 48 or LA151 == 53 or LA151 == 55: alt151 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 151, 0, self.input) raise nvae if alt151 == 1: # lesscss.g:608:6: 'u' pass self.match(117) elif alt151 == 2: # lesscss.g:609:6: 'U' pass self.match(85) elif alt151 == 3: # lesscss.g:610:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '5' ) pass # lesscss.g:610:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt150 = 2 LA150_0 = self.input.LA(1) if (LA150_0 == 48) : alt150 = 1 if alt150 == 1: # lesscss.g:610:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:610:11: ( '0' ( '0' ( '0' )? )? )? alt149 = 2 LA149_0 = self.input.LA(1) if (LA149_0 == 48) : alt149 = 1 if alt149 == 1: # lesscss.g:610:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:610:16: ( '0' ( '0' )? )? alt148 = 2 LA148_0 = self.input.LA(1) if (LA148_0 == 48) : alt148 = 1 if alt148 == 1: # lesscss.g:610:17: '0' ( '0' )? pass self.match(48) # lesscss.g:610:21: ( '0' )? alt147 = 2 LA147_0 = self.input.LA(1) if (LA147_0 == 48) : alt147 = 1 if alt147 == 1: # lesscss.g:610:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:610:41: ( '5' ) # lesscss.g:610:42: '5' pass self.match(53) finally: pass # $ANTLR end "U" # $ANTLR start "V" def mV(self, ): try: # lesscss.g:613:12: ( ( 'v' | 'V' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'v' | 'V' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '6' ) ) ) alt159 = 2 LA159_0 = self.input.LA(1) if (LA159_0 == 86 or LA159_0 == 118) : alt159 = 1 elif (LA159_0 == 92) : alt159 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 159, 0, self.input) raise nvae if alt159 == 1: # lesscss.g:613:14: ( 'v' | 'V' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 86 or self.input.LA(1) == 118: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:613:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop153 alt153 = 2 LA153_0 = self.input.LA(1) if ((9 <= LA153_0 <= 10) or (12 <= LA153_0 <= 13) or LA153_0 == 32) : alt153 = 1 if alt153 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop153 elif alt159 == 2: # lesscss.g:614:5: '\\\\' ( 'v' | 'V' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '6' ) ) pass self.match(92) # lesscss.g:615:3: ( 'v' | 'V' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '6' ) ) alt158 = 3 LA158 = self.input.LA(1) if LA158 == 118: alt158 = 1 elif LA158 == 86: alt158 = 2 elif LA158 == 48 or LA158 == 53 or LA158 == 55: alt158 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 158, 0, self.input) raise nvae if alt158 == 1: # lesscss.g:616:6: 'v' pass self.match(118) elif alt158 == 2: # lesscss.g:617:6: 'V' pass self.match(86) elif alt158 == 3: # lesscss.g:618:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '6' ) pass # lesscss.g:618:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt157 = 2 LA157_0 = self.input.LA(1) if (LA157_0 == 48) : alt157 = 1 if alt157 == 1: # lesscss.g:618:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:618:11: ( '0' ( '0' ( '0' )? )? )? alt156 = 2 LA156_0 = self.input.LA(1) if (LA156_0 == 48) : alt156 = 1 if alt156 == 1: # lesscss.g:618:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:618:16: ( '0' ( '0' )? )? alt155 = 2 LA155_0 = self.input.LA(1) if (LA155_0 == 48) : alt155 = 1 if alt155 == 1: # lesscss.g:618:17: '0' ( '0' )? pass self.match(48) # lesscss.g:618:21: ( '0' )? alt154 = 2 LA154_0 = self.input.LA(1) if (LA154_0 == 48) : alt154 = 1 if alt154 == 1: # lesscss.g:618:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:618:41: ( '6' ) # lesscss.g:618:42: '6' pass self.match(54) finally: pass # $ANTLR end "V" # $ANTLR start "W" def mW(self, ): try: # lesscss.g:621:12: ( ( 'w' | 'W' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'w' | 'W' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '7' ) ) ) alt166 = 2 LA166_0 = self.input.LA(1) if (LA166_0 == 87 or LA166_0 == 119) : alt166 = 1 elif (LA166_0 == 92) : alt166 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 166, 0, self.input) raise nvae if alt166 == 1: # lesscss.g:621:14: ( 'w' | 'W' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 87 or self.input.LA(1) == 119: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:621:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop160 alt160 = 2 LA160_0 = self.input.LA(1) if ((9 <= LA160_0 <= 10) or (12 <= LA160_0 <= 13) or LA160_0 == 32) : alt160 = 1 if alt160 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop160 elif alt166 == 2: # lesscss.g:622:5: '\\\\' ( 'w' | 'W' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '7' ) ) pass self.match(92) # lesscss.g:623:3: ( 'w' | 'W' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '7' ) ) alt165 = 3 LA165 = self.input.LA(1) if LA165 == 119: alt165 = 1 elif LA165 == 87: alt165 = 2 elif LA165 == 48 or LA165 == 53 or LA165 == 55: alt165 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 165, 0, self.input) raise nvae if alt165 == 1: # lesscss.g:624:6: 'w' pass self.match(119) elif alt165 == 2: # lesscss.g:625:6: 'W' pass self.match(87) elif alt165 == 3: # lesscss.g:626:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '7' ) pass # lesscss.g:626:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt164 = 2 LA164_0 = self.input.LA(1) if (LA164_0 == 48) : alt164 = 1 if alt164 == 1: # lesscss.g:626:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:626:11: ( '0' ( '0' ( '0' )? )? )? alt163 = 2 LA163_0 = self.input.LA(1) if (LA163_0 == 48) : alt163 = 1 if alt163 == 1: # lesscss.g:626:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:626:16: ( '0' ( '0' )? )? alt162 = 2 LA162_0 = self.input.LA(1) if (LA162_0 == 48) : alt162 = 1 if alt162 == 1: # lesscss.g:626:17: '0' ( '0' )? pass self.match(48) # lesscss.g:626:21: ( '0' )? alt161 = 2 LA161_0 = self.input.LA(1) if (LA161_0 == 48) : alt161 = 1 if alt161 == 1: # lesscss.g:626:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:626:41: ( '7' ) # lesscss.g:626:42: '7' pass self.match(55) finally: pass # $ANTLR end "W" # $ANTLR start "X" def mX(self, ): try: # lesscss.g:629:12: ( ( 'x' | 'X' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'x' | 'X' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '8' ) ) ) alt173 = 2 LA173_0 = self.input.LA(1) if (LA173_0 == 88 or LA173_0 == 120) : alt173 = 1 elif (LA173_0 == 92) : alt173 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 173, 0, self.input) raise nvae if alt173 == 1: # lesscss.g:629:14: ( 'x' | 'X' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 88 or self.input.LA(1) == 120: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:629:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop167 alt167 = 2 LA167_0 = self.input.LA(1) if ((9 <= LA167_0 <= 10) or (12 <= LA167_0 <= 13) or LA167_0 == 32) : alt167 = 1 if alt167 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop167 elif alt173 == 2: # lesscss.g:630:5: '\\\\' ( 'x' | 'X' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '8' ) ) pass self.match(92) # lesscss.g:631:3: ( 'x' | 'X' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '8' ) ) alt172 = 3 LA172 = self.input.LA(1) if LA172 == 120: alt172 = 1 elif LA172 == 88: alt172 = 2 elif LA172 == 48 or LA172 == 53 or LA172 == 55: alt172 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 172, 0, self.input) raise nvae if alt172 == 1: # lesscss.g:632:6: 'x' pass self.match(120) elif alt172 == 2: # lesscss.g:633:6: 'X' pass self.match(88) elif alt172 == 3: # lesscss.g:634:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '8' ) pass # lesscss.g:634:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt171 = 2 LA171_0 = self.input.LA(1) if (LA171_0 == 48) : alt171 = 1 if alt171 == 1: # lesscss.g:634:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:634:11: ( '0' ( '0' ( '0' )? )? )? alt170 = 2 LA170_0 = self.input.LA(1) if (LA170_0 == 48) : alt170 = 1 if alt170 == 1: # lesscss.g:634:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:634:16: ( '0' ( '0' )? )? alt169 = 2 LA169_0 = self.input.LA(1) if (LA169_0 == 48) : alt169 = 1 if alt169 == 1: # lesscss.g:634:17: '0' ( '0' )? pass self.match(48) # lesscss.g:634:21: ( '0' )? alt168 = 2 LA168_0 = self.input.LA(1) if (LA168_0 == 48) : alt168 = 1 if alt168 == 1: # lesscss.g:634:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:634:41: ( '8' ) # lesscss.g:634:42: '8' pass self.match(56) finally: pass # $ANTLR end "X" # $ANTLR start "Y" def mY(self, ): try: # lesscss.g:637:12: ( ( 'y' | 'Y' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'y' | 'Y' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '9' ) ) ) alt180 = 2 LA180_0 = self.input.LA(1) if (LA180_0 == 89 or LA180_0 == 121) : alt180 = 1 elif (LA180_0 == 92) : alt180 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 180, 0, self.input) raise nvae if alt180 == 1: # lesscss.g:637:14: ( 'y' | 'Y' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 89 or self.input.LA(1) == 121: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:637:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop174 alt174 = 2 LA174_0 = self.input.LA(1) if ((9 <= LA174_0 <= 10) or (12 <= LA174_0 <= 13) or LA174_0 == 32) : alt174 = 1 if alt174 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop174 elif alt180 == 2: # lesscss.g:638:5: '\\\\' ( 'y' | 'Y' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '9' ) ) pass self.match(92) # lesscss.g:639:3: ( 'y' | 'Y' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '9' ) ) alt179 = 3 LA179 = self.input.LA(1) if LA179 == 121: alt179 = 1 elif LA179 == 89: alt179 = 2 elif LA179 == 48 or LA179 == 53 or LA179 == 55: alt179 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 179, 0, self.input) raise nvae if alt179 == 1: # lesscss.g:640:6: 'y' pass self.match(121) elif alt179 == 2: # lesscss.g:641:6: 'Y' pass self.match(89) elif alt179 == 3: # lesscss.g:642:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( '9' ) pass # lesscss.g:642:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt178 = 2 LA178_0 = self.input.LA(1) if (LA178_0 == 48) : alt178 = 1 if alt178 == 1: # lesscss.g:642:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:642:11: ( '0' ( '0' ( '0' )? )? )? alt177 = 2 LA177_0 = self.input.LA(1) if (LA177_0 == 48) : alt177 = 1 if alt177 == 1: # lesscss.g:642:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:642:16: ( '0' ( '0' )? )? alt176 = 2 LA176_0 = self.input.LA(1) if (LA176_0 == 48) : alt176 = 1 if alt176 == 1: # lesscss.g:642:17: '0' ( '0' )? pass self.match(48) # lesscss.g:642:21: ( '0' )? alt175 = 2 LA175_0 = self.input.LA(1) if (LA175_0 == 48) : alt175 = 1 if alt175 == 1: # lesscss.g:642:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:642:41: ( '9' ) # lesscss.g:642:42: '9' pass self.match(57) finally: pass # $ANTLR end "Y" # $ANTLR start "Z" def mZ(self, ): try: # lesscss.g:645:12: ( ( 'z' | 'Z' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* | '\\\\' ( 'z' | 'Z' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( 'A' | 'a' ) ) ) alt187 = 2 LA187_0 = self.input.LA(1) if (LA187_0 == 90 or LA187_0 == 122) : alt187 = 1 elif (LA187_0 == 92) : alt187 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 187, 0, self.input) raise nvae if alt187 == 1: # lesscss.g:645:14: ( 'z' | 'Z' ) ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass if self.input.LA(1) == 90 or self.input.LA(1) == 122: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:645:24: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop181 alt181 = 2 LA181_0 = self.input.LA(1) if ((9 <= LA181_0 <= 10) or (12 <= LA181_0 <= 13) or LA181_0 == 32) : alt181 = 1 if alt181 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop181 elif alt187 == 2: # lesscss.g:646:5: '\\\\' ( 'z' | 'Z' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( 'A' | 'a' ) ) pass self.match(92) # lesscss.g:647:3: ( 'z' | 'Z' | ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( 'A' | 'a' ) ) alt186 = 3 LA186 = self.input.LA(1) if LA186 == 122: alt186 = 1 elif LA186 == 90: alt186 = 2 elif LA186 == 48 or LA186 == 53 or LA186 == 55: alt186 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 186, 0, self.input) raise nvae if alt186 == 1: # lesscss.g:648:6: 'z' pass self.match(122) elif alt186 == 2: # lesscss.g:649:6: 'Z' pass self.match(90) elif alt186 == 3: # lesscss.g:650:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? ( '5' | '7' ) ( 'A' | 'a' ) pass # lesscss.g:650:6: ( '0' ( '0' ( '0' ( '0' )? )? )? )? alt185 = 2 LA185_0 = self.input.LA(1) if (LA185_0 == 48) : alt185 = 1 if alt185 == 1: # lesscss.g:650:7: '0' ( '0' ( '0' ( '0' )? )? )? pass self.match(48) # lesscss.g:650:11: ( '0' ( '0' ( '0' )? )? )? alt184 = 2 LA184_0 = self.input.LA(1) if (LA184_0 == 48) : alt184 = 1 if alt184 == 1: # lesscss.g:650:12: '0' ( '0' ( '0' )? )? pass self.match(48) # lesscss.g:650:16: ( '0' ( '0' )? )? alt183 = 2 LA183_0 = self.input.LA(1) if (LA183_0 == 48) : alt183 = 1 if alt183 == 1: # lesscss.g:650:17: '0' ( '0' )? pass self.match(48) # lesscss.g:650:21: ( '0' )? alt182 = 2 LA182_0 = self.input.LA(1) if (LA182_0 == 48) : alt182 = 1 if alt182 == 1: # lesscss.g:650:21: '0' pass self.match(48) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if self.input.LA(1) == 65 or self.input.LA(1) == 97: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "Z" # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # lesscss.g:661:17: ( '/*' ( options {greedy=false; } : ( . )* ) '*/' ) # lesscss.g:661:19: '/*' ( options {greedy=false; } : ( . )* ) '*/' pass self.match("/*") # lesscss.g:661:24: ( options {greedy=false; } : ( . )* ) # lesscss.g:661:54: ( . )* pass # lesscss.g:661:54: ( . )* while True: #loop188 alt188 = 2 LA188_0 = self.input.LA(1) if (LA188_0 == 42) : LA188_1 = self.input.LA(2) if (LA188_1 == 47) : alt188 = 2 elif ((0 <= LA188_1 <= 46) or (48 <= LA188_1 <= 65535)) : alt188 = 1 elif ((0 <= LA188_0 <= 41) or (43 <= LA188_0 <= 65535)) : alt188 = 1 if alt188 == 1: # lesscss.g:661:54: . pass self.matchAny() else: break #loop188 self.match("*/") if self._state.backtracking == 0: _channel = 2; # Comments on channel 2 in case we want to find them self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "CDO" def mCDO(self, ): try: _type = CDO _channel = DEFAULT_CHANNEL # lesscss.g:673:17: ( '<!--' ) # lesscss.g:673:19: '<!--' pass self.match("<!--") if self._state.backtracking == 0: _channel = 3; # CDO on channel 3 in case we want it later self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CDO" # $ANTLR start "CDC" def mCDC(self, ): try: _type = CDC _channel = DEFAULT_CHANNEL # lesscss.g:685:17: ( '-->' ) # lesscss.g:685:19: '-->' pass self.match("-->") if self._state.backtracking == 0: _channel = 3; # CDC on channel 3 in case we want it later self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CDC" # $ANTLR start "INCLUDES" def mINCLUDES(self, ): try: _type = INCLUDES _channel = DEFAULT_CHANNEL # lesscss.g:691:10: ( '~=' ) # lesscss.g:691:12: '~=' pass self.match("~=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INCLUDES" # $ANTLR start "DASHMATCH" def mDASHMATCH(self, ): try: _type = DASHMATCH _channel = DEFAULT_CHANNEL # lesscss.g:692:11: ( '|=' ) # lesscss.g:692:13: '|=' pass self.match("|=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DASHMATCH" # $ANTLR start "PREFIXMATCH" def mPREFIXMATCH(self, ): try: _type = PREFIXMATCH _channel = DEFAULT_CHANNEL # lesscss.g:693:13: ( '^=' ) # lesscss.g:693:15: '^=' pass self.match("^=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PREFIXMATCH" # $ANTLR start "SUFFIXMATCH" def mSUFFIXMATCH(self, ): try: _type = SUFFIXMATCH _channel = DEFAULT_CHANNEL # lesscss.g:694:13: ( '$=' ) # lesscss.g:694:15: '$=' pass self.match("$=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SUFFIXMATCH" # $ANTLR start "SUBSTRINGMATCH" def mSUBSTRINGMATCH(self, ): try: _type = SUBSTRINGMATCH _channel = DEFAULT_CHANNEL # lesscss.g:695:16: ( '*=' ) # lesscss.g:695:18: '*=' pass self.match("*=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SUBSTRINGMATCH" # $ANTLR start "GREATER" def mGREATER(self, ): try: _type = GREATER _channel = DEFAULT_CHANNEL # lesscss.g:698:10: ( '>' ) # lesscss.g:698:12: '>' pass self.match(62) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "GREATER" # $ANTLR start "LBRACE" def mLBRACE(self, ): try: _type = LBRACE _channel = DEFAULT_CHANNEL # lesscss.g:699:9: ( '{' ) # lesscss.g:699:11: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LBRACE" # $ANTLR start "RBRACE" def mRBRACE(self, ): try: _type = RBRACE _channel = DEFAULT_CHANNEL # lesscss.g:700:9: ( '}' ) # lesscss.g:700:11: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RBRACE" # $ANTLR start "LBRACKET" def mLBRACKET(self, ): try: _type = LBRACKET _channel = DEFAULT_CHANNEL # lesscss.g:701:10: ( '[' ) # lesscss.g:701:12: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LBRACKET" # $ANTLR start "RBRACKET" def mRBRACKET(self, ): try: _type = RBRACKET _channel = DEFAULT_CHANNEL # lesscss.g:702:10: ( ']' ) # lesscss.g:702:12: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RBRACKET" # $ANTLR start "OPEQ" def mOPEQ(self, ): try: _type = OPEQ _channel = DEFAULT_CHANNEL # lesscss.g:703:7: ( '=' ) # lesscss.g:703:9: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OPEQ" # $ANTLR start "SEMI" def mSEMI(self, ): try: _type = SEMI _channel = DEFAULT_CHANNEL # lesscss.g:704:7: ( ';' ) # lesscss.g:704:9: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SEMI" # $ANTLR start "COLON" def mCOLON(self, ): try: _type = COLON _channel = DEFAULT_CHANNEL # lesscss.g:705:8: ( ':' ) # lesscss.g:705:10: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COLON" # $ANTLR start "SOLIDUS" def mSOLIDUS(self, ): try: _type = SOLIDUS _channel = DEFAULT_CHANNEL # lesscss.g:706:10: ( '/' ) # lesscss.g:706:12: '/' pass self.match(47) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SOLIDUS" # $ANTLR start "MINUS" def mMINUS(self, ): try: _type = MINUS _channel = DEFAULT_CHANNEL # lesscss.g:707:8: ( '-' ) # lesscss.g:707:10: '-' pass self.match(45) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MINUS" # $ANTLR start "PLUS" def mPLUS(self, ): try: _type = PLUS _channel = DEFAULT_CHANNEL # lesscss.g:708:7: ( '+' ) # lesscss.g:708:9: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUS" # $ANTLR start "STAR" def mSTAR(self, ): try: _type = STAR _channel = DEFAULT_CHANNEL # lesscss.g:709:7: ( '*' ) # lesscss.g:709:9: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STAR" # $ANTLR start "LPAREN" def mLPAREN(self, ): try: _type = LPAREN _channel = DEFAULT_CHANNEL # lesscss.g:710:9: ( '(' ) # lesscss.g:710:11: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LPAREN" # $ANTLR start "RPAREN" def mRPAREN(self, ): try: _type = RPAREN _channel = DEFAULT_CHANNEL # lesscss.g:711:9: ( ')' ) # lesscss.g:711:11: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RPAREN" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # lesscss.g:712:8: ( ',' ) # lesscss.g:712:10: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "DOT" def mDOT(self, ): try: _type = DOT _channel = DEFAULT_CHANNEL # lesscss.g:713:6: ( '.' ) # lesscss.g:713:8: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOT" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # lesscss.g:719:2: ( '\"' ( STRINGESC | ~ ( '\"' | '\\\\' | '\\n' | '\\r' ) )* '\"' | '\\'' ( STRINGESC | ~ ( '\\'' | '\\\\' | '\\n' | '\\r' ) )* '\\'' ) alt191 = 2 LA191_0 = self.input.LA(1) if (LA191_0 == 34) : alt191 = 1 elif (LA191_0 == 39) : alt191 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 191, 0, self.input) raise nvae if alt191 == 1: # lesscss.g:719:4: '\"' ( STRINGESC | ~ ( '\"' | '\\\\' | '\\n' | '\\r' ) )* '\"' pass self.match(34) # lesscss.g:719:8: ( STRINGESC | ~ ( '\"' | '\\\\' | '\\n' | '\\r' ) )* while True: #loop189 alt189 = 3 LA189_0 = self.input.LA(1) if (LA189_0 == 92) : alt189 = 1 elif ((0 <= LA189_0 <= 9) or (11 <= LA189_0 <= 12) or (14 <= LA189_0 <= 33) or (35 <= LA189_0 <= 91) or (93 <= LA189_0 <= 65535)) : alt189 = 2 if alt189 == 1: # lesscss.g:719:10: STRINGESC pass self.mSTRINGESC() elif alt189 == 2: # lesscss.g:719:22: ~ ( '\"' | '\\\\' | '\\n' | '\\r' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop189 self.match(34) elif alt191 == 2: # lesscss.g:720:4: '\\'' ( STRINGESC | ~ ( '\\'' | '\\\\' | '\\n' | '\\r' ) )* '\\'' pass self.match(39) # lesscss.g:720:9: ( STRINGESC | ~ ( '\\'' | '\\\\' | '\\n' | '\\r' ) )* while True: #loop190 alt190 = 3 LA190_0 = self.input.LA(1) if (LA190_0 == 92) : alt190 = 1 elif ((0 <= LA190_0 <= 9) or (11 <= LA190_0 <= 12) or (14 <= LA190_0 <= 38) or (40 <= LA190_0 <= 91) or (93 <= LA190_0 <= 65535)) : alt190 = 2 if alt190 == 1: # lesscss.g:720:11: STRINGESC pass self.mSTRINGESC() elif alt190 == 2: # lesscss.g:720:23: ~ ( '\\'' | '\\\\' | '\\n' | '\\r' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop190 self.match(39) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "STRINGESC" def mSTRINGESC(self, ): try: # lesscss.g:724:2: ( '\\\\' ( 'n' | 'r' | 't' | HEXCHAR | '\"' | '\\'' | '\\\\' | ( 'u' )+ HEXCHAR HEXCHAR HEXCHAR HEXCHAR | HEXCHAR HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* ) ) # lesscss.g:724:6: '\\\\' ( 'n' | 'r' | 't' | HEXCHAR | '\"' | '\\'' | '\\\\' | ( 'u' )+ HEXCHAR HEXCHAR HEXCHAR HEXCHAR | HEXCHAR HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* ) pass self.match(92) # lesscss.g:725:3: ( 'n' | 'r' | 't' | HEXCHAR | '\"' | '\\'' | '\\\\' | ( 'u' )+ HEXCHAR HEXCHAR HEXCHAR HEXCHAR | HEXCHAR HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* ) alt198 = 9 alt198 = self.dfa198.predict(self.input) if alt198 == 1: # lesscss.g:725:7: 'n' pass self.match(110) elif alt198 == 2: # lesscss.g:726:7: 'r' pass self.match(114) elif alt198 == 3: # lesscss.g:727:7: 't' pass self.match(116) elif alt198 == 4: # lesscss.g:728:7: HEXCHAR pass self.mHEXCHAR() elif alt198 == 5: # lesscss.g:729:7: '\"' pass self.match(34) elif alt198 == 6: # lesscss.g:730:7: '\\'' pass self.match(39) elif alt198 == 7: # lesscss.g:731:7: '\\\\' pass self.match(92) elif alt198 == 8: # lesscss.g:732:7: ( 'u' )+ HEXCHAR HEXCHAR HEXCHAR HEXCHAR pass # lesscss.g:732:7: ( 'u' )+ cnt192 = 0 while True: #loop192 alt192 = 2 LA192_0 = self.input.LA(1) if (LA192_0 == 117) : alt192 = 1 if alt192 == 1: # lesscss.g:732:8: 'u' pass self.match(117) else: if cnt192 >= 1: break #loop192 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(192, self.input) raise eee cnt192 += 1 self.mHEXCHAR() self.mHEXCHAR() self.mHEXCHAR() self.mHEXCHAR() elif alt198 == 9: # lesscss.g:734:7: HEXCHAR HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* pass self.mHEXCHAR() self.mHEXCHAR() # lesscss.g:735:4: ( HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? )? alt196 = 2 LA196_0 = self.input.LA(1) if ((48 <= LA196_0 <= 57) or (65 <= LA196_0 <= 70) or (97 <= LA196_0 <= 102)) : alt196 = 1 if alt196 == 1: # lesscss.g:735:5: HEXCHAR ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? pass self.mHEXCHAR() # lesscss.g:736:5: ( HEXCHAR ( HEXCHAR ( HEXCHAR )? )? )? alt195 = 2 LA195_0 = self.input.LA(1) if ((48 <= LA195_0 <= 57) or (65 <= LA195_0 <= 70) or (97 <= LA195_0 <= 102)) : alt195 = 1 if alt195 == 1: # lesscss.g:736:6: HEXCHAR ( HEXCHAR ( HEXCHAR )? )? pass self.mHEXCHAR() # lesscss.g:737:6: ( HEXCHAR ( HEXCHAR )? )? alt194 = 2 LA194_0 = self.input.LA(1) if ((48 <= LA194_0 <= 57) or (65 <= LA194_0 <= 70) or (97 <= LA194_0 <= 102)) : alt194 = 1 if alt194 == 1: # lesscss.g:737:7: HEXCHAR ( HEXCHAR )? pass self.mHEXCHAR() # lesscss.g:737:15: ( HEXCHAR )? alt193 = 2 LA193_0 = self.input.LA(1) if ((48 <= LA193_0 <= 57) or (65 <= LA193_0 <= 70) or (97 <= LA193_0 <= 102)) : alt193 = 1 if alt193 == 1: # lesscss.g:737:15: HEXCHAR pass self.mHEXCHAR() # lesscss.g:740:4: ( '\\r' | '\\n' | '\\t' | '\\f' | ' ' )* while True: #loop197 alt197 = 2 LA197_0 = self.input.LA(1) if ((9 <= LA197_0 <= 10) or (12 <= LA197_0 <= 13) or LA197_0 == 32) : alt197 = 1 if alt197 == 1: # lesscss.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop197 finally: pass # $ANTLR end "STRINGESC" # $ANTLR start "UNICODE_RANGE" def mUNICODE_RANGE(self, ): try: _type = UNICODE_RANGE _channel = DEFAULT_CHANNEL # lesscss.g:748:2: ( U '+' ( ( ( HEXCHAR )+ ) | ( ( HEXCHAR )* ( '?' )+ ) | ( ( HEXCHAR )+ MINUS ( HEXCHAR )+ ) ) ) # lesscss.g:748:4: U '+' ( ( ( HEXCHAR )+ ) | ( ( HEXCHAR )* ( '?' )+ ) | ( ( HEXCHAR )+ MINUS ( HEXCHAR )+ ) ) pass self.mU() self.match(43) # lesscss.g:749:3: ( ( ( HEXCHAR )+ ) | ( ( HEXCHAR )* ( '?' )+ ) | ( ( HEXCHAR )+ MINUS ( HEXCHAR )+ ) ) alt204 = 3 alt204 = self.dfa204.predict(self.input) if alt204 == 1: # lesscss.g:749:5: ( ( HEXCHAR )+ ) pass # lesscss.g:749:5: ( ( HEXCHAR )+ ) # lesscss.g:749:7: ( HEXCHAR )+ pass # lesscss.g:749:7: ( HEXCHAR )+ cnt199 = 0 while True: #loop199 alt199 = 2 LA199_0 = self.input.LA(1) if ((48 <= LA199_0 <= 57) or (65 <= LA199_0 <= 70) or (97 <= LA199_0 <= 102)) : alt199 = 1 if alt199 == 1: # lesscss.g:749:7: HEXCHAR pass self.mHEXCHAR() else: if cnt199 >= 1: break #loop199 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(199, self.input) raise eee cnt199 += 1 elif alt204 == 2: # lesscss.g:750:5: ( ( HEXCHAR )* ( '?' )+ ) pass # lesscss.g:750:5: ( ( HEXCHAR )* ( '?' )+ ) # lesscss.g:750:7: ( HEXCHAR )* ( '?' )+ pass # lesscss.g:750:7: ( HEXCHAR )* while True: #loop200 alt200 = 2 LA200_0 = self.input.LA(1) if ((48 <= LA200_0 <= 57) or (65 <= LA200_0 <= 70) or (97 <= LA200_0 <= 102)) : alt200 = 1 if alt200 == 1: # lesscss.g:750:7: HEXCHAR pass self.mHEXCHAR() else: break #loop200 # lesscss.g:750:16: ( '?' )+ cnt201 = 0 while True: #loop201 alt201 = 2 LA201_0 = self.input.LA(1) if (LA201_0 == 63) : alt201 = 1 if alt201 == 1: # lesscss.g:750:16: '?' pass self.match(63) else: if cnt201 >= 1: break #loop201 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(201, self.input) raise eee cnt201 += 1 elif alt204 == 3: # lesscss.g:751:5: ( ( HEXCHAR )+ MINUS ( HEXCHAR )+ ) pass # lesscss.g:751:5: ( ( HEXCHAR )+ MINUS ( HEXCHAR )+ ) # lesscss.g:751:7: ( HEXCHAR )+ MINUS ( HEXCHAR )+ pass # lesscss.g:751:7: ( HEXCHAR )+ cnt202 = 0 while True: #loop202 alt202 = 2 LA202_0 = self.input.LA(1) if ((48 <= LA202_0 <= 57) or (65 <= LA202_0 <= 70) or (97 <= LA202_0 <= 102)) : alt202 = 1 if alt202 == 1: # lesscss.g:751:7: HEXCHAR pass self.mHEXCHAR() else: if cnt202 >= 1: break #loop202 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(202, self.input) raise eee cnt202 += 1 self.mMINUS() # lesscss.g:751:22: ( HEXCHAR )+ cnt203 = 0 while True: #loop203 alt203 = 2 LA203_0 = self.input.LA(1) if ((48 <= LA203_0 <= 57) or (65 <= LA203_0 <= 70) or (97 <= LA203_0 <= 102)) : alt203 = 1 if alt203 == 1: # lesscss.g:751:22: HEXCHAR pass self.mHEXCHAR() else: if cnt203 >= 1: break #loop203 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(203, self.input) raise eee cnt203 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "UNICODE_RANGE" # $ANTLR start "IDENT" def mIDENT(self, ): try: _type = IDENT _channel = DEFAULT_CHANNEL # lesscss.g:760:2: ( ( '-' )? NMSTART ( NMCHAR )* ) # lesscss.g:760:4: ( '-' )? NMSTART ( NMCHAR )* pass # lesscss.g:760:4: ( '-' )? alt205 = 2 LA205_0 = self.input.LA(1) if (LA205_0 == 45) : alt205 = 1 if alt205 == 1: # lesscss.g:760:4: '-' pass self.match(45) self.mNMSTART() # lesscss.g:760:17: ( NMCHAR )* while True: #loop206 alt206 = 2 LA206_0 = self.input.LA(1) if (LA206_0 == 45 or (48 <= LA206_0 <= 57) or (65 <= LA206_0 <= 90) or LA206_0 == 92 or LA206_0 == 95 or (97 <= LA206_0 <= 122)) : alt206 = 1 if alt206 == 1: # lesscss.g:760:17: NMCHAR pass self.mNMCHAR() else: break #loop206 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IDENT" # $ANTLR start "FUNCTION" def mFUNCTION(self, ): try: _type = FUNCTION _channel = DEFAULT_CHANNEL # lesscss.g:767:2: ( IDENT LPAREN ) # lesscss.g:767:4: IDENT LPAREN pass self.mIDENT() self.mLPAREN() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FUNCTION" # $ANTLR start "HASH" def mHASH(self, ): try: _type = HASH _channel = DEFAULT_CHANNEL # lesscss.g:773:7: ( '#' NAME ) # lesscss.g:773:9: '#' NAME pass self.match(35) self.mNAME() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "HASH" # $ANTLR start "IMPORT_SYM" def mIMPORT_SYM(self, ): try: _type = IMPORT_SYM _channel = DEFAULT_CHANNEL # lesscss.g:775:12: ( '@' I M P O R T ) # lesscss.g:775:14: '@' I M P O R T pass self.match(64) self.mI() self.mM() self.mP() self.mO() self.mR() self.mT() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IMPORT_SYM" # $ANTLR start "PAGE_SYM" def mPAGE_SYM(self, ): try: _type = PAGE_SYM _channel = DEFAULT_CHANNEL # lesscss.g:776:10: ( '@' P A G E ) # lesscss.g:776:12: '@' P A G E pass self.match(64) self.mP() self.mA() self.mG() self.mE() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PAGE_SYM" # $ANTLR start "MEDIA_SYM" def mMEDIA_SYM(self, ): try: _type = MEDIA_SYM _channel = DEFAULT_CHANNEL # lesscss.g:777:11: ( '@' M E D I A ) # lesscss.g:777:13: '@' M E D I A pass self.match(64) self.mM() self.mE() self.mD() self.mI() self.mA() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MEDIA_SYM" # $ANTLR start "FONTFACE_SYM" def mFONTFACE_SYM(self, ): try: _type = FONTFACE_SYM _channel = DEFAULT_CHANNEL # lesscss.g:778:14: ( '@' F O N T '-' F A C E ) # lesscss.g:778:16: '@' F O N T '-' F A C E pass self.match(64) self.mF() self.mO() self.mN() self.mT() self.match(45) self.mF() self.mA() self.mC() self.mE() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FONTFACE_SYM" # $ANTLR start "CHARSET_SYM" def mCHARSET_SYM(self, ): try: _type = CHARSET_SYM _channel = DEFAULT_CHANNEL # lesscss.g:779:13: ( '@charset' ) # lesscss.g:779:15: '@charset' pass self.match("@charset") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CHARSET_SYM" # $ANTLR start "KEYFRAMES_SYM" def mKEYFRAMES_SYM(self, ): try: _type = KEYFRAMES_SYM _channel = DEFAULT_CHANNEL # lesscss.g:781:15: ( '@' K E Y F R A M E S | '@' '-' W E B K I T '-' K E Y F R A M E S | '@' '-' M O Z '-' K E Y F R A M E S | '@' '-' M S '-' K E Y F R A M E S | '@' '-' O '-' K E Y F R A M E S ) alt207 = 5 alt207 = self.dfa207.predict(self.input) if alt207 == 1: # lesscss.g:781:17: '@' K E Y F R A M E S pass self.match(64) self.mK() self.mE() self.mY() self.mF() self.mR() self.mA() self.mM() self.mE() self.mS() elif alt207 == 2: # lesscss.g:782:5: '@' '-' W E B K I T '-' K E Y F R A M E S pass self.match(64) self.match(45) self.mW() self.mE() self.mB() self.mK() self.mI() self.mT() self.match(45) self.mK() self.mE() self.mY() self.mF() self.mR() self.mA() self.mM() self.mE() self.mS() elif alt207 == 3: # lesscss.g:783:5: '@' '-' M O Z '-' K E Y F R A M E S pass self.match(64) self.match(45) self.mM() self.mO() self.mZ() self.match(45) self.mK() self.mE() self.mY() self.mF() self.mR() self.mA() self.mM() self.mE() self.mS() elif alt207 == 4: # lesscss.g:784:5: '@' '-' M S '-' K E Y F R A M E S pass self.match(64) self.match(45) self.mM() self.mS() self.match(45) self.mK() self.mE() self.mY() self.mF() self.mR() self.mA() self.mM() self.mE() self.mS() elif alt207 == 5: # lesscss.g:785:5: '@' '-' O '-' K E Y F R A M E S pass self.match(64) self.match(45) self.mO() self.match(45) self.mK() self.mE() self.mY() self.mF() self.mR() self.mA() self.mM() self.mE() self.mS() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "KEYFRAMES_SYM" # $ANTLR start "LESS_VARNAME" def mLESS_VARNAME(self, ): try: _type = LESS_VARNAME _channel = DEFAULT_CHANNEL # lesscss.g:792:2: ( ( '@' )+ NMSTART ( NMCHAR )* ) # lesscss.g:792:4: ( '@' )+ NMSTART ( NMCHAR )* pass # lesscss.g:792:4: ( '@' )+ cnt208 = 0 while True: #loop208 alt208 = 2 LA208_0 = self.input.LA(1) if (LA208_0 == 64) : alt208 = 1 if alt208 == 1: # lesscss.g:792:4: '@' pass self.match(64) else: if cnt208 >= 1: break #loop208 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(208, self.input) raise eee cnt208 += 1 self.mNMSTART() # lesscss.g:792:17: ( NMCHAR )* while True: #loop209 alt209 = 2 LA209_0 = self.input.LA(1) if (LA209_0 == 45 or (48 <= LA209_0 <= 57) or (65 <= LA209_0 <= 90) or LA209_0 == 92 or LA209_0 == 95 or (97 <= LA209_0 <= 122)) : alt209 = 1 if alt209 == 1: # lesscss.g:792:17: NMCHAR pass self.mNMCHAR() else: break #loop209 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LESS_VARNAME" # $ANTLR start "IMPORTANT_SYM" def mIMPORTANT_SYM(self, ): try: _type = IMPORTANT_SYM _channel = DEFAULT_CHANNEL # lesscss.g:796:15: ( '!' ( WS | COMMENT )* I M P O R T A N T ) # lesscss.g:796:17: '!' ( WS | COMMENT )* I M P O R T A N T pass self.match(33) # lesscss.g:796:21: ( WS | COMMENT )* while True: #loop210 alt210 = 3 LA210_0 = self.input.LA(1) if (LA210_0 == 9 or LA210_0 == 32) : alt210 = 1 elif (LA210_0 == 47) : alt210 = 2 if alt210 == 1: # lesscss.g:796:22: WS pass self.mWS() elif alt210 == 2: # lesscss.g:796:25: COMMENT pass self.mCOMMENT() else: break #loop210 self.mI() self.mM() self.mP() self.mO() self.mR() self.mT() self.mA() self.mN() self.mT() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IMPORTANT_SYM" # $ANTLR start "EMS" def mEMS(self, ): try: # lesscss.g:808:15: () # lesscss.g:808:16: pass finally: pass # $ANTLR end "EMS" # $ANTLR start "REMS" def mREMS(self, ): try: # lesscss.g:809:16: () # lesscss.g:809:17: pass finally: pass # $ANTLR end "REMS" # $ANTLR start "EXS" def mEXS(self, ): try: # lesscss.g:810:15: () # lesscss.g:810:16: pass finally: pass # $ANTLR end "EXS" # $ANTLR start "CHS" def mCHS(self, ): try: # lesscss.g:811:15: () # lesscss.g:811:16: pass finally: pass # $ANTLR end "CHS" # $ANTLR start "LENGTH" def mLENGTH(self, ): try: # lesscss.g:812:18: () # lesscss.g:812:19: pass finally: pass # $ANTLR end "LENGTH" # $ANTLR start "ANGLE" def mANGLE(self, ): try: # lesscss.g:813:17: () # lesscss.g:813:18: pass finally: pass # $ANTLR end "ANGLE" # $ANTLR start "TIME" def mTIME(self, ): try: # lesscss.g:814:16: () # lesscss.g:814:17: pass finally: pass # $ANTLR end "TIME" # $ANTLR start "FREQ" def mFREQ(self, ): try: # lesscss.g:815:16: () # lesscss.g:815:17: pass finally: pass # $ANTLR end "FREQ" # $ANTLR start "DIMENSION" def mDIMENSION(self, ): try: # lesscss.g:816:20: () # lesscss.g:816:21: pass finally: pass # $ANTLR end "DIMENSION" # $ANTLR start "PERCENTAGE" def mPERCENTAGE(self, ): try: # lesscss.g:817:21: () # lesscss.g:817:22: pass finally: pass # $ANTLR end "PERCENTAGE" # $ANTLR start "RESOLUTION" def mRESOLUTION(self, ): try: # lesscss.g:818:21: () # lesscss.g:818:22: pass finally: pass # $ANTLR end "RESOLUTION" # $ANTLR start "VPORTLEN" def mVPORTLEN(self, ): try: # lesscss.g:819:19: () # lesscss.g:819:20: pass finally: pass # $ANTLR end "VPORTLEN" # $ANTLR start "NTH" def mNTH(self, ): try: # lesscss.g:820:15: () # lesscss.g:820:16: pass finally: pass # $ANTLR end "NTH" # $ANTLR start "NUMBER" def mNUMBER(self, ): try: _type = NUMBER _channel = DEFAULT_CHANNEL # lesscss.g:823:2: ( ( ( '0' .. '9' )+ ( '.' ( '0' .. '9' )+ )? | '.' ( '0' .. '9' )+ ) ( ( E ( M | X ) )=> E ( M | X ) | ( R E M )=> R E M | ( C H )=> C H | ( P ( X | T | C ) )=> P ( X | T | C ) | ( C M )=> C M | ( M ( M | S ) )=> M ( M | S ) | ( I N )=> I N | ( D E G )=> D E G | ( R A D )=> R A D | ( G R A D )=> G R A D | ( T U R N )=> T U R N | ( S )=> S | ( ( K )? H Z )=> ( K )? H Z | ( D P ( I | C | P ) )=> D ( P I | P C M | P P X ) | ( V ( W | H | M ) )=> V ( W | H | M | M I N | M A X ) | ( N )=> ( N ( PLUS | MINUS ) ( '0' .. '9' )+ | N ) | IDENT | '%' | ) ) # lesscss.g:824:3: ( ( '0' .. '9' )+ ( '.' ( '0' .. '9' )+ )? | '.' ( '0' .. '9' )+ ) ( ( E ( M | X ) )=> E ( M | X ) | ( R E M )=> R E M | ( C H )=> C H | ( P ( X | T | C ) )=> P ( X | T | C ) | ( C M )=> C M | ( M ( M | S ) )=> M ( M | S ) | ( I N )=> I N | ( D E G )=> D E G | ( R A D )=> R A D | ( G R A D )=> G R A D | ( T U R N )=> T U R N | ( S )=> S | ( ( K )? H Z )=> ( K )? H Z | ( D P ( I | C | P ) )=> D ( P I | P C M | P P X ) | ( V ( W | H | M ) )=> V ( W | H | M | M I N | M A X ) | ( N )=> ( N ( PLUS | MINUS ) ( '0' .. '9' )+ | N ) | IDENT | '%' | ) pass # lesscss.g:824:3: ( ( '0' .. '9' )+ ( '.' ( '0' .. '9' )+ )? | '.' ( '0' .. '9' )+ ) alt215 = 2 LA215_0 = self.input.LA(1) if ((48 <= LA215_0 <= 57)) : alt215 = 1 elif (LA215_0 == 46) : alt215 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 215, 0, self.input) raise nvae if alt215 == 1: # lesscss.g:825:6: ( '0' .. '9' )+ ( '.' ( '0' .. '9' )+ )? pass # lesscss.g:825:6: ( '0' .. '9' )+ cnt211 = 0 while True: #loop211 alt211 = 2 LA211_0 = self.input.LA(1) if ((48 <= LA211_0 <= 57)) : alt211 = 1 if alt211 == 1: # lesscss.g:825:6: '0' .. '9' pass self.matchRange(48, 57) else: if cnt211 >= 1: break #loop211 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(211, self.input) raise eee cnt211 += 1 # lesscss.g:825:16: ( '.' ( '0' .. '9' )+ )? alt213 = 2 LA213_0 = self.input.LA(1) if (LA213_0 == 46) : alt213 = 1 if alt213 == 1: # lesscss.g:825:17: '.' ( '0' .. '9' )+ pass self.match(46) # lesscss.g:825:21: ( '0' .. '9' )+ cnt212 = 0 while True: #loop212 alt212 = 2 LA212_0 = self.input.LA(1) if ((48 <= LA212_0 <= 57)) : alt212 = 1 if alt212 == 1: # lesscss.g:825:21: '0' .. '9' pass self.matchRange(48, 57) else: if cnt212 >= 1: break #loop212 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(212, self.input) raise eee cnt212 += 1 elif alt215 == 2: # lesscss.g:826:6: '.' ( '0' .. '9' )+ pass self.match(46) # lesscss.g:826:10: ( '0' .. '9' )+ cnt214 = 0 while True: #loop214 alt214 = 2 LA214_0 = self.input.LA(1) if ((48 <= LA214_0 <= 57)) : alt214 = 1 if alt214 == 1: # lesscss.g:826:10: '0' .. '9' pass self.matchRange(48, 57) else: if cnt214 >= 1: break #loop214 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(214, self.input) raise eee cnt214 += 1 # lesscss.g:828:3: ( ( E ( M | X ) )=> E ( M | X ) | ( R E M )=> R E M | ( C H )=> C H | ( P ( X | T | C ) )=> P ( X | T | C ) | ( C M )=> C M | ( M ( M | S ) )=> M ( M | S ) | ( I N )=> I N | ( D E G )=> D E G | ( R A D )=> R A D | ( G R A D )=> G R A D | ( T U R N )=> T U R N | ( S )=> S | ( ( K )? H Z )=> ( K )? H Z | ( D P ( I | C | P ) )=> D ( P I | P C M | P P X ) | ( V ( W | H | M ) )=> V ( W | H | M | M I N | M A X ) | ( N )=> ( N ( PLUS | MINUS ) ( '0' .. '9' )+ | N ) | IDENT | '%' | ) alt224 = 19 alt224 = self.dfa224.predict(self.input) if alt224 == 1: # lesscss.g:829:6: ( E ( M | X ) )=> E ( M | X ) pass self.mE() # lesscss.g:831:5: ( M | X ) alt216 = 2 LA216 = self.input.LA(1) if LA216 == 77 or LA216 == 109: alt216 = 1 elif LA216 == 92: LA216 = self.input.LA(2) if LA216 == 53 or LA216 == 55 or LA216 == 88 or LA216 == 120: alt216 = 2 elif LA216 == 48: LA216 = self.input.LA(3) if LA216 == 48: LA216 = self.input.LA(4) if LA216 == 48: LA216 = self.input.LA(5) if LA216 == 48: LA216_7 = self.input.LA(6) if (LA216_7 == 52 or LA216_7 == 54) : alt216 = 1 elif (LA216_7 == 53 or LA216_7 == 55) : alt216 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 216, 7, self.input) raise nvae elif LA216 == 52 or LA216 == 54: alt216 = 1 elif LA216 == 53 or LA216 == 55: alt216 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 216, 6, self.input) raise nvae elif LA216 == 52 or LA216 == 54: alt216 = 1 elif LA216 == 53 or LA216 == 55: alt216 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 216, 5, self.input) raise nvae elif LA216 == 52 or LA216 == 54: alt216 = 1 elif LA216 == 53 or LA216 == 55: alt216 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 216, 4, self.input) raise nvae elif LA216 == 52 or LA216 == 54 or LA216 == 77 or LA216 == 109: alt216 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 216, 2, self.input) raise nvae elif LA216 == 88 or LA216 == 120: alt216 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 216, 0, self.input) raise nvae if alt216 == 1: # lesscss.g:832:8: M pass self.mM() if self._state.backtracking == 0: _type = EMS; elif alt216 == 2: # lesscss.g:833:8: X pass self.mX() if self._state.backtracking == 0: _type = EXS; elif alt224 == 2: # lesscss.g:835:6: ( R E M )=> R E M pass self.mR() self.mE() self.mM() if self._state.backtracking == 0: _type = REMS; elif alt224 == 3: # lesscss.g:837:6: ( C H )=> C H pass self.mC() self.mH() if self._state.backtracking == 0: _type = CHS; elif alt224 == 4: # lesscss.g:840:6: ( P ( X | T | C ) )=> P ( X | T | C ) pass self.mP() # lesscss.g:842:5: ( X | T | C ) alt217 = 3 alt217 = self.dfa217.predict(self.input) if alt217 == 1: # lesscss.g:843:8: X pass self.mX() elif alt217 == 2: # lesscss.g:844:8: T pass self.mT() elif alt217 == 3: # lesscss.g:845:8: C pass self.mC() if self._state.backtracking == 0: _type = LENGTH; elif alt224 == 5: # lesscss.g:848:6: ( C M )=> C M pass self.mC() self.mM() if self._state.backtracking == 0: _type = LENGTH; elif alt224 == 6: # lesscss.g:850:6: ( M ( M | S ) )=> M ( M | S ) pass self.mM() # lesscss.g:852:5: ( M | S ) alt218 = 2 LA218 = self.input.LA(1) if LA218 == 77 or LA218 == 109: alt218 = 1 elif LA218 == 92: LA218 = self.input.LA(2) if LA218 == 52 or LA218 == 54 or LA218 == 77 or LA218 == 109: alt218 = 1 elif LA218 == 48: LA218 = self.input.LA(3) if LA218 == 48: LA218 = self.input.LA(4) if LA218 == 48: LA218 = self.input.LA(5) if LA218 == 48: LA218_7 = self.input.LA(6) if (LA218_7 == 52 or LA218_7 == 54) : alt218 = 1 elif (LA218_7 == 53 or LA218_7 == 55) : alt218 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 218, 7, self.input) raise nvae elif LA218 == 53 or LA218 == 55: alt218 = 2 elif LA218 == 52 or LA218 == 54: alt218 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 218, 6, self.input) raise nvae elif LA218 == 53 or LA218 == 55: alt218 = 2 elif LA218 == 52 or LA218 == 54: alt218 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 218, 5, self.input) raise nvae elif LA218 == 53 or LA218 == 55: alt218 = 2 elif LA218 == 52 or LA218 == 54: alt218 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 218, 4, self.input) raise nvae elif LA218 == 53 or LA218 == 55 or LA218 == 83 or LA218 == 115: alt218 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 218, 2, self.input) raise nvae elif LA218 == 83 or LA218 == 115: alt218 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 218, 0, self.input) raise nvae if alt218 == 1: # lesscss.g:853:8: M pass self.mM() if self._state.backtracking == 0: _type = LENGTH; elif alt218 == 2: # lesscss.g:855:8: S pass self.mS() if self._state.backtracking == 0: _type = TIME; elif alt224 == 7: # lesscss.g:857:6: ( I N )=> I N pass self.mI() self.mN() if self._state.backtracking == 0: _type = LENGTH; elif alt224 == 8: # lesscss.g:860:6: ( D E G )=> D E G pass self.mD() self.mE() self.mG() if self._state.backtracking == 0: _type = ANGLE; elif alt224 == 9: # lesscss.g:862:6: ( R A D )=> R A D pass self.mR() self.mA() self.mD() if self._state.backtracking == 0: _type = ANGLE; elif alt224 == 10: # lesscss.g:864:6: ( G R A D )=> G R A D pass self.mG() self.mR() self.mA() self.mD() if self._state.backtracking == 0: _type = ANGLE; elif alt224 == 11: # lesscss.g:866:6: ( T U R N )=> T U R N pass self.mT() self.mU() self.mR() self.mN() if self._state.backtracking == 0: _type = ANGLE; elif alt224 == 12: # lesscss.g:869:6: ( S )=> S pass self.mS() if self._state.backtracking == 0: _type = TIME; elif alt224 == 13: # lesscss.g:871:6: ( ( K )? H Z )=> ( K )? H Z pass # lesscss.g:872:5: ( K )? alt219 = 2 LA219_0 = self.input.LA(1) if (LA219_0 == 75 or LA219_0 == 107) : alt219 = 1 elif (LA219_0 == 92) : LA219 = self.input.LA(2) if LA219 == 75 or LA219 == 107: alt219 = 1 elif LA219 == 48: LA219_4 = self.input.LA(3) if (LA219_4 == 48) : LA219_6 = self.input.LA(4) if (LA219_6 == 48) : LA219_7 = self.input.LA(5) if (LA219_7 == 48) : LA219_8 = self.input.LA(6) if (LA219_8 == 52 or LA219_8 == 54) : LA219_5 = self.input.LA(7) if (LA219_5 == 66 or LA219_5 == 98) : alt219 = 1 elif (LA219_7 == 52 or LA219_7 == 54) : LA219_5 = self.input.LA(6) if (LA219_5 == 66 or LA219_5 == 98) : alt219 = 1 elif (LA219_6 == 52 or LA219_6 == 54) : LA219_5 = self.input.LA(5) if (LA219_5 == 66 or LA219_5 == 98) : alt219 = 1 elif (LA219_4 == 52 or LA219_4 == 54) : LA219_5 = self.input.LA(4) if (LA219_5 == 66 or LA219_5 == 98) : alt219 = 1 elif LA219 == 52 or LA219 == 54: LA219_5 = self.input.LA(3) if (LA219_5 == 66 or LA219_5 == 98) : alt219 = 1 if alt219 == 1: # lesscss.g:872:5: K pass self.mK() self.mH() self.mZ() if self._state.backtracking == 0: _type = FREQ; elif alt224 == 14: # lesscss.g:874:6: ( D P ( I | C | P ) )=> D ( P I | P C M | P P X ) pass self.mD() # lesscss.g:876:5: ( P I | P C M | P P X ) alt220 = 3 alt220 = self.dfa220.predict(self.input) if alt220 == 1: # lesscss.g:876:7: P I pass self.mP() self.mI() if self._state.backtracking == 0: _type = RESOLUTION; elif alt220 == 2: # lesscss.g:877:7: P C M pass self.mP() self.mC() self.mM() if self._state.backtracking == 0: _type = RESOLUTION; elif alt220 == 3: # lesscss.g:878:7: P P X pass self.mP() self.mP() self.mX() if self._state.backtracking == 0: _type = RESOLUTION; elif alt224 == 15: # lesscss.g:881:6: ( V ( W | H | M ) )=> V ( W | H | M | M I N | M A X ) pass self.mV() # lesscss.g:883:5: ( W | H | M | M I N | M A X ) alt221 = 5 alt221 = self.dfa221.predict(self.input) if alt221 == 1: # lesscss.g:883:7: W pass self.mW() if self._state.backtracking == 0: _type = VPORTLEN; elif alt221 == 2: # lesscss.g:884:7: H pass self.mH() if self._state.backtracking == 0: _type = VPORTLEN; elif alt221 == 3: # lesscss.g:885:7: M pass self.mM() if self._state.backtracking == 0: _type = VPORTLEN; elif alt221 == 4: # lesscss.g:886:7: M I N pass self.mM() self.mI() self.mN() if self._state.backtracking == 0: _type = VPORTLEN; elif alt221 == 5: # lesscss.g:887:7: M A X pass self.mM() self.mA() self.mX() if self._state.backtracking == 0: _type = VPORTLEN; elif alt224 == 16: # lesscss.g:890:6: ( N )=> ( N ( PLUS | MINUS ) ( '0' .. '9' )+ | N ) pass # lesscss.g:891:5: ( N ( PLUS | MINUS ) ( '0' .. '9' )+ | N ) alt223 = 2 alt223 = self.dfa223.predict(self.input) if alt223 == 1: # lesscss.g:891:7: N ( PLUS | MINUS ) ( '0' .. '9' )+ pass self.mN() if self.input.LA(1) == 43 or self.input.LA(1) == 45: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # lesscss.g:891:26: ( '0' .. '9' )+ cnt222 = 0 while True: #loop222 alt222 = 2 LA222_0 = self.input.LA(1) if ((48 <= LA222_0 <= 57)) : alt222 = 1 if alt222 == 1: # lesscss.g:891:26: '0' .. '9' pass self.matchRange(48, 57) else: if cnt222 >= 1: break #loop222 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(222, self.input) raise eee cnt222 += 1 if self._state.backtracking == 0: _type = NTH; elif alt223 == 2: # lesscss.g:893:7: N pass self.mN() if self._state.backtracking == 0: _type = NTH; elif alt224 == 17: # lesscss.g:896:6: IDENT pass self.mIDENT() if self._state.backtracking == 0: _type = DIMENSION; elif alt224 == 18: # lesscss.g:898:6: '%' pass self.match(37) if self._state.backtracking == 0: _type = PERCENTAGE; elif alt224 == 19: # lesscss.g:901:3: pass self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NUMBER" # $ANTLR start "URI" def mURI(self, ): try: _type = URI _channel = DEFAULT_CHANNEL # lesscss.g:908:2: ( U R L '(' ( ( WS )=> WS )? ( URL | STRING ) ( WS )? ')' ) # lesscss.g:908:4: U R L '(' ( ( WS )=> WS )? ( URL | STRING ) ( WS )? ')' pass self.mU() self.mR() self.mL() self.match(40) # lesscss.g:910:4: ( ( WS )=> WS )? alt225 = 2 LA225_0 = self.input.LA(1) if (LA225_0 == 9 or LA225_0 == 32) : LA225_1 = self.input.LA(2) if (self.synpred17_lesscss()) : alt225 = 1 if alt225 == 1: # lesscss.g:910:5: ( WS )=> WS pass self.mWS() # lesscss.g:910:16: ( URL | STRING ) alt226 = 2 LA226_0 = self.input.LA(1) if ((9 <= LA226_0 <= 10) or (12 <= LA226_0 <= 13) or (32 <= LA226_0 <= 33) or (35 <= LA226_0 <= 38) or (41 <= LA226_0 <= 59) or LA226_0 == 61 or LA226_0 == 63 or (65 <= LA226_0 <= 91) or LA226_0 == 95 or (97 <= LA226_0 <= 122) or LA226_0 == 126) : alt226 = 1 elif (LA226_0 == 34 or LA226_0 == 39) : alt226 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 226, 0, self.input) raise nvae if alt226 == 1: # lesscss.g:910:17: URL pass self.mURL() elif alt226 == 2: # lesscss.g:910:21: STRING pass self.mSTRING() # lesscss.g:910:29: ( WS )? alt227 = 2 LA227_0 = self.input.LA(1) if (LA227_0 == 9 or LA227_0 == 32) : alt227 = 1 if alt227 == 1: # lesscss.g:910:29: WS pass self.mWS() self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "URI" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # lesscss.g:919:4: ( ( ' ' | '\\t' )+ ) # lesscss.g:919:6: ( ' ' | '\\t' )+ pass # lesscss.g:919:6: ( ' ' | '\\t' )+ cnt228 = 0 while True: #loop228 alt228 = 2 LA228_0 = self.input.LA(1) if (LA228_0 == 9 or LA228_0 == 32) : alt228 = 1 if alt228 == 1: # lesscss.g: pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt228 >= 1: break #loop228 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(228, self.input) raise eee cnt228 += 1 if self._state.backtracking == 0: _channel = HIDDEN; self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "NL" def mNL(self, ): try: _type = NL _channel = DEFAULT_CHANNEL # lesscss.g:920:4: ( ( '\\r' ( '\\n' )? | '\\n' ) ) # lesscss.g:920:6: ( '\\r' ( '\\n' )? | '\\n' ) pass # lesscss.g:920:6: ( '\\r' ( '\\n' )? | '\\n' ) alt230 = 2 LA230_0 = self.input.LA(1) if (LA230_0 == 13) : alt230 = 1 elif (LA230_0 == 10) : alt230 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 230, 0, self.input) raise nvae if alt230 == 1: # lesscss.g:920:7: '\\r' ( '\\n' )? pass self.match(13) # lesscss.g:920:12: ( '\\n' )? alt229 = 2 LA229_0 = self.input.LA(1) if (LA229_0 == 10) : alt229 = 1 if alt229 == 1: # lesscss.g:920:12: '\\n' pass self.match(10) elif alt230 == 2: # lesscss.g:920:20: '\\n' pass self.match(10) if self._state.backtracking == 0: _channel = HIDDEN; self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NL" def mTokens(self): # lesscss.g:1:8: ( COMMENT | CDO | CDC | INCLUDES | DASHMATCH | PREFIXMATCH | SUFFIXMATCH | SUBSTRINGMATCH | GREATER | LBRACE | RBRACE | LBRACKET | RBRACKET | OPEQ | SEMI | COLON | SOLIDUS | MINUS | PLUS | STAR | LPAREN | RPAREN | COMMA | DOT | STRING | UNICODE_RANGE | IDENT | FUNCTION | HASH | IMPORT_SYM | PAGE_SYM | MEDIA_SYM | FONTFACE_SYM | CHARSET_SYM | KEYFRAMES_SYM | LESS_VARNAME | IMPORTANT_SYM | NUMBER | URI | WS | NL ) alt231 = 41 alt231 = self.dfa231.predict(self.input) if alt231 == 1: # lesscss.g:1:10: COMMENT pass self.mCOMMENT() elif alt231 == 2: # lesscss.g:1:18: CDO pass self.mCDO() elif alt231 == 3: # lesscss.g:1:22: CDC pass self.mCDC() elif alt231 == 4: # lesscss.g:1:26: INCLUDES pass self.mINCLUDES() elif alt231 == 5: # lesscss.g:1:35: DASHMATCH pass self.mDASHMATCH() elif alt231 == 6: # lesscss.g:1:45: PREFIXMATCH pass self.mPREFIXMATCH() elif alt231 == 7: # lesscss.g:1:57: SUFFIXMATCH pass self.mSUFFIXMATCH() elif alt231 == 8: # lesscss.g:1:69: SUBSTRINGMATCH pass self.mSUBSTRINGMATCH() elif alt231 == 9: # lesscss.g:1:84: GREATER pass self.mGREATER() elif alt231 == 10: # lesscss.g:1:92: LBRACE pass self.mLBRACE() elif alt231 == 11: # lesscss.g:1:99: RBRACE pass self.mRBRACE() elif alt231 == 12: # lesscss.g:1:106: LBRACKET pass self.mLBRACKET() elif alt231 == 13: # lesscss.g:1:115: RBRACKET pass self.mRBRACKET() elif alt231 == 14: # lesscss.g:1:124: OPEQ pass self.mOPEQ() elif alt231 == 15: # lesscss.g:1:129: SEMI pass self.mSEMI() elif alt231 == 16: # lesscss.g:1:134: COLON pass self.mCOLON() elif alt231 == 17: # lesscss.g:1:140: SOLIDUS pass self.mSOLIDUS() elif alt231 == 18: # lesscss.g:1:148: MINUS pass self.mMINUS() elif alt231 == 19: # lesscss.g:1:154: PLUS pass self.mPLUS() elif alt231 == 20: # lesscss.g:1:159: STAR pass self.mSTAR() elif alt231 == 21: # lesscss.g:1:164: LPAREN pass self.mLPAREN() elif alt231 == 22: # lesscss.g:1:171: RPAREN pass self.mRPAREN() elif alt231 == 23: # lesscss.g:1:178: COMMA pass self.mCOMMA() elif alt231 == 24: # lesscss.g:1:184: DOT pass self.mDOT() elif alt231 == 25: # lesscss.g:1:188: STRING pass self.mSTRING() elif alt231 == 26: # lesscss.g:1:195: UNICODE_RANGE pass self.mUNICODE_RANGE() elif alt231 == 27: # lesscss.g:1:209: IDENT pass self.mIDENT() elif alt231 == 28: # lesscss.g:1:215: FUNCTION pass self.mFUNCTION() elif alt231 == 29: # lesscss.g:1:224: HASH pass self.mHASH() elif alt231 == 30: # lesscss.g:1:229: IMPORT_SYM pass self.mIMPORT_SYM() elif alt231 == 31: # lesscss.g:1:240: PAGE_SYM pass self.mPAGE_SYM() elif alt231 == 32: # lesscss.g:1:249: MEDIA_SYM pass self.mMEDIA_SYM() elif alt231 == 33: # lesscss.g:1:259: FONTFACE_SYM pass self.mFONTFACE_SYM() elif alt231 == 34: # lesscss.g:1:272: CHARSET_SYM pass self.mCHARSET_SYM() elif alt231 == 35: # lesscss.g:1:284: KEYFRAMES_SYM pass self.mKEYFRAMES_SYM() elif alt231 == 36: # lesscss.g:1:298: LESS_VARNAME pass self.mLESS_VARNAME() elif alt231 == 37: # lesscss.g:1:311: IMPORTANT_SYM pass self.mIMPORTANT_SYM() elif alt231 == 38: # lesscss.g:1:325: NUMBER pass self.mNUMBER() elif alt231 == 39: # lesscss.g:1:332: URI pass self.mURI() elif alt231 == 40: # lesscss.g:1:336: WS pass self.mWS() elif alt231 == 41: # lesscss.g:1:339: NL pass self.mNL() # $ANTLR start "synpred1_lesscss" def synpred1_lesscss_fragment(self, ): # lesscss.g:829:6: ( E ( M | X ) ) # lesscss.g:829:7: E ( M | X ) pass self.mE() # lesscss.g:829:9: ( M | X ) alt232 = 2 LA232 = self.input.LA(1) if LA232 == 77 or LA232 == 109: alt232 = 1 elif LA232 == 92: LA232 = self.input.LA(2) if LA232 == 52 or LA232 == 54 or LA232 == 77 or LA232 == 109: alt232 = 1 elif LA232 == 48: LA232 = self.input.LA(3) if LA232 == 48: LA232 = self.input.LA(4) if LA232 == 48: LA232 = self.input.LA(5) if LA232 == 48: LA232_7 = self.input.LA(6) if (LA232_7 == 53 or LA232_7 == 55) : alt232 = 2 elif (LA232_7 == 52 or LA232_7 == 54) : alt232 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 232, 7, self.input) raise nvae elif LA232 == 53 or LA232 == 55: alt232 = 2 elif LA232 == 52 or LA232 == 54: alt232 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 232, 6, self.input) raise nvae elif LA232 == 53 or LA232 == 55: alt232 = 2 elif LA232 == 52 or LA232 == 54: alt232 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 232, 5, self.input) raise nvae elif LA232 == 52 or LA232 == 54: alt232 = 1 elif LA232 == 53 or LA232 == 55: alt232 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 232, 4, self.input) raise nvae elif LA232 == 53 or LA232 == 55 or LA232 == 88 or LA232 == 120: alt232 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 232, 2, self.input) raise nvae elif LA232 == 88 or LA232 == 120: alt232 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 232, 0, self.input) raise nvae if alt232 == 1: # lesscss.g:829:10: M pass self.mM() elif alt232 == 2: # lesscss.g:829:12: X pass self.mX() # $ANTLR end "synpred1_lesscss" # $ANTLR start "synpred2_lesscss" def synpred2_lesscss_fragment(self, ): # lesscss.g:835:6: ( R E M ) # lesscss.g:835:7: R E M pass self.mR() self.mE() self.mM() # $ANTLR end "synpred2_lesscss" # $ANTLR start "synpred3_lesscss" def synpred3_lesscss_fragment(self, ): # lesscss.g:837:6: ( C H ) # lesscss.g:837:7: C H pass self.mC() self.mH() # $ANTLR end "synpred3_lesscss" # $ANTLR start "synpred4_lesscss" def synpred4_lesscss_fragment(self, ): # lesscss.g:840:6: ( P ( X | T | C ) ) # lesscss.g:840:8: P ( X | T | C ) pass self.mP() # lesscss.g:840:10: ( X | T | C ) alt233 = 3 alt233 = self.dfa233.predict(self.input) if alt233 == 1: # lesscss.g:840:12: X pass self.mX() elif alt233 == 2: # lesscss.g:840:16: T pass self.mT() elif alt233 == 3: # lesscss.g:840:20: C pass self.mC() # $ANTLR end "synpred4_lesscss" # $ANTLR start "synpred5_lesscss" def synpred5_lesscss_fragment(self, ): # lesscss.g:848:6: ( C M ) # lesscss.g:848:7: C M pass self.mC() self.mM() # $ANTLR end "synpred5_lesscss" # $ANTLR start "synpred6_lesscss" def synpred6_lesscss_fragment(self, ): # lesscss.g:850:6: ( M ( M | S ) ) # lesscss.g:850:7: M ( M | S ) pass self.mM() # lesscss.g:850:9: ( M | S ) alt234 = 2 LA234 = self.input.LA(1) if LA234 == 77 or LA234 == 109: alt234 = 1 elif LA234 == 92: LA234 = self.input.LA(2) if LA234 == 53 or LA234 == 55 or LA234 == 83 or LA234 == 115: alt234 = 2 elif LA234 == 48: LA234 = self.input.LA(3) if LA234 == 48: LA234 = self.input.LA(4) if LA234 == 48: LA234 = self.input.LA(5) if LA234 == 48: LA234_7 = self.input.LA(6) if (LA234_7 == 53 or LA234_7 == 55) : alt234 = 2 elif (LA234_7 == 52 or LA234_7 == 54) : alt234 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 234, 7, self.input) raise nvae elif LA234 == 53 or LA234 == 55: alt234 = 2 elif LA234 == 52 or LA234 == 54: alt234 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 234, 6, self.input) raise nvae elif LA234 == 53 or LA234 == 55: alt234 = 2 elif LA234 == 52 or LA234 == 54: alt234 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 234, 5, self.input) raise nvae elif LA234 == 52 or LA234 == 54: alt234 = 1 elif LA234 == 53 or LA234 == 55: alt234 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 234, 4, self.input) raise nvae elif LA234 == 52 or LA234 == 54 or LA234 == 77 or LA234 == 109: alt234 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 234, 2, self.input) raise nvae elif LA234 == 83 or LA234 == 115: alt234 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 234, 0, self.input) raise nvae if alt234 == 1: # lesscss.g:850:10: M pass self.mM() elif alt234 == 2: # lesscss.g:850:12: S pass self.mS() # $ANTLR end "synpred6_lesscss" # $ANTLR start "synpred7_lesscss" def synpred7_lesscss_fragment(self, ): # lesscss.g:857:6: ( I N ) # lesscss.g:857:7: I N pass self.mI() self.mN() # $ANTLR end "synpred7_lesscss" # $ANTLR start "synpred8_lesscss" def synpred8_lesscss_fragment(self, ): # lesscss.g:860:6: ( D E G ) # lesscss.g:860:7: D E G pass self.mD() self.mE() self.mG() # $ANTLR end "synpred8_lesscss" # $ANTLR start "synpred9_lesscss" def synpred9_lesscss_fragment(self, ): # lesscss.g:862:6: ( R A D ) # lesscss.g:862:7: R A D pass self.mR() self.mA() self.mD() # $ANTLR end "synpred9_lesscss" # $ANTLR start "synpred10_lesscss" def synpred10_lesscss_fragment(self, ): # lesscss.g:864:6: ( G R A D ) # lesscss.g:864:7: G R A D pass self.mG() self.mR() self.mA() self.mD() # $ANTLR end "synpred10_lesscss" # $ANTLR start "synpred11_lesscss" def synpred11_lesscss_fragment(self, ): # lesscss.g:866:6: ( T U R N ) # lesscss.g:866:7: T U R N pass self.mT() self.mU() self.mR() self.mN() # $ANTLR end "synpred11_lesscss" # $ANTLR start "synpred12_lesscss" def synpred12_lesscss_fragment(self, ): # lesscss.g:869:6: ( S ) # lesscss.g:869:7: S pass self.mS() # $ANTLR end "synpred12_lesscss" # $ANTLR start "synpred13_lesscss" def synpred13_lesscss_fragment(self, ): # lesscss.g:871:6: ( ( K )? H Z ) # lesscss.g:871:7: ( K )? H Z pass # lesscss.g:871:7: ( K )? alt235 = 2 LA235_0 = self.input.LA(1) if (LA235_0 == 75 or LA235_0 == 107) : alt235 = 1 elif (LA235_0 == 92) : LA235 = self.input.LA(2) if LA235 == 48: LA235_4 = self.input.LA(3) if (LA235_4 == 48) : LA235_6 = self.input.LA(4) if (LA235_6 == 48) : LA235_7 = self.input.LA(5) if (LA235_7 == 48) : LA235_8 = self.input.LA(6) if (LA235_8 == 52 or LA235_8 == 54) : LA235_5 = self.input.LA(7) if (LA235_5 == 66 or LA235_5 == 98) : alt235 = 1 elif (LA235_7 == 52 or LA235_7 == 54) : LA235_5 = self.input.LA(6) if (LA235_5 == 66 or LA235_5 == 98) : alt235 = 1 elif (LA235_6 == 52 or LA235_6 == 54) : LA235_5 = self.input.LA(5) if (LA235_5 == 66 or LA235_5 == 98) : alt235 = 1 elif (LA235_4 == 52 or LA235_4 == 54) : LA235_5 = self.input.LA(4) if (LA235_5 == 66 or LA235_5 == 98) : alt235 = 1 elif LA235 == 52 or LA235 == 54: LA235_5 = self.input.LA(3) if (LA235_5 == 66 or LA235_5 == 98) : alt235 = 1 elif LA235 == 75 or LA235 == 107: alt235 = 1 if alt235 == 1: # lesscss.g:871:7: K pass self.mK() self.mH() self.mZ() # $ANTLR end "synpred13_lesscss" # $ANTLR start "synpred14_lesscss" def synpred14_lesscss_fragment(self, ): # lesscss.g:874:6: ( D P ( I | C | P ) ) # lesscss.g:874:7: D P ( I | C | P ) pass self.mD() self.mP() # lesscss.g:874:11: ( I | C | P ) alt236 = 3 alt236 = self.dfa236.predict(self.input) if alt236 == 1: # lesscss.g:874:13: I pass self.mI() elif alt236 == 2: # lesscss.g:874:17: C pass self.mC() elif alt236 == 3: # lesscss.g:874:21: P pass self.mP() # $ANTLR end "synpred14_lesscss" # $ANTLR start "synpred15_lesscss" def synpred15_lesscss_fragment(self, ): # lesscss.g:881:6: ( V ( W | H | M ) ) # lesscss.g:881:8: V ( W | H | M ) pass self.mV() # lesscss.g:881:10: ( W | H | M ) alt237 = 3 alt237 = self.dfa237.predict(self.input) if alt237 == 1: # lesscss.g:881:12: W pass self.mW() elif alt237 == 2: # lesscss.g:881:16: H pass self.mH() elif alt237 == 3: # lesscss.g:881:20: M pass self.mM() # $ANTLR end "synpred15_lesscss" # $ANTLR start "synpred16_lesscss" def synpred16_lesscss_fragment(self, ): # lesscss.g:890:6: ( N ) # lesscss.g:890:7: N pass self.mN() # $ANTLR end "synpred16_lesscss" # $ANTLR start "synpred17_lesscss" def synpred17_lesscss_fragment(self, ): # lesscss.g:910:5: ( WS ) # lesscss.g:910:6: WS pass self.mWS() # $ANTLR end "synpred17_lesscss" def synpred11_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred11_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred16_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred16_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred13_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred13_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred3_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred3_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred5_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred5_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred2_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred2_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred8_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred8_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred6_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred6_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred12_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred12_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred14_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred14_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred4_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred4_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred7_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred7_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred17_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred17_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred9_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred9_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred15_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred15_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred10_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred10_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success def synpred1_lesscss(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred1_lesscss_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success # lookup tables for DFA #198 DFA198_eot = DFA.unpack( u"\4\uffff\1\11\6\uffff" ) DFA198_eof = DFA.unpack( u"\13\uffff" ) DFA198_min = DFA.unpack( u"\1\42\3\uffff\1\60\6\uffff" ) DFA198_max = DFA.unpack( u"\1\165\3\uffff\1\146\6\uffff" ) DFA198_accept = DFA.unpack( u"\1\uffff\1\1\1\2\1\3\1\uffff\1\5\1\6\1\7\1\10\1\4\1\11" ) DFA198_special = DFA.unpack( u"\13\uffff" ) DFA198_transition = [ DFA.unpack(u"\1\5\4\uffff\1\6\10\uffff\12\4\7\uffff\6\4\25\uffff" u"\1\7\4\uffff\6\4\7\uffff\1\1\3\uffff\1\2\1\uffff\1\3\1\10"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\12\7\uffff\6\12\32\uffff\6\12"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #198 class DFA198(DFA): pass # lookup tables for DFA #204 DFA204_eot = DFA.unpack( u"\1\uffff\1\3\3\uffff" ) DFA204_eof = DFA.unpack( u"\5\uffff" ) DFA204_min = DFA.unpack( u"\1\60\1\55\3\uffff" ) DFA204_max = DFA.unpack( u"\2\146\3\uffff" ) DFA204_accept = DFA.unpack( u"\2\uffff\1\2\1\1\1\3" ) DFA204_special = DFA.unpack( u"\5\uffff" ) DFA204_transition = [ DFA.unpack(u"\12\1\5\uffff\1\2\1\uffff\6\1\32\uffff\6\1"), DFA.unpack(u"\1\4\2\uffff\12\1\5\uffff\1\2\1\uffff\6\1\32\uffff" u"\6\1"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #204 class DFA204(DFA): pass # lookup tables for DFA #207 DFA207_eot = DFA.unpack( u"\30\uffff" ) DFA207_eof = DFA.unpack( u"\30\uffff" ) DFA207_min = DFA.unpack( u"\1\100\1\55\1\115\2\uffff\1\60\1\11\1\uffff\1\60\1\104\2\117\1" u"\11\1\uffff\1\60\1\uffff\1\60\1\117\3\60\1\64\1\60\1\64" ) DFA207_max = DFA.unpack( u"\1\100\1\153\1\167\2\uffff\1\167\1\163\1\uffff\1\67\1\146\3\163" u"\1\uffff\1\163\1\uffff\1\67\1\163\6\67" ) DFA207_accept = DFA.unpack( u"\3\uffff\1\1\1\5\2\uffff\1\2\5\uffff\1\3\1\uffff\1\4\10\uffff" ) DFA207_special = DFA.unpack( u"\30\uffff" ) DFA207_transition = [ DFA.unpack(u"\1\1"), DFA.unpack(u"\1\2\35\uffff\1\3\20\uffff\1\3\16\uffff\1\3"), DFA.unpack(u"\1\6\1\uffff\1\4\7\uffff\1\7\4\uffff\1\5\20\uffff\1" u"\6\1\uffff\1\4\7\uffff\1\7"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\10\3\uffff\1\11\1\7\1\11\1\7\25\uffff\1\13\1\uffff" u"\1\4\7\uffff\1\7\25\uffff\1\12\1\uffff\1\4\7\uffff\1\7"), DFA.unpack(u"\2\14\1\uffff\2\14\22\uffff\1\14\56\uffff\1\15\3\uffff" u"\1\17\10\uffff\1\16\22\uffff\1\15\3\uffff\1\17"), DFA.unpack(u""), DFA.unpack(u"\1\20\3\uffff\1\11\1\7\1\11\1\7"), DFA.unpack(u"\1\21\1\uffff\1\4\35\uffff\1\21\1\uffff\1\4"), DFA.unpack(u"\1\15\3\uffff\1\17\10\uffff\1\16\22\uffff\1\15\3\uffff" u"\1\17"), DFA.unpack(u"\1\15\3\uffff\1\17\10\uffff\1\16\22\uffff\1\15\3\uffff" u"\1\17"), DFA.unpack(u"\2\14\1\uffff\2\14\22\uffff\1\14\56\uffff\1\15\3\uffff" u"\1\17\10\uffff\1\16\22\uffff\1\15\3\uffff\1\17"), DFA.unpack(u""), DFA.unpack(u"\1\22\3\uffff\1\15\1\17\1\15\1\17\27\uffff\1\15\3\uffff" u"\1\17\33\uffff\1\15\3\uffff\1\17"), DFA.unpack(u""), DFA.unpack(u"\1\23\3\uffff\1\11\1\7\1\11\1\7"), DFA.unpack(u"\1\15\3\uffff\1\17\10\uffff\1\16\22\uffff\1\15\3\uffff" u"\1\17"), DFA.unpack(u"\1\24\3\uffff\1\15\1\17\1\15\1\17"), DFA.unpack(u"\1\25\3\uffff\1\11\1\7\1\11\1\7"), DFA.unpack(u"\1\26\3\uffff\1\15\1\17\1\15\1\17"), DFA.unpack(u"\1\11\1\7\1\11\1\7"), DFA.unpack(u"\1\27\3\uffff\1\15\1\17\1\15\1\17"), DFA.unpack(u"\1\15\1\17\1\15\1\17") ] # class definition for DFA #207 class DFA207(DFA): pass # lookup tables for DFA #224 DFA224_eot = DFA.unpack( u"\1\40\1\20\1\uffff\10\20\1\uffff\3\20\2\uffff\11\20\1\uffff\3\20" u"\11\uffff\6\20\1\uffff\1\20\1\uffff\4\20\2\uffff\14\20\2\uffff" u"\2\20\30\uffff\2\20\2\uffff\4\20\2\uffff\2\20\3\uffff\2\20\20\uffff" u"\1\20\2\uffff\2\20\1\uffff\4\20\1\uffff\7\20\1\uffff\6\20\5\uffff" u"\2\20\15\uffff\2\20\4\uffff\2\20\1\uffff\1\20\3\uffff\2\20\1\uffff" u"\1\20\2\uffff\2\20\4\uffff\5\20\4\uffff\1\20\1\uffff\3\20\2\uffff" u"\2\20\2\uffff\4\20\1\uffff\1\20\1\uffff\11\20\1\uffff\1\20\1\uffff" u"\1\20\3\uffff\3\20\3\uffff\3\20\3\uffff\4\20\1\uffff\10\20\1\uffff" u"\5\20\1\uffff\2\20\2\uffff\4\20\2\uffff\6\20\2\uffff\2\20\6\uffff" u"\2\20\3\uffff\3\20\3\uffff\3\20\3\uffff\2\20\4\uffff\7\20\11\uffff" u"\2\20\1\uffff\2\20\1\uffff\1\20\10\uffff\5\20\4\uffff\14\20\2\uffff" u"\3\20\4\uffff\3\20\3\uffff\11\20\1\uffff\4\20\1\uffff\4\20\1\uffff" u"\2\20\2\uffff\6\20\2\uffff\3\20\2\uffff\4\20\5\uffff\2\20\4\uffff" u"\2\20\3\uffff\3\20\3\uffff\3\20\3\uffff\2\20\2\uffff\2\20\1\uffff" u"\7\20\3\uffff\6\20\1\uffff\1\20\2\uffff\14\20\1\uffff\1\20\1\uffff" u"\14\20\2\uffff\3\20\4\uffff\3\20\3\uffff\6\20\1\uffff\6\20\1\uffff" u"\4\20\1\uffff\2\20\2\uffff\4\20\2\uffff\2\20\2\uffff\4\20\3\uffff" u"\2\20\2\uffff\2\20\3\uffff\3\20\3\uffff\3\20\3\uffff\2\20\2\uffff" u"\2\20\1\uffff\10\20\1\uffff\2\20\2\uffff\4\20\1\uffff\3\20\1\uffff" u"\2\20\1\uffff\3\20\2\uffff\5\20\2\uffff\3\20\2\uffff\13\20\2\uffff" u"\3\20\4\uffff\2\20\3\uffff\4\20\1\uffff\6\20\1\uffff\4\20\1\uffff" u"\2\20\2\uffff\4\20\2\uffff\2\20\2\uffff\3\20\3\uffff\2\20\2\uffff" u"\1\20\3\uffff\2\20\3\uffff\2\20\3\uffff\1\20\2\uffff\2\20\1\uffff" u"\6\20\1\uffff\2\20\2\uffff\4\20\1\uffff\3\20\1\uffff\2\20\1\uffff" u"\7\20\2\uffff\2\20\2\uffff\10\20\2\uffff\2\20\7\uffff\1\20\2\uffff" u"\2\20\2\uffff\1\20\14\uffff\1\20\1\uffff\6\20\2\uffff\3\20\1\uffff" u"\3\20\1\uffff\2\20\1\uffff\5\20\2\uffff\2\20\2\uffff\4\20\12\uffff" u"\1\20\2\uffff\1\20\1\uffff\2\20\1\uffff\1\20\1\uffff\2\20\2\uffff" u"\1\20\6\uffff" ) DFA224_eof = DFA.unpack( u"\u0360\uffff" ) DFA224_min = DFA.unpack( u"\1\45\1\11\1\0\10\11\1\0\3\11\1\0\1\uffff\11\11\1\0\3\11\1\0\2" u"\uffff\3\0\1\uffff\2\0\2\132\1\101\1\60\1\63\1\101\1\0\1\60\1\0" u"\2\115\2\110\2\0\2\125\2\103\2\122\2\116\2\110\2\11\1\0\4\11\5" u"\0\1\uffff\12\0\1\uffff\5\0\1\uffff\2\11\1\0\5\11\1\0\1\uffff\2" u"\11\1\0\2\uffff\2\11\1\0\1\uffff\3\0\1\uffff\3\0\1\uffff\4\0\1" u"\uffff\1\0\1\60\2\0\1\70\1\104\1\0\1\60\1\63\1\60\1\132\1\0\1\115" u"\1\110\1\105\1\122\1\116\1\115\1\110\1\0\1\115\1\110\1\103\1\101" u"\1\110\1\125\1\0\1\uffff\3\0\1\60\1\61\1\uffff\1\60\2\uffff\3\0" u"\1\uffff\1\60\1\uffff\3\0\1\60\1\70\4\0\1\60\1\64\1\0\1\63\3\0" u"\1\60\1\63\1\0\1\104\2\0\1\60\1\105\1\uffff\3\0\2\103\2\60\1\65" u"\1\uffff\1\60\2\uffff\1\11\1\0\3\11\2\0\2\11\1\0\1\uffff\2\101" u"\1\60\1\62\1\uffff\1\11\1\0\1\11\2\122\1\60\1\65\2\132\1\60\1\70" u"\1\0\1\60\1\0\1\101\3\0\1\60\1\70\1\67\3\0\1\60\1\104\1\70\3\0" u"\1\60\1\63\1\60\1\110\1\0\1\110\1\115\1\122\1\105\1\116\1\132\1" u"\115\1\110\1\0\1\115\1\103\1\101\1\110\1\125\1\0\2\11\2\0\4\11" u"\2\0\1\60\1\104\1\60\1\61\1\104\1\115\1\60\1\61\1\60\1\64\2\uffff" u"\1\60\1\70\2\uffff\1\60\1\70\3\0\1\60\1\64\1\63\3\0\1\60\1\63\1" u"\104\3\0\1\60\1\105\4\0\1\60\1\67\2\60\1\65\1\103\1\107\2\uffff" u"\1\60\3\uffff\3\0\2\130\1\0\2\60\1\0\1\63\3\0\1\uffff\3\0\1\uffff" u"\1\60\1\61\1\60\1\62\1\101\1\uffff\3\0\2\116\1\60\1\62\1\60\1\65" u"\1\122\1\60\1\70\1\132\1\60\1\101\2\0\1\60\1\70\1\67\4\0\1\60\1" u"\70\1\104\3\0\1\64\1\63\1\60\2\110\1\115\1\122\1\105\1\116\1\0" u"\1\132\1\115\1\110\1\115\1\0\1\103\1\101\1\110\1\125\1\0\2\11\2" u"\0\6\11\2\0\1\11\1\60\1\104\2\0\1\60\1\61\1\115\1\104\2\0\1\60" u"\2\uffff\1\60\1\64\1\0\1\60\2\uffff\1\60\1\70\3\0\1\60\1\64\1\63" u"\3\0\1\60\1\104\1\63\3\0\1\60\1\105\2\0\1\60\1\67\1\0\2\60\1\65" u"\1\103\1\107\2\11\1\60\2\0\1\60\1\104\1\60\1\63\1\60\1\130\1\0" u"\1\115\2\0\1\60\1\70\1\60\1\64\1\60\1\61\1\104\1\60\1\62\1\101" u"\2\11\1\0\1\60\1\0\1\105\1\60\1\62\1\116\1\60\1\65\1\122\1\60\1" u"\70\1\132\1\60\1\101\2\0\1\60\1\70\1\67\4\0\1\64\1\104\1\70\3\0" u"\1\63\1\60\1\110\1\122\1\110\1\115\1\0\1\116\1\115\1\105\1\132" u"\1\110\1\115\1\0\1\103\1\101\1\110\1\125\1\0\2\11\2\0\4\11\2\0" u"\1\60\1\104\2\0\1\64\1\61\1\115\1\104\2\0\2\60\1\64\1\0\1\60\1" u"\64\1\70\3\0\2\64\1\63\3\0\1\64\1\104\1\63\3\0\1\64\1\105\2\0\1" u"\60\1\67\1\0\1\64\1\60\1\65\1\103\1\107\3\11\2\60\1\104\2\0\1\60" u"\1\63\1\60\1\115\1\0\1\130\1\60\1\70\1\0\1\60\1\64\1\0\1\60\1\61" u"\1\104\2\0\1\65\1\62\1\101\2\11\2\0\1\11\1\60\1\105\2\0\1\60\1" u"\62\1\116\2\65\1\122\1\64\1\70\1\132\1\65\1\101\2\0\1\64\1\70\1" u"\67\4\0\1\104\1\70\3\0\2\110\1\122\1\115\1\0\1\115\1\116\1\132" u"\1\105\1\110\1\115\1\0\1\103\1\101\1\110\1\125\1\0\2\11\2\0\4\11" u"\2\0\1\64\1\104\2\0\1\61\1\115\1\104\2\0\3\64\1\0\1\64\1\70\3\0" u"\1\63\1\64\3\0\1\104\1\63\3\0\1\105\2\0\1\64\1\67\1\0\1\65\1\60" u"\1\103\1\107\2\11\1\64\1\60\1\104\2\0\1\64\1\63\1\60\1\115\1\0" u"\1\130\1\60\1\70\1\0\1\60\1\64\1\0\1\64\1\61\1\104\1\62\1\101\2" u"\11\2\0\1\60\1\105\2\0\1\65\1\62\1\116\1\65\1\122\1\70\1\132\1" u"\101\2\0\1\70\1\67\7\0\1\104\2\0\1\104\1\115\2\0\1\64\14\0\1\67" u"\1\0\1\107\1\103\2\11\1\64\1\104\2\0\1\63\1\60\1\115\1\0\1\130" u"\1\65\1\70\1\0\2\64\1\0\1\61\1\104\1\101\2\11\2\0\1\64\1\105\2" u"\0\1\62\1\116\1\122\1\132\12\0\1\104\2\0\1\115\1\0\1\130\1\70\1" u"\0\1\64\1\0\1\104\1\105\2\0\1\116\6\0" ) DFA224_max = DFA.unpack( u"\1\172\1\170\1\uffff\1\145\1\155\1\170\1\163\1\156\1\160\1\162" u"\1\165\1\0\1\150\1\172\1\167\1\0\1\uffff\1\170\1\145\1\155\1\170" u"\1\163\1\156\1\160\1\162\1\165\1\0\1\150\1\172\1\167\1\0\2\uffff" u"\2\0\1\uffff\1\uffff\2\0\2\172\1\145\1\67\2\145\1\0\1\66\1\0\2" u"\163\2\167\2\0\2\165\2\170\2\162\2\156\2\150\2\155\1\uffff\1\145" u"\2\144\1\155\1\0\1\uffff\3\0\1\uffff\1\0\1\uffff\7\0\1\uffff\1" u"\uffff\4\0\1\uffff\1\uffff\2\147\1\uffff\3\160\2\141\1\uffff\1" u"\uffff\2\162\1\uffff\2\uffff\2\172\1\uffff\1\uffff\2\0\1\uffff" u"\1\uffff\2\0\1\uffff\1\uffff\4\0\1\uffff\1\0\1\67\2\0\1\70\1\144" u"\1\0\1\67\1\145\1\66\1\172\1\0\1\163\1\155\1\160\1\162\1\156\1" u"\170\1\150\1\0\1\163\1\150\1\170\1\145\1\167\1\165\1\0\1\uffff" u"\1\0\1\uffff\1\0\1\66\1\65\1\uffff\1\66\2\uffff\1\0\1\uffff\1\0" u"\1\uffff\1\155\1\uffff\3\0\1\66\1\144\4\0\1\67\1\70\1\0\1\63\3" u"\0\1\67\1\63\1\0\1\144\2\0\1\66\1\145\1\uffff\1\0\1\uffff\1\0\2" u"\160\1\67\1\60\1\65\1\uffff\1\160\2\uffff\1\155\1\uffff\1\155\2" u"\170\2\0\2\144\1\uffff\1\uffff\2\141\1\67\1\62\1\uffff\1\156\1" u"\uffff\1\156\2\162\1\67\1\65\2\172\1\66\1\70\1\0\1\67\1\0\1\141" u"\3\0\1\67\1\144\1\67\3\0\1\67\1\144\1\70\3\0\1\67\1\145\1\66\1" u"\150\1\0\1\155\1\163\1\162\1\160\1\156\1\172\1\170\1\150\1\0\1" u"\163\1\170\1\145\1\167\1\165\1\0\2\147\2\0\2\144\2\155\2\0\1\66" u"\1\144\1\66\1\65\1\144\1\155\1\66\1\65\1\66\1\64\2\uffff\1\66\1" u"\144\2\uffff\1\66\1\144\3\0\1\67\1\70\1\63\3\0\1\67\1\63\1\144" u"\3\0\1\66\1\145\4\0\1\66\2\67\1\60\1\65\1\160\1\147\2\uffff\1\67" u"\3\uffff\1\0\1\uffff\1\0\2\170\1\0\1\67\1\60\1\0\1\71\2\0\1\uffff" u"\1\uffff\2\0\1\uffff\1\uffff\1\66\1\61\1\67\1\62\1\141\1\uffff" u"\1\0\1\uffff\1\0\2\156\1\67\1\62\1\67\1\65\1\162\1\66\1\70\1\172" u"\1\67\1\141\2\0\1\67\1\144\1\67\4\0\1\67\1\70\1\144\3\0\1\67\1" u"\145\1\66\1\150\1\155\1\163\1\162\1\160\1\156\1\0\1\172\1\170\1" u"\150\1\163\1\0\1\170\1\145\1\167\1\165\1\0\2\147\2\0\2\144\2\155" u"\1\147\1\144\2\0\1\155\1\66\1\144\2\0\1\66\1\65\1\155\1\144\2\0" u"\1\66\2\uffff\1\66\1\64\1\0\1\66\2\uffff\1\66\1\144\3\0\1\67\1" u"\70\1\63\3\0\1\67\1\144\1\63\3\0\1\66\1\145\2\0\1\66\1\67\1\0\1" u"\67\1\60\1\65\1\160\1\147\2\155\1\67\2\0\1\66\1\144\1\67\1\71\1" u"\60\1\170\1\0\1\155\2\0\1\67\1\70\1\66\1\64\1\66\1\61\1\144\1\67" u"\1\62\1\141\2\144\1\0\1\66\1\0\1\145\1\67\1\62\1\156\1\67\1\65" u"\1\162\1\66\1\70\1\172\1\67\1\141\2\0\1\67\1\144\1\67\4\0\1\67" u"\1\144\1\70\3\0\1\145\1\66\1\150\1\162\1\155\1\163\1\0\1\156\1" u"\170\1\160\1\172\1\150\1\163\1\0\1\170\1\145\1\167\1\165\1\0\2" u"\147\2\0\1\144\1\155\1\144\1\155\2\0\1\66\1\144\2\0\1\66\1\65\1" u"\155\1\144\2\0\2\66\1\64\1\0\2\66\1\144\3\0\1\67\1\70\1\63\3\0" u"\1\67\1\144\1\63\3\0\1\66\1\145\2\0\1\66\1\67\1\0\1\67\1\60\1\65" u"\1\160\1\147\3\155\1\67\1\66\1\144\2\0\1\67\1\71\1\60\1\155\1\0" u"\1\170\1\67\1\70\1\0\1\66\1\64\1\0\1\66\1\61\1\144\2\0\1\67\1\62" u"\1\141\2\144\2\0\1\144\1\66\1\145\2\0\1\67\1\62\1\156\1\67\1\65" u"\1\162\1\66\1\70\1\172\1\67\1\141\2\0\1\67\1\144\1\67\4\0\1\144" u"\1\70\3\0\1\155\1\150\1\162\1\163\1\0\1\170\1\156\1\172\1\160\1" u"\150\1\163\1\0\1\170\1\145\1\167\1\165\1\0\2\147\2\0\2\144\2\155" u"\2\0\1\66\1\144\2\0\1\65\1\155\1\144\2\0\2\66\1\64\1\0\1\66\1\144" u"\3\0\1\63\1\70\3\0\1\144\1\63\3\0\1\145\2\0\1\66\1\67\1\0\1\65" u"\1\60\1\160\1\147\2\155\1\67\1\66\1\144\2\0\1\67\1\71\1\60\1\155" u"\1\0\1\170\1\67\1\70\1\0\1\66\1\64\1\0\1\66\1\61\1\144\1\62\1\141" u"\2\144\2\0\1\66\1\145\2\0\1\67\1\62\1\156\1\65\1\162\1\70\1\172" u"\1\141\2\0\1\144\1\67\7\0\1\144\2\0\1\144\1\155\2\0\1\64\14\0\1" u"\67\1\0\1\147\1\160\2\155\1\66\1\144\2\0\1\71\1\60\1\155\1\0\1" u"\170\1\67\1\70\1\0\1\66\1\64\1\0\1\61\1\144\1\141\2\144\2\0\1\66" u"\1\145\2\0\1\62\1\156\1\162\1\172\12\0\1\144\2\0\1\155\1\0\1\170" u"\1\70\1\0\1\64\1\0\1\144\1\145\2\0\1\156\6\0" ) DFA224_accept = DFA.unpack( u"\20\uffff\1\21\16\uffff\1\22\1\23\3\uffff\1\1\47\uffff\1\4\12\uffff" u"\1\6\5\uffff\1\7\11\uffff\1\12\3\uffff\1\13\1\14\3\uffff\1\15\3" u"\uffff\1\15\3\uffff\1\17\4\uffff\1\20\33\uffff\1\2\5\uffff\1\11" u"\1\uffff\1\2\1\11\3\uffff\1\3\1\uffff\1\5\30\uffff\1\10\10\uffff" u"\1\10\1\uffff\2\16\12\uffff\1\12\4\uffff\1\13\106\uffff\2\3\2\uffff" u"\2\5\36\uffff\2\16\1\uffff\1\16\1\10\1\16\15\uffff\1\16\3\uffff" u"\1\12\5\uffff\1\13\112\uffff\1\11\1\2\4\uffff\1\3\1\5\u01a8\uffff" ) DFA224_special = DFA.unpack( u"\1\uffff\1\64\1\u0083\2\uffff\1\74\1\17\1\u0081\1\uffff\1\u0111" u"\1\u0150\1\u00d7\1\165\1\164\1\u00fe\1\u00a4\1\uffff\1\66\2\uffff" u"\1\73\1\24\1\u0080\1\uffff\1\u010a\1\u014f\1\u00d6\1\166\1\144" u"\1\u00fd\1\u00a6\2\uffff\1\u0163\1\u0162\1\u0106\1\uffff\1\u00e1" u"\1\u00df\6\uffff\1\u00b6\1\uffff\1\u00b4\4\uffff\1\u0144\1\u0145" u"\12\uffff\1\u0149\1\u0148\1\u00ff\1\137\1\132\1\131\1\u00c4\1\u0160" u"\1\u0167\1\u0161\1\14\1\13\1\uffff\1\u0100\1\u00a3\1\10\1\u00e3" u"\1\u00fb\1\11\1\u00e2\1\u0137\1\u0136\1\u0107\1\uffff\1\u0139\1" u"\u0131\1\113\1\112\1\u00cb\1\uffff\1\u008e\1\u008d\1\75\1\u00f2" u"\1\u00ed\1\u00ec\1\u0118\1\u0117\1\u0146\1\uffff\1\67\1\63\1\15" u"\2\uffff\1\102\1\101\1\u0114\1\uffff\1\34\1\33\1\u015c\1\uffff" u"\1\u011c\1\u011d\1\5\1\uffff\1\156\1\153\1\u00f0\1\u00ef\1\uffff" u"\1\u0097\1\uffff\1\u0095\1\u0093\2\uffff\1\u0094\4\uffff\1\157" u"\7\uffff\1\162\6\uffff\1\u00f8\1\uffff\1\121\1\u0124\1\120\6\uffff" u"\1\170\1\u00c2\1\167\1\uffff\1\u00a5\1\uffff\1\u010c\1\u010b\1" u"\u0099\2\uffff\1\u009c\1\123\1\122\1\u00bc\2\uffff\1\u00bb\1\uffff" u"\1\104\1\105\1\160\2\uffff\1\161\1\uffff\1\135\1\134\3\uffff\1" u"\u0151\1\u00b8\1\u0152\6\uffff\1\u00ac\2\uffff\1\124\1\7\1\130" u"\1\u011a\1\u011b\1\u00f9\1\u00fa\1\126\1\125\1\140\6\uffff\1\u0087" u"\1\u0147\1\u0086\10\uffff\1\u00b9\1\uffff\1\u00ba\1\uffff\1\u013e" u"\1\u013f\1\u010d\3\uffff\1\u010f\1\u0096\1\u0098\3\uffff\1\127" u"\1\146\1\147\4\uffff\1\u00a0\10\uffff\1\u00a2\5\uffff\1\u0122\2" u"\uffff\1\50\1\51\4\uffff\1\u0091\1\u0085\7\uffff\1\u009f\5\uffff" u"\1\u0115\4\uffff\1\26\1\u00ea\1\u00e9\3\uffff\1\4\1\151\1\u00e0" u"\3\uffff\1\6\1\u00fc\1\u00e8\2\uffff\1\u00d3\1\u00d4\1\u0112\1" u"\u0113\11\uffff\1\u010e\3\uffff\1\40\1\u0138\1\44\2\uffff\1\u00b7" u"\2\uffff\1\u00b5\1\uffff\1\u014e\1\u0153\1\u009e\1\uffff\1\176" u"\1\177\1\u00c5\7\uffff\1\22\1\u00dc\1\20\14\uffff\1\u0109\1\u0108" u"\3\uffff\1\55\1\163\1\56\1\u00bd\3\uffff\1\u00f3\1\u00f1\1\u0082" u"\11\uffff\1\16\4\uffff\1\23\4\uffff\1\u0157\2\uffff\1\u015d\1\u015e" u"\6\uffff\1\u013b\1\u013a\3\uffff\1\u00f4\1\u00f6\4\uffff\1\u0128" u"\1\u0129\5\uffff\1\72\5\uffff\1\u00c8\1\u009a\1\u00c9\3\uffff\1" u"\52\1\u00a7\1\u0166\3\uffff\1\62\1\u00d2\1\u00c1\2\uffff\1\u014d" u"\1\u014c\2\uffff\1\42\7\uffff\1\46\1\110\1\111\6\uffff\1\150\1" u"\uffff\1\u0103\1\u0104\14\uffff\1\114\1\uffff\1\116\14\uffff\1" u"\u00da\1\u00db\3\uffff\1\3\1\u00e6\1\2\1\u00d9\3\uffff\1\u00bf" u"\1\u00c6\1\u00c7\6\uffff\1\65\6\uffff\1\70\4\uffff\1\u00be\2\uffff" u"\1\u0127\1\u012c\4\uffff\1\u016a\1\u016b\2\uffff\1\u00d0\1\u00ce" u"\4\uffff\1\71\1\76\3\uffff\1\32\3\uffff\1\u013c\1\145\1\u013d\3" u"\uffff\1\143\1\u00c0\1\u0130\3\uffff\1\u014b\1\u014a\1\133\2\uffff" u"\1\u0121\1\u0120\2\uffff\1\u00ad\10\uffff\1\u00f7\2\uffff\1\u0169" u"\1\u0168\4\uffff\1\u00eb\3\uffff\1\u00cd\2\uffff\1\100\3\uffff" u"\1\106\1\107\5\uffff\1\35\1\36\3\uffff\1\u00e4\1\u00e5\13\uffff" u"\1\u0158\1\u0159\3\uffff\1\u0090\1\u00c3\1\u008f\1\u0105\2\uffff" u"\1\u0142\1\u0141\1\u00d8\4\uffff\1\u00de\6\uffff\1\u00dd\4\uffff" u"\1\u00a1\2\uffff\1\u00aa\1\u00a9\4\uffff\1\172\1\173\2\uffff\1" u"\u0156\1\u0155\3\uffff\1\25\1\21\3\uffff\1\77\2\uffff\1\u0119\1" u"\u00ee\1\u0116\2\uffff\1\u008c\1\u00e7\1\61\2\uffff\1\u011e\1\u011f" u"\1\u008a\1\uffff\1\117\1\115\2\uffff\1\171\6\uffff\1\u015b\2\uffff" u"\1\u0133\1\u0132\4\uffff\1\u00ca\3\uffff\1\u00f5\2\uffff\1\37\7" u"\uffff\1\30\1\31\2\uffff\1\u0165\1\u0164\10\uffff\1\u012f\1\u012e" u"\2\uffff\1\142\1\u0143\1\141\1\u012a\1\u00b0\1\u00b1\1\12\1\uffff" u"\1\u0123\1\u0126\2\uffff\1\u00cc\1\u00cf\1\uffff\1\27\1\43\1\u00ae" u"\1\u00b3\1\174\1\u015a\1\47\1\u009d\1\u009b\1\u015f\1\155\1\152" u"\1\uffff\1\u0110\6\uffff\1\1\1\0\3\uffff\1\u0140\3\uffff\1\u0125" u"\2\uffff\1\103\5\uffff\1\u00d5\1\u00d1\2\uffff\1\u0135\1\u0134" u"\4\uffff\1\u0092\1\u008b\1\u00b2\1\u012d\1\u012b\1\136\1\u0089" u"\1\u0088\1\u00af\1\45\1\uffff\1\57\1\60\1\uffff\1\u00ab\2\uffff" u"\1\u0154\1\uffff\1\41\2\uffff\1\53\1\54\1\uffff\1\u0101\1\u0102" u"\1\154\1\u00a8\1\u0084\1\175" ) DFA224_transition = [ DFA.unpack(u"\1\37\7\uffff\1\20\23\uffff\2\20\1\23\1\27\1\21\1\20" u"\1\30\1\34\1\26\1\20\1\33\1\20\1\25\1\36\1\20\1\24\1\20\1\22\1" u"\32\1\31\1\20\1\35\4\20\1\uffff\1\2\2\uffff\1\20\1\uffff\2\20\1" u"\4\1\10\1\1\1\20\1\11\1\15\1\7\1\20\1\14\1\20\1\6\1\17\1\20\1\5" u"\1\20\1\3\1\13\1\12\1\20\1\16\4\20"), DFA.unpack(u"\2\44\1\uffff\2\44\22\uffff\1\44\54\uffff\1\42\12\uffff" u"\1\46\3\uffff\1\43\20\uffff\1\41\12\uffff\1\45"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\52\3\20\1\53\1" u"\56\1\53\1\56\17\20\1\73\1\50\1\75\1\20\1\77\1\20\1\61\1\57\1\20" u"\1\71\1\20\1\54\1\65\1\67\1\20\1\63\20\20\1\72\1\47\1\74\1\20\1" u"\76\1\20\1\60\1\55\1\20\1\70\1\20\1\51\1\64\1\66\1\20\1\62\uff89" u"\20"), DFA.unpack(u"\2\103\1\uffff\2\103\22\uffff\1\103\40\uffff\1\105" u"\3\uffff\1\101\26\uffff\1\102\4\uffff\1\104\3\uffff\1\100"), DFA.unpack(u"\2\106\1\uffff\2\106\22\uffff\1\106\47\uffff\1\111" u"\4\uffff\1\113\16\uffff\1\110\13\uffff\1\107\4\uffff\1\112"), DFA.unpack(u"\2\114\1\uffff\2\114\22\uffff\1\114\42\uffff\1\123" u"\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116\6\uffff\1\120\20\uffff" u"\1\117\3\uffff\1\115"), DFA.unpack(u"\2\127\1\uffff\2\127\22\uffff\1\127\54\uffff\1\125" u"\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124\5\uffff\1\130"), DFA.unpack(u"\2\135\1\uffff\2\135\22\uffff\1\135\55\uffff\1\133" u"\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\2\141\1\uffff\2\141\22\uffff\1\141\44\uffff\1\137" u"\12\uffff\1\143\13\uffff\1\140\10\uffff\1\136\12\uffff\1\142"), DFA.unpack(u"\2\147\1\uffff\2\147\22\uffff\1\147\61\uffff\1\145" u"\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\2\153\1\uffff\2\153\22\uffff\1\153\64\uffff\1\151" u"\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\160\1\uffff\2\160\22\uffff\1\160\47\uffff\1\156" u"\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\2\164\1\uffff\2\164\22\uffff\1\164\71\uffff\1\162" u"\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\2\170\1\uffff\2\170\22\uffff\1\170\47\uffff\1\172" u"\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13\uffff\1\171\4\uffff" u"\1\173\11\uffff\1\165"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"\2\44\1\uffff\2\44\22\uffff\1\44\54\uffff\1\42\12\uffff" u"\1\46\3\uffff\1\43\20\uffff\1\41\12\uffff\1\45"), DFA.unpack(u"\2\103\1\uffff\2\103\22\uffff\1\103\40\uffff\1\105" u"\3\uffff\1\101\26\uffff\1\102\4\uffff\1\104\3\uffff\1\100"), DFA.unpack(u"\2\106\1\uffff\2\106\22\uffff\1\106\47\uffff\1\111" u"\4\uffff\1\113\16\uffff\1\110\13\uffff\1\107\4\uffff\1\112"), DFA.unpack(u"\2\114\1\uffff\2\114\22\uffff\1\114\42\uffff\1\123" u"\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116\6\uffff\1\120\20\uffff" u"\1\117\3\uffff\1\115"), DFA.unpack(u"\2\127\1\uffff\2\127\22\uffff\1\127\54\uffff\1\125" u"\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124\5\uffff\1\130"), DFA.unpack(u"\2\135\1\uffff\2\135\22\uffff\1\135\55\uffff\1\133" u"\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\2\141\1\uffff\2\141\22\uffff\1\141\44\uffff\1\137" u"\12\uffff\1\143\13\uffff\1\140\10\uffff\1\136\12\uffff\1\142"), DFA.unpack(u"\2\147\1\uffff\2\147\22\uffff\1\147\61\uffff\1\145" u"\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\2\153\1\uffff\2\153\22\uffff\1\153\64\uffff\1\151" u"\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\160\1\uffff\2\160\22\uffff\1\160\47\uffff\1\156" u"\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\2\164\1\uffff\2\164\22\uffff\1\164\71\uffff\1\162" u"\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\2\170\1\uffff\2\170\22\uffff\1\170\47\uffff\1\172" u"\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13\uffff\1\171\4\uffff" u"\1\173\11\uffff\1\165"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\177\3\20\1\u0083" u"\1\u0082\1\u0083\1\u0082\25\20\1\u0084\12\20\1\u0080\24\20\1\u0081" u"\12\20\1\176\uff87\20"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\105\3\uffff\1\101\26\uffff\1\102\4\uffff\1\104\3" u"\uffff\1\100"), DFA.unpack(u"\1\u0085\3\uffff\1\u0086\1\u0087\1\u0086\1\u0087"), DFA.unpack(u"\1\u008b\1\u008c\1\u008f\1\uffff\1\u008d\1\u0088\1" u"\u008e\10\uffff\1\u0093\1\uffff\1\u0092\1\u0091\34\uffff\1\u0090" u"\1\uffff\1\u008a\1\u0089"), DFA.unpack(u"\1\105\3\uffff\1\101\26\uffff\1\102\4\uffff\1\104\3" u"\uffff\1\100"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0094\1\uffff\1\u0095\1\u0098\1\u0097\1\uffff\1" u"\u0096"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\172\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13" u"\uffff\1\171\4\uffff\1\173\11\uffff\1\165"), DFA.unpack(u"\1\172\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13" u"\uffff\1\171\4\uffff\1\173\11\uffff\1\165"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\151\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\151\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\123\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116\6" u"\uffff\1\120\20\uffff\1\117\3\uffff\1\115"), DFA.unpack(u"\1\123\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116\6" u"\uffff\1\120\20\uffff\1\117\3\uffff\1\115"), DFA.unpack(u"\1\145\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\1\145\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\1\133\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\1\133\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\2\u0099\1\uffff\2\u0099\22\uffff\1\u0099\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\2\u0099\1\uffff\2\u0099\22\uffff\1\u0099\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u009d\3\20\1\u009e" u"\1\20\1\u009e\uffc9\20"), DFA.unpack(u"\2\103\1\uffff\2\103\22\uffff\1\103\40\uffff\1\u009f" u"\3\uffff\1\u00a1\26\uffff\1\u00a0\4\uffff\1\u009f\3\uffff\1\u00a1"), DFA.unpack(u"\2\u00a2\1\uffff\2\u00a2\22\uffff\1\u00a2\43\uffff" u"\1\u00a5\27\uffff\1\u00a4\7\uffff\1\u00a3"), DFA.unpack(u"\2\u00a2\1\uffff\2\u00a2\22\uffff\1\u00a2\43\uffff" u"\1\u00a5\27\uffff\1\u00a4\7\uffff\1\u00a3"), DFA.unpack(u"\2\106\1\uffff\2\106\22\uffff\1\106\47\uffff\1\u00a6" u"\4\uffff\1\u00a8\16\uffff\1\u00a7\13\uffff\1\u00a6\4\uffff\1\u00a8"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00ac\3\20\1\u00ad" u"\1\20\1\u00ad\21\20\1\u00aa\4\20\1\u00ae\32\20\1\u00a9\4\20\1\u00ab" u"\uff92\20"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00b2\3\20\1\u00b5" u"\1\u00b3\1\u00b5\1\u00b3\34\20\1\u00b0\3\20\1\u00b4\33\20\1\u00af" u"\3\20\1\u00b1\uff87\20"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00b9\3\20\1\u00bc" u"\1\u00ba\1\u00bc\1\u00ba\25\20\1\u00bb\5\20\1\u00b7\31\20\1\u00b8" u"\5\20\1\u00b6\uff8c\20"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00bf\3\20\1\u00c0" u"\1\20\1\u00c0\27\20\1\u00be\37\20\1\u00bd\uff91\20"), DFA.unpack(u""), DFA.unpack(u"\2\u00c1\1\uffff\2\u00c1\22\uffff\1\u00c1\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u00c1\1\uffff\2\u00c1\22\uffff\1\u00c1\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00c7\3\20\1\u00c9" u"\1\u00c8\1\u00c9\1\u00c8\30\20\1\u00c6\37\20\1\u00c5\uff8f\20"), DFA.unpack(u"\2\141\1\uffff\2\141\22\uffff\1\141\44\uffff\1\u00ca" u"\12\uffff\1\u00cc\13\uffff\1\u00cb\10\uffff\1\u00ca\12\uffff\1" u"\u00cc"), DFA.unpack(u"\2\u00cd\1\uffff\2\u00cd\22\uffff\1\u00cd\42\uffff" u"\1\u00d0\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1\u00cf\6\uffff" u"\1\u00ce\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\2\u00cd\1\uffff\2\u00cd\22\uffff\1\u00cd\42\uffff" u"\1\u00d0\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1\u00cf\6\uffff" u"\1\u00ce\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\2\u00d8\1\uffff\2\u00d8\22\uffff\1\u00d8\40\uffff" u"\1\u00d6\32\uffff\1\u00d7\4\uffff\1\u00d5"), DFA.unpack(u"\2\u00d8\1\uffff\2\u00d8\22\uffff\1\u00d8\40\uffff" u"\1\u00d6\32\uffff\1\u00d7\4\uffff\1\u00d5"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00db\4\20\1\u00dc" u"\1\20\1\u00dc\32\20\1\u00da\37\20\1\u00d9\uff8d\20"), DFA.unpack(u""), DFA.unpack(u"\2\u00dd\1\uffff\2\u00dd\22\uffff\1\u00dd\61\uffff" u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\2\u00dd\1\uffff\2\u00dd\22\uffff\1\u00dd\61\uffff" u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00e3\4\20\1\u00e4" u"\1\20\1\u00e4\35\20\1\u00e2\37\20\1\u00e1\uff8a\20"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\2\164\1\uffff\2\164\22\uffff\1\164\71\uffff\1\162" u"\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\2\164\1\uffff\2\164\22\uffff\1\164\71\uffff\1\162" u"\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00e7\3\20\1\u00e8" u"\1\20\1\u00e8\21\20\1\u00e6\37\20\1\u00e5\uff97\20"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00ea\4\20\1\u00ec" u"\1\20\1\u00ec\42\20\1\u00eb\37\20\1\u00e9\uff85\20"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u00f0\3\20\1\u00f1" u"\1\u00f2\1\u00f1\1\u00f2\20\20\1\u00f5\4\20\1\u00ee\11\20\1\u00f3" u"\20\20\1\u00f4\4\20\1\u00ed\11\20\1\u00ef\uff88\20"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u00f6\3\uffff\1\u00f7\1\u00f8\1\u00f7\1\u00f8"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u00f9"), DFA.unpack(u"\1\u00fb\37\uffff\1\u00fa"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u00fc\3\uffff\1\u00fd\1\u00fe\1\u00fd\1\u00fe"), DFA.unpack(u"\1\u0101\1\u0104\1\u0107\1\uffff\1\u0103\1\u0106\1" u"\u0105\10\uffff\1\u0108\1\uffff\1\u010a\1\u0109\34\uffff\1\u00ff" u"\1\uffff\1\u0102\1\u0100"), DFA.unpack(u"\1\u010b\1\uffff\1\u010c\1\u010f\1\u010e\1\uffff\1" u"\u010d"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\111\4\uffff\1\113\16\uffff\1\110\13\uffff\1\107" u"\4\uffff\1\112"), DFA.unpack(u"\1\u0111\12\uffff\1\143\13\uffff\1\140\10\uffff\1\u0110" u"\12\uffff\1\142"), DFA.unpack(u"\1\145\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\1\133\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\1\42\12\uffff\1\46\3\uffff\1\43\20\uffff\1\41\12\uffff" u"\1\45"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\u0113\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116" u"\6\uffff\1\u0112\20\uffff\1\117\3\uffff\1\115"), DFA.unpack(u"\1\u0115\3\uffff\1\u0117\26\uffff\1\102\4\uffff\1\u0114" u"\3\uffff\1\u0116"), DFA.unpack(u"\1\172\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13" u"\uffff\1\171\4\uffff\1\173\11\uffff\1\165"), DFA.unpack(u"\1\151\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u011a\3\20\1\u011b" u"\1\20\1\u011b\26\20\1\u0119\37\20\1\u0118\uff92\20"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u011c\3\uffff\1\u011d\1\uffff\1\u011d"), DFA.unpack(u"\1\u011e\3\uffff\1\u011f"), DFA.unpack(u""), DFA.unpack(u"\1\u0120\3\uffff\1\u0121\1\uffff\1\u0121"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u0122\3\20\1\u0123" u"\1\20\1\u0123\uffc9\20"), DFA.unpack(u"\1\uffff"), DFA.unpack(u""), DFA.unpack(u"\1\u0126\3\uffff\1\u0127\1\uffff\1\u0127\21\uffff\1" u"\u0125\4\uffff\1\u0129\32\uffff\1\u0124\4\uffff\1\u0128"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u012a\3\uffff\1\u012b\1\uffff\1\u012b"), DFA.unpack(u"\1\u012c\13\uffff\1\u012e\37\uffff\1\u012d"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u012f\3\uffff\1\u0131\1\u0130\1\u0131\1\u0130"), DFA.unpack(u"\1\u0132\3\uffff\1\u0133"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0134"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0135\3\uffff\1\u0137\1\u0136\1\u0137\1\u0136"), DFA.unpack(u"\1\u0138"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u013a\37\uffff\1\u0139"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u013b\3\uffff\1\u013c\1\uffff\1\u013c"), DFA.unpack(u"\1\u013e\37\uffff\1\u013d"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u0141\3\20\1\u0142" u"\1\20\1\u0142\20\20\1\u0140\37\20\1\u013f\uff98\20"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u00d0\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1" u"\u00cf\6\uffff\1\u00ce\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\1\u00d0\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1" u"\u00cf\6\uffff\1\u00ce\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\1\u0143\3\uffff\1\u0145\1\u0144\1\u0145\1\u0144"), DFA.unpack(u"\1\u0146"), DFA.unpack(u"\1\u0147"), DFA.unpack(u""), DFA.unpack(u"\1\u014a\3\uffff\1\u014c\1\u014b\1\u014c\1\u014b\30" u"\uffff\1\u0149\37\uffff\1\u0148"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\2\u014d\1\uffff\2\u014d\22\uffff\1\u014d\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u0154\3\20\1\u0157" u"\1\u0155\1\u0157\1\u0155\21\20\1\u0156\6\20\1\u0152\30\20\1\u0153" u"\6\20\1\u0151\uff8f\20"), DFA.unpack(u"\2\u014d\1\uffff\2\u014d\22\uffff\1\u014d\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\2\u015b\1\uffff\2\u015b\22\uffff\1\u015b\67\uffff" u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\2\u015b\1\uffff\2\u015b\22\uffff\1\u015b\67\uffff" u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u015f\1\uffff\2\u015f\22\uffff\1\u015f\43\uffff" u"\1\u015d\27\uffff\1\u015e\7\uffff\1\u015c"), DFA.unpack(u"\2\u015f\1\uffff\2\u015f\22\uffff\1\u015f\43\uffff" u"\1\u015d\27\uffff\1\u015e\7\uffff\1\u015c"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u0160\3\20\1\u0161" u"\1\20\1\u0161\uffc9\20"), DFA.unpack(u""), DFA.unpack(u"\1\u00d6\32\uffff\1\u00d7\4\uffff\1\u00d5"), DFA.unpack(u"\1\u00d6\32\uffff\1\u00d7\4\uffff\1\u00d5"), DFA.unpack(u"\1\u0162\4\uffff\1\u0163\1\uffff\1\u0163"), DFA.unpack(u"\1\u0164"), DFA.unpack(u""), DFA.unpack(u"\2\u0165\1\uffff\2\u0165\22\uffff\1\u0165\55\uffff" u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u016b\4\20\1\u016c" u"\1\20\1\u016c\32\20\1\u016a\37\20\1\u0169\uff8d\20"), DFA.unpack(u"\2\u0165\1\uffff\2\u0165\22\uffff\1\u0165\55\uffff" u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\1\u016d\4\uffff\1\u016e\1\uffff\1\u016e"), DFA.unpack(u"\1\u016f"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\u0170\3\uffff\1\u0171\1\uffff\1\u0171"), DFA.unpack(u"\1\u0172"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0173\4\uffff\1\u0174\1\uffff\1\u0174"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0176\37\uffff\1\u0175"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0177\3\uffff\1\u0178\1\u0179\1\u0178\1\u0179"), DFA.unpack(u"\1\u017b\13\uffff\1\u017c\37\uffff\1\u017a"), DFA.unpack(u"\1\u017d"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u017e\3\uffff\1\u0180\1\u017f\1\u0180\1\u017f"), DFA.unpack(u"\1\u0182\37\uffff\1\u0181"), DFA.unpack(u"\1\u0183"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0184\3\uffff\1\u0185\1\u0186\1\u0185\1\u0186"), DFA.unpack(u"\1\u0188\1\u018b\1\u018f\1\uffff\1\u018a\1\u018e\1" u"\u018c\10\uffff\1\u0190\1\uffff\1\u0191\1\u0192\34\uffff\1\u0187" u"\1\uffff\1\u0189\1\u018d"), DFA.unpack(u"\1\u0193\1\uffff\1\u0194\1\u0197\1\u0196\1\uffff\1" u"\u0195"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\111\4\uffff\1\113\16\uffff\1\110\13\uffff\1\107" u"\4\uffff\1\112"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\145\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\1\u0199\12\uffff\1\143\13\uffff\1\140\10\uffff\1\u0198" u"\12\uffff\1\142"), DFA.unpack(u"\1\133\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\42\12\uffff\1\46\3\uffff\1\43\20\uffff\1\41\12\uffff" u"\1\45"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\u019b\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116" u"\6\uffff\1\u019a\20\uffff\1\117\3\uffff\1\115"), DFA.unpack(u"\1\u019d\3\uffff\1\u019f\26\uffff\1\102\4\uffff\1\u019c" u"\3\uffff\1\u019e"), DFA.unpack(u"\1\172\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13" u"\uffff\1\171\4\uffff\1\173\11\uffff\1\165"), DFA.unpack(u"\1\151\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u01a3\27\uffff\1\u00a4\7\uffff\1\u01a2"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u01a3\27\uffff\1\u00a4\7\uffff\1\u01a2"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u01a5\3\uffff\1\u01a6\1\uffff\1\u01a6"), DFA.unpack(u"\1\u01a8\37\uffff\1\u01a7"), DFA.unpack(u"\1\u01a9\3\uffff\1\u01aa\1\uffff\1\u01aa"), DFA.unpack(u"\1\u01ac\3\uffff\1\u01ab"), DFA.unpack(u"\1\u01ae\27\uffff\1\u00a4\7\uffff\1\u01ad"), DFA.unpack(u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\u01af\3\uffff\1\u0121\1\uffff\1\u0121"), DFA.unpack(u"\1\u01b0\3\uffff\1\u01b1"), DFA.unpack(u"\1\u01b2\3\uffff\1\u01b3\1\uffff\1\u01b3"), DFA.unpack(u"\1\u01b4"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u01b5\3\uffff\1\u0127\1\uffff\1\u0127"), DFA.unpack(u"\1\u01b6\13\uffff\1\u01b7\37\uffff\1\u01b7"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u01b8\3\uffff\1\u01b9\1\uffff\1\u01b9"), DFA.unpack(u"\1\u01bb\13\uffff\1\u01bc\37\uffff\1\u01ba"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u01bd\3\uffff\1\u01bf\1\u01be\1\u01bf\1\u01be"), DFA.unpack(u"\1\u01c0\3\uffff\1\u01c1"), DFA.unpack(u"\1\u01c2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u01c3\3\uffff\1\u01c4\1\u01c5\1\u01c4\1\u01c5"), DFA.unpack(u"\1\u01c6"), DFA.unpack(u"\1\u01c8\37\uffff\1\u01c7"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u01c9\3\uffff\1\u01ca\1\uffff\1\u01ca"), DFA.unpack(u"\1\u01cc\37\uffff\1\u01cb"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u01cd\3\uffff\1\u01ce\1\uffff\1\u01ce"), DFA.unpack(u"\1\u01cf"), DFA.unpack(u"\1\u01d0\3\uffff\1\u01d2\1\u01d1\1\u01d2\1\u01d1"), DFA.unpack(u"\1\u01d3"), DFA.unpack(u"\1\u01d4"), DFA.unpack(u"\1\u01d6\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1" u"\u00cf\6\uffff\1\u01d5\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u01d7\3\uffff\1\u014c\1\u014b\1\u014c\1\u014b"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u01da\3\20\1\u01db" u"\1\20\1\u01db\26\20\1\u01d9\37\20\1\u01d8\uff92\20"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u01dc\3\uffff\1\u01dd\1\u01de\1\u01dd\1\u01de"), DFA.unpack(u"\1\u01df"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u01e1\5\uffff\1\u01e0"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u01e4\4\20\1\u01e5" u"\1\20\1\u01e5\40\20\1\u01e3\37\20\1\u01e2\uff87\20"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u01e6\3\20\1\u01e7" u"\1\20\1\u01e7\uffc9\20"), DFA.unpack(u""), DFA.unpack(u"\1\u01e8\3\uffff\1\u01e9\1\uffff\1\u01e9"), DFA.unpack(u"\1\u01ea"), DFA.unpack(u"\1\u01eb\4\uffff\1\u01ec\1\uffff\1\u01ec"), DFA.unpack(u"\1\u01ed"), DFA.unpack(u"\1\u01ef\32\uffff\1\u00d7\4\uffff\1\u01ee"), DFA.unpack(u""), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\12\20\1\uffff\1\20\2\uffff\42\20\1\u01f1\3\20\1\u01f3" u"\1\20\1\u01f3\27\20\1\u01f2\37\20\1\u01f0\uff91\20"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\1\u01f4\4\uffff\1\u01f5\1\uffff\1\u01f5"), DFA.unpack(u"\1\u01f6"), DFA.unpack(u"\1\u01f7\4\uffff\1\u01f8\1\uffff\1\u01f8"), DFA.unpack(u"\1\u01f9"), DFA.unpack(u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\1\u01fa\3\uffff\1\u01fb\1\uffff\1\u01fb"), DFA.unpack(u"\1\u01fc"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\u01fd\4\uffff\1\u01fe\1\uffff\1\u01fe"), DFA.unpack(u"\1\u0200\37\uffff\1\u01ff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0201\3\uffff\1\u0202\1\u0203\1\u0202\1\u0203"), DFA.unpack(u"\1\u0205\13\uffff\1\u0206\37\uffff\1\u0204"), DFA.unpack(u"\1\u0207"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0208\3\uffff\1\u0209\1\u020a\1\u0209\1\u020a"), DFA.unpack(u"\1\u020b"), DFA.unpack(u"\1\u020d\37\uffff\1\u020c"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u020e\1\u020f\1\u020e\1\u020f"), DFA.unpack(u"\1\u0212\1\u0217\1\u0216\1\uffff\1\u0211\1\u0218\1" u"\u0215\10\uffff\1\u0219\1\uffff\1\u021a\1\u021b\34\uffff\1\u0210" u"\1\uffff\1\u0213\1\u0214"), DFA.unpack(u"\1\u021c\1\uffff\1\u021d\1\u0220\1\u021f\1\uffff\1" u"\u021e"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\111\4\uffff\1\113\16\uffff\1\110\13\uffff\1\107" u"\4\uffff\1\112"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\145\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\1\u0222\12\uffff\1\143\13\uffff\1\140\10\uffff\1\u0221" u"\12\uffff\1\142"), DFA.unpack(u"\1\133\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\42\12\uffff\1\46\3\uffff\1\43\20\uffff\1\41\12\uffff" u"\1\45"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0224\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116" u"\6\uffff\1\u0223\20\uffff\1\117\3\uffff\1\115"), DFA.unpack(u"\1\u0227\3\uffff\1\u0228\26\uffff\1\102\4\uffff\1\u0225" u"\3\uffff\1\u0226"), DFA.unpack(u"\1\172\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13" u"\uffff\1\171\4\uffff\1\173\11\uffff\1\165"), DFA.unpack(u"\1\151\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u022a\27\uffff\1\u00a4\7\uffff\1\u0229"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u022a\27\uffff\1\u00a4\7\uffff\1\u0229"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u00a5\27\uffff\1\u00a4\7\uffff\1\u00a3"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\u022b\3\uffff\1\u022c\1\uffff\1\u022c"), DFA.unpack(u"\1\u022e\37\uffff\1\u022d"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u022f\3\uffff\1\u0230\1\uffff\1\u0230"), DFA.unpack(u"\1\u0232\3\uffff\1\u0231"), DFA.unpack(u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\u0234\27\uffff\1\u00a4\7\uffff\1\u0233"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0235\3\uffff\1\u0121\1\uffff\1\u0121"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0236\3\uffff\1\u0237\1\uffff\1\u0237"), DFA.unpack(u"\1\u0238"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0239\3\uffff\1\u0127\1\uffff\1\u0127"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u023a\3\uffff\1\u023b\1\uffff\1\u023b"), DFA.unpack(u"\1\u023d\13\uffff\1\u023e\37\uffff\1\u023c"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u023f\3\uffff\1\u0241\1\u0240\1\u0241\1\u0240"), DFA.unpack(u"\1\u0242\3\uffff\1\u0243"), DFA.unpack(u"\1\u0244"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0245\3\uffff\1\u0246\1\u0247\1\u0246\1\u0247"), DFA.unpack(u"\1\u0249\37\uffff\1\u0248"), DFA.unpack(u"\1\u024a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u024b\3\uffff\1\u024c\1\uffff\1\u024c"), DFA.unpack(u"\1\u024e\37\uffff\1\u024d"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u024f\3\uffff\1\u0250\1\uffff\1\u0250"), DFA.unpack(u"\1\u0251"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0252\3\uffff\1\u0254\1\u0253\1\u0254\1\u0253"), DFA.unpack(u"\1\u0255"), DFA.unpack(u"\1\u0256"), DFA.unpack(u"\1\u0258\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1" u"\u00cf\6\uffff\1\u0257\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\u025a\3\uffff\1\u014c\1\u014b\1\u014c\1\u014b"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u025b\3\uffff\1\u025c\1\uffff\1\u025c"), DFA.unpack(u"\1\u025e\37\uffff\1\u025d"), DFA.unpack(u"\1\u025f\3\uffff\1\u0260\1\u0261\1\u0260\1\u0261"), DFA.unpack(u"\1\u0262\5\uffff\1\u0263"), DFA.unpack(u"\1\u0264"), DFA.unpack(u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0265\4\uffff\1\u0266\1\uffff\1\u0266"), DFA.unpack(u"\1\u0267"), DFA.unpack(u"\1\u0268\3\uffff\1\u0269\1\uffff\1\u0269"), DFA.unpack(u"\1\u026a"), DFA.unpack(u"\1\u026b\3\uffff\1\u026c\1\uffff\1\u026c"), DFA.unpack(u"\1\u026d"), DFA.unpack(u"\1\u026f\27\uffff\1\u015e\7\uffff\1\u026e"), DFA.unpack(u"\1\u0270\4\uffff\1\u0271\1\uffff\1\u0271"), DFA.unpack(u"\1\u0272"), DFA.unpack(u"\1\u0274\32\uffff\1\u00d7\4\uffff\1\u0273"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u0276\27\uffff\1\u015e\7\uffff\1\u0275"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u0276\27\uffff\1\u015e\7\uffff\1\u0275"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0278\3\uffff\1\u0279\1\uffff\1\u0279"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u027b\37\uffff\1\u027a"), DFA.unpack(u"\1\u027c\4\uffff\1\u027d\1\uffff\1\u027d"), DFA.unpack(u"\1\u027e"), DFA.unpack(u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\1\u027f\4\uffff\1\u0280\1\uffff\1\u0280"), DFA.unpack(u"\1\u0281"), DFA.unpack(u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\1\u0282\3\uffff\1\u0283\1\uffff\1\u0283"), DFA.unpack(u"\1\u0284"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\u0285\4\uffff\1\u0286\1\uffff\1\u0286"), DFA.unpack(u"\1\u0288\37\uffff\1\u0287"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0289\3\uffff\1\u028a\1\u028b\1\u028a\1\u028b"), DFA.unpack(u"\1\u028d\13\uffff\1\u028e\37\uffff\1\u028c"), DFA.unpack(u"\1\u028f"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0290\1\u0291\1\u0290\1\u0291"), DFA.unpack(u"\1\u0293\37\uffff\1\u0292"), DFA.unpack(u"\1\u0294"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0295\1\u029d\1\u029a\1\uffff\1\u0297\1\u029c\1" u"\u029b\10\uffff\1\u029e\1\uffff\1\u029f\1\u02a0\34\uffff\1\u0296" u"\1\uffff\1\u0298\1\u0299"), DFA.unpack(u"\1\u02a1\1\uffff\1\u02a2\1\u02a5\1\u02a4\1\uffff\1" u"\u02a3"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\145\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\1\111\4\uffff\1\113\16\uffff\1\110\13\uffff\1\107" u"\4\uffff\1\112"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\133\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\1\42\12\uffff\1\46\3\uffff\1\43\20\uffff\1\41\12\uffff" u"\1\45"), DFA.unpack(u"\1\u02a7\12\uffff\1\143\13\uffff\1\140\10\uffff\1\u02a6" u"\12\uffff\1\142"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02a9\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116" u"\6\uffff\1\u02a8\20\uffff\1\117\3\uffff\1\115"), DFA.unpack(u"\1\u02ab\3\uffff\1\u02ad\26\uffff\1\102\4\uffff\1\u02aa" u"\3\uffff\1\u02ac"), DFA.unpack(u"\1\172\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13" u"\uffff\1\171\4\uffff\1\173\11\uffff\1\165"), DFA.unpack(u"\1\151\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u02af\27\uffff\1\u00a4\7\uffff\1\u02ae"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u02af\27\uffff\1\u00a4\7\uffff\1\u02ae"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02b0\3\uffff\1\u02b1\1\uffff\1\u02b1"), DFA.unpack(u"\1\u02b3\37\uffff\1\u02b2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02b4\1\uffff\1\u02b4"), DFA.unpack(u"\1\u02b6\3\uffff\1\u02b5"), DFA.unpack(u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\u02b8\27\uffff\1\u00a4\7\uffff\1\u02b7"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02b9\3\uffff\1\u0121\1\uffff\1\u0121"), DFA.unpack(u"\1\u02ba\3\uffff\1\u02bb\1\uffff\1\u02bb"), DFA.unpack(u"\1\u02bc"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02bd\3\uffff\1\u0127\1\uffff\1\u0127"), DFA.unpack(u"\1\u02be\1\uffff\1\u02be"), DFA.unpack(u"\1\u02c0\13\uffff\1\u02c1\37\uffff\1\u02bf"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02c2\1\u02c3\1\u02c2\1\u02c3"), DFA.unpack(u"\1\u02c4\3\uffff\1\u02c5"), DFA.unpack(u"\1\u02c6"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02c7\1\u02c8\1\u02c7\1\u02c8"), DFA.unpack(u"\1\u02ca\37\uffff\1\u02c9"), DFA.unpack(u"\1\u02cb"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02cc\1\uffff\1\u02cc"), DFA.unpack(u"\1\u02ce\37\uffff\1\u02cd"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02cf\3\uffff\1\u02d0\1\uffff\1\u02d0"), DFA.unpack(u"\1\u02d1"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02d2\1\u02d3\1\u02d2\1\u02d3"), DFA.unpack(u"\1\u02d4"), DFA.unpack(u"\1\u02d5"), DFA.unpack(u"\1\u02d7\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1" u"\u00cf\6\uffff\1\u02d6\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\u02d8\3\uffff\1\u014c\1\u014b\1\u014c\1\u014b"), DFA.unpack(u"\1\u02d9\3\uffff\1\u02da\1\uffff\1\u02da"), DFA.unpack(u"\1\u02dc\37\uffff\1\u02db"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02dd\3\uffff\1\u02de\1\u02df\1\u02de\1\u02df"), DFA.unpack(u"\1\u02e0\5\uffff\1\u02e1"), DFA.unpack(u"\1\u02e2"), DFA.unpack(u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\1\u02e3\4\uffff\1\u02e4\1\uffff\1\u02e4"), DFA.unpack(u"\1\u02e5"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02e6\3\uffff\1\u02e7\1\uffff\1\u02e7"), DFA.unpack(u"\1\u02e8"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02e9\3\uffff\1\u02ea\1\uffff\1\u02ea"), DFA.unpack(u"\1\u02eb"), DFA.unpack(u"\1\u0276\27\uffff\1\u015e\7\uffff\1\u0275"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02ec\1\uffff\1\u02ec"), DFA.unpack(u"\1\u02ed"), DFA.unpack(u"\1\u02ef\32\uffff\1\u00d7\4\uffff\1\u02ee"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u02f1\27\uffff\1\u015e\7\uffff\1\u02f0"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u02f1\27\uffff\1\u015e\7\uffff\1\u02f0"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u015d\27\uffff\1\u015e\7\uffff\1\u015c"), DFA.unpack(u"\1\u02f2\3\uffff\1\u02f3\1\uffff\1\u02f3"), DFA.unpack(u"\1\u02f5\37\uffff\1\u02f4"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u02f6\4\uffff\1\u02f7\1\uffff\1\u02f7"), DFA.unpack(u"\1\u02f8"), DFA.unpack(u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\1\u02f9\1\uffff\1\u02f9"), DFA.unpack(u"\1\u02fa"), DFA.unpack(u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\1\u02fb\1\uffff\1\u02fb"), DFA.unpack(u"\1\u02fc"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\u02fd\1\uffff\1\u02fd"), DFA.unpack(u"\1\u02ff\37\uffff\1\u02fe"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0300\1\u0301\1\u0300\1\u0301"), DFA.unpack(u"\1\u0303\13\uffff\1\u0304\37\uffff\1\u0302"), DFA.unpack(u"\1\u0305"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0307\37\uffff\1\u0306"), DFA.unpack(u"\1\u0308"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\111\4\uffff\1\113\16\uffff\1\110\13\uffff\1\107" u"\4\uffff\1\112"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\145\11\uffff\1\146\25\uffff\1\144"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\42\12\uffff\1\46\3\uffff\1\43\20\uffff\1\41\12\uffff" u"\1\45"), DFA.unpack(u"\1\133\15\uffff\1\134\21\uffff\1\132"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\137\12\uffff\1\143\13\uffff\1\140\10\uffff\1\136" u"\12\uffff\1\142"), DFA.unpack(u"\1\156\23\uffff\1\157\13\uffff\1\155"), DFA.unpack(u"\1\125\5\uffff\1\131\10\uffff\1\126\20\uffff\1\124" u"\5\uffff\1\130"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\123\20\uffff\1\122\3\uffff\1\121\3\uffff\1\116\6" u"\uffff\1\120\20\uffff\1\117\3\uffff\1\115"), DFA.unpack(u"\1\105\3\uffff\1\101\26\uffff\1\102\4\uffff\1\104\3" u"\uffff\1\100"), DFA.unpack(u"\1\172\4\uffff\1\174\11\uffff\1\166\4\uffff\1\167\13" u"\uffff\1\171\4\uffff\1\173\11\uffff\1\165"), DFA.unpack(u"\1\151\6\uffff\1\152\30\uffff\1\150"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u01a0\1\uffff\2\u01a0\22\uffff\1\u01a0\46\uffff" u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u00a5\27\uffff\1\u00a4\7\uffff\1\u00a3"), DFA.unpack(u"\2\u01a1\1\uffff\2\u01a1\22\uffff\1\u01a1\43\uffff" u"\1\u00a5\27\uffff\1\u00a4\7\uffff\1\u00a3"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\2\u01a4\1\uffff\2\u01a4\22\uffff\1\u01a4\54\uffff" u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0309\1\uffff\1\u0309"), DFA.unpack(u"\1\u030b\37\uffff\1\u030a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u030c\3\uffff\1\u030d"), DFA.unpack(u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\u030f\27\uffff\1\u00a4\7\uffff\1\u030e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0121\1\uffff\1\u0121"), DFA.unpack(u"\1\u0310\1\uffff\1\u0310"), DFA.unpack(u"\1\u0311"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0127\1\uffff\1\u0127"), DFA.unpack(u"\1\u0312\13\uffff\1\u0314\37\uffff\1\u0313"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0315"), DFA.unpack(u"\1\u0316\3\uffff\1\u0317"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0319\37\uffff\1\u0318"), DFA.unpack(u"\1\u031a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u031c\37\uffff\1\u031b"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u031d\1\uffff\1\u031d"), DFA.unpack(u"\1\u031e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u031f"), DFA.unpack(u"\1\u0320"), DFA.unpack(u"\1\u0322\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1" u"\u00cf\6\uffff\1\u0321\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\u014c\1\u014b\1\u014c\1\u014b"), DFA.unpack(u"\1\u0323\3\uffff\1\u0324\1\uffff\1\u0324"), DFA.unpack(u"\1\u0326\37\uffff\1\u0325"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0327\1\u0328\1\u0327\1\u0328"), DFA.unpack(u"\1\u0329\5\uffff\1\u032a"), DFA.unpack(u"\1\u032b"), DFA.unpack(u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\1\u032c\4\uffff\1\u032d\1\uffff\1\u032d"), DFA.unpack(u"\1\u032e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u032f\3\uffff\1\u0330\1\uffff\1\u0330"), DFA.unpack(u"\1\u0331"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0332\1\uffff\1\u0332"), DFA.unpack(u"\1\u0333"), DFA.unpack(u"\1\u02f1\27\uffff\1\u015e\7\uffff\1\u02f0"), DFA.unpack(u"\1\u0334"), DFA.unpack(u"\1\u0336\32\uffff\1\u00d7\4\uffff\1\u0335"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u0338\27\uffff\1\u015e\7\uffff\1\u0337"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u0338\27\uffff\1\u015e\7\uffff\1\u0337"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0339\3\uffff\1\u033a\1\uffff\1\u033a"), DFA.unpack(u"\1\u033c\37\uffff\1\u033b"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u033d\1\uffff\1\u033d"), DFA.unpack(u"\1\u033e"), DFA.unpack(u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\1\u033f"), DFA.unpack(u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\1\u0340"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\u0342\37\uffff\1\u0341"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0343\13\uffff\1\u0345\37\uffff\1\u0344"), DFA.unpack(u"\1\u0346"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0348\37\uffff\1\u0347"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u00a5\27\uffff\1\u00a4\7\uffff\1\u00a3"), DFA.unpack(u"\1\u009c\16\uffff\1\u009b\20\uffff\1\u009a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0349"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u034a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u00c4\24\uffff\1\u00c3\12\uffff\1\u00c2"), DFA.unpack(u"\1\u00d0\5\uffff\1\u00d4\6\uffff\1\u00d2\13\uffff\1" u"\u00cf\6\uffff\1\u00ce\5\uffff\1\u00d3\6\uffff\1\u00d1"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\2\u0259\1\uffff\2\u0259\22\uffff\1\u0259\54\uffff" u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\u034b\1\uffff\1\u034b"), DFA.unpack(u"\1\u034d\37\uffff\1\u034c"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u034e\5\uffff\1\u034f"), DFA.unpack(u"\1\u0350"), DFA.unpack(u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\1\u0351\1\uffff\1\u0351"), DFA.unpack(u"\1\u0352"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0353\1\uffff\1\u0353"), DFA.unpack(u"\1\u0354"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0355"), DFA.unpack(u"\1\u0338\27\uffff\1\u015e\7\uffff\1\u0337"), DFA.unpack(u"\1\u00d6\32\uffff\1\u00d7\4\uffff\1\u00d5"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u015d\27\uffff\1\u015e\7\uffff\1\u015c"), DFA.unpack(u"\2\u0277\1\uffff\2\u0277\22\uffff\1\u0277\43\uffff" u"\1\u015d\27\uffff\1\u015e\7\uffff\1\u015c"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0356\1\uffff\1\u0356"), DFA.unpack(u"\1\u0358\37\uffff\1\u0357"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0359"), DFA.unpack(u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\1\u00e0\11\uffff\1\u00df\25\uffff\1\u00de"), DFA.unpack(u"\1\162\1\uffff\1\163\35\uffff\1\161"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u035b\37\uffff\1\u035a"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0150\16\uffff\1\u014f\20\uffff\1\u014e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0159\3\uffff\1\u015a\33\uffff\1\u0158"), DFA.unpack(u"\1\u035c"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u035d"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u015d\27\uffff\1\u015e\7\uffff\1\u015c"), DFA.unpack(u"\1\u035f\37\uffff\1\u035e"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\u0168\15\uffff\1\u0167\21\uffff\1\u0166"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff"), DFA.unpack(u"\1\uffff") ] # class definition for DFA #224 class DFA224(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA224_806 = input.LA(1) index224_806 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_806) if s >= 0: return s elif s == 1: LA224_805 = input.LA(1) index224_805 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_805) if s >= 0: return s elif s == 2: LA224_518 = input.LA(1) index224_518 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_518) if s >= 0: return s elif s == 3: LA224_516 = input.LA(1) index224_516 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_516) if s >= 0: return s elif s == 4: LA224_306 = input.LA(1) index224_306 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_306) if s >= 0: return s elif s == 5: LA224_119 = input.LA(1) s = -1 if (LA224_119 == 109): s = 237 elif (LA224_119 == 77): s = 238 elif (LA224_119 == 119): s = 239 elif (LA224_119 == 48): s = 240 elif (LA224_119 == 52 or LA224_119 == 54): s = 241 elif (LA224_119 == 53 or LA224_119 == 55): s = 242 elif (LA224_119 == 87): s = 243 elif (LA224_119 == 104): s = 244 elif ((0 <= LA224_119 <= 9) or LA224_119 == 11 or (14 <= LA224_119 <= 47) or (49 <= LA224_119 <= 51) or (56 <= LA224_119 <= 71) or (73 <= LA224_119 <= 76) or (78 <= LA224_119 <= 86) or (88 <= LA224_119 <= 103) or (105 <= LA224_119 <= 108) or (110 <= LA224_119 <= 118) or (120 <= LA224_119 <= 65535)): s = 16 elif (LA224_119 == 72): s = 245 if s >= 0: return s elif s == 6: LA224_312 = input.LA(1) index224_312 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_312) if s >= 0: return s elif s == 7: LA224_207 = input.LA(1) s = -1 if (LA224_207 == 112): s = 337 elif (LA224_207 == 80): s = 338 elif (LA224_207 == 105): s = 339 elif (LA224_207 == 48): s = 340 elif (LA224_207 == 53 or LA224_207 == 55): s = 341 elif (LA224_207 == 73): s = 342 elif ((0 <= LA224_207 <= 9) or LA224_207 == 11 or (14 <= LA224_207 <= 47) or (49 <= LA224_207 <= 51) or (56 <= LA224_207 <= 72) or (74 <= LA224_207 <= 79) or (81 <= LA224_207 <= 104) or (106 <= LA224_207 <= 111) or (113 <= LA224_207 <= 65535)): s = 16 elif (LA224_207 == 52 or LA224_207 == 54): s = 343 if s >= 0: return s elif s == 8: LA224_79 = input.LA(1) index224_79 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_79) if s >= 0: return s elif s == 9: LA224_82 = input.LA(1) index224_82 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_82) if s >= 0: return s elif s == 10: LA224_776 = input.LA(1) index224_776 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_776) if s >= 0: return s elif s == 11: LA224_75 = input.LA(1) index224_75 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 168 elif (True): s = 16 input.seek(index224_75) if s >= 0: return s elif s == 12: LA224_74 = input.LA(1) index224_74 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 168 elif (True): s = 16 input.seek(index224_74) if s >= 0: return s elif s == 13: LA224_106 = input.LA(1) s = -1 if (LA224_106 == 117): s = 225 elif (LA224_106 == 85): s = 226 elif ((0 <= LA224_106 <= 9) or LA224_106 == 11 or (14 <= LA224_106 <= 47) or (49 <= LA224_106 <= 52) or LA224_106 == 54 or (56 <= LA224_106 <= 84) or (86 <= LA224_106 <= 116) or (118 <= LA224_106 <= 65535)): s = 16 elif (LA224_106 == 48): s = 227 elif (LA224_106 == 53 or LA224_106 == 55): s = 228 if s >= 0: return s elif s == 14: LA224_397 = input.LA(1) index224_397 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_397) if s >= 0: return s elif s == 15: LA224_6 = input.LA(1) index224_6 = input.index() input.rewind() s = -1 if (LA224_6 == 109): s = 84 elif (LA224_6 == 77): s = 85 elif (LA224_6 == 92): s = 86 elif ((9 <= LA224_6 <= 10) or (12 <= LA224_6 <= 13) or LA224_6 == 32) and (self.synpred6_lesscss()): s = 87 elif (LA224_6 == 115): s = 88 elif (LA224_6 == 83): s = 89 else: s = 16 input.seek(index224_6) if s >= 0: return s elif s == 16: LA224_360 = input.LA(1) index224_360 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_360) if s >= 0: return s elif s == 17: LA224_696 = input.LA(1) index224_696 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_696) if s >= 0: return s elif s == 18: LA224_358 = input.LA(1) index224_358 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_358) if s >= 0: return s elif s == 19: LA224_402 = input.LA(1) index224_402 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_402) if s >= 0: return s elif s == 20: LA224_21 = input.LA(1) index224_21 = input.index() input.rewind() s = -1 if (LA224_21 == 109): s = 84 elif (LA224_21 == 77): s = 85 elif (LA224_21 == 92): s = 86 elif ((9 <= LA224_21 <= 10) or (12 <= LA224_21 <= 13) or LA224_21 == 32) and (self.synpred6_lesscss()): s = 87 elif (LA224_21 == 115): s = 88 elif (LA224_21 == 83): s = 89 else: s = 16 input.seek(index224_21) if s >= 0: return s elif s == 21: LA224_695 = input.LA(1) index224_695 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_695) if s >= 0: return s elif s == 22: LA224_300 = input.LA(1) index224_300 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 438 elif (True): s = 16 input.seek(index224_300) if s >= 0: return s elif s == 23: LA224_785 = input.LA(1) index224_785 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_785) if s >= 0: return s elif s == 24: LA224_752 = input.LA(1) index224_752 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_752) if s >= 0: return s elif s == 25: LA224_753 = input.LA(1) index224_753 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_753) if s >= 0: return s elif s == 26: LA224_568 = input.LA(1) index224_568 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_568) if s >= 0: return s elif s == 27: LA224_114 = input.LA(1) index224_114 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_114) if s >= 0: return s elif s == 28: LA224_113 = input.LA(1) index224_113 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_113) if s >= 0: return s elif s == 29: LA224_629 = input.LA(1) index224_629 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_629) if s >= 0: return s elif s == 30: LA224_630 = input.LA(1) index224_630 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_630) if s >= 0: return s elif s == 31: LA224_744 = input.LA(1) index224_744 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_744) if s >= 0: return s elif s == 32: LA224_334 = input.LA(1) index224_334 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_334) if s >= 0: return s elif s == 33: LA224_852 = input.LA(1) index224_852 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_852) if s >= 0: return s elif s == 34: LA224_463 = input.LA(1) index224_463 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 332 elif (True): s = 16 input.seek(index224_463) if s >= 0: return s elif s == 35: LA224_786 = input.LA(1) index224_786 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 438 elif (True): s = 16 input.seek(index224_786) if s >= 0: return s elif s == 36: LA224_336 = input.LA(1) index224_336 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_336) if s >= 0: return s elif s == 37: LA224_842 = input.LA(1) index224_842 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 332 elif (True): s = 16 input.seek(index224_842) if s >= 0: return s elif s == 38: LA224_471 = input.LA(1) index224_471 = input.index() input.rewind() s = -1 if (LA224_471 == 48): s = 602 elif (LA224_471 == 53 or LA224_471 == 55) and (self.synpred14_lesscss()): s = 331 elif (LA224_471 == 52 or LA224_471 == 54) and (self.synpred8_lesscss()): s = 332 input.seek(index224_471) if s >= 0: return s elif s == 39: LA224_791 = input.LA(1) index224_791 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_791) if s >= 0: return s elif s == 40: LA224_274 = input.LA(1) index224_274 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_274) if s >= 0: return s elif s == 41: LA224_275 = input.LA(1) index224_275 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_275) if s >= 0: return s elif s == 42: LA224_448 = input.LA(1) index224_448 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_448) if s >= 0: return s elif s == 43: LA224_855 = input.LA(1) index224_855 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_855) if s >= 0: return s elif s == 44: LA224_856 = input.LA(1) index224_856 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_856) if s >= 0: return s elif s == 45: LA224_378 = input.LA(1) index224_378 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_378) if s >= 0: return s elif s == 46: LA224_380 = input.LA(1) index224_380 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_380) if s >= 0: return s elif s == 47: LA224_844 = input.LA(1) index224_844 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_844) if s >= 0: return s elif s == 48: LA224_845 = input.LA(1) index224_845 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_845) if s >= 0: return s elif s == 49: LA224_710 = input.LA(1) index224_710 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_710) if s >= 0: return s elif s == 50: LA224_454 = input.LA(1) index224_454 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_454) if s >= 0: return s elif s == 51: LA224_105 = input.LA(1) index224_105 = input.index() input.rewind() s = -1 if ((9 <= LA224_105 <= 10) or (12 <= LA224_105 <= 13) or LA224_105 == 32) and (self.synpred11_lesscss()): s = 221 elif (LA224_105 == 114): s = 222 elif (LA224_105 == 92): s = 223 elif (LA224_105 == 82): s = 224 else: s = 16 input.seek(index224_105) if s >= 0: return s elif s == 52: LA224_1 = input.LA(1) index224_1 = input.index() input.rewind() s = -1 if (LA224_1 == 109): s = 33 elif (LA224_1 == 77): s = 34 elif (LA224_1 == 92): s = 35 elif ((9 <= LA224_1 <= 10) or (12 <= LA224_1 <= 13) or LA224_1 == 32) and (self.synpred1_lesscss()): s = 36 elif (LA224_1 == 120): s = 37 elif (LA224_1 == 88): s = 38 else: s = 16 input.seek(index224_1) if s >= 0: return s elif s == 53: LA224_532 = input.LA(1) index224_532 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_532) if s >= 0: return s elif s == 54: LA224_17 = input.LA(1) index224_17 = input.index() input.rewind() s = -1 if (LA224_17 == 109): s = 33 elif (LA224_17 == 77): s = 34 elif (LA224_17 == 92): s = 35 elif ((9 <= LA224_17 <= 10) or (12 <= LA224_17 <= 13) or LA224_17 == 32) and (self.synpred1_lesscss()): s = 36 elif (LA224_17 == 120): s = 37 elif (LA224_17 == 88): s = 38 else: s = 16 input.seek(index224_17) if s >= 0: return s elif s == 55: LA224_104 = input.LA(1) index224_104 = input.index() input.rewind() s = -1 if ((9 <= LA224_104 <= 10) or (12 <= LA224_104 <= 13) or LA224_104 == 32) and (self.synpred11_lesscss()): s = 221 elif (LA224_104 == 114): s = 222 elif (LA224_104 == 92): s = 223 elif (LA224_104 == 82): s = 224 else: s = 16 input.seek(index224_104) if s >= 0: return s elif s == 56: LA224_539 = input.LA(1) index224_539 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_539) if s >= 0: return s elif s == 57: LA224_563 = input.LA(1) index224_563 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_563) if s >= 0: return s elif s == 58: LA224_436 = input.LA(1) index224_436 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_436) if s >= 0: return s elif s == 59: LA224_20 = input.LA(1) index224_20 = input.index() input.rewind() s = -1 if ((9 <= LA224_20 <= 10) or (12 <= LA224_20 <= 13) or LA224_20 == 32) and (self.synpred4_lesscss()): s = 76 elif (LA224_20 == 120): s = 77 elif (LA224_20 == 92): s = 78 elif (LA224_20 == 116): s = 79 elif (LA224_20 == 99): s = 80 elif (LA224_20 == 88): s = 81 elif (LA224_20 == 84): s = 82 elif (LA224_20 == 67): s = 83 else: s = 16 input.seek(index224_20) if s >= 0: return s elif s == 60: LA224_5 = input.LA(1) index224_5 = input.index() input.rewind() s = -1 if ((9 <= LA224_5 <= 10) or (12 <= LA224_5 <= 13) or LA224_5 == 32) and (self.synpred4_lesscss()): s = 76 elif (LA224_5 == 120): s = 77 elif (LA224_5 == 92): s = 78 elif (LA224_5 == 116): s = 79 elif (LA224_5 == 99): s = 80 elif (LA224_5 == 88): s = 81 elif (LA224_5 == 84): s = 82 elif (LA224_5 == 67): s = 83 else: s = 16 input.seek(index224_5) if s >= 0: return s elif s == 61: LA224_96 = input.LA(1) s = -1 if (LA224_96 == 112): s = 197 elif (LA224_96 == 80): s = 198 elif ((0 <= LA224_96 <= 9) or LA224_96 == 11 or (14 <= LA224_96 <= 47) or (49 <= LA224_96 <= 51) or (56 <= LA224_96 <= 79) or (81 <= LA224_96 <= 111) or (113 <= LA224_96 <= 65535)): s = 16 elif (LA224_96 == 48): s = 199 elif (LA224_96 == 53 or LA224_96 == 55): s = 200 elif (LA224_96 == 52 or LA224_96 == 54): s = 201 if s >= 0: return s elif s == 62: LA224_564 = input.LA(1) index224_564 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_564) if s >= 0: return s elif s == 63: LA224_700 = input.LA(1) index224_700 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_700) if s >= 0: return s elif s == 64: LA224_618 = input.LA(1) index224_618 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_618) if s >= 0: return s elif s == 65: LA224_110 = input.LA(1) index224_110 = input.index() input.rewind() s = -1 if (LA224_110 == 122): s = 113 elif (LA224_110 == 90): s = 114 elif (LA224_110 == 92): s = 115 elif ((9 <= LA224_110 <= 10) or (12 <= LA224_110 <= 13) or LA224_110 == 32) and (self.synpred13_lesscss()): s = 116 else: s = 16 input.seek(index224_110) if s >= 0: return s elif s == 66: LA224_109 = input.LA(1) index224_109 = input.index() input.rewind() s = -1 if (LA224_109 == 122): s = 113 elif (LA224_109 == 90): s = 114 elif (LA224_109 == 92): s = 115 elif ((9 <= LA224_109 <= 10) or (12 <= LA224_109 <= 13) or LA224_109 == 32) and (self.synpred13_lesscss()): s = 116 else: s = 16 input.seek(index224_109) if s >= 0: return s elif s == 67: LA224_817 = input.LA(1) index224_817 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_817) if s >= 0: return s elif s == 68: LA224_182 = input.LA(1) index224_182 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_182) if s >= 0: return s elif s == 69: LA224_183 = input.LA(1) index224_183 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_183) if s >= 0: return s elif s == 70: LA224_622 = input.LA(1) index224_622 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_622) if s >= 0: return s elif s == 71: LA224_623 = input.LA(1) index224_623 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_623) if s >= 0: return s elif s == 72: LA224_472 = input.LA(1) index224_472 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_472) if s >= 0: return s elif s == 73: LA224_473 = input.LA(1) index224_473 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_473) if s >= 0: return s elif s == 74: LA224_91 = input.LA(1) index224_91 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_91) if s >= 0: return s elif s == 75: LA224_90 = input.LA(1) index224_90 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_90) if s >= 0: return s elif s == 76: LA224_496 = input.LA(1) index224_496 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_496) if s >= 0: return s elif s == 77: LA224_718 = input.LA(1) index224_718 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_718) if s >= 0: return s elif s == 78: LA224_498 = input.LA(1) index224_498 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_498) if s >= 0: return s elif s == 79: LA224_717 = input.LA(1) index224_717 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_717) if s >= 0: return s elif s == 80: LA224_156 = input.LA(1) index224_156 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 161 elif (True): s = 16 input.seek(index224_156) if s >= 0: return s elif s == 81: LA224_154 = input.LA(1) index224_154 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 161 elif (True): s = 16 input.seek(index224_154) if s >= 0: return s elif s == 82: LA224_176 = input.LA(1) index224_176 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_176) if s >= 0: return s elif s == 83: LA224_175 = input.LA(1) index224_175 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_175) if s >= 0: return s elif s == 84: LA224_206 = input.LA(1) index224_206 = input.index() input.rewind() s = -1 if ((9 <= LA224_206 <= 10) or (12 <= LA224_206 <= 13) or LA224_206 == 32) and (self.synpred14_lesscss()): s = 333 elif (LA224_206 == 109): s = 334 elif (LA224_206 == 92): s = 335 elif (LA224_206 == 77): s = 336 else: s = 16 input.seek(index224_206) if s >= 0: return s elif s == 85: LA224_214 = input.LA(1) index224_214 = input.index() input.rewind() s = -1 if (LA224_214 == 100): s = 348 elif (LA224_214 == 68): s = 349 elif (LA224_214 == 92): s = 350 elif ((9 <= LA224_214 <= 10) or (12 <= LA224_214 <= 13) or LA224_214 == 32) and (self.synpred10_lesscss()): s = 351 else: s = 16 input.seek(index224_214) if s >= 0: return s elif s == 86: LA224_213 = input.LA(1) index224_213 = input.index() input.rewind() s = -1 if (LA224_213 == 100): s = 348 elif (LA224_213 == 68): s = 349 elif (LA224_213 == 92): s = 350 elif ((9 <= LA224_213 <= 10) or (12 <= LA224_213 <= 13) or LA224_213 == 32) and (self.synpred10_lesscss()): s = 351 else: s = 16 input.seek(index224_213) if s >= 0: return s elif s == 87: LA224_249 = input.LA(1) index224_249 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_249) if s >= 0: return s elif s == 88: LA224_208 = input.LA(1) index224_208 = input.index() input.rewind() s = -1 if ((9 <= LA224_208 <= 10) or (12 <= LA224_208 <= 13) or LA224_208 == 32) and (self.synpred14_lesscss()): s = 333 elif (LA224_208 == 109): s = 334 elif (LA224_208 == 92): s = 335 elif (LA224_208 == 77): s = 336 else: s = 16 input.seek(index224_208) if s >= 0: return s elif s == 89: LA224_69 = input.LA(1) index224_69 = input.index() input.rewind() s = -1 if ((9 <= LA224_69 <= 10) or (12 <= LA224_69 <= 13) or LA224_69 == 32) and (self.synpred9_lesscss()): s = 162 elif (LA224_69 == 100): s = 163 elif (LA224_69 == 92): s = 164 elif (LA224_69 == 68): s = 165 else: s = 16 input.seek(index224_69) if s >= 0: return s elif s == 90: LA224_68 = input.LA(1) index224_68 = input.index() input.rewind() s = -1 if ((9 <= LA224_68 <= 10) or (12 <= LA224_68 <= 13) or LA224_68 == 32) and (self.synpred9_lesscss()): s = 162 elif (LA224_68 == 100): s = 163 elif (LA224_68 == 92): s = 164 elif (LA224_68 == 68): s = 165 else: s = 16 input.seek(index224_68) if s >= 0: return s elif s == 91: LA224_586 = input.LA(1) index224_586 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_586) if s >= 0: return s elif s == 92: LA224_190 = input.LA(1) index224_190 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_190) if s >= 0: return s elif s == 93: LA224_189 = input.LA(1) index224_189 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_189) if s >= 0: return s elif s == 94: LA224_838 = input.LA(1) index224_838 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_838) if s >= 0: return s elif s == 95: LA224_67 = input.LA(1) index224_67 = input.index() input.rewind() s = -1 if (LA224_67 == 65 or LA224_67 == 97) and (self.synpred9_lesscss()): s = 159 elif (LA224_67 == 92): s = 160 elif ((9 <= LA224_67 <= 10) or (12 <= LA224_67 <= 13) or LA224_67 == 32): s = 67 elif (LA224_67 == 69 or LA224_67 == 101) and (self.synpred2_lesscss()): s = 161 input.seek(index224_67) if s >= 0: return s elif s == 96: LA224_215 = input.LA(1) s = -1 if ((0 <= LA224_215 <= 9) or LA224_215 == 11 or (14 <= LA224_215 <= 47) or (49 <= LA224_215 <= 51) or LA224_215 == 53 or (55 <= LA224_215 <= 65535)): s = 16 elif (LA224_215 == 48): s = 352 elif (LA224_215 == 52 or LA224_215 == 54): s = 353 if s >= 0: return s elif s == 97: LA224_772 = input.LA(1) index224_772 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_772) if s >= 0: return s elif s == 98: LA224_770 = input.LA(1) index224_770 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_770) if s >= 0: return s elif s == 99: LA224_578 = input.LA(1) index224_578 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_578) if s >= 0: return s elif s == 100: LA224_28 = input.LA(1) index224_28 = input.index() input.rewind() s = -1 if (LA224_28 == 122): s = 113 elif (LA224_28 == 90): s = 114 elif (LA224_28 == 92): s = 115 elif ((9 <= LA224_28 <= 10) or (12 <= LA224_28 <= 13) or LA224_28 == 32) and (self.synpred13_lesscss()): s = 116 else: s = 16 input.seek(index224_28) if s >= 0: return s elif s == 101: LA224_573 = input.LA(1) index224_573 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 438 elif (True): s = 16 input.seek(index224_573) if s >= 0: return s elif s == 102: LA224_250 = input.LA(1) index224_250 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_250) if s >= 0: return s elif s == 103: LA224_251 = input.LA(1) index224_251 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_251) if s >= 0: return s elif s == 104: LA224_480 = input.LA(1) index224_480 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_480) if s >= 0: return s elif s == 105: LA224_307 = input.LA(1) index224_307 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_307) if s >= 0: return s elif s == 106: LA224_796 = input.LA(1) index224_796 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_796) if s >= 0: return s elif s == 107: LA224_122 = input.LA(1) index224_122 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_122) if s >= 0: return s elif s == 108: LA224_860 = input.LA(1) index224_860 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_860) if s >= 0: return s elif s == 109: LA224_795 = input.LA(1) index224_795 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_795) if s >= 0: return s elif s == 110: LA224_121 = input.LA(1) index224_121 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_121) if s >= 0: return s elif s == 111: LA224_137 = input.LA(1) index224_137 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_137) if s >= 0: return s elif s == 112: LA224_184 = input.LA(1) index224_184 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_184) if s >= 0: return s elif s == 113: LA224_187 = input.LA(1) index224_187 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_187) if s >= 0: return s elif s == 114: LA224_145 = input.LA(1) index224_145 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_145) if s >= 0: return s elif s == 115: LA224_379 = input.LA(1) index224_379 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_379) if s >= 0: return s elif s == 116: LA224_13 = input.LA(1) index224_13 = input.index() input.rewind() s = -1 if (LA224_13 == 122): s = 113 elif (LA224_13 == 90): s = 114 elif (LA224_13 == 92): s = 115 elif ((9 <= LA224_13 <= 10) or (12 <= LA224_13 <= 13) or LA224_13 == 32) and (self.synpred13_lesscss()): s = 116 else: s = 16 input.seek(index224_13) if s >= 0: return s elif s == 117: LA224_12 = input.LA(1) index224_12 = input.index() input.rewind() s = -1 if (LA224_12 == 104): s = 109 elif (LA224_12 == 72): s = 110 elif (LA224_12 == 92): s = 111 elif ((9 <= LA224_12 <= 10) or (12 <= LA224_12 <= 13) or LA224_12 == 32) and (self.synpred13_lesscss()): s = 112 else: s = 16 input.seek(index224_12) if s >= 0: return s elif s == 118: LA224_27 = input.LA(1) index224_27 = input.index() input.rewind() s = -1 if (LA224_27 == 104): s = 109 elif (LA224_27 == 72): s = 110 elif (LA224_27 == 92): s = 111 elif ((9 <= LA224_27 <= 10) or (12 <= LA224_27 <= 13) or LA224_27 == 32) and (self.synpred13_lesscss()): s = 112 else: s = 16 input.seek(index224_27) if s >= 0: return s elif s == 119: LA224_165 = input.LA(1) index224_165 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 162 elif (True): s = 16 input.seek(index224_165) if s >= 0: return s elif s == 120: LA224_163 = input.LA(1) index224_163 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 162 elif (True): s = 16 input.seek(index224_163) if s >= 0: return s elif s == 121: LA224_721 = input.LA(1) index224_721 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 332 elif (True): s = 16 input.seek(index224_721) if s >= 0: return s elif s == 122: LA224_686 = input.LA(1) index224_686 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_686) if s >= 0: return s elif s == 123: LA224_687 = input.LA(1) index224_687 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_687) if s >= 0: return s elif s == 124: LA224_789 = input.LA(1) index224_789 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_789) if s >= 0: return s elif s == 125: LA224_863 = input.LA(1) index224_863 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_863) if s >= 0: return s elif s == 126: LA224_348 = input.LA(1) index224_348 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_348) if s >= 0: return s elif s == 127: LA224_349 = input.LA(1) index224_349 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_349) if s >= 0: return s elif s == 128: LA224_22 = input.LA(1) index224_22 = input.index() input.rewind() s = -1 if ((9 <= LA224_22 <= 10) or (12 <= LA224_22 <= 13) or LA224_22 == 32) and (self.synpred7_lesscss()): s = 93 elif (LA224_22 == 110): s = 90 elif (LA224_22 == 92): s = 92 elif (LA224_22 == 78): s = 91 else: s = 16 input.seek(index224_22) if s >= 0: return s elif s == 129: LA224_7 = input.LA(1) index224_7 = input.index() input.rewind() s = -1 if (LA224_7 == 110): s = 90 elif (LA224_7 == 78): s = 91 elif (LA224_7 == 92): s = 92 elif ((9 <= LA224_7 <= 10) or (12 <= LA224_7 <= 13) or LA224_7 == 32) and (self.synpred7_lesscss()): s = 93 else: s = 16 input.seek(index224_7) if s >= 0: return s elif s == 130: LA224_387 = input.LA(1) index224_387 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_387) if s >= 0: return s elif s == 131: LA224_2 = input.LA(1) s = -1 if (LA224_2 == 104): s = 39 elif (LA224_2 == 72): s = 40 elif (LA224_2 == 114): s = 41 elif (LA224_2 == 48): s = 42 elif (LA224_2 == 52 or LA224_2 == 54): s = 43 elif (LA224_2 == 82): s = 44 elif (LA224_2 == 110): s = 45 elif (LA224_2 == 53 or LA224_2 == 55): s = 46 elif (LA224_2 == 78): s = 47 elif (LA224_2 == 109): s = 48 elif (LA224_2 == 77): s = 49 elif (LA224_2 == 118): s = 50 elif (LA224_2 == 86): s = 51 elif (LA224_2 == 115): s = 52 elif (LA224_2 == 83): s = 53 elif (LA224_2 == 116): s = 54 elif (LA224_2 == 84): s = 55 elif (LA224_2 == 112): s = 56 elif (LA224_2 == 80): s = 57 elif (LA224_2 == 103): s = 58 elif (LA224_2 == 71): s = 59 elif (LA224_2 == 105): s = 60 elif (LA224_2 == 73): s = 61 elif (LA224_2 == 107): s = 62 elif (LA224_2 == 75): s = 63 elif ((0 <= LA224_2 <= 9) or LA224_2 == 11 or (14 <= LA224_2 <= 47) or (49 <= LA224_2 <= 51) or (56 <= LA224_2 <= 70) or LA224_2 == 74 or LA224_2 == 76 or LA224_2 == 79 or LA224_2 == 81 or LA224_2 == 85 or (87 <= LA224_2 <= 102) or LA224_2 == 106 or LA224_2 == 108 or LA224_2 == 111 or LA224_2 == 113 or LA224_2 == 117 or (119 <= LA224_2 <= 65535)): s = 16 if s >= 0: return s elif s == 132: LA224_862 = input.LA(1) index224_862 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_862) if s >= 0: return s elif s == 133: LA224_281 = input.LA(1) index224_281 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 161 elif (True): s = 16 input.seek(index224_281) if s >= 0: return s elif s == 134: LA224_224 = input.LA(1) index224_224 = input.index() input.rewind() s = -1 if ((9 <= LA224_224 <= 10) or (12 <= LA224_224 <= 13) or LA224_224 == 32) and (self.synpred11_lesscss()): s = 357 elif (LA224_224 == 110): s = 358 elif (LA224_224 == 92): s = 359 elif (LA224_224 == 78): s = 360 else: s = 16 input.seek(index224_224) if s >= 0: return s elif s == 135: LA224_222 = input.LA(1) index224_222 = input.index() input.rewind() s = -1 if ((9 <= LA224_222 <= 10) or (12 <= LA224_222 <= 13) or LA224_222 == 32) and (self.synpred11_lesscss()): s = 357 elif (LA224_222 == 110): s = 358 elif (LA224_222 == 92): s = 359 elif (LA224_222 == 78): s = 360 else: s = 16 input.seek(index224_222) if s >= 0: return s elif s == 136: LA224_840 = input.LA(1) index224_840 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_840) if s >= 0: return s elif s == 137: LA224_839 = input.LA(1) index224_839 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_839) if s >= 0: return s elif s == 138: LA224_715 = input.LA(1) index224_715 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_715) if s >= 0: return s elif s == 139: LA224_834 = input.LA(1) index224_834 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_834) if s >= 0: return s elif s == 140: LA224_708 = input.LA(1) index224_708 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_708) if s >= 0: return s elif s == 141: LA224_95 = input.LA(1) index224_95 = input.index() input.rewind() s = -1 if (LA224_95 == 103): s = 194 elif (LA224_95 == 71): s = 196 elif (LA224_95 == 92): s = 195 elif ((9 <= LA224_95 <= 10) or (12 <= LA224_95 <= 13) or LA224_95 == 32) and (self.synpred8_lesscss()): s = 193 else: s = 16 input.seek(index224_95) if s >= 0: return s elif s == 142: LA224_94 = input.LA(1) index224_94 = input.index() input.rewind() s = -1 if ((9 <= LA224_94 <= 10) or (12 <= LA224_94 <= 13) or LA224_94 == 32) and (self.synpred8_lesscss()): s = 193 elif (LA224_94 == 103): s = 194 elif (LA224_94 == 92): s = 195 elif (LA224_94 == 71): s = 196 else: s = 16 input.seek(index224_94) if s >= 0: return s elif s == 143: LA224_654 = input.LA(1) index224_654 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_654) if s >= 0: return s elif s == 144: LA224_652 = input.LA(1) index224_652 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_652) if s >= 0: return s elif s == 145: LA224_280 = input.LA(1) index224_280 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 161 elif (True): s = 16 input.seek(index224_280) if s >= 0: return s elif s == 146: LA224_833 = input.LA(1) index224_833 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_833) if s >= 0: return s elif s == 147: LA224_129 = input.LA(1) index224_129 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_129) if s >= 0: return s elif s == 148: LA224_132 = input.LA(1) index224_132 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_132) if s >= 0: return s elif s == 149: LA224_128 = input.LA(1) index224_128 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_128) if s >= 0: return s elif s == 150: LA224_244 = input.LA(1) index224_244 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_244) if s >= 0: return s elif s == 151: LA224_126 = input.LA(1) index224_126 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_126) if s >= 0: return s elif s == 152: LA224_245 = input.LA(1) index224_245 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_245) if s >= 0: return s elif s == 153: LA224_171 = input.LA(1) index224_171 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 297 elif (True): s = 16 input.seek(index224_171) if s >= 0: return s elif s == 154: LA224_443 = input.LA(1) index224_443 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 438 elif (True): s = 16 input.seek(index224_443) if s >= 0: return s elif s == 155: LA224_793 = input.LA(1) index224_793 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_793) if s >= 0: return s elif s == 156: LA224_174 = input.LA(1) index224_174 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 297 elif (True): s = 16 input.seek(index224_174) if s >= 0: return s elif s == 157: LA224_792 = input.LA(1) index224_792 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_792) if s >= 0: return s elif s == 158: LA224_346 = input.LA(1) s = -1 if (LA224_346 == 120): s = 482 elif (LA224_346 == 88): s = 483 elif ((0 <= LA224_346 <= 9) or LA224_346 == 11 or (14 <= LA224_346 <= 47) or (49 <= LA224_346 <= 52) or LA224_346 == 54 or (56 <= LA224_346 <= 87) or (89 <= LA224_346 <= 119) or (121 <= LA224_346 <= 65535)): s = 16 elif (LA224_346 == 48): s = 484 elif (LA224_346 == 53 or LA224_346 == 55): s = 485 if s >= 0: return s elif s == 159: LA224_289 = input.LA(1) index224_289 = input.index() input.rewind() s = -1 if (LA224_289 == 49) and (self.synpred9_lesscss()): s = 432 elif (LA224_289 == 53) and (self.synpred2_lesscss()): s = 433 input.seek(index224_289) if s >= 0: return s elif s == 160: LA224_256 = input.LA(1) index224_256 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_256) if s >= 0: return s elif s == 161: LA224_677 = input.LA(1) index224_677 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_677) if s >= 0: return s elif s == 162: LA224_265 = input.LA(1) index224_265 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_265) if s >= 0: return s elif s == 163: LA224_78 = input.LA(1) s = -1 if (LA224_78 == 116): s = 175 elif (LA224_78 == 84): s = 176 elif (LA224_78 == 120): s = 177 elif (LA224_78 == 48): s = 178 elif (LA224_78 == 53 or LA224_78 == 55): s = 179 elif (LA224_78 == 88): s = 180 elif ((0 <= LA224_78 <= 9) or LA224_78 == 11 or (14 <= LA224_78 <= 47) or (49 <= LA224_78 <= 51) or (56 <= LA224_78 <= 83) or (85 <= LA224_78 <= 87) or (89 <= LA224_78 <= 115) or (117 <= LA224_78 <= 119) or (121 <= LA224_78 <= 65535)): s = 16 elif (LA224_78 == 52 or LA224_78 == 54): s = 181 if s >= 0: return s elif s == 164: LA224_15 = input.LA(1) index224_15 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_15) if s >= 0: return s elif s == 165: LA224_167 = input.LA(1) index224_167 = input.index() input.rewind() s = -1 if (LA224_167 == 104) and (self.synpred3_lesscss()): s = 292 elif (LA224_167 == 72) and (self.synpred3_lesscss()): s = 293 elif (LA224_167 == 48): s = 294 elif (LA224_167 == 52 or LA224_167 == 54): s = 295 elif (LA224_167 == 109) and (self.synpred5_lesscss()): s = 296 elif (LA224_167 == 77) and (self.synpred5_lesscss()): s = 297 input.seek(index224_167) if s >= 0: return s elif s == 166: LA224_30 = input.LA(1) index224_30 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_30) if s >= 0: return s elif s == 167: LA224_449 = input.LA(1) index224_449 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_449) if s >= 0: return s elif s == 168: LA224_861 = input.LA(1) index224_861 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_861) if s >= 0: return s elif s == 169: LA224_681 = input.LA(1) index224_681 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_681) if s >= 0: return s elif s == 170: LA224_680 = input.LA(1) index224_680 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_680) if s >= 0: return s elif s == 171: LA224_847 = input.LA(1) index224_847 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_847) if s >= 0: return s elif s == 172: LA224_203 = input.LA(1) index224_203 = input.index() input.rewind() s = -1 if (LA224_203 == 112) and (self.synpred14_lesscss()): s = 328 elif (LA224_203 == 80) and (self.synpred14_lesscss()): s = 329 elif (LA224_203 == 48): s = 330 elif (LA224_203 == 53 or LA224_203 == 55) and (self.synpred14_lesscss()): s = 331 elif (LA224_203 == 52 or LA224_203 == 54) and (self.synpred8_lesscss()): s = 332 input.seek(index224_203) if s >= 0: return s elif s == 173: LA224_593 = input.LA(1) index224_593 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 332 elif (True): s = 16 input.seek(index224_593) if s >= 0: return s elif s == 174: LA224_787 = input.LA(1) index224_787 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_787) if s >= 0: return s elif s == 175: LA224_841 = input.LA(1) index224_841 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_841) if s >= 0: return s elif s == 176: LA224_774 = input.LA(1) index224_774 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_774) if s >= 0: return s elif s == 177: LA224_775 = input.LA(1) index224_775 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_775) if s >= 0: return s elif s == 178: LA224_835 = input.LA(1) index224_835 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_835) if s >= 0: return s elif s == 179: LA224_788 = input.LA(1) index224_788 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_788) if s >= 0: return s elif s == 180: LA224_47 = input.LA(1) index224_47 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_47) if s >= 0: return s elif s == 181: LA224_342 = input.LA(1) index224_342 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_342) if s >= 0: return s elif s == 182: LA224_45 = input.LA(1) index224_45 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_45) if s >= 0: return s elif s == 183: LA224_339 = input.LA(1) index224_339 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_339) if s >= 0: return s elif s == 184: LA224_195 = input.LA(1) s = -1 if (LA224_195 == 103): s = 319 elif (LA224_195 == 71): s = 320 elif ((0 <= LA224_195 <= 9) or LA224_195 == 11 or (14 <= LA224_195 <= 47) or (49 <= LA224_195 <= 51) or LA224_195 == 53 or (55 <= LA224_195 <= 70) or (72 <= LA224_195 <= 102) or (104 <= LA224_195 <= 65535)): s = 16 elif (LA224_195 == 48): s = 321 elif (LA224_195 == 52 or LA224_195 == 54): s = 322 if s >= 0: return s elif s == 185: LA224_233 = input.LA(1) index224_233 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_233) if s >= 0: return s elif s == 186: LA224_235 = input.LA(1) index224_235 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_235) if s >= 0: return s elif s == 187: LA224_180 = input.LA(1) index224_180 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_180) if s >= 0: return s elif s == 188: LA224_177 = input.LA(1) index224_177 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_177) if s >= 0: return s elif s == 189: LA224_381 = input.LA(1) index224_381 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_381) if s >= 0: return s elif s == 190: LA224_544 = input.LA(1) index224_544 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_544) if s >= 0: return s elif s == 191: LA224_523 = input.LA(1) index224_523 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_523) if s >= 0: return s elif s == 192: LA224_579 = input.LA(1) index224_579 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_579) if s >= 0: return s elif s == 193: LA224_456 = input.LA(1) index224_456 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_456) if s >= 0: return s elif s == 194: LA224_164 = input.LA(1) s = -1 if ((0 <= LA224_164 <= 9) or LA224_164 == 11 or (14 <= LA224_164 <= 47) or (49 <= LA224_164 <= 51) or LA224_164 == 53 or (55 <= LA224_164 <= 65535)): s = 16 elif (LA224_164 == 48): s = 290 elif (LA224_164 == 52 or LA224_164 == 54): s = 291 if s >= 0: return s elif s == 195: LA224_653 = input.LA(1) index224_653 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_653) if s >= 0: return s elif s == 196: LA224_70 = input.LA(1) index224_70 = input.index() input.rewind() s = -1 if (LA224_70 == 72 or LA224_70 == 104) and (self.synpred3_lesscss()): s = 166 elif (LA224_70 == 92): s = 167 elif ((9 <= LA224_70 <= 10) or (12 <= LA224_70 <= 13) or LA224_70 == 32): s = 70 elif (LA224_70 == 77 or LA224_70 == 109) and (self.synpred5_lesscss()): s = 168 input.seek(index224_70) if s >= 0: return s elif s == 197: LA224_350 = input.LA(1) s = -1 if ((0 <= LA224_350 <= 9) or LA224_350 == 11 or (14 <= LA224_350 <= 47) or (49 <= LA224_350 <= 51) or LA224_350 == 53 or (55 <= LA224_350 <= 65535)): s = 16 elif (LA224_350 == 48): s = 486 elif (LA224_350 == 52 or LA224_350 == 54): s = 487 if s >= 0: return s elif s == 198: LA224_524 = input.LA(1) index224_524 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_524) if s >= 0: return s elif s == 199: LA224_525 = input.LA(1) index224_525 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_525) if s >= 0: return s elif s == 200: LA224_442 = input.LA(1) index224_442 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_442) if s >= 0: return s elif s == 201: LA224_444 = input.LA(1) index224_444 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_444) if s >= 0: return s elif s == 202: LA224_737 = input.LA(1) index224_737 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_737) if s >= 0: return s elif s == 203: LA224_92 = input.LA(1) s = -1 if (LA224_92 == 110): s = 189 elif (LA224_92 == 78): s = 190 elif ((0 <= LA224_92 <= 9) or LA224_92 == 11 or (14 <= LA224_92 <= 47) or (49 <= LA224_92 <= 51) or LA224_92 == 53 or (55 <= LA224_92 <= 77) or (79 <= LA224_92 <= 109) or (111 <= LA224_92 <= 65535)): s = 16 elif (LA224_92 == 48): s = 191 elif (LA224_92 == 52 or LA224_92 == 54): s = 192 if s >= 0: return s elif s == 204: LA224_782 = input.LA(1) index224_782 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_782) if s >= 0: return s elif s == 205: LA224_615 = input.LA(1) index224_615 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_615) if s >= 0: return s elif s == 206: LA224_558 = input.LA(1) index224_558 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_558) if s >= 0: return s elif s == 207: LA224_783 = input.LA(1) index224_783 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_783) if s >= 0: return s elif s == 208: LA224_557 = input.LA(1) index224_557 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_557) if s >= 0: return s elif s == 209: LA224_824 = input.LA(1) index224_824 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_824) if s >= 0: return s elif s == 210: LA224_455 = input.LA(1) index224_455 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_455) if s >= 0: return s elif s == 211: LA224_317 = input.LA(1) index224_317 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_317) if s >= 0: return s elif s == 212: LA224_318 = input.LA(1) index224_318 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_318) if s >= 0: return s elif s == 213: LA224_823 = input.LA(1) index224_823 = input.index() input.rewind() s = -1 if (self.synpred10_lesscss()): s = 351 elif (True): s = 16 input.seek(index224_823) if s >= 0: return s elif s == 214: LA224_26 = input.LA(1) index224_26 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_26) if s >= 0: return s elif s == 215: LA224_11 = input.LA(1) index224_11 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_11) if s >= 0: return s elif s == 216: LA224_660 = input.LA(1) index224_660 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_660) if s >= 0: return s elif s == 217: LA224_519 = input.LA(1) index224_519 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_519) if s >= 0: return s elif s == 218: LA224_511 = input.LA(1) index224_511 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_511) if s >= 0: return s elif s == 219: LA224_512 = input.LA(1) index224_512 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_512) if s >= 0: return s elif s == 220: LA224_359 = input.LA(1) s = -1 if (LA224_359 == 110): s = 496 elif (LA224_359 == 48): s = 497 elif (LA224_359 == 78): s = 498 elif ((0 <= LA224_359 <= 9) or LA224_359 == 11 or (14 <= LA224_359 <= 47) or (49 <= LA224_359 <= 51) or LA224_359 == 53 or (55 <= LA224_359 <= 77) or (79 <= LA224_359 <= 109) or (111 <= LA224_359 <= 65535)): s = 16 elif (LA224_359 == 52 or LA224_359 == 54): s = 499 if s >= 0: return s elif s == 221: LA224_672 = input.LA(1) index224_672 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_672) if s >= 0: return s elif s == 222: LA224_665 = input.LA(1) index224_665 = input.index() input.rewind() s = -1 if (self.synpred16_lesscss()): s = 125 elif (True): s = 16 input.seek(index224_665) if s >= 0: return s elif s == 223: LA224_38 = input.LA(1) index224_38 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_38) if s >= 0: return s elif s == 224: LA224_308 = input.LA(1) index224_308 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_308) if s >= 0: return s elif s == 225: LA224_37 = input.LA(1) index224_37 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_37) if s >= 0: return s elif s == 226: LA224_83 = input.LA(1) index224_83 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_83) if s >= 0: return s elif s == 227: LA224_80 = input.LA(1) index224_80 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_80) if s >= 0: return s elif s == 228: LA224_634 = input.LA(1) index224_634 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_634) if s >= 0: return s elif s == 229: LA224_635 = input.LA(1) index224_635 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_635) if s >= 0: return s elif s == 230: LA224_517 = input.LA(1) index224_517 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_517) if s >= 0: return s elif s == 231: LA224_709 = input.LA(1) index224_709 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_709) if s >= 0: return s elif s == 232: LA224_314 = input.LA(1) index224_314 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_314) if s >= 0: return s elif s == 233: LA224_302 = input.LA(1) index224_302 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_302) if s >= 0: return s elif s == 234: LA224_301 = input.LA(1) index224_301 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_301) if s >= 0: return s elif s == 235: LA224_611 = input.LA(1) index224_611 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_611) if s >= 0: return s elif s == 236: LA224_99 = input.LA(1) index224_99 = input.index() input.rewind() s = -1 if ((9 <= LA224_99 <= 10) or (12 <= LA224_99 <= 13) or LA224_99 == 32) and (self.synpred14_lesscss()): s = 205 elif (LA224_99 == 99): s = 206 elif (LA224_99 == 92): s = 207 elif (LA224_99 == 67): s = 208 elif (LA224_99 == 112): s = 209 elif (LA224_99 == 80): s = 210 elif (LA224_99 == 105): s = 211 elif (LA224_99 == 73): s = 212 else: s = 16 input.seek(index224_99) if s >= 0: return s elif s == 237: LA224_98 = input.LA(1) index224_98 = input.index() input.rewind() s = -1 if ((9 <= LA224_98 <= 10) or (12 <= LA224_98 <= 13) or LA224_98 == 32) and (self.synpred14_lesscss()): s = 205 elif (LA224_98 == 99): s = 206 elif (LA224_98 == 92): s = 207 elif (LA224_98 == 67): s = 208 elif (LA224_98 == 112): s = 209 elif (LA224_98 == 80): s = 210 elif (LA224_98 == 105): s = 211 elif (LA224_98 == 73): s = 212 else: s = 16 input.seek(index224_98) if s >= 0: return s elif s == 238: LA224_704 = input.LA(1) index224_704 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 438 elif (True): s = 16 input.seek(index224_704) if s >= 0: return s elif s == 239: LA224_124 = input.LA(1) index224_124 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_124) if s >= 0: return s elif s == 240: LA224_123 = input.LA(1) index224_123 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_123) if s >= 0: return s elif s == 241: LA224_386 = input.LA(1) index224_386 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_386) if s >= 0: return s elif s == 242: LA224_97 = input.LA(1) index224_97 = input.index() input.rewind() s = -1 if (LA224_97 == 69 or LA224_97 == 101) and (self.synpred8_lesscss()): s = 202 elif (LA224_97 == 92): s = 203 elif ((9 <= LA224_97 <= 10) or (12 <= LA224_97 <= 13) or LA224_97 == 32): s = 97 elif (LA224_97 == 80 or LA224_97 == 112) and (self.synpred14_lesscss()): s = 204 input.seek(index224_97) if s >= 0: return s elif s == 243: LA224_385 = input.LA(1) index224_385 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_385) if s >= 0: return s elif s == 244: LA224_423 = input.LA(1) index224_423 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_423) if s >= 0: return s elif s == 245: LA224_741 = input.LA(1) index224_741 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_741) if s >= 0: return s elif s == 246: LA224_424 = input.LA(1) index224_424 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_424) if s >= 0: return s elif s == 247: LA224_602 = input.LA(1) index224_602 = input.index() input.rewind() s = -1 if (LA224_602 == 48): s = 728 elif (LA224_602 == 53 or LA224_602 == 55) and (self.synpred14_lesscss()): s = 331 elif (LA224_602 == 52 or LA224_602 == 54) and (self.synpred8_lesscss()): s = 332 input.seek(index224_602) if s >= 0: return s elif s == 248: LA224_152 = input.LA(1) index224_152 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_152) if s >= 0: return s elif s == 249: LA224_211 = input.LA(1) index224_211 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_211) if s >= 0: return s elif s == 250: LA224_212 = input.LA(1) index224_212 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_212) if s >= 0: return s elif s == 251: LA224_81 = input.LA(1) index224_81 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_81) if s >= 0: return s elif s == 252: LA224_313 = input.LA(1) index224_313 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_313) if s >= 0: return s elif s == 253: LA224_29 = input.LA(1) index224_29 = input.index() input.rewind() s = -1 if (LA224_29 == 119): s = 117 elif (LA224_29 == 87): s = 118 elif (LA224_29 == 92): s = 119 elif ((9 <= LA224_29 <= 10) or (12 <= LA224_29 <= 13) or LA224_29 == 32) and (self.synpred15_lesscss()): s = 120 elif (LA224_29 == 104): s = 121 elif (LA224_29 == 72): s = 122 elif (LA224_29 == 109): s = 123 elif (LA224_29 == 77): s = 124 else: s = 16 input.seek(index224_29) if s >= 0: return s elif s == 254: LA224_14 = input.LA(1) index224_14 = input.index() input.rewind() s = -1 if (LA224_14 == 119): s = 117 elif (LA224_14 == 87): s = 118 elif (LA224_14 == 92): s = 119 elif ((9 <= LA224_14 <= 10) or (12 <= LA224_14 <= 13) or LA224_14 == 32) and (self.synpred15_lesscss()): s = 120 elif (LA224_14 == 104): s = 121 elif (LA224_14 == 72): s = 122 elif (LA224_14 == 109): s = 123 elif (LA224_14 == 77): s = 124 else: s = 16 input.seek(index224_14) if s >= 0: return s elif s == 255: LA224_66 = input.LA(1) s = -1 if ((0 <= LA224_66 <= 9) or LA224_66 == 11 or (14 <= LA224_66 <= 47) or (49 <= LA224_66 <= 51) or LA224_66 == 53 or (55 <= LA224_66 <= 65535)): s = 16 elif (LA224_66 == 48): s = 157 elif (LA224_66 == 52 or LA224_66 == 54): s = 158 if s >= 0: return s elif s == 256: LA224_77 = input.LA(1) index224_77 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_77) if s >= 0: return s elif s == 257: LA224_858 = input.LA(1) index224_858 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_858) if s >= 0: return s elif s == 258: LA224_859 = input.LA(1) index224_859 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_859) if s >= 0: return s elif s == 259: LA224_482 = input.LA(1) index224_482 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_482) if s >= 0: return s elif s == 260: LA224_483 = input.LA(1) index224_483 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_483) if s >= 0: return s elif s == 261: LA224_655 = input.LA(1) index224_655 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_655) if s >= 0: return s elif s == 262: LA224_35 = input.LA(1) s = -1 if (LA224_35 == 120): s = 126 elif (LA224_35 == 48): s = 127 elif (LA224_35 == 88): s = 128 elif (LA224_35 == 109): s = 129 elif (LA224_35 == 53 or LA224_35 == 55): s = 130 elif (LA224_35 == 52 or LA224_35 == 54): s = 131 elif (LA224_35 == 77): s = 132 elif ((0 <= LA224_35 <= 9) or LA224_35 == 11 or (14 <= LA224_35 <= 47) or (49 <= LA224_35 <= 51) or (56 <= LA224_35 <= 76) or (78 <= LA224_35 <= 87) or (89 <= LA224_35 <= 108) or (110 <= LA224_35 <= 119) or (121 <= LA224_35 <= 65535)): s = 16 if s >= 0: return s elif s == 263: LA224_86 = input.LA(1) s = -1 if (LA224_86 == 115): s = 182 elif (LA224_86 == 83): s = 183 elif (LA224_86 == 109): s = 184 elif (LA224_86 == 48): s = 185 elif (LA224_86 == 53 or LA224_86 == 55): s = 186 elif (LA224_86 == 77): s = 187 elif ((0 <= LA224_86 <= 9) or LA224_86 == 11 or (14 <= LA224_86 <= 47) or (49 <= LA224_86 <= 51) or (56 <= LA224_86 <= 76) or (78 <= LA224_86 <= 82) or (84 <= LA224_86 <= 108) or (110 <= LA224_86 <= 114) or (116 <= LA224_86 <= 65535)): s = 16 elif (LA224_86 == 52 or LA224_86 == 54): s = 188 if s >= 0: return s elif s == 264: LA224_374 = input.LA(1) index224_374 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_374) if s >= 0: return s elif s == 265: LA224_373 = input.LA(1) index224_373 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_373) if s >= 0: return s elif s == 266: LA224_24 = input.LA(1) index224_24 = input.index() input.rewind() s = -1 if (LA224_24 == 114): s = 100 elif (LA224_24 == 82): s = 101 elif (LA224_24 == 92): s = 102 elif ((9 <= LA224_24 <= 10) or (12 <= LA224_24 <= 13) or LA224_24 == 32) and (self.synpred10_lesscss()): s = 103 else: s = 16 input.seek(index224_24) if s >= 0: return s elif s == 267: LA224_170 = input.LA(1) index224_170 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 293 elif (True): s = 16 input.seek(index224_170) if s >= 0: return s elif s == 268: LA224_169 = input.LA(1) index224_169 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 293 elif (True): s = 16 input.seek(index224_169) if s >= 0: return s elif s == 269: LA224_239 = input.LA(1) index224_239 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_239) if s >= 0: return s elif s == 270: LA224_330 = input.LA(1) index224_330 = input.index() input.rewind() s = -1 if (LA224_330 == 48): s = 471 elif (LA224_330 == 53 or LA224_330 == 55) and (self.synpred14_lesscss()): s = 331 elif (LA224_330 == 52 or LA224_330 == 54) and (self.synpred8_lesscss()): s = 332 input.seek(index224_330) if s >= 0: return s elif s == 271: LA224_243 = input.LA(1) index224_243 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_243) if s >= 0: return s elif s == 272: LA224_798 = input.LA(1) index224_798 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 332 elif (True): s = 16 input.seek(index224_798) if s >= 0: return s elif s == 273: LA224_9 = input.LA(1) index224_9 = input.index() input.rewind() s = -1 if (LA224_9 == 114): s = 100 elif (LA224_9 == 82): s = 101 elif (LA224_9 == 92): s = 102 elif ((9 <= LA224_9 <= 10) or (12 <= LA224_9 <= 13) or LA224_9 == 32) and (self.synpred10_lesscss()): s = 103 else: s = 16 input.seek(index224_9) if s >= 0: return s elif s == 274: LA224_319 = input.LA(1) index224_319 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 332 elif (True): s = 16 input.seek(index224_319) if s >= 0: return s elif s == 275: LA224_320 = input.LA(1) index224_320 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 332 elif (True): s = 16 input.seek(index224_320) if s >= 0: return s elif s == 276: LA224_111 = input.LA(1) s = -1 if (LA224_111 == 104): s = 229 elif (LA224_111 == 72): s = 230 elif ((0 <= LA224_111 <= 9) or LA224_111 == 11 or (14 <= LA224_111 <= 47) or (49 <= LA224_111 <= 51) or LA224_111 == 53 or (55 <= LA224_111 <= 71) or (73 <= LA224_111 <= 103) or (105 <= LA224_111 <= 65535)): s = 16 elif (LA224_111 == 48): s = 231 elif (LA224_111 == 52 or LA224_111 == 54): s = 232 if s >= 0: return s elif s == 277: LA224_295 = input.LA(1) index224_295 = input.index() input.rewind() s = -1 if (LA224_295 == 56) and (self.synpred3_lesscss()): s = 438 elif (LA224_295 == 68 or LA224_295 == 100) and (self.synpred5_lesscss()): s = 439 input.seek(index224_295) if s >= 0: return s elif s == 278: LA224_705 = input.LA(1) index224_705 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_705) if s >= 0: return s elif s == 279: LA224_101 = input.LA(1) index224_101 = input.index() input.rewind() s = -1 if (LA224_101 == 97): s = 213 elif (LA224_101 == 65): s = 214 elif (LA224_101 == 92): s = 215 elif ((9 <= LA224_101 <= 10) or (12 <= LA224_101 <= 13) or LA224_101 == 32) and (self.synpred10_lesscss()): s = 216 else: s = 16 input.seek(index224_101) if s >= 0: return s elif s == 280: LA224_100 = input.LA(1) index224_100 = input.index() input.rewind() s = -1 if (LA224_100 == 97): s = 213 elif (LA224_100 == 65): s = 214 elif (LA224_100 == 92): s = 215 elif ((9 <= LA224_100 <= 10) or (12 <= LA224_100 <= 13) or LA224_100 == 32) and (self.synpred10_lesscss()): s = 216 else: s = 16 input.seek(index224_100) if s >= 0: return s elif s == 281: LA224_703 = input.LA(1) index224_703 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_703) if s >= 0: return s elif s == 282: LA224_209 = input.LA(1) index224_209 = input.index() input.rewind() s = -1 if (LA224_209 == 120): s = 344 elif (LA224_209 == 88): s = 345 elif (LA224_209 == 92): s = 346 elif ((9 <= LA224_209 <= 10) or (12 <= LA224_209 <= 13) or LA224_209 == 32) and (self.synpred14_lesscss()): s = 347 else: s = 16 input.seek(index224_209) if s >= 0: return s elif s == 283: LA224_210 = input.LA(1) index224_210 = input.index() input.rewind() s = -1 if (LA224_210 == 120): s = 344 elif (LA224_210 == 88): s = 345 elif (LA224_210 == 92): s = 346 elif ((9 <= LA224_210 <= 10) or (12 <= LA224_210 <= 13) or LA224_210 == 32) and (self.synpred14_lesscss()): s = 347 else: s = 16 input.seek(index224_210) if s >= 0: return s elif s == 284: LA224_117 = input.LA(1) index224_117 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_117) if s >= 0: return s elif s == 285: LA224_118 = input.LA(1) index224_118 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_118) if s >= 0: return s elif s == 286: LA224_713 = input.LA(1) index224_713 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_713) if s >= 0: return s elif s == 287: LA224_714 = input.LA(1) index224_714 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_714) if s >= 0: return s elif s == 288: LA224_590 = input.LA(1) index224_590 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_590) if s >= 0: return s elif s == 289: LA224_589 = input.LA(1) index224_589 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_589) if s >= 0: return s elif s == 290: LA224_271 = input.LA(1) index224_271 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_271) if s >= 0: return s elif s == 291: LA224_778 = input.LA(1) index224_778 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_778) if s >= 0: return s elif s == 292: LA224_155 = input.LA(1) s = -1 if (LA224_155 == 109): s = 280 elif (LA224_155 == 77): s = 281 elif ((0 <= LA224_155 <= 9) or LA224_155 == 11 or (14 <= LA224_155 <= 47) or (49 <= LA224_155 <= 51) or LA224_155 == 53 or (55 <= LA224_155 <= 76) or (78 <= LA224_155 <= 108) or (110 <= LA224_155 <= 65535)): s = 16 elif (LA224_155 == 48): s = 282 elif (LA224_155 == 52 or LA224_155 == 54): s = 283 if s >= 0: return s elif s == 293: LA224_814 = input.LA(1) index224_814 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_814) if s >= 0: return s elif s == 294: LA224_779 = input.LA(1) index224_779 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_779) if s >= 0: return s elif s == 295: LA224_547 = input.LA(1) index224_547 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_547) if s >= 0: return s elif s == 296: LA224_429 = input.LA(1) index224_429 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_429) if s >= 0: return s elif s == 297: LA224_430 = input.LA(1) index224_430 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_430) if s >= 0: return s elif s == 298: LA224_773 = input.LA(1) index224_773 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_773) if s >= 0: return s elif s == 299: LA224_837 = input.LA(1) index224_837 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_837) if s >= 0: return s elif s == 300: LA224_548 = input.LA(1) index224_548 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_548) if s >= 0: return s elif s == 301: LA224_836 = input.LA(1) index224_836 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_836) if s >= 0: return s elif s == 302: LA224_767 = input.LA(1) index224_767 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_767) if s >= 0: return s elif s == 303: LA224_766 = input.LA(1) index224_766 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_766) if s >= 0: return s elif s == 304: LA224_580 = input.LA(1) index224_580 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_580) if s >= 0: return s elif s == 305: LA224_89 = input.LA(1) index224_89 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_89) if s >= 0: return s elif s == 306: LA224_732 = input.LA(1) index224_732 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_732) if s >= 0: return s elif s == 307: LA224_731 = input.LA(1) index224_731 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_731) if s >= 0: return s elif s == 308: LA224_828 = input.LA(1) index224_828 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_828) if s >= 0: return s elif s == 309: LA224_827 = input.LA(1) index224_827 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_827) if s >= 0: return s elif s == 310: LA224_85 = input.LA(1) index224_85 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_85) if s >= 0: return s elif s == 311: LA224_84 = input.LA(1) index224_84 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_84) if s >= 0: return s elif s == 312: LA224_335 = input.LA(1) s = -1 if (LA224_335 == 109): s = 472 elif (LA224_335 == 77): s = 473 elif ((0 <= LA224_335 <= 9) or LA224_335 == 11 or (14 <= LA224_335 <= 47) or (49 <= LA224_335 <= 51) or LA224_335 == 53 or (55 <= LA224_335 <= 76) or (78 <= LA224_335 <= 108) or (110 <= LA224_335 <= 65535)): s = 16 elif (LA224_335 == 48): s = 474 elif (LA224_335 == 52 or LA224_335 == 54): s = 475 if s >= 0: return s elif s == 313: LA224_88 = input.LA(1) index224_88 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_88) if s >= 0: return s elif s == 314: LA224_419 = input.LA(1) index224_419 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_419) if s >= 0: return s elif s == 315: LA224_418 = input.LA(1) index224_418 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_418) if s >= 0: return s elif s == 316: LA224_572 = input.LA(1) index224_572 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_572) if s >= 0: return s elif s == 317: LA224_574 = input.LA(1) index224_574 = input.index() input.rewind() s = -1 if (self.synpred5_lesscss()): s = 439 elif (True): s = 16 input.seek(index224_574) if s >= 0: return s elif s == 318: LA224_237 = input.LA(1) index224_237 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_237) if s >= 0: return s elif s == 319: LA224_238 = input.LA(1) index224_238 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_238) if s >= 0: return s elif s == 320: LA224_810 = input.LA(1) index224_810 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_810) if s >= 0: return s elif s == 321: LA224_659 = input.LA(1) index224_659 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_659) if s >= 0: return s elif s == 322: LA224_658 = input.LA(1) index224_658 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_658) if s >= 0: return s elif s == 323: LA224_771 = input.LA(1) index224_771 = input.index() input.rewind() s = -1 if (self.synpred15_lesscss()): s = 120 elif (True): s = 16 input.seek(index224_771) if s >= 0: return s elif s == 324: LA224_52 = input.LA(1) index224_52 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_52) if s >= 0: return s elif s == 325: LA224_53 = input.LA(1) index224_53 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_53) if s >= 0: return s elif s == 326: LA224_102 = input.LA(1) s = -1 if (LA224_102 == 114): s = 217 elif (LA224_102 == 82): s = 218 elif ((0 <= LA224_102 <= 9) or LA224_102 == 11 or (14 <= LA224_102 <= 47) or (49 <= LA224_102 <= 52) or LA224_102 == 54 or (56 <= LA224_102 <= 81) or (83 <= LA224_102 <= 113) or (115 <= LA224_102 <= 65535)): s = 16 elif (LA224_102 == 48): s = 219 elif (LA224_102 == 53 or LA224_102 == 55): s = 220 if s >= 0: return s elif s == 327: LA224_223 = input.LA(1) s = -1 if (LA224_223 == 114): s = 361 elif (LA224_223 == 82): s = 362 elif ((0 <= LA224_223 <= 9) or LA224_223 == 11 or (14 <= LA224_223 <= 47) or (49 <= LA224_223 <= 52) or LA224_223 == 54 or (56 <= LA224_223 <= 81) or (83 <= LA224_223 <= 113) or (115 <= LA224_223 <= 65535)): s = 16 elif (LA224_223 == 48): s = 363 elif (LA224_223 == 53 or LA224_223 == 55): s = 364 if s >= 0: return s elif s == 328: LA224_65 = input.LA(1) index224_65 = input.index() input.rewind() s = -1 if ((9 <= LA224_65 <= 10) or (12 <= LA224_65 <= 13) or LA224_65 == 32) and (self.synpred2_lesscss()): s = 153 elif (LA224_65 == 109): s = 154 elif (LA224_65 == 92): s = 155 elif (LA224_65 == 77): s = 156 else: s = 16 input.seek(index224_65) if s >= 0: return s elif s == 329: LA224_64 = input.LA(1) index224_64 = input.index() input.rewind() s = -1 if ((9 <= LA224_64 <= 10) or (12 <= LA224_64 <= 13) or LA224_64 == 32) and (self.synpred2_lesscss()): s = 153 elif (LA224_64 == 109): s = 154 elif (LA224_64 == 92): s = 155 elif (LA224_64 == 77): s = 156 else: s = 16 input.seek(index224_64) if s >= 0: return s elif s == 330: LA224_585 = input.LA(1) index224_585 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_585) if s >= 0: return s elif s == 331: LA224_584 = input.LA(1) index224_584 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_584) if s >= 0: return s elif s == 332: LA224_460 = input.LA(1) index224_460 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_460) if s >= 0: return s elif s == 333: LA224_459 = input.LA(1) index224_459 = input.index() input.rewind() s = -1 if (self.synpred7_lesscss()): s = 93 elif (True): s = 16 input.seek(index224_459) if s >= 0: return s elif s == 334: LA224_344 = input.LA(1) index224_344 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_344) if s >= 0: return s elif s == 335: LA224_25 = input.LA(1) index224_25 = input.index() input.rewind() s = -1 if (LA224_25 == 117): s = 104 elif (LA224_25 == 85): s = 105 elif (LA224_25 == 92): s = 106 elif ((9 <= LA224_25 <= 10) or (12 <= LA224_25 <= 13) or LA224_25 == 32) and (self.synpred11_lesscss()): s = 107 else: s = 16 input.seek(index224_25) if s >= 0: return s elif s == 336: LA224_10 = input.LA(1) index224_10 = input.index() input.rewind() s = -1 if (LA224_10 == 117): s = 104 elif (LA224_10 == 85): s = 105 elif (LA224_10 == 92): s = 106 elif ((9 <= LA224_10 <= 10) or (12 <= LA224_10 <= 13) or LA224_10 == 32) and (self.synpred11_lesscss()): s = 107 else: s = 16 input.seek(index224_10) if s >= 0: return s elif s == 337: LA224_194 = input.LA(1) index224_194 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 202 elif (True): s = 16 input.seek(index224_194) if s >= 0: return s elif s == 338: LA224_196 = input.LA(1) index224_196 = input.index() input.rewind() s = -1 if (self.synpred8_lesscss()): s = 202 elif (True): s = 16 input.seek(index224_196) if s >= 0: return s elif s == 339: LA224_345 = input.LA(1) index224_345 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_345) if s >= 0: return s elif s == 340: LA224_850 = input.LA(1) index224_850 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_850) if s >= 0: return s elif s == 341: LA224_691 = input.LA(1) index224_691 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_691) if s >= 0: return s elif s == 342: LA224_690 = input.LA(1) index224_690 = input.index() input.rewind() s = -1 if (self.synpred2_lesscss()): s = 433 elif (True): s = 16 input.seek(index224_690) if s >= 0: return s elif s == 343: LA224_407 = input.LA(1) index224_407 = input.index() input.rewind() s = -1 if (self.synpred12_lesscss()): s = 108 elif (True): s = 16 input.seek(index224_407) if s >= 0: return s elif s == 344: LA224_647 = input.LA(1) index224_647 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_647) if s >= 0: return s elif s == 345: LA224_648 = input.LA(1) index224_648 = input.index() input.rewind() s = -1 if (self.synpred13_lesscss()): s = 116 elif (True): s = 16 input.seek(index224_648) if s >= 0: return s elif s == 346: LA224_790 = input.LA(1) index224_790 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_790) if s >= 0: return s elif s == 347: LA224_728 = input.LA(1) index224_728 = input.index() input.rewind() s = -1 if (LA224_728 == 52 or LA224_728 == 54) and (self.synpred8_lesscss()): s = 332 elif (LA224_728 == 53 or LA224_728 == 55) and (self.synpred14_lesscss()): s = 331 input.seek(index224_728) if s >= 0: return s elif s == 348: LA224_115 = input.LA(1) s = -1 if (LA224_115 == 122): s = 233 elif (LA224_115 == 48): s = 234 elif (LA224_115 == 90): s = 235 elif ((0 <= LA224_115 <= 9) or LA224_115 == 11 or (14 <= LA224_115 <= 47) or (49 <= LA224_115 <= 52) or LA224_115 == 54 or (56 <= LA224_115 <= 89) or (91 <= LA224_115 <= 121) or (123 <= LA224_115 <= 65535)): s = 16 elif (LA224_115 == 53 or LA224_115 == 55): s = 236 if s >= 0: return s elif s == 349: LA224_410 = input.LA(1) index224_410 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_410) if s >= 0: return s elif s == 350: LA224_411 = input.LA(1) index224_411 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_411) if s >= 0: return s elif s == 351: LA224_794 = input.LA(1) index224_794 = input.index() input.rewind() s = -1 if (self.synpred6_lesscss()): s = 87 elif (True): s = 16 input.seek(index224_794) if s >= 0: return s elif s == 352: LA224_71 = input.LA(1) index224_71 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 166 elif (True): s = 16 input.seek(index224_71) if s >= 0: return s elif s == 353: LA224_73 = input.LA(1) index224_73 = input.index() input.rewind() s = -1 if (self.synpred3_lesscss()): s = 166 elif (True): s = 16 input.seek(index224_73) if s >= 0: return s elif s == 354: LA224_34 = input.LA(1) index224_34 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_34) if s >= 0: return s elif s == 355: LA224_33 = input.LA(1) index224_33 = input.index() input.rewind() s = -1 if (self.synpred1_lesscss()): s = 36 elif (True): s = 16 input.seek(index224_33) if s >= 0: return s elif s == 356: LA224_757 = input.LA(1) index224_757 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_757) if s >= 0: return s elif s == 357: LA224_756 = input.LA(1) index224_756 = input.index() input.rewind() s = -1 if (self.synpred11_lesscss()): s = 357 elif (True): s = 16 input.seek(index224_756) if s >= 0: return s elif s == 358: LA224_450 = input.LA(1) index224_450 = input.index() input.rewind() s = -1 if (self.synpred4_lesscss()): s = 76 elif (True): s = 16 input.seek(index224_450) if s >= 0: return s elif s == 359: LA224_72 = input.LA(1) s = -1 if (LA224_72 == 104): s = 169 elif (LA224_72 == 72): s = 170 elif (LA224_72 == 109): s = 171 elif (LA224_72 == 48): s = 172 elif (LA224_72 == 52 or LA224_72 == 54): s = 173 elif (LA224_72 == 77): s = 174 elif ((0 <= LA224_72 <= 9) or LA224_72 == 11 or (14 <= LA224_72 <= 47) or (49 <= LA224_72 <= 51) or LA224_72 == 53 or (55 <= LA224_72 <= 71) or (73 <= LA224_72 <= 76) or (78 <= LA224_72 <= 103) or (105 <= LA224_72 <= 108) or (110 <= LA224_72 <= 65535)): s = 16 if s >= 0: return s elif s == 360: LA224_606 = input.LA(1) index224_606 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_606) if s >= 0: return s elif s == 361: LA224_605 = input.LA(1) index224_605 = input.index() input.rewind() s = -1 if (self.synpred14_lesscss()): s = 347 elif (True): s = 16 input.seek(index224_605) if s >= 0: return s elif s == 362: LA224_553 = input.LA(1) index224_553 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_553) if s >= 0: return s elif s == 363: LA224_554 = input.LA(1) index224_554 = input.index() input.rewind() s = -1 if (self.synpred9_lesscss()): s = 432 elif (True): s = 16 input.seek(index224_554) if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 224, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #217 DFA217_eot = DFA.unpack( u"\12\uffff" ) DFA217_eof = DFA.unpack( u"\12\uffff" ) DFA217_min = DFA.unpack( u"\1\103\1\uffff\1\60\2\uffff\1\60\1\64\2\60\1\64" ) DFA217_max = DFA.unpack( u"\1\170\1\uffff\1\170\2\uffff\1\67\1\70\3\67" ) DFA217_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\2\1\3\5\uffff" ) DFA217_special = DFA.unpack( u"\12\uffff" ) DFA217_transition = [ DFA.unpack(u"\1\4\20\uffff\1\3\3\uffff\1\1\3\uffff\1\2\6\uffff\1" u"\4\20\uffff\1\3\3\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u"\1\5\3\uffff\1\4\1\6\1\4\1\6\34\uffff\1\3\3\uffff\1" u"\1\33\uffff\1\3\3\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\7\3\uffff\1\4\1\6\1\4\1\6"), DFA.unpack(u"\1\3\3\uffff\1\1"), DFA.unpack(u"\1\10\3\uffff\1\4\1\6\1\4\1\6"), DFA.unpack(u"\1\11\3\uffff\1\4\1\6\1\4\1\6"), DFA.unpack(u"\1\4\1\6\1\4\1\6") ] # class definition for DFA #217 class DFA217(DFA): pass # lookup tables for DFA #220 DFA220_eot = DFA.unpack( u"\25\uffff" ) DFA220_eof = DFA.unpack( u"\25\uffff" ) DFA220_min = DFA.unpack( u"\1\120\1\11\1\60\1\11\1\uffff\1\60\2\uffff\2\103\3\60\1\63\1\60" u"\1\103\3\60\1\65\1\64" ) DFA220_max = DFA.unpack( u"\4\160\1\uffff\1\160\2\uffff\2\160\1\67\1\60\1\67\1\71\1\67\1\160" u"\5\67" ) DFA220_accept = DFA.unpack( u"\4\uffff\1\1\1\uffff\1\3\1\2\15\uffff" ) DFA220_special = DFA.unpack( u"\25\uffff" ) DFA220_transition = [ DFA.unpack(u"\1\1\13\uffff\1\2\23\uffff\1\1"), DFA.unpack(u"\2\3\1\uffff\2\3\22\uffff\1\3\42\uffff\1\7\5\uffff" u"\1\4\6\uffff\1\6\13\uffff\1\5\6\uffff\1\7\5\uffff\1\4\6\uffff\1" u"\6"), DFA.unpack(u"\1\12\4\uffff\1\13\1\uffff\1\13\30\uffff\1\11\37\uffff" u"\1\10"), DFA.unpack(u"\2\3\1\uffff\2\3\22\uffff\1\3\42\uffff\1\7\5\uffff" u"\1\4\6\uffff\1\6\13\uffff\1\5\6\uffff\1\7\5\uffff\1\4\6\uffff\1" u"\6"), DFA.unpack(u""), DFA.unpack(u"\1\14\3\uffff\1\15\1\6\1\15\1\6\21\uffff\1\4\6\uffff" u"\1\6\30\uffff\1\4\6\uffff\1\6"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\7\5\uffff\1\4\6\uffff\1\6\13\uffff\1\5\6\uffff\1" u"\7\5\uffff\1\4\6\uffff\1\6"), DFA.unpack(u"\1\7\5\uffff\1\4\6\uffff\1\6\13\uffff\1\5\6\uffff\1" u"\7\5\uffff\1\4\6\uffff\1\6"), DFA.unpack(u"\1\16\4\uffff\1\13\1\uffff\1\13"), DFA.unpack(u"\1\17"), DFA.unpack(u"\1\20\3\uffff\1\15\1\6\1\15\1\6"), DFA.unpack(u"\1\7\5\uffff\1\4"), DFA.unpack(u"\1\21\4\uffff\1\13\1\uffff\1\13"), DFA.unpack(u"\1\7\5\uffff\1\4\6\uffff\1\6\13\uffff\1\5\6\uffff\1" u"\7\5\uffff\1\4\6\uffff\1\6"), DFA.unpack(u"\1\22\3\uffff\1\15\1\6\1\15\1\6"), DFA.unpack(u"\1\23\4\uffff\1\13\1\uffff\1\13"), DFA.unpack(u"\1\24\3\uffff\1\15\1\6\1\15\1\6"), DFA.unpack(u"\1\13\1\uffff\1\13"), DFA.unpack(u"\1\15\1\6\1\15\1\6") ] # class definition for DFA #220 class DFA220(DFA): pass # lookup tables for DFA #221 DFA221_eot = DFA.unpack( u"\4\uffff\1\12\2\uffff\3\12\5\uffff\1\12\7\uffff" ) DFA221_eof = DFA.unpack( u"\27\uffff" ) DFA221_min = DFA.unpack( u"\1\110\1\uffff\1\60\1\uffff\1\11\1\60\1\70\2\101\1\11\2\uffff\1" u"\60\1\uffff\1\60\1\101\1\60\1\61\2\60\1\64\1\60\1\64" ) DFA221_max = DFA.unpack( u"\1\167\1\uffff\1\167\1\uffff\1\151\1\67\1\144\3\151\2\uffff\1\151" u"\1\uffff\1\67\1\151\1\66\1\71\1\67\1\66\1\67\2\66" ) DFA221_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\2\6\uffff\1\3\1\5\1\uffff\1\4\11\uffff" ) DFA221_special = DFA.unpack( u"\27\uffff" ) DFA221_transition = [ DFA.unpack(u"\1\3\4\uffff\1\4\11\uffff\1\1\4\uffff\1\2\13\uffff\1" u"\3\4\uffff\1\4\11\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u"\1\5\3\uffff\1\6\1\1\1\6\1\1\20\uffff\1\3\4\uffff\1" u"\10\11\uffff\1\1\20\uffff\1\3\4\uffff\1\7\11\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u"\2\11\1\uffff\2\11\22\uffff\1\11\40\uffff\1\13\7\uffff" u"\1\15\22\uffff\1\14\4\uffff\1\13\7\uffff\1\15"), DFA.unpack(u"\1\16\3\uffff\1\6\1\1\1\6\1\1"), DFA.unpack(u"\1\3\13\uffff\1\17\37\uffff\1\17"), DFA.unpack(u"\1\13\7\uffff\1\15\22\uffff\1\14\4\uffff\1\13\7\uffff" u"\1\15"), DFA.unpack(u"\1\13\7\uffff\1\15\22\uffff\1\14\4\uffff\1\13\7\uffff" u"\1\15"), DFA.unpack(u"\2\11\1\uffff\2\11\22\uffff\1\11\40\uffff\1\13\7\uffff" u"\1\15\22\uffff\1\14\4\uffff\1\13\7\uffff\1\15"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\20\3\uffff\1\21\1\uffff\1\21\22\uffff\1\15\37\uffff" u"\1\15"), DFA.unpack(u""), DFA.unpack(u"\1\22\3\uffff\1\6\1\1\1\6\1\1"), DFA.unpack(u"\1\13\7\uffff\1\15\22\uffff\1\14\4\uffff\1\13\7\uffff" u"\1\15"), DFA.unpack(u"\1\23\3\uffff\1\21\1\uffff\1\21"), DFA.unpack(u"\1\13\7\uffff\1\15"), DFA.unpack(u"\1\24\3\uffff\1\6\1\1\1\6\1\1"), DFA.unpack(u"\1\25\3\uffff\1\21\1\uffff\1\21"), DFA.unpack(u"\1\6\1\1\1\6\1\1"), DFA.unpack(u"\1\26\3\uffff\1\21\1\uffff\1\21"), DFA.unpack(u"\1\21\1\uffff\1\21") ] # class definition for DFA #221 class DFA221(DFA): pass # lookup tables for DFA #223 DFA223_eot = DFA.unpack( u"\1\uffff\1\4\1\uffff\1\4\2\uffff\2\4\3\uffff\1\4\2\uffff" ) DFA223_eof = DFA.unpack( u"\16\uffff" ) DFA223_min = DFA.unpack( u"\1\116\1\11\1\60\1\11\2\uffff\2\53\1\60\1\105\1\60\1\53\1\60\1" u"\64" ) DFA223_max = DFA.unpack( u"\1\156\1\55\1\156\1\55\2\uffff\2\55\1\66\1\145\1\66\1\55\2\66" ) DFA223_accept = DFA.unpack( u"\4\uffff\1\2\1\1\10\uffff" ) DFA223_special = DFA.unpack( u"\16\uffff" ) DFA223_transition = [ DFA.unpack(u"\1\1\15\uffff\1\2\21\uffff\1\1"), DFA.unpack(u"\2\3\1\uffff\2\3\22\uffff\1\3\12\uffff\1\5\1\uffff" u"\1\5"), DFA.unpack(u"\1\10\3\uffff\1\11\1\uffff\1\11\27\uffff\1\7\37\uffff" u"\1\6"), DFA.unpack(u"\2\3\1\uffff\2\3\22\uffff\1\3\12\uffff\1\5\1\uffff" u"\1\5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\5\1\uffff\1\5"), DFA.unpack(u"\1\5\1\uffff\1\5"), DFA.unpack(u"\1\12\3\uffff\1\11\1\uffff\1\11"), DFA.unpack(u"\1\13\37\uffff\1\13"), DFA.unpack(u"\1\14\3\uffff\1\11\1\uffff\1\11"), DFA.unpack(u"\1\5\1\uffff\1\5"), DFA.unpack(u"\1\15\3\uffff\1\11\1\uffff\1\11"), DFA.unpack(u"\1\11\1\uffff\1\11") ] # class definition for DFA #223 class DFA223(DFA): pass # lookup tables for DFA #231 DFA231_eot = DFA.unpack( u"\1\uffff\1\44\1\uffff\1\46\4\uffff\1\51\14\uffff\1\52\1\uffff\1" u"\54\1\uffff\4\54\21\uffff\5\54\2\uffff\10\54\1\uffff\1\100\2\uffff" u"\2\100\1\uffff\10\100\1\uffff\2\54\1\uffff\15\54\1\100\1\uffff" u"\1\100\1\uffff\14\100\1\uffff\1\100\1\uffff\1\100\1\uffff\1\100" u"\1\uffff\3\100\1\uffff\2\100\2\uffff\1\64\21\54\2\100\1\uffff\16" u"\100\1\uffff\6\100\1\uffff\4\100\1\uffff\4\100\1\uffff\5\100\20" u"\54\3\100\1\uffff\27\100\1\uffff\10\100\2\161\1\uffff\10\100\1" u"\uffff\11\100\1\uffff\11\100\17\54\1\100\2\136\1\uffff\67\100\1" u"\uffff\13\100\1\uffff\13\100\15\54\43\100\1\uffff\15\100\1\161" u"\3\100\2\161\4\100\1\uffff\20\100\1\173\1\uffff\1\173\17\100\7" u"\54\1\u023c\2\100\1\136\3\100\2\136\27\100\1\uffff\17\100\1\161" u"\3\100\3\161\3\100\1\uffff\21\100\1\173\1\100\1\173\16\100\2\54" u"\1\uffff\2\100\1\136\3\100\3\136\7\100\1\uffff\17\100\1\161\2\100" u"\2\161\3\100\1\uffff\26\100\1\173\15\100\1\136\2\100\2\136\1\100" u"\1\155\1\uffff\1\155\17\100\1\161\1\100\2\161\2\77\1\uffff\26\100" u"\1\173\10\100\1\136\1\100\2\136\23\100\1\161\2\77\25\100\1\173" u"\4\100\1\136\2\100\1\155\3\100\2\155\3\100\1\155\1\100\1\155\6" u"\100\2\155\2\100\1\77\20\100\1\173\3\100\1\155\3\100\1\155\7\100" u"\2\155\2\100\1\77\11\100\1\173\2\100\1\155\5\100\1\77\7\100\1\155" u"\2\100\1\77\1\100\1\155\1\77" ) DFA231_eof = DFA.unpack( u"\u035c\uffff" ) DFA231_min = DFA.unpack( u"\1\11\1\52\1\uffff\1\55\4\uffff\1\75\14\uffff\1\60\1\uffff\1\11" u"\1\0\1\50\1\11\2\50\1\uffff\1\55\10\uffff\1\0\3\uffff\1\11\2\uffff" u"\1\50\2\11\2\50\1\0\1\uffff\5\50\3\11\1\0\1\150\2\uffff\2\11\1" u"\0\10\11\1\uffff\2\11\1\0\1\50\1\11\2\50\11\11\1\141\1\uffff\1" u"\11\1\0\1\11\3\105\1\60\1\66\1\60\1\105\2\115\2\101\1\uffff\1\11" u"\1\0\1\11\1\uffff\1\11\1\0\3\11\1\0\2\11\1\0\1\uffff\1\11\1\50" u"\1\11\1\50\16\11\1\162\1\11\1\0\1\11\1\60\1\65\1\60\1\66\1\60\2" u"\105\1\115\1\117\2\105\1\101\1\11\1\0\1\11\2\116\1\60\1\106\1\11" u"\1\0\1\11\1\60\1\61\1\11\1\0\1\11\1\60\1\65\1\11\1\0\1\11\1\120" u"\1\60\1\120\1\104\20\11\1\163\2\11\1\0\1\60\1\64\1\60\1\65\1\104" u"\2\60\1\66\1\115\1\117\4\105\1\101\10\11\1\0\1\124\1\60\1\124\1" u"\105\1\60\1\106\2\116\2\55\1\0\1\105\1\60\1\105\1\67\1\60\1\61" u"\1\107\1\11\1\0\1\11\1\106\1\60\1\106\1\71\1\60\1\65\1\131\1\11" u"\1\0\1\11\1\117\1\60\1\117\2\60\1\104\2\120\17\11\1\145\2\55\1" u"\0\1\101\1\60\1\101\1\71\1\60\1\64\1\111\1\60\1\65\1\104\2\11\1" u"\64\1\66\1\60\1\101\1\115\2\105\1\117\2\105\13\11\1\106\1\55\1" u"\60\1\55\1\64\1\60\1\105\2\124\1\60\1\106\2\116\1\60\1\65\1\60" u"\1\67\1\105\1\60\1\61\1\107\1\11\1\0\1\11\1\60\1\66\1\60\1\71\1" u"\106\1\60\1\65\1\131\2\11\1\0\1\122\1\60\1\122\1\106\2\60\1\117" u"\1\60\1\104\2\120\15\11\1\164\1\60\1\61\1\60\1\71\1\101\1\60\1" u"\64\1\111\1\64\1\65\1\104\3\11\1\66\1\60\2\105\1\115\1\117\2\105" u"\1\101\13\11\1\0\1\60\1\64\1\55\1\60\1\105\2\124\1\64\1\106\2\116" u"\1\60\1\65\1\11\1\60\1\67\1\105\2\11\1\64\1\61\1\107\1\11\1\0\1" u"\11\1\101\1\60\1\101\1\62\1\60\1\66\1\122\1\60\1\71\1\106\2\11" u"\1\64\1\65\1\131\1\55\1\0\1\55\1\124\1\60\1\124\1\62\1\60\1\106" u"\2\122\2\60\1\117\1\64\1\104\2\120\7\11\1\55\1\60\1\61\1\11\1\60" u"\1\71\1\101\2\11\2\64\1\111\1\65\1\104\2\11\1\117\2\105\1\115\2" u"\105\1\101\11\11\1\0\1\11\1\60\1\66\1\60\1\64\1\55\1\64\1\105\2" u"\124\1\106\2\116\1\60\1\65\1\11\1\64\1\67\1\105\3\11\1\61\1\107" u"\1\11\1\0\1\11\1\60\1\61\1\60\1\62\1\101\1\60\1\66\1\122\1\65\1" u"\71\1\106\3\11\1\65\1\131\1\55\1\60\1\55\1\64\1\60\1\62\1\124\1" u"\60\1\106\2\122\1\65\1\60\1\117\1\104\2\120\2\11\1\uffff\1\60\1" u"\61\1\11\1\64\1\71\1\101\3\11\1\64\1\111\1\104\4\11\1\0\1\60\1" u"\61\1\60\1\66\1\101\1\65\1\64\1\55\1\105\2\124\2\116\1\64\1\65" u"\1\11\1\67\1\105\2\11\1\107\2\11\1\0\1\105\1\60\1\105\1\104\1\60" u"\1\61\1\115\1\60\1\62\1\101\2\11\1\64\1\66\1\122\1\71\1\106\2\11" u"\1\131\1\60\1\64\1\11\1\60\1\62\1\124\1\64\1\106\2\122\1\60\1\117" u"\2\120\1\64\1\61\1\11\1\71\1\101\2\11\1\111\1\55\1\0\1\55\1\60" u"\1\63\1\60\1\61\1\103\1\60\1\66\1\101\2\11\1\64\1\55\2\124\1\65" u"\1\11\1\105\2\11\2\55\1\0\1\60\1\65\1\60\1\104\2\105\1\60\1\61" u"\1\115\1\65\1\62\1\101\3\11\1\66\1\122\1\106\2\11\1\60\1\64\1\11" u"\1\65\1\62\1\124\1\106\2\122\1\117\1\61\1\11\1\101\2\11\1\60\1" u"\65\1\60\1\63\1\105\1\60\1\61\1\103\2\11\1\64\1\66\1\101\5\11\1" u"\55\1\11\2\55\1\60\1\63\1\60\1\65\1\123\1\60\1\104\2\105\2\11\1" u"\64\1\61\1\115\1\62\1\101\2\11\1\122\1\65\1\64\1\11\1\62\1\124" u"\2\122\1\11\1\60\1\65\1\11\1\60\1\63\1\105\2\11\1\64\1\61\1\103" u"\3\11\1\66\1\101\6\11\1\60\1\63\1\11\1\60\1\65\1\123\1\64\1\104" u"\2\105\3\11\1\61\1\115\1\101\2\11\1\64\1\11\1\124\1\60\1\65\1\11" u"\1\64\1\63\1\105\1\11\1\61\1\103\1\101\6\11\1\60\1\63\1\11\1\64" u"\1\65\1\123\1\104\2\105\2\11\1\115\1\11\1\64\1\65\1\11\1\63\1\105" u"\1\103\1\65\1\63\1\11\1\65\1\123\2\105\2\11\1\65\1\11\1\105\1\63" u"\1\11\1\123\2\11" ) DFA231_max = DFA.unpack( u"\1\176\1\52\1\uffff\1\172\4\uffff\1\75\14\uffff\1\71\1\uffff\1" u"\172\1\uffff\4\172\1\uffff\1\172\10\uffff\1\uffff\3\uffff\1\162" u"\2\uffff\5\172\1\uffff\1\uffff\10\172\1\uffff\1\150\2\uffff\2\145" u"\1\uffff\2\157\2\141\2\145\2\155\1\uffff\2\172\1\uffff\15\172\1" u"\141\1\uffff\1\144\1\uffff\1\144\3\145\1\67\1\144\1\60\1\145\2" u"\155\2\141\1\uffff\1\156\1\uffff\1\156\1\uffff\1\147\1\uffff\1" u"\147\2\171\1\uffff\2\160\1\uffff\1\uffff\1\176\21\172\1\162\1\151" u"\1\uffff\1\151\1\66\1\65\1\67\1\144\1\60\2\145\1\155\1\157\2\145" u"\1\141\1\164\1\uffff\1\164\2\156\1\66\1\146\1\145\1\uffff\1\145" u"\1\66\1\61\1\146\1\uffff\1\146\1\66\1\65\1\157\1\uffff\1\157\1" u"\160\1\66\1\160\1\144\20\172\1\163\2\141\1\uffff\1\66\1\64\1\66" u"\1\65\1\144\1\67\1\60\1\144\1\155\1\157\4\145\1\141\2\144\2\171" u"\2\147\2\55\1\uffff\1\164\1\66\1\164\1\145\1\66\1\146\2\156\2\172" u"\1\uffff\1\145\1\66\1\145\1\67\1\66\1\61\1\147\1\162\1\uffff\1" u"\162\1\146\1\67\1\146\1\71\1\66\1\65\1\171\1\162\1\uffff\1\162" u"\1\157\1\67\1\157\1\60\1\66\1\144\2\160\17\172\1\145\2\172\1\uffff" u"\1\141\1\66\1\141\1\71\1\66\1\64\1\151\1\66\1\65\1\144\2\151\1" u"\67\1\144\1\60\1\141\1\155\2\145\1\157\2\145\2\171\2\144\2\147" u"\1\151\1\144\1\151\1\171\1\147\1\146\1\55\1\67\1\55\1\64\1\66\1" u"\145\2\164\1\66\1\146\2\156\1\66\1\65\1\66\1\67\1\145\1\66\1\61" u"\1\147\1\141\1\uffff\1\141\2\66\1\67\1\71\1\146\1\66\1\65\1\171" u"\2\164\1\uffff\1\162\1\66\1\162\1\146\1\67\1\60\1\157\1\66\1\144" u"\2\160\15\172\1\164\1\66\1\61\1\66\1\71\1\141\1\66\1\64\1\151\1" u"\66\1\65\1\144\3\151\1\144\1\60\2\145\1\155\1\157\2\145\1\141\2" u"\147\2\144\2\171\3\151\2\141\1\uffff\1\67\1\64\1\55\1\66\1\145" u"\2\164\1\66\1\146\2\156\1\66\1\65\1\172\1\66\1\67\1\145\2\172\1" u"\66\1\61\1\147\1\155\1\uffff\1\155\1\141\1\67\1\141\1\62\2\66\1" u"\162\1\67\1\71\1\146\2\162\1\66\1\65\1\171\1\172\1\uffff\1\172" u"\1\164\1\67\1\164\1\62\1\66\1\146\2\162\1\67\1\60\1\157\1\66\1" u"\144\2\160\10\172\1\66\1\61\1\172\1\66\1\71\1\141\2\172\1\66\1" u"\64\1\151\1\65\1\144\2\151\1\157\2\145\1\155\2\145\1\141\2\171" u"\2\144\2\147\2\151\1\143\1\uffff\1\143\2\66\1\67\1\64\1\55\1\66" u"\1\145\2\164\1\146\2\156\1\66\1\65\1\172\1\66\1\67\1\145\3\172" u"\1\61\1\147\1\145\1\uffff\1\145\1\66\1\61\1\67\1\62\1\141\2\66" u"\1\162\1\67\1\71\1\146\3\162\1\65\1\171\1\172\1\67\1\172\1\64\1" u"\67\1\62\1\164\1\66\1\146\2\162\1\67\1\60\1\157\1\144\2\160\2\172" u"\1\uffff\1\66\1\61\1\172\1\66\1\71\1\141\3\172\1\64\1\151\1\144" u"\2\151\2\145\1\uffff\1\66\1\61\2\66\1\141\1\67\1\64\1\55\1\145" u"\2\164\2\156\1\66\1\65\1\172\1\67\1\145\2\172\1\147\2\163\1\uffff" u"\1\145\1\66\1\145\1\144\1\66\1\61\1\155\1\67\1\62\1\141\2\155\2" u"\66\1\162\1\71\1\146\2\162\1\171\1\67\1\64\1\172\1\67\1\62\1\164" u"\1\66\1\146\2\162\1\60\1\157\2\160\1\66\1\61\1\172\1\71\1\141\2" u"\172\1\151\1\172\1\uffff\1\172\1\66\1\63\1\66\1\61\1\143\2\66\1" u"\141\2\143\1\64\1\55\2\164\1\65\1\172\1\145\4\172\1\uffff\1\66" u"\1\65\1\66\1\144\2\145\1\66\1\61\1\155\1\67\1\62\1\141\3\155\1" u"\66\1\162\1\146\2\162\1\67\1\64\1\172\1\67\1\62\1\164\1\146\2\162" u"\1\157\1\61\1\172\1\141\2\172\1\66\1\65\1\66\1\63\1\145\1\66\1" u"\61\1\143\2\145\2\66\1\141\2\143\1\145\1\143\1\145\1\55\3\172\1" u"\67\1\63\1\66\1\65\1\163\1\66\1\144\2\145\2\163\1\66\1\61\1\155" u"\1\62\1\141\2\155\1\162\1\67\1\64\1\172\1\62\1\164\2\162\1\172" u"\1\66\1\65\1\172\1\66\1\63\1\145\2\172\1\66\1\61\1\143\1\172\1" u"\145\1\172\1\66\1\141\2\143\2\145\2\172\1\67\1\63\1\172\1\66\1" u"\65\1\163\1\66\1\144\2\145\3\163\1\61\1\155\1\141\2\155\1\64\1" u"\172\1\164\1\66\1\65\1\172\1\66\1\63\1\145\1\172\1\61\1\143\1\141" u"\2\143\2\145\2\172\1\67\1\63\1\172\1\66\1\65\1\163\1\144\2\145" u"\2\163\1\155\1\172\1\66\1\65\1\172\1\63\1\145\1\143\1\67\1\63\1" u"\172\1\65\1\163\2\145\2\163\1\65\1\172\1\145\1\63\1\172\1\163\2" u"\172" ) DFA231_accept = DFA.unpack( u"\2\uffff\1\2\1\uffff\1\4\1\5\1\6\1\7\1\uffff\1\11\1\12\1\13\1\14" u"\1\15\1\16\1\17\1\20\1\23\1\25\1\26\1\27\1\uffff\1\31\6\uffff\1" u"\35\1\uffff\1\45\1\46\1\50\1\51\1\1\1\21\1\3\1\22\1\uffff\1\10" u"\1\24\1\30\1\uffff\1\33\1\32\6\uffff\1\34\12\uffff\1\43\1\44\13" u"\uffff\1\47\21\uffff\1\40\16\uffff\1\41\3\uffff\1\37\11\uffff\1" u"\36\u01c0\uffff\1\42\u011f\uffff" ) DFA231_special = DFA.unpack( u"\30\uffff\1\27\16\uffff\1\3\13\uffff\1\0\11\uffff\1\2\5\uffff\1" u"\4\13\uffff\1\10\20\uffff\1\34\16\uffff\1\12\3\uffff\1\15\3\uffff" u"\1\30\2\uffff\1\40\25\uffff\1\24\16\uffff\1\26\6\uffff\1\11\4\uffff" u"\1\1\4\uffff\1\7\30\uffff\1\35\27\uffff\1\6\12\uffff\1\33\10\uffff" u"\1\37\11\uffff\1\14\33\uffff\1\16\67\uffff\1\25\13\uffff\1\23\73" u"\uffff\1\36\27\uffff\1\20\21\uffff\1\5\67\uffff\1\17\31\uffff\1" u"\21\65\uffff\1\22\27\uffff\1\31\53\uffff\1\32\26\uffff\1\13\u00b3" u"\uffff" ) DFA231_transition = [ DFA.unpack(u"\1\41\1\42\2\uffff\1\42\22\uffff\1\41\1\37\1\26\1\35" u"\1\7\2\uffff\1\26\1\22\1\23\1\10\1\21\1\24\1\3\1\25\1\1\12\40\1" u"\20\1\17\1\2\1\16\1\11\1\uffff\1\36\24\34\1\32\5\34\1\14\1\30\1" u"\15\1\6\1\31\1\uffff\24\33\1\27\5\33\1\12\1\5\1\13\1\4"), DFA.unpack(u"\1\43"), DFA.unpack(u""), DFA.unpack(u"\1\45\23\uffff\32\34\1\uffff\1\47\2\uffff\1\31\1\uffff" u"\32\33"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\50"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\40"), DFA.unpack(u""), DFA.unpack(u"\2\53\1\uffff\2\53\22\uffff\1\53\7\uffff\1\64\2\uffff" u"\1\55\1\uffff\1\62\2\uffff\12\61\7\uffff\21\66\1\60\10\66\1\uffff" u"\1\63\2\uffff\1\56\1\uffff\21\65\1\57\10\65"), DFA.unpack(u"\12\71\1\uffff\1\71\2\uffff\42\71\1\72\4\74\1\73\1" u"\74\1\73\2\74\7\71\6\74\16\71\1\70\13\71\6\74\16\71\1\67\uff8a" u"\71"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\2\53\1\uffff\2\53\22\uffff\1\53\7\uffff\1\64\2\uffff" u"\1\55\1\uffff\1\62\2\uffff\12\61\7\uffff\21\66\1\60\10\66\1\uffff" u"\1\63\2\uffff\1\56\1\uffff\21\65\1\57\10\65"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u""), DFA.unpack(u"\1\77\22\uffff\6\100\1\105\2\100\1\113\1\100\1\111" u"\1\100\1\102\2\100\1\107\12\100\1\uffff\1\103\2\uffff\1\100\1\uffff" u"\2\100\1\76\2\100\1\104\2\100\1\112\1\100\1\110\1\100\1\101\2\100" u"\1\106\12\100"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\71\1\uffff\1\71\2\uffff\42\71\12\74\7\71\6\74\32" u"\71\6\74\uff99\71"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\2\53\1\uffff\2\53\22\uffff\1\53\12\uffff\1\55\46\uffff" u"\1\114\11\uffff\1\114\25\uffff\1\114"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\2\114\1\uffff\2\114\22\uffff\1\114\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\61\7\uffff\13\66\1\116\16\66\1\uffff\1\117" u"\2\uffff\1\56\1\uffff\13\65\1\115\16\65"), DFA.unpack(u"\2\114\1\uffff\2\114\22\uffff\1\114\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\61\7\uffff\13\66\1\116\16\66\1\uffff\1\117" u"\2\uffff\1\56\1\uffff\13\65\1\115\16\65"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\12\123\1\uffff\1\123\2\uffff\42\123\1\121\4\125\1" u"\124\1\125\1\124\2\125\7\123\6\125\13\123\1\122\16\123\6\125\13" u"\123\1\120\uff8d\123"), DFA.unpack(u""), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\1\64\2\uffff\1\55\1\uffff\1\62\2\uffff\12\61\7\uffff" u"\21\66\1\60\10\66\1\uffff\1\63\2\uffff\1\56\1\uffff\21\65\1\57" u"\10\65"), DFA.unpack(u"\1\64\2\uffff\1\55\1\uffff\1\62\2\uffff\12\61\7\uffff" u"\21\66\1\60\10\66\1\uffff\1\63\2\uffff\1\56\1\uffff\21\65\1\57" u"\10\65"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\1\126\4\133\1\127\1\133\1\127\2\133\7\uffff" u"\6\132\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\130\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\5\133\1\134\4\133\7\uffff\6\132\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\130\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\133\7\uffff\6\132\24\66\1\uffff\1\75\2\uffff" u"\1\56\1\uffff\6\130\24\65"), DFA.unpack(u"\12\123\1\uffff\1\123\2\uffff\42\123\12\125\7\123\6" u"\125\32\123\6\125\uff99\123"), DFA.unpack(u"\1\135"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\2\136\1\uffff\2\136\22\uffff\1\136\44\uffff\1\141" u"\26\uffff\1\140\10\uffff\1\137"), DFA.unpack(u"\2\136\1\uffff\2\136\22\uffff\1\136\44\uffff\1\141" u"\26\uffff\1\140\10\uffff\1\137"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\145\3\100\1" u"\146\1\147\1\146\1\147\21\100\1\152\1\100\1\150\1\100\1\143\2\100" u"\1\154\30\100\1\151\1\100\1\144\1\100\1\142\2\100\1\153\uff8f\100"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\56\uffff\1\160" u"\14\uffff\1\157\22\uffff\1\156"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\56\uffff\1\160" u"\14\uffff\1\157\22\uffff\1\156"), DFA.unpack(u"\2\161\1\uffff\2\161\22\uffff\1\161\40\uffff\1\164" u"\32\uffff\1\163\4\uffff\1\162"), DFA.unpack(u"\2\161\1\uffff\2\161\22\uffff\1\161\40\uffff\1\164" u"\32\uffff\1\163\4\uffff\1\162"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\44\uffff\1\166\26" u"\uffff\1\167\10\uffff\1\165"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\44\uffff\1\166\26" u"\uffff\1\167\10\uffff\1\165"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\54\uffff\1\171" u"\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\54\uffff\1\171" u"\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u""), DFA.unpack(u"\2\114\1\uffff\2\114\22\uffff\1\114\7\uffff\1\174\4" u"\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff\1" u"\56\1\uffff\32\65"), DFA.unpack(u"\2\114\1\uffff\2\114\22\uffff\1\114\7\uffff\1\174\4" u"\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff\1" u"\56\1\uffff\32\65"), DFA.unpack(u"\12\123\1\uffff\1\123\2\uffff\42\123\1\176\3\125\1" u"\u0080\1\125\1\u0080\3\125\7\123\6\125\5\123\1\177\24\123\6\125" u"\5\123\1\175\uff93\123"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\13\66\1\116" u"\16\66\1\uffff\1\117\2\uffff\1\56\1\uffff\13\65\1\115\16\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\1\u0084\4\u0086\1\u0085\1\u0086\1\u0085" u"\2\u0086\7\uffff\6\u0083\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff" u"\6\u0081\24\65"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\13\66\1\116" u"\16\66\1\uffff\1\117\2\uffff\1\56\1\uffff\13\65\1\115\16\65"), DFA.unpack(u"\1\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\2\u0086\1\u0087\7\u0086\7\uffff\6\u0083" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u0081\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u0086\7\uffff\6\u0083\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u0081\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\1\u008a\4\u008c\1\u008b\1\u008c\1\u008b\2\u008c" u"\7\uffff\6\u0089\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u0088" u"\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\5\u008c\1\u008d\4\u008c\7\uffff\6\u0089\24" u"\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u0088\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u008c\7\uffff\6\u0089\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0088\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff\1" u"\56\1\uffff\32\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u008c\7\uffff\6\u0089\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0088\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u008c\7\uffff\6\u0089\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0088\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\2" u"\uffff\1\55\1\uffff\1\62\2\uffff\12\u008c\7\uffff\6\u0089\13\66" u"\1\60\10\66\1\uffff\1\63\2\uffff\1\56\1\uffff\6\u0088\13\65\1\57" u"\10\65"), DFA.unpack(u"\1\u008e"), DFA.unpack(u""), DFA.unpack(u"\2\136\1\uffff\2\136\22\uffff\1\136\43\uffff\1\u0091" u"\27\uffff\1\u0090\7\uffff\1\u008f"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u0092\3\100" u"\1\u0093\1\100\1\u0093\uffc9\100"), DFA.unpack(u"\2\136\1\uffff\2\136\22\uffff\1\136\43\uffff\1\u0091" u"\27\uffff\1\u0090\7\uffff\1\u008f"), DFA.unpack(u"\1\141\26\uffff\1\140\10\uffff\1\137"), DFA.unpack(u"\1\141\26\uffff\1\140\10\uffff\1\137"), DFA.unpack(u"\1\166\26\uffff\1\167\10\uffff\1\165"), DFA.unpack(u"\1\u0094\3\uffff\1\u0095\1\u0096\1\u0095\1\u0096"), DFA.unpack(u"\1\u009a\2\uffff\1\u0099\10\uffff\1\u009c\1\uffff\1" u"\u009b\35\uffff\1\u0098\1\uffff\1\u0097"), DFA.unpack(u"\1\u009d"), DFA.unpack(u"\1\166\26\uffff\1\167\10\uffff\1\165"), DFA.unpack(u"\1\171\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u"\1\171\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u"\1\164\32\uffff\1\163\4\uffff\1\162"), DFA.unpack(u"\1\164\32\uffff\1\163\4\uffff\1\162"), DFA.unpack(u""), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\55\uffff\1\u00a0" u"\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u00a3\3\100" u"\1\u00a4\1\100\1\u00a4\30\100\1\u00a2\37\100\1\u00a1\uff90\100"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\55\uffff\1\u00a0" u"\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u""), DFA.unpack(u"\2\161\1\uffff\2\161\22\uffff\1\161\46\uffff\1\u00a7" u"\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u00a8\3\100" u"\1\u00a9\1\100\1\u00a9\uffc9\100"), DFA.unpack(u"\2\161\1\uffff\2\161\22\uffff\1\161\46\uffff\1\u00a7" u"\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\70\uffff\1\u00ac\2" u"\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\70\uffff\1\u00ac\2" u"\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u00ad\3\100" u"\1\u00ae\1\100\1\u00ae\uffc9\100"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\57\uffff\1\u00b1" u"\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\57\uffff\1\u00b1" u"\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u00b3\3\100" u"\1\u00b5\1\100\1\u00b5\26\100\1\u00b4\37\100\1\u00b2\uff92\100"), DFA.unpack(u""), DFA.unpack(u"\2\114\1\uffff\2\114\22\uffff\10\114\1\uffff\23\114" u"\1\uffff\1\114\1\uffff\1\114\1\uffff\33\114\3\uffff\1\114\1\uffff" u"\32\114\3\uffff\1\114"), DFA.unpack(u"\1\174\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\1\u00b6\3\u0086\1\u00b7\1\u0086\1\u00b7" u"\3\u0086\7\uffff\6\u0083\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff" u"\6\u0081\24\65"), DFA.unpack(u"\1\174\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\32\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u0086\7\uffff\2\u0083\1\u00b9\3\u0083" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\2\u0081\1\u00b8\3\u0081" u"\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u00bc\7\uffff\6\u00bb\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u00ba\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff" u"\1\56\1\uffff\32\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u00bc\7\uffff\6\u00bb\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u00ba\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\1\u00bd\4\u00bc\1\u00be\1\u00bc\1\u00be" u"\2\u00bc\7\uffff\6\u00bb\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff" u"\6\u00ba\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\2\u00bc\1\u00bf\7\u00bc\7\uffff\6\u00bb" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u00ba\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u00bc\7\uffff\6\u00bb\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u00ba\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u00bc\7\uffff\6\u00bb\5\66\1\116\16" u"\66\1\uffff\1\117\2\uffff\1\56\1\uffff\6\u00ba\5\65\1\115\16\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u00c2\7\uffff\6\u00c1\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u00c0\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u00c2\7\uffff\6\u00c1\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u00c0\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\1\u00c3\4\u00c2\1\u00c4\1\u00c2\1\u00c4\2\u00c2" u"\7\uffff\6\u00c1\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u00c0" u"\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\5\u00c2\1\u00c5\4\u00c2\7\uffff\6\u00c1\24" u"\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u00c0\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u00c2\7\uffff\6\u00c1\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u00c0\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\2" u"\uffff\1\55\1\uffff\1\62\2\uffff\12\u00c2\7\uffff\6\u00c1\13\66" u"\1\60\10\66\1\uffff\1\63\2\uffff\1\56\1\uffff\6\u00c0\13\65\1\57" u"\10\65"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u"\2\136\1\uffff\2\136\22\uffff\1\136\50\uffff\1\u00c8" u"\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u00ca\3\100" u"\1\u00cb\1\100\1\u00cb\uffc9\100"), DFA.unpack(u"\2\136\1\uffff\2\136\22\uffff\1\136\50\uffff\1\u00c8" u"\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\u00cc\3\uffff\1\u00cd\1\uffff\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u"\1\u00cf\3\uffff\1\u00d1\1\u00d0\1\u00d1\1\u00d0"), DFA.unpack(u"\1\u00d3\2\uffff\1\u00d2\10\uffff\1\u00d6\1\uffff\1" u"\u00d7\35\uffff\1\u00d4\1\uffff\1\u00d5"), DFA.unpack(u"\1\u00d8"), DFA.unpack(u"\1\u00da\26\uffff\1\140\10\uffff\1\u00d9"), DFA.unpack(u"\1\u00dc\26\uffff\1\167\10\uffff\1\u00db"), DFA.unpack(u"\1\171\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u"\1\160\14\uffff\1\157\22\uffff\1\156"), DFA.unpack(u"\1\u00da\26\uffff\1\140\10\uffff\1\u00d9"), DFA.unpack(u"\1\u00dc\26\uffff\1\167\10\uffff\1\u00db"), DFA.unpack(u"\1\u00de\32\uffff\1\163\4\uffff\1\u00dd"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\63\uffff\1\u00e0" u"\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u00e3\3\100" u"\1\u00e5\1\100\1\u00e5\27\100\1\u00e4\37\100\1\u00e2\uff91\100"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\63\uffff\1\u00e0" u"\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u00e6\3\uffff\1\u00e7\1\uffff\1\u00e7"), DFA.unpack(u"\1\u00e9\37\uffff\1\u00e8"), DFA.unpack(u"\2\161\1\uffff\2\161\22\uffff\1\161\44\uffff\1\u00eb" u"\26\uffff\1\u00ec\10\uffff\1\u00ea"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u00ee\3\100" u"\1\u00f0\1\100\1\u00f0\20\100\1\u00ef\37\100\1\u00ed\uff98\100"), DFA.unpack(u"\2\161\1\uffff\2\161\22\uffff\1\161\44\uffff\1\u00eb" u"\26\uffff\1\u00ec\10\uffff\1\u00ea"), DFA.unpack(u"\1\u00f1\3\uffff\1\u00f2\1\uffff\1\u00f2"), DFA.unpack(u"\1\u00f3"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\45\uffff\1\u00f6\25" u"\uffff\1\u00f5\11\uffff\1\u00f4"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u00f8\4\100" u"\1\u00fa\1\100\1\u00fa\41\100\1\u00f9\37\100\1\u00f7\uff86\100"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\45\uffff\1\u00f6\25" u"\uffff\1\u00f5\11\uffff\1\u00f4"), DFA.unpack(u"\1\u00fb\3\uffff\1\u00fc\1\uffff\1\u00fc"), DFA.unpack(u"\1\u00fd"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\56\uffff\1\u0100" u"\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u0102\4\100" u"\1\u0104\1\100\1\u0104\30\100\1\u0103\37\100\1\u0101\uff8f\100"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\56\uffff\1\u0100" u"\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\1\u0105\3\uffff\1\u0106\1\uffff\1\u0106"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\1\u0108\37\uffff\1\u0107"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\1\u0109\3\u00bc\1\u010a\1\u00bc\1\u010a" u"\3\u00bc\7\uffff\6\u00bb\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff" u"\6\u00ba\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u00bc\7\uffff\2\u00bb\1\u010c\3\u00bb" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\2\u00ba\1\u010b\3\u00ba" u"\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\u00bc\7\uffff\6\u00bb\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u00ba\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\u00bc\7\uffff\6\u00bb\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u00ba\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u010f\7\uffff\6\u010e\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u010d\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u010f\7\uffff\6\u010e\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u010d\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u010f\7\uffff\6\u010e\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u010d\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\1\u0110\4\u010f\1\u0111\1\u010f\1\u0111" u"\2\u010f\7\uffff\6\u010e\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff" u"\6\u010d\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\2\u010f\1\u0112\7\u010f\7\uffff\6\u010e" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u010d\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u010f\7\uffff\6\u010e\5\66\1\116\16" u"\66\1\uffff\1\117\2\uffff\1\56\1\uffff\6\u010d\5\65\1\115\16\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u0115\7\uffff\6\u0114\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0113\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u0115\7\uffff\6\u0114\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0113\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u0115\7\uffff\6\u0114\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0113\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\5\u0115\1\u0116\1\u0115\1\u0116\2\u0115\7\uffff" u"\6\u0114\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u0113\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\5\u0115\1\u0117\4\u0115\7\uffff\6\u0114\24" u"\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u0113\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\2" u"\uffff\1\55\1\uffff\1\62\2\uffff\12\u0115\7\uffff\6\u0114\13\66" u"\1\60\10\66\1\uffff\1\63\2\uffff\1\56\1\uffff\6\u0113\13\65\1\57" u"\10\65"), DFA.unpack(u"\1\u0118"), DFA.unpack(u"\2\136\1\uffff\2\136\22\uffff\1\136\40\uffff\1\u011a" u"\32\uffff\1\u011b\4\uffff\1\u0119"), DFA.unpack(u"\2\136\1\uffff\2\136\22\uffff\1\136\40\uffff\1\u011a" u"\32\uffff\1\u011b\4\uffff\1\u0119"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u011d\3\100" u"\1\u011f\1\100\1\u011f\22\100\1\u011e\37\100\1\u011c\uff96\100"), DFA.unpack(u"\1\u0120\3\uffff\1\u0121\1\uffff\1\u0121"), DFA.unpack(u"\1\u0122"), DFA.unpack(u"\1\u0123\3\uffff\1\u0124\1\uffff\1\u0124"), DFA.unpack(u"\1\u0125"), DFA.unpack(u"\1\u0127\27\uffff\1\u0090\7\uffff\1\u0126"), DFA.unpack(u"\1\u0128\3\uffff\1\u0129\1\u012a\1\u0129\1\u012a"), DFA.unpack(u"\1\u012b"), DFA.unpack(u"\1\u012f\2\uffff\1\u012c\10\uffff\1\u0131\1\uffff\1" u"\u0130\35\uffff\1\u012e\1\uffff\1\u012d"), DFA.unpack(u"\1\171\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u"\1\160\14\uffff\1\157\22\uffff\1\156"), DFA.unpack(u"\1\u0133\26\uffff\1\167\10\uffff\1\u0132"), DFA.unpack(u"\1\u0135\26\uffff\1\140\10\uffff\1\u0134"), DFA.unpack(u"\1\u0133\26\uffff\1\167\10\uffff\1\u0132"), DFA.unpack(u"\1\u0135\26\uffff\1\140\10\uffff\1\u0134"), DFA.unpack(u"\1\u0137\32\uffff\1\163\4\uffff\1\u0136"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u013a\27\uffff\1\u0090\7\uffff\1\u0138"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u013a\27\uffff\1\u0090\7\uffff\1\u0138"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\14\uffff\1\u013d"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\14\uffff\1\u013d"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u013f\4\100" u"\1\u0141\1\100\1\u0141\34\100\1\u0140\37\100\1\u013e\uff8b\100"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u0142\3\uffff\1\u0143\1\uffff\1\u0143"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u0145\37\uffff\1\u0144"), DFA.unpack(u"\1\u0146\3\uffff\1\u0147\1\uffff\1\u0147"), DFA.unpack(u"\1\u0149\37\uffff\1\u0148"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u014a\3\100" u"\1\u014b\1\100\1\u014b\uffc9\100"), DFA.unpack(u"\1\u00eb\26\uffff\1\u00ec\10\uffff\1\u00ea"), DFA.unpack(u"\1\u014c\3\uffff\1\u014d\1\uffff\1\u014d"), DFA.unpack(u"\1\u00eb\26\uffff\1\u00ec\10\uffff\1\u00ea"), DFA.unpack(u"\1\u014e"), DFA.unpack(u"\1\u014f\3\uffff\1\u0150\1\uffff\1\u0150"), DFA.unpack(u"\1\u0151"), DFA.unpack(u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\61\uffff\1\u0154\11" u"\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u0155\3\100" u"\1\u0156\1\100\1\u0156\uffc9\100"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\61\uffff\1\u0154\11" u"\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u00f6\25\uffff\1\u00f5\11\uffff\1\u00f4"), DFA.unpack(u"\1\u0157\4\uffff\1\u0158\1\uffff\1\u0158"), DFA.unpack(u"\1\u00f6\25\uffff\1\u00f5\11\uffff\1\u00f4"), DFA.unpack(u"\1\u0159"), DFA.unpack(u"\1\u015a\3\uffff\1\u015b\1\uffff\1\u015b"), DFA.unpack(u"\1\u015c"), DFA.unpack(u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\61\uffff\1\u015e" u"\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u0161\3\100" u"\1\u0163\1\100\1\u0163\30\100\1\u0162\37\100\1\u0160\uff90\100"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\61\uffff\1\u015e" u"\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u0100\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\1\u0164\4\uffff\1\u0165\1\uffff\1\u0165"), DFA.unpack(u"\1\u0100\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\1\u0166"), DFA.unpack(u"\1\u0167\3\uffff\1\u0168\1\uffff\1\u0168"), DFA.unpack(u"\1\u016a\37\uffff\1\u0169"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\1\u016b\3\u010f\1\u016c\1\u010f\1\u016c" u"\3\u010f\7\uffff\6\u010e\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff" u"\6\u010d\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u010f\7\uffff\2\u010e\1\u016e\3\u010e" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\2\u010d\1\u016d\3\u010d" u"\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\u010f\7\uffff\6\u010e\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u010d\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\u010f\7\uffff\6\u010e\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u010d\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u0171\7\uffff\6\u0170\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u016f\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u0171\7\uffff\6\u0170\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u016f\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u0171\7\uffff\6\u0170\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u016f\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\5\u0171\1\u0172\1\u0171\1\u0172\2\u0171" u"\7\uffff\6\u0170\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u016f" u"\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\2\u0171\1\u0173\7\u0171\7\uffff\6\u0170" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u016f\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u0171\7\uffff\6\u0170\5\66\1\116\16" u"\66\1\uffff\1\117\2\uffff\1\56\1\uffff\6\u016f\5\65\1\115\16\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u0176\7\uffff\6\u0175\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0174\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u0176\7\uffff\6\u0175\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0174\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\u0176\7\uffff\6\u0175\24\66\1\uffff\1\75" u"\2\uffff\1\56\1\uffff\6\u0174\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\5\u0176\1\u0177\4\u0176\7\uffff\6\u0175\24" u"\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u0174\24\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\2" u"\uffff\1\55\1\uffff\1\62\2\uffff\12\u0176\7\uffff\6\u0175\13\66" u"\1\60\10\66\1\uffff\1\63\2\uffff\1\56\1\uffff\6\u0174\13\65\1\57" u"\10\65"), DFA.unpack(u"\1\u0178"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u0179\3\100" u"\1\u017a\1\100\1\u017a\uffc9\100"), DFA.unpack(u"\1\u011a\32\uffff\1\u011b\4\uffff\1\u0119"), DFA.unpack(u"\1\u017b\3\uffff\1\u017c\1\uffff\1\u017c"), DFA.unpack(u"\1\u011a\32\uffff\1\u011b\4\uffff\1\u0119"), DFA.unpack(u"\1\u017d"), DFA.unpack(u"\1\u017e\3\uffff\1\u017f\1\uffff\1\u017f"), DFA.unpack(u"\1\u0180"), DFA.unpack(u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\u0181\3\uffff\1\u0182\1\uffff\1\u0182"), DFA.unpack(u"\1\u0183"), DFA.unpack(u"\1\u0185\27\uffff\1\u0090\7\uffff\1\u0184"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\u0187\1\u0188\1\u0187\1\u0188"), DFA.unpack(u"\1\u018c\2\uffff\1\u018b\10\uffff\1\u018d\1\uffff\1" u"\u018e\35\uffff\1\u0189\1\uffff\1\u018a"), DFA.unpack(u"\1\u018f"), DFA.unpack(u"\1\u0191\32\uffff\1\163\4\uffff\1\u0190"), DFA.unpack(u"\1\171\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u"\1\u0193\26\uffff\1\140\10\uffff\1\u0192"), DFA.unpack(u"\1\u0195\26\uffff\1\167\10\uffff\1\u0194"), DFA.unpack(u"\1\160\14\uffff\1\157\22\uffff\1\156"), DFA.unpack(u"\1\u0193\26\uffff\1\140\10\uffff\1\u0192"), DFA.unpack(u"\1\u0195\26\uffff\1\167\10\uffff\1\u0194"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u0197\27\uffff\1\u0090\7\uffff\1\u0196"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u0197\27\uffff\1\u0090\7\uffff\1\u0196"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\u0198\1\uffff\2\u0198\22\uffff\1\u0198\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u0091\27\uffff\1\u0090\7\uffff\1\u008f"), DFA.unpack(u"\2\u0198\1\uffff\2\u0198\22\uffff\1\u0198\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\1\u019a\25\uffff\1\u019b\11\uffff\1\u0199"), DFA.unpack(u"\1\u013d"), DFA.unpack(u"\1\u019c\4\uffff\1\u019d\1\uffff\1\u019d"), DFA.unpack(u"\1\u013d"), DFA.unpack(u"\1\u019e"), DFA.unpack(u"\1\u019f\3\uffff\1\u01a0\1\uffff\1\u01a0"), DFA.unpack(u"\1\u01a2\37\uffff\1\u01a1"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u01a3\3\uffff\1\u01a4\1\uffff\1\u01a4"), DFA.unpack(u"\1\u01a6\37\uffff\1\u01a5"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u01a7\3\uffff\1\u01a8\1\uffff\1\u01a8"), DFA.unpack(u"\1\u01a9"), DFA.unpack(u"\1\u01aa\3\uffff\1\u01ab\1\uffff\1\u01ab"), DFA.unpack(u"\1\u01ac"), DFA.unpack(u"\1\u01ae\26\uffff\1\u00ec\10\uffff\1\u01ad"), DFA.unpack(u"\1\u01af\3\uffff\1\u01b0\1\uffff\1\u01b0"), DFA.unpack(u"\1\u01b1"), DFA.unpack(u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\40\uffff\1\u01b4\32" u"\uffff\1\u01b3\4\uffff\1\u01b2"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u01b6\4\100" u"\1\u01b8\1\100\1\u01b8\32\100\1\u01b7\37\100\1\u01b5\uff8d\100"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\40\uffff\1\u01b4\32" u"\uffff\1\u01b3\4\uffff\1\u01b2"), DFA.unpack(u"\1\u01b9\3\uffff\1\u01ba\1\uffff\1\u01ba"), DFA.unpack(u"\1\u01bb"), DFA.unpack(u"\1\u01bc\4\uffff\1\u01bd\1\uffff\1\u01bd"), DFA.unpack(u"\1\u01be"), DFA.unpack(u"\1\u01c0\25\uffff\1\u00f5\11\uffff\1\u01bf"), DFA.unpack(u"\1\u01c1\3\uffff\1\u01c2\1\uffff\1\u01c2"), DFA.unpack(u"\1\u01c3"), DFA.unpack(u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\63\uffff\1\u01c6" u"\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\2\173\1\uffff\2\173\22\uffff\1\173\63\uffff\1\u01c6" u"\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u01c8\4\100" u"\1\u01ca\1\100\1\u01ca\32\100\1\u01c9\37\100\1\u01c7\uff8d\100"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u01cb\3\uffff\1\u01cc\1\uffff\1\u01cc"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u01ce\37\uffff\1\u01cd"), DFA.unpack(u"\1\u01cf\4\uffff\1\u01d0\1\uffff\1\u01d0"), DFA.unpack(u"\1\u01d1"), DFA.unpack(u"\1\u0100\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\1\u01d2\3\uffff\1\u01d3\1\uffff\1\u01d3"), DFA.unpack(u"\1\u01d5\37\uffff\1\u01d4"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\4\u0171\1\u01d6\1\u0171\1\u01d6\3\u0171" u"\7\uffff\6\u0170\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u016f" u"\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u0171\7\uffff\2\u0170\1\u01d8\3\u0170" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\2\u016f\1\u01d7\3\u016f" u"\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\u0171\7\uffff\6\u0170\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u016f\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\u0171\7\uffff\6\u0170\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u016f\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u01db\7\uffff\6\u01da\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u01d9\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u01db\7\uffff\6\u01da\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u01d9\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u01db\7\uffff\6\u01da\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u01d9\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\2\u01db\1\u01dc\7\u01db\7\uffff\6\u01da" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\6\u01d9\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u01db\7\uffff\6\u01da\5\66\1\116\16" u"\66\1\uffff\1\117\2\uffff\1\56\1\uffff\6\u01d9\5\65\1\115\16\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff\1" u"\56\1\uffff\32\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff\1" u"\56\1\uffff\32\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\4" u"\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff\1" u"\56\1\uffff\32\65"), DFA.unpack(u"\2\131\1\uffff\2\131\22\uffff\1\131\7\uffff\1\64\2" u"\uffff\1\55\1\uffff\1\62\2\uffff\12\61\7\uffff\21\66\1\60\10\66" u"\1\uffff\1\63\2\uffff\1\56\1\uffff\21\65\1\57\10\65"), DFA.unpack(u"\1\u01dd"), DFA.unpack(u"\1\u01de\3\uffff\1\u01df\1\uffff\1\u01df"), DFA.unpack(u"\1\u01e0"), DFA.unpack(u"\1\u01e1\3\uffff\1\u01e2\1\uffff\1\u01e2"), DFA.unpack(u"\1\u01e3"), DFA.unpack(u"\1\u01e5\32\uffff\1\u011b\4\uffff\1\u01e4"), DFA.unpack(u"\1\u01e6\3\uffff\1\u01e7\1\uffff\1\u01e7"), DFA.unpack(u"\1\u01e8"), DFA.unpack(u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\u01e9\1\uffff\1\u01e9"), DFA.unpack(u"\1\u01ea"), DFA.unpack(u"\1\u01ec\27\uffff\1\u0090\7\uffff\1\u01eb"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\u01ed\2\uffff\1\u01f0\10\uffff\1\u01f1\1\uffff\1" u"\u01f2\35\uffff\1\u01ee\1\uffff\1\u01ef"), DFA.unpack(u"\1\u01f3"), DFA.unpack(u"\1\u01f5\26\uffff\1\167\10\uffff\1\u01f4"), DFA.unpack(u"\1\u01f7\26\uffff\1\140\10\uffff\1\u01f6"), DFA.unpack(u"\1\171\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u"\1\160\14\uffff\1\157\22\uffff\1\156"), DFA.unpack(u"\1\u01f5\26\uffff\1\167\10\uffff\1\u01f4"), DFA.unpack(u"\1\u01f7\26\uffff\1\140\10\uffff\1\u01f6"), DFA.unpack(u"\1\u01f9\32\uffff\1\163\4\uffff\1\u01f8"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u01fb\27\uffff\1\u0090\7\uffff\1\u01fa"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u01fb\27\uffff\1\u0090\7\uffff\1\u01fa"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u0198\1\uffff\2\u0198\22\uffff\1\u0198\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0198\1\uffff\2\u0198\22\uffff\1\u0198\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0198\1\uffff\2\u0198\22\uffff\1\u0198\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\40\uffff\1\u01fe" u"\32\uffff\1\u01fd\4\uffff\1\u01fc"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\40\uffff\1\u01fe" u"\32\uffff\1\u01fd\4\uffff\1\u01fc"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u01ff\3\100" u"\1\u0200\1\100\1\u0200\uffc9\100"), DFA.unpack(u"\1\u0201\4\uffff\1\u0202\1\uffff\1\u0202"), DFA.unpack(u"\1\u0203"), DFA.unpack(u"\1\u013d"), DFA.unpack(u"\1\u0204\3\uffff\1\u0205\1\uffff\1\u0205"), DFA.unpack(u"\1\u0207\37\uffff\1\u0206"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u0208\1\uffff\1\u0208"), DFA.unpack(u"\1\u020a\37\uffff\1\u0209"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u020b\3\uffff\1\u020c\1\uffff\1\u020c"), DFA.unpack(u"\1\u020d"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u020e\3\uffff\1\u020f\1\uffff\1\u020f"), DFA.unpack(u"\1\u0210"), DFA.unpack(u"\1\u0212\26\uffff\1\u00ec\10\uffff\1\u0211"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u0214\1\uffff\1\u0214"), DFA.unpack(u"\1\u0215"), DFA.unpack(u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\54\uffff\1\u0218\16" u"\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u0219\3\100" u"\1\u021a\1\100\1\u021a\uffc9\100"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\54\uffff\1\u0218\16" u"\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u01b4\32\uffff\1\u01b3\4\uffff\1\u01b2"), DFA.unpack(u"\1\u021b\4\uffff\1\u021c\1\uffff\1\u021c"), DFA.unpack(u"\1\u01b4\32\uffff\1\u01b3\4\uffff\1\u01b2"), DFA.unpack(u"\1\u021d"), DFA.unpack(u"\1\u021e\3\uffff\1\u021f\1\uffff\1\u021f"), DFA.unpack(u"\1\u0220"), DFA.unpack(u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u0221\4\uffff\1\u0222\1\uffff\1\u0222"), DFA.unpack(u"\1\u0223"), DFA.unpack(u"\1\u0225\25\uffff\1\u00f5\11\uffff\1\u0224"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u0227\1\uffff\1\u0227"), DFA.unpack(u"\1\u0228"), DFA.unpack(u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u022a\4\100" u"\1\u022c\1\100\1\u022c\34\100\1\u022b\37\100\1\u0229\uff8b\100"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\u01c6\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\1\u022d\4\uffff\1\u022e\1\uffff\1\u022e"), DFA.unpack(u"\1\u01c6\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\1\u022f"), DFA.unpack(u"\1\u0230\3\uffff\1\u0231\1\uffff\1\u0231"), DFA.unpack(u"\1\u0233\37\uffff\1\u0232"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u0234\4\uffff\1\u0235\1\uffff\1\u0235"), DFA.unpack(u"\1\u0236"), DFA.unpack(u"\1\u0100\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\1\u0237\1\uffff\1\u0237"), DFA.unpack(u"\1\u0239\37\uffff\1\u0238"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\u01db\7\uffff\2\u01da\1\u023b\3\u01da" u"\24\66\1\uffff\1\75\2\uffff\1\56\1\uffff\2\u01d9\1\u023a\3\u01d9" u"\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\u01db\7\uffff\6\u01da\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u01d9\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\u01db\7\uffff\6\u01da\24\66\1\uffff" u"\1\75\2\uffff\1\56\1\uffff\6\u01d9\24\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff" u"\1\56\1\uffff\32\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff" u"\1\56\1\uffff\32\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff" u"\1\56\1\uffff\32\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\64\4\uffff\1\62\2\uffff\12\61\7\uffff\13\66\1\116\16\66\1\uffff" u"\1\117\2\uffff\1\56\1\uffff\13\65\1\115\16\65"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\u023d\3\uffff\1\u023e\1\uffff\1\u023e"), DFA.unpack(u"\1\u023f"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u0240\3\uffff\1\u0241\1\uffff\1\u0241"), DFA.unpack(u"\1\u0242"), DFA.unpack(u"\1\u0244\32\uffff\1\u011b\4\uffff\1\u0243"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u0246\1\uffff\1\u0246"), DFA.unpack(u"\1\u0247"), DFA.unpack(u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\u0248"), DFA.unpack(u"\1\u024a\27\uffff\1\u0090\7\uffff\1\u0249"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\160\14\uffff\1\157\22\uffff\1\156"), DFA.unpack(u"\1\166\26\uffff\1\167\10\uffff\1\165"), DFA.unpack(u"\1\141\26\uffff\1\140\10\uffff\1\137"), DFA.unpack(u"\1\171\16\uffff\1\172\20\uffff\1\170"), DFA.unpack(u"\1\166\26\uffff\1\167\10\uffff\1\165"), DFA.unpack(u"\1\141\26\uffff\1\140\10\uffff\1\137"), DFA.unpack(u"\1\164\32\uffff\1\163\4\uffff\1\162"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u013b\1\uffff\2\u013b\22\uffff\1\u013b\70\uffff" u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u0091\27\uffff\1\u0090\7\uffff\1\u008f"), DFA.unpack(u"\2\u0139\1\uffff\2\u0139\22\uffff\1\u0139\43\uffff" u"\1\u0091\27\uffff\1\u0090\7\uffff\1\u008f"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\u013c\1\uffff\2\u013c\22\uffff\1\u013c\46\uffff" u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\u0198\1\uffff\2\u0198\22\uffff\1\u0198\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0198\1\uffff\2\u0198\22\uffff\1\u0198\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\42\uffff\1\u024c" u"\30\uffff\1\u024d\6\uffff\1\u024b"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u024e\3\100" u"\1\u024f\1\100\1\u024f\uffc9\100"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\42\uffff\1\u024c" u"\30\uffff\1\u024d\6\uffff\1\u024b"), DFA.unpack(u"\1\u0250\3\uffff\1\u0251\1\uffff\1\u0251"), DFA.unpack(u"\1\u0252"), DFA.unpack(u"\1\u0253\4\uffff\1\u0254\1\uffff\1\u0254"), DFA.unpack(u"\1\u0255"), DFA.unpack(u"\1\u013d"), DFA.unpack(u"\1\u0256\1\uffff\1\u0256"), DFA.unpack(u"\1\u0258\37\uffff\1\u0257"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u025a\37\uffff\1\u0259"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u025b\3\uffff\1\u025c\1\uffff\1\u025c"), DFA.unpack(u"\1\u025d"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u025e\1\uffff\1\u025e"), DFA.unpack(u"\1\u025f"), DFA.unpack(u"\1\u0261\26\uffff\1\u00ec\10\uffff\1\u0260"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u0262"), DFA.unpack(u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\44\uffff\1\u0264\26" u"\uffff\1\u0265\10\uffff\1\u0263"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u0267\3\100" u"\1\u0269\1\100\1\u0269\26\100\1\u0268\37\100\1\u0266\uff92\100"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\44\uffff\1\u0264\26" u"\uffff\1\u0265\10\uffff\1\u0263"), DFA.unpack(u"\1\u026a\3\uffff\1\u026b\1\uffff\1\u026b"), DFA.unpack(u"\1\u026c"), DFA.unpack(u"\1\u026d\4\uffff\1\u026e\1\uffff\1\u026e"), DFA.unpack(u"\1\u026f"), DFA.unpack(u"\1\u0271\32\uffff\1\u01b3\4\uffff\1\u0270"), DFA.unpack(u"\1\u0272\3\uffff\1\u0273\1\uffff\1\u0273"), DFA.unpack(u"\1\u0274"), DFA.unpack(u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u0275\1\uffff\1\u0275"), DFA.unpack(u"\1\u0276"), DFA.unpack(u"\1\u0278\25\uffff\1\u00f5\11\uffff\1\u0277"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u0279"), DFA.unpack(u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\u027a\4\uffff\1\u027b\1\uffff\1\u027b"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\u027c"), DFA.unpack(u"\1\u027d\4\uffff\1\u027e\1\uffff\1\u027e"), DFA.unpack(u"\1\u027f"), DFA.unpack(u"\1\u01c6\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\1\u0280\3\uffff\1\u0281\1\uffff\1\u0281"), DFA.unpack(u"\1\u0283\37\uffff\1\u0282"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u0284\1\uffff\1\u0284"), DFA.unpack(u"\1\u0285"), DFA.unpack(u"\1\u0100\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\1\u0287\37\uffff\1\u0286"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff" u"\1\56\1\uffff\32\65"), DFA.unpack(u"\2\u0082\1\uffff\2\u0082\22\uffff\1\u0082\7\uffff\1" u"\174\4\uffff\1\62\2\uffff\12\61\7\uffff\32\66\1\uffff\1\75\2\uffff" u"\1\56\1\uffff\32\65"), DFA.unpack(u""), DFA.unpack(u"\1\u0288\3\uffff\1\u0289\1\uffff\1\u0289"), DFA.unpack(u"\1\u028a"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u028b\1\uffff\1\u028b"), DFA.unpack(u"\1\u028c"), DFA.unpack(u"\1\u028e\32\uffff\1\u011b\4\uffff\1\u028d"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u028f"), DFA.unpack(u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\u0091\27\uffff\1\u0090\7\uffff\1\u008f"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\u0186\1\uffff\2\u0186\22\uffff\1\u0186\50\uffff" u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\44\uffff\1\u0292" u"\26\uffff\1\u0291\10\uffff\1\u0290"), DFA.unpack(u"\2\155\1\uffff\2\155\22\uffff\1\155\44\uffff\1\u0292" u"\26\uffff\1\u0291\10\uffff\1\u0290"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u0293\3\100" u"\1\u0294\1\100\1\u0294\uffc9\100"), DFA.unpack(u"\1\u0295\3\uffff\1\u0296\1\uffff\1\u0296"), DFA.unpack(u"\1\u0297"), DFA.unpack(u"\1\u0298\3\uffff\1\u0299\1\uffff\1\u0299"), DFA.unpack(u"\1\u029a"), DFA.unpack(u"\1\u029c\32\uffff\1\u01fd\4\uffff\1\u029b"), DFA.unpack(u"\1\u029d\1\uffff\1\u029d"), DFA.unpack(u"\1\u029e"), DFA.unpack(u"\1\u013d"), DFA.unpack(u"\1\u02a0\37\uffff\1\u029f"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u00a0\15\uffff\1\u009f\21\uffff\1\u009e"), DFA.unpack(u"\1\u02a1\1\uffff\1\u02a1"), DFA.unpack(u"\1\u02a2"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u02a3"), DFA.unpack(u"\1\u02a5\26\uffff\1\u00ec\10\uffff\1\u02a4"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u00a7\24\uffff\1\u00a6\12\uffff\1\u00a5"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\62\uffff\1\u02a7\10" u"\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\2\77\1\uffff\2\77\22\uffff\1\77\62\uffff\1\u02a7\10" u"\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u02a9\3\100" u"\1\u02aa\1\100\1\u02aa\uffc9\100"), DFA.unpack(u"\1\u0264\26\uffff\1\u0265\10\uffff\1\u0263"), DFA.unpack(u"\1\u02ab\3\uffff\1\u02ac\1\uffff\1\u02ac"), DFA.unpack(u"\1\u0264\26\uffff\1\u0265\10\uffff\1\u0263"), DFA.unpack(u"\1\u02ae\37\uffff\1\u02ad"), DFA.unpack(u"\1\u02af\3\uffff\1\u02b0\1\uffff\1\u02b0"), DFA.unpack(u"\1\u02b1"), DFA.unpack(u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u02b2\4\uffff\1\u02b3\1\uffff\1\u02b3"), DFA.unpack(u"\1\u02b4"), DFA.unpack(u"\1\u02b6\32\uffff\1\u01b3\4\uffff\1\u02b5"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u02b8\1\uffff\1\u02b8"), DFA.unpack(u"\1\u02b9"), DFA.unpack(u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u02ba"), DFA.unpack(u"\1\u02bc\25\uffff\1\u00f5\11\uffff\1\u02bb"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u00ac\2\uffff\1\u00ab\34\uffff\1\u00aa"), DFA.unpack(u"\1\u02bd\4\uffff\1\u02be\1\uffff\1\u02be"), DFA.unpack(u"\1\u02bf"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u02c0\4\uffff\1\u02c1\1\uffff\1\u02c1"), DFA.unpack(u"\1\u02c2"), DFA.unpack(u"\1\u01c6\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\1\u02c3\1\uffff\1\u02c3"), DFA.unpack(u"\1\u02c5\37\uffff\1\u02c4"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u02c6"), DFA.unpack(u"\1\u0100\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\1\u00b1\13\uffff\1\u00b0\23\uffff\1\u00af"), DFA.unpack(u"\1\u02c7\1\uffff\1\u02c7"), DFA.unpack(u"\1\u02c8"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u02c9"), DFA.unpack(u"\1\u02cb\32\uffff\1\u011b\4\uffff\1\u02ca"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u00c8\22\uffff\1\u00c9\14\uffff\1\u00c7"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u02cc\3\100" u"\1\u02cd\1\100\1\u02cd\uffc9\100"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\u02ce\3\uffff\1\u02cf\1\uffff\1\u02cf"), DFA.unpack(u"\1\u02d0"), DFA.unpack(u"\1\u02d1\3\uffff\1\u02d2\1\uffff\1\u02d2"), DFA.unpack(u"\1\u02d3"), DFA.unpack(u"\1\u02d5\30\uffff\1\u024d\6\uffff\1\u02d4"), DFA.unpack(u"\1\u02d6\3\uffff\1\u02d7\1\uffff\1\u02d7"), DFA.unpack(u"\1\u02d8"), DFA.unpack(u"\1\u02da\32\uffff\1\u01fd\4\uffff\1\u02d9"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u02dd\30\uffff\1\u024d\6\uffff\1\u02db"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u02dd\30\uffff\1\u024d\6\uffff\1\u02db"), DFA.unpack(u"\1\u02de"), DFA.unpack(u"\1\u013d"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u00e0\7\uffff\1\u00e1\27\uffff\1\u00df"), DFA.unpack(u"\1\u02df"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u00eb\26\uffff\1\u00ec\10\uffff\1\u00ea"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0213\1\uffff\2\u0213\22\uffff\1\u0213\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\12\100\1\uffff\1\100\2\uffff\42\100\1\u02e2\4\100" u"\1\u02e3\1\100\1\u02e3\33\100\1\u02e1\37\100\1\u02e0\uff8c\100"), DFA.unpack(u"\1\u02e4\3\uffff\1\u02e5\1\uffff\1\u02e5"), DFA.unpack(u"\1\u02e6"), DFA.unpack(u"\1\u02e7\3\uffff\1\u02e8\1\uffff\1\u02e8"), DFA.unpack(u"\1\u02ea\37\uffff\1\u02e9"), DFA.unpack(u"\1\u02ec\26\uffff\1\u0265\10\uffff\1\u02eb"), DFA.unpack(u"\1\u02ec\26\uffff\1\u0265\10\uffff\1\u02eb"), DFA.unpack(u"\1\u02ed\3\uffff\1\u02ee\1\uffff\1\u02ee"), DFA.unpack(u"\1\u02ef"), DFA.unpack(u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u02f0\1\uffff\1\u02f0"), DFA.unpack(u"\1\u02f1"), DFA.unpack(u"\1\u02f3\32\uffff\1\u01b3\4\uffff\1\u02f2"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u02f4"), DFA.unpack(u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u00f6\25\uffff\1\u00f5\11\uffff\1\u00f4"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\2\u0226\1\uffff\2\u0226\22\uffff\1\u0226\61\uffff" u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u02f5\4\uffff\1\u02f6\1\uffff\1\u02f6"), DFA.unpack(u"\1\u02f7"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u02f8\1\uffff\1\u02f8"), DFA.unpack(u"\1\u02f9"), DFA.unpack(u"\1\u01c6\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\1\u02fb\37\uffff\1\u02fa"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u0100\14\uffff\1\u00ff\22\uffff\1\u00fe"), DFA.unpack(u"\1\u02fc"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u011a\32\uffff\1\u011b\4\uffff\1\u0119"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0245\1\uffff\2\u0245\22\uffff\1\u0245\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u02fd\3\uffff\1\u02fe\1\uffff\1\u02fe"), DFA.unpack(u"\1\u02ff"), DFA.unpack(u"\1\u0300\3\uffff\1\u0301\1\uffff\1\u0301"), DFA.unpack(u"\1\u0302"), DFA.unpack(u"\1\u0304\26\uffff\1\u0291\10\uffff\1\u0303"), DFA.unpack(u"\1\u0305\3\uffff\1\u0306\1\uffff\1\u0306"), DFA.unpack(u"\1\u0307"), DFA.unpack(u"\1\u02dd\30\uffff\1\u024d\6\uffff\1\u02db"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u030a\26\uffff\1\u0291\10\uffff\1\u0308"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u030a\26\uffff\1\u0291\10\uffff\1\u0308"), DFA.unpack(u"\1\u030b\1\uffff\1\u030b"), DFA.unpack(u"\1\u030c"), DFA.unpack(u"\1\u030e\32\uffff\1\u01fd\4\uffff\1\u030d"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u0310\30\uffff\1\u024d\6\uffff\1\u030f"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u0310\30\uffff\1\u024d\6\uffff\1\u030f"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u0312\26\uffff\1\u0291\10\uffff\1\u0311"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u024c\30\uffff\1\u024d\6\uffff\1\u024b"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u0312\26\uffff\1\u0291\10\uffff\1\u0311"), DFA.unpack(u"\1\u013d"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100" u"\2\uffff\1\100\1\uffff\32\100"), DFA.unpack(u"\1\u0313\4\uffff\1\u0314\1\uffff\1\u0314"), DFA.unpack(u"\1\u0315"), DFA.unpack(u"\1\u0316\3\uffff\1\u0317\1\uffff\1\u0317"), DFA.unpack(u"\1\u0318"), DFA.unpack(u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\1\u0319\3\uffff\1\u031a\1\uffff\1\u031a"), DFA.unpack(u"\1\u031c\37\uffff\1\u031b"), DFA.unpack(u"\1\u031e\26\uffff\1\u0265\10\uffff\1\u031d"), DFA.unpack(u"\1\u031e\26\uffff\1\u0265\10\uffff\1\u031d"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\1\u0320\1\uffff\1\u0320"), DFA.unpack(u"\1\u0321"), DFA.unpack(u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u0322"), DFA.unpack(u"\1\u0324\32\uffff\1\u01b3\4\uffff\1\u0323"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u0154\11\uffff\1\u0153\25\uffff\1\u0152"), DFA.unpack(u"\1\u0325\1\uffff\1\u0325"), DFA.unpack(u"\1\u0326"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u0327"), DFA.unpack(u"\1\u01c6\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\1\u015e\11\uffff\1\u015f\25\uffff\1\u015d"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u0328\3\uffff\1\u0329\1\uffff\1\u0329"), DFA.unpack(u"\1\u032a"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u032b\3\uffff\1\u032c\1\uffff\1\u032c"), DFA.unpack(u"\1\u032d"), DFA.unpack(u"\1\u030a\26\uffff\1\u0291\10\uffff\1\u0308"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u032f\1\uffff\1\u032f"), DFA.unpack(u"\1\u0330"), DFA.unpack(u"\1\u0310\30\uffff\1\u024d\6\uffff\1\u030f"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u0292\26\uffff\1\u0291\10\uffff\1\u0290"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u0331"), DFA.unpack(u"\1\u0333\32\uffff\1\u01fd\4\uffff\1\u0332"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u0335\30\uffff\1\u024d\6\uffff\1\u0334"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u0335\30\uffff\1\u024d\6\uffff\1\u0334"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u0337\26\uffff\1\u0291\10\uffff\1\u0336"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u0337\26\uffff\1\u0291\10\uffff\1\u0336"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u0338\4\uffff\1\u0339\1\uffff\1\u0339"), DFA.unpack(u"\1\u033a"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u033b\3\uffff\1\u033c\1\uffff\1\u033c"), DFA.unpack(u"\1\u033d"), DFA.unpack(u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\1\u033e\1\uffff\1\u033e"), DFA.unpack(u"\1\u0340\37\uffff\1\u033f"), DFA.unpack(u"\1\u0342\26\uffff\1\u0265\10\uffff\1\u0341"), DFA.unpack(u"\1\u0342\26\uffff\1\u0265\10\uffff\1\u0341"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\1\u0343"), DFA.unpack(u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u01b4\32\uffff\1\u01b3\4\uffff\1\u01b2"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\2\u02b7\1\uffff\2\u02b7\22\uffff\1\u02b7\54\uffff" u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\1\u0344"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u01c6\7\uffff\1\u01c5\27\uffff\1\u01c4"), DFA.unpack(u"\1\u0345\3\uffff\1\u0346\1\uffff\1\u0346"), DFA.unpack(u"\1\u0347"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u0348\1\uffff\1\u0348"), DFA.unpack(u"\1\u0349"), DFA.unpack(u"\1\u0312\26\uffff\1\u0291\10\uffff\1\u0311"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u034a"), DFA.unpack(u"\1\u0335\30\uffff\1\u024d\6\uffff\1\u0334"), DFA.unpack(u"\1\u01fe\32\uffff\1\u01fd\4\uffff\1\u01fc"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u024c\30\uffff\1\u024d\6\uffff\1\u024b"), DFA.unpack(u"\2\u02dc\1\uffff\2\u02dc\22\uffff\1\u02dc\42\uffff" u"\1\u024c\30\uffff\1\u024d\6\uffff\1\u024b"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u0292\26\uffff\1\u0291\10\uffff\1\u0290"), DFA.unpack(u"\2\u0309\1\uffff\2\u0309\22\uffff\1\u0309\44\uffff" u"\1\u0292\26\uffff\1\u0291\10\uffff\1\u0290"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\2\u032e\1\uffff\2\u032e\22\uffff\1\u032e\14\uffff" u"\1\100\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100" u"\1\uffff\32\100"), DFA.unpack(u"\1\u034b\4\uffff\1\u034c\1\uffff\1\u034c"), DFA.unpack(u"\1\u034d"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u034e\1\uffff\1\u034e"), DFA.unpack(u"\1\u034f"), DFA.unpack(u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\1\u0351\37\uffff\1\u0350"), DFA.unpack(u"\1\u0353\26\uffff\1\u0265\10\uffff\1\u0352"), DFA.unpack(u"\1\u0353\26\uffff\1\u0265\10\uffff\1\u0352"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\1\u0218\16\uffff\1\u0217\20\uffff\1\u0216"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u0354\1\uffff\1\u0354"), DFA.unpack(u"\1\u0355"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u0356"), DFA.unpack(u"\1\u0337\26\uffff\1\u0291\10\uffff\1\u0336"), DFA.unpack(u"\1\u024c\30\uffff\1\u024d\6\uffff\1\u024b"), DFA.unpack(u"\1\u0357\1\uffff\1\u0357"), DFA.unpack(u"\1\u0358"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u0359"), DFA.unpack(u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\1\u0264\26\uffff\1\u0265\10\uffff\1\u0263"), DFA.unpack(u"\1\u0264\26\uffff\1\u0265\10\uffff\1\u0263"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\2\u031f\1\uffff\2\u031f\22\uffff\1\u031f\62\uffff" u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\1\u035a"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u0292\26\uffff\1\u0291\10\uffff\1\u0290"), DFA.unpack(u"\1\u035b"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\1\u02a7\10\uffff\1\u02a8\26\uffff\1\u02a6"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100"), DFA.unpack(u"\2\100\1\uffff\2\100\22\uffff\1\100\14\uffff\1\100" u"\2\uffff\12\100\7\uffff\32\100\1\uffff\1\100\2\uffff\1\100\1\uffff" u"\32\100") ] # class definition for DFA #231 class DFA231(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA231_51 = input.LA(1) s = -1 if (LA231_51 == 114): s = 80 elif (LA231_51 == 48): s = 81 elif (LA231_51 == 82): s = 82 elif ((0 <= LA231_51 <= 9) or LA231_51 == 11 or (14 <= LA231_51 <= 47) or (58 <= LA231_51 <= 64) or (71 <= LA231_51 <= 81) or (83 <= LA231_51 <= 96) or (103 <= LA231_51 <= 113) or (115 <= LA231_51 <= 65535)): s = 83 elif (LA231_51 == 53 or LA231_51 == 55): s = 84 elif ((49 <= LA231_51 <= 52) or LA231_51 == 54 or (56 <= LA231_51 <= 57) or (65 <= LA231_51 <= 70) or (97 <= LA231_51 <= 102)): s = 85 if s >= 0: return s elif s == 1: LA231_171 = input.LA(1) s = -1 if (LA231_171 == 121): s = 247 elif (LA231_171 == 48): s = 248 elif (LA231_171 == 89): s = 249 elif ((0 <= LA231_171 <= 9) or LA231_171 == 11 or (14 <= LA231_171 <= 47) or (49 <= LA231_171 <= 52) or LA231_171 == 54 or (56 <= LA231_171 <= 88) or (90 <= LA231_171 <= 120) or (122 <= LA231_171 <= 65535)): s = 64 elif (LA231_171 == 53 or LA231_171 == 55): s = 250 if s >= 0: return s elif s == 2: LA231_61 = input.LA(1) s = -1 if ((0 <= LA231_61 <= 9) or LA231_61 == 11 or (14 <= LA231_61 <= 47) or (58 <= LA231_61 <= 64) or (71 <= LA231_61 <= 96) or (103 <= LA231_61 <= 65535)): s = 83 elif ((48 <= LA231_61 <= 57) or (65 <= LA231_61 <= 70) or (97 <= LA231_61 <= 102)): s = 85 if s >= 0: return s elif s == 3: LA231_39 = input.LA(1) s = -1 if ((0 <= LA231_39 <= 9) or LA231_39 == 11 or (14 <= LA231_39 <= 47) or (58 <= LA231_39 <= 64) or (71 <= LA231_39 <= 96) or (103 <= LA231_39 <= 65535)): s = 57 elif ((48 <= LA231_39 <= 57) or (65 <= LA231_39 <= 70) or (97 <= LA231_39 <= 102)): s = 60 if s >= 0: return s elif s == 4: LA231_67 = input.LA(1) s = -1 if (LA231_67 == 109): s = 98 elif (LA231_67 == 77): s = 99 elif (LA231_67 == 107): s = 100 elif (LA231_67 == 48): s = 101 elif (LA231_67 == 52 or LA231_67 == 54): s = 102 elif (LA231_67 == 53 or LA231_67 == 55): s = 103 elif (LA231_67 == 75): s = 104 elif (LA231_67 == 105): s = 105 elif (LA231_67 == 73): s = 106 elif (LA231_67 == 112): s = 107 elif (LA231_67 == 80): s = 108 elif ((0 <= LA231_67 <= 9) or LA231_67 == 11 or (14 <= LA231_67 <= 47) or (49 <= LA231_67 <= 51) or (56 <= LA231_67 <= 72) or LA231_67 == 74 or LA231_67 == 76 or (78 <= LA231_67 <= 79) or (81 <= LA231_67 <= 104) or LA231_67 == 106 or LA231_67 == 108 or (110 <= LA231_67 <= 111) or (113 <= LA231_67 <= 65535)): s = 64 if s >= 0: return s elif s == 5: LA231_453 = input.LA(1) s = -1 if (LA231_453 == 116): s = 553 elif (LA231_453 == 48): s = 554 elif (LA231_453 == 84): s = 555 elif ((0 <= LA231_453 <= 9) or LA231_453 == 11 or (14 <= LA231_453 <= 47) or (49 <= LA231_453 <= 52) or LA231_453 == 54 or (56 <= LA231_453 <= 83) or (85 <= LA231_453 <= 115) or (117 <= LA231_453 <= 65535)): s = 64 elif (LA231_453 == 53 or LA231_453 == 55): s = 556 if s >= 0: return s elif s == 6: LA231_225 = input.LA(1) s = -1 if (LA231_225 == 116): s = 318 elif (LA231_225 == 48): s = 319 elif (LA231_225 == 84): s = 320 elif ((0 <= LA231_225 <= 9) or LA231_225 == 11 or (14 <= LA231_225 <= 47) or (49 <= LA231_225 <= 52) or LA231_225 == 54 or (56 <= LA231_225 <= 83) or (85 <= LA231_225 <= 115) or (117 <= LA231_225 <= 65535)): s = 64 elif (LA231_225 == 53 or LA231_225 == 55): s = 321 if s >= 0: return s elif s == 7: LA231_176 = input.LA(1) s = -1 if (LA231_176 == 112): s = 257 elif (LA231_176 == 48): s = 258 elif (LA231_176 == 80): s = 259 elif ((0 <= LA231_176 <= 9) or LA231_176 == 11 or (14 <= LA231_176 <= 47) or (49 <= LA231_176 <= 52) or LA231_176 == 54 or (56 <= LA231_176 <= 79) or (81 <= LA231_176 <= 111) or (113 <= LA231_176 <= 65535)): s = 64 elif (LA231_176 == 53 or LA231_176 == 55): s = 260 if s >= 0: return s elif s == 8: LA231_79 = input.LA(1) s = -1 if (LA231_79 == 108): s = 125 elif (LA231_79 == 48): s = 126 elif (LA231_79 == 76): s = 127 elif ((0 <= LA231_79 <= 9) or LA231_79 == 11 or (14 <= LA231_79 <= 47) or (58 <= LA231_79 <= 64) or (71 <= LA231_79 <= 75) or (77 <= LA231_79 <= 96) or (103 <= LA231_79 <= 107) or (109 <= LA231_79 <= 65535)): s = 83 elif (LA231_79 == 52 or LA231_79 == 54): s = 128 elif ((49 <= LA231_79 <= 51) or LA231_79 == 53 or (55 <= LA231_79 <= 57) or (65 <= LA231_79 <= 70) or (97 <= LA231_79 <= 102)): s = 85 if s >= 0: return s elif s == 9: LA231_166 = input.LA(1) s = -1 if (LA231_166 == 103): s = 237 elif (LA231_166 == 48): s = 238 elif (LA231_166 == 71): s = 239 elif ((0 <= LA231_166 <= 9) or LA231_166 == 11 or (14 <= LA231_166 <= 47) or (49 <= LA231_166 <= 51) or LA231_166 == 53 or (55 <= LA231_166 <= 70) or (72 <= LA231_166 <= 102) or (104 <= LA231_166 <= 65535)): s = 64 elif (LA231_166 == 52 or LA231_166 == 54): s = 240 if s >= 0: return s elif s == 10: LA231_111 = input.LA(1) s = -1 if (LA231_111 == 111): s = 161 elif (LA231_111 == 79): s = 162 elif ((0 <= LA231_111 <= 9) or LA231_111 == 11 or (14 <= LA231_111 <= 47) or (49 <= LA231_111 <= 51) or LA231_111 == 53 or (55 <= LA231_111 <= 78) or (80 <= LA231_111 <= 110) or (112 <= LA231_111 <= 65535)): s = 64 elif (LA231_111 == 48): s = 163 elif (LA231_111 == 52 or LA231_111 == 54): s = 164 if s >= 0: return s elif s == 11: LA231_680 = input.LA(1) s = -1 if (LA231_680 == 115): s = 736 elif (LA231_680 == 83): s = 737 elif ((0 <= LA231_680 <= 9) or LA231_680 == 11 or (14 <= LA231_680 <= 47) or (49 <= LA231_680 <= 52) or LA231_680 == 54 or (56 <= LA231_680 <= 82) or (84 <= LA231_680 <= 114) or (116 <= LA231_680 <= 65535)): s = 64 elif (LA231_680 == 48): s = 738 elif (LA231_680 == 53 or LA231_680 == 55): s = 739 if s >= 0: return s elif s == 12: LA231_255 = input.LA(1) s = -1 if (LA231_255 == 111): s = 352 elif (LA231_255 == 48): s = 353 elif (LA231_255 == 79): s = 354 elif ((0 <= LA231_255 <= 9) or LA231_255 == 11 or (14 <= LA231_255 <= 47) or (49 <= LA231_255 <= 51) or LA231_255 == 53 or (55 <= LA231_255 <= 78) or (80 <= LA231_255 <= 110) or (112 <= LA231_255 <= 65535)): s = 64 elif (LA231_255 == 52 or LA231_255 == 54): s = 355 if s >= 0: return s elif s == 13: LA231_115 = input.LA(1) s = -1 if ((0 <= LA231_115 <= 9) or LA231_115 == 11 or (14 <= LA231_115 <= 47) or (49 <= LA231_115 <= 51) or LA231_115 == 53 or (55 <= LA231_115 <= 65535)): s = 64 elif (LA231_115 == 48): s = 168 elif (LA231_115 == 52 or LA231_115 == 54): s = 169 if s >= 0: return s elif s == 14: LA231_283 = input.LA(1) s = -1 if ((0 <= LA231_283 <= 9) or LA231_283 == 11 or (14 <= LA231_283 <= 47) or (49 <= LA231_283 <= 51) or LA231_283 == 53 or (55 <= LA231_283 <= 65535)): s = 64 elif (LA231_283 == 48): s = 377 elif (LA231_283 == 52 or LA231_283 == 54): s = 378 if s >= 0: return s elif s == 15: LA231_509 = input.LA(1) s = -1 if ((0 <= LA231_509 <= 9) or LA231_509 == 11 or (14 <= LA231_509 <= 47) or (49 <= LA231_509 <= 51) or LA231_509 == 53 or (55 <= LA231_509 <= 65535)): s = 64 elif (LA231_509 == 48): s = 590 elif (LA231_509 == 52 or LA231_509 == 54): s = 591 if s >= 0: return s elif s == 16: LA231_435 = input.LA(1) s = -1 if ((0 <= LA231_435 <= 9) or LA231_435 == 11 or (14 <= LA231_435 <= 47) or (49 <= LA231_435 <= 51) or LA231_435 == 53 or (55 <= LA231_435 <= 65535)): s = 64 elif (LA231_435 == 48): s = 537 elif (LA231_435 == 52 or LA231_435 == 54): s = 538 if s >= 0: return s elif s == 17: LA231_535 = input.LA(1) s = -1 if (LA231_535 == 109): s = 614 elif (LA231_535 == 48): s = 615 elif (LA231_535 == 77): s = 616 elif ((0 <= LA231_535 <= 9) or LA231_535 == 11 or (14 <= LA231_535 <= 47) or (49 <= LA231_535 <= 51) or LA231_535 == 53 or (55 <= LA231_535 <= 76) or (78 <= LA231_535 <= 108) or (110 <= LA231_535 <= 65535)): s = 64 elif (LA231_535 == 52 or LA231_535 == 54): s = 617 if s >= 0: return s elif s == 18: LA231_589 = input.LA(1) s = -1 if ((0 <= LA231_589 <= 9) or LA231_589 == 11 or (14 <= LA231_589 <= 47) or (49 <= LA231_589 <= 51) or LA231_589 == 53 or (55 <= LA231_589 <= 65535)): s = 64 elif (LA231_589 == 48): s = 659 elif (LA231_589 == 52 or LA231_589 == 54): s = 660 if s >= 0: return s elif s == 19: LA231_351 = input.LA(1) s = -1 if (LA231_351 == 114): s = 455 elif (LA231_351 == 48): s = 456 elif (LA231_351 == 82): s = 457 elif ((0 <= LA231_351 <= 9) or LA231_351 == 11 or (14 <= LA231_351 <= 47) or (49 <= LA231_351 <= 52) or LA231_351 == 54 or (56 <= LA231_351 <= 81) or (83 <= LA231_351 <= 113) or (115 <= LA231_351 <= 65535)): s = 64 elif (LA231_351 == 53 or LA231_351 == 55): s = 458 if s >= 0: return s elif s == 20: LA231_144 = input.LA(1) s = -1 if ((0 <= LA231_144 <= 9) or LA231_144 == 11 or (14 <= LA231_144 <= 47) or (49 <= LA231_144 <= 51) or LA231_144 == 53 or (55 <= LA231_144 <= 65535)): s = 64 elif (LA231_144 == 48): s = 202 elif (LA231_144 == 52 or LA231_144 == 54): s = 203 if s >= 0: return s elif s == 21: LA231_339 = input.LA(1) s = -1 if (LA231_339 == 114): s = 437 elif (LA231_339 == 48): s = 438 elif (LA231_339 == 82): s = 439 elif ((0 <= LA231_339 <= 9) or LA231_339 == 11 or (14 <= LA231_339 <= 47) or (49 <= LA231_339 <= 52) or LA231_339 == 54 or (56 <= LA231_339 <= 81) or (83 <= LA231_339 <= 113) or (115 <= LA231_339 <= 65535)): s = 64 elif (LA231_339 == 53 or LA231_339 == 55): s = 440 if s >= 0: return s elif s == 22: LA231_159 = input.LA(1) s = -1 if (LA231_159 == 110): s = 226 elif (LA231_159 == 48): s = 227 elif (LA231_159 == 78): s = 228 elif ((0 <= LA231_159 <= 9) or LA231_159 == 11 or (14 <= LA231_159 <= 47) or (49 <= LA231_159 <= 51) or LA231_159 == 53 or (55 <= LA231_159 <= 77) or (79 <= LA231_159 <= 109) or (111 <= LA231_159 <= 65535)): s = 64 elif (LA231_159 == 52 or LA231_159 == 54): s = 229 if s >= 0: return s elif s == 23: LA231_24 = input.LA(1) s = -1 if (LA231_24 == 117): s = 55 elif (LA231_24 == 85): s = 56 elif ((0 <= LA231_24 <= 9) or LA231_24 == 11 or (14 <= LA231_24 <= 47) or (58 <= LA231_24 <= 64) or (71 <= LA231_24 <= 84) or (86 <= LA231_24 <= 96) or (103 <= LA231_24 <= 116) or (118 <= LA231_24 <= 65535)): s = 57 elif (LA231_24 == 48): s = 58 elif (LA231_24 == 53 or LA231_24 == 55): s = 59 elif ((49 <= LA231_24 <= 52) or LA231_24 == 54 or (56 <= LA231_24 <= 57) or (65 <= LA231_24 <= 70) or (97 <= LA231_24 <= 102)): s = 60 if s >= 0: return s elif s == 24: LA231_119 = input.LA(1) s = -1 if ((0 <= LA231_119 <= 9) or LA231_119 == 11 or (14 <= LA231_119 <= 47) or (49 <= LA231_119 <= 51) or LA231_119 == 53 or (55 <= LA231_119 <= 65535)): s = 64 elif (LA231_119 == 48): s = 173 elif (LA231_119 == 52 or LA231_119 == 54): s = 174 if s >= 0: return s elif s == 25: LA231_613 = input.LA(1) s = -1 if ((0 <= LA231_613 <= 9) or LA231_613 == 11 or (14 <= LA231_613 <= 47) or (49 <= LA231_613 <= 51) or LA231_613 == 53 or (55 <= LA231_613 <= 65535)): s = 64 elif (LA231_613 == 48): s = 681 elif (LA231_613 == 52 or LA231_613 == 54): s = 682 if s >= 0: return s elif s == 26: LA231_657 = input.LA(1) s = -1 if ((0 <= LA231_657 <= 9) or LA231_657 == 11 or (14 <= LA231_657 <= 47) or (49 <= LA231_657 <= 51) or LA231_657 == 53 or (55 <= LA231_657 <= 65535)): s = 64 elif (LA231_657 == 48): s = 716 elif (LA231_657 == 52 or LA231_657 == 54): s = 717 if s >= 0: return s elif s == 27: LA231_236 = input.LA(1) s = -1 if ((0 <= LA231_236 <= 9) or LA231_236 == 11 or (14 <= LA231_236 <= 47) or (49 <= LA231_236 <= 51) or LA231_236 == 53 or (55 <= LA231_236 <= 65535)): s = 64 elif (LA231_236 == 48): s = 330 elif (LA231_236 == 52 or LA231_236 == 54): s = 331 if s >= 0: return s elif s == 28: LA231_96 = input.LA(1) s = -1 if ((0 <= LA231_96 <= 9) or LA231_96 == 11 or (14 <= LA231_96 <= 47) or (49 <= LA231_96 <= 51) or LA231_96 == 53 or (55 <= LA231_96 <= 65535)): s = 64 elif (LA231_96 == 48): s = 146 elif (LA231_96 == 52 or LA231_96 == 54): s = 147 if s >= 0: return s elif s == 29: LA231_201 = input.LA(1) s = -1 if (LA231_201 == 105): s = 284 elif (LA231_201 == 48): s = 285 elif (LA231_201 == 73): s = 286 elif ((0 <= LA231_201 <= 9) or LA231_201 == 11 or (14 <= LA231_201 <= 47) or (49 <= LA231_201 <= 51) or LA231_201 == 53 or (55 <= LA231_201 <= 72) or (74 <= LA231_201 <= 104) or (106 <= LA231_201 <= 65535)): s = 64 elif (LA231_201 == 52 or LA231_201 == 54): s = 287 if s >= 0: return s elif s == 30: LA231_411 = input.LA(1) s = -1 if ((0 <= LA231_411 <= 9) or LA231_411 == 11 or (14 <= LA231_411 <= 47) or (49 <= LA231_411 <= 51) or LA231_411 == 53 or (55 <= LA231_411 <= 65535)): s = 64 elif (LA231_411 == 48): s = 511 elif (LA231_411 == 52 or LA231_411 == 54): s = 512 if s >= 0: return s elif s == 31: LA231_245 = input.LA(1) s = -1 if ((0 <= LA231_245 <= 9) or LA231_245 == 11 or (14 <= LA231_245 <= 47) or (49 <= LA231_245 <= 51) or LA231_245 == 53 or (55 <= LA231_245 <= 65535)): s = 64 elif (LA231_245 == 48): s = 341 elif (LA231_245 == 52 or LA231_245 == 54): s = 342 if s >= 0: return s elif s == 32: LA231_122 = input.LA(1) s = -1 if (LA231_122 == 109): s = 178 elif (LA231_122 == 48): s = 179 elif (LA231_122 == 77): s = 180 elif ((0 <= LA231_122 <= 9) or LA231_122 == 11 or (14 <= LA231_122 <= 47) or (49 <= LA231_122 <= 51) or LA231_122 == 53 or (55 <= LA231_122 <= 76) or (78 <= LA231_122 <= 108) or (110 <= LA231_122 <= 65535)): s = 64 elif (LA231_122 == 52 or LA231_122 == 54): s = 181 if s >= 0: return s if self._state.backtracking >0: raise BacktrackingFailed nvae = NoViableAltException(self_.getDescription(), 231, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #233 DFA233_eot = DFA.unpack( u"\12\uffff" ) DFA233_eof = DFA.unpack( u"\12\uffff" ) DFA233_min = DFA.unpack( u"\1\103\1\uffff\1\60\2\uffff\1\60\1\64\2\60\1\64" ) DFA233_max = DFA.unpack( u"\1\170\1\uffff\1\170\2\uffff\1\67\1\70\3\67" ) DFA233_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\2\1\3\5\uffff" ) DFA233_special = DFA.unpack( u"\12\uffff" ) DFA233_transition = [ DFA.unpack(u"\1\4\20\uffff\1\3\3\uffff\1\1\3\uffff\1\2\6\uffff\1" u"\4\20\uffff\1\3\3\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u"\1\5\3\uffff\1\4\1\6\1\4\1\6\34\uffff\1\3\3\uffff\1" u"\1\33\uffff\1\3\3\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\7\3\uffff\1\4\1\6\1\4\1\6"), DFA.unpack(u"\1\3\3\uffff\1\1"), DFA.unpack(u"\1\10\3\uffff\1\4\1\6\1\4\1\6"), DFA.unpack(u"\1\11\3\uffff\1\4\1\6\1\4\1\6"), DFA.unpack(u"\1\4\1\6\1\4\1\6") ] # class definition for DFA #233 class DFA233(DFA): pass # lookup tables for DFA #236 DFA236_eot = DFA.unpack( u"\12\uffff" ) DFA236_eof = DFA.unpack( u"\12\uffff" ) DFA236_min = DFA.unpack( u"\1\103\1\uffff\1\60\2\uffff\1\60\1\63\2\60\1\64" ) DFA236_max = DFA.unpack( u"\1\160\1\uffff\1\160\2\uffff\1\67\1\71\3\67" ) DFA236_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\2\1\3\5\uffff" ) DFA236_special = DFA.unpack( u"\12\uffff" ) DFA236_transition = [ DFA.unpack(u"\1\3\5\uffff\1\1\6\uffff\1\4\13\uffff\1\2\6\uffff\1" u"\3\5\uffff\1\1\6\uffff\1\4"), DFA.unpack(u""), DFA.unpack(u"\1\5\3\uffff\1\6\1\4\1\6\1\4\21\uffff\1\1\6\uffff\1" u"\4\30\uffff\1\1\6\uffff\1\4"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\7\3\uffff\1\6\1\4\1\6\1\4"), DFA.unpack(u"\1\3\5\uffff\1\1"), DFA.unpack(u"\1\10\3\uffff\1\6\1\4\1\6\1\4"), DFA.unpack(u"\1\11\3\uffff\1\6\1\4\1\6\1\4"), DFA.unpack(u"\1\6\1\4\1\6\1\4") ] # class definition for DFA #236 class DFA236(DFA): pass # lookup tables for DFA #237 DFA237_eot = DFA.unpack( u"\12\uffff" ) DFA237_eof = DFA.unpack( u"\12\uffff" ) DFA237_min = DFA.unpack( u"\1\110\1\uffff\1\60\2\uffff\1\60\1\70\2\60\1\64" ) DFA237_max = DFA.unpack( u"\1\167\1\uffff\1\167\2\uffff\1\67\1\144\3\67" ) DFA237_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\2\1\3\5\uffff" ) DFA237_special = DFA.unpack( u"\12\uffff" ) DFA237_transition = [ DFA.unpack(u"\1\3\4\uffff\1\4\11\uffff\1\1\4\uffff\1\2\13\uffff\1" u"\3\4\uffff\1\4\11\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u"\1\5\3\uffff\1\6\1\1\1\6\1\1\20\uffff\1\3\4\uffff\1" u"\4\11\uffff\1\1\20\uffff\1\3\4\uffff\1\4\11\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\7\3\uffff\1\6\1\1\1\6\1\1"), DFA.unpack(u"\1\3\13\uffff\1\4\37\uffff\1\4"), DFA.unpack(u"\1\10\3\uffff\1\6\1\1\1\6\1\1"), DFA.unpack(u"\1\11\3\uffff\1\6\1\1\1\6\1\1"), DFA.unpack(u"\1\6\1\1\1\6\1\1") ] # class definition for DFA #237 class DFA237(DFA): pass def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(lesscssLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ateska/pyless", "path": "pyless/lesscssLexer.py", "copies": "1", "size": "639531", "license": "bsd-2-clause", "hash": -5994230704869434000, "line_mean": 31.0229833258, "line_max": 582, "alpha_frac": 0.3915009593, "autogenerated": false, "ratio": 3.0827159363145133, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.39742168956145135, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 proto_lexer.g 2013-10-23 04:20:51 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EXPONENT=60 MESSAGE_LITERAL=11 REQUIRED_PROTOBUF_SCOPE_LITERAL=29 STRING_GUTS=54 EQUALS=25 UINT32_PROTOBUF_TYPE_LITERAL=37 INT32_PROTOBUF_TYPE_LITERAL=35 EOF=-1 UINT64_PROTOBUF_TYPE_LITERAL=38 QUALIFIED_IDENTIFIER=63 ESCAPE_SEQUENCE=56 UNICODE_ESCAPE=58 FIXED64_PROTOBUF_TYPE_LITERAL=42 STRING_LITERAL=55 PACKAGE_LITERAL=7 FIXED32_PROTOBUF_TYPE_LITERAL=41 COMMA=27 IDENTIFIER=62 EXTEND_LITERAL=12 REPEATED_PROTOBUF_SCOPE_LITERAL=31 PROTOBUF_TYPE_LITERAL=48 ENUM_LITERAL=10 IMPORT_LITERAL=8 HEX_LITERAL=49 COMMENT=5 FLOAT_PROTOBUF_TYPE_LITERAL=34 BYTES_PROTOBUF_TYPE_LITERAL=47 BLOCK_OPEN=19 SFIXED64_PROTOBUF_TYPE_LITERAL=44 SERVICE_LITERAL=16 PROTOBUF_SCOPE_LITERAL=32 END_OF_LINE=4 EXTENSIONS_TO_LITERAL=14 OPTIONAL_PROTOBUF_SCOPE_LITERAL=30 PAREN_CLOSE=22 BOOL_PROTOBUF_TYPE_LITERAL=45 ITEM_TERMINATOR=28 OCTAL_LITERAL=50 EXTENSIONS_MAX_LITERAL=15 OPTION_LITERAL=9 HEX_DIGIT=53 STRING_PROTOBUF_TYPE_LITERAL=46 WHITESPACE=6 OCTAL_ESCAPE=57 BOOL_LITERAL=59 EXTENSIONS_DEF_LITERAL=13 SINT32_PROTOBUF_TYPE_LITERAL=39 FLOAT_LITERAL=61 COLON=26 BLOCK_CLOSE=20 INT64_PROTOBUF_TYPE_LITERAL=36 FIELD_IDENTIFIER=64 INTEGER_LITERAL=52 PAREN_OPEN=21 DOUBLE_PROTOBUF_TYPE_LITERAL=33 SFIXED32_PROTOBUF_TYPE_LITERAL=43 DECIMAL_LITERAL=51 BRACKET_CLOSE=24 SINT64_PROTOBUF_TYPE_LITERAL=40 RPC_LITERAL=18 RETURNS_LITERAL=17 BRACKET_OPEN=23 class proto_lexer(Lexer): grammarFileName = "proto_lexer.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(proto_lexer, self).__init__(input, state) self.dfa7 = self.DFA7( self, 7, eot = self.DFA7_eot, eof = self.DFA7_eof, min = self.DFA7_min, max = self.DFA7_max, accept = self.DFA7_accept, special = self.DFA7_special, transition = self.DFA7_transition ) self.dfa29 = self.DFA29( self, 29, eot = self.DFA29_eot, eof = self.DFA29_eof, min = self.DFA29_min, max = self.DFA29_max, accept = self.DFA29_accept, special = self.DFA29_special, transition = self.DFA29_transition ) self.dfa35 = self.DFA35( self, 35, eot = self.DFA35_eot, eof = self.DFA35_eof, min = self.DFA35_min, max = self.DFA35_max, accept = self.DFA35_accept, special = self.DFA35_special, transition = self.DFA35_transition ) literals = dict([ ("PACKAGE_LITERAL", "package"), ("IMPORT_LITERAL", "import"), ("OPTION_LITERAL", "option"), ("ENUM_LITERAL", "enum"), ("MESSAGE_LITERAL", "message"), ("EXTEND_LITERAL", "extend"), ("EXTENSIONS_DEF_LITERAL", "extensions"), ("EXTENSIONS_TO_LITERAL", "to"), ("EXTENSIONS_MAX_LITERAL", "max"), ("SERVICE_LITERAL", "service"), ("RETURNS_LITERAL", "returns"), ("RPC_LITERAL", "rpc"), ("BLOCK_OPEN", "{"), ("BLOCK_CLOSE", "}"), ("PAREN_OPEN", "("), ("PAREN_CLOSE", ")"), ("BRACKET_OPEN", "["), ("BRACKET_CLOSE", "]"), ("EQUALS", "="), ("COLON", ":"), ("COMMA", ","), ("ITEM_TERMINATOR", ";"), ]) def getLiterals(): return literals; # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # proto_lexer.g:39:3: ( '//' (~ ( '\\n' | '\\r' ) )* END_OF_LINE | '/*' ( options {greedy=false; } : . )* '*/' ) alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == 47) : LA3_1 = self.input.LA(2) if (LA3_1 == 47) : alt3 = 1 elif (LA3_1 == 42) : alt3 = 2 else: nvae = NoViableAltException("", 3, 1, self.input) raise nvae else: nvae = NoViableAltException("", 3, 0, self.input) raise nvae if alt3 == 1: # proto_lexer.g:39:6: '//' (~ ( '\\n' | '\\r' ) )* END_OF_LINE pass self.match("//") # proto_lexer.g:39:11: (~ ( '\\n' | '\\r' ) )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((0 <= LA1_0 <= 9) or (11 <= LA1_0 <= 12) or (14 <= LA1_0 <= 65535)) : alt1 = 1 if alt1 == 1: # proto_lexer.g:39:11: ~ ( '\\n' | '\\r' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 self.mEND_OF_LINE() #action start self.skip() #action end elif alt3 == 2: # proto_lexer.g:40:6: '/*' ( options {greedy=false; } : . )* '*/' pass self.match("/*") # proto_lexer.g:40:11: ( options {greedy=false; } : . )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == 42) : LA2_1 = self.input.LA(2) if (LA2_1 == 47) : alt2 = 2 elif ((0 <= LA2_1 <= 46) or (48 <= LA2_1 <= 65535)) : alt2 = 1 elif ((0 <= LA2_0 <= 41) or (43 <= LA2_0 <= 65535)) : alt2 = 1 if alt2 == 1: # proto_lexer.g:40:38: . pass self.matchAny() else: break #loop2 self.match("*/") #action start self.skip() #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "END_OF_LINE" def mEND_OF_LINE(self, ): try: # proto_lexer.g:42:21: ( '\\r\\n' | '\\n' | '\\r' | ) alt4 = 4 LA4 = self.input.LA(1) if LA4 == 13: LA4_1 = self.input.LA(2) if (LA4_1 == 10) : alt4 = 1 else: alt4 = 3 elif LA4 == 10: alt4 = 2 else: alt4 = 4 if alt4 == 1: # proto_lexer.g:42:23: '\\r\\n' pass self.match("\r\n") elif alt4 == 2: # proto_lexer.g:42:32: '\\n' pass self.match(10) elif alt4 == 3: # proto_lexer.g:42:39: '\\r' pass self.match(13) elif alt4 == 4: # proto_lexer.g:42:46: pass #action start self.skip() #action end finally: pass # $ANTLR end "END_OF_LINE" # $ANTLR start "WHITESPACE" def mWHITESPACE(self, ): try: _type = WHITESPACE _channel = DEFAULT_CHANNEL # proto_lexer.g:43:12: ( ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+ ) # proto_lexer.g:43:14: ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+ pass # proto_lexer.g:43:14: ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+ cnt5 = 0 while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if ((9 <= LA5_0 <= 10) or (12 <= LA5_0 <= 13) or LA5_0 == 32) : alt5 = 1 if alt5 == 1: # proto_lexer.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt5 >= 1: break #loop5 eee = EarlyExitException(5, self.input) raise eee cnt5 += 1 #action start self.skip() #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WHITESPACE" # $ANTLR start "PACKAGE_LITERAL" def mPACKAGE_LITERAL(self, ): try: _type = PACKAGE_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:45:17: ( 'package' ) # proto_lexer.g:45:19: 'package' pass self.match("package") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PACKAGE_LITERAL" # $ANTLR start "IMPORT_LITERAL" def mIMPORT_LITERAL(self, ): try: _type = IMPORT_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:46:16: ( 'import' ) # proto_lexer.g:46:18: 'import' pass self.match("import") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IMPORT_LITERAL" # $ANTLR start "OPTION_LITERAL" def mOPTION_LITERAL(self, ): try: _type = OPTION_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:47:16: ( 'option' ) # proto_lexer.g:47:18: 'option' pass self.match("option") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OPTION_LITERAL" # $ANTLR start "ENUM_LITERAL" def mENUM_LITERAL(self, ): try: _type = ENUM_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:49:14: ( 'enum' ) # proto_lexer.g:49:16: 'enum' pass self.match("enum") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ENUM_LITERAL" # $ANTLR start "MESSAGE_LITERAL" def mMESSAGE_LITERAL(self, ): try: _type = MESSAGE_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:50:17: ( 'message' ) # proto_lexer.g:50:19: 'message' pass self.match("message") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MESSAGE_LITERAL" # $ANTLR start "EXTEND_LITERAL" def mEXTEND_LITERAL(self, ): try: _type = EXTEND_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:51:16: ( 'extend' ) # proto_lexer.g:51:18: 'extend' pass self.match("extend") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EXTEND_LITERAL" # $ANTLR start "EXTENSIONS_DEF_LITERAL" def mEXTENSIONS_DEF_LITERAL(self, ): try: _type = EXTENSIONS_DEF_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:52:24: ( 'extensions' ) # proto_lexer.g:52:26: 'extensions' pass self.match("extensions") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EXTENSIONS_DEF_LITERAL" # $ANTLR start "EXTENSIONS_TO_LITERAL" def mEXTENSIONS_TO_LITERAL(self, ): try: _type = EXTENSIONS_TO_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:53:23: ( 'to' ) # proto_lexer.g:53:25: 'to' pass self.match("to") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EXTENSIONS_TO_LITERAL" # $ANTLR start "EXTENSIONS_MAX_LITERAL" def mEXTENSIONS_MAX_LITERAL(self, ): try: _type = EXTENSIONS_MAX_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:54:24: ( 'max' ) # proto_lexer.g:54:26: 'max' pass self.match("max") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EXTENSIONS_MAX_LITERAL" # $ANTLR start "SERVICE_LITERAL" def mSERVICE_LITERAL(self, ): try: _type = SERVICE_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:61:17: ( 'service' ) # proto_lexer.g:61:19: 'service' pass self.match("service") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SERVICE_LITERAL" # $ANTLR start "RETURNS_LITERAL" def mRETURNS_LITERAL(self, ): try: _type = RETURNS_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:62:17: ( 'returns' ) # proto_lexer.g:62:19: 'returns' pass self.match("returns") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RETURNS_LITERAL" # $ANTLR start "RPC_LITERAL" def mRPC_LITERAL(self, ): try: _type = RPC_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:63:13: ( 'rpc' ) # proto_lexer.g:63:15: 'rpc' pass self.match("rpc") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RPC_LITERAL" # $ANTLR start "BLOCK_OPEN" def mBLOCK_OPEN(self, ): try: _type = BLOCK_OPEN _channel = DEFAULT_CHANNEL # proto_lexer.g:65:12: ( '{' ) # proto_lexer.g:65:14: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BLOCK_OPEN" # $ANTLR start "BLOCK_CLOSE" def mBLOCK_CLOSE(self, ): try: _type = BLOCK_CLOSE _channel = DEFAULT_CHANNEL # proto_lexer.g:66:13: ( '}' ) # proto_lexer.g:66:15: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BLOCK_CLOSE" # $ANTLR start "PAREN_OPEN" def mPAREN_OPEN(self, ): try: _type = PAREN_OPEN _channel = DEFAULT_CHANNEL # proto_lexer.g:67:12: ( '(' ) # proto_lexer.g:67:14: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PAREN_OPEN" # $ANTLR start "PAREN_CLOSE" def mPAREN_CLOSE(self, ): try: _type = PAREN_CLOSE _channel = DEFAULT_CHANNEL # proto_lexer.g:68:13: ( ')' ) # proto_lexer.g:68:15: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PAREN_CLOSE" # $ANTLR start "BRACKET_OPEN" def mBRACKET_OPEN(self, ): try: _type = BRACKET_OPEN _channel = DEFAULT_CHANNEL # proto_lexer.g:69:14: ( '[' ) # proto_lexer.g:69:16: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BRACKET_OPEN" # $ANTLR start "BRACKET_CLOSE" def mBRACKET_CLOSE(self, ): try: _type = BRACKET_CLOSE _channel = DEFAULT_CHANNEL # proto_lexer.g:70:15: ( ']' ) # proto_lexer.g:70:17: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BRACKET_CLOSE" # $ANTLR start "EQUALS" def mEQUALS(self, ): try: _type = EQUALS _channel = DEFAULT_CHANNEL # proto_lexer.g:71:8: ( '=' ) # proto_lexer.g:71:10: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EQUALS" # $ANTLR start "COLON" def mCOLON(self, ): try: _type = COLON _channel = DEFAULT_CHANNEL # proto_lexer.g:72:7: ( ':' ) # proto_lexer.g:72:9: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COLON" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # proto_lexer.g:73:7: ( ',' ) # proto_lexer.g:73:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "ITEM_TERMINATOR" def mITEM_TERMINATOR(self, ): try: _type = ITEM_TERMINATOR _channel = DEFAULT_CHANNEL # proto_lexer.g:74:17: ( ';' ) # proto_lexer.g:74:19: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ITEM_TERMINATOR" # $ANTLR start "PROTOBUF_SCOPE_LITERAL" def mPROTOBUF_SCOPE_LITERAL(self, ): try: _type = PROTOBUF_SCOPE_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:78:3: ( REQUIRED_PROTOBUF_SCOPE_LITERAL | OPTIONAL_PROTOBUF_SCOPE_LITERAL | REPEATED_PROTOBUF_SCOPE_LITERAL ) alt6 = 3 LA6_0 = self.input.LA(1) if (LA6_0 == 114) : LA6_1 = self.input.LA(2) if (LA6_1 == 101) : LA6_3 = self.input.LA(3) if (LA6_3 == 113) : alt6 = 1 elif (LA6_3 == 112) : alt6 = 3 else: nvae = NoViableAltException("", 6, 3, self.input) raise nvae else: nvae = NoViableAltException("", 6, 1, self.input) raise nvae elif (LA6_0 == 111) : alt6 = 2 else: nvae = NoViableAltException("", 6, 0, self.input) raise nvae if alt6 == 1: # proto_lexer.g:78:6: REQUIRED_PROTOBUF_SCOPE_LITERAL pass self.mREQUIRED_PROTOBUF_SCOPE_LITERAL() elif alt6 == 2: # proto_lexer.g:79:6: OPTIONAL_PROTOBUF_SCOPE_LITERAL pass self.mOPTIONAL_PROTOBUF_SCOPE_LITERAL() elif alt6 == 3: # proto_lexer.g:80:6: REPEATED_PROTOBUF_SCOPE_LITERAL pass self.mREPEATED_PROTOBUF_SCOPE_LITERAL() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PROTOBUF_SCOPE_LITERAL" # $ANTLR start "REQUIRED_PROTOBUF_SCOPE_LITERAL" def mREQUIRED_PROTOBUF_SCOPE_LITERAL(self, ): try: # proto_lexer.g:83:42: ( 'required' ) # proto_lexer.g:83:44: 'required' pass self.match("required") finally: pass # $ANTLR end "REQUIRED_PROTOBUF_SCOPE_LITERAL" # $ANTLR start "OPTIONAL_PROTOBUF_SCOPE_LITERAL" def mOPTIONAL_PROTOBUF_SCOPE_LITERAL(self, ): try: # proto_lexer.g:84:42: ( 'optional' ) # proto_lexer.g:84:44: 'optional' pass self.match("optional") finally: pass # $ANTLR end "OPTIONAL_PROTOBUF_SCOPE_LITERAL" # $ANTLR start "REPEATED_PROTOBUF_SCOPE_LITERAL" def mREPEATED_PROTOBUF_SCOPE_LITERAL(self, ): try: # proto_lexer.g:85:42: ( 'repeated' ) # proto_lexer.g:85:44: 'repeated' pass self.match("repeated") finally: pass # $ANTLR end "REPEATED_PROTOBUF_SCOPE_LITERAL" # $ANTLR start "PROTOBUF_TYPE_LITERAL" def mPROTOBUF_TYPE_LITERAL(self, ): try: _type = PROTOBUF_TYPE_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:90:3: ( DOUBLE_PROTOBUF_TYPE_LITERAL | FLOAT_PROTOBUF_TYPE_LITERAL | INT32_PROTOBUF_TYPE_LITERAL | INT64_PROTOBUF_TYPE_LITERAL | UINT32_PROTOBUF_TYPE_LITERAL | UINT64_PROTOBUF_TYPE_LITERAL | SINT32_PROTOBUF_TYPE_LITERAL | SINT64_PROTOBUF_TYPE_LITERAL | FIXED32_PROTOBUF_TYPE_LITERAL | FIXED64_PROTOBUF_TYPE_LITERAL | SFIXED32_PROTOBUF_TYPE_LITERAL | SFIXED64_PROTOBUF_TYPE_LITERAL | BOOL_PROTOBUF_TYPE_LITERAL | STRING_PROTOBUF_TYPE_LITERAL | BYTES_PROTOBUF_TYPE_LITERAL ) alt7 = 15 alt7 = self.dfa7.predict(self.input) if alt7 == 1: # proto_lexer.g:90:6: DOUBLE_PROTOBUF_TYPE_LITERAL pass self.mDOUBLE_PROTOBUF_TYPE_LITERAL() elif alt7 == 2: # proto_lexer.g:91:6: FLOAT_PROTOBUF_TYPE_LITERAL pass self.mFLOAT_PROTOBUF_TYPE_LITERAL() elif alt7 == 3: # proto_lexer.g:92:6: INT32_PROTOBUF_TYPE_LITERAL pass self.mINT32_PROTOBUF_TYPE_LITERAL() elif alt7 == 4: # proto_lexer.g:93:6: INT64_PROTOBUF_TYPE_LITERAL pass self.mINT64_PROTOBUF_TYPE_LITERAL() elif alt7 == 5: # proto_lexer.g:94:6: UINT32_PROTOBUF_TYPE_LITERAL pass self.mUINT32_PROTOBUF_TYPE_LITERAL() elif alt7 == 6: # proto_lexer.g:95:6: UINT64_PROTOBUF_TYPE_LITERAL pass self.mUINT64_PROTOBUF_TYPE_LITERAL() elif alt7 == 7: # proto_lexer.g:96:6: SINT32_PROTOBUF_TYPE_LITERAL pass self.mSINT32_PROTOBUF_TYPE_LITERAL() elif alt7 == 8: # proto_lexer.g:97:6: SINT64_PROTOBUF_TYPE_LITERAL pass self.mSINT64_PROTOBUF_TYPE_LITERAL() elif alt7 == 9: # proto_lexer.g:98:6: FIXED32_PROTOBUF_TYPE_LITERAL pass self.mFIXED32_PROTOBUF_TYPE_LITERAL() elif alt7 == 10: # proto_lexer.g:99:6: FIXED64_PROTOBUF_TYPE_LITERAL pass self.mFIXED64_PROTOBUF_TYPE_LITERAL() elif alt7 == 11: # proto_lexer.g:100:6: SFIXED32_PROTOBUF_TYPE_LITERAL pass self.mSFIXED32_PROTOBUF_TYPE_LITERAL() elif alt7 == 12: # proto_lexer.g:101:6: SFIXED64_PROTOBUF_TYPE_LITERAL pass self.mSFIXED64_PROTOBUF_TYPE_LITERAL() elif alt7 == 13: # proto_lexer.g:102:6: BOOL_PROTOBUF_TYPE_LITERAL pass self.mBOOL_PROTOBUF_TYPE_LITERAL() elif alt7 == 14: # proto_lexer.g:103:6: STRING_PROTOBUF_TYPE_LITERAL pass self.mSTRING_PROTOBUF_TYPE_LITERAL() elif alt7 == 15: # proto_lexer.g:104:6: BYTES_PROTOBUF_TYPE_LITERAL pass self.mBYTES_PROTOBUF_TYPE_LITERAL() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PROTOBUF_TYPE_LITERAL" # $ANTLR start "DOUBLE_PROTOBUF_TYPE_LITERAL" def mDOUBLE_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:107:39: ( 'double' ) # proto_lexer.g:107:41: 'double' pass self.match("double") finally: pass # $ANTLR end "DOUBLE_PROTOBUF_TYPE_LITERAL" # $ANTLR start "FLOAT_PROTOBUF_TYPE_LITERAL" def mFLOAT_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:108:38: ( 'float' ) # proto_lexer.g:108:40: 'float' pass self.match("float") finally: pass # $ANTLR end "FLOAT_PROTOBUF_TYPE_LITERAL" # $ANTLR start "INT32_PROTOBUF_TYPE_LITERAL" def mINT32_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:109:38: ( 'int32' ) # proto_lexer.g:109:40: 'int32' pass self.match("int32") finally: pass # $ANTLR end "INT32_PROTOBUF_TYPE_LITERAL" # $ANTLR start "INT64_PROTOBUF_TYPE_LITERAL" def mINT64_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:110:38: ( 'int64' ) # proto_lexer.g:110:40: 'int64' pass self.match("int64") finally: pass # $ANTLR end "INT64_PROTOBUF_TYPE_LITERAL" # $ANTLR start "UINT32_PROTOBUF_TYPE_LITERAL" def mUINT32_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:111:39: ( 'uint32' ) # proto_lexer.g:111:41: 'uint32' pass self.match("uint32") finally: pass # $ANTLR end "UINT32_PROTOBUF_TYPE_LITERAL" # $ANTLR start "UINT64_PROTOBUF_TYPE_LITERAL" def mUINT64_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:112:39: ( 'uint64' ) # proto_lexer.g:112:41: 'uint64' pass self.match("uint64") finally: pass # $ANTLR end "UINT64_PROTOBUF_TYPE_LITERAL" # $ANTLR start "SINT32_PROTOBUF_TYPE_LITERAL" def mSINT32_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:113:39: ( 'sint32' ) # proto_lexer.g:113:41: 'sint32' pass self.match("sint32") finally: pass # $ANTLR end "SINT32_PROTOBUF_TYPE_LITERAL" # $ANTLR start "SINT64_PROTOBUF_TYPE_LITERAL" def mSINT64_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:114:39: ( 'sint64' ) # proto_lexer.g:114:41: 'sint64' pass self.match("sint64") finally: pass # $ANTLR end "SINT64_PROTOBUF_TYPE_LITERAL" # $ANTLR start "FIXED32_PROTOBUF_TYPE_LITERAL" def mFIXED32_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:115:40: ( 'fixed32' ) # proto_lexer.g:115:42: 'fixed32' pass self.match("fixed32") finally: pass # $ANTLR end "FIXED32_PROTOBUF_TYPE_LITERAL" # $ANTLR start "FIXED64_PROTOBUF_TYPE_LITERAL" def mFIXED64_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:116:40: ( 'fixed64' ) # proto_lexer.g:116:42: 'fixed64' pass self.match("fixed64") finally: pass # $ANTLR end "FIXED64_PROTOBUF_TYPE_LITERAL" # $ANTLR start "SFIXED32_PROTOBUF_TYPE_LITERAL" def mSFIXED32_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:117:41: ( 'sfixed32' ) # proto_lexer.g:117:43: 'sfixed32' pass self.match("sfixed32") finally: pass # $ANTLR end "SFIXED32_PROTOBUF_TYPE_LITERAL" # $ANTLR start "SFIXED64_PROTOBUF_TYPE_LITERAL" def mSFIXED64_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:118:41: ( 'sfixed64' ) # proto_lexer.g:118:43: 'sfixed64' pass self.match("sfixed64") finally: pass # $ANTLR end "SFIXED64_PROTOBUF_TYPE_LITERAL" # $ANTLR start "BOOL_PROTOBUF_TYPE_LITERAL" def mBOOL_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:119:37: ( 'bool' ) # proto_lexer.g:119:39: 'bool' pass self.match("bool") finally: pass # $ANTLR end "BOOL_PROTOBUF_TYPE_LITERAL" # $ANTLR start "STRING_PROTOBUF_TYPE_LITERAL" def mSTRING_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:120:39: ( 'string' ) # proto_lexer.g:120:41: 'string' pass self.match("string") finally: pass # $ANTLR end "STRING_PROTOBUF_TYPE_LITERAL" # $ANTLR start "BYTES_PROTOBUF_TYPE_LITERAL" def mBYTES_PROTOBUF_TYPE_LITERAL(self, ): try: # proto_lexer.g:121:38: ( 'bytes' ) # proto_lexer.g:121:40: 'bytes' pass self.match("bytes") finally: pass # $ANTLR end "BYTES_PROTOBUF_TYPE_LITERAL" # $ANTLR start "INTEGER_LITERAL" def mINTEGER_LITERAL(self, ): try: _type = INTEGER_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:126:3: ( HEX_LITERAL | OCTAL_LITERAL | DECIMAL_LITERAL ) alt8 = 3 LA8 = self.input.LA(1) if LA8 == 45: LA8_1 = self.input.LA(2) if (LA8_1 == 48) : LA8_4 = self.input.LA(3) if (LA8_4 == 88 or LA8_4 == 120) : alt8 = 1 elif ((48 <= LA8_4 <= 55)) : alt8 = 2 else: nvae = NoViableAltException("", 8, 4, self.input) raise nvae elif ((49 <= LA8_1 <= 57)) : alt8 = 3 else: nvae = NoViableAltException("", 8, 1, self.input) raise nvae elif LA8 == 48: LA8 = self.input.LA(2) if LA8 == 88 or LA8 == 120: alt8 = 1 elif LA8 == 48 or LA8 == 49 or LA8 == 50 or LA8 == 51 or LA8 == 52 or LA8 == 53 or LA8 == 54 or LA8 == 55: alt8 = 2 else: alt8 = 3 elif LA8 == 49 or LA8 == 50 or LA8 == 51 or LA8 == 52 or LA8 == 53 or LA8 == 54 or LA8 == 55 or LA8 == 56 or LA8 == 57: alt8 = 3 else: nvae = NoViableAltException("", 8, 0, self.input) raise nvae if alt8 == 1: # proto_lexer.g:126:6: HEX_LITERAL pass self.mHEX_LITERAL() elif alt8 == 2: # proto_lexer.g:127:6: OCTAL_LITERAL pass self.mOCTAL_LITERAL() elif alt8 == 3: # proto_lexer.g:128:6: DECIMAL_LITERAL pass self.mDECIMAL_LITERAL() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INTEGER_LITERAL" # $ANTLR start "HEX_DIGIT" def mHEX_DIGIT(self, ): try: # proto_lexer.g:130:20: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) ) # proto_lexer.g:130:22: ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "HEX_DIGIT" # $ANTLR start "HEX_LITERAL" def mHEX_LITERAL(self, ): try: # proto_lexer.g:131:22: ( ( '-' )? '0' ( 'x' | 'X' ) ( HEX_DIGIT )+ ) # proto_lexer.g:131:24: ( '-' )? '0' ( 'x' | 'X' ) ( HEX_DIGIT )+ pass # proto_lexer.g:131:24: ( '-' )? alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == 45) : alt9 = 1 if alt9 == 1: # proto_lexer.g:131:24: '-' pass self.match(45) self.match(48) if self.input.LA(1) == 88 or self.input.LA(1) == 120: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # proto_lexer.g:131:43: ( HEX_DIGIT )+ cnt10 = 0 while True: #loop10 alt10 = 2 LA10_0 = self.input.LA(1) if ((48 <= LA10_0 <= 57) or (65 <= LA10_0 <= 70) or (97 <= LA10_0 <= 102)) : alt10 = 1 if alt10 == 1: # proto_lexer.g:131:43: HEX_DIGIT pass self.mHEX_DIGIT() else: if cnt10 >= 1: break #loop10 eee = EarlyExitException(10, self.input) raise eee cnt10 += 1 finally: pass # $ANTLR end "HEX_LITERAL" # $ANTLR start "OCTAL_LITERAL" def mOCTAL_LITERAL(self, ): try: # proto_lexer.g:132:24: ( ( '-' )? '0' ( '0' .. '7' )+ ) # proto_lexer.g:132:26: ( '-' )? '0' ( '0' .. '7' )+ pass # proto_lexer.g:132:26: ( '-' )? alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == 45) : alt11 = 1 if alt11 == 1: # proto_lexer.g:132:26: '-' pass self.match(45) self.match(48) # proto_lexer.g:132:35: ( '0' .. '7' )+ cnt12 = 0 while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if ((48 <= LA12_0 <= 55)) : alt12 = 1 if alt12 == 1: # proto_lexer.g:132:36: '0' .. '7' pass self.matchRange(48, 55) else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 finally: pass # $ANTLR end "OCTAL_LITERAL" # $ANTLR start "DECIMAL_LITERAL" def mDECIMAL_LITERAL(self, ): try: # proto_lexer.g:133:26: ( ( '0' | ( '-' )? '1' .. '9' ( '0' .. '9' )* ) ) # proto_lexer.g:133:28: ( '0' | ( '-' )? '1' .. '9' ( '0' .. '9' )* ) pass # proto_lexer.g:133:28: ( '0' | ( '-' )? '1' .. '9' ( '0' .. '9' )* ) alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == 48) : alt15 = 1 elif (LA15_0 == 45 or (49 <= LA15_0 <= 57)) : alt15 = 2 else: nvae = NoViableAltException("", 15, 0, self.input) raise nvae if alt15 == 1: # proto_lexer.g:133:29: '0' pass self.match(48) elif alt15 == 2: # proto_lexer.g:133:35: ( '-' )? '1' .. '9' ( '0' .. '9' )* pass # proto_lexer.g:133:35: ( '-' )? alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == 45) : alt13 = 1 if alt13 == 1: # proto_lexer.g:133:35: '-' pass self.match(45) self.matchRange(49, 57) # proto_lexer.g:133:49: ( '0' .. '9' )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if ((48 <= LA14_0 <= 57)) : alt14 = 1 if alt14 == 1: # proto_lexer.g:133:49: '0' .. '9' pass self.matchRange(48, 57) else: break #loop14 finally: pass # $ANTLR end "DECIMAL_LITERAL" # $ANTLR start "STRING_LITERAL" def mSTRING_LITERAL(self, ): try: _type = STRING_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:138:3: ( '\"' STRING_GUTS '\"' ) # proto_lexer.g:138:6: '\"' STRING_GUTS '\"' pass self.match(34) self.mSTRING_GUTS() self.match(34) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING_LITERAL" # $ANTLR start "STRING_GUTS" def mSTRING_GUTS(self, ): try: # proto_lexer.g:140:22: ( ( ESCAPE_SEQUENCE | ~ ( '\\\\' | '\"' | '\\n' | '\\r' ) )* ) # proto_lexer.g:140:24: ( ESCAPE_SEQUENCE | ~ ( '\\\\' | '\"' | '\\n' | '\\r' ) )* pass # proto_lexer.g:140:24: ( ESCAPE_SEQUENCE | ~ ( '\\\\' | '\"' | '\\n' | '\\r' ) )* while True: #loop16 alt16 = 3 LA16_0 = self.input.LA(1) if (LA16_0 == 92) : alt16 = 1 elif ((0 <= LA16_0 <= 9) or (11 <= LA16_0 <= 12) or (14 <= LA16_0 <= 33) or (35 <= LA16_0 <= 91) or (93 <= LA16_0 <= 65535)) : alt16 = 2 if alt16 == 1: # proto_lexer.g:140:26: ESCAPE_SEQUENCE pass self.mESCAPE_SEQUENCE() elif alt16 == 2: # proto_lexer.g:140:44: ~ ( '\\\\' | '\"' | '\\n' | '\\r' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop16 finally: pass # $ANTLR end "STRING_GUTS" # $ANTLR start "ESCAPE_SEQUENCE" def mESCAPE_SEQUENCE(self, ): try: # proto_lexer.g:143:3: ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | OCTAL_ESCAPE | UNICODE_ESCAPE ) alt17 = 3 LA17_0 = self.input.LA(1) if (LA17_0 == 92) : LA17 = self.input.LA(2) if LA17 == 34 or LA17 == 39 or LA17 == 92 or LA17 == 98 or LA17 == 102 or LA17 == 110 or LA17 == 114 or LA17 == 116: alt17 = 1 elif LA17 == 117: alt17 = 3 elif LA17 == 48 or LA17 == 49 or LA17 == 50 or LA17 == 51 or LA17 == 52 or LA17 == 53 or LA17 == 54 or LA17 == 55: alt17 = 2 else: nvae = NoViableAltException("", 17, 1, self.input) raise nvae else: nvae = NoViableAltException("", 17, 0, self.input) raise nvae if alt17 == 1: # proto_lexer.g:143:6: '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) pass self.match(92) if self.input.LA(1) == 34 or self.input.LA(1) == 39 or self.input.LA(1) == 92 or self.input.LA(1) == 98 or self.input.LA(1) == 102 or self.input.LA(1) == 110 or self.input.LA(1) == 114 or self.input.LA(1) == 116: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt17 == 2: # proto_lexer.g:144:6: OCTAL_ESCAPE pass self.mOCTAL_ESCAPE() elif alt17 == 3: # proto_lexer.g:145:6: UNICODE_ESCAPE pass self.mUNICODE_ESCAPE() finally: pass # $ANTLR end "ESCAPE_SEQUENCE" # $ANTLR start "OCTAL_ESCAPE" def mOCTAL_ESCAPE(self, ): try: # proto_lexer.g:149:3: ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ) alt18 = 3 LA18_0 = self.input.LA(1) if (LA18_0 == 92) : LA18_1 = self.input.LA(2) if ((48 <= LA18_1 <= 51)) : LA18_2 = self.input.LA(3) if ((48 <= LA18_2 <= 55)) : LA18_4 = self.input.LA(4) if ((48 <= LA18_4 <= 55)) : alt18 = 1 else: alt18 = 2 else: alt18 = 3 elif ((52 <= LA18_1 <= 55)) : LA18_3 = self.input.LA(3) if ((48 <= LA18_3 <= 55)) : alt18 = 2 else: alt18 = 3 else: nvae = NoViableAltException("", 18, 1, self.input) raise nvae else: nvae = NoViableAltException("", 18, 0, self.input) raise nvae if alt18 == 1: # proto_lexer.g:149:6: '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) pass self.match(92) # proto_lexer.g:149:11: ( '0' .. '3' ) # proto_lexer.g:149:12: '0' .. '3' pass self.matchRange(48, 51) # proto_lexer.g:149:22: ( '0' .. '7' ) # proto_lexer.g:149:23: '0' .. '7' pass self.matchRange(48, 55) # proto_lexer.g:149:33: ( '0' .. '7' ) # proto_lexer.g:149:34: '0' .. '7' pass self.matchRange(48, 55) elif alt18 == 2: # proto_lexer.g:150:6: '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) pass self.match(92) # proto_lexer.g:150:11: ( '0' .. '7' ) # proto_lexer.g:150:12: '0' .. '7' pass self.matchRange(48, 55) # proto_lexer.g:150:22: ( '0' .. '7' ) # proto_lexer.g:150:23: '0' .. '7' pass self.matchRange(48, 55) elif alt18 == 3: # proto_lexer.g:151:6: '\\\\' ( '0' .. '7' ) pass self.match(92) # proto_lexer.g:151:11: ( '0' .. '7' ) # proto_lexer.g:151:12: '0' .. '7' pass self.matchRange(48, 55) finally: pass # $ANTLR end "OCTAL_ESCAPE" # $ANTLR start "UNICODE_ESCAPE" def mUNICODE_ESCAPE(self, ): try: # proto_lexer.g:155:3: ( '\\\\' 'u' HEX_DIGIT HEX_DIGIT HEX_DIGIT HEX_DIGIT ) # proto_lexer.g:155:6: '\\\\' 'u' HEX_DIGIT HEX_DIGIT HEX_DIGIT HEX_DIGIT pass self.match(92) self.match(117) self.mHEX_DIGIT() self.mHEX_DIGIT() self.mHEX_DIGIT() self.mHEX_DIGIT() finally: pass # $ANTLR end "UNICODE_ESCAPE" # $ANTLR start "BOOL_LITERAL" def mBOOL_LITERAL(self, ): try: _type = BOOL_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:160:14: ( 'true' | 'false' ) alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == 116) : alt19 = 1 elif (LA19_0 == 102) : alt19 = 2 else: nvae = NoViableAltException("", 19, 0, self.input) raise nvae if alt19 == 1: # proto_lexer.g:160:16: 'true' pass self.match("true") elif alt19 == 2: # proto_lexer.g:160:25: 'false' pass self.match("false") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BOOL_LITERAL" # $ANTLR start "FLOAT_LITERAL" def mFLOAT_LITERAL(self, ): try: _type = FLOAT_LITERAL _channel = DEFAULT_CHANNEL # proto_lexer.g:165:3: ( ( '-' )? ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( EXPONENT )? | ( '-' )? '.' ( '0' .. '9' )+ ( EXPONENT )? | ( '-' )? ( '0' .. '9' )+ EXPONENT ) alt29 = 3 alt29 = self.dfa29.predict(self.input) if alt29 == 1: # proto_lexer.g:165:6: ( '-' )? ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( EXPONENT )? pass # proto_lexer.g:165:6: ( '-' )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == 45) : alt20 = 1 if alt20 == 1: # proto_lexer.g:165:6: '-' pass self.match(45) # proto_lexer.g:165:11: ( '0' .. '9' )+ cnt21 = 0 while True: #loop21 alt21 = 2 LA21_0 = self.input.LA(1) if ((48 <= LA21_0 <= 57)) : alt21 = 1 if alt21 == 1: # proto_lexer.g:165:12: '0' .. '9' pass self.matchRange(48, 57) else: if cnt21 >= 1: break #loop21 eee = EarlyExitException(21, self.input) raise eee cnt21 += 1 self.match(46) # proto_lexer.g:165:27: ( '0' .. '9' )* while True: #loop22 alt22 = 2 LA22_0 = self.input.LA(1) if ((48 <= LA22_0 <= 57)) : alt22 = 1 if alt22 == 1: # proto_lexer.g:165:28: '0' .. '9' pass self.matchRange(48, 57) else: break #loop22 # proto_lexer.g:165:39: ( EXPONENT )? alt23 = 2 LA23_0 = self.input.LA(1) if (LA23_0 == 69 or LA23_0 == 101) : alt23 = 1 if alt23 == 1: # proto_lexer.g:165:39: EXPONENT pass self.mEXPONENT() elif alt29 == 2: # proto_lexer.g:166:6: ( '-' )? '.' ( '0' .. '9' )+ ( EXPONENT )? pass # proto_lexer.g:166:6: ( '-' )? alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == 45) : alt24 = 1 if alt24 == 1: # proto_lexer.g:166:6: '-' pass self.match(45) self.match(46) # proto_lexer.g:166:15: ( '0' .. '9' )+ cnt25 = 0 while True: #loop25 alt25 = 2 LA25_0 = self.input.LA(1) if ((48 <= LA25_0 <= 57)) : alt25 = 1 if alt25 == 1: # proto_lexer.g:166:16: '0' .. '9' pass self.matchRange(48, 57) else: if cnt25 >= 1: break #loop25 eee = EarlyExitException(25, self.input) raise eee cnt25 += 1 # proto_lexer.g:166:27: ( EXPONENT )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == 69 or LA26_0 == 101) : alt26 = 1 if alt26 == 1: # proto_lexer.g:166:27: EXPONENT pass self.mEXPONENT() elif alt29 == 3: # proto_lexer.g:167:6: ( '-' )? ( '0' .. '9' )+ EXPONENT pass # proto_lexer.g:167:6: ( '-' )? alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == 45) : alt27 = 1 if alt27 == 1: # proto_lexer.g:167:6: '-' pass self.match(45) # proto_lexer.g:167:11: ( '0' .. '9' )+ cnt28 = 0 while True: #loop28 alt28 = 2 LA28_0 = self.input.LA(1) if ((48 <= LA28_0 <= 57)) : alt28 = 1 if alt28 == 1: # proto_lexer.g:167:12: '0' .. '9' pass self.matchRange(48, 57) else: if cnt28 >= 1: break #loop28 eee = EarlyExitException(28, self.input) raise eee cnt28 += 1 self.mEXPONENT() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FLOAT_LITERAL" # $ANTLR start "EXPONENT" def mEXPONENT(self, ): try: # proto_lexer.g:170:19: ( ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ ) # proto_lexer.g:170:21: ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ pass if self.input.LA(1) == 69 or self.input.LA(1) == 101: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # proto_lexer.g:170:31: ( '+' | '-' )? alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == 43 or LA30_0 == 45) : alt30 = 1 if alt30 == 1: # proto_lexer.g: pass if self.input.LA(1) == 43 or self.input.LA(1) == 45: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # proto_lexer.g:170:42: ( '0' .. '9' )+ cnt31 = 0 while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if ((48 <= LA31_0 <= 57)) : alt31 = 1 if alt31 == 1: # proto_lexer.g:170:43: '0' .. '9' pass self.matchRange(48, 57) else: if cnt31 >= 1: break #loop31 eee = EarlyExitException(31, self.input) raise eee cnt31 += 1 finally: pass # $ANTLR end "EXPONENT" # $ANTLR start "IDENTIFIER" def mIDENTIFIER(self, ): try: _type = IDENTIFIER _channel = DEFAULT_CHANNEL # proto_lexer.g:173:12: ( ( '_' )* ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* ) # proto_lexer.g:173:14: ( '_' )* ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* pass # proto_lexer.g:173:14: ( '_' )* while True: #loop32 alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == 95) : alt32 = 1 if alt32 == 1: # proto_lexer.g:173:14: '_' pass self.match(95) else: break #loop32 if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # proto_lexer.g:173:42: ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '0' .. '9' )* while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if ((48 <= LA33_0 <= 57) or (65 <= LA33_0 <= 90) or LA33_0 == 95 or (97 <= LA33_0 <= 122)) : alt33 = 1 if alt33 == 1: # proto_lexer.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop33 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IDENTIFIER" # $ANTLR start "QUALIFIED_IDENTIFIER" def mQUALIFIED_IDENTIFIER(self, ): try: _type = QUALIFIED_IDENTIFIER _channel = DEFAULT_CHANNEL # proto_lexer.g:174:22: ( IDENTIFIER ( '.' IDENTIFIER )+ ) # proto_lexer.g:174:24: IDENTIFIER ( '.' IDENTIFIER )+ pass self.mIDENTIFIER() # proto_lexer.g:174:35: ( '.' IDENTIFIER )+ cnt34 = 0 while True: #loop34 alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == 46) : alt34 = 1 if alt34 == 1: # proto_lexer.g:174:36: '.' IDENTIFIER pass self.match(46) self.mIDENTIFIER() else: if cnt34 >= 1: break #loop34 eee = EarlyExitException(34, self.input) raise eee cnt34 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "QUALIFIED_IDENTIFIER" # $ANTLR start "FIELD_IDENTIFIER" def mFIELD_IDENTIFIER(self, ): try: _type = FIELD_IDENTIFIER _channel = DEFAULT_CHANNEL # proto_lexer.g:175:18: ( '.' IDENTIFIER ) # proto_lexer.g:175:20: '.' IDENTIFIER pass self.match(46) self.mIDENTIFIER() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FIELD_IDENTIFIER" def mTokens(self): # proto_lexer.g:1:8: ( COMMENT | WHITESPACE | PACKAGE_LITERAL | IMPORT_LITERAL | OPTION_LITERAL | ENUM_LITERAL | MESSAGE_LITERAL | EXTEND_LITERAL | EXTENSIONS_DEF_LITERAL | EXTENSIONS_TO_LITERAL | EXTENSIONS_MAX_LITERAL | SERVICE_LITERAL | RETURNS_LITERAL | RPC_LITERAL | BLOCK_OPEN | BLOCK_CLOSE | PAREN_OPEN | PAREN_CLOSE | BRACKET_OPEN | BRACKET_CLOSE | EQUALS | COLON | COMMA | ITEM_TERMINATOR | PROTOBUF_SCOPE_LITERAL | PROTOBUF_TYPE_LITERAL | INTEGER_LITERAL | STRING_LITERAL | BOOL_LITERAL | FLOAT_LITERAL | IDENTIFIER | QUALIFIED_IDENTIFIER | FIELD_IDENTIFIER ) alt35 = 33 alt35 = self.dfa35.predict(self.input) if alt35 == 1: # proto_lexer.g:1:10: COMMENT pass self.mCOMMENT() elif alt35 == 2: # proto_lexer.g:1:18: WHITESPACE pass self.mWHITESPACE() elif alt35 == 3: # proto_lexer.g:1:29: PACKAGE_LITERAL pass self.mPACKAGE_LITERAL() elif alt35 == 4: # proto_lexer.g:1:45: IMPORT_LITERAL pass self.mIMPORT_LITERAL() elif alt35 == 5: # proto_lexer.g:1:60: OPTION_LITERAL pass self.mOPTION_LITERAL() elif alt35 == 6: # proto_lexer.g:1:75: ENUM_LITERAL pass self.mENUM_LITERAL() elif alt35 == 7: # proto_lexer.g:1:88: MESSAGE_LITERAL pass self.mMESSAGE_LITERAL() elif alt35 == 8: # proto_lexer.g:1:104: EXTEND_LITERAL pass self.mEXTEND_LITERAL() elif alt35 == 9: # proto_lexer.g:1:119: EXTENSIONS_DEF_LITERAL pass self.mEXTENSIONS_DEF_LITERAL() elif alt35 == 10: # proto_lexer.g:1:142: EXTENSIONS_TO_LITERAL pass self.mEXTENSIONS_TO_LITERAL() elif alt35 == 11: # proto_lexer.g:1:164: EXTENSIONS_MAX_LITERAL pass self.mEXTENSIONS_MAX_LITERAL() elif alt35 == 12: # proto_lexer.g:1:187: SERVICE_LITERAL pass self.mSERVICE_LITERAL() elif alt35 == 13: # proto_lexer.g:1:203: RETURNS_LITERAL pass self.mRETURNS_LITERAL() elif alt35 == 14: # proto_lexer.g:1:219: RPC_LITERAL pass self.mRPC_LITERAL() elif alt35 == 15: # proto_lexer.g:1:231: BLOCK_OPEN pass self.mBLOCK_OPEN() elif alt35 == 16: # proto_lexer.g:1:242: BLOCK_CLOSE pass self.mBLOCK_CLOSE() elif alt35 == 17: # proto_lexer.g:1:254: PAREN_OPEN pass self.mPAREN_OPEN() elif alt35 == 18: # proto_lexer.g:1:265: PAREN_CLOSE pass self.mPAREN_CLOSE() elif alt35 == 19: # proto_lexer.g:1:277: BRACKET_OPEN pass self.mBRACKET_OPEN() elif alt35 == 20: # proto_lexer.g:1:290: BRACKET_CLOSE pass self.mBRACKET_CLOSE() elif alt35 == 21: # proto_lexer.g:1:304: EQUALS pass self.mEQUALS() elif alt35 == 22: # proto_lexer.g:1:311: COLON pass self.mCOLON() elif alt35 == 23: # proto_lexer.g:1:317: COMMA pass self.mCOMMA() elif alt35 == 24: # proto_lexer.g:1:323: ITEM_TERMINATOR pass self.mITEM_TERMINATOR() elif alt35 == 25: # proto_lexer.g:1:339: PROTOBUF_SCOPE_LITERAL pass self.mPROTOBUF_SCOPE_LITERAL() elif alt35 == 26: # proto_lexer.g:1:362: PROTOBUF_TYPE_LITERAL pass self.mPROTOBUF_TYPE_LITERAL() elif alt35 == 27: # proto_lexer.g:1:384: INTEGER_LITERAL pass self.mINTEGER_LITERAL() elif alt35 == 28: # proto_lexer.g:1:400: STRING_LITERAL pass self.mSTRING_LITERAL() elif alt35 == 29: # proto_lexer.g:1:415: BOOL_LITERAL pass self.mBOOL_LITERAL() elif alt35 == 30: # proto_lexer.g:1:428: FLOAT_LITERAL pass self.mFLOAT_LITERAL() elif alt35 == 31: # proto_lexer.g:1:442: IDENTIFIER pass self.mIDENTIFIER() elif alt35 == 32: # proto_lexer.g:1:453: QUALIFIED_IDENTIFIER pass self.mQUALIFIED_IDENTIFIER() elif alt35 == 33: # proto_lexer.g:1:474: FIELD_IDENTIFIER pass self.mFIELD_IDENTIFIER() # lookup tables for DFA #7 DFA7_eot = DFA.unpack( u"\46\uffff" ) DFA7_eof = DFA.unpack( u"\46\uffff" ) DFA7_min = DFA.unpack( u"\1\142\1\uffff\1\151\1\156\1\151\1\146\1\157\1\uffff\1\170\1\164" u"\2\156\1\151\3\uffff\1\145\1\63\2\164\1\170\1\144\2\uffff\2\63" u"\1\145\1\63\4\uffff\1\144\2\uffff\1\63\2\uffff" ) DFA7_max = DFA.unpack( u"\1\165\1\uffff\1\154\1\156\1\151\1\164\1\171\1\uffff\1\170\1\164" u"\2\156\1\151\3\uffff\1\145\1\66\2\164\1\170\1\144\2\uffff\2\66" u"\1\145\1\66\4\uffff\1\144\2\uffff\1\66\2\uffff" ) DFA7_accept = DFA.unpack( u"\1\uffff\1\1\5\uffff\1\2\5\uffff\1\16\1\15\1\17\6\uffff\1\3\1\4" u"\4\uffff\1\5\1\6\1\7\1\10\1\uffff\1\11\1\12\1\uffff\1\13\1\14" ) DFA7_special = DFA.unpack( u"\46\uffff" ) DFA7_transition = [ DFA.unpack(u"\1\6\1\uffff\1\1\1\uffff\1\2\2\uffff\1\3\11\uffff\1" u"\5\1\uffff\1\4"), DFA.unpack(u""), DFA.unpack(u"\1\10\2\uffff\1\7"), DFA.unpack(u"\1\11"), DFA.unpack(u"\1\12"), DFA.unpack(u"\1\14\2\uffff\1\13\12\uffff\1\15"), DFA.unpack(u"\1\16\11\uffff\1\17"), DFA.unpack(u""), DFA.unpack(u"\1\20"), DFA.unpack(u"\1\21"), DFA.unpack(u"\1\22"), DFA.unpack(u"\1\23"), DFA.unpack(u"\1\24"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\25"), DFA.unpack(u"\1\26\2\uffff\1\27"), DFA.unpack(u"\1\30"), DFA.unpack(u"\1\31"), DFA.unpack(u"\1\32"), DFA.unpack(u"\1\33"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\34\2\uffff\1\35"), DFA.unpack(u"\1\36\2\uffff\1\37"), DFA.unpack(u"\1\40"), DFA.unpack(u"\1\41\2\uffff\1\42"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\43"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\44\2\uffff\1\45"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #7 class DFA7(DFA): pass # lookup tables for DFA #29 DFA29_eot = DFA.unpack( u"\6\uffff" ) DFA29_eof = DFA.unpack( u"\6\uffff" ) DFA29_min = DFA.unpack( u"\1\55\2\56\3\uffff" ) DFA29_max = DFA.unpack( u"\2\71\1\145\3\uffff" ) DFA29_accept = DFA.unpack( u"\3\uffff\1\2\1\3\1\1" ) DFA29_special = DFA.unpack( u"\6\uffff" ) DFA29_transition = [ DFA.unpack(u"\1\1\1\3\1\uffff\12\2"), DFA.unpack(u"\1\3\1\uffff\12\2"), DFA.unpack(u"\1\5\1\uffff\12\2\13\uffff\1\4\37\uffff\1\4"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #29 class DFA29(DFA): pass # lookup tables for DFA #35 DFA35_eot = DFA.unpack( u"\3\uffff\10\42\12\uffff\4\42\1\uffff\2\74\3\uffff\3\42\2\uffff" u"\7\42\1\110\16\42\3\uffff\2\74\1\uffff\7\42\1\141\1\uffff\10\42" u"\1\152\14\42\1\167\2\42\1\uffff\1\172\7\42\1\uffff\5\42\1\u0089" u"\3\42\2\u0089\1\42\1\uffff\2\42\1\uffff\11\42\1\u0089\1\42\1\172" u"\2\42\1\uffff\1\u0089\1\42\1\u009f\1\u00a1\1\u00a2\3\42\2\u0089" u"\1\42\1\u0089\3\42\1\u0089\2\42\2\u0089\1\u00ad\1\uffff\1\42\2" u"\uffff\1\42\1\u00b0\1\u00b1\2\42\1\u00b4\2\42\2\u0089\1\uffff\1" u"\u00b7\1\42\2\uffff\2\u0089\1\uffff\2\u00b7\1\uffff\1\42\1\u00ba" u"\1\uffff" ) DFA35_eof = DFA.unpack( u"\u00bb\uffff" ) DFA35_min = DFA.unpack( u"\1\11\2\uffff\10\56\12\uffff\7\56\1\uffff\1\60\1\101\3\56\2\uffff" u"\27\56\2\uffff\2\56\1\uffff\10\56\1\uffff\30\56\1\uffff\10\56\1" u"\uffff\14\56\1\uffff\2\56\1\uffff\16\56\1\uffff\25\56\1\uffff\1" u"\56\2\uffff\12\56\1\uffff\2\56\2\uffff\2\56\1\uffff\2\56\1\uffff" u"\2\56\1\uffff" ) DFA35_max = DFA.unpack( u"\1\175\2\uffff\10\172\12\uffff\4\172\1\71\2\145\1\uffff\5\172\2" u"\uffff\26\172\1\170\2\uffff\2\145\1\uffff\10\172\1\uffff\30\172" u"\1\uffff\10\172\1\uffff\14\172\1\uffff\2\172\1\uffff\16\172\1\uffff" u"\25\172\1\uffff\1\172\2\uffff\12\172\1\uffff\2\172\2\uffff\2\172" u"\1\uffff\2\172\1\uffff\2\172\1\uffff" ) DFA35_accept = DFA.unpack( u"\1\uffff\1\1\1\2\10\uffff\1\17\1\20\1\21\1\22\1\23\1\24\1\25\1" u"\26\1\27\1\30\7\uffff\1\34\5\uffff\1\37\1\40\27\uffff\1\36\1\33" u"\2\uffff\1\41\10\uffff\1\12\30\uffff\1\13\10\uffff\1\16\14\uffff" u"\1\6\2\uffff\1\35\16\uffff\1\32\25\uffff\1\4\1\uffff\1\5\1\10\12" u"\uffff\1\3\2\uffff\1\7\1\14\2\uffff\1\15\2\uffff\1\31\2\uffff\1" u"\11" ) DFA35_special = DFA.unpack( u"\u00bb\uffff" ) DFA35_transition = [ DFA.unpack(u"\2\2\1\uffff\2\2\22\uffff\1\2\1\uffff\1\34\5\uffff\1" u"\15\1\16\2\uffff\1\23\1\31\1\35\1\1\1\32\11\33\1\22\1\24\1\uffff" u"\1\21\3\uffff\32\37\1\17\1\uffff\1\20\1\uffff\1\36\1\uffff\1\37" u"\1\30\1\37\1\25\1\6\1\26\2\37\1\4\3\37\1\7\1\37\1\5\1\3\1\37\1" u"\12\1\11\1\10\1\27\5\37\1\13\1\uffff\1\14"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\40\31\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\14\41\1\44\1\45\14\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\17\41\1\46\12\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\15\41\1\47\11\41\1\50\2\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\52\3\41\1\51\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\16\41\1\53\2\41\1\54\10\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\55\1\57\2\41\1\56\12\41\1\60\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\61\12\41\1\62\12\41"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\16\41\1\63\13\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\66\7\41\1\65\2\41\1\64\16\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\10\41\1\67\21\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\16\41\1\70\11\41\1\71\1\41"), DFA.unpack(u"\1\73\1\uffff\1\72\11\33"), DFA.unpack(u"\1\73\1\uffff\10\75\2\73\13\uffff\1\73\37\uffff\1\73"), DFA.unpack(u"\1\73\1\uffff\12\76\13\uffff\1\73\37\uffff\1\73"), DFA.unpack(u""), DFA.unpack(u"\12\73\7\uffff\32\77\4\uffff\1\77\1\uffff\32\77"), DFA.unpack(u"\32\37\4\uffff\1\36\1\uffff\32\37"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\2\41\1\100\27\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\17\41\1\101\12\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\102\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\103\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\24\41\1\104\5\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\105\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\22\41\1\106\7\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\27\41\1\107\2\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\24\41\1\111\5\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\21\41\1\112\10\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\15\41\1\113\14\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\10\41\1\114\21\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\21\41\1\115\10\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\17\41\1\120\1\117\2\41\1\116\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\2\41\1\121\27\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\24\41\1\122\5\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\16\41\1\123\13\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\27\41\1\124\2\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\13\41\1\125\16\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\15\41\1\126\14\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\16\41\1\127\13\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\130\6\41"), DFA.unpack(u"\1\73\1\uffff\10\75\2\73\13\uffff\1\73\22\uffff\1\74" u"\14\uffff\1\73\22\uffff\1\74"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\73\1\uffff\10\75\2\73\13\uffff\1\73\37\uffff\1\73"), DFA.unpack(u"\1\73\1\uffff\12\76\13\uffff\1\73\37\uffff\1\73"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\12\41\1\131\17\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\16\41\1\132\13\41"), DFA.unpack(u"\1\43\1\uffff\3\41\1\133\2\41\1\134\3\41\7\uffff\32" u"\41\4\uffff\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\10\41\1\135\21\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\14\41\1\136\15\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\137\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\22\41\1\140\7\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\142\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\25\41\1\143\4\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\144\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\27\41\1\145\2\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\10\41\1\146\21\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\24\41\1\147\5\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\24\41\1\150\5\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\151\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\41\1\153\30\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\154\31\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\155\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\22\41\1\156\7\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\157\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\13\41\1\160\16\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\161\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\162\31\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\21\41\1\163\10\41"), DFA.unpack(u"\1\43\1\uffff\2\41\1\164\7\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\4\41\1\165\5\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\16\41\1\166\13\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\15\41\1\170\14\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\171\31\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\10\41\1\173\21\41"), DFA.unpack(u"\1\43\1\uffff\3\41\1\174\2\41\1\175\3\41\7\uffff\32" u"\41\4\uffff\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\176\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\15\41\1\177\14\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\21\41\1\u0080\10\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\10\41\1\u0081\21\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\u0082\31\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\13\41\1\u0083\16\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\u0084\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\3\41\1\u0085\26\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\u0086\25\41"), DFA.unpack(u"\1\43\1\uffff\3\41\1\u0087\2\41\1\u0088\3\41\7\uffff" u"\32\41\4\uffff\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\22\41\1\u008a\7\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\6\41\1\u008b\23\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\u008c\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\15\41\1\u008d\14\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\3\41\1\u008e\16\41\1\u008f\7\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\6\41\1\u0090\23\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\2\41\1\u0091\27\41"), DFA.unpack(u"\1\43\1\uffff\2\41\1\u0092\7\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\4\41\1\u0093\5\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\3\41\1\u0094\26\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\6\41\1\u0095\23\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\15\41\1\u0096\14\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\21\41\1\u0097\10\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\23\41\1\u0098\6\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\u0099\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\3\41\1\u009a\2\41\1\u009b\3\41\7\uffff" u"\32\41\4\uffff\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\2\41\1\u009c\7\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\4\41\1\u009d\5\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\u009e\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\1\u00a0\31\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\10\41\1\u00a3\21\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\u00a4\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\u00a5\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\3\41\1\u00a6\2\41\1\u00a7\3\41\7\uffff" u"\32\41\4\uffff\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\22\41\1\u00a8\7\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\u00a9\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\4\41\1\u00aa\25\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\2\41\1\u00ab\7\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\4\41\1\u00ac\5\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\13\41\1\u00ae\16\41"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\16\41\1\u00af\13\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\2\41\1\u00b2\7\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\4\41\1\u00b3\5\41\7\uffff\32\41\4\uffff" u"\1\41\1\uffff\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\3\41\1\u00b5\26\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\3\41\1\u00b6\26\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\15\41\1\u00b8\14\41"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u""), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\22\41\1\u00b9\7\41"), DFA.unpack(u"\1\43\1\uffff\12\41\7\uffff\32\41\4\uffff\1\41\1\uffff" u"\32\41"), DFA.unpack(u"") ] # class definition for DFA #35 class DFA35(DFA): pass def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(proto_lexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "thelinuxkid/python-protolite", "path": "protolite/parser/proto_lexer.py", "copies": "1", "size": "85288", "license": "mit", "hash": -1752709773565619200, "line_mean": 25.49518484, "line_max": 577, "alpha_frac": 0.4569927774, "autogenerated": false, "ratio": 2.9610804430094086, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.3918073220409408, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 proto_parser.g 2013-10-23 04:20:56 import sys from antlr3 import * from antlr3.compat import set, frozenset from antlr3.tree import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EXPONENT=60 MESSAGE_LITERAL=11 REQUIRED_PROTOBUF_SCOPE_LITERAL=29 STRING_GUTS=54 EQUALS=25 UINT32_PROTOBUF_TYPE_LITERAL=37 INT32_PROTOBUF_TYPE_LITERAL=35 EOF=-1 UINT64_PROTOBUF_TYPE_LITERAL=38 ENUM_FIELD=70 ESCAPE_SEQUENCE=56 QUALIFIED_IDENTIFIER=63 FIXED64_PROTOBUF_TYPE_LITERAL=42 UNICODE_ESCAPE=58 STRING_LITERAL=55 FIXED32_PROTOBUF_TYPE_LITERAL=41 PACKAGE_LITERAL=7 COMMA=27 OPTION_CUSTOMIZED=67 IDENTIFIER=62 EXTEND_LITERAL=12 REPEATED_PROTOBUF_SCOPE_LITERAL=31 PROTOBUF_TYPE_LITERAL=48 OPTION_VALUE_ITEM=68 ENUM_LITERAL=10 IMPORT_LITERAL=8 HEX_LITERAL=49 COMMENT=5 FLOAT_PROTOBUF_TYPE_LITERAL=34 BYTES_PROTOBUF_TYPE_LITERAL=47 BLOCK_OPEN=19 SFIXED64_PROTOBUF_TYPE_LITERAL=44 SERVICE_LITERAL=16 PROTOBUF_SCOPE_LITERAL=32 MESSAGE_FIELD=71 END_OF_LINE=4 EXTENSIONS_TO_LITERAL=14 OPTIONAL_PROTOBUF_SCOPE_LITERAL=30 PAREN_CLOSE=22 BOOL_PROTOBUF_TYPE_LITERAL=45 ITEM_TERMINATOR=28 OPTION_VALUE_OBJECT=69 OCTAL_LITERAL=50 EXTENSIONS_MAX_LITERAL=15 OPTION_LITERAL=9 WHITESPACE=6 STRING_PROTOBUF_TYPE_LITERAL=46 HEX_DIGIT=53 OCTAL_ESCAPE=57 BOOL_LITERAL=59 EXTENSIONS_DEF_LITERAL=13 SINT32_PROTOBUF_TYPE_LITERAL=39 COLON=26 FLOAT_LITERAL=61 INT64_PROTOBUF_TYPE_LITERAL=36 BLOCK_CLOSE=20 FIELD_IDENTIFIER=64 INTEGER_LITERAL=52 OPTION_PREDEFINED=66 PAREN_OPEN=21 SFIXED32_PROTOBUF_TYPE_LITERAL=43 DOUBLE_PROTOBUF_TYPE_LITERAL=33 PROTO=65 DECIMAL_LITERAL=51 SINT64_PROTOBUF_TYPE_LITERAL=40 BRACKET_CLOSE=24 RPC_LITERAL=18 BRACKET_OPEN=23 RETURNS_LITERAL=17 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "END_OF_LINE", "COMMENT", "WHITESPACE", "PACKAGE_LITERAL", "IMPORT_LITERAL", "OPTION_LITERAL", "ENUM_LITERAL", "MESSAGE_LITERAL", "EXTEND_LITERAL", "EXTENSIONS_DEF_LITERAL", "EXTENSIONS_TO_LITERAL", "EXTENSIONS_MAX_LITERAL", "SERVICE_LITERAL", "RETURNS_LITERAL", "RPC_LITERAL", "BLOCK_OPEN", "BLOCK_CLOSE", "PAREN_OPEN", "PAREN_CLOSE", "BRACKET_OPEN", "BRACKET_CLOSE", "EQUALS", "COLON", "COMMA", "ITEM_TERMINATOR", "REQUIRED_PROTOBUF_SCOPE_LITERAL", "OPTIONAL_PROTOBUF_SCOPE_LITERAL", "REPEATED_PROTOBUF_SCOPE_LITERAL", "PROTOBUF_SCOPE_LITERAL", "DOUBLE_PROTOBUF_TYPE_LITERAL", "FLOAT_PROTOBUF_TYPE_LITERAL", "INT32_PROTOBUF_TYPE_LITERAL", "INT64_PROTOBUF_TYPE_LITERAL", "UINT32_PROTOBUF_TYPE_LITERAL", "UINT64_PROTOBUF_TYPE_LITERAL", "SINT32_PROTOBUF_TYPE_LITERAL", "SINT64_PROTOBUF_TYPE_LITERAL", "FIXED32_PROTOBUF_TYPE_LITERAL", "FIXED64_PROTOBUF_TYPE_LITERAL", "SFIXED32_PROTOBUF_TYPE_LITERAL", "SFIXED64_PROTOBUF_TYPE_LITERAL", "BOOL_PROTOBUF_TYPE_LITERAL", "STRING_PROTOBUF_TYPE_LITERAL", "BYTES_PROTOBUF_TYPE_LITERAL", "PROTOBUF_TYPE_LITERAL", "HEX_LITERAL", "OCTAL_LITERAL", "DECIMAL_LITERAL", "INTEGER_LITERAL", "HEX_DIGIT", "STRING_GUTS", "STRING_LITERAL", "ESCAPE_SEQUENCE", "OCTAL_ESCAPE", "UNICODE_ESCAPE", "BOOL_LITERAL", "EXPONENT", "FLOAT_LITERAL", "IDENTIFIER", "QUALIFIED_IDENTIFIER", "FIELD_IDENTIFIER", "PROTO", "OPTION_PREDEFINED", "OPTION_CUSTOMIZED", "OPTION_VALUE_ITEM", "OPTION_VALUE_OBJECT", "ENUM_FIELD", "MESSAGE_FIELD" ] class proto_parser(Parser): grammarFileName = "proto_parser.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(proto_parser, self).__init__(input, state, *args, **kwargs) self._adaptor = None self.adaptor = CommonTreeAdaptor() def getTreeAdaptor(self): return self._adaptor def setTreeAdaptor(self, adaptor): self._adaptor = adaptor adaptor = property(getTreeAdaptor, setTreeAdaptor) class all_identifier_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.all_identifier_return, self).__init__() self.tree = None # $ANTLR start "all_identifier" # proto_parser.g:22:1: all_identifier : ( IDENTIFIER | QUALIFIED_IDENTIFIER ); def all_identifier(self, ): retval = self.all_identifier_return() retval.start = self.input.LT(1) root_0 = None set1 = None set1_tree = None try: try: # proto_parser.g:23:3: ( IDENTIFIER | QUALIFIED_IDENTIFIER ) # proto_parser.g: pass root_0 = self._adaptor.nil() set1 = self.input.LT(1) if (IDENTIFIER <= self.input.LA(1) <= QUALIFIED_IDENTIFIER): self.input.consume() self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set1)) self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "all_identifier" class all_value_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.all_value_return, self).__init__() self.tree = None # $ANTLR start "all_value" # proto_parser.g:27:1: all_value : ( IDENTIFIER | literal_value ); def all_value(self, ): retval = self.all_value_return() retval.start = self.input.LT(1) root_0 = None IDENTIFIER2 = None literal_value3 = None IDENTIFIER2_tree = None try: try: # proto_parser.g:28:3: ( IDENTIFIER | literal_value ) alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == IDENTIFIER) : alt1 = 1 elif (LA1_0 == INTEGER_LITERAL or LA1_0 == STRING_LITERAL or LA1_0 == BOOL_LITERAL or LA1_0 == FLOAT_LITERAL) : alt1 = 2 else: nvae = NoViableAltException("", 1, 0, self.input) raise nvae if alt1 == 1: # proto_parser.g:28:6: IDENTIFIER pass root_0 = self._adaptor.nil() IDENTIFIER2=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_all_value129) IDENTIFIER2_tree = self._adaptor.createWithPayload(IDENTIFIER2) self._adaptor.addChild(root_0, IDENTIFIER2_tree) elif alt1 == 2: # proto_parser.g:29:6: literal_value pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_literal_value_in_all_value136) literal_value3 = self.literal_value() self._state.following.pop() self._adaptor.addChild(root_0, literal_value3.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "all_value" class literal_value_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.literal_value_return, self).__init__() self.tree = None # $ANTLR start "literal_value" # proto_parser.g:32:1: literal_value : ( INTEGER_LITERAL | STRING_LITERAL | BOOL_LITERAL | FLOAT_LITERAL ); def literal_value(self, ): retval = self.literal_value_return() retval.start = self.input.LT(1) root_0 = None set4 = None set4_tree = None try: try: # proto_parser.g:33:3: ( INTEGER_LITERAL | STRING_LITERAL | BOOL_LITERAL | FLOAT_LITERAL ) # proto_parser.g: pass root_0 = self._adaptor.nil() set4 = self.input.LT(1) if self.input.LA(1) == INTEGER_LITERAL or self.input.LA(1) == STRING_LITERAL or self.input.LA(1) == BOOL_LITERAL or self.input.LA(1) == FLOAT_LITERAL: self.input.consume() self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set4)) self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "literal_value" class proto_type_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.proto_type_return, self).__init__() self.tree = None # $ANTLR start "proto_type" # proto_parser.g:39:1: proto_type : ( PROTOBUF_TYPE_LITERAL | all_identifier ); def proto_type(self, ): retval = self.proto_type_return() retval.start = self.input.LT(1) root_0 = None PROTOBUF_TYPE_LITERAL5 = None all_identifier6 = None PROTOBUF_TYPE_LITERAL5_tree = None try: try: # proto_parser.g:40:3: ( PROTOBUF_TYPE_LITERAL | all_identifier ) alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == PROTOBUF_TYPE_LITERAL) : alt2 = 1 elif ((IDENTIFIER <= LA2_0 <= QUALIFIED_IDENTIFIER)) : alt2 = 2 else: nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # proto_parser.g:40:6: PROTOBUF_TYPE_LITERAL pass root_0 = self._adaptor.nil() PROTOBUF_TYPE_LITERAL5=self.match(self.input, PROTOBUF_TYPE_LITERAL, self.FOLLOW_PROTOBUF_TYPE_LITERAL_in_proto_type185) PROTOBUF_TYPE_LITERAL5_tree = self._adaptor.createWithPayload(PROTOBUF_TYPE_LITERAL5) self._adaptor.addChild(root_0, PROTOBUF_TYPE_LITERAL5_tree) elif alt2 == 2: # proto_parser.g:41:6: all_identifier pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_all_identifier_in_proto_type192) all_identifier6 = self.all_identifier() self._state.following.pop() self._adaptor.addChild(root_0, all_identifier6.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "proto_type" class proto_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.proto_return, self).__init__() self.tree = None # $ANTLR start "proto" # proto_parser.g:45:1: proto : ( package_def | import_def | option_line_def | enum_def | ext_def | message_def | service_def )* EOF -> ^( PROTO ( package_def )* ( import_def )* ( option_line_def )* ( enum_def )* ( ext_def )* ( message_def )* ( service_def )* ) ; def proto(self, ): retval = self.proto_return() retval.start = self.input.LT(1) root_0 = None EOF14 = None package_def7 = None import_def8 = None option_line_def9 = None enum_def10 = None ext_def11 = None message_def12 = None service_def13 = None EOF14_tree = None stream_EOF = RewriteRuleTokenStream(self._adaptor, "token EOF") stream_enum_def = RewriteRuleSubtreeStream(self._adaptor, "rule enum_def") stream_message_def = RewriteRuleSubtreeStream(self._adaptor, "rule message_def") stream_import_def = RewriteRuleSubtreeStream(self._adaptor, "rule import_def") stream_service_def = RewriteRuleSubtreeStream(self._adaptor, "rule service_def") stream_ext_def = RewriteRuleSubtreeStream(self._adaptor, "rule ext_def") stream_option_line_def = RewriteRuleSubtreeStream(self._adaptor, "rule option_line_def") stream_package_def = RewriteRuleSubtreeStream(self._adaptor, "rule package_def") try: try: # proto_parser.g:46:3: ( ( package_def | import_def | option_line_def | enum_def | ext_def | message_def | service_def )* EOF -> ^( PROTO ( package_def )* ( import_def )* ( option_line_def )* ( enum_def )* ( ext_def )* ( message_def )* ( service_def )* ) ) # proto_parser.g:46:6: ( package_def | import_def | option_line_def | enum_def | ext_def | message_def | service_def )* EOF pass # proto_parser.g:46:6: ( package_def | import_def | option_line_def | enum_def | ext_def | message_def | service_def )* while True: #loop3 alt3 = 8 LA3 = self.input.LA(1) if LA3 == PACKAGE_LITERAL: alt3 = 1 elif LA3 == IMPORT_LITERAL: alt3 = 2 elif LA3 == OPTION_LITERAL: alt3 = 3 elif LA3 == ENUM_LITERAL: alt3 = 4 elif LA3 == EXTEND_LITERAL: alt3 = 5 elif LA3 == MESSAGE_LITERAL: alt3 = 6 elif LA3 == SERVICE_LITERAL: alt3 = 7 if alt3 == 1: # proto_parser.g:46:7: package_def pass self._state.following.append(self.FOLLOW_package_def_in_proto208) package_def7 = self.package_def() self._state.following.pop() stream_package_def.add(package_def7.tree) elif alt3 == 2: # proto_parser.g:46:21: import_def pass self._state.following.append(self.FOLLOW_import_def_in_proto212) import_def8 = self.import_def() self._state.following.pop() stream_import_def.add(import_def8.tree) elif alt3 == 3: # proto_parser.g:46:34: option_line_def pass self._state.following.append(self.FOLLOW_option_line_def_in_proto216) option_line_def9 = self.option_line_def() self._state.following.pop() stream_option_line_def.add(option_line_def9.tree) elif alt3 == 4: # proto_parser.g:46:52: enum_def pass self._state.following.append(self.FOLLOW_enum_def_in_proto220) enum_def10 = self.enum_def() self._state.following.pop() stream_enum_def.add(enum_def10.tree) elif alt3 == 5: # proto_parser.g:46:63: ext_def pass self._state.following.append(self.FOLLOW_ext_def_in_proto224) ext_def11 = self.ext_def() self._state.following.pop() stream_ext_def.add(ext_def11.tree) elif alt3 == 6: # proto_parser.g:46:73: message_def pass self._state.following.append(self.FOLLOW_message_def_in_proto228) message_def12 = self.message_def() self._state.following.pop() stream_message_def.add(message_def12.tree) elif alt3 == 7: # proto_parser.g:46:87: service_def pass self._state.following.append(self.FOLLOW_service_def_in_proto232) service_def13 = self.service_def() self._state.following.pop() stream_service_def.add(service_def13.tree) else: break #loop3 EOF14=self.match(self.input, EOF, self.FOLLOW_EOF_in_proto236) stream_EOF.add(EOF14) # AST Rewrite # elements: service_def, enum_def, message_def, import_def, option_line_def, ext_def, package_def # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 47:6: -> ^( PROTO ( package_def )* ( import_def )* ( option_line_def )* ( enum_def )* ( ext_def )* ( message_def )* ( service_def )* ) # proto_parser.g:47:9: ^( PROTO ( package_def )* ( import_def )* ( option_line_def )* ( enum_def )* ( ext_def )* ( message_def )* ( service_def )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(PROTO, "PROTO"), root_1) # proto_parser.g:47:17: ( package_def )* while stream_package_def.hasNext(): self._adaptor.addChild(root_1, stream_package_def.nextTree()) stream_package_def.reset(); # proto_parser.g:47:30: ( import_def )* while stream_import_def.hasNext(): self._adaptor.addChild(root_1, stream_import_def.nextTree()) stream_import_def.reset(); # proto_parser.g:47:42: ( option_line_def )* while stream_option_line_def.hasNext(): self._adaptor.addChild(root_1, stream_option_line_def.nextTree()) stream_option_line_def.reset(); # proto_parser.g:47:59: ( enum_def )* while stream_enum_def.hasNext(): self._adaptor.addChild(root_1, stream_enum_def.nextTree()) stream_enum_def.reset(); # proto_parser.g:47:69: ( ext_def )* while stream_ext_def.hasNext(): self._adaptor.addChild(root_1, stream_ext_def.nextTree()) stream_ext_def.reset(); # proto_parser.g:47:78: ( message_def )* while stream_message_def.hasNext(): self._adaptor.addChild(root_1, stream_message_def.nextTree()) stream_message_def.reset(); # proto_parser.g:47:91: ( service_def )* while stream_service_def.hasNext(): self._adaptor.addChild(root_1, stream_service_def.nextTree()) stream_service_def.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "proto" class package_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.package_def_return, self).__init__() self.tree = None # $ANTLR start "package_def" # proto_parser.g:52:1: package_def : PACKAGE_LITERAL package_name ITEM_TERMINATOR -> ^( PACKAGE_LITERAL package_name ) ; def package_def(self, ): retval = self.package_def_return() retval.start = self.input.LT(1) root_0 = None PACKAGE_LITERAL15 = None ITEM_TERMINATOR17 = None package_name16 = None PACKAGE_LITERAL15_tree = None ITEM_TERMINATOR17_tree = None stream_PACKAGE_LITERAL = RewriteRuleTokenStream(self._adaptor, "token PACKAGE_LITERAL") stream_ITEM_TERMINATOR = RewriteRuleTokenStream(self._adaptor, "token ITEM_TERMINATOR") stream_package_name = RewriteRuleSubtreeStream(self._adaptor, "rule package_name") try: try: # proto_parser.g:53:3: ( PACKAGE_LITERAL package_name ITEM_TERMINATOR -> ^( PACKAGE_LITERAL package_name ) ) # proto_parser.g:53:6: PACKAGE_LITERAL package_name ITEM_TERMINATOR pass PACKAGE_LITERAL15=self.match(self.input, PACKAGE_LITERAL, self.FOLLOW_PACKAGE_LITERAL_in_package_def286) stream_PACKAGE_LITERAL.add(PACKAGE_LITERAL15) self._state.following.append(self.FOLLOW_package_name_in_package_def288) package_name16 = self.package_name() self._state.following.pop() stream_package_name.add(package_name16.tree) ITEM_TERMINATOR17=self.match(self.input, ITEM_TERMINATOR, self.FOLLOW_ITEM_TERMINATOR_in_package_def290) stream_ITEM_TERMINATOR.add(ITEM_TERMINATOR17) # AST Rewrite # elements: PACKAGE_LITERAL, package_name # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 54:6: -> ^( PACKAGE_LITERAL package_name ) # proto_parser.g:54:9: ^( PACKAGE_LITERAL package_name ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_PACKAGE_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_package_name.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "package_def" class package_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.package_name_return, self).__init__() self.tree = None # $ANTLR start "package_name" # proto_parser.g:57:1: package_name : all_identifier ; def package_name(self, ): retval = self.package_name_return() retval.start = self.input.LT(1) root_0 = None all_identifier18 = None try: try: # proto_parser.g:57:14: ( all_identifier ) # proto_parser.g:57:16: all_identifier pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_all_identifier_in_package_name314) all_identifier18 = self.all_identifier() self._state.following.pop() self._adaptor.addChild(root_0, all_identifier18.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "package_name" class import_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.import_def_return, self).__init__() self.tree = None # $ANTLR start "import_def" # proto_parser.g:61:1: import_def : IMPORT_LITERAL import_file_name ITEM_TERMINATOR -> ^( IMPORT_LITERAL import_file_name ) ; def import_def(self, ): retval = self.import_def_return() retval.start = self.input.LT(1) root_0 = None IMPORT_LITERAL19 = None ITEM_TERMINATOR21 = None import_file_name20 = None IMPORT_LITERAL19_tree = None ITEM_TERMINATOR21_tree = None stream_IMPORT_LITERAL = RewriteRuleTokenStream(self._adaptor, "token IMPORT_LITERAL") stream_ITEM_TERMINATOR = RewriteRuleTokenStream(self._adaptor, "token ITEM_TERMINATOR") stream_import_file_name = RewriteRuleSubtreeStream(self._adaptor, "rule import_file_name") try: try: # proto_parser.g:62:3: ( IMPORT_LITERAL import_file_name ITEM_TERMINATOR -> ^( IMPORT_LITERAL import_file_name ) ) # proto_parser.g:62:6: IMPORT_LITERAL import_file_name ITEM_TERMINATOR pass IMPORT_LITERAL19=self.match(self.input, IMPORT_LITERAL, self.FOLLOW_IMPORT_LITERAL_in_import_def328) stream_IMPORT_LITERAL.add(IMPORT_LITERAL19) self._state.following.append(self.FOLLOW_import_file_name_in_import_def330) import_file_name20 = self.import_file_name() self._state.following.pop() stream_import_file_name.add(import_file_name20.tree) ITEM_TERMINATOR21=self.match(self.input, ITEM_TERMINATOR, self.FOLLOW_ITEM_TERMINATOR_in_import_def332) stream_ITEM_TERMINATOR.add(ITEM_TERMINATOR21) # AST Rewrite # elements: import_file_name, IMPORT_LITERAL # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 63:6: -> ^( IMPORT_LITERAL import_file_name ) # proto_parser.g:63:9: ^( IMPORT_LITERAL import_file_name ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_IMPORT_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_import_file_name.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "import_def" class import_file_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.import_file_name_return, self).__init__() self.tree = None # $ANTLR start "import_file_name" # proto_parser.g:66:1: import_file_name : STRING_LITERAL ; def import_file_name(self, ): retval = self.import_file_name_return() retval.start = self.input.LT(1) root_0 = None STRING_LITERAL22 = None STRING_LITERAL22_tree = None try: try: # proto_parser.g:66:18: ( STRING_LITERAL ) # proto_parser.g:66:20: STRING_LITERAL pass root_0 = self._adaptor.nil() STRING_LITERAL22=self.match(self.input, STRING_LITERAL, self.FOLLOW_STRING_LITERAL_in_import_file_name356) STRING_LITERAL22_tree = self._adaptor.createWithPayload(STRING_LITERAL22) self._adaptor.addChild(root_0, STRING_LITERAL22_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "import_file_name" class option_line_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.option_line_def_return, self).__init__() self.tree = None # $ANTLR start "option_line_def" # proto_parser.g:70:1: option_line_def : OPTION_LITERAL option_name EQUALS option_all_value ITEM_TERMINATOR -> ^( OPTION_LITERAL option_name option_all_value ) ; def option_line_def(self, ): retval = self.option_line_def_return() retval.start = self.input.LT(1) root_0 = None OPTION_LITERAL23 = None EQUALS25 = None ITEM_TERMINATOR27 = None option_name24 = None option_all_value26 = None OPTION_LITERAL23_tree = None EQUALS25_tree = None ITEM_TERMINATOR27_tree = None stream_OPTION_LITERAL = RewriteRuleTokenStream(self._adaptor, "token OPTION_LITERAL") stream_EQUALS = RewriteRuleTokenStream(self._adaptor, "token EQUALS") stream_ITEM_TERMINATOR = RewriteRuleTokenStream(self._adaptor, "token ITEM_TERMINATOR") stream_option_name = RewriteRuleSubtreeStream(self._adaptor, "rule option_name") stream_option_all_value = RewriteRuleSubtreeStream(self._adaptor, "rule option_all_value") try: try: # proto_parser.g:71:3: ( OPTION_LITERAL option_name EQUALS option_all_value ITEM_TERMINATOR -> ^( OPTION_LITERAL option_name option_all_value ) ) # proto_parser.g:71:6: OPTION_LITERAL option_name EQUALS option_all_value ITEM_TERMINATOR pass OPTION_LITERAL23=self.match(self.input, OPTION_LITERAL, self.FOLLOW_OPTION_LITERAL_in_option_line_def370) stream_OPTION_LITERAL.add(OPTION_LITERAL23) self._state.following.append(self.FOLLOW_option_name_in_option_line_def372) option_name24 = self.option_name() self._state.following.pop() stream_option_name.add(option_name24.tree) EQUALS25=self.match(self.input, EQUALS, self.FOLLOW_EQUALS_in_option_line_def374) stream_EQUALS.add(EQUALS25) self._state.following.append(self.FOLLOW_option_all_value_in_option_line_def376) option_all_value26 = self.option_all_value() self._state.following.pop() stream_option_all_value.add(option_all_value26.tree) ITEM_TERMINATOR27=self.match(self.input, ITEM_TERMINATOR, self.FOLLOW_ITEM_TERMINATOR_in_option_line_def378) stream_ITEM_TERMINATOR.add(ITEM_TERMINATOR27) # AST Rewrite # elements: OPTION_LITERAL, option_name, option_all_value # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 72:6: -> ^( OPTION_LITERAL option_name option_all_value ) # proto_parser.g:72:9: ^( OPTION_LITERAL option_name option_all_value ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_OPTION_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_option_name.nextTree()) self._adaptor.addChild(root_1, stream_option_all_value.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "option_line_def" class option_field_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.option_field_def_return, self).__init__() self.tree = None # $ANTLR start "option_field_def" # proto_parser.g:75:1: option_field_def : BRACKET_OPEN option_field_item ( COMMA option_field_item )* BRACKET_CLOSE ; def option_field_def(self, ): retval = self.option_field_def_return() retval.start = self.input.LT(1) root_0 = None BRACKET_OPEN28 = None COMMA30 = None BRACKET_CLOSE32 = None option_field_item29 = None option_field_item31 = None BRACKET_OPEN28_tree = None COMMA30_tree = None BRACKET_CLOSE32_tree = None try: try: # proto_parser.g:76:3: ( BRACKET_OPEN option_field_item ( COMMA option_field_item )* BRACKET_CLOSE ) # proto_parser.g:76:6: BRACKET_OPEN option_field_item ( COMMA option_field_item )* BRACKET_CLOSE pass root_0 = self._adaptor.nil() BRACKET_OPEN28=self.match(self.input, BRACKET_OPEN, self.FOLLOW_BRACKET_OPEN_in_option_field_def407) self._state.following.append(self.FOLLOW_option_field_item_in_option_field_def410) option_field_item29 = self.option_field_item() self._state.following.pop() self._adaptor.addChild(root_0, option_field_item29.tree) # proto_parser.g:76:38: ( COMMA option_field_item )* while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == COMMA) : alt4 = 1 if alt4 == 1: # proto_parser.g:76:39: COMMA option_field_item pass COMMA30=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_option_field_def413) self._state.following.append(self.FOLLOW_option_field_item_in_option_field_def416) option_field_item31 = self.option_field_item() self._state.following.pop() self._adaptor.addChild(root_0, option_field_item31.tree) else: break #loop4 BRACKET_CLOSE32=self.match(self.input, BRACKET_CLOSE, self.FOLLOW_BRACKET_CLOSE_in_option_field_def420) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "option_field_def" class option_field_item_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.option_field_item_return, self).__init__() self.tree = None # $ANTLR start "option_field_item" # proto_parser.g:79:1: option_field_item : option_name EQUALS option_all_value -> ^( OPTION_LITERAL option_name option_all_value ) ; def option_field_item(self, ): retval = self.option_field_item_return() retval.start = self.input.LT(1) root_0 = None EQUALS34 = None option_name33 = None option_all_value35 = None EQUALS34_tree = None stream_EQUALS = RewriteRuleTokenStream(self._adaptor, "token EQUALS") stream_option_name = RewriteRuleSubtreeStream(self._adaptor, "rule option_name") stream_option_all_value = RewriteRuleSubtreeStream(self._adaptor, "rule option_all_value") try: try: # proto_parser.g:80:3: ( option_name EQUALS option_all_value -> ^( OPTION_LITERAL option_name option_all_value ) ) # proto_parser.g:80:6: option_name EQUALS option_all_value pass self._state.following.append(self.FOLLOW_option_name_in_option_field_item435) option_name33 = self.option_name() self._state.following.pop() stream_option_name.add(option_name33.tree) EQUALS34=self.match(self.input, EQUALS, self.FOLLOW_EQUALS_in_option_field_item437) stream_EQUALS.add(EQUALS34) self._state.following.append(self.FOLLOW_option_all_value_in_option_field_item439) option_all_value35 = self.option_all_value() self._state.following.pop() stream_option_all_value.add(option_all_value35.tree) # AST Rewrite # elements: option_all_value, option_name # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 81:6: -> ^( OPTION_LITERAL option_name option_all_value ) # proto_parser.g:81:9: ^( OPTION_LITERAL option_name option_all_value ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(OPTION_LITERAL, "OPTION_LITERAL"), root_1) self._adaptor.addChild(root_1, stream_option_name.nextTree()) self._adaptor.addChild(root_1, stream_option_all_value.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "option_field_item" class option_all_value_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.option_all_value_return, self).__init__() self.tree = None # $ANTLR start "option_all_value" # proto_parser.g:84:1: option_all_value : ( all_value | option_value_object ); def option_all_value(self, ): retval = self.option_all_value_return() retval.start = self.input.LT(1) root_0 = None all_value36 = None option_value_object37 = None try: try: # proto_parser.g:85:3: ( all_value | option_value_object ) alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == INTEGER_LITERAL or LA5_0 == STRING_LITERAL or LA5_0 == BOOL_LITERAL or (FLOAT_LITERAL <= LA5_0 <= IDENTIFIER)) : alt5 = 1 elif (LA5_0 == BLOCK_OPEN) : alt5 = 2 else: nvae = NoViableAltException("", 5, 0, self.input) raise nvae if alt5 == 1: # proto_parser.g:85:5: all_value pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_all_value_in_option_all_value467) all_value36 = self.all_value() self._state.following.pop() self._adaptor.addChild(root_0, all_value36.tree) elif alt5 == 2: # proto_parser.g:86:5: option_value_object pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_option_value_object_in_option_all_value473) option_value_object37 = self.option_value_object() self._state.following.pop() self._adaptor.addChild(root_0, option_value_object37.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "option_all_value" class option_value_object_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.option_value_object_return, self).__init__() self.tree = None # $ANTLR start "option_value_object" # proto_parser.g:89:1: option_value_object : BLOCK_OPEN ( option_value_item )* BLOCK_CLOSE -> ^( OPTION_VALUE_OBJECT ( option_value_item )* ) ; def option_value_object(self, ): retval = self.option_value_object_return() retval.start = self.input.LT(1) root_0 = None BLOCK_OPEN38 = None BLOCK_CLOSE40 = None option_value_item39 = None BLOCK_OPEN38_tree = None BLOCK_CLOSE40_tree = None stream_BLOCK_OPEN = RewriteRuleTokenStream(self._adaptor, "token BLOCK_OPEN") stream_BLOCK_CLOSE = RewriteRuleTokenStream(self._adaptor, "token BLOCK_CLOSE") stream_option_value_item = RewriteRuleSubtreeStream(self._adaptor, "rule option_value_item") try: try: # proto_parser.g:90:3: ( BLOCK_OPEN ( option_value_item )* BLOCK_CLOSE -> ^( OPTION_VALUE_OBJECT ( option_value_item )* ) ) # proto_parser.g:90:6: BLOCK_OPEN ( option_value_item )* BLOCK_CLOSE pass BLOCK_OPEN38=self.match(self.input, BLOCK_OPEN, self.FOLLOW_BLOCK_OPEN_in_option_value_object487) stream_BLOCK_OPEN.add(BLOCK_OPEN38) # proto_parser.g:90:17: ( option_value_item )* while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == IDENTIFIER) : alt6 = 1 if alt6 == 1: # proto_parser.g:90:17: option_value_item pass self._state.following.append(self.FOLLOW_option_value_item_in_option_value_object489) option_value_item39 = self.option_value_item() self._state.following.pop() stream_option_value_item.add(option_value_item39.tree) else: break #loop6 BLOCK_CLOSE40=self.match(self.input, BLOCK_CLOSE, self.FOLLOW_BLOCK_CLOSE_in_option_value_object492) stream_BLOCK_CLOSE.add(BLOCK_CLOSE40) # AST Rewrite # elements: option_value_item # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 91:6: -> ^( OPTION_VALUE_OBJECT ( option_value_item )* ) # proto_parser.g:91:9: ^( OPTION_VALUE_OBJECT ( option_value_item )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(OPTION_VALUE_OBJECT, "OPTION_VALUE_OBJECT"), root_1) # proto_parser.g:91:31: ( option_value_item )* while stream_option_value_item.hasNext(): self._adaptor.addChild(root_1, stream_option_value_item.nextTree()) stream_option_value_item.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "option_value_object" class option_value_item_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.option_value_item_return, self).__init__() self.tree = None # $ANTLR start "option_value_item" # proto_parser.g:94:1: option_value_item : IDENTIFIER COLON option_all_value -> ^( OPTION_VALUE_ITEM IDENTIFIER option_all_value ) ; def option_value_item(self, ): retval = self.option_value_item_return() retval.start = self.input.LT(1) root_0 = None IDENTIFIER41 = None COLON42 = None option_all_value43 = None IDENTIFIER41_tree = None COLON42_tree = None stream_COLON = RewriteRuleTokenStream(self._adaptor, "token COLON") stream_IDENTIFIER = RewriteRuleTokenStream(self._adaptor, "token IDENTIFIER") stream_option_all_value = RewriteRuleSubtreeStream(self._adaptor, "rule option_all_value") try: try: # proto_parser.g:95:3: ( IDENTIFIER COLON option_all_value -> ^( OPTION_VALUE_ITEM IDENTIFIER option_all_value ) ) # proto_parser.g:95:6: IDENTIFIER COLON option_all_value pass IDENTIFIER41=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_option_value_item520) stream_IDENTIFIER.add(IDENTIFIER41) COLON42=self.match(self.input, COLON, self.FOLLOW_COLON_in_option_value_item522) stream_COLON.add(COLON42) self._state.following.append(self.FOLLOW_option_all_value_in_option_value_item524) option_all_value43 = self.option_all_value() self._state.following.pop() stream_option_all_value.add(option_all_value43.tree) # AST Rewrite # elements: option_all_value, IDENTIFIER # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 96:6: -> ^( OPTION_VALUE_ITEM IDENTIFIER option_all_value ) # proto_parser.g:96:9: ^( OPTION_VALUE_ITEM IDENTIFIER option_all_value ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(OPTION_VALUE_ITEM, "OPTION_VALUE_ITEM"), root_1) self._adaptor.addChild(root_1, stream_IDENTIFIER.nextNode()) self._adaptor.addChild(root_1, stream_option_all_value.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "option_value_item" class option_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.option_name_return, self).__init__() self.tree = None # $ANTLR start "option_name" # proto_parser.g:99:1: option_name : ( IDENTIFIER -> ^( OPTION_PREDEFINED IDENTIFIER ) | PAREN_OPEN all_identifier PAREN_CLOSE ( FIELD_IDENTIFIER )* -> ^( OPTION_CUSTOMIZED all_identifier ( FIELD_IDENTIFIER )* ) ); def option_name(self, ): retval = self.option_name_return() retval.start = self.input.LT(1) root_0 = None IDENTIFIER44 = None PAREN_OPEN45 = None PAREN_CLOSE47 = None FIELD_IDENTIFIER48 = None all_identifier46 = None IDENTIFIER44_tree = None PAREN_OPEN45_tree = None PAREN_CLOSE47_tree = None FIELD_IDENTIFIER48_tree = None stream_FIELD_IDENTIFIER = RewriteRuleTokenStream(self._adaptor, "token FIELD_IDENTIFIER") stream_PAREN_OPEN = RewriteRuleTokenStream(self._adaptor, "token PAREN_OPEN") stream_PAREN_CLOSE = RewriteRuleTokenStream(self._adaptor, "token PAREN_CLOSE") stream_IDENTIFIER = RewriteRuleTokenStream(self._adaptor, "token IDENTIFIER") stream_all_identifier = RewriteRuleSubtreeStream(self._adaptor, "rule all_identifier") try: try: # proto_parser.g:100:3: ( IDENTIFIER -> ^( OPTION_PREDEFINED IDENTIFIER ) | PAREN_OPEN all_identifier PAREN_CLOSE ( FIELD_IDENTIFIER )* -> ^( OPTION_CUSTOMIZED all_identifier ( FIELD_IDENTIFIER )* ) ) alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == IDENTIFIER) : alt8 = 1 elif (LA8_0 == PAREN_OPEN) : alt8 = 2 else: nvae = NoViableAltException("", 8, 0, self.input) raise nvae if alt8 == 1: # proto_parser.g:100:6: IDENTIFIER pass IDENTIFIER44=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_option_name553) stream_IDENTIFIER.add(IDENTIFIER44) # AST Rewrite # elements: IDENTIFIER # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 101:6: -> ^( OPTION_PREDEFINED IDENTIFIER ) # proto_parser.g:101:9: ^( OPTION_PREDEFINED IDENTIFIER ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(OPTION_PREDEFINED, "OPTION_PREDEFINED"), root_1) self._adaptor.addChild(root_1, stream_IDENTIFIER.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt8 == 2: # proto_parser.g:102:6: PAREN_OPEN all_identifier PAREN_CLOSE ( FIELD_IDENTIFIER )* pass PAREN_OPEN45=self.match(self.input, PAREN_OPEN, self.FOLLOW_PAREN_OPEN_in_option_name573) stream_PAREN_OPEN.add(PAREN_OPEN45) self._state.following.append(self.FOLLOW_all_identifier_in_option_name575) all_identifier46 = self.all_identifier() self._state.following.pop() stream_all_identifier.add(all_identifier46.tree) PAREN_CLOSE47=self.match(self.input, PAREN_CLOSE, self.FOLLOW_PAREN_CLOSE_in_option_name577) stream_PAREN_CLOSE.add(PAREN_CLOSE47) # proto_parser.g:102:44: ( FIELD_IDENTIFIER )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == FIELD_IDENTIFIER) : alt7 = 1 if alt7 == 1: # proto_parser.g:102:44: FIELD_IDENTIFIER pass FIELD_IDENTIFIER48=self.match(self.input, FIELD_IDENTIFIER, self.FOLLOW_FIELD_IDENTIFIER_in_option_name579) stream_FIELD_IDENTIFIER.add(FIELD_IDENTIFIER48) else: break #loop7 # AST Rewrite # elements: FIELD_IDENTIFIER, all_identifier # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 103:6: -> ^( OPTION_CUSTOMIZED all_identifier ( FIELD_IDENTIFIER )* ) # proto_parser.g:103:9: ^( OPTION_CUSTOMIZED all_identifier ( FIELD_IDENTIFIER )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(OPTION_CUSTOMIZED, "OPTION_CUSTOMIZED"), root_1) self._adaptor.addChild(root_1, stream_all_identifier.nextTree()) # proto_parser.g:103:44: ( FIELD_IDENTIFIER )* while stream_FIELD_IDENTIFIER.hasNext(): self._adaptor.addChild(root_1, stream_FIELD_IDENTIFIER.nextNode()) stream_FIELD_IDENTIFIER.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "option_name" class enum_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.enum_def_return, self).__init__() self.tree = None # $ANTLR start "enum_def" # proto_parser.g:108:1: enum_def : ENUM_LITERAL enum_name BLOCK_OPEN enum_content BLOCK_CLOSE -> ^( ENUM_LITERAL enum_name enum_content ) ; def enum_def(self, ): retval = self.enum_def_return() retval.start = self.input.LT(1) root_0 = None ENUM_LITERAL49 = None BLOCK_OPEN51 = None BLOCK_CLOSE53 = None enum_name50 = None enum_content52 = None ENUM_LITERAL49_tree = None BLOCK_OPEN51_tree = None BLOCK_CLOSE53_tree = None stream_BLOCK_OPEN = RewriteRuleTokenStream(self._adaptor, "token BLOCK_OPEN") stream_ENUM_LITERAL = RewriteRuleTokenStream(self._adaptor, "token ENUM_LITERAL") stream_BLOCK_CLOSE = RewriteRuleTokenStream(self._adaptor, "token BLOCK_CLOSE") stream_enum_name = RewriteRuleSubtreeStream(self._adaptor, "rule enum_name") stream_enum_content = RewriteRuleSubtreeStream(self._adaptor, "rule enum_content") try: try: # proto_parser.g:109:3: ( ENUM_LITERAL enum_name BLOCK_OPEN enum_content BLOCK_CLOSE -> ^( ENUM_LITERAL enum_name enum_content ) ) # proto_parser.g:109:6: ENUM_LITERAL enum_name BLOCK_OPEN enum_content BLOCK_CLOSE pass ENUM_LITERAL49=self.match(self.input, ENUM_LITERAL, self.FOLLOW_ENUM_LITERAL_in_enum_def612) stream_ENUM_LITERAL.add(ENUM_LITERAL49) self._state.following.append(self.FOLLOW_enum_name_in_enum_def614) enum_name50 = self.enum_name() self._state.following.pop() stream_enum_name.add(enum_name50.tree) BLOCK_OPEN51=self.match(self.input, BLOCK_OPEN, self.FOLLOW_BLOCK_OPEN_in_enum_def616) stream_BLOCK_OPEN.add(BLOCK_OPEN51) self._state.following.append(self.FOLLOW_enum_content_in_enum_def618) enum_content52 = self.enum_content() self._state.following.pop() stream_enum_content.add(enum_content52.tree) BLOCK_CLOSE53=self.match(self.input, BLOCK_CLOSE, self.FOLLOW_BLOCK_CLOSE_in_enum_def620) stream_BLOCK_CLOSE.add(BLOCK_CLOSE53) # AST Rewrite # elements: enum_name, enum_content, ENUM_LITERAL # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 110:6: -> ^( ENUM_LITERAL enum_name enum_content ) # proto_parser.g:110:9: ^( ENUM_LITERAL enum_name enum_content ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_ENUM_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_enum_name.nextTree()) self._adaptor.addChild(root_1, stream_enum_content.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "enum_def" class enum_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.enum_name_return, self).__init__() self.tree = None # $ANTLR start "enum_name" # proto_parser.g:113:1: enum_name : IDENTIFIER ; def enum_name(self, ): retval = self.enum_name_return() retval.start = self.input.LT(1) root_0 = None IDENTIFIER54 = None IDENTIFIER54_tree = None try: try: # proto_parser.g:113:11: ( IDENTIFIER ) # proto_parser.g:113:13: IDENTIFIER pass root_0 = self._adaptor.nil() IDENTIFIER54=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enum_name646) IDENTIFIER54_tree = self._adaptor.createWithPayload(IDENTIFIER54) self._adaptor.addChild(root_0, IDENTIFIER54_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "enum_name" class enum_content_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.enum_content_return, self).__init__() self.tree = None # $ANTLR start "enum_content" # proto_parser.g:115:1: enum_content : ( option_line_def | enum_item_def )* ; def enum_content(self, ): retval = self.enum_content_return() retval.start = self.input.LT(1) root_0 = None option_line_def55 = None enum_item_def56 = None try: try: # proto_parser.g:115:14: ( ( option_line_def | enum_item_def )* ) # proto_parser.g:115:16: ( option_line_def | enum_item_def )* pass root_0 = self._adaptor.nil() # proto_parser.g:115:16: ( option_line_def | enum_item_def )* while True: #loop9 alt9 = 3 LA9_0 = self.input.LA(1) if (LA9_0 == OPTION_LITERAL) : alt9 = 1 elif (LA9_0 == IDENTIFIER) : alt9 = 2 if alt9 == 1: # proto_parser.g:115:17: option_line_def pass self._state.following.append(self.FOLLOW_option_line_def_in_enum_content656) option_line_def55 = self.option_line_def() self._state.following.pop() self._adaptor.addChild(root_0, option_line_def55.tree) elif alt9 == 2: # proto_parser.g:115:35: enum_item_def pass self._state.following.append(self.FOLLOW_enum_item_def_in_enum_content660) enum_item_def56 = self.enum_item_def() self._state.following.pop() self._adaptor.addChild(root_0, enum_item_def56.tree) else: break #loop9 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "enum_content" class enum_item_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.enum_item_def_return, self).__init__() self.tree = None # $ANTLR start "enum_item_def" # proto_parser.g:117:1: enum_item_def : IDENTIFIER EQUALS INTEGER_LITERAL ( option_field_def )? ITEM_TERMINATOR -> ^( ENUM_FIELD IDENTIFIER INTEGER_LITERAL ( option_field_def )? ) ; def enum_item_def(self, ): retval = self.enum_item_def_return() retval.start = self.input.LT(1) root_0 = None IDENTIFIER57 = None EQUALS58 = None INTEGER_LITERAL59 = None ITEM_TERMINATOR61 = None option_field_def60 = None IDENTIFIER57_tree = None EQUALS58_tree = None INTEGER_LITERAL59_tree = None ITEM_TERMINATOR61_tree = None stream_EQUALS = RewriteRuleTokenStream(self._adaptor, "token EQUALS") stream_IDENTIFIER = RewriteRuleTokenStream(self._adaptor, "token IDENTIFIER") stream_INTEGER_LITERAL = RewriteRuleTokenStream(self._adaptor, "token INTEGER_LITERAL") stream_ITEM_TERMINATOR = RewriteRuleTokenStream(self._adaptor, "token ITEM_TERMINATOR") stream_option_field_def = RewriteRuleSubtreeStream(self._adaptor, "rule option_field_def") try: try: # proto_parser.g:118:3: ( IDENTIFIER EQUALS INTEGER_LITERAL ( option_field_def )? ITEM_TERMINATOR -> ^( ENUM_FIELD IDENTIFIER INTEGER_LITERAL ( option_field_def )? ) ) # proto_parser.g:118:6: IDENTIFIER EQUALS INTEGER_LITERAL ( option_field_def )? ITEM_TERMINATOR pass IDENTIFIER57=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enum_item_def674) stream_IDENTIFIER.add(IDENTIFIER57) EQUALS58=self.match(self.input, EQUALS, self.FOLLOW_EQUALS_in_enum_item_def676) stream_EQUALS.add(EQUALS58) INTEGER_LITERAL59=self.match(self.input, INTEGER_LITERAL, self.FOLLOW_INTEGER_LITERAL_in_enum_item_def678) stream_INTEGER_LITERAL.add(INTEGER_LITERAL59) # proto_parser.g:118:40: ( option_field_def )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == BRACKET_OPEN) : alt10 = 1 if alt10 == 1: # proto_parser.g:118:40: option_field_def pass self._state.following.append(self.FOLLOW_option_field_def_in_enum_item_def680) option_field_def60 = self.option_field_def() self._state.following.pop() stream_option_field_def.add(option_field_def60.tree) ITEM_TERMINATOR61=self.match(self.input, ITEM_TERMINATOR, self.FOLLOW_ITEM_TERMINATOR_in_enum_item_def683) stream_ITEM_TERMINATOR.add(ITEM_TERMINATOR61) # AST Rewrite # elements: INTEGER_LITERAL, IDENTIFIER, option_field_def # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 119:6: -> ^( ENUM_FIELD IDENTIFIER INTEGER_LITERAL ( option_field_def )? ) # proto_parser.g:119:9: ^( ENUM_FIELD IDENTIFIER INTEGER_LITERAL ( option_field_def )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(ENUM_FIELD, "ENUM_FIELD"), root_1) self._adaptor.addChild(root_1, stream_IDENTIFIER.nextNode()) self._adaptor.addChild(root_1, stream_INTEGER_LITERAL.nextNode()) # proto_parser.g:119:49: ( option_field_def )? if stream_option_field_def.hasNext(): self._adaptor.addChild(root_1, stream_option_field_def.nextTree()) stream_option_field_def.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "enum_item_def" class message_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.message_def_return, self).__init__() self.tree = None # $ANTLR start "message_def" # proto_parser.g:124:1: message_def : MESSAGE_LITERAL message_name BLOCK_OPEN ( message_content )? BLOCK_CLOSE -> ^( MESSAGE_LITERAL message_name ( message_content )? ) ; def message_def(self, ): retval = self.message_def_return() retval.start = self.input.LT(1) root_0 = None MESSAGE_LITERAL62 = None BLOCK_OPEN64 = None BLOCK_CLOSE66 = None message_name63 = None message_content65 = None MESSAGE_LITERAL62_tree = None BLOCK_OPEN64_tree = None BLOCK_CLOSE66_tree = None stream_BLOCK_OPEN = RewriteRuleTokenStream(self._adaptor, "token BLOCK_OPEN") stream_MESSAGE_LITERAL = RewriteRuleTokenStream(self._adaptor, "token MESSAGE_LITERAL") stream_BLOCK_CLOSE = RewriteRuleTokenStream(self._adaptor, "token BLOCK_CLOSE") stream_message_name = RewriteRuleSubtreeStream(self._adaptor, "rule message_name") stream_message_content = RewriteRuleSubtreeStream(self._adaptor, "rule message_content") try: try: # proto_parser.g:125:3: ( MESSAGE_LITERAL message_name BLOCK_OPEN ( message_content )? BLOCK_CLOSE -> ^( MESSAGE_LITERAL message_name ( message_content )? ) ) # proto_parser.g:125:6: MESSAGE_LITERAL message_name BLOCK_OPEN ( message_content )? BLOCK_CLOSE pass MESSAGE_LITERAL62=self.match(self.input, MESSAGE_LITERAL, self.FOLLOW_MESSAGE_LITERAL_in_message_def717) stream_MESSAGE_LITERAL.add(MESSAGE_LITERAL62) self._state.following.append(self.FOLLOW_message_name_in_message_def719) message_name63 = self.message_name() self._state.following.pop() stream_message_name.add(message_name63.tree) BLOCK_OPEN64=self.match(self.input, BLOCK_OPEN, self.FOLLOW_BLOCK_OPEN_in_message_def721) stream_BLOCK_OPEN.add(BLOCK_OPEN64) # proto_parser.g:125:46: ( message_content )? alt11 = 2 LA11_0 = self.input.LA(1) if ((OPTION_LITERAL <= LA11_0 <= MESSAGE_LITERAL) or LA11_0 == EXTENSIONS_DEF_LITERAL or LA11_0 == PROTOBUF_SCOPE_LITERAL) : alt11 = 1 if alt11 == 1: # proto_parser.g:125:46: message_content pass self._state.following.append(self.FOLLOW_message_content_in_message_def723) message_content65 = self.message_content() self._state.following.pop() stream_message_content.add(message_content65.tree) BLOCK_CLOSE66=self.match(self.input, BLOCK_CLOSE, self.FOLLOW_BLOCK_CLOSE_in_message_def726) stream_BLOCK_CLOSE.add(BLOCK_CLOSE66) # AST Rewrite # elements: MESSAGE_LITERAL, message_name, message_content # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 126:6: -> ^( MESSAGE_LITERAL message_name ( message_content )? ) # proto_parser.g:126:9: ^( MESSAGE_LITERAL message_name ( message_content )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_MESSAGE_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_message_name.nextTree()) # proto_parser.g:126:40: ( message_content )? if stream_message_content.hasNext(): self._adaptor.addChild(root_1, stream_message_content.nextTree()) stream_message_content.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "message_def" class message_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.message_name_return, self).__init__() self.tree = None # $ANTLR start "message_name" # proto_parser.g:129:1: message_name : IDENTIFIER ; def message_name(self, ): retval = self.message_name_return() retval.start = self.input.LT(1) root_0 = None IDENTIFIER67 = None IDENTIFIER67_tree = None try: try: # proto_parser.g:129:14: ( IDENTIFIER ) # proto_parser.g:129:16: IDENTIFIER pass root_0 = self._adaptor.nil() IDENTIFIER67=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_message_name753) IDENTIFIER67_tree = self._adaptor.createWithPayload(IDENTIFIER67) self._adaptor.addChild(root_0, IDENTIFIER67_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "message_name" class message_content_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.message_content_return, self).__init__() self.tree = None # $ANTLR start "message_content" # proto_parser.g:131:1: message_content : ( option_line_def | message_item_def | message_def | enum_def | message_ext_def )+ ; def message_content(self, ): retval = self.message_content_return() retval.start = self.input.LT(1) root_0 = None option_line_def68 = None message_item_def69 = None message_def70 = None enum_def71 = None message_ext_def72 = None try: try: # proto_parser.g:131:17: ( ( option_line_def | message_item_def | message_def | enum_def | message_ext_def )+ ) # proto_parser.g:131:19: ( option_line_def | message_item_def | message_def | enum_def | message_ext_def )+ pass root_0 = self._adaptor.nil() # proto_parser.g:131:19: ( option_line_def | message_item_def | message_def | enum_def | message_ext_def )+ cnt12 = 0 while True: #loop12 alt12 = 6 LA12 = self.input.LA(1) if LA12 == OPTION_LITERAL: alt12 = 1 elif LA12 == PROTOBUF_SCOPE_LITERAL: alt12 = 2 elif LA12 == MESSAGE_LITERAL: alt12 = 3 elif LA12 == ENUM_LITERAL: alt12 = 4 elif LA12 == EXTENSIONS_DEF_LITERAL: alt12 = 5 if alt12 == 1: # proto_parser.g:131:20: option_line_def pass self._state.following.append(self.FOLLOW_option_line_def_in_message_content763) option_line_def68 = self.option_line_def() self._state.following.pop() self._adaptor.addChild(root_0, option_line_def68.tree) elif alt12 == 2: # proto_parser.g:131:38: message_item_def pass self._state.following.append(self.FOLLOW_message_item_def_in_message_content767) message_item_def69 = self.message_item_def() self._state.following.pop() self._adaptor.addChild(root_0, message_item_def69.tree) elif alt12 == 3: # proto_parser.g:131:57: message_def pass self._state.following.append(self.FOLLOW_message_def_in_message_content771) message_def70 = self.message_def() self._state.following.pop() self._adaptor.addChild(root_0, message_def70.tree) elif alt12 == 4: # proto_parser.g:131:71: enum_def pass self._state.following.append(self.FOLLOW_enum_def_in_message_content775) enum_def71 = self.enum_def() self._state.following.pop() self._adaptor.addChild(root_0, enum_def71.tree) elif alt12 == 5: # proto_parser.g:131:82: message_ext_def pass self._state.following.append(self.FOLLOW_message_ext_def_in_message_content779) message_ext_def72 = self.message_ext_def() self._state.following.pop() self._adaptor.addChild(root_0, message_ext_def72.tree) else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "message_content" class message_item_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.message_item_def_return, self).__init__() self.tree = None # $ANTLR start "message_item_def" # proto_parser.g:133:1: message_item_def : PROTOBUF_SCOPE_LITERAL proto_type IDENTIFIER EQUALS INTEGER_LITERAL ( option_field_def )? ITEM_TERMINATOR -> ^( MESSAGE_FIELD PROTOBUF_SCOPE_LITERAL proto_type IDENTIFIER INTEGER_LITERAL ( option_field_def )? ) ; def message_item_def(self, ): retval = self.message_item_def_return() retval.start = self.input.LT(1) root_0 = None PROTOBUF_SCOPE_LITERAL73 = None IDENTIFIER75 = None EQUALS76 = None INTEGER_LITERAL77 = None ITEM_TERMINATOR79 = None proto_type74 = None option_field_def78 = None PROTOBUF_SCOPE_LITERAL73_tree = None IDENTIFIER75_tree = None EQUALS76_tree = None INTEGER_LITERAL77_tree = None ITEM_TERMINATOR79_tree = None stream_EQUALS = RewriteRuleTokenStream(self._adaptor, "token EQUALS") stream_PROTOBUF_SCOPE_LITERAL = RewriteRuleTokenStream(self._adaptor, "token PROTOBUF_SCOPE_LITERAL") stream_IDENTIFIER = RewriteRuleTokenStream(self._adaptor, "token IDENTIFIER") stream_INTEGER_LITERAL = RewriteRuleTokenStream(self._adaptor, "token INTEGER_LITERAL") stream_ITEM_TERMINATOR = RewriteRuleTokenStream(self._adaptor, "token ITEM_TERMINATOR") stream_proto_type = RewriteRuleSubtreeStream(self._adaptor, "rule proto_type") stream_option_field_def = RewriteRuleSubtreeStream(self._adaptor, "rule option_field_def") try: try: # proto_parser.g:134:3: ( PROTOBUF_SCOPE_LITERAL proto_type IDENTIFIER EQUALS INTEGER_LITERAL ( option_field_def )? ITEM_TERMINATOR -> ^( MESSAGE_FIELD PROTOBUF_SCOPE_LITERAL proto_type IDENTIFIER INTEGER_LITERAL ( option_field_def )? ) ) # proto_parser.g:134:5: PROTOBUF_SCOPE_LITERAL proto_type IDENTIFIER EQUALS INTEGER_LITERAL ( option_field_def )? ITEM_TERMINATOR pass PROTOBUF_SCOPE_LITERAL73=self.match(self.input, PROTOBUF_SCOPE_LITERAL, self.FOLLOW_PROTOBUF_SCOPE_LITERAL_in_message_item_def792) stream_PROTOBUF_SCOPE_LITERAL.add(PROTOBUF_SCOPE_LITERAL73) self._state.following.append(self.FOLLOW_proto_type_in_message_item_def794) proto_type74 = self.proto_type() self._state.following.pop() stream_proto_type.add(proto_type74.tree) IDENTIFIER75=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_message_item_def796) stream_IDENTIFIER.add(IDENTIFIER75) EQUALS76=self.match(self.input, EQUALS, self.FOLLOW_EQUALS_in_message_item_def798) stream_EQUALS.add(EQUALS76) INTEGER_LITERAL77=self.match(self.input, INTEGER_LITERAL, self.FOLLOW_INTEGER_LITERAL_in_message_item_def800) stream_INTEGER_LITERAL.add(INTEGER_LITERAL77) # proto_parser.g:134:73: ( option_field_def )? alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == BRACKET_OPEN) : alt13 = 1 if alt13 == 1: # proto_parser.g:134:73: option_field_def pass self._state.following.append(self.FOLLOW_option_field_def_in_message_item_def802) option_field_def78 = self.option_field_def() self._state.following.pop() stream_option_field_def.add(option_field_def78.tree) ITEM_TERMINATOR79=self.match(self.input, ITEM_TERMINATOR, self.FOLLOW_ITEM_TERMINATOR_in_message_item_def805) stream_ITEM_TERMINATOR.add(ITEM_TERMINATOR79) # AST Rewrite # elements: INTEGER_LITERAL, option_field_def, proto_type, PROTOBUF_SCOPE_LITERAL, IDENTIFIER # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 135:6: -> ^( MESSAGE_FIELD PROTOBUF_SCOPE_LITERAL proto_type IDENTIFIER INTEGER_LITERAL ( option_field_def )? ) # proto_parser.g:135:9: ^( MESSAGE_FIELD PROTOBUF_SCOPE_LITERAL proto_type IDENTIFIER INTEGER_LITERAL ( option_field_def )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(MESSAGE_FIELD, "MESSAGE_FIELD"), root_1) self._adaptor.addChild(root_1, stream_PROTOBUF_SCOPE_LITERAL.nextNode()) self._adaptor.addChild(root_1, stream_proto_type.nextTree()) self._adaptor.addChild(root_1, stream_IDENTIFIER.nextNode()) self._adaptor.addChild(root_1, stream_INTEGER_LITERAL.nextNode()) # proto_parser.g:135:86: ( option_field_def )? if stream_option_field_def.hasNext(): self._adaptor.addChild(root_1, stream_option_field_def.nextTree()) stream_option_field_def.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "message_item_def" class message_ext_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.message_ext_def_return, self).__init__() self.tree = None # $ANTLR start "message_ext_def" # proto_parser.g:138:1: message_ext_def : EXTENSIONS_DEF_LITERAL INTEGER_LITERAL EXTENSIONS_TO_LITERAL (v= INTEGER_LITERAL | v= EXTENSIONS_MAX_LITERAL ) ITEM_TERMINATOR -> ^( EXTENSIONS_DEF_LITERAL INTEGER_LITERAL $v) ; def message_ext_def(self, ): retval = self.message_ext_def_return() retval.start = self.input.LT(1) root_0 = None v = None EXTENSIONS_DEF_LITERAL80 = None INTEGER_LITERAL81 = None EXTENSIONS_TO_LITERAL82 = None ITEM_TERMINATOR83 = None v_tree = None EXTENSIONS_DEF_LITERAL80_tree = None INTEGER_LITERAL81_tree = None EXTENSIONS_TO_LITERAL82_tree = None ITEM_TERMINATOR83_tree = None stream_EXTENSIONS_MAX_LITERAL = RewriteRuleTokenStream(self._adaptor, "token EXTENSIONS_MAX_LITERAL") stream_EXTENSIONS_TO_LITERAL = RewriteRuleTokenStream(self._adaptor, "token EXTENSIONS_TO_LITERAL") stream_EXTENSIONS_DEF_LITERAL = RewriteRuleTokenStream(self._adaptor, "token EXTENSIONS_DEF_LITERAL") stream_INTEGER_LITERAL = RewriteRuleTokenStream(self._adaptor, "token INTEGER_LITERAL") stream_ITEM_TERMINATOR = RewriteRuleTokenStream(self._adaptor, "token ITEM_TERMINATOR") try: try: # proto_parser.g:139:3: ( EXTENSIONS_DEF_LITERAL INTEGER_LITERAL EXTENSIONS_TO_LITERAL (v= INTEGER_LITERAL | v= EXTENSIONS_MAX_LITERAL ) ITEM_TERMINATOR -> ^( EXTENSIONS_DEF_LITERAL INTEGER_LITERAL $v) ) # proto_parser.g:139:5: EXTENSIONS_DEF_LITERAL INTEGER_LITERAL EXTENSIONS_TO_LITERAL (v= INTEGER_LITERAL | v= EXTENSIONS_MAX_LITERAL ) ITEM_TERMINATOR pass EXTENSIONS_DEF_LITERAL80=self.match(self.input, EXTENSIONS_DEF_LITERAL, self.FOLLOW_EXTENSIONS_DEF_LITERAL_in_message_ext_def840) stream_EXTENSIONS_DEF_LITERAL.add(EXTENSIONS_DEF_LITERAL80) INTEGER_LITERAL81=self.match(self.input, INTEGER_LITERAL, self.FOLLOW_INTEGER_LITERAL_in_message_ext_def842) stream_INTEGER_LITERAL.add(INTEGER_LITERAL81) EXTENSIONS_TO_LITERAL82=self.match(self.input, EXTENSIONS_TO_LITERAL, self.FOLLOW_EXTENSIONS_TO_LITERAL_in_message_ext_def844) stream_EXTENSIONS_TO_LITERAL.add(EXTENSIONS_TO_LITERAL82) # proto_parser.g:139:66: (v= INTEGER_LITERAL | v= EXTENSIONS_MAX_LITERAL ) alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == INTEGER_LITERAL) : alt14 = 1 elif (LA14_0 == EXTENSIONS_MAX_LITERAL) : alt14 = 2 else: nvae = NoViableAltException("", 14, 0, self.input) raise nvae if alt14 == 1: # proto_parser.g:139:67: v= INTEGER_LITERAL pass v=self.match(self.input, INTEGER_LITERAL, self.FOLLOW_INTEGER_LITERAL_in_message_ext_def849) stream_INTEGER_LITERAL.add(v) elif alt14 == 2: # proto_parser.g:139:87: v= EXTENSIONS_MAX_LITERAL pass v=self.match(self.input, EXTENSIONS_MAX_LITERAL, self.FOLLOW_EXTENSIONS_MAX_LITERAL_in_message_ext_def855) stream_EXTENSIONS_MAX_LITERAL.add(v) ITEM_TERMINATOR83=self.match(self.input, ITEM_TERMINATOR, self.FOLLOW_ITEM_TERMINATOR_in_message_ext_def858) stream_ITEM_TERMINATOR.add(ITEM_TERMINATOR83) # AST Rewrite # elements: INTEGER_LITERAL, EXTENSIONS_DEF_LITERAL, v # token labels: v # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 stream_v = RewriteRuleTokenStream(self._adaptor, "token v", v) if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 140:5: -> ^( EXTENSIONS_DEF_LITERAL INTEGER_LITERAL $v) # proto_parser.g:140:8: ^( EXTENSIONS_DEF_LITERAL INTEGER_LITERAL $v) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_EXTENSIONS_DEF_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_INTEGER_LITERAL.nextNode()) self._adaptor.addChild(root_1, stream_v.nextNode()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "message_ext_def" class ext_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.ext_def_return, self).__init__() self.tree = None # $ANTLR start "ext_def" # proto_parser.g:145:1: ext_def : EXTEND_LITERAL ext_name BLOCK_OPEN ( ext_content )? BLOCK_CLOSE -> ^( EXTEND_LITERAL ext_name ( ext_content )? ) ; def ext_def(self, ): retval = self.ext_def_return() retval.start = self.input.LT(1) root_0 = None EXTEND_LITERAL84 = None BLOCK_OPEN86 = None BLOCK_CLOSE88 = None ext_name85 = None ext_content87 = None EXTEND_LITERAL84_tree = None BLOCK_OPEN86_tree = None BLOCK_CLOSE88_tree = None stream_BLOCK_OPEN = RewriteRuleTokenStream(self._adaptor, "token BLOCK_OPEN") stream_BLOCK_CLOSE = RewriteRuleTokenStream(self._adaptor, "token BLOCK_CLOSE") stream_EXTEND_LITERAL = RewriteRuleTokenStream(self._adaptor, "token EXTEND_LITERAL") stream_ext_name = RewriteRuleSubtreeStream(self._adaptor, "rule ext_name") stream_ext_content = RewriteRuleSubtreeStream(self._adaptor, "rule ext_content") try: try: # proto_parser.g:146:3: ( EXTEND_LITERAL ext_name BLOCK_OPEN ( ext_content )? BLOCK_CLOSE -> ^( EXTEND_LITERAL ext_name ( ext_content )? ) ) # proto_parser.g:146:6: EXTEND_LITERAL ext_name BLOCK_OPEN ( ext_content )? BLOCK_CLOSE pass EXTEND_LITERAL84=self.match(self.input, EXTEND_LITERAL, self.FOLLOW_EXTEND_LITERAL_in_ext_def889) stream_EXTEND_LITERAL.add(EXTEND_LITERAL84) self._state.following.append(self.FOLLOW_ext_name_in_ext_def891) ext_name85 = self.ext_name() self._state.following.pop() stream_ext_name.add(ext_name85.tree) BLOCK_OPEN86=self.match(self.input, BLOCK_OPEN, self.FOLLOW_BLOCK_OPEN_in_ext_def893) stream_BLOCK_OPEN.add(BLOCK_OPEN86) # proto_parser.g:146:41: ( ext_content )? alt15 = 2 LA15_0 = self.input.LA(1) if ((OPTION_LITERAL <= LA15_0 <= MESSAGE_LITERAL) or LA15_0 == PROTOBUF_SCOPE_LITERAL) : alt15 = 1 if alt15 == 1: # proto_parser.g:146:41: ext_content pass self._state.following.append(self.FOLLOW_ext_content_in_ext_def895) ext_content87 = self.ext_content() self._state.following.pop() stream_ext_content.add(ext_content87.tree) BLOCK_CLOSE88=self.match(self.input, BLOCK_CLOSE, self.FOLLOW_BLOCK_CLOSE_in_ext_def898) stream_BLOCK_CLOSE.add(BLOCK_CLOSE88) # AST Rewrite # elements: ext_content, ext_name, EXTEND_LITERAL # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 147:6: -> ^( EXTEND_LITERAL ext_name ( ext_content )? ) # proto_parser.g:147:9: ^( EXTEND_LITERAL ext_name ( ext_content )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_EXTEND_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_ext_name.nextTree()) # proto_parser.g:147:35: ( ext_content )? if stream_ext_content.hasNext(): self._adaptor.addChild(root_1, stream_ext_content.nextTree()) stream_ext_content.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "ext_def" class ext_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.ext_name_return, self).__init__() self.tree = None # $ANTLR start "ext_name" # proto_parser.g:150:1: ext_name : all_identifier ; def ext_name(self, ): retval = self.ext_name_return() retval.start = self.input.LT(1) root_0 = None all_identifier89 = None try: try: # proto_parser.g:150:10: ( all_identifier ) # proto_parser.g:150:12: all_identifier pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_all_identifier_in_ext_name925) all_identifier89 = self.all_identifier() self._state.following.pop() self._adaptor.addChild(root_0, all_identifier89.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "ext_name" class ext_content_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.ext_content_return, self).__init__() self.tree = None # $ANTLR start "ext_content" # proto_parser.g:152:1: ext_content : ( option_line_def | message_item_def | message_def | enum_def )+ ; def ext_content(self, ): retval = self.ext_content_return() retval.start = self.input.LT(1) root_0 = None option_line_def90 = None message_item_def91 = None message_def92 = None enum_def93 = None try: try: # proto_parser.g:152:13: ( ( option_line_def | message_item_def | message_def | enum_def )+ ) # proto_parser.g:152:15: ( option_line_def | message_item_def | message_def | enum_def )+ pass root_0 = self._adaptor.nil() # proto_parser.g:152:15: ( option_line_def | message_item_def | message_def | enum_def )+ cnt16 = 0 while True: #loop16 alt16 = 5 LA16 = self.input.LA(1) if LA16 == OPTION_LITERAL: alt16 = 1 elif LA16 == PROTOBUF_SCOPE_LITERAL: alt16 = 2 elif LA16 == MESSAGE_LITERAL: alt16 = 3 elif LA16 == ENUM_LITERAL: alt16 = 4 if alt16 == 1: # proto_parser.g:152:16: option_line_def pass self._state.following.append(self.FOLLOW_option_line_def_in_ext_content935) option_line_def90 = self.option_line_def() self._state.following.pop() self._adaptor.addChild(root_0, option_line_def90.tree) elif alt16 == 2: # proto_parser.g:152:34: message_item_def pass self._state.following.append(self.FOLLOW_message_item_def_in_ext_content939) message_item_def91 = self.message_item_def() self._state.following.pop() self._adaptor.addChild(root_0, message_item_def91.tree) elif alt16 == 3: # proto_parser.g:152:53: message_def pass self._state.following.append(self.FOLLOW_message_def_in_ext_content943) message_def92 = self.message_def() self._state.following.pop() self._adaptor.addChild(root_0, message_def92.tree) elif alt16 == 4: # proto_parser.g:152:67: enum_def pass self._state.following.append(self.FOLLOW_enum_def_in_ext_content947) enum_def93 = self.enum_def() self._state.following.pop() self._adaptor.addChild(root_0, enum_def93.tree) else: if cnt16 >= 1: break #loop16 eee = EarlyExitException(16, self.input) raise eee cnt16 += 1 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "ext_content" class service_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.service_def_return, self).__init__() self.tree = None # $ANTLR start "service_def" # proto_parser.g:156:1: service_def : SERVICE_LITERAL service_name BLOCK_OPEN ( service_content )? BLOCK_CLOSE -> ^( SERVICE_LITERAL service_name ( service_content )? ) ; def service_def(self, ): retval = self.service_def_return() retval.start = self.input.LT(1) root_0 = None SERVICE_LITERAL94 = None BLOCK_OPEN96 = None BLOCK_CLOSE98 = None service_name95 = None service_content97 = None SERVICE_LITERAL94_tree = None BLOCK_OPEN96_tree = None BLOCK_CLOSE98_tree = None stream_BLOCK_OPEN = RewriteRuleTokenStream(self._adaptor, "token BLOCK_OPEN") stream_SERVICE_LITERAL = RewriteRuleTokenStream(self._adaptor, "token SERVICE_LITERAL") stream_BLOCK_CLOSE = RewriteRuleTokenStream(self._adaptor, "token BLOCK_CLOSE") stream_service_content = RewriteRuleSubtreeStream(self._adaptor, "rule service_content") stream_service_name = RewriteRuleSubtreeStream(self._adaptor, "rule service_name") try: try: # proto_parser.g:157:3: ( SERVICE_LITERAL service_name BLOCK_OPEN ( service_content )? BLOCK_CLOSE -> ^( SERVICE_LITERAL service_name ( service_content )? ) ) # proto_parser.g:157:6: SERVICE_LITERAL service_name BLOCK_OPEN ( service_content )? BLOCK_CLOSE pass SERVICE_LITERAL94=self.match(self.input, SERVICE_LITERAL, self.FOLLOW_SERVICE_LITERAL_in_service_def963) stream_SERVICE_LITERAL.add(SERVICE_LITERAL94) self._state.following.append(self.FOLLOW_service_name_in_service_def965) service_name95 = self.service_name() self._state.following.pop() stream_service_name.add(service_name95.tree) BLOCK_OPEN96=self.match(self.input, BLOCK_OPEN, self.FOLLOW_BLOCK_OPEN_in_service_def967) stream_BLOCK_OPEN.add(BLOCK_OPEN96) # proto_parser.g:157:46: ( service_content )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == OPTION_LITERAL or LA17_0 == RPC_LITERAL) : alt17 = 1 if alt17 == 1: # proto_parser.g:157:46: service_content pass self._state.following.append(self.FOLLOW_service_content_in_service_def969) service_content97 = self.service_content() self._state.following.pop() stream_service_content.add(service_content97.tree) BLOCK_CLOSE98=self.match(self.input, BLOCK_CLOSE, self.FOLLOW_BLOCK_CLOSE_in_service_def972) stream_BLOCK_CLOSE.add(BLOCK_CLOSE98) # AST Rewrite # elements: service_content, SERVICE_LITERAL, service_name # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 158:6: -> ^( SERVICE_LITERAL service_name ( service_content )? ) # proto_parser.g:158:9: ^( SERVICE_LITERAL service_name ( service_content )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_SERVICE_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_service_name.nextTree()) # proto_parser.g:158:40: ( service_content )? if stream_service_content.hasNext(): self._adaptor.addChild(root_1, stream_service_content.nextTree()) stream_service_content.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "service_def" class service_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.service_name_return, self).__init__() self.tree = None # $ANTLR start "service_name" # proto_parser.g:161:1: service_name : IDENTIFIER ; def service_name(self, ): retval = self.service_name_return() retval.start = self.input.LT(1) root_0 = None IDENTIFIER99 = None IDENTIFIER99_tree = None try: try: # proto_parser.g:161:14: ( IDENTIFIER ) # proto_parser.g:161:16: IDENTIFIER pass root_0 = self._adaptor.nil() IDENTIFIER99=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_service_name999) IDENTIFIER99_tree = self._adaptor.createWithPayload(IDENTIFIER99) self._adaptor.addChild(root_0, IDENTIFIER99_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "service_name" class service_content_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.service_content_return, self).__init__() self.tree = None # $ANTLR start "service_content" # proto_parser.g:163:1: service_content : ( option_line_def | rpc_def )+ ; def service_content(self, ): retval = self.service_content_return() retval.start = self.input.LT(1) root_0 = None option_line_def100 = None rpc_def101 = None try: try: # proto_parser.g:163:17: ( ( option_line_def | rpc_def )+ ) # proto_parser.g:163:19: ( option_line_def | rpc_def )+ pass root_0 = self._adaptor.nil() # proto_parser.g:163:19: ( option_line_def | rpc_def )+ cnt18 = 0 while True: #loop18 alt18 = 3 LA18_0 = self.input.LA(1) if (LA18_0 == OPTION_LITERAL) : alt18 = 1 elif (LA18_0 == RPC_LITERAL) : alt18 = 2 if alt18 == 1: # proto_parser.g:163:20: option_line_def pass self._state.following.append(self.FOLLOW_option_line_def_in_service_content1009) option_line_def100 = self.option_line_def() self._state.following.pop() self._adaptor.addChild(root_0, option_line_def100.tree) elif alt18 == 2: # proto_parser.g:163:38: rpc_def pass self._state.following.append(self.FOLLOW_rpc_def_in_service_content1013) rpc_def101 = self.rpc_def() self._state.following.pop() self._adaptor.addChild(root_0, rpc_def101.tree) else: if cnt18 >= 1: break #loop18 eee = EarlyExitException(18, self.input) raise eee cnt18 += 1 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "service_content" class rpc_def_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.rpc_def_return, self).__init__() self.tree = None # $ANTLR start "rpc_def" # proto_parser.g:165:1: rpc_def : RPC_LITERAL rpc_name PAREN_OPEN req_name PAREN_CLOSE RETURNS_LITERAL PAREN_OPEN resp_name PAREN_CLOSE ( BLOCK_OPEN ( option_line_def )* BLOCK_CLOSE ( ITEM_TERMINATOR )? | ITEM_TERMINATOR ) -> ^( RPC_LITERAL rpc_name req_name resp_name ( option_line_def )* ) ; def rpc_def(self, ): retval = self.rpc_def_return() retval.start = self.input.LT(1) root_0 = None RPC_LITERAL102 = None PAREN_OPEN104 = None PAREN_CLOSE106 = None RETURNS_LITERAL107 = None PAREN_OPEN108 = None PAREN_CLOSE110 = None BLOCK_OPEN111 = None BLOCK_CLOSE113 = None ITEM_TERMINATOR114 = None ITEM_TERMINATOR115 = None rpc_name103 = None req_name105 = None resp_name109 = None option_line_def112 = None RPC_LITERAL102_tree = None PAREN_OPEN104_tree = None PAREN_CLOSE106_tree = None RETURNS_LITERAL107_tree = None PAREN_OPEN108_tree = None PAREN_CLOSE110_tree = None BLOCK_OPEN111_tree = None BLOCK_CLOSE113_tree = None ITEM_TERMINATOR114_tree = None ITEM_TERMINATOR115_tree = None stream_BLOCK_OPEN = RewriteRuleTokenStream(self._adaptor, "token BLOCK_OPEN") stream_BLOCK_CLOSE = RewriteRuleTokenStream(self._adaptor, "token BLOCK_CLOSE") stream_PAREN_OPEN = RewriteRuleTokenStream(self._adaptor, "token PAREN_OPEN") stream_PAREN_CLOSE = RewriteRuleTokenStream(self._adaptor, "token PAREN_CLOSE") stream_ITEM_TERMINATOR = RewriteRuleTokenStream(self._adaptor, "token ITEM_TERMINATOR") stream_RPC_LITERAL = RewriteRuleTokenStream(self._adaptor, "token RPC_LITERAL") stream_RETURNS_LITERAL = RewriteRuleTokenStream(self._adaptor, "token RETURNS_LITERAL") stream_rpc_name = RewriteRuleSubtreeStream(self._adaptor, "rule rpc_name") stream_resp_name = RewriteRuleSubtreeStream(self._adaptor, "rule resp_name") stream_req_name = RewriteRuleSubtreeStream(self._adaptor, "rule req_name") stream_option_line_def = RewriteRuleSubtreeStream(self._adaptor, "rule option_line_def") try: try: # proto_parser.g:166:3: ( RPC_LITERAL rpc_name PAREN_OPEN req_name PAREN_CLOSE RETURNS_LITERAL PAREN_OPEN resp_name PAREN_CLOSE ( BLOCK_OPEN ( option_line_def )* BLOCK_CLOSE ( ITEM_TERMINATOR )? | ITEM_TERMINATOR ) -> ^( RPC_LITERAL rpc_name req_name resp_name ( option_line_def )* ) ) # proto_parser.g:166:6: RPC_LITERAL rpc_name PAREN_OPEN req_name PAREN_CLOSE RETURNS_LITERAL PAREN_OPEN resp_name PAREN_CLOSE ( BLOCK_OPEN ( option_line_def )* BLOCK_CLOSE ( ITEM_TERMINATOR )? | ITEM_TERMINATOR ) pass RPC_LITERAL102=self.match(self.input, RPC_LITERAL, self.FOLLOW_RPC_LITERAL_in_rpc_def1028) stream_RPC_LITERAL.add(RPC_LITERAL102) self._state.following.append(self.FOLLOW_rpc_name_in_rpc_def1030) rpc_name103 = self.rpc_name() self._state.following.pop() stream_rpc_name.add(rpc_name103.tree) PAREN_OPEN104=self.match(self.input, PAREN_OPEN, self.FOLLOW_PAREN_OPEN_in_rpc_def1032) stream_PAREN_OPEN.add(PAREN_OPEN104) self._state.following.append(self.FOLLOW_req_name_in_rpc_def1034) req_name105 = self.req_name() self._state.following.pop() stream_req_name.add(req_name105.tree) PAREN_CLOSE106=self.match(self.input, PAREN_CLOSE, self.FOLLOW_PAREN_CLOSE_in_rpc_def1036) stream_PAREN_CLOSE.add(PAREN_CLOSE106) RETURNS_LITERAL107=self.match(self.input, RETURNS_LITERAL, self.FOLLOW_RETURNS_LITERAL_in_rpc_def1038) stream_RETURNS_LITERAL.add(RETURNS_LITERAL107) PAREN_OPEN108=self.match(self.input, PAREN_OPEN, self.FOLLOW_PAREN_OPEN_in_rpc_def1040) stream_PAREN_OPEN.add(PAREN_OPEN108) self._state.following.append(self.FOLLOW_resp_name_in_rpc_def1042) resp_name109 = self.resp_name() self._state.following.pop() stream_resp_name.add(resp_name109.tree) PAREN_CLOSE110=self.match(self.input, PAREN_CLOSE, self.FOLLOW_PAREN_CLOSE_in_rpc_def1044) stream_PAREN_CLOSE.add(PAREN_CLOSE110) # proto_parser.g:166:108: ( BLOCK_OPEN ( option_line_def )* BLOCK_CLOSE ( ITEM_TERMINATOR )? | ITEM_TERMINATOR ) alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == BLOCK_OPEN) : alt21 = 1 elif (LA21_0 == ITEM_TERMINATOR) : alt21 = 2 else: nvae = NoViableAltException("", 21, 0, self.input) raise nvae if alt21 == 1: # proto_parser.g:166:109: BLOCK_OPEN ( option_line_def )* BLOCK_CLOSE ( ITEM_TERMINATOR )? pass BLOCK_OPEN111=self.match(self.input, BLOCK_OPEN, self.FOLLOW_BLOCK_OPEN_in_rpc_def1047) stream_BLOCK_OPEN.add(BLOCK_OPEN111) # proto_parser.g:166:120: ( option_line_def )* while True: #loop19 alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == OPTION_LITERAL) : alt19 = 1 if alt19 == 1: # proto_parser.g:166:120: option_line_def pass self._state.following.append(self.FOLLOW_option_line_def_in_rpc_def1049) option_line_def112 = self.option_line_def() self._state.following.pop() stream_option_line_def.add(option_line_def112.tree) else: break #loop19 BLOCK_CLOSE113=self.match(self.input, BLOCK_CLOSE, self.FOLLOW_BLOCK_CLOSE_in_rpc_def1052) stream_BLOCK_CLOSE.add(BLOCK_CLOSE113) # proto_parser.g:166:149: ( ITEM_TERMINATOR )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == ITEM_TERMINATOR) : alt20 = 1 if alt20 == 1: # proto_parser.g:166:149: ITEM_TERMINATOR pass ITEM_TERMINATOR114=self.match(self.input, ITEM_TERMINATOR, self.FOLLOW_ITEM_TERMINATOR_in_rpc_def1054) stream_ITEM_TERMINATOR.add(ITEM_TERMINATOR114) elif alt21 == 2: # proto_parser.g:166:168: ITEM_TERMINATOR pass ITEM_TERMINATOR115=self.match(self.input, ITEM_TERMINATOR, self.FOLLOW_ITEM_TERMINATOR_in_rpc_def1059) stream_ITEM_TERMINATOR.add(ITEM_TERMINATOR115) # AST Rewrite # elements: option_line_def, rpc_name, resp_name, req_name, RPC_LITERAL # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 167:6: -> ^( RPC_LITERAL rpc_name req_name resp_name ( option_line_def )* ) # proto_parser.g:167:9: ^( RPC_LITERAL rpc_name req_name resp_name ( option_line_def )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_RPC_LITERAL.nextNode(), root_1) self._adaptor.addChild(root_1, stream_rpc_name.nextTree()) self._adaptor.addChild(root_1, stream_req_name.nextTree()) self._adaptor.addChild(root_1, stream_resp_name.nextTree()) # proto_parser.g:167:51: ( option_line_def )* while stream_option_line_def.hasNext(): self._adaptor.addChild(root_1, stream_option_line_def.nextTree()) stream_option_line_def.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "rpc_def" class rpc_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.rpc_name_return, self).__init__() self.tree = None # $ANTLR start "rpc_name" # proto_parser.g:170:1: rpc_name : IDENTIFIER ; def rpc_name(self, ): retval = self.rpc_name_return() retval.start = self.input.LT(1) root_0 = None IDENTIFIER116 = None IDENTIFIER116_tree = None try: try: # proto_parser.g:170:10: ( IDENTIFIER ) # proto_parser.g:170:12: IDENTIFIER pass root_0 = self._adaptor.nil() IDENTIFIER116=self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_rpc_name1091) IDENTIFIER116_tree = self._adaptor.createWithPayload(IDENTIFIER116) self._adaptor.addChild(root_0, IDENTIFIER116_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "rpc_name" class req_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.req_name_return, self).__init__() self.tree = None # $ANTLR start "req_name" # proto_parser.g:171:1: req_name : all_identifier ; def req_name(self, ): retval = self.req_name_return() retval.start = self.input.LT(1) root_0 = None all_identifier117 = None try: try: # proto_parser.g:171:10: ( all_identifier ) # proto_parser.g:171:12: all_identifier pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_all_identifier_in_req_name1099) all_identifier117 = self.all_identifier() self._state.following.pop() self._adaptor.addChild(root_0, all_identifier117.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "req_name" class resp_name_return(ParserRuleReturnScope): def __init__(self): super(proto_parser.resp_name_return, self).__init__() self.tree = None # $ANTLR start "resp_name" # proto_parser.g:172:1: resp_name : all_identifier ; def resp_name(self, ): retval = self.resp_name_return() retval.start = self.input.LT(1) root_0 = None all_identifier118 = None try: try: # proto_parser.g:172:11: ( all_identifier ) # proto_parser.g:172:13: all_identifier pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_all_identifier_in_resp_name1107) all_identifier118 = self.all_identifier() self._state.following.pop() self._adaptor.addChild(root_0, all_identifier118.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "resp_name" # Delegated rules FOLLOW_set_in_all_identifier0 = frozenset([1]) FOLLOW_IDENTIFIER_in_all_value129 = frozenset([1]) FOLLOW_literal_value_in_all_value136 = frozenset([1]) FOLLOW_set_in_literal_value0 = frozenset([1]) FOLLOW_PROTOBUF_TYPE_LITERAL_in_proto_type185 = frozenset([1]) FOLLOW_all_identifier_in_proto_type192 = frozenset([1]) FOLLOW_package_def_in_proto208 = frozenset([7, 8, 9, 10, 11, 12, 16]) FOLLOW_import_def_in_proto212 = frozenset([7, 8, 9, 10, 11, 12, 16]) FOLLOW_option_line_def_in_proto216 = frozenset([7, 8, 9, 10, 11, 12, 16]) FOLLOW_enum_def_in_proto220 = frozenset([7, 8, 9, 10, 11, 12, 16]) FOLLOW_ext_def_in_proto224 = frozenset([7, 8, 9, 10, 11, 12, 16]) FOLLOW_message_def_in_proto228 = frozenset([7, 8, 9, 10, 11, 12, 16]) FOLLOW_service_def_in_proto232 = frozenset([7, 8, 9, 10, 11, 12, 16]) FOLLOW_EOF_in_proto236 = frozenset([1]) FOLLOW_PACKAGE_LITERAL_in_package_def286 = frozenset([62, 63]) FOLLOW_package_name_in_package_def288 = frozenset([28]) FOLLOW_ITEM_TERMINATOR_in_package_def290 = frozenset([1]) FOLLOW_all_identifier_in_package_name314 = frozenset([1]) FOLLOW_IMPORT_LITERAL_in_import_def328 = frozenset([55]) FOLLOW_import_file_name_in_import_def330 = frozenset([28]) FOLLOW_ITEM_TERMINATOR_in_import_def332 = frozenset([1]) FOLLOW_STRING_LITERAL_in_import_file_name356 = frozenset([1]) FOLLOW_OPTION_LITERAL_in_option_line_def370 = frozenset([21, 62]) FOLLOW_option_name_in_option_line_def372 = frozenset([25]) FOLLOW_EQUALS_in_option_line_def374 = frozenset([19, 52, 55, 59, 61, 62]) FOLLOW_option_all_value_in_option_line_def376 = frozenset([28]) FOLLOW_ITEM_TERMINATOR_in_option_line_def378 = frozenset([1]) FOLLOW_BRACKET_OPEN_in_option_field_def407 = frozenset([21, 62]) FOLLOW_option_field_item_in_option_field_def410 = frozenset([24, 27]) FOLLOW_COMMA_in_option_field_def413 = frozenset([21, 62]) FOLLOW_option_field_item_in_option_field_def416 = frozenset([24, 27]) FOLLOW_BRACKET_CLOSE_in_option_field_def420 = frozenset([1]) FOLLOW_option_name_in_option_field_item435 = frozenset([25]) FOLLOW_EQUALS_in_option_field_item437 = frozenset([19, 52, 55, 59, 61, 62]) FOLLOW_option_all_value_in_option_field_item439 = frozenset([1]) FOLLOW_all_value_in_option_all_value467 = frozenset([1]) FOLLOW_option_value_object_in_option_all_value473 = frozenset([1]) FOLLOW_BLOCK_OPEN_in_option_value_object487 = frozenset([20, 62]) FOLLOW_option_value_item_in_option_value_object489 = frozenset([20, 62]) FOLLOW_BLOCK_CLOSE_in_option_value_object492 = frozenset([1]) FOLLOW_IDENTIFIER_in_option_value_item520 = frozenset([26]) FOLLOW_COLON_in_option_value_item522 = frozenset([19, 52, 55, 59, 61, 62]) FOLLOW_option_all_value_in_option_value_item524 = frozenset([1]) FOLLOW_IDENTIFIER_in_option_name553 = frozenset([1]) FOLLOW_PAREN_OPEN_in_option_name573 = frozenset([62, 63]) FOLLOW_all_identifier_in_option_name575 = frozenset([22]) FOLLOW_PAREN_CLOSE_in_option_name577 = frozenset([1, 64]) FOLLOW_FIELD_IDENTIFIER_in_option_name579 = frozenset([1, 64]) FOLLOW_ENUM_LITERAL_in_enum_def612 = frozenset([62]) FOLLOW_enum_name_in_enum_def614 = frozenset([19]) FOLLOW_BLOCK_OPEN_in_enum_def616 = frozenset([9, 20, 62]) FOLLOW_enum_content_in_enum_def618 = frozenset([20]) FOLLOW_BLOCK_CLOSE_in_enum_def620 = frozenset([1]) FOLLOW_IDENTIFIER_in_enum_name646 = frozenset([1]) FOLLOW_option_line_def_in_enum_content656 = frozenset([1, 9, 62]) FOLLOW_enum_item_def_in_enum_content660 = frozenset([1, 9, 62]) FOLLOW_IDENTIFIER_in_enum_item_def674 = frozenset([25]) FOLLOW_EQUALS_in_enum_item_def676 = frozenset([52]) FOLLOW_INTEGER_LITERAL_in_enum_item_def678 = frozenset([23, 28]) FOLLOW_option_field_def_in_enum_item_def680 = frozenset([28]) FOLLOW_ITEM_TERMINATOR_in_enum_item_def683 = frozenset([1]) FOLLOW_MESSAGE_LITERAL_in_message_def717 = frozenset([62]) FOLLOW_message_name_in_message_def719 = frozenset([19]) FOLLOW_BLOCK_OPEN_in_message_def721 = frozenset([9, 10, 11, 13, 20, 32]) FOLLOW_message_content_in_message_def723 = frozenset([20]) FOLLOW_BLOCK_CLOSE_in_message_def726 = frozenset([1]) FOLLOW_IDENTIFIER_in_message_name753 = frozenset([1]) FOLLOW_option_line_def_in_message_content763 = frozenset([1, 9, 10, 11, 13, 32]) FOLLOW_message_item_def_in_message_content767 = frozenset([1, 9, 10, 11, 13, 32]) FOLLOW_message_def_in_message_content771 = frozenset([1, 9, 10, 11, 13, 32]) FOLLOW_enum_def_in_message_content775 = frozenset([1, 9, 10, 11, 13, 32]) FOLLOW_message_ext_def_in_message_content779 = frozenset([1, 9, 10, 11, 13, 32]) FOLLOW_PROTOBUF_SCOPE_LITERAL_in_message_item_def792 = frozenset([48, 62, 63]) FOLLOW_proto_type_in_message_item_def794 = frozenset([62]) FOLLOW_IDENTIFIER_in_message_item_def796 = frozenset([25]) FOLLOW_EQUALS_in_message_item_def798 = frozenset([52]) FOLLOW_INTEGER_LITERAL_in_message_item_def800 = frozenset([23, 28]) FOLLOW_option_field_def_in_message_item_def802 = frozenset([28]) FOLLOW_ITEM_TERMINATOR_in_message_item_def805 = frozenset([1]) FOLLOW_EXTENSIONS_DEF_LITERAL_in_message_ext_def840 = frozenset([52]) FOLLOW_INTEGER_LITERAL_in_message_ext_def842 = frozenset([14]) FOLLOW_EXTENSIONS_TO_LITERAL_in_message_ext_def844 = frozenset([15, 52]) FOLLOW_INTEGER_LITERAL_in_message_ext_def849 = frozenset([28]) FOLLOW_EXTENSIONS_MAX_LITERAL_in_message_ext_def855 = frozenset([28]) FOLLOW_ITEM_TERMINATOR_in_message_ext_def858 = frozenset([1]) FOLLOW_EXTEND_LITERAL_in_ext_def889 = frozenset([62, 63]) FOLLOW_ext_name_in_ext_def891 = frozenset([19]) FOLLOW_BLOCK_OPEN_in_ext_def893 = frozenset([9, 10, 11, 20, 32]) FOLLOW_ext_content_in_ext_def895 = frozenset([20]) FOLLOW_BLOCK_CLOSE_in_ext_def898 = frozenset([1]) FOLLOW_all_identifier_in_ext_name925 = frozenset([1]) FOLLOW_option_line_def_in_ext_content935 = frozenset([1, 9, 10, 11, 32]) FOLLOW_message_item_def_in_ext_content939 = frozenset([1, 9, 10, 11, 32]) FOLLOW_message_def_in_ext_content943 = frozenset([1, 9, 10, 11, 32]) FOLLOW_enum_def_in_ext_content947 = frozenset([1, 9, 10, 11, 32]) FOLLOW_SERVICE_LITERAL_in_service_def963 = frozenset([62]) FOLLOW_service_name_in_service_def965 = frozenset([19]) FOLLOW_BLOCK_OPEN_in_service_def967 = frozenset([9, 18, 20]) FOLLOW_service_content_in_service_def969 = frozenset([20]) FOLLOW_BLOCK_CLOSE_in_service_def972 = frozenset([1]) FOLLOW_IDENTIFIER_in_service_name999 = frozenset([1]) FOLLOW_option_line_def_in_service_content1009 = frozenset([1, 9, 18]) FOLLOW_rpc_def_in_service_content1013 = frozenset([1, 9, 18]) FOLLOW_RPC_LITERAL_in_rpc_def1028 = frozenset([62]) FOLLOW_rpc_name_in_rpc_def1030 = frozenset([21]) FOLLOW_PAREN_OPEN_in_rpc_def1032 = frozenset([62, 63]) FOLLOW_req_name_in_rpc_def1034 = frozenset([22]) FOLLOW_PAREN_CLOSE_in_rpc_def1036 = frozenset([17]) FOLLOW_RETURNS_LITERAL_in_rpc_def1038 = frozenset([21]) FOLLOW_PAREN_OPEN_in_rpc_def1040 = frozenset([62, 63]) FOLLOW_resp_name_in_rpc_def1042 = frozenset([22]) FOLLOW_PAREN_CLOSE_in_rpc_def1044 = frozenset([19, 28]) FOLLOW_BLOCK_OPEN_in_rpc_def1047 = frozenset([9, 20]) FOLLOW_option_line_def_in_rpc_def1049 = frozenset([9, 20]) FOLLOW_BLOCK_CLOSE_in_rpc_def1052 = frozenset([1, 28]) FOLLOW_ITEM_TERMINATOR_in_rpc_def1054 = frozenset([1]) FOLLOW_ITEM_TERMINATOR_in_rpc_def1059 = frozenset([1]) FOLLOW_IDENTIFIER_in_rpc_name1091 = frozenset([1]) FOLLOW_all_identifier_in_req_name1099 = frozenset([1]) FOLLOW_all_identifier_in_resp_name1107 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("proto_parserLexer", proto_parser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "thelinuxkid/python-protolite", "path": "protolite/parser/proto_parser.py", "copies": "1", "size": "136654", "license": "mit", "hash": -1846773940166551800, "line_mean": 35.5287356322, "line_max": 301, "alpha_frac": 0.5615861958, "autogenerated": false, "ratio": 3.792573268206039, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4854159464006039, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 src/SavedFSM/BuildFSM.g 2012-03-12 22:19:58 import sys from antlr3 import * from antlr3.tree import * from antlr3.compat import set, frozenset from pyon.core.governance.conversation.core.fsm import FSM from pyon.core.governance.conversation.core.fsm import ExceptionFSM from pyon.core.governance.conversation.core.transition import TransitionFactory from pyon.core.governance.conversation.core.local_type import LocalType from pyon.core.governance.conversation.extensions.simple_logic import * def checkMessages(fsm): print "Message is checked: %s" %(fsm.input_symbol) def nothing(fsm): print "I am invoked for empty transition" def generate_ints(): x = 1 while True: yield x x += 1 def format_state_name(state, parent_state = None): if parent_state is not None: return "%s_%s" %(parent_state, state) else: return state class FSMBuilderState(object): def __init__(self, parent= None): self.state_gen = generate_ints() self.current_state = self.state_gen.next() if (parent is not None): self.parent = parent self.fsm = FSM(format_state_name(self.current_state, self.parent.get_current_state())) self.set_interrupt_transition = self.parent.set_interrupt_transition self.top_parent = parent.top_parent else: self.fsm = FSM(self.current_state) self.top_parent = self self.set_interrupt_transition = False self.start_new_par_branch = False # Choice States self.choice_start_state = [] self.choice_end_state = [] # Recursion states self.recursions_states = {} self.parent = parent def format_state_name(self, state): if self.parent is not None: return "%s_%s" %(self.parent.get_current_state(), state) else: return state def move_current_state(self, value = None): if value is None: self.current_state = self.state_gen.next() else: self.current_state = value return self.current_state def get_current_state(self): return self.current_state def add_transition(self, transition, assertion = None, transition_context = None): if assertion is not None: preprocess_assertion = Assertion.create(assertion) else: preprocess_assertion = assertion if self.parent is not None: suffix = self.parent.get_current_state() self.parent.fsm.add_nested_transition(transition, self.parent.get_current_state(), format_state_name(self.get_current_state(), suffix), format_state_name(self.move_current_state(), suffix), preprocess_assertion, transition_context) else: self.fsm.add_transition(transition, self.get_current_state(), self.move_current_state(), preprocess_assertion, transition_context) # We are in interrup block and want to set the first transition that occur as interrupt_transition # This is a global try catch. We assume that do wraps the whole program if self.set_interrupt_transition: self.set_interrupt_transition = False self.fsm.add_interrupt_transition(transition, self.interrupt_start_state) # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types RESV=12 ANNOTATION=25 ASSERTION=28 PARALLEL=19 T__61=61 ID=26 T__60=60 EOF=-1 PROTOCOL=20 TYPE=14 T__55=55 INTERACTION=4 T__56=56 ML_COMMENT=32 T__57=57 T__58=58 ROLES=24 T__51=51 T__52=52 T__53=53 T__54=54 T__59=59 FULLSTOP=11 PLUS=7 SEND=13 DIGIT=30 T__50=50 T__42=42 T__43=43 T__40=40 T__41=41 T__46=46 T__47=47 T__44=44 T__45=45 LINE_COMMENT=33 T__48=48 T__49=49 RECLABEL=18 NUMBER=29 WHITESPACE=31 INT=5 VALUE=15 MULT=9 MINUS=8 ASSERT=21 UNORDERED=17 EMPTY=23 StringLiteral=27 T__34=34 GLOBAL_ESCAPE=22 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 BRANCH=16 DIV=10 STRING=6 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "INTERACTION", "INT", "STRING", "PLUS", "MINUS", "MULT", "DIV", "FULLSTOP", "RESV", "SEND", "TYPE", "VALUE", "BRANCH", "UNORDERED", "RECLABEL", "PARALLEL", "PROTOCOL", "ASSERT", "GLOBAL_ESCAPE", "EMPTY", "ROLES", "ANNOTATION", "ID", "StringLiteral", "ASSERTION", "NUMBER", "DIGIT", "WHITESPACE", "ML_COMMENT", "LINE_COMMENT", "'import'", "'protocol'", "','", "';'", "'from'", "'as'", "'at'", "'{'", "'}'", "'('", "')'", "'role'", "'introduces'", "':'", "'to'", "'choice'", "'or'", "'repeat'", "'rec'", "'end'", "'run'", "'inline'", "'parallel'", "'and'", "'do'", "'interrupt'", "'by'", "'unordered'" ] class BuildFSM(TreeParser): grammarFileName = "src/SavedFSM/BuildFSM.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(BuildFSM, self).__init__(input, state, *args, **kwargs) # memory here is used only for logging and debugging purposes. # We append bebugging information to memory so we can print it later. self.memory = [] self.roles = [] self.main_fsm = FSMBuilderState() self.current_fsm = self.main_fsm # $ANTLR start "description" # src/SavedFSM/BuildFSM.g:107:1: description : ^( PROTOCOL roleName parameterDefs ( activityDef )+ ) ; def description(self, ): try: try: # src/SavedFSM/BuildFSM.g:107:12: ( ^( PROTOCOL roleName parameterDefs ( activityDef )+ ) ) # src/SavedFSM/BuildFSM.g:107:14: ^( PROTOCOL roleName parameterDefs ( activityDef )+ ) pass self.match(self.input, PROTOCOL, self.FOLLOW_PROTOCOL_in_description52) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_roleName_in_description54) self.roleName() self._state.following.pop() self._state.following.append(self.FOLLOW_parameterDefs_in_description56) self.parameterDefs() self._state.following.pop() # src/SavedFSM/BuildFSM.g:107:48: ( activityDef )+ cnt1 = 0 while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((RESV <= LA1_0 <= SEND) or (RECLABEL <= LA1_0 <= PARALLEL) or LA1_0 == GLOBAL_ESCAPE or LA1_0 == 49 or (51 <= LA1_0 <= 52)) : alt1 = 1 if alt1 == 1: # src/SavedFSM/BuildFSM.g:107:48: activityDef pass self._state.following.append(self.FOLLOW_activityDef_in_description58) self.activityDef() self._state.following.pop() else: if cnt1 >= 1: break #loop1 eee = EarlyExitException(1, self.input) raise eee cnt1 += 1 self.match(self.input, UP, None) #action start #print "ProtocolDefinition" #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "description" # $ANTLR start "parameterDefs" # src/SavedFSM/BuildFSM.g:108:1: parameterDefs : ^( ROLES ( roleName )+ ) ; def parameterDefs(self, ): try: try: # src/SavedFSM/BuildFSM.g:108:14: ( ^( ROLES ( roleName )+ ) ) # src/SavedFSM/BuildFSM.g:108:16: ^( ROLES ( roleName )+ ) pass self.match(self.input, ROLES, self.FOLLOW_ROLES_in_parameterDefs71) self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:108:24: ( roleName )+ cnt2 = 0 while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == ID) : alt2 = 1 if alt2 == 1: # src/SavedFSM/BuildFSM.g:108:24: roleName pass self._state.following.append(self.FOLLOW_roleName_in_parameterDefs73) self.roleName() self._state.following.pop() else: if cnt2 >= 1: break #loop2 eee = EarlyExitException(2, self.input) raise eee cnt2 += 1 self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "parameterDefs" # $ANTLR start "activityDef" # src/SavedFSM/BuildFSM.g:109:1: activityDef : ( ^( RESV (rlabel= ID )? ( ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) ) role= ID ( ^( ASSERT (assertion= ASSERTION )? ) ) ) | ^( SEND (slabel= ID )? ( ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) ) role= ID ( ^( ASSERT (assertion= ASSERTION )? ) ) ) | ^( 'choice' ( ^( BRANCH ( activityDef )+ ) )+ ) | ^( PARALLEL ( ^( BRANCH ( activityDef )+ ) )+ ) | ^( 'repeat' ( ^( BRANCH ( activityDef )+ ) ) ) | ^( 'rec' label= ID ( ^( BRANCH ( activityDef )+ ) ) ) | ^( 'RECLABEL' labelID= ID ) | ^( GLOBAL_ESCAPE ( ^( 'do' ( ( activityDef )+ ) ) ) ( ^( 'interrupt' roleName ( ( activityDef )+ ) ) ) ) ); def activityDef(self, ): rlabel = None val = None vtype = None role = None assertion = None slabel = None label = None labelID = None try: try: # src/SavedFSM/BuildFSM.g:109:12: ( ^( RESV (rlabel= ID )? ( ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) ) role= ID ( ^( ASSERT (assertion= ASSERTION )? ) ) ) | ^( SEND (slabel= ID )? ( ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) ) role= ID ( ^( ASSERT (assertion= ASSERTION )? ) ) ) | ^( 'choice' ( ^( BRANCH ( activityDef )+ ) )+ ) | ^( PARALLEL ( ^( BRANCH ( activityDef )+ ) )+ ) | ^( 'repeat' ( ^( BRANCH ( activityDef )+ ) ) ) | ^( 'rec' label= ID ( ^( BRANCH ( activityDef )+ ) ) ) | ^( 'RECLABEL' labelID= ID ) | ^( GLOBAL_ESCAPE ( ^( 'do' ( ( activityDef )+ ) ) ) ( ^( 'interrupt' roleName ( ( activityDef )+ ) ) ) ) ) alt19 = 8 LA19 = self.input.LA(1) if LA19 == RESV: alt19 = 1 elif LA19 == SEND: alt19 = 2 elif LA19 == 49: alt19 = 3 elif LA19 == PARALLEL: alt19 = 4 elif LA19 == 51: alt19 = 5 elif LA19 == 52: alt19 = 6 elif LA19 == RECLABEL: alt19 = 7 elif LA19 == GLOBAL_ESCAPE: alt19 = 8 else: nvae = NoViableAltException("", 19, 0, self.input) raise nvae if alt19 == 1: # src/SavedFSM/BuildFSM.g:110:2: ^( RESV (rlabel= ID )? ( ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) ) role= ID ( ^( ASSERT (assertion= ASSERTION )? ) ) ) pass self.match(self.input, RESV, self.FOLLOW_RESV_in_activityDef85) #action start local_context = [] label = '' #action end self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:113:5: (rlabel= ID )? alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == ID) : alt3 = 1 if alt3 == 1: # src/SavedFSM/BuildFSM.g:113:6: rlabel= ID pass rlabel=self.match(self.input, ID, self.FOLLOW_ID_in_activityDef98) #action start if (rlabel is not None): label = rlabel.text self.memory.append('before setting the label:' + label) #action end # src/SavedFSM/BuildFSM.g:116:5: ( ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) ) # src/SavedFSM/BuildFSM.g:116:6: ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) pass self.match(self.input, VALUE, self.FOLLOW_VALUE_in_activityDef110) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:116:14: ( (val= ID (vtype= ( INT | STRING ) )? ) )* while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == ID) : alt5 = 1 if alt5 == 1: # src/SavedFSM/BuildFSM.g:116:15: (val= ID (vtype= ( INT | STRING ) )? ) pass # src/SavedFSM/BuildFSM.g:116:15: (val= ID (vtype= ( INT | STRING ) )? ) # src/SavedFSM/BuildFSM.g:116:16: val= ID (vtype= ( INT | STRING ) )? pass val=self.match(self.input, ID, self.FOLLOW_ID_in_activityDef116) # src/SavedFSM/BuildFSM.g:116:28: (vtype= ( INT | STRING ) )? alt4 = 2 LA4_0 = self.input.LA(1) if ((INT <= LA4_0 <= STRING)) : alt4 = 1 if alt4 == 1: # src/SavedFSM/BuildFSM.g:116:28: vtype= ( INT | STRING ) pass vtype = self.input.LT(1) if (INT <= self.input.LA(1) <= STRING): self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse #action start if ((val is not None) and (vtype is not None)): local_context.append((val.text, vtype.text)) #action end else: break #loop5 self.match(self.input, UP, None) role=self.match(self.input, ID, self.FOLLOW_ID_in_activityDef141) #action start if not(role.text in self.roles): self.roles.append(role.text) #action end # src/SavedFSM/BuildFSM.g:118:5: ( ^( ASSERT (assertion= ASSERTION )? ) ) # src/SavedFSM/BuildFSM.g:118:6: ^( ASSERT (assertion= ASSERTION )? ) pass self.match(self.input, ASSERT, self.FOLLOW_ASSERT_in_activityDef151) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:118:15: (assertion= ASSERTION )? alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == ASSERTION) : alt6 = 1 if alt6 == 1: # src/SavedFSM/BuildFSM.g:118:16: assertion= ASSERTION pass assertion=self.match(self.input, ASSERTION, self.FOLLOW_ASSERTION_in_activityDef156) self.match(self.input, UP, None) self.match(self.input, UP, None) #action start self.memory.append('label is:' + label); self.current_fsm.add_transition(TransitionFactory.create(LocalType.RESV, label, role), assertion, local_context) #action end elif alt19 == 2: # src/SavedFSM/BuildFSM.g:123:3: ^( SEND (slabel= ID )? ( ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) ) role= ID ( ^( ASSERT (assertion= ASSERTION )? ) ) ) pass self.match(self.input, SEND, self.FOLLOW_SEND_in_activityDef169) #action start local_context = [] label = '' #action end self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:126:5: (slabel= ID )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == ID) : alt7 = 1 if alt7 == 1: # src/SavedFSM/BuildFSM.g:126:6: slabel= ID pass slabel=self.match(self.input, ID, self.FOLLOW_ID_in_activityDef182) #action start self.memory.append('send' + slabel.text) if (slabel is not None): label = slabel.text #action end # src/SavedFSM/BuildFSM.g:129:12: ( ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) ) # src/SavedFSM/BuildFSM.g:129:13: ^( VALUE ( (val= ID (vtype= ( INT | STRING ) )? ) )* ) pass self.match(self.input, VALUE, self.FOLLOW_VALUE_in_activityDef201) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:129:21: ( (val= ID (vtype= ( INT | STRING ) )? ) )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == ID) : alt9 = 1 if alt9 == 1: # src/SavedFSM/BuildFSM.g:129:22: (val= ID (vtype= ( INT | STRING ) )? ) pass # src/SavedFSM/BuildFSM.g:129:22: (val= ID (vtype= ( INT | STRING ) )? ) # src/SavedFSM/BuildFSM.g:129:23: val= ID (vtype= ( INT | STRING ) )? pass val=self.match(self.input, ID, self.FOLLOW_ID_in_activityDef207) # src/SavedFSM/BuildFSM.g:129:35: (vtype= ( INT | STRING ) )? alt8 = 2 LA8_0 = self.input.LA(1) if ((INT <= LA8_0 <= STRING)) : alt8 = 1 if alt8 == 1: # src/SavedFSM/BuildFSM.g:129:35: vtype= ( INT | STRING ) pass vtype = self.input.LT(1) if (INT <= self.input.LA(1) <= STRING): self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse #action start if ((val is not None) and (vtype is not None)): local_context.append((val.text, vtype.text)) #action end else: break #loop9 self.match(self.input, UP, None) role=self.match(self.input, ID, self.FOLLOW_ID_in_activityDef236) #action start if not(role.text in self.roles): self.roles.append(role.text) #action end # src/SavedFSM/BuildFSM.g:131:5: ( ^( ASSERT (assertion= ASSERTION )? ) ) # src/SavedFSM/BuildFSM.g:131:6: ^( ASSERT (assertion= ASSERTION )? ) pass self.match(self.input, ASSERT, self.FOLLOW_ASSERT_in_activityDef246) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:131:15: (assertion= ASSERTION )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == ASSERTION) : alt10 = 1 if alt10 == 1: # src/SavedFSM/BuildFSM.g:131:16: assertion= ASSERTION pass assertion=self.match(self.input, ASSERTION, self.FOLLOW_ASSERTION_in_activityDef251) self.match(self.input, UP, None) self.match(self.input, UP, None) #action start self.memory.append('In SEND assertion') #action end #action start self.current_fsm.add_transition(TransitionFactory.create(LocalType.SEND, label, role), assertion, local_context) #action end elif alt19 == 3: # src/SavedFSM/BuildFSM.g:136:3: ^( 'choice' ( ^( BRANCH ( activityDef )+ ) )+ ) pass self.match(self.input, 49, self.FOLLOW_49_in_activityDef270) #action start self.memory.append('enter choice state') self.current_fsm.choice_start_state.append(self.current_fsm.get_current_state()) self.current_fsm.choice_end_state.append(self.current_fsm.state_gen.next()) #action end self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:141:2: ( ^( BRANCH ( activityDef )+ ) )+ cnt12 = 0 while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == BRANCH) : alt12 = 1 if alt12 == 1: # src/SavedFSM/BuildFSM.g:141:3: ^( BRANCH ( activityDef )+ ) pass self.match(self.input, BRANCH, self.FOLLOW_BRANCH_in_activityDef280) #action start self.memory.append('enter choice branch and save the current state') self.current_fsm.move_current_state(self.current_fsm.choice_start_state[-1]) #action end self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:146:4: ( activityDef )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((RESV <= LA11_0 <= SEND) or (RECLABEL <= LA11_0 <= PARALLEL) or LA11_0 == GLOBAL_ESCAPE or LA11_0 == 49 or (51 <= LA11_0 <= 52)) : alt11 = 1 if alt11 == 1: # src/SavedFSM/BuildFSM.g:146:4: activityDef pass self._state.following.append(self.FOLLOW_activityDef_in_activityDef286) self.activityDef() self._state.following.pop() else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 self.match(self.input, UP, None) #action start self.memory.append('exit choice branch and set the current state to the end state for the choice') self.current_fsm.fsm.add_transition(self.current_fsm.fsm.EMPTY_TRANSITION, self.current_fsm.get_current_state(), self.current_fsm.choice_end_state[-1]) #action end else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 self.match(self.input, UP, None) #action start self.memory.append('set the current state to be equal to the end state for the choice') self.current_fsm.move_current_state(self.current_fsm.choice_end_state[-1]) self.current_fsm.choice_end_state.pop() self.current_fsm.choice_start_state.pop() #action end elif alt19 == 4: # src/SavedFSM/BuildFSM.g:158:4: ^( PARALLEL ( ^( BRANCH ( activityDef )+ ) )+ ) pass self.match(self.input, PARALLEL, self.FOLLOW_PARALLEL_in_activityDef305) #action start self.memory.append('enter parallel state') self.parallel_root = self.current_fsm #action end self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:163:2: ( ^( BRANCH ( activityDef )+ ) )+ cnt14 = 0 while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == BRANCH) : alt14 = 1 if alt14 == 1: # src/SavedFSM/BuildFSM.g:163:3: ^( BRANCH ( activityDef )+ ) pass self.match(self.input, BRANCH, self.FOLLOW_BRANCH_in_activityDef322) #action start self.memory.append('enter parallel branch') nested_fsm = FSMBuilderState(self.parallel_root) self.parallel_root.fsm.add_fsm_to_memory(self.parallel_root.get_current_state(), nested_fsm.fsm) self.current_fsm = nested_fsm #action end self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:170:2: ( activityDef )+ cnt13 = 0 while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if ((RESV <= LA13_0 <= SEND) or (RECLABEL <= LA13_0 <= PARALLEL) or LA13_0 == GLOBAL_ESCAPE or LA13_0 == 49 or (51 <= LA13_0 <= 52)) : alt13 = 1 if alt13 == 1: # src/SavedFSM/BuildFSM.g:170:3: activityDef pass self._state.following.append(self.FOLLOW_activityDef_in_activityDef331) self.activityDef() self._state.following.pop() else: if cnt13 >= 1: break #loop13 eee = EarlyExitException(13, self.input) raise eee cnt13 += 1 self.match(self.input, UP, None) #action start self.memory.append('exit parallel branch') self.current_fsm.add_transition(self.current_fsm.fsm.END_PAR_TRANSITION) #action end else: if cnt14 >= 1: break #loop14 eee = EarlyExitException(14, self.input) raise eee cnt14 += 1 self.match(self.input, UP, None) #action start self.memory.append('exit parallel state') self.current_fsm = self.current_fsm.parent self.current_fsm.fsm.add_transition(self.current_fsm.fsm.EMPTY_TRANSITION, self.current_fsm.get_current_state(), self.current_fsm.move_current_state()) #action end elif alt19 == 5: # src/SavedFSM/BuildFSM.g:180:3: ^( 'repeat' ( ^( BRANCH ( activityDef )+ ) ) ) pass self.match(self.input, 51, self.FOLLOW_51_in_activityDef352) #action start self.memory.append('enter repeat state') #action end self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:182:2: ( ^( BRANCH ( activityDef )+ ) ) # src/SavedFSM/BuildFSM.g:182:3: ^( BRANCH ( activityDef )+ ) pass self.match(self.input, BRANCH, self.FOLLOW_BRANCH_in_activityDef361) self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:182:12: ( activityDef )+ cnt15 = 0 while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if ((RESV <= LA15_0 <= SEND) or (RECLABEL <= LA15_0 <= PARALLEL) or LA15_0 == GLOBAL_ESCAPE or LA15_0 == 49 or (51 <= LA15_0 <= 52)) : alt15 = 1 if alt15 == 1: # src/SavedFSM/BuildFSM.g:182:13: activityDef pass self._state.following.append(self.FOLLOW_activityDef_in_activityDef364) self.activityDef() self._state.following.pop() #action start self.memory.append('repeat statement') #action end else: if cnt15 >= 1: break #loop15 eee = EarlyExitException(15, self.input) raise eee cnt15 += 1 self.match(self.input, UP, None) self.match(self.input, UP, None) #action start self.memory.append('exit repeat state') #action end elif alt19 == 6: # src/SavedFSM/BuildFSM.g:185:10: ^( 'rec' label= ID ( ^( BRANCH ( activityDef )+ ) ) ) pass self.match(self.input, 52, self.FOLLOW_52_in_activityDef388) self.match(self.input, DOWN, None) label=self.match(self.input, ID, self.FOLLOW_ID_in_activityDef394) #action start self.memory.append('enter rec state ' + label.text + str(self.current_fsm.get_current_state())) self.current_fsm.recursions_states.setdefault(label.text, (self.current_fsm.format_state_name(self.current_fsm.get_current_state()), True)) #action end # src/SavedFSM/BuildFSM.g:189:2: ( ^( BRANCH ( activityDef )+ ) ) # src/SavedFSM/BuildFSM.g:189:3: ^( BRANCH ( activityDef )+ ) pass self.match(self.input, BRANCH, self.FOLLOW_BRANCH_in_activityDef410) self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:189:12: ( activityDef )+ cnt16 = 0 while True: #loop16 alt16 = 2 LA16_0 = self.input.LA(1) if ((RESV <= LA16_0 <= SEND) or (RECLABEL <= LA16_0 <= PARALLEL) or LA16_0 == GLOBAL_ESCAPE or LA16_0 == 49 or (51 <= LA16_0 <= 52)) : alt16 = 1 if alt16 == 1: # src/SavedFSM/BuildFSM.g:189:13: activityDef pass self._state.following.append(self.FOLLOW_activityDef_in_activityDef413) self.activityDef() self._state.following.pop() #action start self.memory.append('rec statement') #action end else: if cnt16 >= 1: break #loop16 eee = EarlyExitException(16, self.input) raise eee cnt16 += 1 self.match(self.input, UP, None) self.match(self.input, UP, None) #action start (start_state, isActive) = self.current_fsm.recursions_states.get(label.text) self.memory.append('exit rec state ' + label.text + 'start_state' + str(start_state)) self.current_fsm.recursions_states[label.text] = (start_state, False) #action end elif alt19 == 7: # src/SavedFSM/BuildFSM.g:196:3: ^( 'RECLABEL' labelID= ID ) pass self.match(self.input, RECLABEL, self.FOLLOW_RECLABEL_in_activityDef431) self.match(self.input, DOWN, None) labelID=self.match(self.input, ID, self.FOLLOW_ID_in_activityDef438) #action start (start_rec_state, isActive) = self.current_fsm.recursions_states.get(labelID.text) self.memory.append('rec label:' + labelID.text + 'starts from state:' + str(start_rec_state)) if isActive: self.current_fsm.fsm.add_transition(self.current_fsm.fsm.EMPTY_TRANSITION, self.current_fsm.format_state_name(self.current_fsm.get_current_state()), start_rec_state) # Generate unreachable state for the choice construct self.current_fsm.move_current_state() else: raise ExceptionFSM('Calling a recusrion label from a recursion that is not valid') #action end self.match(self.input, UP, None) #action start # Do not need it for no #self.current_fsm.fsm.copy_transitions(self.current_fsm.recursions_states[labelID.text], self.current_fsm.get_current_state()) #action end elif alt19 == 8: # src/SavedFSM/BuildFSM.g:213:3: ^( GLOBAL_ESCAPE ( ^( 'do' ( ( activityDef )+ ) ) ) ( ^( 'interrupt' roleName ( ( activityDef )+ ) ) ) ) pass self.match(self.input, GLOBAL_ESCAPE, self.FOLLOW_GLOBAL_ESCAPE_in_activityDef452) self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:214:5: ( ^( 'do' ( ( activityDef )+ ) ) ) # src/SavedFSM/BuildFSM.g:214:6: ^( 'do' ( ( activityDef )+ ) ) pass self.match(self.input, 58, self.FOLLOW_58_in_activityDef461) self.match(self.input, DOWN, None) # src/SavedFSM/BuildFSM.g:214:13: ( ( activityDef )+ ) # src/SavedFSM/BuildFSM.g:214:14: ( activityDef )+ pass # src/SavedFSM/BuildFSM.g:214:14: ( activityDef )+ cnt17 = 0 while True: #loop17 alt17 = 2 LA17_0 = self.input.LA(1) if ((RESV <= LA17_0 <= SEND) or (RECLABEL <= LA17_0 <= PARALLEL) or LA17_0 == GLOBAL_ESCAPE or LA17_0 == 49 or (51 <= LA17_0 <= 52)) : alt17 = 1 if alt17 == 1: # src/SavedFSM/BuildFSM.g:214:14: activityDef pass self._state.following.append(self.FOLLOW_activityDef_in_activityDef464) self.activityDef() self._state.following.pop() else: if cnt17 >= 1: break #loop17 eee = EarlyExitException(17, self.input) raise eee cnt17 += 1 #action start self.current_fsm.fsm.final_state = self.current_fsm.get_current_state() #action end self.match(self.input, UP, None) # src/SavedFSM/BuildFSM.g:215:5: ( ^( 'interrupt' roleName ( ( activityDef )+ ) ) ) # src/SavedFSM/BuildFSM.g:215:6: ^( 'interrupt' roleName ( ( activityDef )+ ) ) pass self.match(self.input, 59, self.FOLLOW_59_in_activityDef477) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_roleName_in_activityDef479) self.roleName() self._state.following.pop() #action start self.memory.append('before setting interrupt_transition to True') self.current_fsm.interrupt_start_state = self.current_fsm.move_current_state() self.current_fsm.set_interrupt_transition = True #action end # src/SavedFSM/BuildFSM.g:218:56: ( ( activityDef )+ ) # src/SavedFSM/BuildFSM.g:218:57: ( activityDef )+ pass # src/SavedFSM/BuildFSM.g:218:57: ( activityDef )+ cnt18 = 0 while True: #loop18 alt18 = 2 LA18_0 = self.input.LA(1) if ((RESV <= LA18_0 <= SEND) or (RECLABEL <= LA18_0 <= PARALLEL) or LA18_0 == GLOBAL_ESCAPE or LA18_0 == 49 or (51 <= LA18_0 <= 52)) : alt18 = 1 if alt18 == 1: # src/SavedFSM/BuildFSM.g:218:57: activityDef pass self._state.following.append(self.FOLLOW_activityDef_in_activityDef488) self.activityDef() self._state.following.pop() else: if cnt18 >= 1: break #loop18 eee = EarlyExitException(18, self.input) raise eee cnt18 += 1 self.match(self.input, UP, None) self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "activityDef" # $ANTLR start "roleName" # src/SavedFSM/BuildFSM.g:220:1: roleName : role= ID ; def roleName(self, ): role = None try: try: # src/SavedFSM/BuildFSM.g:220:9: (role= ID ) # src/SavedFSM/BuildFSM.g:220:11: role= ID pass role=self.match(self.input, ID, self.FOLLOW_ID_in_roleName505) #action start if not(role.text in self.roles): self.roles.append(role.text) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "roleName" # $ANTLR start "labelName" # src/SavedFSM/BuildFSM.g:223:1: labelName : ID ; def labelName(self, ): try: try: # src/SavedFSM/BuildFSM.g:223:10: ( ID ) # src/SavedFSM/BuildFSM.g:223:12: ID pass self.match(self.input, ID, self.FOLLOW_ID_in_labelName513) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "labelName" # $ANTLR start "roleDef" # src/SavedFSM/BuildFSM.g:224:1: roleDef : ID ; def roleDef(self, ): try: try: # src/SavedFSM/BuildFSM.g:224:8: ( ID ) # src/SavedFSM/BuildFSM.g:224:10: ID pass self.match(self.input, ID, self.FOLLOW_ID_in_roleDef519) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "roleDef" # $ANTLR start "primitivetype" # src/SavedFSM/BuildFSM.g:225:1: primitivetype : INT ; def primitivetype(self, ): try: try: # src/SavedFSM/BuildFSM.g:225:15: ( INT ) # src/SavedFSM/BuildFSM.g:225:16: INT pass self.match(self.input, INT, self.FOLLOW_INT_in_primitivetype525) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "primitivetype" # Delegated rules FOLLOW_PROTOCOL_in_description52 = frozenset([2]) FOLLOW_roleName_in_description54 = frozenset([24]) FOLLOW_parameterDefs_in_description56 = frozenset([12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_activityDef_in_description58 = frozenset([3, 12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_ROLES_in_parameterDefs71 = frozenset([2]) FOLLOW_roleName_in_parameterDefs73 = frozenset([3, 26]) FOLLOW_RESV_in_activityDef85 = frozenset([2]) FOLLOW_ID_in_activityDef98 = frozenset([15]) FOLLOW_VALUE_in_activityDef110 = frozenset([2]) FOLLOW_ID_in_activityDef116 = frozenset([3, 5, 6, 26]) FOLLOW_set_in_activityDef120 = frozenset([3, 26]) FOLLOW_ID_in_activityDef141 = frozenset([21]) FOLLOW_ASSERT_in_activityDef151 = frozenset([2]) FOLLOW_ASSERTION_in_activityDef156 = frozenset([3]) FOLLOW_SEND_in_activityDef169 = frozenset([2]) FOLLOW_ID_in_activityDef182 = frozenset([15]) FOLLOW_VALUE_in_activityDef201 = frozenset([2]) FOLLOW_ID_in_activityDef207 = frozenset([3, 5, 6, 26]) FOLLOW_set_in_activityDef212 = frozenset([3, 26]) FOLLOW_ID_in_activityDef236 = frozenset([21]) FOLLOW_ASSERT_in_activityDef246 = frozenset([2]) FOLLOW_ASSERTION_in_activityDef251 = frozenset([3]) FOLLOW_49_in_activityDef270 = frozenset([2]) FOLLOW_BRANCH_in_activityDef280 = frozenset([2]) FOLLOW_activityDef_in_activityDef286 = frozenset([3, 12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_PARALLEL_in_activityDef305 = frozenset([2]) FOLLOW_BRANCH_in_activityDef322 = frozenset([2]) FOLLOW_activityDef_in_activityDef331 = frozenset([3, 12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_51_in_activityDef352 = frozenset([2]) FOLLOW_BRANCH_in_activityDef361 = frozenset([2]) FOLLOW_activityDef_in_activityDef364 = frozenset([3, 12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_52_in_activityDef388 = frozenset([2]) FOLLOW_ID_in_activityDef394 = frozenset([16]) FOLLOW_BRANCH_in_activityDef410 = frozenset([2]) FOLLOW_activityDef_in_activityDef413 = frozenset([3, 12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_RECLABEL_in_activityDef431 = frozenset([2]) FOLLOW_ID_in_activityDef438 = frozenset([3]) FOLLOW_GLOBAL_ESCAPE_in_activityDef452 = frozenset([2]) FOLLOW_58_in_activityDef461 = frozenset([2]) FOLLOW_activityDef_in_activityDef464 = frozenset([3, 12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_59_in_activityDef477 = frozenset([2]) FOLLOW_roleName_in_activityDef479 = frozenset([12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_activityDef_in_activityDef488 = frozenset([3, 12, 13, 18, 19, 22, 49, 51, 52]) FOLLOW_ID_in_roleName505 = frozenset([1]) FOLLOW_ID_in_labelName513 = frozenset([1]) FOLLOW_ID_in_roleDef519 = frozenset([1]) FOLLOW_INT_in_primitivetype525 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import WalkerMain main = WalkerMain(BuildFSM) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ooici/pyon", "path": "pyon/core/governance/conversation/parsing/BuildFSM.py", "copies": "1", "size": "47270", "license": "bsd-2-clause", "hash": -2051810926013478100, "line_mean": 36.2498029945, "line_max": 667, "alpha_frac": 0.4573725407, "autogenerated": false, "ratio": 3.970934139784946, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4928306680484946, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 src/SavedFSM/Monitor.g 2012-03-12 22:09:37 import sys from antlr3 import * from antlr3.compat import set, frozenset from antlr3.tree import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types RESV=12 ANNOTATION=25 ASSERTION=28 PARALLEL=19 ID=26 T__61=61 EOF=-1 T__60=60 PROTOCOL=20 TYPE=14 T__55=55 ML_COMMENT=32 T__56=56 INTERACTION=4 T__57=57 ROLES=24 T__58=58 T__51=51 T__52=52 T__53=53 T__54=54 T__59=59 FULLSTOP=11 PLUS=7 SEND=13 DIGIT=30 T__50=50 T__42=42 T__43=43 T__40=40 T__41=41 T__46=46 T__47=47 T__44=44 T__45=45 LINE_COMMENT=33 T__48=48 T__49=49 RECLABEL=18 NUMBER=29 WHITESPACE=31 INT=5 MINUS=8 MULT=9 VALUE=15 ASSERT=21 UNORDERED=17 EMPTY=23 StringLiteral=27 GLOBAL_ESCAPE=22 T__34=34 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 BRANCH=16 DIV=10 STRING=6 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "INTERACTION", "INT", "STRING", "PLUS", "MINUS", "MULT", "DIV", "FULLSTOP", "RESV", "SEND", "TYPE", "VALUE", "BRANCH", "UNORDERED", "RECLABEL", "PARALLEL", "PROTOCOL", "ASSERT", "GLOBAL_ESCAPE", "EMPTY", "ROLES", "ANNOTATION", "ID", "StringLiteral", "ASSERTION", "NUMBER", "DIGIT", "WHITESPACE", "ML_COMMENT", "LINE_COMMENT", "'import'", "'protocol'", "','", "';'", "'from'", "'as'", "'at'", "'{'", "'}'", "'('", "')'", "'role'", "'introduces'", "':'", "'to'", "'choice'", "'or'", "'repeat'", "'rec'", "'end'", "'run'", "'inline'", "'parallel'", "'and'", "'do'", "'interrupt'", "'by'", "'unordered'" ] class MonitorParser(Parser): grammarFileName = "src/SavedFSM/Monitor.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(MonitorParser, self).__init__(input, state, *args, **kwargs) self.dfa3 = self.DFA3( self, 3, eot = self.DFA3_eot, eof = self.DFA3_eof, min = self.DFA3_min, max = self.DFA3_max, accept = self.DFA3_accept, special = self.DFA3_special, transition = self.DFA3_transition ) self.dfa17 = self.DFA17( self, 17, eot = self.DFA17_eot, eof = self.DFA17_eof, min = self.DFA17_min, max = self.DFA17_max, accept = self.DFA17_accept, special = self.DFA17_special, transition = self.DFA17_transition ) self.dfa35 = self.DFA35( self, 35, eot = self.DFA35_eot, eof = self.DFA35_eof, min = self.DFA35_min, max = self.DFA35_max, accept = self.DFA35_accept, special = self.DFA35_special, transition = self.DFA35_transition ) self._adaptor = None self.adaptor = CommonTreeAdaptor() def getTreeAdaptor(self): return self._adaptor def setTreeAdaptor(self, adaptor): self._adaptor = adaptor adaptor = property(getTreeAdaptor, setTreeAdaptor) class description_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.description_return, self).__init__() self.tree = None # $ANTLR start "description" # src/SavedFSM/Monitor.g:39:1: description : ( ( ANNOTATION )* ( importProtocolStatement | importTypeStatement ) )* ( ANNOTATION )* protocolDef -> protocolDef ; def description(self, ): retval = self.description_return() retval.start = self.input.LT(1) root_0 = None ANNOTATION1 = None ANNOTATION4 = None importProtocolStatement2 = None importTypeStatement3 = None protocolDef5 = None ANNOTATION1_tree = None ANNOTATION4_tree = None stream_ANNOTATION = RewriteRuleTokenStream(self._adaptor, "token ANNOTATION") stream_importTypeStatement = RewriteRuleSubtreeStream(self._adaptor, "rule importTypeStatement") stream_protocolDef = RewriteRuleSubtreeStream(self._adaptor, "rule protocolDef") stream_importProtocolStatement = RewriteRuleSubtreeStream(self._adaptor, "rule importProtocolStatement") try: try: # src/SavedFSM/Monitor.g:39:12: ( ( ( ANNOTATION )* ( importProtocolStatement | importTypeStatement ) )* ( ANNOTATION )* protocolDef -> protocolDef ) # src/SavedFSM/Monitor.g:39:14: ( ( ANNOTATION )* ( importProtocolStatement | importTypeStatement ) )* ( ANNOTATION )* protocolDef pass # src/SavedFSM/Monitor.g:39:14: ( ( ANNOTATION )* ( importProtocolStatement | importTypeStatement ) )* while True: #loop3 alt3 = 2 alt3 = self.dfa3.predict(self.input) if alt3 == 1: # src/SavedFSM/Monitor.g:39:16: ( ANNOTATION )* ( importProtocolStatement | importTypeStatement ) pass # src/SavedFSM/Monitor.g:39:16: ( ANNOTATION )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == ANNOTATION) : alt1 = 1 if alt1 == 1: # src/SavedFSM/Monitor.g:39:18: ANNOTATION pass ANNOTATION1=self.match(self.input, ANNOTATION, self.FOLLOW_ANNOTATION_in_description241) if self._state.backtracking == 0: stream_ANNOTATION.add(ANNOTATION1) else: break #loop1 # src/SavedFSM/Monitor.g:39:32: ( importProtocolStatement | importTypeStatement ) alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == 34) : LA2_1 = self.input.LA(2) if (LA2_1 == 35) : alt2 = 1 elif ((ID <= LA2_1 <= StringLiteral)) : alt2 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 2, 1, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # src/SavedFSM/Monitor.g:39:34: importProtocolStatement pass self._state.following.append(self.FOLLOW_importProtocolStatement_in_description248) importProtocolStatement2 = self.importProtocolStatement() self._state.following.pop() if self._state.backtracking == 0: stream_importProtocolStatement.add(importProtocolStatement2.tree) elif alt2 == 2: # src/SavedFSM/Monitor.g:39:60: importTypeStatement pass self._state.following.append(self.FOLLOW_importTypeStatement_in_description252) importTypeStatement3 = self.importTypeStatement() self._state.following.pop() if self._state.backtracking == 0: stream_importTypeStatement.add(importTypeStatement3.tree) else: break #loop3 # src/SavedFSM/Monitor.g:39:85: ( ANNOTATION )* while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == ANNOTATION) : alt4 = 1 if alt4 == 1: # src/SavedFSM/Monitor.g:39:87: ANNOTATION pass ANNOTATION4=self.match(self.input, ANNOTATION, self.FOLLOW_ANNOTATION_in_description261) if self._state.backtracking == 0: stream_ANNOTATION.add(ANNOTATION4) else: break #loop4 self._state.following.append(self.FOLLOW_protocolDef_in_description266) protocolDef5 = self.protocolDef() self._state.following.pop() if self._state.backtracking == 0: stream_protocolDef.add(protocolDef5.tree) # AST Rewrite # elements: protocolDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 39:113: -> protocolDef self._adaptor.addChild(root_0, stream_protocolDef.nextTree()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "description" class importProtocolStatement_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.importProtocolStatement_return, self).__init__() self.tree = None # $ANTLR start "importProtocolStatement" # src/SavedFSM/Monitor.g:41:1: importProtocolStatement : 'import' 'protocol' importProtocolDef ( ',' importProtocolDef )* ';' ; def importProtocolStatement(self, ): retval = self.importProtocolStatement_return() retval.start = self.input.LT(1) root_0 = None string_literal6 = None string_literal7 = None char_literal9 = None char_literal11 = None importProtocolDef8 = None importProtocolDef10 = None string_literal6_tree = None string_literal7_tree = None char_literal9_tree = None char_literal11_tree = None try: try: # src/SavedFSM/Monitor.g:41:24: ( 'import' 'protocol' importProtocolDef ( ',' importProtocolDef )* ';' ) # src/SavedFSM/Monitor.g:41:26: 'import' 'protocol' importProtocolDef ( ',' importProtocolDef )* ';' pass root_0 = self._adaptor.nil() string_literal6=self.match(self.input, 34, self.FOLLOW_34_in_importProtocolStatement277) if self._state.backtracking == 0: string_literal6_tree = self._adaptor.createWithPayload(string_literal6) self._adaptor.addChild(root_0, string_literal6_tree) string_literal7=self.match(self.input, 35, self.FOLLOW_35_in_importProtocolStatement279) if self._state.backtracking == 0: string_literal7_tree = self._adaptor.createWithPayload(string_literal7) self._adaptor.addChild(root_0, string_literal7_tree) self._state.following.append(self.FOLLOW_importProtocolDef_in_importProtocolStatement281) importProtocolDef8 = self.importProtocolDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, importProtocolDef8.tree) # src/SavedFSM/Monitor.g:41:64: ( ',' importProtocolDef )* while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == 36) : alt5 = 1 if alt5 == 1: # src/SavedFSM/Monitor.g:41:66: ',' importProtocolDef pass char_literal9=self.match(self.input, 36, self.FOLLOW_36_in_importProtocolStatement285) self._state.following.append(self.FOLLOW_importProtocolDef_in_importProtocolStatement288) importProtocolDef10 = self.importProtocolDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, importProtocolDef10.tree) else: break #loop5 char_literal11=self.match(self.input, 37, self.FOLLOW_37_in_importProtocolStatement293) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "importProtocolStatement" class importProtocolDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.importProtocolDef_return, self).__init__() self.tree = None # $ANTLR start "importProtocolDef" # src/SavedFSM/Monitor.g:43:1: importProtocolDef : ID 'from' StringLiteral ; def importProtocolDef(self, ): retval = self.importProtocolDef_return() retval.start = self.input.LT(1) root_0 = None ID12 = None string_literal13 = None StringLiteral14 = None ID12_tree = None string_literal13_tree = None StringLiteral14_tree = None try: try: # src/SavedFSM/Monitor.g:43:18: ( ID 'from' StringLiteral ) # src/SavedFSM/Monitor.g:43:20: ID 'from' StringLiteral pass root_0 = self._adaptor.nil() ID12=self.match(self.input, ID, self.FOLLOW_ID_in_importProtocolDef302) if self._state.backtracking == 0: ID12_tree = self._adaptor.createWithPayload(ID12) self._adaptor.addChild(root_0, ID12_tree) string_literal13=self.match(self.input, 38, self.FOLLOW_38_in_importProtocolDef304) StringLiteral14=self.match(self.input, StringLiteral, self.FOLLOW_StringLiteral_in_importProtocolDef307) if self._state.backtracking == 0: StringLiteral14_tree = self._adaptor.createWithPayload(StringLiteral14) self._adaptor.addChild(root_0, StringLiteral14_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "importProtocolDef" class importTypeStatement_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.importTypeStatement_return, self).__init__() self.tree = None # $ANTLR start "importTypeStatement" # src/SavedFSM/Monitor.g:45:1: importTypeStatement : 'import' ( simpleName )? importTypeDef ( ',' importTypeDef )* ( 'from' StringLiteral )? ';' ; def importTypeStatement(self, ): retval = self.importTypeStatement_return() retval.start = self.input.LT(1) root_0 = None string_literal15 = None char_literal18 = None string_literal20 = None StringLiteral21 = None char_literal22 = None simpleName16 = None importTypeDef17 = None importTypeDef19 = None string_literal15_tree = None char_literal18_tree = None string_literal20_tree = None StringLiteral21_tree = None char_literal22_tree = None try: try: # src/SavedFSM/Monitor.g:45:20: ( 'import' ( simpleName )? importTypeDef ( ',' importTypeDef )* ( 'from' StringLiteral )? ';' ) # src/SavedFSM/Monitor.g:45:22: 'import' ( simpleName )? importTypeDef ( ',' importTypeDef )* ( 'from' StringLiteral )? ';' pass root_0 = self._adaptor.nil() string_literal15=self.match(self.input, 34, self.FOLLOW_34_in_importTypeStatement320) if self._state.backtracking == 0: string_literal15_tree = self._adaptor.createWithPayload(string_literal15) self._adaptor.addChild(root_0, string_literal15_tree) # src/SavedFSM/Monitor.g:45:31: ( simpleName )? alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == ID) : LA6_1 = self.input.LA(2) if ((ID <= LA6_1 <= StringLiteral)) : alt6 = 1 if alt6 == 1: # src/SavedFSM/Monitor.g:45:33: simpleName pass self._state.following.append(self.FOLLOW_simpleName_in_importTypeStatement324) simpleName16 = self.simpleName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, simpleName16.tree) self._state.following.append(self.FOLLOW_importTypeDef_in_importTypeStatement329) importTypeDef17 = self.importTypeDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, importTypeDef17.tree) # src/SavedFSM/Monitor.g:45:61: ( ',' importTypeDef )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 36) : alt7 = 1 if alt7 == 1: # src/SavedFSM/Monitor.g:45:63: ',' importTypeDef pass char_literal18=self.match(self.input, 36, self.FOLLOW_36_in_importTypeStatement333) self._state.following.append(self.FOLLOW_importTypeDef_in_importTypeStatement336) importTypeDef19 = self.importTypeDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, importTypeDef19.tree) else: break #loop7 # src/SavedFSM/Monitor.g:45:85: ( 'from' StringLiteral )? alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == 38) : alt8 = 1 if alt8 == 1: # src/SavedFSM/Monitor.g:45:87: 'from' StringLiteral pass string_literal20=self.match(self.input, 38, self.FOLLOW_38_in_importTypeStatement343) StringLiteral21=self.match(self.input, StringLiteral, self.FOLLOW_StringLiteral_in_importTypeStatement346) if self._state.backtracking == 0: StringLiteral21_tree = self._adaptor.createWithPayload(StringLiteral21) self._adaptor.addChild(root_0, StringLiteral21_tree) char_literal22=self.match(self.input, 37, self.FOLLOW_37_in_importTypeStatement351) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "importTypeStatement" class importTypeDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.importTypeDef_return, self).__init__() self.tree = None # $ANTLR start "importTypeDef" # src/SavedFSM/Monitor.g:47:1: importTypeDef : ( dataTypeDef 'as' )? ID ; def importTypeDef(self, ): retval = self.importTypeDef_return() retval.start = self.input.LT(1) root_0 = None string_literal24 = None ID25 = None dataTypeDef23 = None string_literal24_tree = None ID25_tree = None try: try: # src/SavedFSM/Monitor.g:47:14: ( ( dataTypeDef 'as' )? ID ) # src/SavedFSM/Monitor.g:47:16: ( dataTypeDef 'as' )? ID pass root_0 = self._adaptor.nil() # src/SavedFSM/Monitor.g:47:16: ( dataTypeDef 'as' )? alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == StringLiteral) : alt9 = 1 if alt9 == 1: # src/SavedFSM/Monitor.g:47:18: dataTypeDef 'as' pass self._state.following.append(self.FOLLOW_dataTypeDef_in_importTypeDef362) dataTypeDef23 = self.dataTypeDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, dataTypeDef23.tree) string_literal24=self.match(self.input, 39, self.FOLLOW_39_in_importTypeDef364) ID25=self.match(self.input, ID, self.FOLLOW_ID_in_importTypeDef370) if self._state.backtracking == 0: ID25_tree = self._adaptor.createWithPayload(ID25) self._adaptor.addChild(root_0, ID25_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "importTypeDef" class dataTypeDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.dataTypeDef_return, self).__init__() self.tree = None # $ANTLR start "dataTypeDef" # src/SavedFSM/Monitor.g:49:1: dataTypeDef : StringLiteral ; def dataTypeDef(self, ): retval = self.dataTypeDef_return() retval.start = self.input.LT(1) root_0 = None StringLiteral26 = None StringLiteral26_tree = None try: try: # src/SavedFSM/Monitor.g:49:12: ( StringLiteral ) # src/SavedFSM/Monitor.g:49:14: StringLiteral pass root_0 = self._adaptor.nil() StringLiteral26=self.match(self.input, StringLiteral, self.FOLLOW_StringLiteral_in_dataTypeDef378) if self._state.backtracking == 0: StringLiteral26_tree = self._adaptor.createWithPayload(StringLiteral26) self._adaptor.addChild(root_0, StringLiteral26_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "dataTypeDef" class simpleName_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.simpleName_return, self).__init__() self.tree = None # $ANTLR start "simpleName" # src/SavedFSM/Monitor.g:51:1: simpleName : ID ; def simpleName(self, ): retval = self.simpleName_return() retval.start = self.input.LT(1) root_0 = None ID27 = None ID27_tree = None try: try: # src/SavedFSM/Monitor.g:51:11: ( ID ) # src/SavedFSM/Monitor.g:51:13: ID pass root_0 = self._adaptor.nil() ID27=self.match(self.input, ID, self.FOLLOW_ID_in_simpleName386) if self._state.backtracking == 0: ID27_tree = self._adaptor.createWithPayload(ID27) self._adaptor.addChild(root_0, ID27_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "simpleName" class protocolDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.protocolDef_return, self).__init__() self.tree = None # $ANTLR start "protocolDef" # src/SavedFSM/Monitor.g:53:1: protocolDef : 'protocol' protocolName ( 'at' roleName )? ( parameterDefs )? '{' protocolBlockDef ( ( ANNOTATION )* protocolDef )* '}' -> ^( PROTOCOL roleName ( parameterDefs )* ( protocolBlockDef )+ ) ; def protocolDef(self, ): retval = self.protocolDef_return() retval.start = self.input.LT(1) root_0 = None string_literal28 = None string_literal30 = None char_literal33 = None ANNOTATION35 = None char_literal37 = None protocolName29 = None roleName31 = None parameterDefs32 = None protocolBlockDef34 = None protocolDef36 = None string_literal28_tree = None string_literal30_tree = None char_literal33_tree = None ANNOTATION35_tree = None char_literal37_tree = None stream_42 = RewriteRuleTokenStream(self._adaptor, "token 42") stream_41 = RewriteRuleTokenStream(self._adaptor, "token 41") stream_40 = RewriteRuleTokenStream(self._adaptor, "token 40") stream_35 = RewriteRuleTokenStream(self._adaptor, "token 35") stream_ANNOTATION = RewriteRuleTokenStream(self._adaptor, "token ANNOTATION") stream_parameterDefs = RewriteRuleSubtreeStream(self._adaptor, "rule parameterDefs") stream_protocolDef = RewriteRuleSubtreeStream(self._adaptor, "rule protocolDef") stream_protocolName = RewriteRuleSubtreeStream(self._adaptor, "rule protocolName") stream_protocolBlockDef = RewriteRuleSubtreeStream(self._adaptor, "rule protocolBlockDef") stream_roleName = RewriteRuleSubtreeStream(self._adaptor, "rule roleName") try: try: # src/SavedFSM/Monitor.g:53:12: ( 'protocol' protocolName ( 'at' roleName )? ( parameterDefs )? '{' protocolBlockDef ( ( ANNOTATION )* protocolDef )* '}' -> ^( PROTOCOL roleName ( parameterDefs )* ( protocolBlockDef )+ ) ) # src/SavedFSM/Monitor.g:53:14: 'protocol' protocolName ( 'at' roleName )? ( parameterDefs )? '{' protocolBlockDef ( ( ANNOTATION )* protocolDef )* '}' pass string_literal28=self.match(self.input, 35, self.FOLLOW_35_in_protocolDef394) if self._state.backtracking == 0: stream_35.add(string_literal28) self._state.following.append(self.FOLLOW_protocolName_in_protocolDef396) protocolName29 = self.protocolName() self._state.following.pop() if self._state.backtracking == 0: stream_protocolName.add(protocolName29.tree) # src/SavedFSM/Monitor.g:53:38: ( 'at' roleName )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 40) : alt10 = 1 if alt10 == 1: # src/SavedFSM/Monitor.g:53:40: 'at' roleName pass string_literal30=self.match(self.input, 40, self.FOLLOW_40_in_protocolDef400) if self._state.backtracking == 0: stream_40.add(string_literal30) self._state.following.append(self.FOLLOW_roleName_in_protocolDef402) roleName31 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: stream_roleName.add(roleName31.tree) # src/SavedFSM/Monitor.g:53:57: ( parameterDefs )? alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == 43) : alt11 = 1 if alt11 == 1: # src/SavedFSM/Monitor.g:53:59: parameterDefs pass self._state.following.append(self.FOLLOW_parameterDefs_in_protocolDef409) parameterDefs32 = self.parameterDefs() self._state.following.pop() if self._state.backtracking == 0: stream_parameterDefs.add(parameterDefs32.tree) char_literal33=self.match(self.input, 41, self.FOLLOW_41_in_protocolDef414) if self._state.backtracking == 0: stream_41.add(char_literal33) self._state.following.append(self.FOLLOW_protocolBlockDef_in_protocolDef416) protocolBlockDef34 = self.protocolBlockDef() self._state.following.pop() if self._state.backtracking == 0: stream_protocolBlockDef.add(protocolBlockDef34.tree) # src/SavedFSM/Monitor.g:53:97: ( ( ANNOTATION )* protocolDef )* while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == ANNOTATION or LA13_0 == 35) : alt13 = 1 if alt13 == 1: # src/SavedFSM/Monitor.g:53:99: ( ANNOTATION )* protocolDef pass # src/SavedFSM/Monitor.g:53:99: ( ANNOTATION )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == ANNOTATION) : alt12 = 1 if alt12 == 1: # src/SavedFSM/Monitor.g:53:101: ANNOTATION pass ANNOTATION35=self.match(self.input, ANNOTATION, self.FOLLOW_ANNOTATION_in_protocolDef422) if self._state.backtracking == 0: stream_ANNOTATION.add(ANNOTATION35) else: break #loop12 self._state.following.append(self.FOLLOW_protocolDef_in_protocolDef427) protocolDef36 = self.protocolDef() self._state.following.pop() if self._state.backtracking == 0: stream_protocolDef.add(protocolDef36.tree) else: break #loop13 char_literal37=self.match(self.input, 42, self.FOLLOW_42_in_protocolDef432) if self._state.backtracking == 0: stream_42.add(char_literal37) # AST Rewrite # elements: parameterDefs, roleName, protocolBlockDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 54:7: -> ^( PROTOCOL roleName ( parameterDefs )* ( protocolBlockDef )+ ) # src/SavedFSM/Monitor.g:54:10: ^( PROTOCOL roleName ( parameterDefs )* ( protocolBlockDef )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(PROTOCOL, "PROTOCOL"), root_1) self._adaptor.addChild(root_1, stream_roleName.nextTree()) # src/SavedFSM/Monitor.g:54:31: ( parameterDefs )* while stream_parameterDefs.hasNext(): self._adaptor.addChild(root_1, stream_parameterDefs.nextTree()) stream_parameterDefs.reset(); # src/SavedFSM/Monitor.g:54:46: ( protocolBlockDef )+ if not (stream_protocolBlockDef.hasNext()): raise RewriteEarlyExitException() while stream_protocolBlockDef.hasNext(): self._adaptor.addChild(root_1, stream_protocolBlockDef.nextTree()) stream_protocolBlockDef.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "protocolDef" class protocolName_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.protocolName_return, self).__init__() self.tree = None # $ANTLR start "protocolName" # src/SavedFSM/Monitor.g:56:1: protocolName : ID ; def protocolName(self, ): retval = self.protocolName_return() retval.start = self.input.LT(1) root_0 = None ID38 = None ID38_tree = None try: try: # src/SavedFSM/Monitor.g:56:13: ( ID ) # src/SavedFSM/Monitor.g:56:15: ID pass root_0 = self._adaptor.nil() ID38=self.match(self.input, ID, self.FOLLOW_ID_in_protocolName460) if self._state.backtracking == 0: ID38_tree = self._adaptor.createWithPayload(ID38) self._adaptor.addChild(root_0, ID38_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "protocolName" class parameterDefs_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.parameterDefs_return, self).__init__() self.tree = None # $ANTLR start "parameterDefs" # src/SavedFSM/Monitor.g:58:1: parameterDefs : '(' roleparameDef ( ',' roleparameDef )* ')' -> ^( ROLES ( roleparameDef )+ ) ; def parameterDefs(self, ): retval = self.parameterDefs_return() retval.start = self.input.LT(1) root_0 = None char_literal39 = None char_literal41 = None char_literal43 = None roleparameDef40 = None roleparameDef42 = None char_literal39_tree = None char_literal41_tree = None char_literal43_tree = None stream_43 = RewriteRuleTokenStream(self._adaptor, "token 43") stream_44 = RewriteRuleTokenStream(self._adaptor, "token 44") stream_36 = RewriteRuleTokenStream(self._adaptor, "token 36") stream_roleparameDef = RewriteRuleSubtreeStream(self._adaptor, "rule roleparameDef") try: try: # src/SavedFSM/Monitor.g:58:14: ( '(' roleparameDef ( ',' roleparameDef )* ')' -> ^( ROLES ( roleparameDef )+ ) ) # src/SavedFSM/Monitor.g:58:16: '(' roleparameDef ( ',' roleparameDef )* ')' pass char_literal39=self.match(self.input, 43, self.FOLLOW_43_in_parameterDefs468) if self._state.backtracking == 0: stream_43.add(char_literal39) self._state.following.append(self.FOLLOW_roleparameDef_in_parameterDefs470) roleparameDef40 = self.roleparameDef() self._state.following.pop() if self._state.backtracking == 0: stream_roleparameDef.add(roleparameDef40.tree) # src/SavedFSM/Monitor.g:58:34: ( ',' roleparameDef )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == 36) : alt14 = 1 if alt14 == 1: # src/SavedFSM/Monitor.g:58:36: ',' roleparameDef pass char_literal41=self.match(self.input, 36, self.FOLLOW_36_in_parameterDefs474) if self._state.backtracking == 0: stream_36.add(char_literal41) self._state.following.append(self.FOLLOW_roleparameDef_in_parameterDefs476) roleparameDef42 = self.roleparameDef() self._state.following.pop() if self._state.backtracking == 0: stream_roleparameDef.add(roleparameDef42.tree) else: break #loop14 char_literal43=self.match(self.input, 44, self.FOLLOW_44_in_parameterDefs481) if self._state.backtracking == 0: stream_44.add(char_literal43) # AST Rewrite # elements: roleparameDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 58:61: -> ^( ROLES ( roleparameDef )+ ) # src/SavedFSM/Monitor.g:58:64: ^( ROLES ( roleparameDef )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(ROLES, "ROLES"), root_1) # src/SavedFSM/Monitor.g:58:72: ( roleparameDef )+ if not (stream_roleparameDef.hasNext()): raise RewriteEarlyExitException() while stream_roleparameDef.hasNext(): self._adaptor.addChild(root_1, stream_roleparameDef.nextTree()) stream_roleparameDef.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "parameterDefs" class roleparameDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.roleparameDef_return, self).__init__() self.tree = None # $ANTLR start "roleparameDef" # src/SavedFSM/Monitor.g:60:1: roleparameDef : 'role' simpleName -> simpleName ; def roleparameDef(self, ): retval = self.roleparameDef_return() retval.start = self.input.LT(1) root_0 = None string_literal44 = None simpleName45 = None string_literal44_tree = None stream_45 = RewriteRuleTokenStream(self._adaptor, "token 45") stream_simpleName = RewriteRuleSubtreeStream(self._adaptor, "rule simpleName") try: try: # src/SavedFSM/Monitor.g:60:14: ( 'role' simpleName -> simpleName ) # src/SavedFSM/Monitor.g:60:16: 'role' simpleName pass string_literal44=self.match(self.input, 45, self.FOLLOW_45_in_roleparameDef497) if self._state.backtracking == 0: stream_45.add(string_literal44) self._state.following.append(self.FOLLOW_simpleName_in_roleparameDef499) simpleName45 = self.simpleName() self._state.following.pop() if self._state.backtracking == 0: stream_simpleName.add(simpleName45.tree) # AST Rewrite # elements: simpleName # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 60:34: -> simpleName self._adaptor.addChild(root_0, stream_simpleName.nextTree()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "roleparameDef" class protocolBlockDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.protocolBlockDef_return, self).__init__() self.tree = None # $ANTLR start "protocolBlockDef" # src/SavedFSM/Monitor.g:62:1: protocolBlockDef : activityListDef -> activityListDef ; def protocolBlockDef(self, ): retval = self.protocolBlockDef_return() retval.start = self.input.LT(1) root_0 = None activityListDef46 = None stream_activityListDef = RewriteRuleSubtreeStream(self._adaptor, "rule activityListDef") try: try: # src/SavedFSM/Monitor.g:62:17: ( activityListDef -> activityListDef ) # src/SavedFSM/Monitor.g:62:19: activityListDef pass self._state.following.append(self.FOLLOW_activityListDef_in_protocolBlockDef510) activityListDef46 = self.activityListDef() self._state.following.pop() if self._state.backtracking == 0: stream_activityListDef.add(activityListDef46.tree) # AST Rewrite # elements: activityListDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 62:35: -> activityListDef self._adaptor.addChild(root_0, stream_activityListDef.nextTree()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "protocolBlockDef" class blockDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.blockDef_return, self).__init__() self.tree = None # $ANTLR start "blockDef" # src/SavedFSM/Monitor.g:64:1: blockDef : '{' activityListDef '}' -> ^( BRANCH activityListDef ) ; def blockDef(self, ): retval = self.blockDef_return() retval.start = self.input.LT(1) root_0 = None char_literal47 = None char_literal49 = None activityListDef48 = None char_literal47_tree = None char_literal49_tree = None stream_42 = RewriteRuleTokenStream(self._adaptor, "token 42") stream_41 = RewriteRuleTokenStream(self._adaptor, "token 41") stream_activityListDef = RewriteRuleSubtreeStream(self._adaptor, "rule activityListDef") try: try: # src/SavedFSM/Monitor.g:64:9: ( '{' activityListDef '}' -> ^( BRANCH activityListDef ) ) # src/SavedFSM/Monitor.g:64:11: '{' activityListDef '}' pass char_literal47=self.match(self.input, 41, self.FOLLOW_41_in_blockDef521) if self._state.backtracking == 0: stream_41.add(char_literal47) self._state.following.append(self.FOLLOW_activityListDef_in_blockDef523) activityListDef48 = self.activityListDef() self._state.following.pop() if self._state.backtracking == 0: stream_activityListDef.add(activityListDef48.tree) char_literal49=self.match(self.input, 42, self.FOLLOW_42_in_blockDef525) if self._state.backtracking == 0: stream_42.add(char_literal49) # AST Rewrite # elements: activityListDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 64:35: -> ^( BRANCH activityListDef ) # src/SavedFSM/Monitor.g:64:38: ^( BRANCH activityListDef ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(BRANCH, "BRANCH"), root_1) self._adaptor.addChild(root_1, stream_activityListDef.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "blockDef" class assertDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.assertDef_return, self).__init__() self.tree = None # $ANTLR start "assertDef" # src/SavedFSM/Monitor.g:66:1: assertDef : ( ASSERTION )? -> ^( ASSERT ( ASSERTION )? ) ; def assertDef(self, ): retval = self.assertDef_return() retval.start = self.input.LT(1) root_0 = None ASSERTION50 = None ASSERTION50_tree = None stream_ASSERTION = RewriteRuleTokenStream(self._adaptor, "token ASSERTION") try: try: # src/SavedFSM/Monitor.g:66:11: ( ( ASSERTION )? -> ^( ASSERT ( ASSERTION )? ) ) # src/SavedFSM/Monitor.g:66:13: ( ASSERTION )? pass # src/SavedFSM/Monitor.g:66:13: ( ASSERTION )? alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == ASSERTION) : alt15 = 1 if alt15 == 1: # src/SavedFSM/Monitor.g:66:14: ASSERTION pass ASSERTION50=self.match(self.input, ASSERTION, self.FOLLOW_ASSERTION_in_assertDef547) if self._state.backtracking == 0: stream_ASSERTION.add(ASSERTION50) # AST Rewrite # elements: ASSERTION # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 66:26: -> ^( ASSERT ( ASSERTION )? ) # src/SavedFSM/Monitor.g:66:29: ^( ASSERT ( ASSERTION )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(ASSERT, "ASSERT"), root_1) # src/SavedFSM/Monitor.g:66:38: ( ASSERTION )? if stream_ASSERTION.hasNext(): self._adaptor.addChild(root_1, stream_ASSERTION.nextNode()) stream_ASSERTION.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "assertDef" class activityListDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.activityListDef_return, self).__init__() self.tree = None # $ANTLR start "activityListDef" # src/SavedFSM/Monitor.g:68:1: activityListDef : ( ( ANNOTATION )* activityDef )* -> ( activityDef )+ ; def activityListDef(self, ): retval = self.activityListDef_return() retval.start = self.input.LT(1) root_0 = None ANNOTATION51 = None activityDef52 = None ANNOTATION51_tree = None stream_ANNOTATION = RewriteRuleTokenStream(self._adaptor, "token ANNOTATION") stream_activityDef = RewriteRuleSubtreeStream(self._adaptor, "rule activityDef") try: try: # src/SavedFSM/Monitor.g:68:16: ( ( ( ANNOTATION )* activityDef )* -> ( activityDef )+ ) # src/SavedFSM/Monitor.g:68:18: ( ( ANNOTATION )* activityDef )* pass # src/SavedFSM/Monitor.g:68:18: ( ( ANNOTATION )* activityDef )* while True: #loop17 alt17 = 2 alt17 = self.dfa17.predict(self.input) if alt17 == 1: # src/SavedFSM/Monitor.g:68:20: ( ANNOTATION )* activityDef pass # src/SavedFSM/Monitor.g:68:20: ( ANNOTATION )* while True: #loop16 alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == ANNOTATION) : alt16 = 1 if alt16 == 1: # src/SavedFSM/Monitor.g:68:22: ANNOTATION pass ANNOTATION51=self.match(self.input, ANNOTATION, self.FOLLOW_ANNOTATION_in_activityListDef569) if self._state.backtracking == 0: stream_ANNOTATION.add(ANNOTATION51) else: break #loop16 self._state.following.append(self.FOLLOW_activityDef_in_activityListDef574) activityDef52 = self.activityDef() self._state.following.pop() if self._state.backtracking == 0: stream_activityDef.add(activityDef52.tree) else: break #loop17 # AST Rewrite # elements: activityDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 68:51: -> ( activityDef )+ # src/SavedFSM/Monitor.g:68:54: ( activityDef )+ if not (stream_activityDef.hasNext()): raise RewriteEarlyExitException() while stream_activityDef.hasNext(): self._adaptor.addChild(root_0, stream_activityDef.nextTree()) stream_activityDef.reset() retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "activityListDef" class primitivetype_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.primitivetype_return, self).__init__() self.tree = None # $ANTLR start "primitivetype" # src/SavedFSM/Monitor.g:70:1: primitivetype : ( INT -> INT | STRING -> STRING ) ; def primitivetype(self, ): retval = self.primitivetype_return() retval.start = self.input.LT(1) root_0 = None INT53 = None STRING54 = None INT53_tree = None STRING54_tree = None stream_INT = RewriteRuleTokenStream(self._adaptor, "token INT") stream_STRING = RewriteRuleTokenStream(self._adaptor, "token STRING") try: try: # src/SavedFSM/Monitor.g:70:15: ( ( INT -> INT | STRING -> STRING ) ) # src/SavedFSM/Monitor.g:70:16: ( INT -> INT | STRING -> STRING ) pass # src/SavedFSM/Monitor.g:70:16: ( INT -> INT | STRING -> STRING ) alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == INT) : alt18 = 1 elif (LA18_0 == STRING) : alt18 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 18, 0, self.input) raise nvae if alt18 == 1: # src/SavedFSM/Monitor.g:70:17: INT pass INT53=self.match(self.input, INT, self.FOLLOW_INT_in_primitivetype590) if self._state.backtracking == 0: stream_INT.add(INT53) # AST Rewrite # elements: INT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 70:21: -> INT self._adaptor.addChild(root_0, stream_INT.nextNode()) retval.tree = root_0 elif alt18 == 2: # src/SavedFSM/Monitor.g:70:28: STRING pass STRING54=self.match(self.input, STRING, self.FOLLOW_STRING_in_primitivetype596) if self._state.backtracking == 0: stream_STRING.add(STRING54) # AST Rewrite # elements: STRING # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 70:34: -> STRING self._adaptor.addChild(root_0, stream_STRING.nextNode()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "primitivetype" class activityDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.activityDef_return, self).__init__() self.tree = None # $ANTLR start "activityDef" # src/SavedFSM/Monitor.g:72:1: activityDef : ( ( introducesDef | interactionDef | inlineDef | runDef | recursionDef | endDef | RECLABEL ) ';' | choiceDef | directedChoiceDef | parallelDef | repeatDef | unorderedDef | recBlockDef | globalEscapeDef ); def activityDef(self, ): retval = self.activityDef_return() retval.start = self.input.LT(1) root_0 = None RECLABEL61 = None char_literal62 = None introducesDef55 = None interactionDef56 = None inlineDef57 = None runDef58 = None recursionDef59 = None endDef60 = None choiceDef63 = None directedChoiceDef64 = None parallelDef65 = None repeatDef66 = None unorderedDef67 = None recBlockDef68 = None globalEscapeDef69 = None RECLABEL61_tree = None char_literal62_tree = None try: try: # src/SavedFSM/Monitor.g:72:12: ( ( introducesDef | interactionDef | inlineDef | runDef | recursionDef | endDef | RECLABEL ) ';' | choiceDef | directedChoiceDef | parallelDef | repeatDef | unorderedDef | recBlockDef | globalEscapeDef ) alt20 = 8 LA20 = self.input.LA(1) if LA20 == RECLABEL or LA20 == ID or LA20 == 43 or LA20 == 53 or LA20 == 54 or LA20 == 55: alt20 = 1 elif LA20 == 49: alt20 = 2 elif LA20 == 38 or LA20 == 41 or LA20 == 48: alt20 = 3 elif LA20 == 56: alt20 = 4 elif LA20 == 51: alt20 = 5 elif LA20 == 61: alt20 = 6 elif LA20 == 52: alt20 = 7 elif LA20 == 58: alt20 = 8 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 20, 0, self.input) raise nvae if alt20 == 1: # src/SavedFSM/Monitor.g:72:14: ( introducesDef | interactionDef | inlineDef | runDef | recursionDef | endDef | RECLABEL ) ';' pass root_0 = self._adaptor.nil() # src/SavedFSM/Monitor.g:72:14: ( introducesDef | interactionDef | inlineDef | runDef | recursionDef | endDef | RECLABEL ) alt19 = 7 LA19 = self.input.LA(1) if LA19 == ID: LA19 = self.input.LA(2) if LA19 == 37: alt19 = 5 elif LA19 == 46: alt19 = 1 elif LA19 == 38 or LA19 == 43 or LA19 == 48: alt19 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 19, 1, self.input) raise nvae elif LA19 == 43: alt19 = 2 elif LA19 == 55: alt19 = 3 elif LA19 == 54: alt19 = 4 elif LA19 == 53: alt19 = 6 elif LA19 == RECLABEL: alt19 = 7 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 19, 0, self.input) raise nvae if alt19 == 1: # src/SavedFSM/Monitor.g:72:16: introducesDef pass self._state.following.append(self.FOLLOW_introducesDef_in_activityDef609) introducesDef55 = self.introducesDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, introducesDef55.tree) elif alt19 == 2: # src/SavedFSM/Monitor.g:72:32: interactionDef pass self._state.following.append(self.FOLLOW_interactionDef_in_activityDef613) interactionDef56 = self.interactionDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, interactionDef56.tree) elif alt19 == 3: # src/SavedFSM/Monitor.g:72:49: inlineDef pass self._state.following.append(self.FOLLOW_inlineDef_in_activityDef617) inlineDef57 = self.inlineDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, inlineDef57.tree) elif alt19 == 4: # src/SavedFSM/Monitor.g:72:61: runDef pass self._state.following.append(self.FOLLOW_runDef_in_activityDef621) runDef58 = self.runDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, runDef58.tree) elif alt19 == 5: # src/SavedFSM/Monitor.g:72:70: recursionDef pass self._state.following.append(self.FOLLOW_recursionDef_in_activityDef625) recursionDef59 = self.recursionDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, recursionDef59.tree) elif alt19 == 6: # src/SavedFSM/Monitor.g:72:85: endDef pass self._state.following.append(self.FOLLOW_endDef_in_activityDef629) endDef60 = self.endDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, endDef60.tree) elif alt19 == 7: # src/SavedFSM/Monitor.g:72:94: RECLABEL pass RECLABEL61=self.match(self.input, RECLABEL, self.FOLLOW_RECLABEL_in_activityDef633) if self._state.backtracking == 0: RECLABEL61_tree = self._adaptor.createWithPayload(RECLABEL61) self._adaptor.addChild(root_0, RECLABEL61_tree) char_literal62=self.match(self.input, 37, self.FOLLOW_37_in_activityDef637) elif alt20 == 2: # src/SavedFSM/Monitor.g:73:4: choiceDef pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_choiceDef_in_activityDef646) choiceDef63 = self.choiceDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, choiceDef63.tree) elif alt20 == 3: # src/SavedFSM/Monitor.g:73:16: directedChoiceDef pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_directedChoiceDef_in_activityDef650) directedChoiceDef64 = self.directedChoiceDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, directedChoiceDef64.tree) elif alt20 == 4: # src/SavedFSM/Monitor.g:73:36: parallelDef pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_parallelDef_in_activityDef654) parallelDef65 = self.parallelDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, parallelDef65.tree) elif alt20 == 5: # src/SavedFSM/Monitor.g:73:50: repeatDef pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_repeatDef_in_activityDef658) repeatDef66 = self.repeatDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, repeatDef66.tree) elif alt20 == 6: # src/SavedFSM/Monitor.g:73:62: unorderedDef pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_unorderedDef_in_activityDef662) unorderedDef67 = self.unorderedDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, unorderedDef67.tree) elif alt20 == 7: # src/SavedFSM/Monitor.g:74:4: recBlockDef pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_recBlockDef_in_activityDef669) recBlockDef68 = self.recBlockDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, recBlockDef68.tree) elif alt20 == 8: # src/SavedFSM/Monitor.g:74:18: globalEscapeDef pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_globalEscapeDef_in_activityDef673) globalEscapeDef69 = self.globalEscapeDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, globalEscapeDef69.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "activityDef" class introducesDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.introducesDef_return, self).__init__() self.tree = None # $ANTLR start "introducesDef" # src/SavedFSM/Monitor.g:76:1: introducesDef : roleDef 'introduces' roleDef ( ',' roleDef )* ; def introducesDef(self, ): retval = self.introducesDef_return() retval.start = self.input.LT(1) root_0 = None string_literal71 = None char_literal73 = None roleDef70 = None roleDef72 = None roleDef74 = None string_literal71_tree = None char_literal73_tree = None try: try: # src/SavedFSM/Monitor.g:76:14: ( roleDef 'introduces' roleDef ( ',' roleDef )* ) # src/SavedFSM/Monitor.g:76:16: roleDef 'introduces' roleDef ( ',' roleDef )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_roleDef_in_introducesDef681) roleDef70 = self.roleDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, roleDef70.tree) string_literal71=self.match(self.input, 46, self.FOLLOW_46_in_introducesDef683) if self._state.backtracking == 0: string_literal71_tree = self._adaptor.createWithPayload(string_literal71) self._adaptor.addChild(root_0, string_literal71_tree) self._state.following.append(self.FOLLOW_roleDef_in_introducesDef685) roleDef72 = self.roleDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, roleDef72.tree) # src/SavedFSM/Monitor.g:76:45: ( ',' roleDef )* while True: #loop21 alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == 36) : alt21 = 1 if alt21 == 1: # src/SavedFSM/Monitor.g:76:47: ',' roleDef pass char_literal73=self.match(self.input, 36, self.FOLLOW_36_in_introducesDef689) if self._state.backtracking == 0: char_literal73_tree = self._adaptor.createWithPayload(char_literal73) self._adaptor.addChild(root_0, char_literal73_tree) self._state.following.append(self.FOLLOW_roleDef_in_introducesDef691) roleDef74 = self.roleDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, roleDef74.tree) else: break #loop21 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "introducesDef" class roleDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.roleDef_return, self).__init__() self.tree = None # $ANTLR start "roleDef" # src/SavedFSM/Monitor.g:78:1: roleDef : ID -> ID ; def roleDef(self, ): retval = self.roleDef_return() retval.start = self.input.LT(1) root_0 = None ID75 = None ID75_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") try: try: # src/SavedFSM/Monitor.g:78:8: ( ID -> ID ) # src/SavedFSM/Monitor.g:78:10: ID pass ID75=self.match(self.input, ID, self.FOLLOW_ID_in_roleDef702) if self._state.backtracking == 0: stream_ID.add(ID75) # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 78:13: -> ID self._adaptor.addChild(root_0, stream_ID.nextNode()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "roleDef" class roleName_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.roleName_return, self).__init__() self.tree = None # $ANTLR start "roleName" # src/SavedFSM/Monitor.g:80:1: roleName : ID -> ID ; def roleName(self, ): retval = self.roleName_return() retval.start = self.input.LT(1) root_0 = None ID76 = None ID76_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") try: try: # src/SavedFSM/Monitor.g:80:9: ( ID -> ID ) # src/SavedFSM/Monitor.g:80:11: ID pass ID76=self.match(self.input, ID, self.FOLLOW_ID_in_roleName713) if self._state.backtracking == 0: stream_ID.add(ID76) # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 80:14: -> ID self._adaptor.addChild(root_0, stream_ID.nextNode()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "roleName" class typeReferenceDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.typeReferenceDef_return, self).__init__() self.tree = None # $ANTLR start "typeReferenceDef" # src/SavedFSM/Monitor.g:82:1: typeReferenceDef : ID -> ID ; def typeReferenceDef(self, ): retval = self.typeReferenceDef_return() retval.start = self.input.LT(1) root_0 = None ID77 = None ID77_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") try: try: # src/SavedFSM/Monitor.g:82:17: ( ID -> ID ) # src/SavedFSM/Monitor.g:82:19: ID pass ID77=self.match(self.input, ID, self.FOLLOW_ID_in_typeReferenceDef724) if self._state.backtracking == 0: stream_ID.add(ID77) # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 82:22: -> ID self._adaptor.addChild(root_0, stream_ID.nextNode()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "typeReferenceDef" class interactionSignatureDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.interactionSignatureDef_return, self).__init__() self.tree = None # $ANTLR start "interactionSignatureDef" # src/SavedFSM/Monitor.g:83:1: interactionSignatureDef : ( ( typeReferenceDef ( '(' valueDecl ( ',' valueDecl )* ')' )? -> typeReferenceDef ^( VALUE ( valueDecl )* ) ) | ( ( '(' valueDecl ( ',' valueDecl )* ')' ) -> ^( VALUE ( valueDecl )* ) ) ) ; def interactionSignatureDef(self, ): retval = self.interactionSignatureDef_return() retval.start = self.input.LT(1) root_0 = None char_literal79 = None char_literal81 = None char_literal83 = None char_literal84 = None char_literal86 = None char_literal88 = None typeReferenceDef78 = None valueDecl80 = None valueDecl82 = None valueDecl85 = None valueDecl87 = None char_literal79_tree = None char_literal81_tree = None char_literal83_tree = None char_literal84_tree = None char_literal86_tree = None char_literal88_tree = None stream_43 = RewriteRuleTokenStream(self._adaptor, "token 43") stream_44 = RewriteRuleTokenStream(self._adaptor, "token 44") stream_36 = RewriteRuleTokenStream(self._adaptor, "token 36") stream_typeReferenceDef = RewriteRuleSubtreeStream(self._adaptor, "rule typeReferenceDef") stream_valueDecl = RewriteRuleSubtreeStream(self._adaptor, "rule valueDecl") try: try: # src/SavedFSM/Monitor.g:83:24: ( ( ( typeReferenceDef ( '(' valueDecl ( ',' valueDecl )* ')' )? -> typeReferenceDef ^( VALUE ( valueDecl )* ) ) | ( ( '(' valueDecl ( ',' valueDecl )* ')' ) -> ^( VALUE ( valueDecl )* ) ) ) ) # src/SavedFSM/Monitor.g:83:26: ( ( typeReferenceDef ( '(' valueDecl ( ',' valueDecl )* ')' )? -> typeReferenceDef ^( VALUE ( valueDecl )* ) ) | ( ( '(' valueDecl ( ',' valueDecl )* ')' ) -> ^( VALUE ( valueDecl )* ) ) ) pass # src/SavedFSM/Monitor.g:83:26: ( ( typeReferenceDef ( '(' valueDecl ( ',' valueDecl )* ')' )? -> typeReferenceDef ^( VALUE ( valueDecl )* ) ) | ( ( '(' valueDecl ( ',' valueDecl )* ')' ) -> ^( VALUE ( valueDecl )* ) ) ) alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == ID) : alt25 = 1 elif (LA25_0 == 43) : alt25 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 25, 0, self.input) raise nvae if alt25 == 1: # src/SavedFSM/Monitor.g:83:27: ( typeReferenceDef ( '(' valueDecl ( ',' valueDecl )* ')' )? -> typeReferenceDef ^( VALUE ( valueDecl )* ) ) pass # src/SavedFSM/Monitor.g:83:27: ( typeReferenceDef ( '(' valueDecl ( ',' valueDecl )* ')' )? -> typeReferenceDef ^( VALUE ( valueDecl )* ) ) # src/SavedFSM/Monitor.g:83:28: typeReferenceDef ( '(' valueDecl ( ',' valueDecl )* ')' )? pass self._state.following.append(self.FOLLOW_typeReferenceDef_in_interactionSignatureDef735) typeReferenceDef78 = self.typeReferenceDef() self._state.following.pop() if self._state.backtracking == 0: stream_typeReferenceDef.add(typeReferenceDef78.tree) # src/SavedFSM/Monitor.g:83:45: ( '(' valueDecl ( ',' valueDecl )* ')' )? alt23 = 2 LA23_0 = self.input.LA(1) if (LA23_0 == 43) : alt23 = 1 if alt23 == 1: # src/SavedFSM/Monitor.g:83:46: '(' valueDecl ( ',' valueDecl )* ')' pass char_literal79=self.match(self.input, 43, self.FOLLOW_43_in_interactionSignatureDef738) if self._state.backtracking == 0: stream_43.add(char_literal79) self._state.following.append(self.FOLLOW_valueDecl_in_interactionSignatureDef740) valueDecl80 = self.valueDecl() self._state.following.pop() if self._state.backtracking == 0: stream_valueDecl.add(valueDecl80.tree) # src/SavedFSM/Monitor.g:83:60: ( ',' valueDecl )* while True: #loop22 alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == 36) : alt22 = 1 if alt22 == 1: # src/SavedFSM/Monitor.g:83:61: ',' valueDecl pass char_literal81=self.match(self.input, 36, self.FOLLOW_36_in_interactionSignatureDef743) if self._state.backtracking == 0: stream_36.add(char_literal81) self._state.following.append(self.FOLLOW_valueDecl_in_interactionSignatureDef745) valueDecl82 = self.valueDecl() self._state.following.pop() if self._state.backtracking == 0: stream_valueDecl.add(valueDecl82.tree) else: break #loop22 char_literal83=self.match(self.input, 44, self.FOLLOW_44_in_interactionSignatureDef749) if self._state.backtracking == 0: stream_44.add(char_literal83) # AST Rewrite # elements: typeReferenceDef, valueDecl # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 83:83: -> typeReferenceDef ^( VALUE ( valueDecl )* ) self._adaptor.addChild(root_0, stream_typeReferenceDef.nextTree()) # src/SavedFSM/Monitor.g:83:103: ^( VALUE ( valueDecl )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(VALUE, "VALUE"), root_1) # src/SavedFSM/Monitor.g:83:111: ( valueDecl )* while stream_valueDecl.hasNext(): self._adaptor.addChild(root_1, stream_valueDecl.nextTree()) stream_valueDecl.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt25 == 2: # src/SavedFSM/Monitor.g:84:7: ( ( '(' valueDecl ( ',' valueDecl )* ')' ) -> ^( VALUE ( valueDecl )* ) ) pass # src/SavedFSM/Monitor.g:84:7: ( ( '(' valueDecl ( ',' valueDecl )* ')' ) -> ^( VALUE ( valueDecl )* ) ) # src/SavedFSM/Monitor.g:84:8: ( '(' valueDecl ( ',' valueDecl )* ')' ) pass # src/SavedFSM/Monitor.g:84:8: ( '(' valueDecl ( ',' valueDecl )* ')' ) # src/SavedFSM/Monitor.g:84:9: '(' valueDecl ( ',' valueDecl )* ')' pass char_literal84=self.match(self.input, 43, self.FOLLOW_43_in_interactionSignatureDef773) if self._state.backtracking == 0: stream_43.add(char_literal84) self._state.following.append(self.FOLLOW_valueDecl_in_interactionSignatureDef775) valueDecl85 = self.valueDecl() self._state.following.pop() if self._state.backtracking == 0: stream_valueDecl.add(valueDecl85.tree) # src/SavedFSM/Monitor.g:84:23: ( ',' valueDecl )* while True: #loop24 alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == 36) : alt24 = 1 if alt24 == 1: # src/SavedFSM/Monitor.g:84:24: ',' valueDecl pass char_literal86=self.match(self.input, 36, self.FOLLOW_36_in_interactionSignatureDef778) if self._state.backtracking == 0: stream_36.add(char_literal86) self._state.following.append(self.FOLLOW_valueDecl_in_interactionSignatureDef780) valueDecl87 = self.valueDecl() self._state.following.pop() if self._state.backtracking == 0: stream_valueDecl.add(valueDecl87.tree) else: break #loop24 char_literal88=self.match(self.input, 44, self.FOLLOW_44_in_interactionSignatureDef784) if self._state.backtracking == 0: stream_44.add(char_literal88) # AST Rewrite # elements: valueDecl # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 84:45: -> ^( VALUE ( valueDecl )* ) # src/SavedFSM/Monitor.g:84:48: ^( VALUE ( valueDecl )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(VALUE, "VALUE"), root_1) # src/SavedFSM/Monitor.g:84:56: ( valueDecl )* while stream_valueDecl.hasNext(): self._adaptor.addChild(root_1, stream_valueDecl.nextTree()) stream_valueDecl.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "interactionSignatureDef" class valueDecl_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.valueDecl_return, self).__init__() self.tree = None # $ANTLR start "valueDecl" # src/SavedFSM/Monitor.g:86:1: valueDecl : ID ( ':' primitivetype )? ; def valueDecl(self, ): retval = self.valueDecl_return() retval.start = self.input.LT(1) root_0 = None ID89 = None char_literal90 = None primitivetype91 = None ID89_tree = None char_literal90_tree = None try: try: # src/SavedFSM/Monitor.g:86:11: ( ID ( ':' primitivetype )? ) # src/SavedFSM/Monitor.g:86:13: ID ( ':' primitivetype )? pass root_0 = self._adaptor.nil() ID89=self.match(self.input, ID, self.FOLLOW_ID_in_valueDecl804) if self._state.backtracking == 0: ID89_tree = self._adaptor.createWithPayload(ID89) self._adaptor.addChild(root_0, ID89_tree) # src/SavedFSM/Monitor.g:86:16: ( ':' primitivetype )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == 47) : alt26 = 1 if alt26 == 1: # src/SavedFSM/Monitor.g:86:17: ':' primitivetype pass char_literal90=self.match(self.input, 47, self.FOLLOW_47_in_valueDecl807) self._state.following.append(self.FOLLOW_primitivetype_in_valueDecl810) primitivetype91 = self.primitivetype() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, primitivetype91.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "valueDecl" class firstValueDecl_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.firstValueDecl_return, self).__init__() self.tree = None # $ANTLR start "firstValueDecl" # src/SavedFSM/Monitor.g:87:1: firstValueDecl : valueDecl ; def firstValueDecl(self, ): retval = self.firstValueDecl_return() retval.start = self.input.LT(1) root_0 = None valueDecl92 = None try: try: # src/SavedFSM/Monitor.g:87:16: ( valueDecl ) # src/SavedFSM/Monitor.g:87:18: valueDecl pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_valueDecl_in_firstValueDecl821) valueDecl92 = self.valueDecl() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, valueDecl92.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "firstValueDecl" class interactionDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.interactionDef_return, self).__init__() self.tree = None # $ANTLR start "interactionDef" # src/SavedFSM/Monitor.g:90:1: interactionDef : interactionSignatureDef ( 'from' role= roleName ( assertDef ) -> ^( RESV interactionSignatureDef $role assertDef ) | 'to' roleName ( assertDef ) -> ^( SEND interactionSignatureDef roleName assertDef ) ) ; def interactionDef(self, ): retval = self.interactionDef_return() retval.start = self.input.LT(1) root_0 = None string_literal94 = None string_literal96 = None role = None interactionSignatureDef93 = None assertDef95 = None roleName97 = None assertDef98 = None string_literal94_tree = None string_literal96_tree = None stream_48 = RewriteRuleTokenStream(self._adaptor, "token 48") stream_38 = RewriteRuleTokenStream(self._adaptor, "token 38") stream_assertDef = RewriteRuleSubtreeStream(self._adaptor, "rule assertDef") stream_roleName = RewriteRuleSubtreeStream(self._adaptor, "rule roleName") stream_interactionSignatureDef = RewriteRuleSubtreeStream(self._adaptor, "rule interactionSignatureDef") try: try: # src/SavedFSM/Monitor.g:90:15: ( interactionSignatureDef ( 'from' role= roleName ( assertDef ) -> ^( RESV interactionSignatureDef $role assertDef ) | 'to' roleName ( assertDef ) -> ^( SEND interactionSignatureDef roleName assertDef ) ) ) # src/SavedFSM/Monitor.g:91:7: interactionSignatureDef ( 'from' role= roleName ( assertDef ) -> ^( RESV interactionSignatureDef $role assertDef ) | 'to' roleName ( assertDef ) -> ^( SEND interactionSignatureDef roleName assertDef ) ) pass self._state.following.append(self.FOLLOW_interactionSignatureDef_in_interactionDef836) interactionSignatureDef93 = self.interactionSignatureDef() self._state.following.pop() if self._state.backtracking == 0: stream_interactionSignatureDef.add(interactionSignatureDef93.tree) # src/SavedFSM/Monitor.g:91:31: ( 'from' role= roleName ( assertDef ) -> ^( RESV interactionSignatureDef $role assertDef ) | 'to' roleName ( assertDef ) -> ^( SEND interactionSignatureDef roleName assertDef ) ) alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == 38) : alt27 = 1 elif (LA27_0 == 48) : alt27 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 27, 0, self.input) raise nvae if alt27 == 1: # src/SavedFSM/Monitor.g:92:3: 'from' role= roleName ( assertDef ) pass string_literal94=self.match(self.input, 38, self.FOLLOW_38_in_interactionDef842) if self._state.backtracking == 0: stream_38.add(string_literal94) self._state.following.append(self.FOLLOW_roleName_in_interactionDef847) role = self.roleName() self._state.following.pop() if self._state.backtracking == 0: stream_roleName.add(role.tree) # src/SavedFSM/Monitor.g:92:26: ( assertDef ) # src/SavedFSM/Monitor.g:92:27: assertDef pass self._state.following.append(self.FOLLOW_assertDef_in_interactionDef851) assertDef95 = self.assertDef() self._state.following.pop() if self._state.backtracking == 0: stream_assertDef.add(assertDef95.tree) # AST Rewrite # elements: assertDef, role, interactionSignatureDef # token labels: # rule labels: retval, role # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) if role is not None: stream_role = RewriteRuleSubtreeStream(self._adaptor, "rule role", role.tree) else: stream_role = RewriteRuleSubtreeStream(self._adaptor, "token role", None) root_0 = self._adaptor.nil() # 92:37: -> ^( RESV interactionSignatureDef $role assertDef ) # src/SavedFSM/Monitor.g:92:40: ^( RESV interactionSignatureDef $role assertDef ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(RESV, "RESV"), root_1) self._adaptor.addChild(root_1, stream_interactionSignatureDef.nextTree()) self._adaptor.addChild(root_1, stream_role.nextTree()) self._adaptor.addChild(root_1, stream_assertDef.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt27 == 2: # src/SavedFSM/Monitor.g:93:10: 'to' roleName ( assertDef ) pass string_literal96=self.match(self.input, 48, self.FOLLOW_48_in_interactionDef875) if self._state.backtracking == 0: stream_48.add(string_literal96) self._state.following.append(self.FOLLOW_roleName_in_interactionDef877) roleName97 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: stream_roleName.add(roleName97.tree) # src/SavedFSM/Monitor.g:93:25: ( assertDef ) # src/SavedFSM/Monitor.g:93:26: assertDef pass self._state.following.append(self.FOLLOW_assertDef_in_interactionDef881) assertDef98 = self.assertDef() self._state.following.pop() if self._state.backtracking == 0: stream_assertDef.add(assertDef98.tree) # AST Rewrite # elements: roleName, assertDef, interactionSignatureDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 93:37: -> ^( SEND interactionSignatureDef roleName assertDef ) # src/SavedFSM/Monitor.g:93:40: ^( SEND interactionSignatureDef roleName assertDef ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(SEND, "SEND"), root_1) self._adaptor.addChild(root_1, stream_interactionSignatureDef.nextTree()) self._adaptor.addChild(root_1, stream_roleName.nextTree()) self._adaptor.addChild(root_1, stream_assertDef.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "interactionDef" class choiceDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.choiceDef_return, self).__init__() self.tree = None # $ANTLR start "choiceDef" # src/SavedFSM/Monitor.g:95:1: choiceDef : 'choice' ( 'at' roleName )? blockDef ( 'or' blockDef )* -> ^( 'choice' ( blockDef )+ ) ; def choiceDef(self, ): retval = self.choiceDef_return() retval.start = self.input.LT(1) root_0 = None string_literal99 = None string_literal100 = None string_literal103 = None roleName101 = None blockDef102 = None blockDef104 = None string_literal99_tree = None string_literal100_tree = None string_literal103_tree = None stream_49 = RewriteRuleTokenStream(self._adaptor, "token 49") stream_40 = RewriteRuleTokenStream(self._adaptor, "token 40") stream_50 = RewriteRuleTokenStream(self._adaptor, "token 50") stream_roleName = RewriteRuleSubtreeStream(self._adaptor, "rule roleName") stream_blockDef = RewriteRuleSubtreeStream(self._adaptor, "rule blockDef") try: try: # src/SavedFSM/Monitor.g:95:10: ( 'choice' ( 'at' roleName )? blockDef ( 'or' blockDef )* -> ^( 'choice' ( blockDef )+ ) ) # src/SavedFSM/Monitor.g:95:12: 'choice' ( 'at' roleName )? blockDef ( 'or' blockDef )* pass string_literal99=self.match(self.input, 49, self.FOLLOW_49_in_choiceDef902) if self._state.backtracking == 0: stream_49.add(string_literal99) # src/SavedFSM/Monitor.g:95:21: ( 'at' roleName )? alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == 40) : alt28 = 1 if alt28 == 1: # src/SavedFSM/Monitor.g:95:23: 'at' roleName pass string_literal100=self.match(self.input, 40, self.FOLLOW_40_in_choiceDef906) if self._state.backtracking == 0: stream_40.add(string_literal100) self._state.following.append(self.FOLLOW_roleName_in_choiceDef908) roleName101 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: stream_roleName.add(roleName101.tree) self._state.following.append(self.FOLLOW_blockDef_in_choiceDef913) blockDef102 = self.blockDef() self._state.following.pop() if self._state.backtracking == 0: stream_blockDef.add(blockDef102.tree) # src/SavedFSM/Monitor.g:95:49: ( 'or' blockDef )* while True: #loop29 alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == 50) : alt29 = 1 if alt29 == 1: # src/SavedFSM/Monitor.g:95:51: 'or' blockDef pass string_literal103=self.match(self.input, 50, self.FOLLOW_50_in_choiceDef917) if self._state.backtracking == 0: stream_50.add(string_literal103) self._state.following.append(self.FOLLOW_blockDef_in_choiceDef919) blockDef104 = self.blockDef() self._state.following.pop() if self._state.backtracking == 0: stream_blockDef.add(blockDef104.tree) else: break #loop29 # AST Rewrite # elements: 49, blockDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 95:68: -> ^( 'choice' ( blockDef )+ ) # src/SavedFSM/Monitor.g:95:71: ^( 'choice' ( blockDef )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_49.nextNode(), root_1) # src/SavedFSM/Monitor.g:95:82: ( blockDef )+ if not (stream_blockDef.hasNext()): raise RewriteEarlyExitException() while stream_blockDef.hasNext(): self._adaptor.addChild(root_1, stream_blockDef.nextTree()) stream_blockDef.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "choiceDef" class directedChoiceDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.directedChoiceDef_return, self).__init__() self.tree = None # $ANTLR start "directedChoiceDef" # src/SavedFSM/Monitor.g:97:1: directedChoiceDef : ( 'from' roleName )? ( 'to' roleName ( ',' roleName )* )? '{' ( onMessageDef )+ '}' ; def directedChoiceDef(self, ): retval = self.directedChoiceDef_return() retval.start = self.input.LT(1) root_0 = None string_literal105 = None string_literal107 = None char_literal109 = None char_literal111 = None char_literal113 = None roleName106 = None roleName108 = None roleName110 = None onMessageDef112 = None string_literal105_tree = None string_literal107_tree = None char_literal109_tree = None char_literal111_tree = None char_literal113_tree = None try: try: # src/SavedFSM/Monitor.g:97:18: ( ( 'from' roleName )? ( 'to' roleName ( ',' roleName )* )? '{' ( onMessageDef )+ '}' ) # src/SavedFSM/Monitor.g:97:20: ( 'from' roleName )? ( 'to' roleName ( ',' roleName )* )? '{' ( onMessageDef )+ '}' pass root_0 = self._adaptor.nil() # src/SavedFSM/Monitor.g:97:20: ( 'from' roleName )? alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == 38) : alt30 = 1 if alt30 == 1: # src/SavedFSM/Monitor.g:97:22: 'from' roleName pass string_literal105=self.match(self.input, 38, self.FOLLOW_38_in_directedChoiceDef940) if self._state.backtracking == 0: string_literal105_tree = self._adaptor.createWithPayload(string_literal105) self._adaptor.addChild(root_0, string_literal105_tree) self._state.following.append(self.FOLLOW_roleName_in_directedChoiceDef942) roleName106 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, roleName106.tree) # src/SavedFSM/Monitor.g:97:41: ( 'to' roleName ( ',' roleName )* )? alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == 48) : alt32 = 1 if alt32 == 1: # src/SavedFSM/Monitor.g:97:43: 'to' roleName ( ',' roleName )* pass string_literal107=self.match(self.input, 48, self.FOLLOW_48_in_directedChoiceDef949) if self._state.backtracking == 0: string_literal107_tree = self._adaptor.createWithPayload(string_literal107) self._adaptor.addChild(root_0, string_literal107_tree) self._state.following.append(self.FOLLOW_roleName_in_directedChoiceDef951) roleName108 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, roleName108.tree) # src/SavedFSM/Monitor.g:97:57: ( ',' roleName )* while True: #loop31 alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == 36) : alt31 = 1 if alt31 == 1: # src/SavedFSM/Monitor.g:97:59: ',' roleName pass char_literal109=self.match(self.input, 36, self.FOLLOW_36_in_directedChoiceDef955) self._state.following.append(self.FOLLOW_roleName_in_directedChoiceDef958) roleName110 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, roleName110.tree) else: break #loop31 char_literal111=self.match(self.input, 41, self.FOLLOW_41_in_directedChoiceDef966) if self._state.backtracking == 0: char_literal111_tree = self._adaptor.createWithPayload(char_literal111) self._adaptor.addChild(root_0, char_literal111_tree) # src/SavedFSM/Monitor.g:97:83: ( onMessageDef )+ cnt33 = 0 while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == ID or LA33_0 == 43) : alt33 = 1 if alt33 == 1: # src/SavedFSM/Monitor.g:97:85: onMessageDef pass self._state.following.append(self.FOLLOW_onMessageDef_in_directedChoiceDef970) onMessageDef112 = self.onMessageDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, onMessageDef112.tree) else: if cnt33 >= 1: break #loop33 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(33, self.input) raise eee cnt33 += 1 char_literal113=self.match(self.input, 42, self.FOLLOW_42_in_directedChoiceDef975) if self._state.backtracking == 0: char_literal113_tree = self._adaptor.createWithPayload(char_literal113) self._adaptor.addChild(root_0, char_literal113_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "directedChoiceDef" class onMessageDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.onMessageDef_return, self).__init__() self.tree = None # $ANTLR start "onMessageDef" # src/SavedFSM/Monitor.g:99:1: onMessageDef : interactionSignatureDef ':' activityList ; def onMessageDef(self, ): retval = self.onMessageDef_return() retval.start = self.input.LT(1) root_0 = None char_literal115 = None interactionSignatureDef114 = None activityList116 = None char_literal115_tree = None try: try: # src/SavedFSM/Monitor.g:99:13: ( interactionSignatureDef ':' activityList ) # src/SavedFSM/Monitor.g:99:15: interactionSignatureDef ':' activityList pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_interactionSignatureDef_in_onMessageDef982) interactionSignatureDef114 = self.interactionSignatureDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, interactionSignatureDef114.tree) char_literal115=self.match(self.input, 47, self.FOLLOW_47_in_onMessageDef984) if self._state.backtracking == 0: char_literal115_tree = self._adaptor.createWithPayload(char_literal115) self._adaptor.addChild(root_0, char_literal115_tree) self._state.following.append(self.FOLLOW_activityList_in_onMessageDef986) activityList116 = self.activityList() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, activityList116.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "onMessageDef" class activityList_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.activityList_return, self).__init__() self.tree = None # $ANTLR start "activityList" # src/SavedFSM/Monitor.g:101:1: activityList : ( ( ANNOTATION )* activityDef )* ; def activityList(self, ): retval = self.activityList_return() retval.start = self.input.LT(1) root_0 = None ANNOTATION117 = None activityDef118 = None ANNOTATION117_tree = None try: try: # src/SavedFSM/Monitor.g:101:13: ( ( ( ANNOTATION )* activityDef )* ) # src/SavedFSM/Monitor.g:101:15: ( ( ANNOTATION )* activityDef )* pass root_0 = self._adaptor.nil() # src/SavedFSM/Monitor.g:101:15: ( ( ANNOTATION )* activityDef )* while True: #loop35 alt35 = 2 alt35 = self.dfa35.predict(self.input) if alt35 == 1: # src/SavedFSM/Monitor.g:101:17: ( ANNOTATION )* activityDef pass # src/SavedFSM/Monitor.g:101:17: ( ANNOTATION )* while True: #loop34 alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == ANNOTATION) : alt34 = 1 if alt34 == 1: # src/SavedFSM/Monitor.g:101:19: ANNOTATION pass ANNOTATION117=self.match(self.input, ANNOTATION, self.FOLLOW_ANNOTATION_in_activityList999) if self._state.backtracking == 0: ANNOTATION117_tree = self._adaptor.createWithPayload(ANNOTATION117) self._adaptor.addChild(root_0, ANNOTATION117_tree) else: break #loop34 self._state.following.append(self.FOLLOW_activityDef_in_activityList1004) activityDef118 = self.activityDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, activityDef118.tree) else: break #loop35 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "activityList" class repeatDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.repeatDef_return, self).__init__() self.tree = None # $ANTLR start "repeatDef" # src/SavedFSM/Monitor.g:103:1: repeatDef : 'repeat' ( 'at' roleName ( ',' roleName )* )? blockDef -> ^( 'repeat' blockDef ) ; def repeatDef(self, ): retval = self.repeatDef_return() retval.start = self.input.LT(1) root_0 = None string_literal119 = None string_literal120 = None char_literal122 = None roleName121 = None roleName123 = None blockDef124 = None string_literal119_tree = None string_literal120_tree = None char_literal122_tree = None stream_40 = RewriteRuleTokenStream(self._adaptor, "token 40") stream_51 = RewriteRuleTokenStream(self._adaptor, "token 51") stream_36 = RewriteRuleTokenStream(self._adaptor, "token 36") stream_roleName = RewriteRuleSubtreeStream(self._adaptor, "rule roleName") stream_blockDef = RewriteRuleSubtreeStream(self._adaptor, "rule blockDef") try: try: # src/SavedFSM/Monitor.g:103:10: ( 'repeat' ( 'at' roleName ( ',' roleName )* )? blockDef -> ^( 'repeat' blockDef ) ) # src/SavedFSM/Monitor.g:103:12: 'repeat' ( 'at' roleName ( ',' roleName )* )? blockDef pass string_literal119=self.match(self.input, 51, self.FOLLOW_51_in_repeatDef1014) if self._state.backtracking == 0: stream_51.add(string_literal119) # src/SavedFSM/Monitor.g:103:21: ( 'at' roleName ( ',' roleName )* )? alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == 40) : alt37 = 1 if alt37 == 1: # src/SavedFSM/Monitor.g:103:23: 'at' roleName ( ',' roleName )* pass string_literal120=self.match(self.input, 40, self.FOLLOW_40_in_repeatDef1018) if self._state.backtracking == 0: stream_40.add(string_literal120) self._state.following.append(self.FOLLOW_roleName_in_repeatDef1020) roleName121 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: stream_roleName.add(roleName121.tree) # src/SavedFSM/Monitor.g:103:37: ( ',' roleName )* while True: #loop36 alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == 36) : alt36 = 1 if alt36 == 1: # src/SavedFSM/Monitor.g:103:39: ',' roleName pass char_literal122=self.match(self.input, 36, self.FOLLOW_36_in_repeatDef1024) if self._state.backtracking == 0: stream_36.add(char_literal122) self._state.following.append(self.FOLLOW_roleName_in_repeatDef1026) roleName123 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: stream_roleName.add(roleName123.tree) else: break #loop36 self._state.following.append(self.FOLLOW_blockDef_in_repeatDef1034) blockDef124 = self.blockDef() self._state.following.pop() if self._state.backtracking == 0: stream_blockDef.add(blockDef124.tree) # AST Rewrite # elements: 51, blockDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 103:68: -> ^( 'repeat' blockDef ) # src/SavedFSM/Monitor.g:103:71: ^( 'repeat' blockDef ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_51.nextNode(), root_1) self._adaptor.addChild(root_1, stream_blockDef.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "repeatDef" class recBlockDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.recBlockDef_return, self).__init__() self.tree = None # $ANTLR start "recBlockDef" # src/SavedFSM/Monitor.g:105:1: recBlockDef : 'rec' labelName blockDef -> ^( 'rec' labelName blockDef ) ; def recBlockDef(self, ): retval = self.recBlockDef_return() retval.start = self.input.LT(1) root_0 = None string_literal125 = None labelName126 = None blockDef127 = None string_literal125_tree = None stream_52 = RewriteRuleTokenStream(self._adaptor, "token 52") stream_labelName = RewriteRuleSubtreeStream(self._adaptor, "rule labelName") stream_blockDef = RewriteRuleSubtreeStream(self._adaptor, "rule blockDef") try: try: # src/SavedFSM/Monitor.g:105:12: ( 'rec' labelName blockDef -> ^( 'rec' labelName blockDef ) ) # src/SavedFSM/Monitor.g:105:14: 'rec' labelName blockDef pass string_literal125=self.match(self.input, 52, self.FOLLOW_52_in_recBlockDef1050) if self._state.backtracking == 0: stream_52.add(string_literal125) self._state.following.append(self.FOLLOW_labelName_in_recBlockDef1052) labelName126 = self.labelName() self._state.following.pop() if self._state.backtracking == 0: stream_labelName.add(labelName126.tree) self._state.following.append(self.FOLLOW_blockDef_in_recBlockDef1054) blockDef127 = self.blockDef() self._state.following.pop() if self._state.backtracking == 0: stream_blockDef.add(blockDef127.tree) # AST Rewrite # elements: labelName, blockDef, 52 # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 105:39: -> ^( 'rec' labelName blockDef ) # src/SavedFSM/Monitor.g:105:42: ^( 'rec' labelName blockDef ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_52.nextNode(), root_1) self._adaptor.addChild(root_1, stream_labelName.nextTree()) self._adaptor.addChild(root_1, stream_blockDef.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "recBlockDef" class labelName_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.labelName_return, self).__init__() self.tree = None # $ANTLR start "labelName" # src/SavedFSM/Monitor.g:107:1: labelName : ID -> ID ; def labelName(self, ): retval = self.labelName_return() retval.start = self.input.LT(1) root_0 = None ID128 = None ID128_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") try: try: # src/SavedFSM/Monitor.g:107:10: ( ID -> ID ) # src/SavedFSM/Monitor.g:107:12: ID pass ID128=self.match(self.input, ID, self.FOLLOW_ID_in_labelName1071) if self._state.backtracking == 0: stream_ID.add(ID128) # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 107:15: -> ID self._adaptor.addChild(root_0, stream_ID.nextNode()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "labelName" class recursionDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.recursionDef_return, self).__init__() self.tree = None # $ANTLR start "recursionDef" # src/SavedFSM/Monitor.g:109:1: recursionDef : labelName -> ^( RECLABEL labelName ) ; def recursionDef(self, ): retval = self.recursionDef_return() retval.start = self.input.LT(1) root_0 = None labelName129 = None stream_labelName = RewriteRuleSubtreeStream(self._adaptor, "rule labelName") try: try: # src/SavedFSM/Monitor.g:109:13: ( labelName -> ^( RECLABEL labelName ) ) # src/SavedFSM/Monitor.g:109:15: labelName pass self._state.following.append(self.FOLLOW_labelName_in_recursionDef1083) labelName129 = self.labelName() self._state.following.pop() if self._state.backtracking == 0: stream_labelName.add(labelName129.tree) # AST Rewrite # elements: labelName # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 109:25: -> ^( RECLABEL labelName ) # src/SavedFSM/Monitor.g:109:28: ^( RECLABEL labelName ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(RECLABEL, "RECLABEL"), root_1) self._adaptor.addChild(root_1, stream_labelName.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "recursionDef" class endDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.endDef_return, self).__init__() self.tree = None # $ANTLR start "endDef" # src/SavedFSM/Monitor.g:112:1: endDef : 'end' ; def endDef(self, ): retval = self.endDef_return() retval.start = self.input.LT(1) root_0 = None string_literal130 = None string_literal130_tree = None try: try: # src/SavedFSM/Monitor.g:112:7: ( 'end' ) # src/SavedFSM/Monitor.g:112:9: 'end' pass root_0 = self._adaptor.nil() string_literal130=self.match(self.input, 53, self.FOLLOW_53_in_endDef1099) if self._state.backtracking == 0: string_literal130_tree = self._adaptor.createWithPayload(string_literal130) root_0 = self._adaptor.becomeRoot(string_literal130_tree, root_0) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "endDef" class runDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.runDef_return, self).__init__() self.tree = None # $ANTLR start "runDef" # src/SavedFSM/Monitor.g:115:1: runDef : 'run' protocolRefDef ( '(' parameter ( ',' parameter )* ')' )? 'from' roleName ; def runDef(self, ): retval = self.runDef_return() retval.start = self.input.LT(1) root_0 = None string_literal131 = None char_literal133 = None char_literal135 = None char_literal137 = None string_literal138 = None protocolRefDef132 = None parameter134 = None parameter136 = None roleName139 = None string_literal131_tree = None char_literal133_tree = None char_literal135_tree = None char_literal137_tree = None string_literal138_tree = None try: try: # src/SavedFSM/Monitor.g:115:7: ( 'run' protocolRefDef ( '(' parameter ( ',' parameter )* ')' )? 'from' roleName ) # src/SavedFSM/Monitor.g:115:9: 'run' protocolRefDef ( '(' parameter ( ',' parameter )* ')' )? 'from' roleName pass root_0 = self._adaptor.nil() string_literal131=self.match(self.input, 54, self.FOLLOW_54_in_runDef1109) if self._state.backtracking == 0: string_literal131_tree = self._adaptor.createWithPayload(string_literal131) root_0 = self._adaptor.becomeRoot(string_literal131_tree, root_0) self._state.following.append(self.FOLLOW_protocolRefDef_in_runDef1112) protocolRefDef132 = self.protocolRefDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, protocolRefDef132.tree) # src/SavedFSM/Monitor.g:115:31: ( '(' parameter ( ',' parameter )* ')' )? alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == 43) : alt39 = 1 if alt39 == 1: # src/SavedFSM/Monitor.g:115:33: '(' parameter ( ',' parameter )* ')' pass char_literal133=self.match(self.input, 43, self.FOLLOW_43_in_runDef1116) self._state.following.append(self.FOLLOW_parameter_in_runDef1119) parameter134 = self.parameter() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, parameter134.tree) # src/SavedFSM/Monitor.g:115:48: ( ',' parameter )* while True: #loop38 alt38 = 2 LA38_0 = self.input.LA(1) if (LA38_0 == 36) : alt38 = 1 if alt38 == 1: # src/SavedFSM/Monitor.g:115:50: ',' parameter pass char_literal135=self.match(self.input, 36, self.FOLLOW_36_in_runDef1123) self._state.following.append(self.FOLLOW_parameter_in_runDef1126) parameter136 = self.parameter() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, parameter136.tree) else: break #loop38 char_literal137=self.match(self.input, 44, self.FOLLOW_44_in_runDef1131) string_literal138=self.match(self.input, 38, self.FOLLOW_38_in_runDef1137) if self._state.backtracking == 0: string_literal138_tree = self._adaptor.createWithPayload(string_literal138) self._adaptor.addChild(root_0, string_literal138_tree) self._state.following.append(self.FOLLOW_roleName_in_runDef1139) roleName139 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, roleName139.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "runDef" class protocolRefDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.protocolRefDef_return, self).__init__() self.tree = None # $ANTLR start "protocolRefDef" # src/SavedFSM/Monitor.g:117:1: protocolRefDef : ID ( 'at' roleName )? ; def protocolRefDef(self, ): retval = self.protocolRefDef_return() retval.start = self.input.LT(1) root_0 = None ID140 = None string_literal141 = None roleName142 = None ID140_tree = None string_literal141_tree = None try: try: # src/SavedFSM/Monitor.g:117:15: ( ID ( 'at' roleName )? ) # src/SavedFSM/Monitor.g:117:17: ID ( 'at' roleName )? pass root_0 = self._adaptor.nil() ID140=self.match(self.input, ID, self.FOLLOW_ID_in_protocolRefDef1147) if self._state.backtracking == 0: ID140_tree = self._adaptor.createWithPayload(ID140) self._adaptor.addChild(root_0, ID140_tree) # src/SavedFSM/Monitor.g:117:20: ( 'at' roleName )? alt40 = 2 LA40_0 = self.input.LA(1) if (LA40_0 == 40) : alt40 = 1 if alt40 == 1: # src/SavedFSM/Monitor.g:117:22: 'at' roleName pass string_literal141=self.match(self.input, 40, self.FOLLOW_40_in_protocolRefDef1151) if self._state.backtracking == 0: string_literal141_tree = self._adaptor.createWithPayload(string_literal141) self._adaptor.addChild(root_0, string_literal141_tree) self._state.following.append(self.FOLLOW_roleName_in_protocolRefDef1153) roleName142 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, roleName142.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "protocolRefDef" class declarationName_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.declarationName_return, self).__init__() self.tree = None # $ANTLR start "declarationName" # src/SavedFSM/Monitor.g:119:1: declarationName : ID ; def declarationName(self, ): retval = self.declarationName_return() retval.start = self.input.LT(1) root_0 = None ID143 = None ID143_tree = None try: try: # src/SavedFSM/Monitor.g:119:16: ( ID ) # src/SavedFSM/Monitor.g:119:18: ID pass root_0 = self._adaptor.nil() ID143=self.match(self.input, ID, self.FOLLOW_ID_in_declarationName1164) if self._state.backtracking == 0: ID143_tree = self._adaptor.createWithPayload(ID143) self._adaptor.addChild(root_0, ID143_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "declarationName" class parameter_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.parameter_return, self).__init__() self.tree = None # $ANTLR start "parameter" # src/SavedFSM/Monitor.g:121:1: parameter : declarationName ; def parameter(self, ): retval = self.parameter_return() retval.start = self.input.LT(1) root_0 = None declarationName144 = None try: try: # src/SavedFSM/Monitor.g:121:10: ( declarationName ) # src/SavedFSM/Monitor.g:121:12: declarationName pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_declarationName_in_parameter1172) declarationName144 = self.declarationName() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, declarationName144.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "parameter" class inlineDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.inlineDef_return, self).__init__() self.tree = None # $ANTLR start "inlineDef" # src/SavedFSM/Monitor.g:124:1: inlineDef : 'inline' protocolRefDef ( '(' parameter ( ',' parameter )* ')' )? ; def inlineDef(self, ): retval = self.inlineDef_return() retval.start = self.input.LT(1) root_0 = None string_literal145 = None char_literal147 = None char_literal149 = None char_literal151 = None protocolRefDef146 = None parameter148 = None parameter150 = None string_literal145_tree = None char_literal147_tree = None char_literal149_tree = None char_literal151_tree = None try: try: # src/SavedFSM/Monitor.g:124:10: ( 'inline' protocolRefDef ( '(' parameter ( ',' parameter )* ')' )? ) # src/SavedFSM/Monitor.g:124:12: 'inline' protocolRefDef ( '(' parameter ( ',' parameter )* ')' )? pass root_0 = self._adaptor.nil() string_literal145=self.match(self.input, 55, self.FOLLOW_55_in_inlineDef1181) if self._state.backtracking == 0: string_literal145_tree = self._adaptor.createWithPayload(string_literal145) root_0 = self._adaptor.becomeRoot(string_literal145_tree, root_0) self._state.following.append(self.FOLLOW_protocolRefDef_in_inlineDef1184) protocolRefDef146 = self.protocolRefDef() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, protocolRefDef146.tree) # src/SavedFSM/Monitor.g:124:37: ( '(' parameter ( ',' parameter )* ')' )? alt42 = 2 LA42_0 = self.input.LA(1) if (LA42_0 == 43) : alt42 = 1 if alt42 == 1: # src/SavedFSM/Monitor.g:124:39: '(' parameter ( ',' parameter )* ')' pass char_literal147=self.match(self.input, 43, self.FOLLOW_43_in_inlineDef1188) self._state.following.append(self.FOLLOW_parameter_in_inlineDef1191) parameter148 = self.parameter() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, parameter148.tree) # src/SavedFSM/Monitor.g:124:54: ( ',' parameter )* while True: #loop41 alt41 = 2 LA41_0 = self.input.LA(1) if (LA41_0 == 36) : alt41 = 1 if alt41 == 1: # src/SavedFSM/Monitor.g:124:56: ',' parameter pass char_literal149=self.match(self.input, 36, self.FOLLOW_36_in_inlineDef1195) self._state.following.append(self.FOLLOW_parameter_in_inlineDef1198) parameter150 = self.parameter() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, parameter150.tree) else: break #loop41 char_literal151=self.match(self.input, 44, self.FOLLOW_44_in_inlineDef1203) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "inlineDef" class parallelDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.parallelDef_return, self).__init__() self.tree = None # $ANTLR start "parallelDef" # src/SavedFSM/Monitor.g:126:1: parallelDef : 'parallel' blockDef ( 'and' blockDef )* -> ^( PARALLEL ( blockDef )+ ) ; def parallelDef(self, ): retval = self.parallelDef_return() retval.start = self.input.LT(1) root_0 = None string_literal152 = None string_literal154 = None blockDef153 = None blockDef155 = None string_literal152_tree = None string_literal154_tree = None stream_57 = RewriteRuleTokenStream(self._adaptor, "token 57") stream_56 = RewriteRuleTokenStream(self._adaptor, "token 56") stream_blockDef = RewriteRuleSubtreeStream(self._adaptor, "rule blockDef") try: try: # src/SavedFSM/Monitor.g:126:12: ( 'parallel' blockDef ( 'and' blockDef )* -> ^( PARALLEL ( blockDef )+ ) ) # src/SavedFSM/Monitor.g:126:14: 'parallel' blockDef ( 'and' blockDef )* pass string_literal152=self.match(self.input, 56, self.FOLLOW_56_in_parallelDef1215) if self._state.backtracking == 0: stream_56.add(string_literal152) self._state.following.append(self.FOLLOW_blockDef_in_parallelDef1217) blockDef153 = self.blockDef() self._state.following.pop() if self._state.backtracking == 0: stream_blockDef.add(blockDef153.tree) # src/SavedFSM/Monitor.g:126:34: ( 'and' blockDef )* while True: #loop43 alt43 = 2 LA43_0 = self.input.LA(1) if (LA43_0 == 57) : alt43 = 1 if alt43 == 1: # src/SavedFSM/Monitor.g:126:36: 'and' blockDef pass string_literal154=self.match(self.input, 57, self.FOLLOW_57_in_parallelDef1221) if self._state.backtracking == 0: stream_57.add(string_literal154) self._state.following.append(self.FOLLOW_blockDef_in_parallelDef1223) blockDef155 = self.blockDef() self._state.following.pop() if self._state.backtracking == 0: stream_blockDef.add(blockDef155.tree) else: break #loop43 # AST Rewrite # elements: blockDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 126:54: -> ^( PARALLEL ( blockDef )+ ) # src/SavedFSM/Monitor.g:126:57: ^( PARALLEL ( blockDef )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(PARALLEL, "PARALLEL"), root_1) # src/SavedFSM/Monitor.g:126:68: ( blockDef )+ if not (stream_blockDef.hasNext()): raise RewriteEarlyExitException() while stream_blockDef.hasNext(): self._adaptor.addChild(root_1, stream_blockDef.nextTree()) stream_blockDef.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "parallelDef" class doBlockDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.doBlockDef_return, self).__init__() self.tree = None # $ANTLR start "doBlockDef" # src/SavedFSM/Monitor.g:129:1: doBlockDef : 'do' '{' activityListDef '}' -> ^( 'do' activityListDef ) ; def doBlockDef(self, ): retval = self.doBlockDef_return() retval.start = self.input.LT(1) root_0 = None string_literal156 = None char_literal157 = None char_literal159 = None activityListDef158 = None string_literal156_tree = None char_literal157_tree = None char_literal159_tree = None stream_58 = RewriteRuleTokenStream(self._adaptor, "token 58") stream_42 = RewriteRuleTokenStream(self._adaptor, "token 42") stream_41 = RewriteRuleTokenStream(self._adaptor, "token 41") stream_activityListDef = RewriteRuleSubtreeStream(self._adaptor, "rule activityListDef") try: try: # src/SavedFSM/Monitor.g:129:11: ( 'do' '{' activityListDef '}' -> ^( 'do' activityListDef ) ) # src/SavedFSM/Monitor.g:129:13: 'do' '{' activityListDef '}' pass string_literal156=self.match(self.input, 58, self.FOLLOW_58_in_doBlockDef1243) if self._state.backtracking == 0: stream_58.add(string_literal156) char_literal157=self.match(self.input, 41, self.FOLLOW_41_in_doBlockDef1245) if self._state.backtracking == 0: stream_41.add(char_literal157) self._state.following.append(self.FOLLOW_activityListDef_in_doBlockDef1247) activityListDef158 = self.activityListDef() self._state.following.pop() if self._state.backtracking == 0: stream_activityListDef.add(activityListDef158.tree) char_literal159=self.match(self.input, 42, self.FOLLOW_42_in_doBlockDef1250) if self._state.backtracking == 0: stream_42.add(char_literal159) # AST Rewrite # elements: activityListDef, 58 # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 129:43: -> ^( 'do' activityListDef ) # src/SavedFSM/Monitor.g:129:46: ^( 'do' activityListDef ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_58.nextNode(), root_1) self._adaptor.addChild(root_1, stream_activityListDef.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "doBlockDef" class interruptDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.interruptDef_return, self).__init__() self.tree = None # $ANTLR start "interruptDef" # src/SavedFSM/Monitor.g:131:1: interruptDef : 'interrupt' 'by' roleName '{' activityListDef '}' -> ^( 'interrupt' roleName activityListDef ) ; def interruptDef(self, ): retval = self.interruptDef_return() retval.start = self.input.LT(1) root_0 = None string_literal160 = None string_literal161 = None char_literal163 = None char_literal165 = None roleName162 = None activityListDef164 = None string_literal160_tree = None string_literal161_tree = None char_literal163_tree = None char_literal165_tree = None stream_59 = RewriteRuleTokenStream(self._adaptor, "token 59") stream_42 = RewriteRuleTokenStream(self._adaptor, "token 42") stream_41 = RewriteRuleTokenStream(self._adaptor, "token 41") stream_60 = RewriteRuleTokenStream(self._adaptor, "token 60") stream_activityListDef = RewriteRuleSubtreeStream(self._adaptor, "rule activityListDef") stream_roleName = RewriteRuleSubtreeStream(self._adaptor, "rule roleName") try: try: # src/SavedFSM/Monitor.g:131:13: ( 'interrupt' 'by' roleName '{' activityListDef '}' -> ^( 'interrupt' roleName activityListDef ) ) # src/SavedFSM/Monitor.g:131:15: 'interrupt' 'by' roleName '{' activityListDef '}' pass string_literal160=self.match(self.input, 59, self.FOLLOW_59_in_interruptDef1268) if self._state.backtracking == 0: stream_59.add(string_literal160) string_literal161=self.match(self.input, 60, self.FOLLOW_60_in_interruptDef1270) if self._state.backtracking == 0: stream_60.add(string_literal161) self._state.following.append(self.FOLLOW_roleName_in_interruptDef1272) roleName162 = self.roleName() self._state.following.pop() if self._state.backtracking == 0: stream_roleName.add(roleName162.tree) char_literal163=self.match(self.input, 41, self.FOLLOW_41_in_interruptDef1274) if self._state.backtracking == 0: stream_41.add(char_literal163) self._state.following.append(self.FOLLOW_activityListDef_in_interruptDef1276) activityListDef164 = self.activityListDef() self._state.following.pop() if self._state.backtracking == 0: stream_activityListDef.add(activityListDef164.tree) char_literal165=self.match(self.input, 42, self.FOLLOW_42_in_interruptDef1278) if self._state.backtracking == 0: stream_42.add(char_literal165) # AST Rewrite # elements: activityListDef, 59, roleName # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 131:65: -> ^( 'interrupt' roleName activityListDef ) # src/SavedFSM/Monitor.g:131:68: ^( 'interrupt' roleName activityListDef ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(stream_59.nextNode(), root_1) self._adaptor.addChild(root_1, stream_roleName.nextTree()) self._adaptor.addChild(root_1, stream_activityListDef.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "interruptDef" class globalEscapeDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.globalEscapeDef_return, self).__init__() self.tree = None # $ANTLR start "globalEscapeDef" # src/SavedFSM/Monitor.g:133:1: globalEscapeDef : doBlockDef interruptDef -> ^( GLOBAL_ESCAPE doBlockDef interruptDef ) ; def globalEscapeDef(self, ): retval = self.globalEscapeDef_return() retval.start = self.input.LT(1) root_0 = None doBlockDef166 = None interruptDef167 = None stream_interruptDef = RewriteRuleSubtreeStream(self._adaptor, "rule interruptDef") stream_doBlockDef = RewriteRuleSubtreeStream(self._adaptor, "rule doBlockDef") try: try: # src/SavedFSM/Monitor.g:133:16: ( doBlockDef interruptDef -> ^( GLOBAL_ESCAPE doBlockDef interruptDef ) ) # src/SavedFSM/Monitor.g:133:19: doBlockDef interruptDef pass self._state.following.append(self.FOLLOW_doBlockDef_in_globalEscapeDef1296) doBlockDef166 = self.doBlockDef() self._state.following.pop() if self._state.backtracking == 0: stream_doBlockDef.add(doBlockDef166.tree) self._state.following.append(self.FOLLOW_interruptDef_in_globalEscapeDef1299) interruptDef167 = self.interruptDef() self._state.following.pop() if self._state.backtracking == 0: stream_interruptDef.add(interruptDef167.tree) # AST Rewrite # elements: interruptDef, doBlockDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 133:44: -> ^( GLOBAL_ESCAPE doBlockDef interruptDef ) # src/SavedFSM/Monitor.g:133:47: ^( GLOBAL_ESCAPE doBlockDef interruptDef ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(GLOBAL_ESCAPE, "GLOBAL_ESCAPE"), root_1) self._adaptor.addChild(root_1, stream_doBlockDef.nextTree()) self._adaptor.addChild(root_1, stream_interruptDef.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "globalEscapeDef" class unorderedDef_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.unorderedDef_return, self).__init__() self.tree = None # $ANTLR start "unorderedDef" # src/SavedFSM/Monitor.g:135:1: unorderedDef : 'unordered' '{' ( ( ANNOTATION )* activityDef )* '}' -> ^( PARALLEL ( ^( BRANCH activityDef ) )+ ) ; def unorderedDef(self, ): retval = self.unorderedDef_return() retval.start = self.input.LT(1) root_0 = None string_literal168 = None char_literal169 = None ANNOTATION170 = None char_literal172 = None activityDef171 = None string_literal168_tree = None char_literal169_tree = None ANNOTATION170_tree = None char_literal172_tree = None stream_42 = RewriteRuleTokenStream(self._adaptor, "token 42") stream_41 = RewriteRuleTokenStream(self._adaptor, "token 41") stream_ANNOTATION = RewriteRuleTokenStream(self._adaptor, "token ANNOTATION") stream_61 = RewriteRuleTokenStream(self._adaptor, "token 61") stream_activityDef = RewriteRuleSubtreeStream(self._adaptor, "rule activityDef") try: try: # src/SavedFSM/Monitor.g:135:13: ( 'unordered' '{' ( ( ANNOTATION )* activityDef )* '}' -> ^( PARALLEL ( ^( BRANCH activityDef ) )+ ) ) # src/SavedFSM/Monitor.g:135:15: 'unordered' '{' ( ( ANNOTATION )* activityDef )* '}' pass string_literal168=self.match(self.input, 61, self.FOLLOW_61_in_unorderedDef1316) if self._state.backtracking == 0: stream_61.add(string_literal168) char_literal169=self.match(self.input, 41, self.FOLLOW_41_in_unorderedDef1318) if self._state.backtracking == 0: stream_41.add(char_literal169) # src/SavedFSM/Monitor.g:135:31: ( ( ANNOTATION )* activityDef )* while True: #loop45 alt45 = 2 LA45_0 = self.input.LA(1) if (LA45_0 == RECLABEL or (ANNOTATION <= LA45_0 <= ID) or LA45_0 == 38 or LA45_0 == 41 or LA45_0 == 43 or (48 <= LA45_0 <= 49) or (51 <= LA45_0 <= 56) or LA45_0 == 58 or LA45_0 == 61) : alt45 = 1 if alt45 == 1: # src/SavedFSM/Monitor.g:135:33: ( ANNOTATION )* activityDef pass # src/SavedFSM/Monitor.g:135:33: ( ANNOTATION )* while True: #loop44 alt44 = 2 LA44_0 = self.input.LA(1) if (LA44_0 == ANNOTATION) : alt44 = 1 if alt44 == 1: # src/SavedFSM/Monitor.g:135:35: ANNOTATION pass ANNOTATION170=self.match(self.input, ANNOTATION, self.FOLLOW_ANNOTATION_in_unorderedDef1324) if self._state.backtracking == 0: stream_ANNOTATION.add(ANNOTATION170) else: break #loop44 self._state.following.append(self.FOLLOW_activityDef_in_unorderedDef1329) activityDef171 = self.activityDef() self._state.following.pop() if self._state.backtracking == 0: stream_activityDef.add(activityDef171.tree) else: break #loop45 char_literal172=self.match(self.input, 42, self.FOLLOW_42_in_unorderedDef1334) if self._state.backtracking == 0: stream_42.add(char_literal172) # AST Rewrite # elements: activityDef # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 135:68: -> ^( PARALLEL ( ^( BRANCH activityDef ) )+ ) # src/SavedFSM/Monitor.g:135:71: ^( PARALLEL ( ^( BRANCH activityDef ) )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot(self._adaptor.createFromType(PARALLEL, "PARALLEL"), root_1) # src/SavedFSM/Monitor.g:135:82: ( ^( BRANCH activityDef ) )+ if not (stream_activityDef.hasNext()): raise RewriteEarlyExitException() while stream_activityDef.hasNext(): # src/SavedFSM/Monitor.g:135:82: ^( BRANCH activityDef ) root_2 = self._adaptor.nil() root_2 = self._adaptor.becomeRoot(self._adaptor.createFromType(BRANCH, "BRANCH"), root_2) self._adaptor.addChild(root_2, stream_activityDef.nextTree()) self._adaptor.addChild(root_1, root_2) stream_activityDef.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "unorderedDef" class expr_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.expr_return, self).__init__() self.tree = None # $ANTLR start "expr" # src/SavedFSM/Monitor.g:144:1: expr : term ( ( PLUS | MINUS ) term )* ; def expr(self, ): retval = self.expr_return() retval.start = self.input.LT(1) root_0 = None set174 = None term173 = None term175 = None set174_tree = None try: try: # src/SavedFSM/Monitor.g:144:6: ( term ( ( PLUS | MINUS ) term )* ) # src/SavedFSM/Monitor.g:144:8: term ( ( PLUS | MINUS ) term )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_term_in_expr1359) term173 = self.term() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, term173.tree) # src/SavedFSM/Monitor.g:144:13: ( ( PLUS | MINUS ) term )* while True: #loop46 alt46 = 2 LA46_0 = self.input.LA(1) if ((PLUS <= LA46_0 <= MINUS)) : alt46 = 1 if alt46 == 1: # src/SavedFSM/Monitor.g:144:15: ( PLUS | MINUS ) term pass set174 = self.input.LT(1) if (PLUS <= self.input.LA(1) <= MINUS): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set174)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_term_in_expr1374) term175 = self.term() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, term175.tree) else: break #loop46 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "expr" class term_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.term_return, self).__init__() self.tree = None # $ANTLR start "term" # src/SavedFSM/Monitor.g:146:1: term : factor ( ( MULT | DIV ) factor )* ; def term(self, ): retval = self.term_return() retval.start = self.input.LT(1) root_0 = None set177 = None factor176 = None factor178 = None set177_tree = None try: try: # src/SavedFSM/Monitor.g:146:6: ( factor ( ( MULT | DIV ) factor )* ) # src/SavedFSM/Monitor.g:146:8: factor ( ( MULT | DIV ) factor )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_factor_in_term1386) factor176 = self.factor() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, factor176.tree) # src/SavedFSM/Monitor.g:146:15: ( ( MULT | DIV ) factor )* while True: #loop47 alt47 = 2 LA47_0 = self.input.LA(1) if ((MULT <= LA47_0 <= DIV)) : alt47 = 1 if alt47 == 1: # src/SavedFSM/Monitor.g:146:17: ( MULT | DIV ) factor pass set177 = self.input.LT(1) if (MULT <= self.input.LA(1) <= DIV): self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set177)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_factor_in_term1400) factor178 = self.factor() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, factor178.tree) else: break #loop47 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "term" class factor_return(ParserRuleReturnScope): def __init__(self): super(MonitorParser.factor_return, self).__init__() self.tree = None # $ANTLR start "factor" # src/SavedFSM/Monitor.g:148:1: factor : NUMBER ; def factor(self, ): retval = self.factor_return() retval.start = self.input.LT(1) root_0 = None NUMBER179 = None NUMBER179_tree = None try: try: # src/SavedFSM/Monitor.g:148:8: ( NUMBER ) # src/SavedFSM/Monitor.g:148:10: NUMBER pass root_0 = self._adaptor.nil() NUMBER179=self.match(self.input, NUMBER, self.FOLLOW_NUMBER_in_factor1412) if self._state.backtracking == 0: NUMBER179_tree = self._adaptor.createWithPayload(NUMBER179) self._adaptor.addChild(root_0, NUMBER179_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "factor" # Delegated rules # lookup tables for DFA #3 DFA3_eot = DFA.unpack( u"\4\uffff" ) DFA3_eof = DFA.unpack( u"\4\uffff" ) DFA3_min = DFA.unpack( u"\2\31\2\uffff" ) DFA3_max = DFA.unpack( u"\2\43\2\uffff" ) DFA3_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA3_special = DFA.unpack( u"\4\uffff" ) DFA3_transition = [ DFA.unpack(u"\1\1\10\uffff\1\3\1\2"), DFA.unpack(u"\1\1\10\uffff\1\3\1\2"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #3 class DFA3(DFA): pass # lookup tables for DFA #17 DFA17_eot = DFA.unpack( u"\4\uffff" ) DFA17_eof = DFA.unpack( u"\4\uffff" ) DFA17_min = DFA.unpack( u"\2\22\2\uffff" ) DFA17_max = DFA.unpack( u"\2\75\2\uffff" ) DFA17_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA17_special = DFA.unpack( u"\4\uffff" ) DFA17_transition = [ DFA.unpack(u"\1\3\6\uffff\1\1\1\3\10\uffff\1\2\2\uffff\1\3\2\uffff" u"\1\3\1\2\1\3\4\uffff\2\3\1\uffff\6\3\1\uffff\1\3\2\uffff\1\3"), DFA.unpack(u"\1\3\6\uffff\1\1\1\3\10\uffff\1\2\2\uffff\1\3\2\uffff" u"\1\3\1\uffff\1\3\4\uffff\2\3\1\uffff\6\3\1\uffff\1\3\2\uffff\1" u"\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #17 class DFA17(DFA): pass # lookup tables for DFA #35 DFA35_eot = DFA.unpack( u"\32\uffff" ) DFA35_eof = DFA.unpack( u"\1\1\31\uffff" ) DFA35_min = DFA.unpack( u"\1\22\1\uffff\1\45\1\32\1\uffff\1\32\2\44\1\5\1\32\1\46\1\5\1\32" u"\1\46\6\44\2\5\4\44" ) DFA35_max = DFA.unpack( u"\1\75\1\uffff\1\60\1\32\1\uffff\1\32\2\57\1\6\1\32\1\60\1\6\1\32" u"\1\60\2\54\1\57\2\54\1\57\2\6\4\54" ) DFA35_accept = DFA.unpack( u"\1\uffff\1\2\2\uffff\1\1\25\uffff" ) DFA35_special = DFA.unpack( u"\32\uffff" ) DFA35_transition = [ DFA.unpack(u"\1\4\6\uffff\1\4\1\2\13\uffff\1\4\2\uffff\1\4\1\1\1" u"\3\4\uffff\2\4\1\uffff\6\4\1\uffff\1\4\2\uffff\1\4"), DFA.unpack(u""), DFA.unpack(u"\2\4\4\uffff\1\5\2\uffff\1\4\1\1\1\4"), DFA.unpack(u"\1\6"), DFA.unpack(u""), DFA.unpack(u"\1\7"), DFA.unpack(u"\1\11\7\uffff\1\12\2\uffff\1\10"), DFA.unpack(u"\1\14\7\uffff\1\15\2\uffff\1\13"), DFA.unpack(u"\1\16\1\17"), DFA.unpack(u"\1\20"), DFA.unpack(u"\1\4\10\uffff\1\1\1\4"), DFA.unpack(u"\1\21\1\22"), DFA.unpack(u"\1\23"), DFA.unpack(u"\1\4\10\uffff\1\1\1\4"), DFA.unpack(u"\1\11\7\uffff\1\12"), DFA.unpack(u"\1\11\7\uffff\1\12"), DFA.unpack(u"\1\11\7\uffff\1\12\2\uffff\1\24"), DFA.unpack(u"\1\14\7\uffff\1\15"), DFA.unpack(u"\1\14\7\uffff\1\15"), DFA.unpack(u"\1\14\7\uffff\1\15\2\uffff\1\25"), DFA.unpack(u"\1\26\1\27"), DFA.unpack(u"\1\30\1\31"), DFA.unpack(u"\1\11\7\uffff\1\12"), DFA.unpack(u"\1\11\7\uffff\1\12"), DFA.unpack(u"\1\14\7\uffff\1\15"), DFA.unpack(u"\1\14\7\uffff\1\15") ] # class definition for DFA #35 class DFA35(DFA): pass FOLLOW_ANNOTATION_in_description241 = frozenset([25, 34]) FOLLOW_importProtocolStatement_in_description248 = frozenset([25, 34, 35]) FOLLOW_importTypeStatement_in_description252 = frozenset([25, 34, 35]) FOLLOW_ANNOTATION_in_description261 = frozenset([25, 35]) FOLLOW_protocolDef_in_description266 = frozenset([1]) FOLLOW_34_in_importProtocolStatement277 = frozenset([35]) FOLLOW_35_in_importProtocolStatement279 = frozenset([26]) FOLLOW_importProtocolDef_in_importProtocolStatement281 = frozenset([36, 37]) FOLLOW_36_in_importProtocolStatement285 = frozenset([26]) FOLLOW_importProtocolDef_in_importProtocolStatement288 = frozenset([36, 37]) FOLLOW_37_in_importProtocolStatement293 = frozenset([1]) FOLLOW_ID_in_importProtocolDef302 = frozenset([38]) FOLLOW_38_in_importProtocolDef304 = frozenset([27]) FOLLOW_StringLiteral_in_importProtocolDef307 = frozenset([1]) FOLLOW_34_in_importTypeStatement320 = frozenset([26, 27]) FOLLOW_simpleName_in_importTypeStatement324 = frozenset([26, 27]) FOLLOW_importTypeDef_in_importTypeStatement329 = frozenset([36, 37, 38]) FOLLOW_36_in_importTypeStatement333 = frozenset([26, 27]) FOLLOW_importTypeDef_in_importTypeStatement336 = frozenset([36, 37, 38]) FOLLOW_38_in_importTypeStatement343 = frozenset([27]) FOLLOW_StringLiteral_in_importTypeStatement346 = frozenset([37]) FOLLOW_37_in_importTypeStatement351 = frozenset([1]) FOLLOW_dataTypeDef_in_importTypeDef362 = frozenset([39]) FOLLOW_39_in_importTypeDef364 = frozenset([26]) FOLLOW_ID_in_importTypeDef370 = frozenset([1]) FOLLOW_StringLiteral_in_dataTypeDef378 = frozenset([1]) FOLLOW_ID_in_simpleName386 = frozenset([1]) FOLLOW_35_in_protocolDef394 = frozenset([26]) FOLLOW_protocolName_in_protocolDef396 = frozenset([40, 41, 43]) FOLLOW_40_in_protocolDef400 = frozenset([26]) FOLLOW_roleName_in_protocolDef402 = frozenset([41, 43]) FOLLOW_parameterDefs_in_protocolDef409 = frozenset([41]) FOLLOW_41_in_protocolDef414 = frozenset([18, 25, 26, 38, 41, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_protocolBlockDef_in_protocolDef416 = frozenset([25, 35, 42]) FOLLOW_ANNOTATION_in_protocolDef422 = frozenset([25, 35]) FOLLOW_protocolDef_in_protocolDef427 = frozenset([25, 35, 42]) FOLLOW_42_in_protocolDef432 = frozenset([1]) FOLLOW_ID_in_protocolName460 = frozenset([1]) FOLLOW_43_in_parameterDefs468 = frozenset([45]) FOLLOW_roleparameDef_in_parameterDefs470 = frozenset([36, 44]) FOLLOW_36_in_parameterDefs474 = frozenset([45]) FOLLOW_roleparameDef_in_parameterDefs476 = frozenset([36, 44]) FOLLOW_44_in_parameterDefs481 = frozenset([1]) FOLLOW_45_in_roleparameDef497 = frozenset([26]) FOLLOW_simpleName_in_roleparameDef499 = frozenset([1]) FOLLOW_activityListDef_in_protocolBlockDef510 = frozenset([1]) FOLLOW_41_in_blockDef521 = frozenset([18, 25, 26, 38, 41, 42, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_activityListDef_in_blockDef523 = frozenset([42]) FOLLOW_42_in_blockDef525 = frozenset([1]) FOLLOW_ASSERTION_in_assertDef547 = frozenset([1]) FOLLOW_ANNOTATION_in_activityListDef569 = frozenset([18, 25, 26, 38, 41, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_activityDef_in_activityListDef574 = frozenset([1, 18, 25, 26, 38, 41, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_INT_in_primitivetype590 = frozenset([1]) FOLLOW_STRING_in_primitivetype596 = frozenset([1]) FOLLOW_introducesDef_in_activityDef609 = frozenset([37]) FOLLOW_interactionDef_in_activityDef613 = frozenset([37]) FOLLOW_inlineDef_in_activityDef617 = frozenset([37]) FOLLOW_runDef_in_activityDef621 = frozenset([37]) FOLLOW_recursionDef_in_activityDef625 = frozenset([37]) FOLLOW_endDef_in_activityDef629 = frozenset([37]) FOLLOW_RECLABEL_in_activityDef633 = frozenset([37]) FOLLOW_37_in_activityDef637 = frozenset([1]) FOLLOW_choiceDef_in_activityDef646 = frozenset([1]) FOLLOW_directedChoiceDef_in_activityDef650 = frozenset([1]) FOLLOW_parallelDef_in_activityDef654 = frozenset([1]) FOLLOW_repeatDef_in_activityDef658 = frozenset([1]) FOLLOW_unorderedDef_in_activityDef662 = frozenset([1]) FOLLOW_recBlockDef_in_activityDef669 = frozenset([1]) FOLLOW_globalEscapeDef_in_activityDef673 = frozenset([1]) FOLLOW_roleDef_in_introducesDef681 = frozenset([46]) FOLLOW_46_in_introducesDef683 = frozenset([26]) FOLLOW_roleDef_in_introducesDef685 = frozenset([1, 36]) FOLLOW_36_in_introducesDef689 = frozenset([26]) FOLLOW_roleDef_in_introducesDef691 = frozenset([1, 36]) FOLLOW_ID_in_roleDef702 = frozenset([1]) FOLLOW_ID_in_roleName713 = frozenset([1]) FOLLOW_ID_in_typeReferenceDef724 = frozenset([1]) FOLLOW_typeReferenceDef_in_interactionSignatureDef735 = frozenset([1, 43]) FOLLOW_43_in_interactionSignatureDef738 = frozenset([26]) FOLLOW_valueDecl_in_interactionSignatureDef740 = frozenset([36, 44]) FOLLOW_36_in_interactionSignatureDef743 = frozenset([26]) FOLLOW_valueDecl_in_interactionSignatureDef745 = frozenset([36, 44]) FOLLOW_44_in_interactionSignatureDef749 = frozenset([1]) FOLLOW_43_in_interactionSignatureDef773 = frozenset([26]) FOLLOW_valueDecl_in_interactionSignatureDef775 = frozenset([36, 44]) FOLLOW_36_in_interactionSignatureDef778 = frozenset([26]) FOLLOW_valueDecl_in_interactionSignatureDef780 = frozenset([36, 44]) FOLLOW_44_in_interactionSignatureDef784 = frozenset([1]) FOLLOW_ID_in_valueDecl804 = frozenset([1, 47]) FOLLOW_47_in_valueDecl807 = frozenset([5, 6]) FOLLOW_primitivetype_in_valueDecl810 = frozenset([1]) FOLLOW_valueDecl_in_firstValueDecl821 = frozenset([1]) FOLLOW_interactionSignatureDef_in_interactionDef836 = frozenset([38, 48]) FOLLOW_38_in_interactionDef842 = frozenset([26]) FOLLOW_roleName_in_interactionDef847 = frozenset([28]) FOLLOW_assertDef_in_interactionDef851 = frozenset([1]) FOLLOW_48_in_interactionDef875 = frozenset([26]) FOLLOW_roleName_in_interactionDef877 = frozenset([28]) FOLLOW_assertDef_in_interactionDef881 = frozenset([1]) FOLLOW_49_in_choiceDef902 = frozenset([40, 41]) FOLLOW_40_in_choiceDef906 = frozenset([26]) FOLLOW_roleName_in_choiceDef908 = frozenset([40, 41]) FOLLOW_blockDef_in_choiceDef913 = frozenset([1, 50]) FOLLOW_50_in_choiceDef917 = frozenset([40, 41]) FOLLOW_blockDef_in_choiceDef919 = frozenset([1, 50]) FOLLOW_38_in_directedChoiceDef940 = frozenset([26]) FOLLOW_roleName_in_directedChoiceDef942 = frozenset([41, 48]) FOLLOW_48_in_directedChoiceDef949 = frozenset([26]) FOLLOW_roleName_in_directedChoiceDef951 = frozenset([36, 41]) FOLLOW_36_in_directedChoiceDef955 = frozenset([26]) FOLLOW_roleName_in_directedChoiceDef958 = frozenset([36, 41]) FOLLOW_41_in_directedChoiceDef966 = frozenset([26, 43]) FOLLOW_onMessageDef_in_directedChoiceDef970 = frozenset([26, 42, 43]) FOLLOW_42_in_directedChoiceDef975 = frozenset([1]) FOLLOW_interactionSignatureDef_in_onMessageDef982 = frozenset([47]) FOLLOW_47_in_onMessageDef984 = frozenset([18, 25, 26, 38, 41, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_activityList_in_onMessageDef986 = frozenset([1]) FOLLOW_ANNOTATION_in_activityList999 = frozenset([18, 25, 26, 38, 41, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_activityDef_in_activityList1004 = frozenset([1, 18, 25, 26, 38, 41, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_51_in_repeatDef1014 = frozenset([40, 41]) FOLLOW_40_in_repeatDef1018 = frozenset([26]) FOLLOW_roleName_in_repeatDef1020 = frozenset([36, 40, 41]) FOLLOW_36_in_repeatDef1024 = frozenset([26]) FOLLOW_roleName_in_repeatDef1026 = frozenset([36, 40, 41]) FOLLOW_blockDef_in_repeatDef1034 = frozenset([1]) FOLLOW_52_in_recBlockDef1050 = frozenset([26]) FOLLOW_labelName_in_recBlockDef1052 = frozenset([40, 41]) FOLLOW_blockDef_in_recBlockDef1054 = frozenset([1]) FOLLOW_ID_in_labelName1071 = frozenset([1]) FOLLOW_labelName_in_recursionDef1083 = frozenset([1]) FOLLOW_53_in_endDef1099 = frozenset([1]) FOLLOW_54_in_runDef1109 = frozenset([26]) FOLLOW_protocolRefDef_in_runDef1112 = frozenset([38, 43]) FOLLOW_43_in_runDef1116 = frozenset([26]) FOLLOW_parameter_in_runDef1119 = frozenset([36, 44]) FOLLOW_36_in_runDef1123 = frozenset([26]) FOLLOW_parameter_in_runDef1126 = frozenset([36, 44]) FOLLOW_44_in_runDef1131 = frozenset([38]) FOLLOW_38_in_runDef1137 = frozenset([26]) FOLLOW_roleName_in_runDef1139 = frozenset([1]) FOLLOW_ID_in_protocolRefDef1147 = frozenset([1, 40]) FOLLOW_40_in_protocolRefDef1151 = frozenset([26]) FOLLOW_roleName_in_protocolRefDef1153 = frozenset([1]) FOLLOW_ID_in_declarationName1164 = frozenset([1]) FOLLOW_declarationName_in_parameter1172 = frozenset([1]) FOLLOW_55_in_inlineDef1181 = frozenset([26]) FOLLOW_protocolRefDef_in_inlineDef1184 = frozenset([1, 43]) FOLLOW_43_in_inlineDef1188 = frozenset([26]) FOLLOW_parameter_in_inlineDef1191 = frozenset([36, 44]) FOLLOW_36_in_inlineDef1195 = frozenset([26]) FOLLOW_parameter_in_inlineDef1198 = frozenset([36, 44]) FOLLOW_44_in_inlineDef1203 = frozenset([1]) FOLLOW_56_in_parallelDef1215 = frozenset([40, 41]) FOLLOW_blockDef_in_parallelDef1217 = frozenset([1, 57]) FOLLOW_57_in_parallelDef1221 = frozenset([40, 41]) FOLLOW_blockDef_in_parallelDef1223 = frozenset([1, 57]) FOLLOW_58_in_doBlockDef1243 = frozenset([41]) FOLLOW_41_in_doBlockDef1245 = frozenset([18, 25, 26, 38, 41, 42, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_activityListDef_in_doBlockDef1247 = frozenset([42]) FOLLOW_42_in_doBlockDef1250 = frozenset([1]) FOLLOW_59_in_interruptDef1268 = frozenset([60]) FOLLOW_60_in_interruptDef1270 = frozenset([26]) FOLLOW_roleName_in_interruptDef1272 = frozenset([41]) FOLLOW_41_in_interruptDef1274 = frozenset([18, 25, 26, 38, 41, 42, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_activityListDef_in_interruptDef1276 = frozenset([42]) FOLLOW_42_in_interruptDef1278 = frozenset([1]) FOLLOW_doBlockDef_in_globalEscapeDef1296 = frozenset([59]) FOLLOW_interruptDef_in_globalEscapeDef1299 = frozenset([1]) FOLLOW_61_in_unorderedDef1316 = frozenset([41]) FOLLOW_41_in_unorderedDef1318 = frozenset([18, 25, 26, 38, 41, 42, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_ANNOTATION_in_unorderedDef1324 = frozenset([18, 25, 26, 38, 41, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_activityDef_in_unorderedDef1329 = frozenset([18, 25, 26, 38, 41, 42, 43, 48, 49, 51, 52, 53, 54, 55, 56, 58, 61]) FOLLOW_42_in_unorderedDef1334 = frozenset([1]) FOLLOW_term_in_expr1359 = frozenset([1, 7, 8]) FOLLOW_set_in_expr1363 = frozenset([29]) FOLLOW_term_in_expr1374 = frozenset([1, 7, 8]) FOLLOW_factor_in_term1386 = frozenset([1, 9, 10]) FOLLOW_set_in_term1390 = frozenset([29]) FOLLOW_factor_in_term1400 = frozenset([1, 9, 10]) FOLLOW_NUMBER_in_factor1412 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("MonitorLexer", MonitorParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ooici/pyon", "path": "pyon/core/governance/conversation/parsing/MonitorParser.py", "copies": "1", "size": "206450", "license": "bsd-2-clause", "hash": 7800116038872353000, "line_mean": 34.5519200964, "line_max": 256, "alpha_frac": 0.5232840882, "autogenerated": false, "ratio": 4.014272103288028, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5037556191488028, "avg_score": null, "num_lines": null }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 src/SavedFSM/Monitor.g 2012-03-12 22:09:37 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types RESV=12 ANNOTATION=25 ASSERTION=28 PARALLEL=19 T__61=61 ID=26 T__60=60 EOF=-1 PROTOCOL=20 TYPE=14 T__55=55 INTERACTION=4 T__56=56 ML_COMMENT=32 T__57=57 T__58=58 ROLES=24 T__51=51 T__52=52 T__53=53 T__54=54 T__59=59 FULLSTOP=11 PLUS=7 SEND=13 DIGIT=30 T__50=50 T__42=42 T__43=43 T__40=40 T__41=41 T__46=46 T__47=47 T__44=44 T__45=45 LINE_COMMENT=33 T__48=48 T__49=49 RECLABEL=18 NUMBER=29 WHITESPACE=31 INT=5 VALUE=15 MULT=9 MINUS=8 ASSERT=21 UNORDERED=17 EMPTY=23 StringLiteral=27 T__34=34 GLOBAL_ESCAPE=22 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 BRANCH=16 DIV=10 STRING=6 class MonitorLexer(Lexer): grammarFileName = "src/SavedFSM/Monitor.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(MonitorLexer, self).__init__(input, state) self.dfa9 = self.DFA9( self, 9, eot = self.DFA9_eot, eof = self.DFA9_eof, min = self.DFA9_min, max = self.DFA9_max, accept = self.DFA9_accept, special = self.DFA9_special, transition = self.DFA9_transition ) # $ANTLR start "INTERACTION" def mINTERACTION(self, ): try: _type = INTERACTION _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:7:13: ( 'interaction' ) # src/SavedFSM/Monitor.g:7:15: 'interaction' pass self.match("interaction") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INTERACTION" # $ANTLR start "INT" def mINT(self, ): try: _type = INT _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:8:5: ( 'int' ) # src/SavedFSM/Monitor.g:8:7: 'int' pass self.match("int") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INT" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:9:8: ( 'string' ) # src/SavedFSM/Monitor.g:9:10: 'string' pass self.match("string") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "PLUS" def mPLUS(self, ): try: _type = PLUS _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:10:6: ( '+' ) # src/SavedFSM/Monitor.g:10:8: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUS" # $ANTLR start "MINUS" def mMINUS(self, ): try: _type = MINUS _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:11:7: ( '-' ) # src/SavedFSM/Monitor.g:11:9: '-' pass self.match(45) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MINUS" # $ANTLR start "MULT" def mMULT(self, ): try: _type = MULT _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:12:6: ( '*' ) # src/SavedFSM/Monitor.g:12:8: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MULT" # $ANTLR start "DIV" def mDIV(self, ): try: _type = DIV _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:13:5: ( '/' ) # src/SavedFSM/Monitor.g:13:7: '/' pass self.match(47) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DIV" # $ANTLR start "FULLSTOP" def mFULLSTOP(self, ): try: _type = FULLSTOP _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:14:10: ( '.' ) # src/SavedFSM/Monitor.g:14:12: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FULLSTOP" # $ANTLR start "RESV" def mRESV(self, ): try: _type = RESV _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:15:6: ( 'RESV' ) # src/SavedFSM/Monitor.g:15:8: 'RESV' pass self.match("RESV") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RESV" # $ANTLR start "SEND" def mSEND(self, ): try: _type = SEND _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:16:6: ( 'SEND' ) # src/SavedFSM/Monitor.g:16:8: 'SEND' pass self.match("SEND") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SEND" # $ANTLR start "TYPE" def mTYPE(self, ): try: _type = TYPE _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:17:6: ( 'TYPE' ) # src/SavedFSM/Monitor.g:17:8: 'TYPE' pass self.match("TYPE") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "TYPE" # $ANTLR start "VALUE" def mVALUE(self, ): try: _type = VALUE _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:18:7: ( 'VALUE' ) # src/SavedFSM/Monitor.g:18:9: 'VALUE' pass self.match("VALUE") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "VALUE" # $ANTLR start "BRANCH" def mBRANCH(self, ): try: _type = BRANCH _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:19:8: ( 'BRANCH' ) # src/SavedFSM/Monitor.g:19:10: 'BRANCH' pass self.match("BRANCH") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BRANCH" # $ANTLR start "UNORDERED" def mUNORDERED(self, ): try: _type = UNORDERED _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:20:11: ( 'UNORDERED' ) # src/SavedFSM/Monitor.g:20:13: 'UNORDERED' pass self.match("UNORDERED") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "UNORDERED" # $ANTLR start "RECLABEL" def mRECLABEL(self, ): try: _type = RECLABEL _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:21:10: ( 'RECLABEL' ) # src/SavedFSM/Monitor.g:21:12: 'RECLABEL' pass self.match("RECLABEL") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RECLABEL" # $ANTLR start "PARALLEL" def mPARALLEL(self, ): try: _type = PARALLEL _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:22:10: ( 'PARALLEL' ) # src/SavedFSM/Monitor.g:22:12: 'PARALLEL' pass self.match("PARALLEL") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PARALLEL" # $ANTLR start "PROTOCOL" def mPROTOCOL(self, ): try: _type = PROTOCOL _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:23:10: ( 'PROTOCOL' ) # src/SavedFSM/Monitor.g:23:12: 'PROTOCOL' pass self.match("PROTOCOL") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PROTOCOL" # $ANTLR start "ASSERT" def mASSERT(self, ): try: _type = ASSERT _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:24:8: ( 'ASSERT' ) # src/SavedFSM/Monitor.g:24:10: 'ASSERT' pass self.match("ASSERT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ASSERT" # $ANTLR start "GLOBAL_ESCAPE" def mGLOBAL_ESCAPE(self, ): try: _type = GLOBAL_ESCAPE _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:25:15: ( 'GLOBAL_ESCAPE' ) # src/SavedFSM/Monitor.g:25:17: 'GLOBAL_ESCAPE' pass self.match("GLOBAL_ESCAPE") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "GLOBAL_ESCAPE" # $ANTLR start "EMPTY" def mEMPTY(self, ): try: _type = EMPTY _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:26:7: ( 'EMPTY' ) # src/SavedFSM/Monitor.g:26:9: 'EMPTY' pass self.match("EMPTY") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EMPTY" # $ANTLR start "ROLES" def mROLES(self, ): try: _type = ROLES _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:27:7: ( 'ROLES' ) # src/SavedFSM/Monitor.g:27:9: 'ROLES' pass self.match("ROLES") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ROLES" # $ANTLR start "T__34" def mT__34(self, ): try: _type = T__34 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:28:7: ( 'import' ) # src/SavedFSM/Monitor.g:28:9: 'import' pass self.match("import") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__34" # $ANTLR start "T__35" def mT__35(self, ): try: _type = T__35 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:29:7: ( 'protocol' ) # src/SavedFSM/Monitor.g:29:9: 'protocol' pass self.match("protocol") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__35" # $ANTLR start "T__36" def mT__36(self, ): try: _type = T__36 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:30:7: ( ',' ) # src/SavedFSM/Monitor.g:30:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__36" # $ANTLR start "T__37" def mT__37(self, ): try: _type = T__37 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:31:7: ( ';' ) # src/SavedFSM/Monitor.g:31:9: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__37" # $ANTLR start "T__38" def mT__38(self, ): try: _type = T__38 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:32:7: ( 'from' ) # src/SavedFSM/Monitor.g:32:9: 'from' pass self.match("from") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__38" # $ANTLR start "T__39" def mT__39(self, ): try: _type = T__39 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:33:7: ( 'as' ) # src/SavedFSM/Monitor.g:33:9: 'as' pass self.match("as") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__39" # $ANTLR start "T__40" def mT__40(self, ): try: _type = T__40 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:34:7: ( 'at' ) # src/SavedFSM/Monitor.g:34:9: 'at' pass self.match("at") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__40" # $ANTLR start "T__41" def mT__41(self, ): try: _type = T__41 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:35:7: ( '{' ) # src/SavedFSM/Monitor.g:35:9: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__41" # $ANTLR start "T__42" def mT__42(self, ): try: _type = T__42 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:36:7: ( '}' ) # src/SavedFSM/Monitor.g:36:9: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__42" # $ANTLR start "T__43" def mT__43(self, ): try: _type = T__43 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:37:7: ( '(' ) # src/SavedFSM/Monitor.g:37:9: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__43" # $ANTLR start "T__44" def mT__44(self, ): try: _type = T__44 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:38:7: ( ')' ) # src/SavedFSM/Monitor.g:38:9: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__44" # $ANTLR start "T__45" def mT__45(self, ): try: _type = T__45 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:39:7: ( 'role' ) # src/SavedFSM/Monitor.g:39:9: 'role' pass self.match("role") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__45" # $ANTLR start "T__46" def mT__46(self, ): try: _type = T__46 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:40:7: ( 'introduces' ) # src/SavedFSM/Monitor.g:40:9: 'introduces' pass self.match("introduces") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__46" # $ANTLR start "T__47" def mT__47(self, ): try: _type = T__47 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:41:7: ( ':' ) # src/SavedFSM/Monitor.g:41:9: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__47" # $ANTLR start "T__48" def mT__48(self, ): try: _type = T__48 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:42:7: ( 'to' ) # src/SavedFSM/Monitor.g:42:9: 'to' pass self.match("to") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__48" # $ANTLR start "T__49" def mT__49(self, ): try: _type = T__49 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:43:7: ( 'choice' ) # src/SavedFSM/Monitor.g:43:9: 'choice' pass self.match("choice") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__49" # $ANTLR start "T__50" def mT__50(self, ): try: _type = T__50 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:44:7: ( 'or' ) # src/SavedFSM/Monitor.g:44:9: 'or' pass self.match("or") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__50" # $ANTLR start "T__51" def mT__51(self, ): try: _type = T__51 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:45:7: ( 'repeat' ) # src/SavedFSM/Monitor.g:45:9: 'repeat' pass self.match("repeat") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__51" # $ANTLR start "T__52" def mT__52(self, ): try: _type = T__52 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:46:7: ( 'rec' ) # src/SavedFSM/Monitor.g:46:9: 'rec' pass self.match("rec") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__52" # $ANTLR start "T__53" def mT__53(self, ): try: _type = T__53 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:47:7: ( 'end' ) # src/SavedFSM/Monitor.g:47:9: 'end' pass self.match("end") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__53" # $ANTLR start "T__54" def mT__54(self, ): try: _type = T__54 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:48:7: ( 'run' ) # src/SavedFSM/Monitor.g:48:9: 'run' pass self.match("run") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__54" # $ANTLR start "T__55" def mT__55(self, ): try: _type = T__55 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:49:7: ( 'inline' ) # src/SavedFSM/Monitor.g:49:9: 'inline' pass self.match("inline") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__55" # $ANTLR start "T__56" def mT__56(self, ): try: _type = T__56 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:50:7: ( 'parallel' ) # src/SavedFSM/Monitor.g:50:9: 'parallel' pass self.match("parallel") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__56" # $ANTLR start "T__57" def mT__57(self, ): try: _type = T__57 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:51:7: ( 'and' ) # src/SavedFSM/Monitor.g:51:9: 'and' pass self.match("and") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__57" # $ANTLR start "T__58" def mT__58(self, ): try: _type = T__58 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:52:7: ( 'do' ) # src/SavedFSM/Monitor.g:52:9: 'do' pass self.match("do") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__58" # $ANTLR start "T__59" def mT__59(self, ): try: _type = T__59 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:53:7: ( 'interrupt' ) # src/SavedFSM/Monitor.g:53:9: 'interrupt' pass self.match("interrupt") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__59" # $ANTLR start "T__60" def mT__60(self, ): try: _type = T__60 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:54:7: ( 'by' ) # src/SavedFSM/Monitor.g:54:9: 'by' pass self.match("by") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__60" # $ANTLR start "T__61" def mT__61(self, ): try: _type = T__61 _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:55:7: ( 'unordered' ) # src/SavedFSM/Monitor.g:55:9: 'unordered' pass self.match("unordered") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__61" # $ANTLR start "ID" def mID(self, ): try: _type = ID _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:156:4: ( ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )* ) # src/SavedFSM/Monitor.g:156:6: ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )* pass if (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # src/SavedFSM/Monitor.g:156:29: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((48 <= LA1_0 <= 57) or (65 <= LA1_0 <= 90) or LA1_0 == 95 or (97 <= LA1_0 <= 122)) : alt1 = 1 if alt1 == 1: # src/SavedFSM/Monitor.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ID" # $ANTLR start "NUMBER" def mNUMBER(self, ): try: _type = NUMBER _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:158:8: ( ( DIGIT )+ ) # src/SavedFSM/Monitor.g:158:10: ( DIGIT )+ pass # src/SavedFSM/Monitor.g:158:10: ( DIGIT )+ cnt2 = 0 while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((48 <= LA2_0 <= 57)) : alt2 = 1 if alt2 == 1: # src/SavedFSM/Monitor.g:158:11: DIGIT pass self.mDIGIT() else: if cnt2 >= 1: break #loop2 eee = EarlyExitException(2, self.input) raise eee cnt2 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NUMBER" # $ANTLR start "WHITESPACE" def mWHITESPACE(self, ): try: _type = WHITESPACE _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:160:12: ( ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+ ) # src/SavedFSM/Monitor.g:160:14: ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+ pass # src/SavedFSM/Monitor.g:160:14: ( '\\t' | ' ' | '\\r' | '\\n' | '\\u000C' )+ cnt3 = 0 while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if ((9 <= LA3_0 <= 10) or (12 <= LA3_0 <= 13) or LA3_0 == 32) : alt3 = 1 if alt3 == 1: # src/SavedFSM/Monitor.g: pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt3 >= 1: break #loop3 eee = EarlyExitException(3, self.input) raise eee cnt3 += 1 #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WHITESPACE" # $ANTLR start "DIGIT" def mDIGIT(self, ): try: # src/SavedFSM/Monitor.g:162:16: ( '0' .. '9' ) # src/SavedFSM/Monitor.g:162:18: '0' .. '9' pass self.matchRange(48, 57) finally: pass # $ANTLR end "DIGIT" # $ANTLR start "ASSERTION" def mASSERTION(self, ): try: _type = ASSERTION _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:164:11: ( '@{' ( options {greedy=false; } : . )* '}' ) # src/SavedFSM/Monitor.g:164:13: '@{' ( options {greedy=false; } : . )* '}' pass self.match("@{") # src/SavedFSM/Monitor.g:164:18: ( options {greedy=false; } : . )* while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 125) : alt4 = 2 elif ((0 <= LA4_0 <= 124) or (126 <= LA4_0 <= 65535)) : alt4 = 1 if alt4 == 1: # src/SavedFSM/Monitor.g:164:45: . pass self.matchAny() else: break #loop4 self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ASSERTION" # $ANTLR start "ANNOTATION" def mANNOTATION(self, ): try: _type = ANNOTATION _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:166:12: ( '[[' ( options {greedy=false; } : . )* ']]' ) # src/SavedFSM/Monitor.g:166:14: '[[' ( options {greedy=false; } : . )* ']]' pass self.match("[[") # src/SavedFSM/Monitor.g:166:19: ( options {greedy=false; } : . )* while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == 93) : LA5_1 = self.input.LA(2) if (LA5_1 == 93) : alt5 = 2 elif ((0 <= LA5_1 <= 92) or (94 <= LA5_1 <= 65535)) : alt5 = 1 elif ((0 <= LA5_0 <= 92) or (94 <= LA5_0 <= 65535)) : alt5 = 1 if alt5 == 1: # src/SavedFSM/Monitor.g:166:46: . pass self.matchAny() else: break #loop5 self.match("]]") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ANNOTATION" # $ANTLR start "ML_COMMENT" def mML_COMMENT(self, ): try: _type = ML_COMMENT _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:169:5: ( '/*' ( options {greedy=false; } : . )* '*/' ) # src/SavedFSM/Monitor.g:169:9: '/*' ( options {greedy=false; } : . )* '*/' pass self.match("/*") # src/SavedFSM/Monitor.g:169:14: ( options {greedy=false; } : . )* while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == 42) : LA6_1 = self.input.LA(2) if (LA6_1 == 47) : alt6 = 2 elif ((0 <= LA6_1 <= 46) or (48 <= LA6_1 <= 65535)) : alt6 = 1 elif ((0 <= LA6_0 <= 41) or (43 <= LA6_0 <= 65535)) : alt6 = 1 if alt6 == 1: # src/SavedFSM/Monitor.g:169:41: . pass self.matchAny() else: break #loop6 self.match("*/") #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ML_COMMENT" # $ANTLR start "LINE_COMMENT" def mLINE_COMMENT(self, ): try: _type = LINE_COMMENT _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:172:14: ( '//' ( options {greedy=false; } : . )* '\\n' ) # src/SavedFSM/Monitor.g:172:16: '//' ( options {greedy=false; } : . )* '\\n' pass self.match("//") # src/SavedFSM/Monitor.g:172:21: ( options {greedy=false; } : . )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 10) : alt7 = 2 elif ((0 <= LA7_0 <= 9) or (11 <= LA7_0 <= 65535)) : alt7 = 1 if alt7 == 1: # src/SavedFSM/Monitor.g:172:48: . pass self.matchAny() else: break #loop7 self.match(10) #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LINE_COMMENT" # $ANTLR start "StringLiteral" def mStringLiteral(self, ): try: _type = StringLiteral _channel = DEFAULT_CHANNEL # src/SavedFSM/Monitor.g:174:14: ( '\"' (~ ( '\\\\' | '\"' ) )* '\"' ) # src/SavedFSM/Monitor.g:174:16: '\"' (~ ( '\\\\' | '\"' ) )* '\"' pass self.match(34) # src/SavedFSM/Monitor.g:174:20: (~ ( '\\\\' | '\"' ) )* while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if ((0 <= LA8_0 <= 33) or (35 <= LA8_0 <= 91) or (93 <= LA8_0 <= 65535)) : alt8 = 1 if alt8 == 1: # src/SavedFSM/Monitor.g:174:22: ~ ( '\\\\' | '\"' ) pass if (0 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop8 self.match(34) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "StringLiteral" def mTokens(self): # src/SavedFSM/Monitor.g:1:8: ( INTERACTION | INT | STRING | PLUS | MINUS | MULT | DIV | FULLSTOP | RESV | SEND | TYPE | VALUE | BRANCH | UNORDERED | RECLABEL | PARALLEL | PROTOCOL | ASSERT | GLOBAL_ESCAPE | EMPTY | ROLES | T__34 | T__35 | T__36 | T__37 | T__38 | T__39 | T__40 | T__41 | T__42 | T__43 | T__44 | T__45 | T__46 | T__47 | T__48 | T__49 | T__50 | T__51 | T__52 | T__53 | T__54 | T__55 | T__56 | T__57 | T__58 | T__59 | T__60 | T__61 | ID | NUMBER | WHITESPACE | ASSERTION | ANNOTATION | ML_COMMENT | LINE_COMMENT | StringLiteral ) alt9 = 57 alt9 = self.dfa9.predict(self.input) if alt9 == 1: # src/SavedFSM/Monitor.g:1:10: INTERACTION pass self.mINTERACTION() elif alt9 == 2: # src/SavedFSM/Monitor.g:1:22: INT pass self.mINT() elif alt9 == 3: # src/SavedFSM/Monitor.g:1:26: STRING pass self.mSTRING() elif alt9 == 4: # src/SavedFSM/Monitor.g:1:33: PLUS pass self.mPLUS() elif alt9 == 5: # src/SavedFSM/Monitor.g:1:38: MINUS pass self.mMINUS() elif alt9 == 6: # src/SavedFSM/Monitor.g:1:44: MULT pass self.mMULT() elif alt9 == 7: # src/SavedFSM/Monitor.g:1:49: DIV pass self.mDIV() elif alt9 == 8: # src/SavedFSM/Monitor.g:1:53: FULLSTOP pass self.mFULLSTOP() elif alt9 == 9: # src/SavedFSM/Monitor.g:1:62: RESV pass self.mRESV() elif alt9 == 10: # src/SavedFSM/Monitor.g:1:67: SEND pass self.mSEND() elif alt9 == 11: # src/SavedFSM/Monitor.g:1:72: TYPE pass self.mTYPE() elif alt9 == 12: # src/SavedFSM/Monitor.g:1:77: VALUE pass self.mVALUE() elif alt9 == 13: # src/SavedFSM/Monitor.g:1:83: BRANCH pass self.mBRANCH() elif alt9 == 14: # src/SavedFSM/Monitor.g:1:90: UNORDERED pass self.mUNORDERED() elif alt9 == 15: # src/SavedFSM/Monitor.g:1:100: RECLABEL pass self.mRECLABEL() elif alt9 == 16: # src/SavedFSM/Monitor.g:1:109: PARALLEL pass self.mPARALLEL() elif alt9 == 17: # src/SavedFSM/Monitor.g:1:118: PROTOCOL pass self.mPROTOCOL() elif alt9 == 18: # src/SavedFSM/Monitor.g:1:127: ASSERT pass self.mASSERT() elif alt9 == 19: # src/SavedFSM/Monitor.g:1:134: GLOBAL_ESCAPE pass self.mGLOBAL_ESCAPE() elif alt9 == 20: # src/SavedFSM/Monitor.g:1:148: EMPTY pass self.mEMPTY() elif alt9 == 21: # src/SavedFSM/Monitor.g:1:154: ROLES pass self.mROLES() elif alt9 == 22: # src/SavedFSM/Monitor.g:1:160: T__34 pass self.mT__34() elif alt9 == 23: # src/SavedFSM/Monitor.g:1:166: T__35 pass self.mT__35() elif alt9 == 24: # src/SavedFSM/Monitor.g:1:172: T__36 pass self.mT__36() elif alt9 == 25: # src/SavedFSM/Monitor.g:1:178: T__37 pass self.mT__37() elif alt9 == 26: # src/SavedFSM/Monitor.g:1:184: T__38 pass self.mT__38() elif alt9 == 27: # src/SavedFSM/Monitor.g:1:190: T__39 pass self.mT__39() elif alt9 == 28: # src/SavedFSM/Monitor.g:1:196: T__40 pass self.mT__40() elif alt9 == 29: # src/SavedFSM/Monitor.g:1:202: T__41 pass self.mT__41() elif alt9 == 30: # src/SavedFSM/Monitor.g:1:208: T__42 pass self.mT__42() elif alt9 == 31: # src/SavedFSM/Monitor.g:1:214: T__43 pass self.mT__43() elif alt9 == 32: # src/SavedFSM/Monitor.g:1:220: T__44 pass self.mT__44() elif alt9 == 33: # src/SavedFSM/Monitor.g:1:226: T__45 pass self.mT__45() elif alt9 == 34: # src/SavedFSM/Monitor.g:1:232: T__46 pass self.mT__46() elif alt9 == 35: # src/SavedFSM/Monitor.g:1:238: T__47 pass self.mT__47() elif alt9 == 36: # src/SavedFSM/Monitor.g:1:244: T__48 pass self.mT__48() elif alt9 == 37: # src/SavedFSM/Monitor.g:1:250: T__49 pass self.mT__49() elif alt9 == 38: # src/SavedFSM/Monitor.g:1:256: T__50 pass self.mT__50() elif alt9 == 39: # src/SavedFSM/Monitor.g:1:262: T__51 pass self.mT__51() elif alt9 == 40: # src/SavedFSM/Monitor.g:1:268: T__52 pass self.mT__52() elif alt9 == 41: # src/SavedFSM/Monitor.g:1:274: T__53 pass self.mT__53() elif alt9 == 42: # src/SavedFSM/Monitor.g:1:280: T__54 pass self.mT__54() elif alt9 == 43: # src/SavedFSM/Monitor.g:1:286: T__55 pass self.mT__55() elif alt9 == 44: # src/SavedFSM/Monitor.g:1:292: T__56 pass self.mT__56() elif alt9 == 45: # src/SavedFSM/Monitor.g:1:298: T__57 pass self.mT__57() elif alt9 == 46: # src/SavedFSM/Monitor.g:1:304: T__58 pass self.mT__58() elif alt9 == 47: # src/SavedFSM/Monitor.g:1:310: T__59 pass self.mT__59() elif alt9 == 48: # src/SavedFSM/Monitor.g:1:316: T__60 pass self.mT__60() elif alt9 == 49: # src/SavedFSM/Monitor.g:1:322: T__61 pass self.mT__61() elif alt9 == 50: # src/SavedFSM/Monitor.g:1:328: ID pass self.mID() elif alt9 == 51: # src/SavedFSM/Monitor.g:1:331: NUMBER pass self.mNUMBER() elif alt9 == 52: # src/SavedFSM/Monitor.g:1:338: WHITESPACE pass self.mWHITESPACE() elif alt9 == 53: # src/SavedFSM/Monitor.g:1:349: ASSERTION pass self.mASSERTION() elif alt9 == 54: # src/SavedFSM/Monitor.g:1:359: ANNOTATION pass self.mANNOTATION() elif alt9 == 55: # src/SavedFSM/Monitor.g:1:370: ML_COMMENT pass self.mML_COMMENT() elif alt9 == 56: # src/SavedFSM/Monitor.g:1:381: LINE_COMMENT pass self.mLINE_COMMENT() elif alt9 == 57: # src/SavedFSM/Monitor.g:1:394: StringLiteral pass self.mStringLiteral() # lookup tables for DFA #9 DFA9_eot = DFA.unpack( u"\1\uffff\2\44\3\uffff\1\57\1\uffff\13\44\2\uffff\2\44\4\uffff\1" u"\44\1\uffff\7\44\6\uffff\3\44\3\uffff\17\44\1\140\1\141\4\44\1" u"\147\1\44\1\151\1\44\1\153\1\154\1\44\1\160\23\44\2\uffff\1\u0084" u"\2\44\1\u0087\1\u0088\1\uffff\1\44\1\uffff\1\u008a\2\uffff\3\44" u"\1\uffff\3\44\1\u0091\2\44\1\u0094\1\u0095\12\44\1\u00a0\1\uffff" u"\1\u00a1\1\44\2\uffff\1\44\1\uffff\6\44\1\uffff\1\44\1\u00ac\2" u"\uffff\1\u00ad\6\44\1\u00b4\2\44\2\uffff\6\44\1\u00bd\1\u00be\1" u"\u00bf\1\44\2\uffff\1\u00c1\3\44\1\u00c5\1\44\1\uffff\2\44\1\u00c9" u"\1\u00ca\4\44\3\uffff\1\44\1\uffff\3\44\1\uffff\3\44\2\uffff\4" u"\44\1\u00da\1\44\1\u00dc\1\u00dd\1\44\1\u00df\1\u00e0\2\44\1\u00e3" u"\1\44\1\uffff\1\u00e5\2\uffff\1\44\2\uffff\1\u00e7\1\44\1\uffff" u"\1\u00e9\1\uffff\1\44\1\uffff\1\u00eb\1\uffff\1\44\1\uffff\1\44" u"\1\u00ee\1\uffff" ) DFA9_eof = DFA.unpack( u"\u00ef\uffff" ) DFA9_min = DFA.unpack( u"\1\11\1\155\1\164\3\uffff\1\52\1\uffff\2\105\1\131\1\101\1\122" u"\1\116\1\101\1\123\1\114\1\115\1\141\2\uffff\1\162\1\156\4\uffff" u"\1\145\1\uffff\1\157\1\150\1\162\1\156\1\157\1\171\1\156\6\uffff" u"\1\154\1\160\1\162\3\uffff\1\103\1\114\1\116\1\120\1\114\1\101" u"\1\117\1\122\1\117\1\123\1\117\1\120\1\157\1\162\1\157\2\60\1\144" u"\1\154\1\143\1\156\1\60\1\157\1\60\1\144\2\60\1\157\1\60\1\151" u"\1\157\1\151\1\126\1\114\1\105\1\104\1\105\1\125\1\116\1\122\1" u"\101\1\124\1\105\1\102\1\124\1\164\1\141\1\155\2\uffff\1\60\2\145" u"\2\60\1\uffff\1\151\1\uffff\1\60\2\uffff\2\162\1\157\1\uffff\1" u"\156\1\162\1\156\1\60\1\101\1\123\2\60\1\105\1\103\1\104\1\114" u"\1\117\1\122\1\101\1\131\1\157\1\154\1\60\1\uffff\1\60\1\141\2" u"\uffff\1\143\1\uffff\1\144\1\141\1\144\1\145\1\164\1\147\1\uffff" u"\1\102\1\60\2\uffff\1\60\1\110\1\105\1\114\1\103\1\124\1\114\1" u"\60\1\143\1\154\2\uffff\1\164\2\145\1\143\2\165\3\60\1\105\2\uffff" u"\1\60\1\122\1\105\1\117\1\60\1\137\1\uffff\1\157\1\145\2\60\1\162" u"\1\164\1\160\1\143\3\uffff\1\114\1\uffff\1\105\2\114\1\uffff\1" u"\105\2\154\2\uffff\1\145\1\151\1\164\1\145\1\60\1\104\2\60\1\123" u"\2\60\1\144\1\157\1\60\1\163\1\uffff\1\60\2\uffff\1\103\2\uffff" u"\1\60\1\156\1\uffff\1\60\1\uffff\1\101\1\uffff\1\60\1\uffff\1\120" u"\1\uffff\1\105\1\60\1\uffff" ) DFA9_max = DFA.unpack( u"\1\175\1\156\1\164\3\uffff\1\57\1\uffff\1\117\1\105\1\131\1\101" u"\1\122\1\116\1\122\1\123\1\114\1\115\1\162\2\uffff\1\162\1\164" u"\4\uffff\1\165\1\uffff\1\157\1\150\1\162\1\156\1\157\1\171\1\156" u"\6\uffff\1\164\1\160\1\162\3\uffff\1\123\1\114\1\116\1\120\1\114" u"\1\101\1\117\1\122\1\117\1\123\1\117\1\120\1\157\1\162\1\157\2" u"\172\1\144\1\154\1\160\1\156\1\172\1\157\1\172\1\144\2\172\1\157" u"\1\172\1\151\1\157\1\151\1\126\1\114\1\105\1\104\1\105\1\125\1" u"\116\1\122\1\101\1\124\1\105\1\102\1\124\1\164\1\141\1\155\2\uffff" u"\1\172\2\145\2\172\1\uffff\1\151\1\uffff\1\172\2\uffff\2\162\1" u"\157\1\uffff\1\156\1\162\1\156\1\172\1\101\1\123\2\172\1\105\1" u"\103\1\104\1\114\1\117\1\122\1\101\1\131\1\157\1\154\1\172\1\uffff" u"\1\172\1\141\2\uffff\1\143\1\uffff\1\144\1\162\1\144\1\145\1\164" u"\1\147\1\uffff\1\102\1\172\2\uffff\1\172\1\110\1\105\1\114\1\103" u"\1\124\1\114\1\172\1\143\1\154\2\uffff\1\164\2\145\1\143\2\165" u"\3\172\1\105\2\uffff\1\172\1\122\1\105\1\117\1\172\1\137\1\uffff" u"\1\157\1\145\2\172\1\162\1\164\1\160\1\143\3\uffff\1\114\1\uffff" u"\1\105\2\114\1\uffff\1\105\2\154\2\uffff\1\145\1\151\1\164\1\145" u"\1\172\1\104\2\172\1\123\2\172\1\144\1\157\1\172\1\163\1\uffff" u"\1\172\2\uffff\1\103\2\uffff\1\172\1\156\1\uffff\1\172\1\uffff" u"\1\101\1\uffff\1\172\1\uffff\1\120\1\uffff\1\105\1\172\1\uffff" ) DFA9_accept = DFA.unpack( u"\3\uffff\1\4\1\5\1\6\1\uffff\1\10\13\uffff\1\30\1\31\2\uffff\1" u"\35\1\36\1\37\1\40\1\uffff\1\43\7\uffff\1\62\1\63\1\64\1\65\1\66" u"\1\71\3\uffff\1\67\1\70\1\7\60\uffff\1\33\1\34\5\uffff\1\44\1\uffff" u"\1\46\1\uffff\1\56\1\60\3\uffff\1\2\23\uffff\1\55\2\uffff\1\50" u"\1\52\1\uffff\1\51\6\uffff\1\11\2\uffff\1\12\1\13\12\uffff\1\32" u"\1\41\12\uffff\1\25\1\14\6\uffff\1\24\10\uffff\1\53\1\26\1\3\1" u"\uffff\1\15\3\uffff\1\22\3\uffff\1\47\1\45\17\uffff\1\17\1\uffff" u"\1\20\1\21\1\uffff\1\27\1\54\2\uffff\1\57\1\uffff\1\16\1\uffff" u"\1\61\1\uffff\1\42\1\uffff\1\1\2\uffff\1\23" ) DFA9_special = DFA.unpack( u"\u00ef\uffff" ) DFA9_transition = [ DFA.unpack(u"\2\46\1\uffff\2\46\22\uffff\1\46\1\uffff\1\51\5\uffff" u"\1\31\1\32\1\5\1\3\1\23\1\4\1\7\1\6\12\45\1\34\1\24\4\uffff\1\47" u"\1\17\1\14\2\44\1\21\1\44\1\20\10\44\1\16\1\44\1\10\1\11\1\12\1" u"\15\1\13\4\44\1\50\3\uffff\1\44\1\uffff\1\26\1\42\1\36\1\41\1\40" u"\1\25\2\44\1\1\5\44\1\37\1\22\1\44\1\33\1\2\1\35\1\43\5\44\1\27" u"\1\uffff\1\30"), DFA.unpack(u"\1\53\1\52"), DFA.unpack(u"\1\54"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\55\4\uffff\1\56"), DFA.unpack(u""), DFA.unpack(u"\1\60\11\uffff\1\61"), DFA.unpack(u"\1\62"), DFA.unpack(u"\1\63"), DFA.unpack(u"\1\64"), DFA.unpack(u"\1\65"), DFA.unpack(u"\1\66"), DFA.unpack(u"\1\67\20\uffff\1\70"), DFA.unpack(u"\1\71"), DFA.unpack(u"\1\72"), DFA.unpack(u"\1\73"), DFA.unpack(u"\1\75\20\uffff\1\74"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76"), DFA.unpack(u"\1\101\4\uffff\1\77\1\100"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\103\11\uffff\1\102\5\uffff\1\104"), DFA.unpack(u""), DFA.unpack(u"\1\105"), DFA.unpack(u"\1\106"), DFA.unpack(u"\1\107"), DFA.unpack(u"\1\110"), DFA.unpack(u"\1\111"), DFA.unpack(u"\1\112"), DFA.unpack(u"\1\113"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\115\7\uffff\1\114"), DFA.unpack(u"\1\116"), DFA.unpack(u"\1\117"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\121\17\uffff\1\120"), DFA.unpack(u"\1\122"), DFA.unpack(u"\1\123"), DFA.unpack(u"\1\124"), DFA.unpack(u"\1\125"), DFA.unpack(u"\1\126"), DFA.unpack(u"\1\127"), DFA.unpack(u"\1\130"), DFA.unpack(u"\1\131"), DFA.unpack(u"\1\132"), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134"), DFA.unpack(u"\1\135"), DFA.unpack(u"\1\136"), DFA.unpack(u"\1\137"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\142"), DFA.unpack(u"\1\143"), DFA.unpack(u"\1\145\14\uffff\1\144"), DFA.unpack(u"\1\146"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\150"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\152"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\155"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\4\44\1\156" u"\14\44\1\157\10\44"), DFA.unpack(u"\1\161"), DFA.unpack(u"\1\162"), DFA.unpack(u"\1\163"), DFA.unpack(u"\1\164"), DFA.unpack(u"\1\165"), DFA.unpack(u"\1\166"), DFA.unpack(u"\1\167"), DFA.unpack(u"\1\170"), DFA.unpack(u"\1\171"), DFA.unpack(u"\1\172"), DFA.unpack(u"\1\173"), DFA.unpack(u"\1\174"), DFA.unpack(u"\1\175"), DFA.unpack(u"\1\176"), DFA.unpack(u"\1\177"), DFA.unpack(u"\1\u0080"), DFA.unpack(u"\1\u0081"), DFA.unpack(u"\1\u0082"), DFA.unpack(u"\1\u0083"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u0085"), DFA.unpack(u"\1\u0086"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u"\1\u0089"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u008b"), DFA.unpack(u"\1\u008c"), DFA.unpack(u"\1\u008d"), DFA.unpack(u""), DFA.unpack(u"\1\u008e"), DFA.unpack(u"\1\u008f"), DFA.unpack(u"\1\u0090"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u0092"), DFA.unpack(u"\1\u0093"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u0096"), DFA.unpack(u"\1\u0097"), DFA.unpack(u"\1\u0098"), DFA.unpack(u"\1\u0099"), DFA.unpack(u"\1\u009a"), DFA.unpack(u"\1\u009b"), DFA.unpack(u"\1\u009c"), DFA.unpack(u"\1\u009d"), DFA.unpack(u"\1\u009e"), DFA.unpack(u"\1\u009f"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00a2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00a3"), DFA.unpack(u""), DFA.unpack(u"\1\u00a4"), DFA.unpack(u"\1\u00a5\20\uffff\1\u00a6"), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\1\u00a8"), DFA.unpack(u"\1\u00a9"), DFA.unpack(u"\1\u00aa"), DFA.unpack(u""), DFA.unpack(u"\1\u00ab"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00ae"), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\1\u00b0"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\1\u00b2"), DFA.unpack(u"\1\u00b3"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00b5"), DFA.unpack(u"\1\u00b6"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00b7"), DFA.unpack(u"\1\u00b8"), DFA.unpack(u"\1\u00b9"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\1\u00bb"), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00c0"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00c2"), DFA.unpack(u"\1\u00c3"), DFA.unpack(u"\1\u00c4"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u""), DFA.unpack(u"\1\u00c7"), DFA.unpack(u"\1\u00c8"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\1\u00cc"), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00cf"), DFA.unpack(u""), DFA.unpack(u"\1\u00d0"), DFA.unpack(u"\1\u00d1"), DFA.unpack(u"\1\u00d2"), DFA.unpack(u""), DFA.unpack(u"\1\u00d3"), DFA.unpack(u"\1\u00d4"), DFA.unpack(u"\1\u00d5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00d6"), DFA.unpack(u"\1\u00d7"), DFA.unpack(u"\1\u00d8"), DFA.unpack(u"\1\u00d9"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00db"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00de"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00e1"), DFA.unpack(u"\1\u00e2"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00e4"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00e6"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00e8"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u"\1\u00ea"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u"\1\u00ec"), DFA.unpack(u""), DFA.unpack(u"\1\u00ed"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"") ] # class definition for DFA #9 class DFA9(DFA): pass def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(MonitorLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ooici/pyon", "path": "pyon/core/governance/conversation/parsing/MonitorLexer.py", "copies": "1", "size": "55966", "license": "bsd-2-clause", "hash": 1544008667884032000, "line_mean": 21.7689178194, "line_max": 551, "alpha_frac": 0.4563663653, "autogenerated": false, "ratio": 2.944339225589226, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.8849529225436741, "avg_score": 0.010235273090497038, "num_lines": 2458 }
# $ANTLR 3.1.3 Mar 18, 2009 10:09:25 treelesscss.g 2012-12-04 00:36:20 import sys from antlr3 import * from antlr3.tree import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types FUNCTION=45 UNICODE_RANGE=67 STAR=44 EOF=-1 MEDIA_SYM=26 LBRACKET=43 INCLUDES=48 RPAREN=33 NAME=75 GREATER=40 ESCAPE=72 DIMENSION=108 STRINGESC=106 NL=109 COMMENT=103 D=80 E=81 F=82 G=83 A=77 B=78 RBRACE=28 C=79 L=88 M=89 NMCHAR=74 IMPORT_SYM=24 N=90 SUBSTRINGMATCH=52 O=91 H=84 I=85 J=86 K=87 NUMBER=55 U=97 T=96 W=99 V=98 Q=93 P=92 S=95 CDO=104 R=94 CDC=105 Y=101 PERCENTAGE=37 URL=76 X=100 Z=102 URI=25 PAGE_SYM=35 WS=107 DASHMATCH=49 EMS=57 N_Less_VarDef=20 N_PseudoFunction=17 N_RuleSet=7 NONASCII=70 N_MediaQuery=5 N_Expr=19 N_Selector=10 LBRACE=27 LPAREN=31 LENGTH=56 IMPORTANT_SYM=53 N_Function=12 TIME=62 KEYFRAMES_SYM=36 COMMA=29 N_StyleSheet=4 IDENT=30 PLUS=39 FREQ=63 RBRACKET=46 DOT=42 VPORTLEN=65 CHARSET_SYM=21 ANGLE=61 REMS=59 HASH=41 HEXCHAR=69 RESOLUTION=64 PREFIXMATCH=50 MINUS=68 N_Pseudo=16 SOLIDUS=54 SEMI=23 N_Empty=14 UNICODE=71 CHS=60 COLON=32 NMSTART=73 N_Declaration=11 OPEQ=47 FONTFACE_SYM=34 N_Term=18 EXS=58 N_Space=15 M_KeyframeSelector=9 N_MediaExpr=6 N_Attrib=13 N_KeyframeBlock=8 SUFFIXMATCH=51 LESS_VARNAME=38 NTH=66 STRING=22 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "N_StyleSheet", "N_MediaQuery", "N_MediaExpr", "N_RuleSet", "N_KeyframeBlock", "M_KeyframeSelector", "N_Selector", "N_Declaration", "N_Function", "N_Attrib", "N_Empty", "N_Space", "N_Pseudo", "N_PseudoFunction", "N_Term", "N_Expr", "N_Less_VarDef", "CHARSET_SYM", "STRING", "SEMI", "IMPORT_SYM", "URI", "MEDIA_SYM", "LBRACE", "RBRACE", "COMMA", "IDENT", "LPAREN", "COLON", "RPAREN", "FONTFACE_SYM", "PAGE_SYM", "KEYFRAMES_SYM", "PERCENTAGE", "LESS_VARNAME", "PLUS", "GREATER", "HASH", "DOT", "LBRACKET", "STAR", "FUNCTION", "RBRACKET", "OPEQ", "INCLUDES", "DASHMATCH", "PREFIXMATCH", "SUFFIXMATCH", "SUBSTRINGMATCH", "IMPORTANT_SYM", "SOLIDUS", "NUMBER", "LENGTH", "EMS", "EXS", "REMS", "CHS", "ANGLE", "TIME", "FREQ", "RESOLUTION", "VPORTLEN", "NTH", "UNICODE_RANGE", "MINUS", "HEXCHAR", "NONASCII", "UNICODE", "ESCAPE", "NMSTART", "NMCHAR", "NAME", "URL", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "COMMENT", "CDO", "CDC", "STRINGESC", "WS", "DIMENSION", "NL" ] class treelesscss(TreeParser): grammarFileName = "treelesscss.g" antlr_version = version_str_to_tuple("3.1.3 Mar 18, 2009 10:09:25") antlr_version_str = "3.1.3 Mar 18, 2009 10:09:25" tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(treelesscss, self).__init__(input, state, *args, **kwargs) self.dfa30 = self.DFA30( self, 30, eot = self.DFA30_eot, eof = self.DFA30_eof, min = self.DFA30_min, max = self.DFA30_max, accept = self.DFA30_accept, special = self.DFA30_special, transition = self.DFA30_transition ) # $ANTLR start "styleSheet" # treelesscss.g:13:1: styleSheet : ^( N_StyleSheet ( charSet )? ( imports )* ( body )* ) ; def styleSheet(self, ): charSet1 = None imports2 = None try: try: # treelesscss.g:14:2: ( ^( N_StyleSheet ( charSet )? ( imports )* ( body )* ) ) # treelesscss.g:14:4: ^( N_StyleSheet ( charSet )? ( imports )* ( body )* ) pass self.match(self.input, N_StyleSheet, self.FOLLOW_N_StyleSheet_in_styleSheet51) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # treelesscss.g:15:3: ( charSet )? alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == CHARSET_SYM) : alt1 = 1 if alt1 == 1: # treelesscss.g:16:5: charSet pass self._state.following.append(self.FOLLOW_charSet_in_styleSheet61) charSet1 = self.charSet() self._state.following.pop() #action start self.writeln(charSet1); #action end # treelesscss.g:18:3: ( imports )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == IMPORT_SYM) : alt2 = 1 if alt2 == 1: # treelesscss.g:19:5: imports pass self._state.following.append(self.FOLLOW_imports_in_styleSheet79) imports2 = self.imports() self._state.following.pop() #action start self.writeln(imports2); #action end else: break #loop2 # treelesscss.g:21:3: ( body )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == N_RuleSet or LA3_0 == MEDIA_SYM or (FONTFACE_SYM <= LA3_0 <= KEYFRAMES_SYM)) : alt3 = 1 if alt3 == 1: # treelesscss.g:21:3: body pass self._state.following.append(self.FOLLOW_body_in_styleSheet91) self.body() self._state.following.pop() else: break #loop3 self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "styleSheet" # $ANTLR start "charSet" # treelesscss.g:27:1: charSet returns [gencode] : ^( CHARSET_SYM STRING ) ; def charSet(self, ): gencode = None STRING3 = None try: try: # treelesscss.g:28:4: ( ^( CHARSET_SYM STRING ) ) # treelesscss.g:28:6: ^( CHARSET_SYM STRING ) pass self.match(self.input, CHARSET_SYM, self.FOLLOW_CHARSET_SYM_in_charSet115) self.match(self.input, DOWN, None) STRING3=self.match(self.input, STRING, self.FOLLOW_STRING_in_charSet117) self.match(self.input, UP, None) #action start gencode = '@charset {0}{1}'.format(STRING3.text, self.EOLSEMI) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "charSet" # $ANTLR start "imports" # treelesscss.g:35:1: imports returns [gencode] : ^( IMPORT_SYM importUrl ( media_query )* ) ; def imports(self, ): gencode = None importUrl4 = None media_query5 = None try: try: # treelesscss.g:36:2: ( ^( IMPORT_SYM importUrl ( media_query )* ) ) # treelesscss.g:36:4: ^( IMPORT_SYM importUrl ( media_query )* ) pass self.match(self.input, IMPORT_SYM, self.FOLLOW_IMPORT_SYM_in_imports144) #action start gencode = '@import ' mqs = list(); #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_importUrl_in_imports152) importUrl4 = self.importUrl() self._state.following.pop() #action start gencode += ((importUrl4 is not None) and [self.input.getTokenStream().toString( self.input.getTreeAdaptor().getTokenStartIndex(importUrl4.start), self.input.getTreeAdaptor().getTokenStopIndex(importUrl4.start) )] or [None])[0]; #action end # treelesscss.g:41:3: ( media_query )* while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == N_MediaQuery) : alt4 = 1 if alt4 == 1: # treelesscss.g:42:5: media_query pass self._state.following.append(self.FOLLOW_media_query_in_imports164) media_query5 = self.media_query() self._state.following.pop() #action start mqs.append(media_query5); #action end else: break #loop4 #action start if len(mqs) > 0: gencode += ' ' + self.LISTCOMA.join(mqs); gencode += self.EOLSEMI ; #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "imports" class importUrl_return(TreeRuleReturnScope): def __init__(self): super(treelesscss.importUrl_return, self).__init__() # $ANTLR start "importUrl" # treelesscss.g:50:1: importUrl : ( STRING | URI ); def importUrl(self, ): retval = self.importUrl_return() retval.start = self.input.LT(1) try: try: # treelesscss.g:51:2: ( STRING | URI ) # treelesscss.g: pass if self.input.LA(1) == STRING or self.input.LA(1) == URI: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "importUrl" # $ANTLR start "body" # treelesscss.g:59:1: body : ( ruleSet | media | page | fontface | keyframes ); def body(self, ): try: try: # treelesscss.g:60:2: ( ruleSet | media | page | fontface | keyframes ) alt5 = 5 LA5 = self.input.LA(1) if LA5 == N_RuleSet: alt5 = 1 elif LA5 == MEDIA_SYM: alt5 = 2 elif LA5 == PAGE_SYM: alt5 = 3 elif LA5 == FONTFACE_SYM: alt5 = 4 elif LA5 == KEYFRAMES_SYM: alt5 = 5 else: nvae = NoViableAltException("", 5, 0, self.input) raise nvae if alt5 == 1: # treelesscss.g:60:4: ruleSet pass self._state.following.append(self.FOLLOW_ruleSet_in_body210) self.ruleSet() self._state.following.pop() elif alt5 == 2: # treelesscss.g:61:4: media pass self._state.following.append(self.FOLLOW_media_in_body216) self.media() self._state.following.pop() elif alt5 == 3: # treelesscss.g:62:4: page pass self._state.following.append(self.FOLLOW_page_in_body223) self.page() self._state.following.pop() elif alt5 == 4: # treelesscss.g:63:4: fontface pass self._state.following.append(self.FOLLOW_fontface_in_body230) self.fontface() self._state.following.pop() elif alt5 == 5: # treelesscss.g:64:4: keyframes pass self._state.following.append(self.FOLLOW_keyframes_in_body236) self.keyframes() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "body" # $ANTLR start "media" # treelesscss.g:72:1: media : ^( MEDIA_SYM ( media_query )* ( body )* ) ; def media(self, ): media_query6 = None try: try: # treelesscss.g:73:2: ( ^( MEDIA_SYM ( media_query )* ( body )* ) ) # treelesscss.g:73:4: ^( MEDIA_SYM ( media_query )* ( body )* ) pass self.match(self.input, MEDIA_SYM, self.FOLLOW_MEDIA_SYM_in_media254) #action start mqs = list(); #action end if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # treelesscss.g:74:3: ( media_query )* while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == N_MediaQuery) : alt6 = 1 if alt6 == 1: # treelesscss.g:75:5: media_query pass self._state.following.append(self.FOLLOW_media_query_in_media267) media_query6 = self.media_query() self._state.following.pop() #action start mqs.append(media_query6); #action end else: break #loop6 #action start mediahead = '@media'; if len(mqs) > 0: mediahead += ' ' + self.LISTCOMA.join(mqs); mediahead += self.EOLLBRACKET; self.writeln(mediahead); self.indent_level += 1 #action end # treelesscss.g:84:3: ( body )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == N_RuleSet or LA7_0 == MEDIA_SYM or (FONTFACE_SYM <= LA7_0 <= KEYFRAMES_SYM)) : alt7 = 1 if alt7 == 1: # treelesscss.g:84:3: body pass self._state.following.append(self.FOLLOW_body_in_media286) self.body() self._state.following.pop() else: break #loop7 #action start self.indent_level -= 1 self.writeln(self.EOLRBRACKET); #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "media" # $ANTLR start "media_query" # treelesscss.g:95:1: media_query returns [gencode] : ^( N_MediaQuery ( media_stmt | media_expr )+ ) ; def media_query(self, ): gencode = None media_stmt7 = None media_expr8 = None try: try: # treelesscss.g:96:2: ( ^( N_MediaQuery ( media_stmt | media_expr )+ ) ) # treelesscss.g:96:4: ^( N_MediaQuery ( media_stmt | media_expr )+ ) pass self.match(self.input, N_MediaQuery, self.FOLLOW_N_MediaQuery_in_media_query314) #action start mq = list(); #action end self.match(self.input, DOWN, None) # treelesscss.g:97:3: ( media_stmt | media_expr )+ cnt8 = 0 while True: #loop8 alt8 = 3 LA8_0 = self.input.LA(1) if (LA8_0 == IDENT) : alt8 = 1 elif (LA8_0 == N_MediaExpr) : alt8 = 2 if alt8 == 1: # treelesscss.g:98:5: media_stmt pass self._state.following.append(self.FOLLOW_media_stmt_in_media_query326) media_stmt7 = self.media_stmt() self._state.following.pop() #action start mq.append(((media_stmt7 is not None) and [self.input.getTokenStream().toString( self.input.getTreeAdaptor().getTokenStartIndex(media_stmt7.start), self.input.getTreeAdaptor().getTokenStopIndex(media_stmt7.start) )] or [None])[0]); #action end elif alt8 == 2: # treelesscss.g:99:5: media_expr pass self._state.following.append(self.FOLLOW_media_expr_in_media_query334) media_expr8 = self.media_expr() self._state.following.pop() #action start mq.append(media_expr8); #action end else: if cnt8 >= 1: break #loop8 eee = EarlyExitException(8, self.input) raise eee cnt8 += 1 self.match(self.input, UP, None) #action start gencode = ' '.join(mq) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "media_query" class media_stmt_return(TreeRuleReturnScope): def __init__(self): super(treelesscss.media_stmt_return, self).__init__() # $ANTLR start "media_stmt" # treelesscss.g:104:1: media_stmt : IDENT ; def media_stmt(self, ): retval = self.media_stmt_return() retval.start = self.input.LT(1) try: try: # treelesscss.g:105:2: ( IDENT ) # treelesscss.g:105:4: IDENT pass self.match(self.input, IDENT, self.FOLLOW_IDENT_in_media_stmt360) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "media_stmt" # $ANTLR start "media_expr" # treelesscss.g:108:1: media_expr returns [gencode] : ^( N_MediaExpr media_stmt ( expr )? ) ; def media_expr(self, ): gencode = None media_stmt9 = None expr10 = None try: try: # treelesscss.g:109:2: ( ^( N_MediaExpr media_stmt ( expr )? ) ) # treelesscss.g:109:4: ^( N_MediaExpr media_stmt ( expr )? ) pass self.match(self.input, N_MediaExpr, self.FOLLOW_N_MediaExpr_in_media_expr376) #action start gencode = '(' #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_media_stmt_in_media_expr383) media_stmt9 = self.media_stmt() self._state.following.pop() #action start gencode += ((media_stmt9 is not None) and [self.input.getTokenStream().toString( self.input.getTreeAdaptor().getTokenStartIndex(media_stmt9.start), self.input.getTreeAdaptor().getTokenStopIndex(media_stmt9.start) )] or [None])[0]; #action end # treelesscss.g:111:3: ( expr )? alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == N_Space or LA9_0 == N_Term or LA9_0 == STRING or LA9_0 == URI or (COMMA <= LA9_0 <= IDENT) or LA9_0 == SOLIDUS or LA9_0 == UNICODE_RANGE) : alt9 = 1 if alt9 == 1: # treelesscss.g:112:5: expr pass self._state.following.append(self.FOLLOW_expr_in_media_expr396) expr10 = self.expr() self._state.following.pop() #action start gencode += ':' + expr10; #action end self.match(self.input, UP, None) #action start gencode += ')'; #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "media_expr" # $ANTLR start "fontface" # treelesscss.g:121:1: fontface : ^( FONTFACE_SYM declarationset ) ; def fontface(self, ): try: try: # treelesscss.g:122:2: ( ^( FONTFACE_SYM declarationset ) ) # treelesscss.g:122:4: ^( FONTFACE_SYM declarationset ) pass self.match(self.input, FONTFACE_SYM, self.FOLLOW_FONTFACE_SYM_in_fontface428) #action start self.writeln('@font-face' + self.EOLLBRACKET); self.indent_level += 1; #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_declarationset_in_fontface438) self.declarationset() self._state.following.pop() #action start self.indent_level -= 1 self.writeln(self.EOLRBRACKET); #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "fontface" # $ANTLR start "page" # treelesscss.g:137:1: page : ^( PAGE_SYM ( pseudoPage )? declarationset ) ; def page(self, ): pseudoPage11 = None try: try: # treelesscss.g:138:2: ( ^( PAGE_SYM ( pseudoPage )? declarationset ) ) # treelesscss.g:138:4: ^( PAGE_SYM ( pseudoPage )? declarationset ) pass self.match(self.input, PAGE_SYM, self.FOLLOW_PAGE_SYM_in_page460) #action start out = '@page'; #action end self.match(self.input, DOWN, None) # treelesscss.g:139:3: ( pseudoPage )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == IDENT) : alt10 = 1 if alt10 == 1: # treelesscss.g:140:5: pseudoPage pass self._state.following.append(self.FOLLOW_pseudoPage_in_page474) pseudoPage11 = self.pseudoPage() self._state.following.pop() #action start out += ' ' + pseudoPage11; #action end #action start self.writeln(out + self.EOLLBRACKET); self.indent_level += 1; #action end self._state.following.append(self.FOLLOW_declarationset_in_page491) self.declarationset() self._state.following.pop() #action start self.indent_level -= 1 self.writeln(self.EOLRBRACKET); #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "page" # $ANTLR start "pseudoPage" # treelesscss.g:153:10: fragment pseudoPage returns [gencode] : IDENT ; def pseudoPage(self, ): gencode = None IDENT12 = None try: try: # treelesscss.g:154:2: ( IDENT ) # treelesscss.g:154:4: IDENT pass IDENT12=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_pseudoPage515) #action start gencode = IDENT12.text #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "pseudoPage" # $ANTLR start "keyframes" # treelesscss.g:161:1: keyframes : ^( KEYFRAMES_SYM IDENT ( keyframes_block )* ) ; def keyframes(self, ): IDENT13 = None try: try: # treelesscss.g:162:2: ( ^( KEYFRAMES_SYM IDENT ( keyframes_block )* ) ) # treelesscss.g:162:4: ^( KEYFRAMES_SYM IDENT ( keyframes_block )* ) pass self.match(self.input, KEYFRAMES_SYM, self.FOLLOW_KEYFRAMES_SYM_in_keyframes535) self.match(self.input, DOWN, None) IDENT13=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_keyframes537) #action start self.writeln('@keyframes ' + IDENT13.text + self.EOLLBRACKET); self.indent_level += 1; #action end # treelesscss.g:167:3: ( keyframes_block )* while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == N_KeyframeBlock) : alt11 = 1 if alt11 == 1: # treelesscss.g:167:3: keyframes_block pass self._state.following.append(self.FOLLOW_keyframes_block_in_keyframes547) self.keyframes_block() self._state.following.pop() else: break #loop11 #action start self.indent_level -= 1 self.writeln(self.EOLRBRACKET); #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "keyframes" # $ANTLR start "keyframes_block" # treelesscss.g:174:1: keyframes_block : ^( N_KeyframeBlock ( keyframe_selector )+ declarationset ) ; def keyframes_block(self, ): keyframe_selector14 = None try: try: # treelesscss.g:175:2: ( ^( N_KeyframeBlock ( keyframe_selector )+ declarationset ) ) # treelesscss.g:175:4: ^( N_KeyframeBlock ( keyframe_selector )+ declarationset ) pass self.match(self.input, N_KeyframeBlock, self.FOLLOW_N_KeyframeBlock_in_keyframes_block567) #action start ks = list(); #action end self.match(self.input, DOWN, None) # treelesscss.g:176:3: ( keyframe_selector )+ cnt12 = 0 while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == M_KeyframeSelector) : alt12 = 1 if alt12 == 1: # treelesscss.g:176:5: keyframe_selector pass self._state.following.append(self.FOLLOW_keyframe_selector_in_keyframes_block576) keyframe_selector14 = self.keyframe_selector() self._state.following.pop() #action start ks.append(keyframe_selector14); #action end else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 #action start self.writeln(self.LISTCOMA.join(ks) + self.EOLLBRACKET); self.indent_level += 1; #action end self._state.following.append(self.FOLLOW_declarationset_in_keyframes_block599) self.declarationset() self._state.following.pop() #action start self.indent_level -= 1 self.writeln(self.EOLRBRACKET); #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "keyframes_block" # $ANTLR start "keyframe_selector" # treelesscss.g:190:1: keyframe_selector returns [gencode] : ^( M_KeyframeSelector ( IDENT | PERCENTAGE ) ) ; def keyframe_selector(self, ): gencode = None IDENT15 = None PERCENTAGE16 = None try: try: # treelesscss.g:191:2: ( ^( M_KeyframeSelector ( IDENT | PERCENTAGE ) ) ) # treelesscss.g:191:4: ^( M_KeyframeSelector ( IDENT | PERCENTAGE ) ) pass self.match(self.input, M_KeyframeSelector, self.FOLLOW_M_KeyframeSelector_in_keyframe_selector622) self.match(self.input, DOWN, None) # treelesscss.g:192:3: ( IDENT | PERCENTAGE ) alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == IDENT) : alt13 = 1 elif (LA13_0 == PERCENTAGE) : alt13 = 2 else: nvae = NoViableAltException("", 13, 0, self.input) raise nvae if alt13 == 1: # treelesscss.g:192:5: IDENT pass IDENT15=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_keyframe_selector628) #action start gencode = IDENT15.text #action end elif alt13 == 2: # treelesscss.g:193:5: PERCENTAGE pass PERCENTAGE16=self.match(self.input, PERCENTAGE, self.FOLLOW_PERCENTAGE_in_keyframe_selector637) #action start gencode = PERCENTAGE16.text #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "keyframe_selector" # $ANTLR start "ruleSet" # treelesscss.g:201:1: ruleSet : ^( N_RuleSet ( selector_list )+ declarationset ) ; def ruleSet(self, ): selector_list17 = None try: try: # treelesscss.g:202:2: ( ^( N_RuleSet ( selector_list )+ declarationset ) ) # treelesscss.g:202:4: ^( N_RuleSet ( selector_list )+ declarationset ) pass self.match(self.input, N_RuleSet, self.FOLLOW_N_RuleSet_in_ruleSet661) #action start sellist = list(); #action end self.match(self.input, DOWN, None) # treelesscss.g:203:3: ( selector_list )+ cnt14 = 0 while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == N_Selector) : alt14 = 1 if alt14 == 1: # treelesscss.g:204:4: selector_list pass self._state.following.append(self.FOLLOW_selector_list_in_ruleSet673) selector_list17 = self.selector_list() self._state.following.pop() #action start sellist.append(selector_list17); #action end else: if cnt14 >= 1: break #loop14 eee = EarlyExitException(14, self.input) raise eee cnt14 += 1 #action start self.writeln(self.LISTCOMA.join(sellist) + self.EOLLBRACKET); self.indent_level += 1; #action end self._state.following.append(self.FOLLOW_declarationset_in_ruleSet691) self.declarationset() self._state.following.pop() #action start self.indent_level -= 1 self.writeln(self.EOLRBRACKET); #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "ruleSet" # $ANTLR start "selector_list" # treelesscss.g:217:1: selector_list returns [gencode] : ^( N_Selector selector ) ; def selector_list(self, ): gencode = None selector18 = None try: try: # treelesscss.g:217:32: ( ^( N_Selector selector ) ) # treelesscss.g:218:2: ^( N_Selector selector ) pass self.match(self.input, N_Selector, self.FOLLOW_N_Selector_in_selector_list713) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_selector_in_selector_list717) selector18 = self.selector() self._state.following.pop() #action start gencode = selector18 #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "selector_list" # $ANTLR start "selector" # treelesscss.g:222:1: selector returns [gencode] : a= simpleSelector ( combinator b= simpleSelector )* ; def selector(self, ): gencode = None a = None b = None combinator19 = None try: try: # treelesscss.g:223:2: (a= simpleSelector ( combinator b= simpleSelector )* ) # treelesscss.g:223:4: a= simpleSelector ( combinator b= simpleSelector )* pass self._state.following.append(self.FOLLOW_simpleSelector_in_selector737) a = self.simpleSelector() self._state.following.pop() #action start gencode = a #action end # treelesscss.g:224:2: ( combinator b= simpleSelector )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == N_Attrib or LA15_0 == N_Pseudo or LA15_0 == IDENT or (PLUS <= LA15_0 <= HASH) or LA15_0 == STAR) : alt15 = 1 if alt15 == 1: # treelesscss.g:225:3: combinator b= simpleSelector pass self._state.following.append(self.FOLLOW_combinator_in_selector746) combinator19 = self.combinator() self._state.following.pop() #action start gencode += combinator19; #action end self._state.following.append(self.FOLLOW_simpleSelector_in_selector754) b = self.simpleSelector() self._state.following.pop() #action start # This code decides if there will be whitespace between selectors or not #TODO: Refactor this (to remove this 'strange construct') if b[:1] == ':': gencode = gencode.rstrip() + b else: gencode += b; #action end else: break #loop15 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "selector" # $ANTLR start "combinator" # treelesscss.g:238:1: combinator returns [gencode] : ( PLUS | GREATER | ); def combinator(self, ): gencode = None PLUS20 = None GREATER21 = None try: try: # treelesscss.g:239:2: ( PLUS | GREATER | ) alt16 = 3 LA16 = self.input.LA(1) if LA16 == PLUS: alt16 = 1 elif LA16 == GREATER: alt16 = 2 elif LA16 == N_Attrib or LA16 == N_Pseudo or LA16 == IDENT or LA16 == HASH or LA16 == STAR: alt16 = 3 else: nvae = NoViableAltException("", 16, 0, self.input) raise nvae if alt16 == 1: # treelesscss.g:239:4: PLUS pass PLUS20=self.match(self.input, PLUS, self.FOLLOW_PLUS_in_combinator779) #action start gencode = PLUS20.text #action end elif alt16 == 2: # treelesscss.g:240:4: GREATER pass GREATER21=self.match(self.input, GREATER, self.FOLLOW_GREATER_in_combinator788) #action start gencode = GREATER21.text #action end elif alt16 == 3: # treelesscss.g:241:6: pass #action start gencode = ' ' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "combinator" # $ANTLR start "simpleSelector" # treelesscss.g:244:1: simpleSelector returns [gencode] : ( IDENT | STAR | HASH | pseudo | attrib ); def simpleSelector(self, ): gencode = None IDENT22 = None STAR23 = None HASH24 = None pseudo25 = None attrib26 = None try: try: # treelesscss.g:245:2: ( IDENT | STAR | HASH | pseudo | attrib ) alt17 = 5 LA17 = self.input.LA(1) if LA17 == IDENT: alt17 = 1 elif LA17 == STAR: alt17 = 2 elif LA17 == HASH: alt17 = 3 elif LA17 == N_Pseudo: alt17 = 4 elif LA17 == N_Attrib: alt17 = 5 else: nvae = NoViableAltException("", 17, 0, self.input) raise nvae if alt17 == 1: # treelesscss.g:245:4: IDENT pass IDENT22=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_simpleSelector813) #action start gencode = IDENT22.text #action end elif alt17 == 2: # treelesscss.g:246:4: STAR pass STAR23=self.match(self.input, STAR, self.FOLLOW_STAR_in_simpleSelector822) #action start gencode = STAR23.text #action end elif alt17 == 3: # treelesscss.g:247:4: HASH pass HASH24=self.match(self.input, HASH, self.FOLLOW_HASH_in_simpleSelector831) #action start gencode = HASH24.text #action end elif alt17 == 4: # treelesscss.g:248:4: pseudo pass self._state.following.append(self.FOLLOW_pseudo_in_simpleSelector840) pseudo25 = self.pseudo() self._state.following.pop() #action start gencode = pseudo25 #action end elif alt17 == 5: # treelesscss.g:249:4: attrib pass self._state.following.append(self.FOLLOW_attrib_in_simpleSelector848) attrib26 = self.attrib() self._state.following.pop() #action start gencode = attrib26 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "simpleSelector" # $ANTLR start "pseudo" # treelesscss.g:252:1: pseudo returns [gencode] : ( ^( N_Pseudo a= COLON (b= COLON )? IDENT ) | ^( N_Pseudo a= COLON (b= COLON )? pseudoFunction ) ); def pseudo(self, ): gencode = None a = None b = None IDENT27 = None pseudoFunction28 = None try: try: # treelesscss.g:253:2: ( ^( N_Pseudo a= COLON (b= COLON )? IDENT ) | ^( N_Pseudo a= COLON (b= COLON )? pseudoFunction ) ) alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == N_Pseudo) : LA20_1 = self.input.LA(2) if (LA20_1 == 2) : LA20_2 = self.input.LA(3) if (LA20_2 == COLON) : LA20 = self.input.LA(4) if LA20 == COLON: LA20_4 = self.input.LA(5) if (LA20_4 == N_PseudoFunction) : alt20 = 2 elif (LA20_4 == IDENT) : alt20 = 1 else: nvae = NoViableAltException("", 20, 4, self.input) raise nvae elif LA20 == N_PseudoFunction: alt20 = 2 elif LA20 == IDENT: alt20 = 1 else: nvae = NoViableAltException("", 20, 3, self.input) raise nvae else: nvae = NoViableAltException("", 20, 2, self.input) raise nvae else: nvae = NoViableAltException("", 20, 1, self.input) raise nvae else: nvae = NoViableAltException("", 20, 0, self.input) raise nvae if alt20 == 1: # treelesscss.g:253:4: ^( N_Pseudo a= COLON (b= COLON )? IDENT ) pass self.match(self.input, N_Pseudo, self.FOLLOW_N_Pseudo_in_pseudo867) self.match(self.input, DOWN, None) a=self.match(self.input, COLON, self.FOLLOW_COLON_in_pseudo873) #action start gencode = a.text #action end # treelesscss.g:255:3: (b= COLON )? alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == COLON) : alt18 = 1 if alt18 == 1: # treelesscss.g:256:5: b= COLON pass b=self.match(self.input, COLON, self.FOLLOW_COLON_in_pseudo888) #action start gencode += b.text; #action end IDENT27=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_pseudo900) #action start gencode += IDENT27.text; #action end self.match(self.input, UP, None) elif alt20 == 2: # treelesscss.g:260:4: ^( N_Pseudo a= COLON (b= COLON )? pseudoFunction ) pass self.match(self.input, N_Pseudo, self.FOLLOW_N_Pseudo_in_pseudo912) self.match(self.input, DOWN, None) a=self.match(self.input, COLON, self.FOLLOW_COLON_in_pseudo918) #action start gencode = a.text #action end # treelesscss.g:262:3: (b= COLON )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == COLON) : alt19 = 1 if alt19 == 1: # treelesscss.g:263:5: b= COLON pass b=self.match(self.input, COLON, self.FOLLOW_COLON_in_pseudo933) #action start gencode += b.text; #action end self._state.following.append(self.FOLLOW_pseudoFunction_in_pseudo945) pseudoFunction28 = self.pseudoFunction() self._state.following.pop() #action start gencode += pseudoFunction28; #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "pseudo" # $ANTLR start "pseudoFunction" # treelesscss.g:268:1: pseudoFunction returns [gencode] : ( ^( N_PseudoFunction FUNCTION expr ) | ^( N_PseudoFunction FUNCTION LBRACKET attribBody RBRACKET ) | ^( N_PseudoFunction FUNCTION pseudo ) ); def pseudoFunction(self, ): gencode = None FUNCTION29 = None FUNCTION31 = None FUNCTION33 = None expr30 = None attribBody32 = None pseudo34 = None try: try: # treelesscss.g:269:2: ( ^( N_PseudoFunction FUNCTION expr ) | ^( N_PseudoFunction FUNCTION LBRACKET attribBody RBRACKET ) | ^( N_PseudoFunction FUNCTION pseudo ) ) alt21 = 3 LA21_0 = self.input.LA(1) if (LA21_0 == N_PseudoFunction) : LA21_1 = self.input.LA(2) if (LA21_1 == 2) : LA21_2 = self.input.LA(3) if (LA21_2 == FUNCTION) : LA21 = self.input.LA(4) if LA21 == LBRACKET: alt21 = 2 elif LA21 == N_Pseudo: alt21 = 3 elif LA21 == N_Space or LA21 == N_Term or LA21 == STRING or LA21 == URI or LA21 == COMMA or LA21 == IDENT or LA21 == SOLIDUS or LA21 == UNICODE_RANGE: alt21 = 1 else: nvae = NoViableAltException("", 21, 3, self.input) raise nvae else: nvae = NoViableAltException("", 21, 2, self.input) raise nvae else: nvae = NoViableAltException("", 21, 1, self.input) raise nvae else: nvae = NoViableAltException("", 21, 0, self.input) raise nvae if alt21 == 1: # treelesscss.g:269:4: ^( N_PseudoFunction FUNCTION expr ) pass self.match(self.input, N_PseudoFunction, self.FOLLOW_N_PseudoFunction_in_pseudoFunction964) self.match(self.input, DOWN, None) FUNCTION29=self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_pseudoFunction968) self._state.following.append(self.FOLLOW_expr_in_pseudoFunction972) expr30 = self.expr() self._state.following.pop() #action start gencode = FUNCTION29.text + expr30 + ')' #action end self.match(self.input, UP, None) elif alt21 == 2: # treelesscss.g:273:4: ^( N_PseudoFunction FUNCTION LBRACKET attribBody RBRACKET ) pass self.match(self.input, N_PseudoFunction, self.FOLLOW_N_PseudoFunction_in_pseudoFunction985) self.match(self.input, DOWN, None) FUNCTION31=self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_pseudoFunction989) self.match(self.input, LBRACKET, self.FOLLOW_LBRACKET_in_pseudoFunction991) self._state.following.append(self.FOLLOW_attribBody_in_pseudoFunction995) attribBody32 = self.attribBody() self._state.following.pop() self.match(self.input, RBRACKET, self.FOLLOW_RBRACKET_in_pseudoFunction999) #action start gencode = FUNCTION31.text + '[' + attribBody32 + '])' #action end self.match(self.input, UP, None) elif alt21 == 3: # treelesscss.g:278:4: ^( N_PseudoFunction FUNCTION pseudo ) pass self.match(self.input, N_PseudoFunction, self.FOLLOW_N_PseudoFunction_in_pseudoFunction1010) self.match(self.input, DOWN, None) FUNCTION33=self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_pseudoFunction1014) self._state.following.append(self.FOLLOW_pseudo_in_pseudoFunction1018) pseudo34 = self.pseudo() self._state.following.pop() #action start gencode = FUNCTION33.text + pseudo34 + ')' #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "pseudoFunction" # $ANTLR start "attrib" # treelesscss.g:283:1: attrib returns [gencode] : ^( N_Attrib attribBody ) ; def attrib(self, ): gencode = None attribBody35 = None try: try: # treelesscss.g:284:2: ( ^( N_Attrib attribBody ) ) # treelesscss.g:284:4: ^( N_Attrib attribBody ) pass self.match(self.input, N_Attrib, self.FOLLOW_N_Attrib_in_attrib1038) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_attribBody_in_attrib1042) attribBody35 = self.attribBody() self._state.following.pop() #action start gencode = '[' + attribBody35 + ']' #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "attrib" # $ANTLR start "attribBody" # treelesscss.g:288:1: attribBody returns [gencode] : ( IDENT | ^( attribOper IDENT term ) ); def attribBody(self, ): gencode = None IDENT36 = None IDENT37 = None attribOper38 = None term39 = None try: try: # treelesscss.g:289:2: ( IDENT | ^( attribOper IDENT term ) ) alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == IDENT) : alt22 = 1 elif ((OPEQ <= LA22_0 <= SUBSTRINGMATCH)) : alt22 = 2 else: nvae = NoViableAltException("", 22, 0, self.input) raise nvae if alt22 == 1: # treelesscss.g:289:4: IDENT pass IDENT36=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_attribBody1060) #action start gencode = IDENT36.text #action end elif alt22 == 2: # treelesscss.g:290:4: ^( attribOper IDENT term ) pass self._state.following.append(self.FOLLOW_attribOper_in_attribBody1070) attribOper38 = self.attribOper() self._state.following.pop() self.match(self.input, DOWN, None) IDENT37=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_attribBody1074) self._state.following.append(self.FOLLOW_term_in_attribBody1078) term39 = self.term() self._state.following.pop() #action start gencode = IDENT37.text + attribOper38 + term39 #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "attribBody" # $ANTLR start "attribOper" # treelesscss.g:295:10: fragment attribOper returns [gencode] : ( OPEQ | INCLUDES | DASHMATCH | PREFIXMATCH | SUFFIXMATCH | SUBSTRINGMATCH ); def attribOper(self, ): gencode = None OPEQ40 = None INCLUDES41 = None DASHMATCH42 = None PREFIXMATCH43 = None SUFFIXMATCH44 = None SUBSTRINGMATCH45 = None try: try: # treelesscss.g:296:2: ( OPEQ | INCLUDES | DASHMATCH | PREFIXMATCH | SUFFIXMATCH | SUBSTRINGMATCH ) alt23 = 6 LA23 = self.input.LA(1) if LA23 == OPEQ: alt23 = 1 elif LA23 == INCLUDES: alt23 = 2 elif LA23 == DASHMATCH: alt23 = 3 elif LA23 == PREFIXMATCH: alt23 = 4 elif LA23 == SUFFIXMATCH: alt23 = 5 elif LA23 == SUBSTRINGMATCH: alt23 = 6 else: nvae = NoViableAltException("", 23, 0, self.input) raise nvae if alt23 == 1: # treelesscss.g:296:4: OPEQ pass OPEQ40=self.match(self.input, OPEQ, self.FOLLOW_OPEQ_in_attribOper1100) #action start gencode = OPEQ40.text #action end elif alt23 == 2: # treelesscss.g:297:4: INCLUDES pass INCLUDES41=self.match(self.input, INCLUDES, self.FOLLOW_INCLUDES_in_attribOper1109) #action start gencode = INCLUDES41.text #action end elif alt23 == 3: # treelesscss.g:298:4: DASHMATCH pass DASHMATCH42=self.match(self.input, DASHMATCH, self.FOLLOW_DASHMATCH_in_attribOper1117) #action start gencode = DASHMATCH42.text #action end elif alt23 == 4: # treelesscss.g:299:4: PREFIXMATCH pass PREFIXMATCH43=self.match(self.input, PREFIXMATCH, self.FOLLOW_PREFIXMATCH_in_attribOper1125) #action start gencode = PREFIXMATCH43.text #action end elif alt23 == 5: # treelesscss.g:300:4: SUFFIXMATCH pass SUFFIXMATCH44=self.match(self.input, SUFFIXMATCH, self.FOLLOW_SUFFIXMATCH_in_attribOper1133) #action start gencode = SUFFIXMATCH44.text #action end elif alt23 == 6: # treelesscss.g:301:4: SUBSTRINGMATCH pass SUBSTRINGMATCH45=self.match(self.input, SUBSTRINGMATCH, self.FOLLOW_SUBSTRINGMATCH_in_attribOper1141) #action start gencode = SUBSTRINGMATCH45.text #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "attribOper" # $ANTLR start "declarationset" # treelesscss.g:307:1: declarationset : ( N_Empty | ( declaration )+ ); def declarationset(self, ): try: try: # treelesscss.g:308:2: ( N_Empty | ( declaration )+ ) alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == N_Empty) : alt25 = 1 elif (LA25_0 == N_Declaration) : alt25 = 2 else: nvae = NoViableAltException("", 25, 0, self.input) raise nvae if alt25 == 1: # treelesscss.g:308:4: N_Empty pass self.match(self.input, N_Empty, self.FOLLOW_N_Empty_in_declarationset1157) elif alt25 == 2: # treelesscss.g:309:4: ( declaration )+ pass # treelesscss.g:309:4: ( declaration )+ cnt24 = 0 while True: #loop24 alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == N_Declaration) : alt24 = 1 if alt24 == 1: # treelesscss.g:309:4: declaration pass self._state.following.append(self.FOLLOW_declaration_in_declarationset1162) self.declaration() self._state.following.pop() else: if cnt24 >= 1: break #loop24 eee = EarlyExitException(24, self.input) raise eee cnt24 += 1 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "declarationset" # $ANTLR start "declaration" # treelesscss.g:313:1: declaration : ^( N_Declaration property ( expr )? ( prio )? ) ; def declaration(self, ): property46 = None expr47 = None try: try: # treelesscss.g:314:2: ( ^( N_Declaration property ( expr )? ( prio )? ) ) # treelesscss.g:314:4: ^( N_Declaration property ( expr )? ( prio )? ) pass self.match(self.input, N_Declaration, self.FOLLOW_N_Declaration_in_declaration1176) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_property_in_declaration1180) property46 = self.property() self._state.following.pop() #action start propout = property46 + ":"; #action end # treelesscss.g:316:3: ( expr )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == N_Space or LA26_0 == N_Term or LA26_0 == STRING or LA26_0 == URI or (COMMA <= LA26_0 <= IDENT) or LA26_0 == SOLIDUS or LA26_0 == UNICODE_RANGE) : alt26 = 1 if alt26 == 1: # treelesscss.g:317:5: expr pass self._state.following.append(self.FOLLOW_expr_in_declaration1193) expr47 = self.expr() self._state.following.pop() #action start propout += expr47 #action end # treelesscss.g:319:3: ( prio )? alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == IMPORTANT_SYM) : alt27 = 1 if alt27 == 1: # treelesscss.g:320:5: prio pass self._state.following.append(self.FOLLOW_prio_in_declaration1211) self.prio() self._state.following.pop() #action start propout += ' !important' #action end #action start #TODO: Remove last semicolon in the declarationset (how?) ... self.writeln(propout + self.EOLSEMI); #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "declaration" # $ANTLR start "property" # treelesscss.g:328:1: property returns [gencode] : IDENT ; def property(self, ): gencode = None IDENT48 = None try: try: # treelesscss.g:329:2: ( IDENT ) # treelesscss.g:329:4: IDENT pass IDENT48=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_property1241) #action start gencode = IDENT48.text #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "property" # $ANTLR start "prio" # treelesscss.g:332:1: prio : IMPORTANT_SYM ; def prio(self, ): try: try: # treelesscss.g:333:2: ( IMPORTANT_SYM ) # treelesscss.g:333:4: IMPORTANT_SYM pass self.match(self.input, IMPORTANT_SYM, self.FOLLOW_IMPORTANT_SYM_in_prio1256) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "prio" # $ANTLR start "expr" # treelesscss.g:337:1: expr returns [gencode] : ( ^( operator a= expr b= expr ) | term ); def expr(self, ): gencode = None a = None b = None operator49 = None term50 = None try: try: # treelesscss.g:338:2: ( ^( operator a= expr b= expr ) | term ) alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == N_Space or LA28_0 == COMMA or LA28_0 == SOLIDUS) : alt28 = 1 elif (LA28_0 == N_Term or LA28_0 == STRING or LA28_0 == URI or LA28_0 == IDENT or LA28_0 == UNICODE_RANGE) : alt28 = 2 else: nvae = NoViableAltException("", 28, 0, self.input) raise nvae if alt28 == 1: # treelesscss.g:338:4: ^( operator a= expr b= expr ) pass self._state.following.append(self.FOLLOW_operator_in_expr1274) operator49 = self.operator() self._state.following.pop() self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_expr1280) a = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_expr1286) b = self.expr() self._state.following.pop() #action start gencode = a + operator49 + b #action end self.match(self.input, UP, None) elif alt28 == 2: # treelesscss.g:342:4: term pass self._state.following.append(self.FOLLOW_term_in_expr1298) term50 = self.term() self._state.following.pop() #action start gencode = term50 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "expr" # $ANTLR start "operator" # treelesscss.g:345:10: fragment operator returns [gencode] : ( SOLIDUS | COMMA | N_Space ); def operator(self, ): gencode = None SOLIDUS51 = None COMMA52 = None try: try: # treelesscss.g:346:2: ( SOLIDUS | COMMA | N_Space ) alt29 = 3 LA29 = self.input.LA(1) if LA29 == SOLIDUS: alt29 = 1 elif LA29 == COMMA: alt29 = 2 elif LA29 == N_Space: alt29 = 3 else: nvae = NoViableAltException("", 29, 0, self.input) raise nvae if alt29 == 1: # treelesscss.g:346:4: SOLIDUS pass SOLIDUS51=self.match(self.input, SOLIDUS, self.FOLLOW_SOLIDUS_in_operator1319) #action start gencode = SOLIDUS51.text #action end elif alt29 == 2: # treelesscss.g:347:4: COMMA pass COMMA52=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_operator1328) #action start gencode = COMMA52.text #action end elif alt29 == 3: # treelesscss.g:348:4: N_Space pass self.match(self.input, N_Space, self.FOLLOW_N_Space_in_operator1337) #action start gencode = ' ' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "operator" # $ANTLR start "term" # treelesscss.g:351:1: term returns [gencode] : ( ^( N_Term unaryOperator termnum ) | ^( N_Term termnum ) | STRING | IDENT | URI | ^( N_Term hexColor ) | UNICODE_RANGE ); def term(self, ): gencode = None STRING56 = None IDENT57 = None URI58 = None UNICODE_RANGE60 = None unaryOperator53 = None termnum54 = None termnum55 = None hexColor59 = None try: try: # treelesscss.g:352:2: ( ^( N_Term unaryOperator termnum ) | ^( N_Term termnum ) | STRING | IDENT | URI | ^( N_Term hexColor ) | UNICODE_RANGE ) alt30 = 7 alt30 = self.dfa30.predict(self.input) if alt30 == 1: # treelesscss.g:352:4: ^( N_Term unaryOperator termnum ) pass self.match(self.input, N_Term, self.FOLLOW_N_Term_in_term1356) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_unaryOperator_in_term1360) unaryOperator53 = self.unaryOperator() self._state.following.pop() self._state.following.append(self.FOLLOW_termnum_in_term1364) termnum54 = self.termnum() self._state.following.pop() #action start gencode = ((unaryOperator53 is not None) and [self.input.getTokenStream().toString( self.input.getTreeAdaptor().getTokenStartIndex(unaryOperator53.start), self.input.getTreeAdaptor().getTokenStopIndex(unaryOperator53.start) )] or [None])[0] + termnum54 #action end self.match(self.input, UP, None) elif alt30 == 2: # treelesscss.g:356:4: ^( N_Term termnum ) pass self.match(self.input, N_Term, self.FOLLOW_N_Term_in_term1378) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_termnum_in_term1382) termnum55 = self.termnum() self._state.following.pop() #action start gencode = termnum55 #action end self.match(self.input, UP, None) elif alt30 == 3: # treelesscss.g:359:4: STRING pass STRING56=self.match(self.input, STRING, self.FOLLOW_STRING_in_term1396) #action start gencode = STRING56.text #action end elif alt30 == 4: # treelesscss.g:360:4: IDENT pass IDENT57=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_term1404) #action start gencode = IDENT57.text #action end elif alt30 == 5: # treelesscss.g:361:4: URI pass URI58=self.match(self.input, URI, self.FOLLOW_URI_in_term1413) #action start gencode = URI58.text #action end elif alt30 == 6: # treelesscss.g:362:4: ^( N_Term hexColor ) pass self.match(self.input, N_Term, self.FOLLOW_N_Term_in_term1423) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_hexColor_in_term1427) hexColor59 = self.hexColor() self._state.following.pop() #action start gencode = ((hexColor59 is not None) and [self.input.getTokenStream().toString( self.input.getTreeAdaptor().getTokenStartIndex(hexColor59.start), self.input.getTreeAdaptor().getTokenStopIndex(hexColor59.start) )] or [None])[0] #action end self.match(self.input, UP, None) elif alt30 == 7: # treelesscss.g:365:4: UNICODE_RANGE pass UNICODE_RANGE60=self.match(self.input, UNICODE_RANGE, self.FOLLOW_UNICODE_RANGE_in_term1437) #action start gencode = UNICODE_RANGE60.text #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "term" # $ANTLR start "termnum" # treelesscss.g:368:10: fragment termnum returns [gencode] : ( NUMBER | PERCENTAGE | LENGTH | EMS | EXS | REMS | CHS | ANGLE | TIME | FREQ | RESOLUTION | VPORTLEN | NTH | function ); def termnum(self, ): gencode = None NUMBER61 = None PERCENTAGE62 = None LENGTH63 = None EMS64 = None EXS65 = None REMS66 = None CHS67 = None ANGLE68 = None TIME69 = None FREQ70 = None RESOLUTION71 = None VPORTLEN72 = None NTH73 = None function74 = None try: try: # treelesscss.g:369:2: ( NUMBER | PERCENTAGE | LENGTH | EMS | EXS | REMS | CHS | ANGLE | TIME | FREQ | RESOLUTION | VPORTLEN | NTH | function ) alt31 = 14 LA31 = self.input.LA(1) if LA31 == NUMBER: alt31 = 1 elif LA31 == PERCENTAGE: alt31 = 2 elif LA31 == LENGTH: alt31 = 3 elif LA31 == EMS: alt31 = 4 elif LA31 == EXS: alt31 = 5 elif LA31 == REMS: alt31 = 6 elif LA31 == CHS: alt31 = 7 elif LA31 == ANGLE: alt31 = 8 elif LA31 == TIME: alt31 = 9 elif LA31 == FREQ: alt31 = 10 elif LA31 == RESOLUTION: alt31 = 11 elif LA31 == VPORTLEN: alt31 = 12 elif LA31 == NTH: alt31 = 13 elif LA31 == N_Function: alt31 = 14 else: nvae = NoViableAltException("", 31, 0, self.input) raise nvae if alt31 == 1: # treelesscss.g:369:4: NUMBER pass NUMBER61=self.match(self.input, NUMBER, self.FOLLOW_NUMBER_in_termnum1457) #action start gencode = NUMBER61.text.strip() #action end elif alt31 == 2: # treelesscss.g:370:4: PERCENTAGE pass PERCENTAGE62=self.match(self.input, PERCENTAGE, self.FOLLOW_PERCENTAGE_in_termnum1465) #action start gencode = PERCENTAGE62.text.strip() #action end elif alt31 == 3: # treelesscss.g:371:4: LENGTH pass LENGTH63=self.match(self.input, LENGTH, self.FOLLOW_LENGTH_in_termnum1473) #action start gencode = LENGTH63.text.strip() #action end elif alt31 == 4: # treelesscss.g:372:4: EMS pass EMS64=self.match(self.input, EMS, self.FOLLOW_EMS_in_termnum1481) #action start gencode = EMS64.text.strip() #action end elif alt31 == 5: # treelesscss.g:373:4: EXS pass EXS65=self.match(self.input, EXS, self.FOLLOW_EXS_in_termnum1490) #action start gencode = EXS65.text.strip() #action end elif alt31 == 6: # treelesscss.g:374:4: REMS pass REMS66=self.match(self.input, REMS, self.FOLLOW_REMS_in_termnum1499) #action start gencode = REMS66.text.strip() #action end elif alt31 == 7: # treelesscss.g:375:4: CHS pass CHS67=self.match(self.input, CHS, self.FOLLOW_CHS_in_termnum1508) #action start gencode = CHS67.text.strip() #action end elif alt31 == 8: # treelesscss.g:376:4: ANGLE pass ANGLE68=self.match(self.input, ANGLE, self.FOLLOW_ANGLE_in_termnum1517) #action start gencode = ANGLE68.text.strip() #action end elif alt31 == 9: # treelesscss.g:377:4: TIME pass TIME69=self.match(self.input, TIME, self.FOLLOW_TIME_in_termnum1526) #action start gencode = TIME69.text.strip() #action end elif alt31 == 10: # treelesscss.g:378:4: FREQ pass FREQ70=self.match(self.input, FREQ, self.FOLLOW_FREQ_in_termnum1535) #action start gencode = FREQ70.text.strip() #action end elif alt31 == 11: # treelesscss.g:379:4: RESOLUTION pass RESOLUTION71=self.match(self.input, RESOLUTION, self.FOLLOW_RESOLUTION_in_termnum1544) #action start gencode = RESOLUTION71.text.strip() #action end elif alt31 == 12: # treelesscss.g:380:4: VPORTLEN pass VPORTLEN72=self.match(self.input, VPORTLEN, self.FOLLOW_VPORTLEN_in_termnum1552) #action start gencode = VPORTLEN72.text.strip() #action end elif alt31 == 13: # treelesscss.g:381:4: NTH pass NTH73=self.match(self.input, NTH, self.FOLLOW_NTH_in_termnum1560) #action start gencode = NTH73.text.strip() #action end elif alt31 == 14: # treelesscss.g:382:4: function pass self._state.following.append(self.FOLLOW_function_in_termnum1569) function74 = self.function() self._state.following.pop() #action start gencode = function74 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "termnum" class unaryOperator_return(TreeRuleReturnScope): def __init__(self): super(treelesscss.unaryOperator_return, self).__init__() # $ANTLR start "unaryOperator" # treelesscss.g:386:1: unaryOperator : ( MINUS | PLUS ); def unaryOperator(self, ): retval = self.unaryOperator_return() retval.start = self.input.LT(1) try: try: # treelesscss.g:387:2: ( MINUS | PLUS ) # treelesscss.g: pass if self.input.LA(1) == PLUS or self.input.LA(1) == MINUS: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "unaryOperator" # $ANTLR start "function" # treelesscss.g:392:1: function returns [gencode] : ^( N_Function fnct_name fnct_args ) ; def function(self, ): gencode = None fnct_name75 = None fnct_args76 = None try: try: # treelesscss.g:393:2: ( ^( N_Function fnct_name fnct_args ) ) # treelesscss.g:393:4: ^( N_Function fnct_name fnct_args ) pass self.match(self.input, N_Function, self.FOLLOW_N_Function_in_function1607) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_fnct_name_in_function1611) fnct_name75 = self.fnct_name() self._state.following.pop() self._state.following.append(self.FOLLOW_fnct_args_in_function1615) fnct_args76 = self.fnct_args() self._state.following.pop() #action start gencode = fnct_name75 + fnct_args76 + ')' #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "function" # $ANTLR start "fnct_name" # treelesscss.g:399:1: fnct_name returns [gencode] : ^( FUNCTION ( IDENT | COLON | DOT )* ) ; def fnct_name(self, ): gencode = None IDENT77 = None COLON78 = None DOT79 = None FUNCTION80 = None try: try: # treelesscss.g:400:2: ( ^( FUNCTION ( IDENT | COLON | DOT )* ) ) # treelesscss.g:400:4: ^( FUNCTION ( IDENT | COLON | DOT )* ) pass FUNCTION80=self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_fnct_name1636) #action start prefix = list(); #action end if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # treelesscss.g:401:3: ( IDENT | COLON | DOT )* while True: #loop32 alt32 = 4 LA32 = self.input.LA(1) if LA32 == IDENT: alt32 = 1 elif LA32 == COLON: alt32 = 2 elif LA32 == DOT: alt32 = 3 if alt32 == 1: # treelesscss.g:401:5: IDENT pass IDENT77=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_fnct_name1645) #action start prefix.append(IDENT77.text); #action end elif alt32 == 2: # treelesscss.g:402:5: COLON pass COLON78=self.match(self.input, COLON, self.FOLLOW_COLON_in_fnct_name1654) #action start prefix.append(COLON78.text); #action end elif alt32 == 3: # treelesscss.g:403:5: DOT pass DOT79=self.match(self.input, DOT, self.FOLLOW_DOT_in_fnct_name1663) #action start prefix.append(DOT79.text); #action end else: break #loop32 self.match(self.input, UP, None) #action start gencode = ''.join(prefix) + FUNCTION80.text #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "fnct_name" # $ANTLR start "fnct_args" # treelesscss.g:408:10: fragment fnct_args returns [gencode] : ( ^( COMMA a= fnct_args b= fnct_args ) | ^( OPEQ IDENT expr ) | ^( N_Expr expr ) ); def fnct_args(self, ): gencode = None COMMA81 = None IDENT82 = None OPEQ83 = None a = None b = None expr84 = None expr85 = None try: try: # treelesscss.g:409:2: ( ^( COMMA a= fnct_args b= fnct_args ) | ^( OPEQ IDENT expr ) | ^( N_Expr expr ) ) alt33 = 3 LA33 = self.input.LA(1) if LA33 == COMMA: alt33 = 1 elif LA33 == OPEQ: alt33 = 2 elif LA33 == N_Expr: alt33 = 3 else: nvae = NoViableAltException("", 33, 0, self.input) raise nvae if alt33 == 1: # treelesscss.g:409:4: ^( COMMA a= fnct_args b= fnct_args ) pass COMMA81=self.match(self.input, COMMA, self.FOLLOW_COMMA_in_fnct_args1697) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_fnct_args_in_fnct_args1703) a = self.fnct_args() self._state.following.pop() self._state.following.append(self.FOLLOW_fnct_args_in_fnct_args1709) b = self.fnct_args() self._state.following.pop() #action start gencode = a + COMMA81.text + b #action end self.match(self.input, UP, None) elif alt33 == 2: # treelesscss.g:413:4: ^( OPEQ IDENT expr ) pass OPEQ83=self.match(self.input, OPEQ, self.FOLLOW_OPEQ_in_fnct_args1720) self.match(self.input, DOWN, None) IDENT82=self.match(self.input, IDENT, self.FOLLOW_IDENT_in_fnct_args1724) self._state.following.append(self.FOLLOW_expr_in_fnct_args1728) expr84 = self.expr() self._state.following.pop() #action start gencode = IDENT82.text + OPEQ83.text + expr84 #action end self.match(self.input, UP, None) elif alt33 == 3: # treelesscss.g:417:4: ^( N_Expr expr ) pass self.match(self.input, N_Expr, self.FOLLOW_N_Expr_in_fnct_args1741) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_fnct_args1745) expr85 = self.expr() self._state.following.pop() #action start gencode = expr85 #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return gencode # $ANTLR end "fnct_args" class hexColor_return(TreeRuleReturnScope): def __init__(self): super(treelesscss.hexColor_return, self).__init__() # $ANTLR start "hexColor" # treelesscss.g:422:1: hexColor : HASH ; def hexColor(self, ): retval = self.hexColor_return() retval.start = self.input.LT(1) try: try: # treelesscss.g:423:2: ( HASH ) # treelesscss.g:423:4: HASH pass self.match(self.input, HASH, self.FOLLOW_HASH_in_hexColor1762) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "hexColor" # Delegated rules # lookup tables for DFA #30 DFA30_eot = DFA.unpack( u"\12\uffff" ) DFA30_eof = DFA.unpack( u"\12\uffff" ) DFA30_min = DFA.unpack( u"\1\22\1\2\4\uffff\1\14\3\uffff" ) DFA30_max = DFA.unpack( u"\1\103\1\2\4\uffff\1\104\3\uffff" ) DFA30_accept = DFA.unpack( u"\2\uffff\1\3\1\4\1\5\1\7\1\uffff\1\1\1\2\1\6" ) DFA30_special = DFA.unpack( u"\12\uffff" ) DFA30_transition = [ DFA.unpack(u"\1\1\3\uffff\1\2\2\uffff\1\4\4\uffff\1\3\44\uffff\1" u"\5"), DFA.unpack(u"\1\6"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\10\30\uffff\1\10\1\uffff\1\7\1\uffff\1\11\15\uffff" u"\14\10\1\uffff\1\7"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #30 class DFA30(DFA): pass FOLLOW_N_StyleSheet_in_styleSheet51 = frozenset([2]) FOLLOW_charSet_in_styleSheet61 = frozenset([3, 7, 24, 26, 34, 35, 36]) FOLLOW_imports_in_styleSheet79 = frozenset([3, 7, 24, 26, 34, 35, 36]) FOLLOW_body_in_styleSheet91 = frozenset([3, 7, 26, 34, 35, 36]) FOLLOW_CHARSET_SYM_in_charSet115 = frozenset([2]) FOLLOW_STRING_in_charSet117 = frozenset([3]) FOLLOW_IMPORT_SYM_in_imports144 = frozenset([2]) FOLLOW_importUrl_in_imports152 = frozenset([3, 5]) FOLLOW_media_query_in_imports164 = frozenset([3, 5]) FOLLOW_set_in_importUrl0 = frozenset([1]) FOLLOW_ruleSet_in_body210 = frozenset([1]) FOLLOW_media_in_body216 = frozenset([1]) FOLLOW_page_in_body223 = frozenset([1]) FOLLOW_fontface_in_body230 = frozenset([1]) FOLLOW_keyframes_in_body236 = frozenset([1]) FOLLOW_MEDIA_SYM_in_media254 = frozenset([2]) FOLLOW_media_query_in_media267 = frozenset([3, 5, 7, 26, 34, 35, 36]) FOLLOW_body_in_media286 = frozenset([3, 7, 26, 34, 35, 36]) FOLLOW_N_MediaQuery_in_media_query314 = frozenset([2]) FOLLOW_media_stmt_in_media_query326 = frozenset([3, 6, 30]) FOLLOW_media_expr_in_media_query334 = frozenset([3, 6, 30]) FOLLOW_IDENT_in_media_stmt360 = frozenset([1]) FOLLOW_N_MediaExpr_in_media_expr376 = frozenset([2]) FOLLOW_media_stmt_in_media_expr383 = frozenset([3, 15, 18, 22, 25, 29, 30, 54, 67]) FOLLOW_expr_in_media_expr396 = frozenset([3]) FOLLOW_FONTFACE_SYM_in_fontface428 = frozenset([2]) FOLLOW_declarationset_in_fontface438 = frozenset([3]) FOLLOW_PAGE_SYM_in_page460 = frozenset([2]) FOLLOW_pseudoPage_in_page474 = frozenset([11, 14]) FOLLOW_declarationset_in_page491 = frozenset([3]) FOLLOW_IDENT_in_pseudoPage515 = frozenset([1]) FOLLOW_KEYFRAMES_SYM_in_keyframes535 = frozenset([2]) FOLLOW_IDENT_in_keyframes537 = frozenset([3, 8]) FOLLOW_keyframes_block_in_keyframes547 = frozenset([3, 8]) FOLLOW_N_KeyframeBlock_in_keyframes_block567 = frozenset([2]) FOLLOW_keyframe_selector_in_keyframes_block576 = frozenset([9, 11, 14]) FOLLOW_declarationset_in_keyframes_block599 = frozenset([3]) FOLLOW_M_KeyframeSelector_in_keyframe_selector622 = frozenset([2]) FOLLOW_IDENT_in_keyframe_selector628 = frozenset([3]) FOLLOW_PERCENTAGE_in_keyframe_selector637 = frozenset([3]) FOLLOW_N_RuleSet_in_ruleSet661 = frozenset([2]) FOLLOW_selector_list_in_ruleSet673 = frozenset([10, 11, 14]) FOLLOW_declarationset_in_ruleSet691 = frozenset([3]) FOLLOW_N_Selector_in_selector_list713 = frozenset([2]) FOLLOW_selector_in_selector_list717 = frozenset([3]) FOLLOW_simpleSelector_in_selector737 = frozenset([1, 13, 16, 30, 39, 40, 41, 44]) FOLLOW_combinator_in_selector746 = frozenset([13, 16, 30, 39, 40, 41, 44]) FOLLOW_simpleSelector_in_selector754 = frozenset([1, 13, 16, 30, 39, 40, 41, 44]) FOLLOW_PLUS_in_combinator779 = frozenset([1]) FOLLOW_GREATER_in_combinator788 = frozenset([1]) FOLLOW_IDENT_in_simpleSelector813 = frozenset([1]) FOLLOW_STAR_in_simpleSelector822 = frozenset([1]) FOLLOW_HASH_in_simpleSelector831 = frozenset([1]) FOLLOW_pseudo_in_simpleSelector840 = frozenset([1]) FOLLOW_attrib_in_simpleSelector848 = frozenset([1]) FOLLOW_N_Pseudo_in_pseudo867 = frozenset([2]) FOLLOW_COLON_in_pseudo873 = frozenset([30, 32]) FOLLOW_COLON_in_pseudo888 = frozenset([30]) FOLLOW_IDENT_in_pseudo900 = frozenset([3]) FOLLOW_N_Pseudo_in_pseudo912 = frozenset([2]) FOLLOW_COLON_in_pseudo918 = frozenset([17, 32]) FOLLOW_COLON_in_pseudo933 = frozenset([17, 32]) FOLLOW_pseudoFunction_in_pseudo945 = frozenset([3]) FOLLOW_N_PseudoFunction_in_pseudoFunction964 = frozenset([2]) FOLLOW_FUNCTION_in_pseudoFunction968 = frozenset([15, 18, 22, 25, 29, 30, 54, 67]) FOLLOW_expr_in_pseudoFunction972 = frozenset([3]) FOLLOW_N_PseudoFunction_in_pseudoFunction985 = frozenset([2]) FOLLOW_FUNCTION_in_pseudoFunction989 = frozenset([43]) FOLLOW_LBRACKET_in_pseudoFunction991 = frozenset([30, 47, 48, 49, 50, 51, 52]) FOLLOW_attribBody_in_pseudoFunction995 = frozenset([46]) FOLLOW_RBRACKET_in_pseudoFunction999 = frozenset([3]) FOLLOW_N_PseudoFunction_in_pseudoFunction1010 = frozenset([2]) FOLLOW_FUNCTION_in_pseudoFunction1014 = frozenset([16]) FOLLOW_pseudo_in_pseudoFunction1018 = frozenset([3]) FOLLOW_N_Attrib_in_attrib1038 = frozenset([2]) FOLLOW_attribBody_in_attrib1042 = frozenset([3]) FOLLOW_IDENT_in_attribBody1060 = frozenset([1]) FOLLOW_attribOper_in_attribBody1070 = frozenset([2]) FOLLOW_IDENT_in_attribBody1074 = frozenset([15, 18, 22, 25, 29, 30, 54, 67]) FOLLOW_term_in_attribBody1078 = frozenset([3]) FOLLOW_OPEQ_in_attribOper1100 = frozenset([1]) FOLLOW_INCLUDES_in_attribOper1109 = frozenset([1]) FOLLOW_DASHMATCH_in_attribOper1117 = frozenset([1]) FOLLOW_PREFIXMATCH_in_attribOper1125 = frozenset([1]) FOLLOW_SUFFIXMATCH_in_attribOper1133 = frozenset([1]) FOLLOW_SUBSTRINGMATCH_in_attribOper1141 = frozenset([1]) FOLLOW_N_Empty_in_declarationset1157 = frozenset([1]) FOLLOW_declaration_in_declarationset1162 = frozenset([1, 11, 14]) FOLLOW_N_Declaration_in_declaration1176 = frozenset([2]) FOLLOW_property_in_declaration1180 = frozenset([3, 15, 18, 22, 25, 29, 30, 53, 54, 67]) FOLLOW_expr_in_declaration1193 = frozenset([3, 53]) FOLLOW_prio_in_declaration1211 = frozenset([3]) FOLLOW_IDENT_in_property1241 = frozenset([1]) FOLLOW_IMPORTANT_SYM_in_prio1256 = frozenset([1]) FOLLOW_operator_in_expr1274 = frozenset([2]) FOLLOW_expr_in_expr1280 = frozenset([15, 18, 22, 25, 29, 30, 54, 67]) FOLLOW_expr_in_expr1286 = frozenset([3]) FOLLOW_term_in_expr1298 = frozenset([1]) FOLLOW_SOLIDUS_in_operator1319 = frozenset([1]) FOLLOW_COMMA_in_operator1328 = frozenset([1]) FOLLOW_N_Space_in_operator1337 = frozenset([1]) FOLLOW_N_Term_in_term1356 = frozenset([2]) FOLLOW_unaryOperator_in_term1360 = frozenset([12, 37, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66]) FOLLOW_termnum_in_term1364 = frozenset([3]) FOLLOW_N_Term_in_term1378 = frozenset([2]) FOLLOW_termnum_in_term1382 = frozenset([3]) FOLLOW_STRING_in_term1396 = frozenset([1]) FOLLOW_IDENT_in_term1404 = frozenset([1]) FOLLOW_URI_in_term1413 = frozenset([1]) FOLLOW_N_Term_in_term1423 = frozenset([2]) FOLLOW_hexColor_in_term1427 = frozenset([3]) FOLLOW_UNICODE_RANGE_in_term1437 = frozenset([1]) FOLLOW_NUMBER_in_termnum1457 = frozenset([1]) FOLLOW_PERCENTAGE_in_termnum1465 = frozenset([1]) FOLLOW_LENGTH_in_termnum1473 = frozenset([1]) FOLLOW_EMS_in_termnum1481 = frozenset([1]) FOLLOW_EXS_in_termnum1490 = frozenset([1]) FOLLOW_REMS_in_termnum1499 = frozenset([1]) FOLLOW_CHS_in_termnum1508 = frozenset([1]) FOLLOW_ANGLE_in_termnum1517 = frozenset([1]) FOLLOW_TIME_in_termnum1526 = frozenset([1]) FOLLOW_FREQ_in_termnum1535 = frozenset([1]) FOLLOW_RESOLUTION_in_termnum1544 = frozenset([1]) FOLLOW_VPORTLEN_in_termnum1552 = frozenset([1]) FOLLOW_NTH_in_termnum1560 = frozenset([1]) FOLLOW_function_in_termnum1569 = frozenset([1]) FOLLOW_set_in_unaryOperator0 = frozenset([1]) FOLLOW_N_Function_in_function1607 = frozenset([2]) FOLLOW_fnct_name_in_function1611 = frozenset([19, 29, 47]) FOLLOW_fnct_args_in_function1615 = frozenset([3]) FOLLOW_FUNCTION_in_fnct_name1636 = frozenset([2]) FOLLOW_IDENT_in_fnct_name1645 = frozenset([3, 30, 32, 42]) FOLLOW_COLON_in_fnct_name1654 = frozenset([3, 30, 32, 42]) FOLLOW_DOT_in_fnct_name1663 = frozenset([3, 30, 32, 42]) FOLLOW_COMMA_in_fnct_args1697 = frozenset([2]) FOLLOW_fnct_args_in_fnct_args1703 = frozenset([19, 29, 47]) FOLLOW_fnct_args_in_fnct_args1709 = frozenset([3]) FOLLOW_OPEQ_in_fnct_args1720 = frozenset([2]) FOLLOW_IDENT_in_fnct_args1724 = frozenset([15, 18, 22, 25, 29, 30, 54, 67]) FOLLOW_expr_in_fnct_args1728 = frozenset([3]) FOLLOW_N_Expr_in_fnct_args1741 = frozenset([2]) FOLLOW_expr_in_fnct_args1745 = frozenset([3]) FOLLOW_HASH_in_hexColor1762 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import WalkerMain main = WalkerMain(treelesscss) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ateska/pyless", "path": "pyless/treelesscss.py", "copies": "1", "size": "100603", "license": "bsd-2-clause", "hash": -7851616493085189000, "line_mean": 30.214086255, "line_max": 204, "alpha_frac": 0.4702543662, "autogenerated": false, "ratio": 4.016408495688278, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9914746555153044, "avg_score": 0.014383261347046601, "num_lines": 3223 }
# $ANTLR 3.1 Comments.g 2012-10-11 20:28:14 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types RBRACK=14 APOS=39 BSLAHS=36 BACKQUOTE=28 STAR=20 LBRACK=13 EMARK=34 SHARP=35 PERCENT=27 LINE_COMMENT=6 LCURLY=29 MINUS=19 EOF=-1 SEMI=17 Identifier=9 LPAREN=11 AT=38 COLON=15 VBAR=22 QUOTE=40 RPAREN=12 GREATER=25 SLASH=21 WS=4 COMMA=16 AMPER=23 RCURLY=30 TILDE=32 ASSIGN=26 LESS=24 JavaIDDigit=8 PLUS=18 DIGIT=10 DOT=37 COMMENT=5 QMARK=33 Letter=7 CIRCUMFLEX=31 class Comments(Lexer): grammarFileName = "Comments.g" antlr_version = version_str_to_tuple("3.1") antlr_version_str = "3.1" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() Lexer.__init__(self, input, state) self.dfa5 = self.DFA5( self, 5, eot = self.DFA5_eot, eof = self.DFA5_eof, min = self.DFA5_min, max = self.DFA5_max, accept = self.DFA5_accept, special = self.DFA5_special, transition = self.DFA5_transition ) # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # Comments.g:10:5: ( ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) ) # Comments.g:10:8: ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # Comments.g:15:5: ( '/*' ( options {greedy=false; } : . )* '*/' ) # Comments.g:15:9: '/*' ( options {greedy=false; } : . )* '*/' pass self.match("/*") # Comments.g:15:14: ( options {greedy=false; } : . )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == 42) : LA1_1 = self.input.LA(2) if (LA1_1 == 47) : alt1 = 2 elif ((0 <= LA1_1 <= 46) or (48 <= LA1_1 <= 65534)) : alt1 = 1 elif ((0 <= LA1_0 <= 41) or (43 <= LA1_0 <= 65534)) : alt1 = 1 if alt1 == 1: # Comments.g:15:41: . pass self.matchAny() else: break #loop1 self.match("*/") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "LINE_COMMENT" def mLINE_COMMENT(self, ): try: _type = LINE_COMMENT _channel = DEFAULT_CHANNEL # Comments.g:19:5: ( '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) # Comments.g:19:7: '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' pass self.match("//") # Comments.g:19:12: (~ ( '\\n' | '\\r' ) )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((0 <= LA2_0 <= 9) or (11 <= LA2_0 <= 12) or (14 <= LA2_0 <= 65534)) : alt2 = 1 if alt2 == 1: # Comments.g:19:12: ~ ( '\\n' | '\\r' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 65534): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop2 # Comments.g:19:26: ( '\\r' )? alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == 13) : alt3 = 1 if alt3 == 1: # Comments.g:19:26: '\\r' pass self.match(13) self.match(10) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LINE_COMMENT" # $ANTLR start "Identifier" def mIdentifier(self, ): try: _type = Identifier _channel = DEFAULT_CHANNEL # Comments.g:23:5: ( Letter ( Letter | JavaIDDigit )* ) # Comments.g:23:9: Letter ( Letter | JavaIDDigit )* pass self.mLetter() # Comments.g:23:16: ( Letter | JavaIDDigit )* while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 36 or (48 <= LA4_0 <= 57) or (65 <= LA4_0 <= 90) or LA4_0 == 95 or (97 <= LA4_0 <= 122) or (192 <= LA4_0 <= 214) or (216 <= LA4_0 <= 246) or (248 <= LA4_0 <= 8191) or (12352 <= LA4_0 <= 12687) or (13056 <= LA4_0 <= 13183) or (13312 <= LA4_0 <= 15661) or (19968 <= LA4_0 <= 40959) or (63744 <= LA4_0 <= 64255)) : alt4 = 1 if alt4 == 1: # Comments.g: pass if self.input.LA(1) == 36 or (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122) or (192 <= self.input.LA(1) <= 214) or (216 <= self.input.LA(1) <= 246) or (248 <= self.input.LA(1) <= 8191) or (12352 <= self.input.LA(1) <= 12687) or (13056 <= self.input.LA(1) <= 13183) or (13312 <= self.input.LA(1) <= 15661) or (19968 <= self.input.LA(1) <= 40959) or (63744 <= self.input.LA(1) <= 64255): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop4 #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "Identifier" # $ANTLR start "Letter" def mLetter(self, ): try: # Comments.g:31:5: ( '\\u0024' | '\\u0041' .. '\\u005a' | '\\u005f' | '\\u0061' .. '\\u007a' | '\\u00c0' .. '\\u00d6' | '\\u00d8' .. '\\u00f6' | '\\u00f8' .. '\\u00ff' | '\\u0100' .. '\\u1fff' | '\\u3040' .. '\\u318f' | '\\u3300' .. '\\u337f' | '\\u3400' .. '\\u3d2d' | '\\u4e00' .. '\\u9fff' | '\\uf900' .. '\\ufaff' ) # Comments.g: pass if self.input.LA(1) == 36 or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122) or (192 <= self.input.LA(1) <= 214) or (216 <= self.input.LA(1) <= 246) or (248 <= self.input.LA(1) <= 8191) or (12352 <= self.input.LA(1) <= 12687) or (13056 <= self.input.LA(1) <= 13183) or (13312 <= self.input.LA(1) <= 15661) or (19968 <= self.input.LA(1) <= 40959) or (63744 <= self.input.LA(1) <= 64255): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "Letter" # $ANTLR start "JavaIDDigit" def mJavaIDDigit(self, ): try: # Comments.g:48:5: ( '\\u0030' .. '\\u0039' | '\\u0660' .. '\\u0669' | '\\u06f0' .. '\\u06f9' | '\\u0966' .. '\\u096f' | '\\u09e6' .. '\\u09ef' | '\\u0a66' .. '\\u0a6f' | '\\u0ae6' .. '\\u0aef' | '\\u0b66' .. '\\u0b6f' | '\\u0be7' .. '\\u0bef' | '\\u0c66' .. '\\u0c6f' | '\\u0ce6' .. '\\u0cef' | '\\u0d66' .. '\\u0d6f' | '\\u0e50' .. '\\u0e59' | '\\u0ed0' .. '\\u0ed9' | '\\u1040' .. '\\u1049' ) # Comments.g: pass if (48 <= self.input.LA(1) <= 57) or (1632 <= self.input.LA(1) <= 1641) or (1776 <= self.input.LA(1) <= 1785) or (2406 <= self.input.LA(1) <= 2415) or (2534 <= self.input.LA(1) <= 2543) or (2662 <= self.input.LA(1) <= 2671) or (2790 <= self.input.LA(1) <= 2799) or (2918 <= self.input.LA(1) <= 2927) or (3047 <= self.input.LA(1) <= 3055) or (3174 <= self.input.LA(1) <= 3183) or (3302 <= self.input.LA(1) <= 3311) or (3430 <= self.input.LA(1) <= 3439) or (3664 <= self.input.LA(1) <= 3673) or (3792 <= self.input.LA(1) <= 3801) or (4160 <= self.input.LA(1) <= 4169): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "JavaIDDigit" # $ANTLR start "DIGIT" def mDIGIT(self, ): try: _type = DIGIT _channel = DEFAULT_CHANNEL # Comments.g:65:7: ( '0' .. '9' ) # Comments.g:65:9: '0' .. '9' pass self.matchRange(48, 57) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DIGIT" # $ANTLR start "LPAREN" def mLPAREN(self, ): try: _type = LPAREN _channel = DEFAULT_CHANNEL # Comments.g:67:11: ( '(' ) # Comments.g:67:13: '(' pass self.match(40) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LPAREN" # $ANTLR start "RPAREN" def mRPAREN(self, ): try: _type = RPAREN _channel = DEFAULT_CHANNEL # Comments.g:69:11: ( ')' ) # Comments.g:69:13: ')' pass self.match(41) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RPAREN" # $ANTLR start "LBRACK" def mLBRACK(self, ): try: _type = LBRACK _channel = DEFAULT_CHANNEL # Comments.g:71:11: ( '[' ) # Comments.g:71:13: '[' pass self.match(91) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LBRACK" # $ANTLR start "RBRACK" def mRBRACK(self, ): try: _type = RBRACK _channel = DEFAULT_CHANNEL # Comments.g:73:11: ( ']' ) # Comments.g:73:13: ']' pass self.match(93) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RBRACK" # $ANTLR start "COLON" def mCOLON(self, ): try: _type = COLON _channel = DEFAULT_CHANNEL # Comments.g:75:11: ( ':' ) # Comments.g:75:13: ':' pass self.match(58) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COLON" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # Comments.g:77:10: ( ',' ) # Comments.g:77:12: ',' pass self.match(44) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "SEMI" def mSEMI(self, ): try: _type = SEMI _channel = DEFAULT_CHANNEL # Comments.g:79:9: ( ';' ) # Comments.g:79:11: ';' pass self.match(59) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SEMI" # $ANTLR start "PLUS" def mPLUS(self, ): try: _type = PLUS _channel = DEFAULT_CHANNEL # Comments.g:81:9: ( '+' ) # Comments.g:81:11: '+' pass self.match(43) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUS" # $ANTLR start "MINUS" def mMINUS(self, ): try: _type = MINUS _channel = DEFAULT_CHANNEL # Comments.g:83:10: ( '-' ) # Comments.g:83:12: '-' pass self.match(45) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "MINUS" # $ANTLR start "STAR" def mSTAR(self, ): try: _type = STAR _channel = DEFAULT_CHANNEL # Comments.g:85:9: ( '*' ) # Comments.g:85:11: '*' pass self.match(42) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STAR" # $ANTLR start "SLASH" def mSLASH(self, ): try: _type = SLASH _channel = DEFAULT_CHANNEL # Comments.g:87:10: ( '/' ) # Comments.g:87:12: '/' pass self.match(47) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SLASH" # $ANTLR start "VBAR" def mVBAR(self, ): try: _type = VBAR _channel = DEFAULT_CHANNEL # Comments.g:89:9: ( '|' ) # Comments.g:89:11: '|' pass self.match(124) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "VBAR" # $ANTLR start "AMPER" def mAMPER(self, ): try: _type = AMPER _channel = DEFAULT_CHANNEL # Comments.g:91:10: ( '&' ) # Comments.g:91:12: '&' pass self.match(38) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AMPER" # $ANTLR start "LESS" def mLESS(self, ): try: _type = LESS _channel = DEFAULT_CHANNEL # Comments.g:93:9: ( '<' ) # Comments.g:93:11: '<' pass self.match(60) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LESS" # $ANTLR start "GREATER" def mGREATER(self, ): try: _type = GREATER _channel = DEFAULT_CHANNEL # Comments.g:95:12: ( '>' ) # Comments.g:95:14: '>' pass self.match(62) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "GREATER" # $ANTLR start "ASSIGN" def mASSIGN(self, ): try: _type = ASSIGN _channel = DEFAULT_CHANNEL # Comments.g:97:11: ( '=' ) # Comments.g:97:13: '=' pass self.match(61) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ASSIGN" # $ANTLR start "PERCENT" def mPERCENT(self, ): try: _type = PERCENT _channel = DEFAULT_CHANNEL # Comments.g:99:12: ( '%' ) # Comments.g:99:14: '%' pass self.match(37) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PERCENT" # $ANTLR start "BACKQUOTE" def mBACKQUOTE(self, ): try: _type = BACKQUOTE _channel = DEFAULT_CHANNEL # Comments.g:101:14: ( '`' ) # Comments.g:101:16: '`' pass self.match(96) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BACKQUOTE" # $ANTLR start "LCURLY" def mLCURLY(self, ): try: _type = LCURLY _channel = DEFAULT_CHANNEL # Comments.g:103:11: ( '{' ) # Comments.g:103:13: '{' pass self.match(123) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LCURLY" # $ANTLR start "RCURLY" def mRCURLY(self, ): try: _type = RCURLY _channel = DEFAULT_CHANNEL # Comments.g:105:11: ( '}' ) # Comments.g:105:13: '}' pass self.match(125) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RCURLY" # $ANTLR start "CIRCUMFLEX" def mCIRCUMFLEX(self, ): try: _type = CIRCUMFLEX _channel = DEFAULT_CHANNEL # Comments.g:107:12: ( '^' ) # Comments.g:107:14: '^' pass self.match(94) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CIRCUMFLEX" # $ANTLR start "TILDE" def mTILDE(self, ): try: _type = TILDE _channel = DEFAULT_CHANNEL # Comments.g:109:10: ( '~' ) # Comments.g:109:12: '~' pass self.match(126) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "TILDE" # $ANTLR start "QMARK" def mQMARK(self, ): try: _type = QMARK _channel = DEFAULT_CHANNEL # Comments.g:111:7: ( '?' ) # Comments.g:111:9: '?' pass self.match(63) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "QMARK" # $ANTLR start "EMARK" def mEMARK(self, ): try: _type = EMARK _channel = DEFAULT_CHANNEL # Comments.g:113:7: ( '!' ) # Comments.g:113:9: '!' pass self.match(33) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EMARK" # $ANTLR start "SHARP" def mSHARP(self, ): try: _type = SHARP _channel = DEFAULT_CHANNEL # Comments.g:115:7: ( '#' ) # Comments.g:115:9: '#' pass self.match(35) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SHARP" # $ANTLR start "BSLAHS" def mBSLAHS(self, ): try: _type = BSLAHS _channel = DEFAULT_CHANNEL # Comments.g:119:8: ( '\\\\' ) # Comments.g:119:10: '\\\\' pass self.match(92) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BSLAHS" # $ANTLR start "DOT" def mDOT(self, ): try: _type = DOT _channel = DEFAULT_CHANNEL # Comments.g:121:5: ( '.' ) # Comments.g:121:7: '.' pass self.match(46) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOT" # $ANTLR start "AT" def mAT(self, ): try: _type = AT _channel = DEFAULT_CHANNEL # Comments.g:123:4: ( '@' ) # Comments.g:123:6: '@' pass self.match(64) #action start _channel = HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT" # $ANTLR start "APOS" def mAPOS(self, ): try: _type = APOS _channel = DEFAULT_CHANNEL # Comments.g:125:6: ( '\\'' ) # Comments.g:125:8: '\\'' pass self.match(39) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "APOS" # $ANTLR start "QUOTE" def mQUOTE(self, ): try: _type = QUOTE _channel = DEFAULT_CHANNEL # Comments.g:127:7: ( '\"' ) # Comments.g:127:9: '\"' pass self.match(34) #action start _channel=HIDDEN #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "QUOTE" def mTokens(self): # Comments.g:1:8: ( WS | COMMENT | LINE_COMMENT | Identifier | DIGIT | LPAREN | RPAREN | LBRACK | RBRACK | COLON | COMMA | SEMI | PLUS | MINUS | STAR | SLASH | VBAR | AMPER | LESS | GREATER | ASSIGN | PERCENT | BACKQUOTE | LCURLY | RCURLY | CIRCUMFLEX | TILDE | QMARK | EMARK | SHARP | BSLAHS | DOT | AT | APOS | QUOTE ) alt5 = 35 alt5 = self.dfa5.predict(self.input) if alt5 == 1: # Comments.g:1:10: WS pass self.mWS() elif alt5 == 2: # Comments.g:1:13: COMMENT pass self.mCOMMENT() elif alt5 == 3: # Comments.g:1:21: LINE_COMMENT pass self.mLINE_COMMENT() elif alt5 == 4: # Comments.g:1:34: Identifier pass self.mIdentifier() elif alt5 == 5: # Comments.g:1:45: DIGIT pass self.mDIGIT() elif alt5 == 6: # Comments.g:1:51: LPAREN pass self.mLPAREN() elif alt5 == 7: # Comments.g:1:58: RPAREN pass self.mRPAREN() elif alt5 == 8: # Comments.g:1:65: LBRACK pass self.mLBRACK() elif alt5 == 9: # Comments.g:1:72: RBRACK pass self.mRBRACK() elif alt5 == 10: # Comments.g:1:79: COLON pass self.mCOLON() elif alt5 == 11: # Comments.g:1:85: COMMA pass self.mCOMMA() elif alt5 == 12: # Comments.g:1:91: SEMI pass self.mSEMI() elif alt5 == 13: # Comments.g:1:96: PLUS pass self.mPLUS() elif alt5 == 14: # Comments.g:1:101: MINUS pass self.mMINUS() elif alt5 == 15: # Comments.g:1:107: STAR pass self.mSTAR() elif alt5 == 16: # Comments.g:1:112: SLASH pass self.mSLASH() elif alt5 == 17: # Comments.g:1:118: VBAR pass self.mVBAR() elif alt5 == 18: # Comments.g:1:123: AMPER pass self.mAMPER() elif alt5 == 19: # Comments.g:1:129: LESS pass self.mLESS() elif alt5 == 20: # Comments.g:1:134: GREATER pass self.mGREATER() elif alt5 == 21: # Comments.g:1:142: ASSIGN pass self.mASSIGN() elif alt5 == 22: # Comments.g:1:149: PERCENT pass self.mPERCENT() elif alt5 == 23: # Comments.g:1:157: BACKQUOTE pass self.mBACKQUOTE() elif alt5 == 24: # Comments.g:1:167: LCURLY pass self.mLCURLY() elif alt5 == 25: # Comments.g:1:174: RCURLY pass self.mRCURLY() elif alt5 == 26: # Comments.g:1:181: CIRCUMFLEX pass self.mCIRCUMFLEX() elif alt5 == 27: # Comments.g:1:192: TILDE pass self.mTILDE() elif alt5 == 28: # Comments.g:1:198: QMARK pass self.mQMARK() elif alt5 == 29: # Comments.g:1:204: EMARK pass self.mEMARK() elif alt5 == 30: # Comments.g:1:210: SHARP pass self.mSHARP() elif alt5 == 31: # Comments.g:1:216: BSLAHS pass self.mBSLAHS() elif alt5 == 32: # Comments.g:1:223: DOT pass self.mDOT() elif alt5 == 33: # Comments.g:1:227: AT pass self.mAT() elif alt5 == 34: # Comments.g:1:230: APOS pass self.mAPOS() elif alt5 == 35: # Comments.g:1:235: QUOTE pass self.mQUOTE() # lookup tables for DFA #5 DFA5_eot = DFA.unpack( u"\2\uffff\1\44\42\uffff" ) DFA5_eof = DFA.unpack( u"\45\uffff" ) DFA5_min = DFA.unpack( u"\1\11\1\uffff\1\52\42\uffff" ) DFA5_max = DFA.unpack( u"\1\ufaff\1\uffff\1\57\42\uffff" ) DFA5_accept = DFA.unpack( u"\1\uffff\1\1\1\uffff\1\4\1\5\1\6\1\7\1\10\1\11\1\12\1\13\1\14\1" u"\15\1\16\1\17\1\21\1\22\1\23\1\24\1\25\1\26\1\27\1\30\1\31\1\32" u"\1\33\1\34\1\35\1\36\1\37\1\40\1\41\1\42\1\43\1\2\1\3\1\20" ) DFA5_special = DFA.unpack( u"\45\uffff" ) DFA5_transition = [ DFA.unpack(u"\2\1\1\uffff\2\1\22\uffff\1\1\1\33\1\41\1\34\1\3\1\24" u"\1\20\1\40\1\5\1\6\1\16\1\14\1\12\1\15\1\36\1\2\12\4\1\11\1\13" u"\1\21\1\23\1\22\1\32\1\37\32\3\1\7\1\35\1\10\1\30\1\3\1\25\32\3" u"\1\26\1\17\1\27\1\31\101\uffff\27\3\1\uffff\37\3\1\uffff\u1f08" u"\3\u1040\uffff\u0150\3\u0170\uffff\u0080\3\u0080\uffff\u092e\3" u"\u10d2\uffff\u5200\3\u5900\uffff\u0200\3"), DFA.unpack(u""), DFA.unpack(u"\1\42\4\uffff\1\43"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #5 DFA5 = DFA def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(Comments) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "leriomaggio/code-coherence-evaluation-tool", "path": "code_comments_coherence/source_code_analysis/code_analysis/Comments.py", "copies": "1", "size": "30857", "license": "bsd-3-clause", "hash": -11754514667656776, "line_mean": 19.3542216359, "line_max": 578, "alpha_frac": 0.429335321, "autogenerated": false, "ratio": 3.472931907709623, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4402267228709623, "avg_score": null, "num_lines": null }
# $ANTLR 3.1 ./Java.g 2013-07-16 16:21:24 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types T__159=159 T__158=158 T__160=160 LEFT_SHIFT_ASSIGN=65 T__167=167 T__168=168 EOF=-1 T__165=165 T__166=166 T__163=163 T__164=164 T__161=161 T__162=162 TYPE_IMPORT_ON_DEMAND_DECLARATION=7 T__148=148 T__147=147 T__149=149 ABSTRACT_METHOD_DECLARATION=28 COMPILATION_UNIT=4 MARKER_ANNOTATION=47 THIS=77 TYPE_PARAMETERS=12 T__154=154 ENUM_DECLARATION=15 T__155=155 T__156=156 T__157=157 T__150=150 QUALIFIED_SUPER=83 T__151=151 T__152=152 T__153=153 T__139=139 T__138=138 LESS_THAN_OR_EQUAL_TO=68 T__137=137 ELEMENT_VALUE_PAIR=48 T__136=136 INNER_THIS=90 IntegerTypeSuffix=102 ALTERNATE_CONSTRUCTOR_INVOCATION=42 TYPE_ARGUMENTS=37 NON_WILD_TYPE_ARGUMENTS=89 T__141=141 T__142=142 T__140=140 T__145=145 T__146=146 T__143=143 T__144=144 T__126=126 T__125=125 UNSIGNED_RIGHT_SHIFT_ASSIGN=66 T__128=128 T__127=127 SINGLE_TYPE_IMPORT_DECLARATION=6 WS=111 T__129=129 UNQUALIFIED_SUPER=78 POST_INCREMENT_EXPRESSION=74 ANNOTATION_TYPE_BODY=51 FloatingPointLiteral=96 ANNOTATION_METHOD=52 NORMAL_ANNOTATION=45 JavaIDDigit=110 PREFIX_EXPRESSION=73 LEFT_SHIFT=70 CALL=81 EXPRESSION_STATEMENT=57 METHOD_DECLARATION=27 T__130=130 T__131=131 T__132=132 CLASS_DESIGNATOR=79 T__133=133 T__134=134 T__135=135 T__118=118 T__119=119 T__116=116 ANNOTATION_INTERFACE=50 T__117=117 ENHANCED_FOR_CONTROL=62 T__114=114 STATIC_IMPORT_ON_DEMAND_DECLARATION=9 T__115=115 T__124=124 T__123=123 T__122=122 T__121=121 T__120=120 HexDigit=101 QUALIFIED_THIS=82 T__202=202 EXPLICIT_GENERIC_INVOCATIONS=88 EXPRESSION_LIST=64 CONSTRUCTOR_DECLARATION=29 HexLiteral=93 CONSTRUCTOR_BODY=34 CLASS_BODY=21 StringLiteral=98 CLASS_DECLARATION=11 ENUM=108 UNSIGNED_RIGHT_SHIFT=71 BLOCK=53 OctalEscape=107 ARRAY_INITIALIZER=33 CAST=76 LOCAL_VARIABLE_DECLARATION=54 FloatTypeSuffix=104 FOR_INIT_DECLARATION=60 OctalLiteral=94 SIGNED_RIGHT_SHIFT=72 Identifier=100 UNQUALIFIED_CLASS_INSTANCE_CREATION=84 FOR_UPDATE=63 UNQUALIFIED_SUPERCLASS_CONSTRUCTOR_INVOCATION=43 NEW_ARRAY=87 ENUM_BODY=16 INSTANCE_INITIALIZER=24 FORMAL_PARAMETER=40 VOID=25 COMMENT=112 SELECT=36 ENUM_CONSTANT=18 SINGLE_ELEMENT_ANNOTATION=46 ARGUMENTS=91 LINE_COMMENT=113 ASSERT_STATEMENT=55 ARRAY_OF=32 ASSERT=99 LAST_FORMAL_PARAMETER=41 TYPE_BOUND=14 BASIC_FOR_CONTROL=59 SWITCH_BLOCK_STATEMENT_GROUP=58 ELEMENT_VALUE_ARRAY_INITIALIZER=49 T__200=200 T__201=201 METHOD_BODY=92 EMPTY_STATEMENT=56 INSTANTIATION=35 POST_DECREMENT_EXPRESSION=75 SINGLE_STATIC_IMPORT_DECLARATION=8 INTERFACE_DECLARATION=20 Letter=109 EscapeSequence=105 FIELD_DECLARATION=26 GREATER_THAN_OR_EQUAL_TO=69 CharacterLiteral=97 Exponent=103 MODIFIERS=10 VARIABLE_DECLARATOR=30 T__199=199 T__198=198 T__197=197 ENUM_CONSTANTS=17 T__196=196 T__195=195 FOR_INIT_EXPRESSION_LIST=61 T__194=194 ENUM_BODY_DECLARATIONS=19 T__193=193 T__192=192 T__191=191 T__190=190 WILDCARD=38 NEW_INITIALIZED_ARRAY=86 T__184=184 T__183=183 T__186=186 T__185=185 T__188=188 T__187=187 PACKAGE_DECLARATION=5 T__189=189 CONSTANT_DECLARATION=31 INTERFACE_BODY=22 T__180=180 T__182=182 T__181=181 SIGNED_RIGHT_SHIFT_ASSIGN=67 ARRAY_ACCESS=80 DecimalLiteral=95 T__175=175 T__174=174 T__173=173 FORMAL_PARAMETERS=39 T__172=172 TYPE_PARAMETER=13 T__179=179 T__178=178 T__177=177 T__176=176 QUALIFIED_SUPERCLASS_CONSTRUCTOR_INVOCATION=44 UnicodeEscape=106 T__171=171 T__170=170 QUALIFIED_CLASS_INSTANCE_CREATION=85 STATIC_INITIALIZER=23 T__169=169 class JavaLexer(Lexer): grammarFileName = "./Java.g" antlr_version = version_str_to_tuple("3.1") antlr_version_str = "3.1" def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() Lexer.__init__(self, input, state) self.dfa18 = self.DFA18( self, 18, eot = self.DFA18_eot, eof = self.DFA18_eof, min = self.DFA18_min, max = self.DFA18_max, accept = self.DFA18_accept, special = self.DFA18_special, transition = self.DFA18_transition ) self.dfa29 = self.DFA29( self, 29, eot = self.DFA29_eot, eof = self.DFA29_eof, min = self.DFA29_min, max = self.DFA29_max, accept = self.DFA29_accept, special = self.DFA29_special, transition = self.DFA29_transition ) self.enumIsKeyword = False; self.assertIsKeyword = True; # $ANTLR start "T__114" def mT__114(self, ): try: _type = T__114 _channel = DEFAULT_CHANNEL # ./Java.g:12:8: ( 'package' ) # ./Java.g:12:10: 'package' pass self.match("package") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__114" # $ANTLR start "T__115" def mT__115(self, ): try: _type = T__115 _channel = DEFAULT_CHANNEL # ./Java.g:13:8: ( ';' ) # ./Java.g:13:10: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__115" # $ANTLR start "T__116" def mT__116(self, ): try: _type = T__116 _channel = DEFAULT_CHANNEL # ./Java.g:14:8: ( 'import' ) # ./Java.g:14:10: 'import' pass self.match("import") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__116" # $ANTLR start "T__117" def mT__117(self, ): try: _type = T__117 _channel = DEFAULT_CHANNEL # ./Java.g:15:8: ( 'static' ) # ./Java.g:15:10: 'static' pass self.match("static") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__117" # $ANTLR start "T__118" def mT__118(self, ): try: _type = T__118 _channel = DEFAULT_CHANNEL # ./Java.g:16:8: ( '.' ) # ./Java.g:16:10: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__118" # $ANTLR start "T__119" def mT__119(self, ): try: _type = T__119 _channel = DEFAULT_CHANNEL # ./Java.g:17:8: ( '*' ) # ./Java.g:17:10: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__119" # $ANTLR start "T__120" def mT__120(self, ): try: _type = T__120 _channel = DEFAULT_CHANNEL # ./Java.g:18:8: ( 'class' ) # ./Java.g:18:10: 'class' pass self.match("class") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__120" # $ANTLR start "T__121" def mT__121(self, ): try: _type = T__121 _channel = DEFAULT_CHANNEL # ./Java.g:19:8: ( 'extends' ) # ./Java.g:19:10: 'extends' pass self.match("extends") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__121" # $ANTLR start "T__122" def mT__122(self, ): try: _type = T__122 _channel = DEFAULT_CHANNEL # ./Java.g:20:8: ( 'implements' ) # ./Java.g:20:10: 'implements' pass self.match("implements") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__122" # $ANTLR start "T__123" def mT__123(self, ): try: _type = T__123 _channel = DEFAULT_CHANNEL # ./Java.g:21:8: ( '<' ) # ./Java.g:21:10: '<' pass self.match(60) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__123" # $ANTLR start "T__124" def mT__124(self, ): try: _type = T__124 _channel = DEFAULT_CHANNEL # ./Java.g:22:8: ( ',' ) # ./Java.g:22:10: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__124" # $ANTLR start "T__125" def mT__125(self, ): try: _type = T__125 _channel = DEFAULT_CHANNEL # ./Java.g:23:8: ( '>' ) # ./Java.g:23:10: '>' pass self.match(62) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__125" # $ANTLR start "T__126" def mT__126(self, ): try: _type = T__126 _channel = DEFAULT_CHANNEL # ./Java.g:24:8: ( '&' ) # ./Java.g:24:10: '&' pass self.match(38) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__126" # $ANTLR start "T__127" def mT__127(self, ): try: _type = T__127 _channel = DEFAULT_CHANNEL # ./Java.g:25:8: ( '{' ) # ./Java.g:25:10: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__127" # $ANTLR start "T__128" def mT__128(self, ): try: _type = T__128 _channel = DEFAULT_CHANNEL # ./Java.g:26:8: ( '}' ) # ./Java.g:26:10: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__128" # $ANTLR start "T__129" def mT__129(self, ): try: _type = T__129 _channel = DEFAULT_CHANNEL # ./Java.g:27:8: ( 'interface' ) # ./Java.g:27:10: 'interface' pass self.match("interface") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__129" # $ANTLR start "T__130" def mT__130(self, ): try: _type = T__130 _channel = DEFAULT_CHANNEL # ./Java.g:28:8: ( 'void' ) # ./Java.g:28:10: 'void' pass self.match("void") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__130" # $ANTLR start "T__131" def mT__131(self, ): try: _type = T__131 _channel = DEFAULT_CHANNEL # ./Java.g:29:8: ( '[' ) # ./Java.g:29:10: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__131" # $ANTLR start "T__132" def mT__132(self, ): try: _type = T__132 _channel = DEFAULT_CHANNEL # ./Java.g:30:8: ( ']' ) # ./Java.g:30:10: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__132" # $ANTLR start "T__133" def mT__133(self, ): try: _type = T__133 _channel = DEFAULT_CHANNEL # ./Java.g:31:8: ( 'throws' ) # ./Java.g:31:10: 'throws' pass self.match("throws") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__133" # $ANTLR start "T__134" def mT__134(self, ): try: _type = T__134 _channel = DEFAULT_CHANNEL # ./Java.g:32:8: ( '=' ) # ./Java.g:32:10: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__134" # $ANTLR start "T__135" def mT__135(self, ): try: _type = T__135 _channel = DEFAULT_CHANNEL # ./Java.g:33:8: ( 'boolean' ) # ./Java.g:33:10: 'boolean' pass self.match("boolean") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__135" # $ANTLR start "T__136" def mT__136(self, ): try: _type = T__136 _channel = DEFAULT_CHANNEL # ./Java.g:34:8: ( 'char' ) # ./Java.g:34:10: 'char' pass self.match("char") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__136" # $ANTLR start "T__137" def mT__137(self, ): try: _type = T__137 _channel = DEFAULT_CHANNEL # ./Java.g:35:8: ( 'byte' ) # ./Java.g:35:10: 'byte' pass self.match("byte") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__137" # $ANTLR start "T__138" def mT__138(self, ): try: _type = T__138 _channel = DEFAULT_CHANNEL # ./Java.g:36:8: ( 'short' ) # ./Java.g:36:10: 'short' pass self.match("short") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__138" # $ANTLR start "T__139" def mT__139(self, ): try: _type = T__139 _channel = DEFAULT_CHANNEL # ./Java.g:37:8: ( 'int' ) # ./Java.g:37:10: 'int' pass self.match("int") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__139" # $ANTLR start "T__140" def mT__140(self, ): try: _type = T__140 _channel = DEFAULT_CHANNEL # ./Java.g:38:8: ( 'long' ) # ./Java.g:38:10: 'long' pass self.match("long") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__140" # $ANTLR start "T__141" def mT__141(self, ): try: _type = T__141 _channel = DEFAULT_CHANNEL # ./Java.g:39:8: ( 'float' ) # ./Java.g:39:10: 'float' pass self.match("float") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__141" # $ANTLR start "T__142" def mT__142(self, ): try: _type = T__142 _channel = DEFAULT_CHANNEL # ./Java.g:40:8: ( 'double' ) # ./Java.g:40:10: 'double' pass self.match("double") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__142" # $ANTLR start "T__143" def mT__143(self, ): try: _type = T__143 _channel = DEFAULT_CHANNEL # ./Java.g:41:8: ( '?' ) # ./Java.g:41:10: '?' pass self.match(63) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__143" # $ANTLR start "T__144" def mT__144(self, ): try: _type = T__144 _channel = DEFAULT_CHANNEL # ./Java.g:42:8: ( 'super' ) # ./Java.g:42:10: 'super' pass self.match("super") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__144" # $ANTLR start "T__145" def mT__145(self, ): try: _type = T__145 _channel = DEFAULT_CHANNEL # ./Java.g:43:8: ( '(' ) # ./Java.g:43:10: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__145" # $ANTLR start "T__146" def mT__146(self, ): try: _type = T__146 _channel = DEFAULT_CHANNEL # ./Java.g:44:8: ( ')' ) # ./Java.g:44:10: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__146" # $ANTLR start "T__147" def mT__147(self, ): try: _type = T__147 _channel = DEFAULT_CHANNEL # ./Java.g:45:8: ( '...' ) # ./Java.g:45:10: '...' pass self.match("...") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__147" # $ANTLR start "T__148" def mT__148(self, ): try: _type = T__148 _channel = DEFAULT_CHANNEL # ./Java.g:46:8: ( 'this' ) # ./Java.g:46:10: 'this' pass self.match("this") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__148" # $ANTLR start "T__149" def mT__149(self, ): try: _type = T__149 _channel = DEFAULT_CHANNEL # ./Java.g:47:8: ( 'true' ) # ./Java.g:47:10: 'true' pass self.match("true") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__149" # $ANTLR start "T__150" def mT__150(self, ): try: _type = T__150 _channel = DEFAULT_CHANNEL # ./Java.g:48:8: ( 'false' ) # ./Java.g:48:10: 'false' pass self.match("false") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__150" # $ANTLR start "T__151" def mT__151(self, ): try: _type = T__151 _channel = DEFAULT_CHANNEL # ./Java.g:49:8: ( 'null' ) # ./Java.g:49:10: 'null' pass self.match("null") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__151" # $ANTLR start "T__152" def mT__152(self, ): try: _type = T__152 _channel = DEFAULT_CHANNEL # ./Java.g:50:8: ( '@' ) # ./Java.g:50:10: '@' pass self.match(64) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__152" # $ANTLR start "T__153" def mT__153(self, ): try: _type = T__153 _channel = DEFAULT_CHANNEL # ./Java.g:51:8: ( 'default' ) # ./Java.g:51:10: 'default' pass self.match("default") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__153" # $ANTLR start "T__154" def mT__154(self, ): try: _type = T__154 _channel = DEFAULT_CHANNEL # ./Java.g:52:8: ( ':' ) # ./Java.g:52:10: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__154" # $ANTLR start "T__155" def mT__155(self, ): try: _type = T__155 _channel = DEFAULT_CHANNEL # ./Java.g:53:8: ( 'if' ) # ./Java.g:53:10: 'if' pass self.match("if") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__155" # $ANTLR start "T__156" def mT__156(self, ): try: _type = T__156 _channel = DEFAULT_CHANNEL # ./Java.g:54:8: ( 'else' ) # ./Java.g:54:10: 'else' pass self.match("else") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__156" # $ANTLR start "T__157" def mT__157(self, ): try: _type = T__157 _channel = DEFAULT_CHANNEL # ./Java.g:55:8: ( 'for' ) # ./Java.g:55:10: 'for' pass self.match("for") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__157" # $ANTLR start "T__158" def mT__158(self, ): try: _type = T__158 _channel = DEFAULT_CHANNEL # ./Java.g:56:8: ( 'while' ) # ./Java.g:56:10: 'while' pass self.match("while") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__158" # $ANTLR start "T__159" def mT__159(self, ): try: _type = T__159 _channel = DEFAULT_CHANNEL # ./Java.g:57:8: ( 'do' ) # ./Java.g:57:10: 'do' pass self.match("do") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__159" # $ANTLR start "T__160" def mT__160(self, ): try: _type = T__160 _channel = DEFAULT_CHANNEL # ./Java.g:58:8: ( 'try' ) # ./Java.g:58:10: 'try' pass self.match("try") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__160" # $ANTLR start "T__161" def mT__161(self, ): try: _type = T__161 _channel = DEFAULT_CHANNEL # ./Java.g:59:8: ( 'catch' ) # ./Java.g:59:10: 'catch' pass self.match("catch") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__161" # $ANTLR start "T__162" def mT__162(self, ): try: _type = T__162 _channel = DEFAULT_CHANNEL # ./Java.g:60:8: ( 'finally' ) # ./Java.g:60:10: 'finally' pass self.match("finally") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__162" # $ANTLR start "T__163" def mT__163(self, ): try: _type = T__163 _channel = DEFAULT_CHANNEL # ./Java.g:61:8: ( 'switch' ) # ./Java.g:61:10: 'switch' pass self.match("switch") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__163" # $ANTLR start "T__164" def mT__164(self, ): try: _type = T__164 _channel = DEFAULT_CHANNEL # ./Java.g:62:8: ( 'synchronized' ) # ./Java.g:62:10: 'synchronized' pass self.match("synchronized") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__164" # $ANTLR start "T__165" def mT__165(self, ): try: _type = T__165 _channel = DEFAULT_CHANNEL # ./Java.g:63:8: ( 'return' ) # ./Java.g:63:10: 'return' pass self.match("return") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__165" # $ANTLR start "T__166" def mT__166(self, ): try: _type = T__166 _channel = DEFAULT_CHANNEL # ./Java.g:64:8: ( 'throw' ) # ./Java.g:64:10: 'throw' pass self.match("throw") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__166" # $ANTLR start "T__167" def mT__167(self, ): try: _type = T__167 _channel = DEFAULT_CHANNEL # ./Java.g:65:8: ( 'break' ) # ./Java.g:65:10: 'break' pass self.match("break") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__167" # $ANTLR start "T__168" def mT__168(self, ): try: _type = T__168 _channel = DEFAULT_CHANNEL # ./Java.g:66:8: ( 'continue' ) # ./Java.g:66:10: 'continue' pass self.match("continue") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__168" # $ANTLR start "T__169" def mT__169(self, ): try: _type = T__169 _channel = DEFAULT_CHANNEL # ./Java.g:67:8: ( 'case' ) # ./Java.g:67:10: 'case' pass self.match("case") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__169" # $ANTLR start "T__170" def mT__170(self, ): try: _type = T__170 _channel = DEFAULT_CHANNEL # ./Java.g:68:8: ( '+=' ) # ./Java.g:68:10: '+=' pass self.match("+=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__170" # $ANTLR start "T__171" def mT__171(self, ): try: _type = T__171 _channel = DEFAULT_CHANNEL # ./Java.g:69:8: ( '-=' ) # ./Java.g:69:10: '-=' pass self.match("-=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__171" # $ANTLR start "T__172" def mT__172(self, ): try: _type = T__172 _channel = DEFAULT_CHANNEL # ./Java.g:70:8: ( '*=' ) # ./Java.g:70:10: '*=' pass self.match("*=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__172" # $ANTLR start "T__173" def mT__173(self, ): try: _type = T__173 _channel = DEFAULT_CHANNEL # ./Java.g:71:8: ( '/=' ) # ./Java.g:71:10: '/=' pass self.match("/=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__173" # $ANTLR start "T__174" def mT__174(self, ): try: _type = T__174 _channel = DEFAULT_CHANNEL # ./Java.g:72:8: ( '&=' ) # ./Java.g:72:10: '&=' pass self.match("&=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__174" # $ANTLR start "T__175" def mT__175(self, ): try: _type = T__175 _channel = DEFAULT_CHANNEL # ./Java.g:73:8: ( '|=' ) # ./Java.g:73:10: '|=' pass self.match("|=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__175" # $ANTLR start "T__176" def mT__176(self, ): try: _type = T__176 _channel = DEFAULT_CHANNEL # ./Java.g:74:8: ( '^=' ) # ./Java.g:74:10: '^=' pass self.match("^=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__176" # $ANTLR start "T__177" def mT__177(self, ): try: _type = T__177 _channel = DEFAULT_CHANNEL # ./Java.g:75:8: ( '%=' ) # ./Java.g:75:10: '%=' pass self.match("%=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__177" # $ANTLR start "T__178" def mT__178(self, ): try: _type = T__178 _channel = DEFAULT_CHANNEL # ./Java.g:76:8: ( '||' ) # ./Java.g:76:10: '||' pass self.match("||") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__178" # $ANTLR start "T__179" def mT__179(self, ): try: _type = T__179 _channel = DEFAULT_CHANNEL # ./Java.g:77:8: ( '&&' ) # ./Java.g:77:10: '&&' pass self.match("&&") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__179" # $ANTLR start "T__180" def mT__180(self, ): try: _type = T__180 _channel = DEFAULT_CHANNEL # ./Java.g:78:8: ( '|' ) # ./Java.g:78:10: '|' pass self.match(124) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__180" # $ANTLR start "T__181" def mT__181(self, ): try: _type = T__181 _channel = DEFAULT_CHANNEL # ./Java.g:79:8: ( '^' ) # ./Java.g:79:10: '^' pass self.match(94) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__181" # $ANTLR start "T__182" def mT__182(self, ): try: _type = T__182 _channel = DEFAULT_CHANNEL # ./Java.g:80:8: ( '==' ) # ./Java.g:80:10: '==' pass self.match("==") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__182" # $ANTLR start "T__183" def mT__183(self, ): try: _type = T__183 _channel = DEFAULT_CHANNEL # ./Java.g:81:8: ( '!=' ) # ./Java.g:81:10: '!=' pass self.match("!=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__183" # $ANTLR start "T__184" def mT__184(self, ): try: _type = T__184 _channel = DEFAULT_CHANNEL # ./Java.g:82:8: ( 'instanceof' ) # ./Java.g:82:10: 'instanceof' pass self.match("instanceof") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__184" # $ANTLR start "T__185" def mT__185(self, ): try: _type = T__185 _channel = DEFAULT_CHANNEL # ./Java.g:83:8: ( '+' ) # ./Java.g:83:10: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__185" # $ANTLR start "T__186" def mT__186(self, ): try: _type = T__186 _channel = DEFAULT_CHANNEL # ./Java.g:84:8: ( '-' ) # ./Java.g:84:10: '-' pass self.match(45) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__186" # $ANTLR start "T__187" def mT__187(self, ): try: _type = T__187 _channel = DEFAULT_CHANNEL # ./Java.g:85:8: ( '/' ) # ./Java.g:85:10: '/' pass self.match(47) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__187" # $ANTLR start "T__188" def mT__188(self, ): try: _type = T__188 _channel = DEFAULT_CHANNEL # ./Java.g:86:8: ( '%' ) # ./Java.g:86:10: '%' pass self.match(37) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__188" # $ANTLR start "T__189" def mT__189(self, ): try: _type = T__189 _channel = DEFAULT_CHANNEL # ./Java.g:87:8: ( '++' ) # ./Java.g:87:10: '++' pass self.match("++") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__189" # $ANTLR start "T__190" def mT__190(self, ): try: _type = T__190 _channel = DEFAULT_CHANNEL # ./Java.g:88:8: ( '--' ) # ./Java.g:88:10: '--' pass self.match("--") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__190" # $ANTLR start "T__191" def mT__191(self, ): try: _type = T__191 _channel = DEFAULT_CHANNEL # ./Java.g:89:8: ( '~' ) # ./Java.g:89:10: '~' pass self.match(126) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__191" # $ANTLR start "T__192" def mT__192(self, ): try: _type = T__192 _channel = DEFAULT_CHANNEL # ./Java.g:90:8: ( '!' ) # ./Java.g:90:10: '!' pass self.match(33) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__192" # $ANTLR start "T__193" def mT__193(self, ): try: _type = T__193 _channel = DEFAULT_CHANNEL # ./Java.g:91:8: ( 'new' ) # ./Java.g:91:10: 'new' pass self.match("new") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__193" # $ANTLR start "T__194" def mT__194(self, ): try: _type = T__194 _channel = DEFAULT_CHANNEL # ./Java.g:92:8: ( 'public' ) # ./Java.g:92:10: 'public' pass self.match("public") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__194" # $ANTLR start "T__195" def mT__195(self, ): try: _type = T__195 _channel = DEFAULT_CHANNEL # ./Java.g:93:8: ( 'protected' ) # ./Java.g:93:10: 'protected' pass self.match("protected") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__195" # $ANTLR start "T__196" def mT__196(self, ): try: _type = T__196 _channel = DEFAULT_CHANNEL # ./Java.g:94:8: ( 'private' ) # ./Java.g:94:10: 'private' pass self.match("private") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__196" # $ANTLR start "T__197" def mT__197(self, ): try: _type = T__197 _channel = DEFAULT_CHANNEL # ./Java.g:95:8: ( 'abstract' ) # ./Java.g:95:10: 'abstract' pass self.match("abstract") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__197" # $ANTLR start "T__198" def mT__198(self, ): try: _type = T__198 _channel = DEFAULT_CHANNEL # ./Java.g:96:8: ( 'final' ) # ./Java.g:96:10: 'final' pass self.match("final") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__198" # $ANTLR start "T__199" def mT__199(self, ): try: _type = T__199 _channel = DEFAULT_CHANNEL # ./Java.g:97:8: ( 'native' ) # ./Java.g:97:10: 'native' pass self.match("native") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__199" # $ANTLR start "T__200" def mT__200(self, ): try: _type = T__200 _channel = DEFAULT_CHANNEL # ./Java.g:98:8: ( 'transient' ) # ./Java.g:98:10: 'transient' pass self.match("transient") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__200" # $ANTLR start "T__201" def mT__201(self, ): try: _type = T__201 _channel = DEFAULT_CHANNEL # ./Java.g:99:8: ( 'volatile' ) # ./Java.g:99:10: 'volatile' pass self.match("volatile") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__201" # $ANTLR start "T__202" def mT__202(self, ): try: _type = T__202 _channel = DEFAULT_CHANNEL # ./Java.g:100:8: ( 'strictfp' ) # ./Java.g:100:10: 'strictfp' pass self.match("strictfp") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__202" # $ANTLR start "HexLiteral" def mHexLiteral(self, ): try: _type = HexLiteral _channel = DEFAULT_CHANNEL # ./Java.g:1470:12: ( '0' ( 'x' | 'X' ) ( HexDigit )+ ( IntegerTypeSuffix )? ) # ./Java.g:1470:14: '0' ( 'x' | 'X' ) ( HexDigit )+ ( IntegerTypeSuffix )? pass self.match(48) if self.input.LA(1) == 88 or self.input.LA(1) == 120: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # ./Java.g:1470:28: ( HexDigit )+ cnt1 = 0 while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((48 <= LA1_0 <= 57) or (65 <= LA1_0 <= 70) or (97 <= LA1_0 <= 102)) : alt1 = 1 if alt1 == 1: # ./Java.g:1470:28: HexDigit pass self.mHexDigit() else: if cnt1 >= 1: break #loop1 eee = EarlyExitException(1, self.input) raise eee cnt1 += 1 # ./Java.g:1470:38: ( IntegerTypeSuffix )? alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == 76 or LA2_0 == 108) : alt2 = 1 if alt2 == 1: # ./Java.g:1470:38: IntegerTypeSuffix pass self.mIntegerTypeSuffix() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "HexLiteral" # $ANTLR start "DecimalLiteral" def mDecimalLiteral(self, ): try: _type = DecimalLiteral _channel = DEFAULT_CHANNEL # ./Java.g:1472:16: ( ( '0' | '1' .. '9' ( '0' .. '9' )* ) ( IntegerTypeSuffix )? ) # ./Java.g:1472:18: ( '0' | '1' .. '9' ( '0' .. '9' )* ) ( IntegerTypeSuffix )? pass # ./Java.g:1472:18: ( '0' | '1' .. '9' ( '0' .. '9' )* ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 48) : alt4 = 1 elif ((49 <= LA4_0 <= 57)) : alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # ./Java.g:1472:19: '0' pass self.match(48) elif alt4 == 2: # ./Java.g:1472:25: '1' .. '9' ( '0' .. '9' )* pass self.matchRange(49, 57) # ./Java.g:1472:34: ( '0' .. '9' )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if ((48 <= LA3_0 <= 57)) : alt3 = 1 if alt3 == 1: # ./Java.g:1472:34: '0' .. '9' pass self.matchRange(48, 57) else: break #loop3 # ./Java.g:1472:45: ( IntegerTypeSuffix )? alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == 76 or LA5_0 == 108) : alt5 = 1 if alt5 == 1: # ./Java.g:1472:45: IntegerTypeSuffix pass self.mIntegerTypeSuffix() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DecimalLiteral" # $ANTLR start "OctalLiteral" def mOctalLiteral(self, ): try: _type = OctalLiteral _channel = DEFAULT_CHANNEL # ./Java.g:1474:14: ( '0' ( '0' .. '7' )+ ( IntegerTypeSuffix )? ) # ./Java.g:1474:16: '0' ( '0' .. '7' )+ ( IntegerTypeSuffix )? pass self.match(48) # ./Java.g:1474:20: ( '0' .. '7' )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if ((48 <= LA6_0 <= 55)) : alt6 = 1 if alt6 == 1: # ./Java.g:1474:21: '0' .. '7' pass self.matchRange(48, 55) else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 # ./Java.g:1474:32: ( IntegerTypeSuffix )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 76 or LA7_0 == 108) : alt7 = 1 if alt7 == 1: # ./Java.g:1474:32: IntegerTypeSuffix pass self.mIntegerTypeSuffix() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OctalLiteral" # $ANTLR start "HexDigit" def mHexDigit(self, ): try: # ./Java.g:1477:10: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) ) # ./Java.g:1477:12: ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "HexDigit" # $ANTLR start "IntegerTypeSuffix" def mIntegerTypeSuffix(self, ): try: # ./Java.g:1480:19: ( ( 'l' | 'L' ) ) # ./Java.g:1480:21: ( 'l' | 'L' ) pass if self.input.LA(1) == 76 or self.input.LA(1) == 108: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "IntegerTypeSuffix" # $ANTLR start "FloatingPointLiteral" def mFloatingPointLiteral(self, ): try: _type = FloatingPointLiteral _channel = DEFAULT_CHANNEL # ./Java.g:1483:5: ( ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( Exponent )? ( FloatTypeSuffix )? | '.' ( '0' .. '9' )+ ( Exponent )? ( FloatTypeSuffix )? | ( '0' .. '9' )+ Exponent ( FloatTypeSuffix )? | ( '0' .. '9' )+ FloatTypeSuffix ) alt18 = 4 alt18 = self.dfa18.predict(self.input) if alt18 == 1: # ./Java.g:1483:9: ( '0' .. '9' )+ '.' ( '0' .. '9' )* ( Exponent )? ( FloatTypeSuffix )? pass # ./Java.g:1483:9: ( '0' .. '9' )+ cnt8 = 0 while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if ((48 <= LA8_0 <= 57)) : alt8 = 1 if alt8 == 1: # ./Java.g:1483:10: '0' .. '9' pass self.matchRange(48, 57) else: if cnt8 >= 1: break #loop8 eee = EarlyExitException(8, self.input) raise eee cnt8 += 1 self.match(46) # ./Java.g:1483:25: ( '0' .. '9' )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if ((48 <= LA9_0 <= 57)) : alt9 = 1 if alt9 == 1: # ./Java.g:1483:26: '0' .. '9' pass self.matchRange(48, 57) else: break #loop9 # ./Java.g:1483:37: ( Exponent )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 69 or LA10_0 == 101) : alt10 = 1 if alt10 == 1: # ./Java.g:1483:37: Exponent pass self.mExponent() # ./Java.g:1483:47: ( FloatTypeSuffix )? alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == 68 or LA11_0 == 70 or LA11_0 == 100 or LA11_0 == 102) : alt11 = 1 if alt11 == 1: # ./Java.g:1483:47: FloatTypeSuffix pass self.mFloatTypeSuffix() elif alt18 == 2: # ./Java.g:1484:9: '.' ( '0' .. '9' )+ ( Exponent )? ( FloatTypeSuffix )? pass self.match(46) # ./Java.g:1484:13: ( '0' .. '9' )+ cnt12 = 0 while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if ((48 <= LA12_0 <= 57)) : alt12 = 1 if alt12 == 1: # ./Java.g:1484:14: '0' .. '9' pass self.matchRange(48, 57) else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 # ./Java.g:1484:25: ( Exponent )? alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == 69 or LA13_0 == 101) : alt13 = 1 if alt13 == 1: # ./Java.g:1484:25: Exponent pass self.mExponent() # ./Java.g:1484:35: ( FloatTypeSuffix )? alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == 68 or LA14_0 == 70 or LA14_0 == 100 or LA14_0 == 102) : alt14 = 1 if alt14 == 1: # ./Java.g:1484:35: FloatTypeSuffix pass self.mFloatTypeSuffix() elif alt18 == 3: # ./Java.g:1485:9: ( '0' .. '9' )+ Exponent ( FloatTypeSuffix )? pass # ./Java.g:1485:9: ( '0' .. '9' )+ cnt15 = 0 while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if ((48 <= LA15_0 <= 57)) : alt15 = 1 if alt15 == 1: # ./Java.g:1485:10: '0' .. '9' pass self.matchRange(48, 57) else: if cnt15 >= 1: break #loop15 eee = EarlyExitException(15, self.input) raise eee cnt15 += 1 self.mExponent() # ./Java.g:1485:30: ( FloatTypeSuffix )? alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == 68 or LA16_0 == 70 or LA16_0 == 100 or LA16_0 == 102) : alt16 = 1 if alt16 == 1: # ./Java.g:1485:30: FloatTypeSuffix pass self.mFloatTypeSuffix() elif alt18 == 4: # ./Java.g:1486:9: ( '0' .. '9' )+ FloatTypeSuffix pass # ./Java.g:1486:9: ( '0' .. '9' )+ cnt17 = 0 while True: #loop17 alt17 = 2 LA17_0 = self.input.LA(1) if ((48 <= LA17_0 <= 57)) : alt17 = 1 if alt17 == 1: # ./Java.g:1486:10: '0' .. '9' pass self.matchRange(48, 57) else: if cnt17 >= 1: break #loop17 eee = EarlyExitException(17, self.input) raise eee cnt17 += 1 self.mFloatTypeSuffix() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FloatingPointLiteral" # $ANTLR start "Exponent" def mExponent(self, ): try: # ./Java.g:1490:10: ( ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ ) # ./Java.g:1490:12: ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ pass if self.input.LA(1) == 69 or self.input.LA(1) == 101: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # ./Java.g:1490:22: ( '+' | '-' )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == 43 or LA19_0 == 45) : alt19 = 1 if alt19 == 1: # ./Java.g: pass if self.input.LA(1) == 43 or self.input.LA(1) == 45: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # ./Java.g:1490:33: ( '0' .. '9' )+ cnt20 = 0 while True: #loop20 alt20 = 2 LA20_0 = self.input.LA(1) if ((48 <= LA20_0 <= 57)) : alt20 = 1 if alt20 == 1: # ./Java.g:1490:34: '0' .. '9' pass self.matchRange(48, 57) else: if cnt20 >= 1: break #loop20 eee = EarlyExitException(20, self.input) raise eee cnt20 += 1 finally: pass # $ANTLR end "Exponent" # $ANTLR start "FloatTypeSuffix" def mFloatTypeSuffix(self, ): try: # ./Java.g:1493:17: ( ( 'f' | 'F' | 'd' | 'D' ) ) # ./Java.g:1493:19: ( 'f' | 'F' | 'd' | 'D' ) pass if self.input.LA(1) == 68 or self.input.LA(1) == 70 or self.input.LA(1) == 100 or self.input.LA(1) == 102: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "FloatTypeSuffix" # $ANTLR start "CharacterLiteral" def mCharacterLiteral(self, ): try: _type = CharacterLiteral _channel = DEFAULT_CHANNEL # ./Java.g:1496:5: ( '\\'' ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) '\\'' ) # ./Java.g:1496:9: '\\'' ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) '\\'' pass self.match(39) # ./Java.g:1496:14: ( EscapeSequence | ~ ( '\\'' | '\\\\' ) ) alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == 92) : alt21 = 1 elif ((0 <= LA21_0 <= 38) or (40 <= LA21_0 <= 91) or (93 <= LA21_0 <= 65534)) : alt21 = 2 else: nvae = NoViableAltException("", 21, 0, self.input) raise nvae if alt21 == 1: # ./Java.g:1496:16: EscapeSequence pass self.mEscapeSequence() elif alt21 == 2: # ./Java.g:1496:33: ~ ( '\\'' | '\\\\' ) pass if (0 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65534): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self.match(39) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CharacterLiteral" # $ANTLR start "StringLiteral" def mStringLiteral(self, ): try: _type = StringLiteral _channel = DEFAULT_CHANNEL # ./Java.g:1500:5: ( '\"' ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* '\"' ) # ./Java.g:1500:8: '\"' ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* '\"' pass self.match(34) # ./Java.g:1500:12: ( EscapeSequence | ~ ( '\\\\' | '\"' ) )* while True: #loop22 alt22 = 3 LA22_0 = self.input.LA(1) if (LA22_0 == 92) : alt22 = 1 elif ((0 <= LA22_0 <= 33) or (35 <= LA22_0 <= 91) or (93 <= LA22_0 <= 65534)) : alt22 = 2 if alt22 == 1: # ./Java.g:1500:14: EscapeSequence pass self.mEscapeSequence() elif alt22 == 2: # ./Java.g:1500:31: ~ ( '\\\\' | '\"' ) pass if (0 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65534): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop22 self.match(34) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "StringLiteral" # $ANTLR start "EscapeSequence" def mEscapeSequence(self, ): try: # ./Java.g:1505:5: ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | UnicodeEscape | OctalEscape ) alt23 = 3 LA23_0 = self.input.LA(1) if (LA23_0 == 92) : LA23 = self.input.LA(2) if LA23 == 34 or LA23 == 39 or LA23 == 92 or LA23 == 98 or LA23 == 102 or LA23 == 110 or LA23 == 114 or LA23 == 116: alt23 = 1 elif LA23 == 117: alt23 = 2 elif LA23 == 48 or LA23 == 49 or LA23 == 50 or LA23 == 51 or LA23 == 52 or LA23 == 53 or LA23 == 54 or LA23 == 55: alt23 = 3 else: nvae = NoViableAltException("", 23, 1, self.input) raise nvae else: nvae = NoViableAltException("", 23, 0, self.input) raise nvae if alt23 == 1: # ./Java.g:1505:9: '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) pass self.match(92) if self.input.LA(1) == 34 or self.input.LA(1) == 39 or self.input.LA(1) == 92 or self.input.LA(1) == 98 or self.input.LA(1) == 102 or self.input.LA(1) == 110 or self.input.LA(1) == 114 or self.input.LA(1) == 116: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt23 == 2: # ./Java.g:1506:9: UnicodeEscape pass self.mUnicodeEscape() elif alt23 == 3: # ./Java.g:1507:9: OctalEscape pass self.mOctalEscape() finally: pass # $ANTLR end "EscapeSequence" # $ANTLR start "OctalEscape" def mOctalEscape(self, ): try: # ./Java.g:1512:5: ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ) alt24 = 3 LA24_0 = self.input.LA(1) if (LA24_0 == 92) : LA24_1 = self.input.LA(2) if ((48 <= LA24_1 <= 51)) : LA24_2 = self.input.LA(3) if ((48 <= LA24_2 <= 55)) : LA24_5 = self.input.LA(4) if ((48 <= LA24_5 <= 55)) : alt24 = 1 else: alt24 = 2 else: alt24 = 3 elif ((52 <= LA24_1 <= 55)) : LA24_3 = self.input.LA(3) if ((48 <= LA24_3 <= 55)) : alt24 = 2 else: alt24 = 3 else: nvae = NoViableAltException("", 24, 1, self.input) raise nvae else: nvae = NoViableAltException("", 24, 0, self.input) raise nvae if alt24 == 1: # ./Java.g:1512:9: '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) pass self.match(92) # ./Java.g:1512:14: ( '0' .. '3' ) # ./Java.g:1512:15: '0' .. '3' pass self.matchRange(48, 51) # ./Java.g:1512:25: ( '0' .. '7' ) # ./Java.g:1512:26: '0' .. '7' pass self.matchRange(48, 55) # ./Java.g:1512:36: ( '0' .. '7' ) # ./Java.g:1512:37: '0' .. '7' pass self.matchRange(48, 55) elif alt24 == 2: # ./Java.g:1513:9: '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) pass self.match(92) # ./Java.g:1513:14: ( '0' .. '7' ) # ./Java.g:1513:15: '0' .. '7' pass self.matchRange(48, 55) # ./Java.g:1513:25: ( '0' .. '7' ) # ./Java.g:1513:26: '0' .. '7' pass self.matchRange(48, 55) elif alt24 == 3: # ./Java.g:1514:9: '\\\\' ( '0' .. '7' ) pass self.match(92) # ./Java.g:1514:14: ( '0' .. '7' ) # ./Java.g:1514:15: '0' .. '7' pass self.matchRange(48, 55) finally: pass # $ANTLR end "OctalEscape" # $ANTLR start "UnicodeEscape" def mUnicodeEscape(self, ): try: # ./Java.g:1519:5: ( '\\\\' 'u' HexDigit HexDigit HexDigit HexDigit ) # ./Java.g:1519:9: '\\\\' 'u' HexDigit HexDigit HexDigit HexDigit pass self.match(92) self.match(117) self.mHexDigit() self.mHexDigit() self.mHexDigit() self.mHexDigit() finally: pass # $ANTLR end "UnicodeEscape" # $ANTLR start "ENUM" def mENUM(self, ): try: _type = ENUM _channel = DEFAULT_CHANNEL # ./Java.g:1522:5: ( 'enum' ) # ./Java.g:1522:9: 'enum' pass self.match("enum") #action start if not(self.enumIsKeyword): _type=Identifier; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ENUM" # $ANTLR start "ASSERT" def mASSERT(self, ): try: _type = ASSERT _channel = DEFAULT_CHANNEL # ./Java.g:1530:5: ( 'assert' ) # ./Java.g:1530:9: 'assert' pass self.match("assert") #action start if not(self.assertIsKeyword): _type=Identifier; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ASSERT" # $ANTLR start "Identifier" def mIdentifier(self, ): try: _type = Identifier _channel = DEFAULT_CHANNEL # ./Java.g:1538:5: ( Letter ( Letter | JavaIDDigit )* ) # ./Java.g:1538:9: Letter ( Letter | JavaIDDigit )* pass self.mLetter() # ./Java.g:1538:16: ( Letter | JavaIDDigit )* while True: #loop25 alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == 36 or (48 <= LA25_0 <= 57) or (65 <= LA25_0 <= 90) or LA25_0 == 95 or (97 <= LA25_0 <= 122) or (192 <= LA25_0 <= 214) or (216 <= LA25_0 <= 246) or (248 <= LA25_0 <= 8191) or (12352 <= LA25_0 <= 12687) or (13056 <= LA25_0 <= 13183) or (13312 <= LA25_0 <= 15661) or (19968 <= LA25_0 <= 40959) or (63744 <= LA25_0 <= 64255)) : alt25 = 1 if alt25 == 1: # ./Java.g: pass if self.input.LA(1) == 36 or (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122) or (192 <= self.input.LA(1) <= 214) or (216 <= self.input.LA(1) <= 246) or (248 <= self.input.LA(1) <= 8191) or (12352 <= self.input.LA(1) <= 12687) or (13056 <= self.input.LA(1) <= 13183) or (13312 <= self.input.LA(1) <= 15661) or (19968 <= self.input.LA(1) <= 40959) or (63744 <= self.input.LA(1) <= 64255): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop25 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "Identifier" # $ANTLR start "Letter" def mLetter(self, ): try: # ./Java.g:1546:5: ( '\\u0024' | '\\u0041' .. '\\u005a' | '\\u005f' | '\\u0061' .. '\\u007a' | '\\u00c0' .. '\\u00d6' | '\\u00d8' .. '\\u00f6' | '\\u00f8' .. '\\u00ff' | '\\u0100' .. '\\u1fff' | '\\u3040' .. '\\u318f' | '\\u3300' .. '\\u337f' | '\\u3400' .. '\\u3d2d' | '\\u4e00' .. '\\u9fff' | '\\uf900' .. '\\ufaff' ) # ./Java.g: pass if self.input.LA(1) == 36 or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122) or (192 <= self.input.LA(1) <= 214) or (216 <= self.input.LA(1) <= 246) or (248 <= self.input.LA(1) <= 8191) or (12352 <= self.input.LA(1) <= 12687) or (13056 <= self.input.LA(1) <= 13183) or (13312 <= self.input.LA(1) <= 15661) or (19968 <= self.input.LA(1) <= 40959) or (63744 <= self.input.LA(1) <= 64255): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "Letter" # $ANTLR start "JavaIDDigit" def mJavaIDDigit(self, ): try: # ./Java.g:1563:5: ( '\\u0030' .. '\\u0039' | '\\u0660' .. '\\u0669' | '\\u06f0' .. '\\u06f9' | '\\u0966' .. '\\u096f' | '\\u09e6' .. '\\u09ef' | '\\u0a66' .. '\\u0a6f' | '\\u0ae6' .. '\\u0aef' | '\\u0b66' .. '\\u0b6f' | '\\u0be7' .. '\\u0bef' | '\\u0c66' .. '\\u0c6f' | '\\u0ce6' .. '\\u0cef' | '\\u0d66' .. '\\u0d6f' | '\\u0e50' .. '\\u0e59' | '\\u0ed0' .. '\\u0ed9' | '\\u1040' .. '\\u1049' ) # ./Java.g: pass if (48 <= self.input.LA(1) <= 57) or (1632 <= self.input.LA(1) <= 1641) or (1776 <= self.input.LA(1) <= 1785) or (2406 <= self.input.LA(1) <= 2415) or (2534 <= self.input.LA(1) <= 2543) or (2662 <= self.input.LA(1) <= 2671) or (2790 <= self.input.LA(1) <= 2799) or (2918 <= self.input.LA(1) <= 2927) or (3047 <= self.input.LA(1) <= 3055) or (3174 <= self.input.LA(1) <= 3183) or (3302 <= self.input.LA(1) <= 3311) or (3430 <= self.input.LA(1) <= 3439) or (3664 <= self.input.LA(1) <= 3673) or (3792 <= self.input.LA(1) <= 3801) or (4160 <= self.input.LA(1) <= 4169): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "JavaIDDigit" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # ./Java.g:1580:5: ( ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) ) # ./Java.g:1580:8: ( ' ' | '\\r' | '\\t' | '\\u000C' | '\\n' ) pass if (9 <= self.input.LA(1) <= 10) or (12 <= self.input.LA(1) <= 13) or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # ./Java.g:1584:5: ( '/*' ( options {greedy=false; } : . )* '*/' ) # ./Java.g:1584:9: '/*' ( options {greedy=false; } : . )* '*/' pass self.match("/*") # ./Java.g:1584:14: ( options {greedy=false; } : . )* while True: #loop26 alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == 42) : LA26_1 = self.input.LA(2) if (LA26_1 == 47) : alt26 = 2 elif ((0 <= LA26_1 <= 46) or (48 <= LA26_1 <= 65534)) : alt26 = 1 elif ((0 <= LA26_0 <= 41) or (43 <= LA26_0 <= 65534)) : alt26 = 1 if alt26 == 1: # ./Java.g:1584:41: . pass self.matchAny() else: break #loop26 self.match("*/") #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "LINE_COMMENT" def mLINE_COMMENT(self, ): try: _type = LINE_COMMENT _channel = DEFAULT_CHANNEL # ./Java.g:1588:5: ( '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) # ./Java.g:1588:7: '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' pass self.match("//") # ./Java.g:1588:12: (~ ( '\\n' | '\\r' ) )* while True: #loop27 alt27 = 2 LA27_0 = self.input.LA(1) if ((0 <= LA27_0 <= 9) or (11 <= LA27_0 <= 12) or (14 <= LA27_0 <= 65534)) : alt27 = 1 if alt27 == 1: # ./Java.g:1588:12: ~ ( '\\n' | '\\r' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 65534): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop27 # ./Java.g:1588:26: ( '\\r' )? alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == 13) : alt28 = 1 if alt28 == 1: # ./Java.g:1588:26: '\\r' pass self.match(13) self.match(10) #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LINE_COMMENT" def mTokens(self): # ./Java.g:1:8: ( T__114 | T__115 | T__116 | T__117 | T__118 | T__119 | T__120 | T__121 | T__122 | T__123 | T__124 | T__125 | T__126 | T__127 | T__128 | T__129 | T__130 | T__131 | T__132 | T__133 | T__134 | T__135 | T__136 | T__137 | T__138 | T__139 | T__140 | T__141 | T__142 | T__143 | T__144 | T__145 | T__146 | T__147 | T__148 | T__149 | T__150 | T__151 | T__152 | T__153 | T__154 | T__155 | T__156 | T__157 | T__158 | T__159 | T__160 | T__161 | T__162 | T__163 | T__164 | T__165 | T__166 | T__167 | T__168 | T__169 | T__170 | T__171 | T__172 | T__173 | T__174 | T__175 | T__176 | T__177 | T__178 | T__179 | T__180 | T__181 | T__182 | T__183 | T__184 | T__185 | T__186 | T__187 | T__188 | T__189 | T__190 | T__191 | T__192 | T__193 | T__194 | T__195 | T__196 | T__197 | T__198 | T__199 | T__200 | T__201 | T__202 | HexLiteral | DecimalLiteral | OctalLiteral | FloatingPointLiteral | CharacterLiteral | StringLiteral | ENUM | ASSERT | Identifier | WS | COMMENT | LINE_COMMENT ) alt29 = 101 alt29 = self.dfa29.predict(self.input) if alt29 == 1: # ./Java.g:1:10: T__114 pass self.mT__114() elif alt29 == 2: # ./Java.g:1:17: T__115 pass self.mT__115() elif alt29 == 3: # ./Java.g:1:24: T__116 pass self.mT__116() elif alt29 == 4: # ./Java.g:1:31: T__117 pass self.mT__117() elif alt29 == 5: # ./Java.g:1:38: T__118 pass self.mT__118() elif alt29 == 6: # ./Java.g:1:45: T__119 pass self.mT__119() elif alt29 == 7: # ./Java.g:1:52: T__120 pass self.mT__120() elif alt29 == 8: # ./Java.g:1:59: T__121 pass self.mT__121() elif alt29 == 9: # ./Java.g:1:66: T__122 pass self.mT__122() elif alt29 == 10: # ./Java.g:1:73: T__123 pass self.mT__123() elif alt29 == 11: # ./Java.g:1:80: T__124 pass self.mT__124() elif alt29 == 12: # ./Java.g:1:87: T__125 pass self.mT__125() elif alt29 == 13: # ./Java.g:1:94: T__126 pass self.mT__126() elif alt29 == 14: # ./Java.g:1:101: T__127 pass self.mT__127() elif alt29 == 15: # ./Java.g:1:108: T__128 pass self.mT__128() elif alt29 == 16: # ./Java.g:1:115: T__129 pass self.mT__129() elif alt29 == 17: # ./Java.g:1:122: T__130 pass self.mT__130() elif alt29 == 18: # ./Java.g:1:129: T__131 pass self.mT__131() elif alt29 == 19: # ./Java.g:1:136: T__132 pass self.mT__132() elif alt29 == 20: # ./Java.g:1:143: T__133 pass self.mT__133() elif alt29 == 21: # ./Java.g:1:150: T__134 pass self.mT__134() elif alt29 == 22: # ./Java.g:1:157: T__135 pass self.mT__135() elif alt29 == 23: # ./Java.g:1:164: T__136 pass self.mT__136() elif alt29 == 24: # ./Java.g:1:171: T__137 pass self.mT__137() elif alt29 == 25: # ./Java.g:1:178: T__138 pass self.mT__138() elif alt29 == 26: # ./Java.g:1:185: T__139 pass self.mT__139() elif alt29 == 27: # ./Java.g:1:192: T__140 pass self.mT__140() elif alt29 == 28: # ./Java.g:1:199: T__141 pass self.mT__141() elif alt29 == 29: # ./Java.g:1:206: T__142 pass self.mT__142() elif alt29 == 30: # ./Java.g:1:213: T__143 pass self.mT__143() elif alt29 == 31: # ./Java.g:1:220: T__144 pass self.mT__144() elif alt29 == 32: # ./Java.g:1:227: T__145 pass self.mT__145() elif alt29 == 33: # ./Java.g:1:234: T__146 pass self.mT__146() elif alt29 == 34: # ./Java.g:1:241: T__147 pass self.mT__147() elif alt29 == 35: # ./Java.g:1:248: T__148 pass self.mT__148() elif alt29 == 36: # ./Java.g:1:255: T__149 pass self.mT__149() elif alt29 == 37: # ./Java.g:1:262: T__150 pass self.mT__150() elif alt29 == 38: # ./Java.g:1:269: T__151 pass self.mT__151() elif alt29 == 39: # ./Java.g:1:276: T__152 pass self.mT__152() elif alt29 == 40: # ./Java.g:1:283: T__153 pass self.mT__153() elif alt29 == 41: # ./Java.g:1:290: T__154 pass self.mT__154() elif alt29 == 42: # ./Java.g:1:297: T__155 pass self.mT__155() elif alt29 == 43: # ./Java.g:1:304: T__156 pass self.mT__156() elif alt29 == 44: # ./Java.g:1:311: T__157 pass self.mT__157() elif alt29 == 45: # ./Java.g:1:318: T__158 pass self.mT__158() elif alt29 == 46: # ./Java.g:1:325: T__159 pass self.mT__159() elif alt29 == 47: # ./Java.g:1:332: T__160 pass self.mT__160() elif alt29 == 48: # ./Java.g:1:339: T__161 pass self.mT__161() elif alt29 == 49: # ./Java.g:1:346: T__162 pass self.mT__162() elif alt29 == 50: # ./Java.g:1:353: T__163 pass self.mT__163() elif alt29 == 51: # ./Java.g:1:360: T__164 pass self.mT__164() elif alt29 == 52: # ./Java.g:1:367: T__165 pass self.mT__165() elif alt29 == 53: # ./Java.g:1:374: T__166 pass self.mT__166() elif alt29 == 54: # ./Java.g:1:381: T__167 pass self.mT__167() elif alt29 == 55: # ./Java.g:1:388: T__168 pass self.mT__168() elif alt29 == 56: # ./Java.g:1:395: T__169 pass self.mT__169() elif alt29 == 57: # ./Java.g:1:402: T__170 pass self.mT__170() elif alt29 == 58: # ./Java.g:1:409: T__171 pass self.mT__171() elif alt29 == 59: # ./Java.g:1:416: T__172 pass self.mT__172() elif alt29 == 60: # ./Java.g:1:423: T__173 pass self.mT__173() elif alt29 == 61: # ./Java.g:1:430: T__174 pass self.mT__174() elif alt29 == 62: # ./Java.g:1:437: T__175 pass self.mT__175() elif alt29 == 63: # ./Java.g:1:444: T__176 pass self.mT__176() elif alt29 == 64: # ./Java.g:1:451: T__177 pass self.mT__177() elif alt29 == 65: # ./Java.g:1:458: T__178 pass self.mT__178() elif alt29 == 66: # ./Java.g:1:465: T__179 pass self.mT__179() elif alt29 == 67: # ./Java.g:1:472: T__180 pass self.mT__180() elif alt29 == 68: # ./Java.g:1:479: T__181 pass self.mT__181() elif alt29 == 69: # ./Java.g:1:486: T__182 pass self.mT__182() elif alt29 == 70: # ./Java.g:1:493: T__183 pass self.mT__183() elif alt29 == 71: # ./Java.g:1:500: T__184 pass self.mT__184() elif alt29 == 72: # ./Java.g:1:507: T__185 pass self.mT__185() elif alt29 == 73: # ./Java.g:1:514: T__186 pass self.mT__186() elif alt29 == 74: # ./Java.g:1:521: T__187 pass self.mT__187() elif alt29 == 75: # ./Java.g:1:528: T__188 pass self.mT__188() elif alt29 == 76: # ./Java.g:1:535: T__189 pass self.mT__189() elif alt29 == 77: # ./Java.g:1:542: T__190 pass self.mT__190() elif alt29 == 78: # ./Java.g:1:549: T__191 pass self.mT__191() elif alt29 == 79: # ./Java.g:1:556: T__192 pass self.mT__192() elif alt29 == 80: # ./Java.g:1:563: T__193 pass self.mT__193() elif alt29 == 81: # ./Java.g:1:570: T__194 pass self.mT__194() elif alt29 == 82: # ./Java.g:1:577: T__195 pass self.mT__195() elif alt29 == 83: # ./Java.g:1:584: T__196 pass self.mT__196() elif alt29 == 84: # ./Java.g:1:591: T__197 pass self.mT__197() elif alt29 == 85: # ./Java.g:1:598: T__198 pass self.mT__198() elif alt29 == 86: # ./Java.g:1:605: T__199 pass self.mT__199() elif alt29 == 87: # ./Java.g:1:612: T__200 pass self.mT__200() elif alt29 == 88: # ./Java.g:1:619: T__201 pass self.mT__201() elif alt29 == 89: # ./Java.g:1:626: T__202 pass self.mT__202() elif alt29 == 90: # ./Java.g:1:633: HexLiteral pass self.mHexLiteral() elif alt29 == 91: # ./Java.g:1:644: DecimalLiteral pass self.mDecimalLiteral() elif alt29 == 92: # ./Java.g:1:659: OctalLiteral pass self.mOctalLiteral() elif alt29 == 93: # ./Java.g:1:672: FloatingPointLiteral pass self.mFloatingPointLiteral() elif alt29 == 94: # ./Java.g:1:693: CharacterLiteral pass self.mCharacterLiteral() elif alt29 == 95: # ./Java.g:1:710: StringLiteral pass self.mStringLiteral() elif alt29 == 96: # ./Java.g:1:724: ENUM pass self.mENUM() elif alt29 == 97: # ./Java.g:1:729: ASSERT pass self.mASSERT() elif alt29 == 98: # ./Java.g:1:736: Identifier pass self.mIdentifier() elif alt29 == 99: # ./Java.g:1:747: WS pass self.mWS() elif alt29 == 100: # ./Java.g:1:750: COMMENT pass self.mCOMMENT() elif alt29 == 101: # ./Java.g:1:758: LINE_COMMENT pass self.mLINE_COMMENT() # lookup tables for DFA #18 DFA18_eot = DFA.unpack( u"\6\uffff" ) DFA18_eof = DFA.unpack( u"\6\uffff" ) DFA18_min = DFA.unpack( u"\2\56\4\uffff" ) DFA18_max = DFA.unpack( u"\1\71\1\146\4\uffff" ) DFA18_accept = DFA.unpack( u"\2\uffff\1\2\1\4\1\3\1\1" ) DFA18_special = DFA.unpack( u"\6\uffff" ) DFA18_transition = [ DFA.unpack(u"\1\2\1\uffff\12\1"), DFA.unpack(u"\1\5\1\uffff\12\1\12\uffff\1\3\1\4\1\3\35\uffff\1\3" u"\1\4\1\3"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #18 DFA18 = DFA # lookup tables for DFA #29 DFA29_eot = DFA.unpack( u"\1\uffff\1\55\1\uffff\2\55\1\73\1\76\2\55\3\uffff\1\110\2\uffff" u"\1\55\2\uffff\1\55\1\115\4\55\3\uffff\1\55\2\uffff\2\55\1\137\1" u"\142\1\146\1\151\1\153\1\155\1\157\1\uffff\1\55\2\164\4\uffff\5" u"\55\1\175\5\55\5\uffff\7\55\3\uffff\3\55\2\uffff\10\55\1\u009c" u"\6\55\23\uffff\2\55\1\uffff\1\u00a5\1\uffff\1\164\5\55\1\u00ad" u"\1\55\1\uffff\23\55\1\u00c2\7\55\1\u00ca\2\55\1\uffff\2\55\1\u00cf" u"\5\55\1\uffff\7\55\1\uffff\10\55\1\u00e4\1\55\1\u00e6\2\55\1\u00e9" u"\1\u00ea\1\u00eb\2\55\1\u00ee\1\u00ef\1\uffff\2\55\1\u00f2\1\55" u"\1\u00f4\2\55\1\uffff\3\55\1\u00fa\1\uffff\17\55\1\u010a\1\u010b" u"\2\55\1\u010e\1\uffff\1\u010f\1\uffff\2\55\3\uffff\1\55\1\u0114" u"\2\uffff\2\55\1\uffff\1\u0117\1\uffff\1\u0118\1\u0119\1\u011b\2" u"\55\1\uffff\1\55\1\u011f\4\55\1\u0124\2\55\1\u0127\3\55\1\u012b" u"\1\55\2\uffff\1\u012d\1\55\2\uffff\3\55\1\u0132\1\uffff\2\55\3" u"\uffff\1\55\1\uffff\1\u0136\1\55\1\u0138\1\uffff\1\u0139\1\55\1" u"\u013b\1\u013c\1\uffff\1\55\1\u013e\1\uffff\3\55\1\uffff\1\55\1" u"\uffff\2\55\1\u0145\1\55\1\uffff\1\55\1\u0148\1\u0149\1\uffff\1" u"\u014a\2\uffff\1\55\2\uffff\1\55\1\uffff\3\55\1\u0150\1\55\1\u0152" u"\1\uffff\1\u0153\1\55\3\uffff\1\u0155\1\u0156\1\55\1\u0158\1\55" u"\1\uffff\1\55\2\uffff\1\u015b\2\uffff\1\u015c\1\uffff\1\u015d\1" u"\55\3\uffff\1\55\1\u0160\1\uffff" ) DFA29_eof = DFA.unpack( u"\u0161\uffff" ) DFA29_min = DFA.unpack( u"\1\11\1\141\1\uffff\1\146\1\150\1\56\1\75\1\141\1\154\3\uffff\1" u"\46\2\uffff\1\157\2\uffff\1\150\1\75\2\157\1\141\1\145\3\uffff" u"\1\141\2\uffff\1\150\1\145\1\53\1\55\1\52\4\75\1\uffff\1\142\2" u"\56\4\uffff\1\143\1\142\1\151\1\160\1\163\1\44\1\141\1\157\1\160" u"\1\151\1\156\5\uffff\2\141\1\163\1\156\1\164\1\163\1\165\3\uffff" u"\2\151\1\141\2\uffff\1\157\1\164\1\145\1\156\1\157\1\154\1\162" u"\1\156\1\44\1\146\1\154\1\167\1\164\1\151\1\164\23\uffff\2\163" u"\1\uffff\1\56\1\uffff\1\56\1\153\1\154\1\164\1\166\1\154\1\44\1" u"\164\1\uffff\1\164\1\151\1\162\1\145\1\164\1\143\1\163\1\162\1" u"\143\1\145\1\164\2\145\1\155\1\144\1\141\1\157\1\163\1\145\1\44" u"\1\156\1\154\1\145\1\141\1\147\1\141\1\163\1\44\1\141\1\142\1\uffff" u"\1\141\1\154\1\44\1\151\1\154\1\165\1\164\1\145\1\uffff\1\141\1" u"\151\1\145\1\141\1\162\1\145\1\162\1\uffff\1\141\1\151\1\143\1" u"\164\1\162\1\143\1\150\1\163\1\44\1\150\1\44\1\151\1\156\3\44\1" u"\164\1\167\2\44\1\uffff\1\163\1\145\1\44\1\153\1\44\1\164\1\145" u"\1\uffff\2\154\1\165\1\44\1\uffff\1\166\1\145\3\162\1\147\2\143" u"\2\164\1\155\1\146\1\156\1\143\1\164\2\44\1\150\1\162\1\44\1\uffff" u"\1\44\1\uffff\1\156\1\144\3\uffff\1\151\1\44\2\uffff\1\151\1\141" u"\1\uffff\1\44\1\uffff\3\44\1\145\1\154\1\uffff\1\145\1\44\1\156" u"\1\141\1\164\1\145\1\44\1\164\1\145\1\44\1\145\1\141\1\143\1\44" u"\1\146\2\uffff\1\44\1\157\2\uffff\1\165\1\163\1\154\1\44\1\uffff" u"\1\145\1\156\3\uffff\1\171\1\uffff\1\44\1\164\1\44\1\uffff\1\44" u"\1\143\2\44\1\uffff\1\145\1\44\1\uffff\1\156\1\143\1\145\1\uffff" u"\1\160\1\uffff\1\156\1\145\1\44\1\145\1\uffff\1\156\2\44\1\uffff" u"\1\44\2\uffff\1\164\2\uffff\1\144\1\uffff\1\164\1\145\1\157\1\44" u"\1\151\1\44\1\uffff\1\44\1\164\3\uffff\2\44\1\163\1\44\1\146\1" u"\uffff\1\172\2\uffff\1\44\2\uffff\1\44\1\uffff\1\44\1\145\3\uffff" u"\1\144\1\44\1\uffff" ) DFA29_max = DFA.unpack( u"\1\ufaff\1\165\1\uffff\1\156\1\171\1\71\1\75\1\157\1\170\3\uffff" u"\1\75\2\uffff\1\157\2\uffff\1\162\1\75\1\171\3\157\3\uffff\1\165" u"\2\uffff\1\150\1\145\3\75\1\174\3\75\1\uffff\1\163\1\170\1\146" u"\4\uffff\1\143\1\142\1\157\1\160\1\164\1\ufaff\1\162\1\157\1\160" u"\1\151\1\156\5\uffff\2\141\1\164\1\156\1\164\1\163\1\165\3\uffff" u"\1\154\1\162\1\171\2\uffff\1\157\1\164\1\145\1\156\1\157\1\154" u"\1\162\1\156\1\ufaff\1\146\1\154\1\167\1\164\1\151\1\164\23\uffff" u"\2\163\1\uffff\1\146\1\uffff\1\146\1\153\1\154\1\164\1\166\1\157" u"\1\ufaff\1\164\1\uffff\1\164\1\151\1\162\1\145\1\164\1\143\1\163" u"\1\162\1\143\1\145\1\164\2\145\1\155\1\144\1\141\1\157\1\163\1" u"\145\1\ufaff\1\156\1\154\1\145\1\141\1\147\1\141\1\163\1\ufaff" u"\1\141\1\142\1\uffff\1\141\1\154\1\ufaff\1\151\1\154\1\165\1\164" u"\1\145\1\uffff\1\141\1\151\1\145\1\141\1\162\1\145\1\162\1\uffff" u"\1\141\1\151\1\143\1\164\1\162\1\143\1\150\1\163\1\ufaff\1\150" u"\1\ufaff\1\151\1\156\3\ufaff\1\164\1\167\2\ufaff\1\uffff\1\163" u"\1\145\1\ufaff\1\153\1\ufaff\1\164\1\145\1\uffff\2\154\1\165\1" u"\ufaff\1\uffff\1\166\1\145\3\162\1\147\2\143\2\164\1\155\1\146" u"\1\156\1\143\1\164\2\ufaff\1\150\1\162\1\ufaff\1\uffff\1\ufaff" u"\1\uffff\1\156\1\144\3\uffff\1\151\1\ufaff\2\uffff\1\151\1\141" u"\1\uffff\1\ufaff\1\uffff\3\ufaff\1\145\1\154\1\uffff\1\145\1\ufaff" u"\1\156\1\141\1\164\1\145\1\ufaff\1\164\1\145\1\ufaff\1\145\1\141" u"\1\143\1\ufaff\1\146\2\uffff\1\ufaff\1\157\2\uffff\1\165\1\163" u"\1\154\1\ufaff\1\uffff\1\145\1\156\3\uffff\1\171\1\uffff\1\ufaff" u"\1\164\1\ufaff\1\uffff\1\ufaff\1\143\2\ufaff\1\uffff\1\145\1\ufaff" u"\1\uffff\1\156\1\143\1\145\1\uffff\1\160\1\uffff\1\156\1\145\1" u"\ufaff\1\145\1\uffff\1\156\2\ufaff\1\uffff\1\ufaff\2\uffff\1\164" u"\2\uffff\1\144\1\uffff\1\164\1\145\1\157\1\ufaff\1\151\1\ufaff" u"\1\uffff\1\ufaff\1\164\3\uffff\2\ufaff\1\163\1\ufaff\1\146\1\uffff" u"\1\172\2\uffff\1\ufaff\2\uffff\1\ufaff\1\uffff\1\ufaff\1\145\3" u"\uffff\1\144\1\ufaff\1\uffff" ) DFA29_accept = DFA.unpack( u"\2\uffff\1\2\6\uffff\1\12\1\13\1\14\1\uffff\1\16\1\17\1\uffff\1" u"\22\1\23\6\uffff\1\36\1\40\1\41\1\uffff\1\47\1\51\11\uffff\1\116" u"\3\uffff\1\136\1\137\1\142\1\143\13\uffff\1\42\1\5\1\135\1\73\1" u"\6\7\uffff\1\75\1\102\1\15\3\uffff\1\105\1\25\17\uffff\1\71\1\114" u"\1\110\1\72\1\115\1\111\1\74\1\144\1\145\1\112\1\76\1\101\1\103" u"\1\77\1\104\1\100\1\113\1\106\1\117\2\uffff\1\132\1\uffff\1\133" u"\10\uffff\1\52\36\uffff\1\56\10\uffff\1\134\7\uffff\1\32\24\uffff" u"\1\57\7\uffff\1\54\4\uffff\1\120\24\uffff\1\27\1\uffff\1\70\2\uffff" u"\1\53\1\140\1\21\2\uffff\1\43\1\44\2\uffff\1\30\1\uffff\1\33\5" u"\uffff\1\46\17\uffff\1\31\1\37\2\uffff\1\7\1\60\4\uffff\1\65\2" u"\uffff\1\66\1\34\1\45\1\uffff\1\125\3\uffff\1\55\4\uffff\1\121" u"\2\uffff\1\3\3\uffff\1\4\1\uffff\1\62\4\uffff\1\24\3\uffff\1\35" u"\1\uffff\1\126\1\64\1\uffff\1\141\1\1\1\uffff\1\123\6\uffff\1\10" u"\2\uffff\1\26\1\61\1\50\5\uffff\1\131\1\uffff\1\67\1\130\1\uffff" u"\1\124\1\122\1\uffff\1\20\2\uffff\1\127\1\11\1\107\2\uffff\1\63" ) DFA29_special = DFA.unpack( u"\u0161\uffff" ) DFA29_transition = [ DFA.unpack(u"\2\56\1\uffff\2\56\22\uffff\1\56\1\46\1\54\1\uffff\1" u"\55\1\45\1\14\1\53\1\31\1\32\1\6\1\40\1\12\1\41\1\5\1\42\1\51\11" u"\52\1\35\1\2\1\11\1\23\1\13\1\30\1\34\32\55\1\20\1\uffff\1\21\1" u"\44\1\55\1\uffff\1\50\1\24\1\7\1\27\1\10\1\26\2\55\1\3\2\55\1\25" u"\1\55\1\33\1\55\1\1\1\55\1\37\1\4\1\22\1\55\1\17\1\36\3\55\1\15" u"\1\43\1\16\1\47\101\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55" u"\u1040\uffff\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55" u"\u10d2\uffff\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\57\20\uffff\1\61\2\uffff\1\60"), DFA.unpack(u""), DFA.unpack(u"\1\64\6\uffff\1\62\1\63"), DFA.unpack(u"\1\66\13\uffff\1\65\1\67\1\uffff\1\70\1\uffff\1\71"), DFA.unpack(u"\1\72\1\uffff\12\74"), DFA.unpack(u"\1\75"), DFA.unpack(u"\1\101\6\uffff\1\100\3\uffff\1\77\2\uffff\1\102"), DFA.unpack(u"\1\104\1\uffff\1\105\11\uffff\1\103"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\107\26\uffff\1\106"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\111"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\112\11\uffff\1\113"), DFA.unpack(u"\1\114"), DFA.unpack(u"\1\116\2\uffff\1\120\6\uffff\1\117"), DFA.unpack(u"\1\121"), DFA.unpack(u"\1\123\7\uffff\1\125\2\uffff\1\122\2\uffff\1\124"), DFA.unpack(u"\1\127\11\uffff\1\126"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\132\3\uffff\1\131\17\uffff\1\130"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134"), DFA.unpack(u"\1\136\21\uffff\1\135"), DFA.unpack(u"\1\141\17\uffff\1\140"), DFA.unpack(u"\1\144\4\uffff\1\145\15\uffff\1\143"), DFA.unpack(u"\1\147\76\uffff\1\150"), DFA.unpack(u"\1\152"), DFA.unpack(u"\1\154"), DFA.unpack(u"\1\156"), DFA.unpack(u""), DFA.unpack(u"\1\160\20\uffff\1\161"), DFA.unpack(u"\1\74\1\uffff\10\163\2\74\12\uffff\3\74\21\uffff\1" u"\162\13\uffff\3\74\21\uffff\1\162"), DFA.unpack(u"\1\74\1\uffff\12\165\12\uffff\3\74\35\uffff\3\74"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\166"), DFA.unpack(u"\1\167"), DFA.unpack(u"\1\171\5\uffff\1\170"), DFA.unpack(u"\1\172"), DFA.unpack(u"\1\174\1\173"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\176\20\uffff\1\177"), DFA.unpack(u"\1\u0080"), DFA.unpack(u"\1\u0081"), DFA.unpack(u"\1\u0082"), DFA.unpack(u"\1\u0083"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0084"), DFA.unpack(u"\1\u0085"), DFA.unpack(u"\1\u0087\1\u0086"), DFA.unpack(u"\1\u0088"), DFA.unpack(u"\1\u0089"), DFA.unpack(u"\1\u008a"), DFA.unpack(u"\1\u008b"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u008c\2\uffff\1\u008d"), DFA.unpack(u"\1\u008f\10\uffff\1\u008e"), DFA.unpack(u"\1\u0092\23\uffff\1\u0090\3\uffff\1\u0091"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0093"), DFA.unpack(u"\1\u0094"), DFA.unpack(u"\1\u0095"), DFA.unpack(u"\1\u0096"), DFA.unpack(u"\1\u0097"), DFA.unpack(u"\1\u0098"), DFA.unpack(u"\1\u0099"), DFA.unpack(u"\1\u009a"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\24\55\1\u009b\5\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08" u"\55\u1040\uffff\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e" u"\55\u10d2\uffff\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u009d"), DFA.unpack(u"\1\u009e"), DFA.unpack(u"\1\u009f"), DFA.unpack(u"\1\u00a0"), DFA.unpack(u"\1\u00a1"), DFA.unpack(u"\1\u00a2"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00a3"), DFA.unpack(u"\1\u00a4"), DFA.unpack(u""), DFA.unpack(u"\1\74\1\uffff\10\163\2\74\12\uffff\3\74\35\uffff\3" u"\74"), DFA.unpack(u""), DFA.unpack(u"\1\74\1\uffff\12\165\12\uffff\3\74\35\uffff\3\74"), DFA.unpack(u"\1\u00a6"), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\1\u00a8"), DFA.unpack(u"\1\u00a9"), DFA.unpack(u"\1\u00ab\2\uffff\1\u00aa"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\4\55\1\u00ac\25\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08" u"\55\u1040\uffff\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e" u"\55\u10d2\uffff\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00ae"), DFA.unpack(u""), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\1\u00b0"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\1\u00b2"), DFA.unpack(u"\1\u00b3"), DFA.unpack(u"\1\u00b4"), DFA.unpack(u"\1\u00b5"), DFA.unpack(u"\1\u00b6"), DFA.unpack(u"\1\u00b7"), DFA.unpack(u"\1\u00b8"), DFA.unpack(u"\1\u00b9"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\1\u00bb"), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\1\u00bd"), DFA.unpack(u"\1\u00be"), DFA.unpack(u"\1\u00bf"), DFA.unpack(u"\1\u00c0"), DFA.unpack(u"\1\u00c1"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00c3"), DFA.unpack(u"\1\u00c4"), DFA.unpack(u"\1\u00c5"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u"\1\u00c7"), DFA.unpack(u"\1\u00c8"), DFA.unpack(u"\1\u00c9"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\1\u00cc"), DFA.unpack(u""), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00d0"), DFA.unpack(u"\1\u00d1"), DFA.unpack(u"\1\u00d2"), DFA.unpack(u"\1\u00d3"), DFA.unpack(u"\1\u00d4"), DFA.unpack(u""), DFA.unpack(u"\1\u00d5"), DFA.unpack(u"\1\u00d6"), DFA.unpack(u"\1\u00d7"), DFA.unpack(u"\1\u00d8"), DFA.unpack(u"\1\u00d9"), DFA.unpack(u"\1\u00da"), DFA.unpack(u"\1\u00db"), DFA.unpack(u""), DFA.unpack(u"\1\u00dc"), DFA.unpack(u"\1\u00dd"), DFA.unpack(u"\1\u00de"), DFA.unpack(u"\1\u00df"), DFA.unpack(u"\1\u00e0"), DFA.unpack(u"\1\u00e1"), DFA.unpack(u"\1\u00e2"), DFA.unpack(u"\1\u00e3"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00e5"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00e7"), DFA.unpack(u"\1\u00e8"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00ec"), DFA.unpack(u"\1\u00ed"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\u00f0"), DFA.unpack(u"\1\u00f1"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00f3"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u00f5"), DFA.unpack(u"\1\u00f6"), DFA.unpack(u""), DFA.unpack(u"\1\u00f7"), DFA.unpack(u"\1\u00f8"), DFA.unpack(u"\1\u00f9"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\u00fb"), DFA.unpack(u"\1\u00fc"), DFA.unpack(u"\1\u00fd"), DFA.unpack(u"\1\u00fe"), DFA.unpack(u"\1\u00ff"), DFA.unpack(u"\1\u0100"), DFA.unpack(u"\1\u0101"), DFA.unpack(u"\1\u0102"), DFA.unpack(u"\1\u0103"), DFA.unpack(u"\1\u0104"), DFA.unpack(u"\1\u0105"), DFA.unpack(u"\1\u0106"), DFA.unpack(u"\1\u0107"), DFA.unpack(u"\1\u0108"), DFA.unpack(u"\1\u0109"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u010c"), DFA.unpack(u"\1\u010d"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\u0110"), DFA.unpack(u"\1\u0111"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0112"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\22\55\1\u0113\7\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08" u"\55\u1040\uffff\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e" u"\55\u10d2\uffff\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0115"), DFA.unpack(u"\1\u0116"), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\13\55\1\u011a\16\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08" u"\55\u1040\uffff\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e" u"\55\u10d2\uffff\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u011c"), DFA.unpack(u"\1\u011d"), DFA.unpack(u""), DFA.unpack(u"\1\u011e"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0120"), DFA.unpack(u"\1\u0121"), DFA.unpack(u"\1\u0122"), DFA.unpack(u"\1\u0123"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0125"), DFA.unpack(u"\1\u0126"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0128"), DFA.unpack(u"\1\u0129"), DFA.unpack(u"\1\u012a"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u012c"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u012e"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u012f"), DFA.unpack(u"\1\u0130"), DFA.unpack(u"\1\u0131"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\u0133"), DFA.unpack(u"\1\u0134"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0135"), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0137"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u013a"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\u013d"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\u013f"), DFA.unpack(u"\1\u0140"), DFA.unpack(u"\1\u0141"), DFA.unpack(u""), DFA.unpack(u"\1\u0142"), DFA.unpack(u""), DFA.unpack(u"\1\u0143"), DFA.unpack(u"\1\u0144"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0146"), DFA.unpack(u""), DFA.unpack(u"\1\u0147"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u014b"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u014c"), DFA.unpack(u""), DFA.unpack(u"\1\u014d"), DFA.unpack(u"\1\u014e"), DFA.unpack(u"\1\u014f"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0151"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0154"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0157"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u0159"), DFA.unpack(u""), DFA.unpack(u"\1\u015a"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u""), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"\1\u015e"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u015f"), DFA.unpack(u"\1\55\13\uffff\12\55\7\uffff\32\55\4\uffff\1\55\1\uffff" u"\32\55\105\uffff\27\55\1\uffff\37\55\1\uffff\u1f08\55\u1040\uffff" u"\u0150\55\u0170\uffff\u0080\55\u0080\uffff\u092e\55\u10d2\uffff" u"\u5200\55\u5900\uffff\u0200\55"), DFA.unpack(u"") ] # class definition for DFA #29 DFA29 = DFA def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(JavaLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "leriomaggio/code-coherence-evaluation-tool", "path": "code_comments_coherence/source_code_analysis/code_analysis/JavaLexer.py", "copies": "1", "size": "118769", "license": "bsd-3-clause", "hash": -5156789610085549000, "line_mean": 22.6638772664, "line_max": 988, "alpha_frac": 0.4466822151, "autogenerated": false, "ratio": 2.8729801644895985, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.38196623795895984, "avg_score": null, "num_lines": null }
# $ANTLR 3.4 Eval.g 2012-12-09 16:07:29 import sys from antlr3 import * from antlr3.tree import * from antlr3.compat import set, frozenset from engine import CpyBuilder # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__68=68 T__69=69 T__70=70 T__71=71 T__72=72 T__73=73 T__74=74 T__75=75 T__76=76 T__77=77 T__78=78 T__79=79 T__80=80 T__81=81 T__82=82 T__83=83 T__84=84 T__85=85 T__86=86 T__87=87 T__88=88 T__89=89 T__90=90 T__91=91 T__92=92 T__93=93 T__94=94 T__95=95 T__96=96 T__97=97 T__98=98 T__99=99 T__100=100 T__101=101 T__102=102 T__103=103 T__104=104 T__105=105 T__106=106 T__107=107 T__108=108 T__109=109 T__110=110 T__111=111 T__112=112 T__113=113 T__114=114 T__115=115 T__116=116 T__117=117 T__118=118 T__119=119 T__120=120 T__121=121 T__122=122 T__123=123 T__124=124 T__125=125 T__126=126 T__127=127 T__128=128 T__129=129 T__130=130 T__131=131 T__132=132 T__133=133 T__134=134 T__135=135 T__136=136 ALPHA=4 ARRAY=5 ASSIGN=6 BLOCK=7 BOOL=8 BREAK=9 CALL=10 CASE=11 CATCH=12 CLASS=13 COMMENT=14 CONSTRUCTOR=15 CONTINUE=16 DEFAULT=17 DIGIT=18 DOUBLE_QUOTE_CHARS=19 DO_WHILE=20 EACH=21 EACH_VAL=22 ELSE=23 ELSE_IF=24 EMPTY_LINE=25 EXEC_LIST=26 EXEC_STMT=27 EXPR_LIST=28 FINALLY=29 FLOAT=30 FOR=31 FOREACH=32 FUNCTION=33 ID=34 ID_LIST=35 IF=36 IMPORT=37 INDEX=38 INT=39 LINECOMMENT=40 MEMBER=41 MODULE=42 NEGATIVE=43 NEW=44 NEWLINE=45 NOP=46 NULL=47 OBJECT=48 OP_ASSIGN=49 PARAMS=50 POST_DEC=51 POST_INC=52 PRE_DEC=53 PRE_INC=54 PRINT=55 PRINTF=56 RETURN=57 SINGLE_QUOTE_CHARS=58 SLICE=59 SPRINTF=60 STRING=61 SWITCH=62 THROW=63 TRY=64 VAR=65 WHILE=66 WS=67 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "ALPHA", "ARRAY", "ASSIGN", "BLOCK", "BOOL", "BREAK", "CALL", "CASE", "CATCH", "CLASS", "COMMENT", "CONSTRUCTOR", "CONTINUE", "DEFAULT", "DIGIT", "DOUBLE_QUOTE_CHARS", "DO_WHILE", "EACH", "EACH_VAL", "ELSE", "ELSE_IF", "EMPTY_LINE", "EXEC_LIST", "EXEC_STMT", "EXPR_LIST", "FINALLY", "FLOAT", "FOR", "FOREACH", "FUNCTION", "ID", "ID_LIST", "IF", "IMPORT", "INDEX", "INT", "LINECOMMENT", "MEMBER", "MODULE", "NEGATIVE", "NEW", "NEWLINE", "NOP", "NULL", "OBJECT", "OP_ASSIGN", "PARAMS", "POST_DEC", "POST_INC", "PRE_DEC", "PRE_INC", "PRINT", "PRINTF", "RETURN", "SINGLE_QUOTE_CHARS", "SLICE", "SPRINTF", "STRING", "SWITCH", "THROW", "TRY", "VAR", "WHILE", "WS", "'!'", "'!='", "'%'", "'%='", "'&&'", "'&'", "'&='", "'('", "')'", "'*'", "'*='", "'+'", "'++'", "'+='", "','", "'-'", "'--'", "'-='", "'.'", "'.*'", "'..'", "'/'", "'/='", "':'", "';'", "'<'", "'<='", "'='", "'=='", "'=>'", "'>'", "'>='", "'['", "']'", "'^'", "'^='", "'as'", "'break'", "'case'", "'catch'", "'class'", "'continue'", "'default'", "'do'", "'else'", "'extends'", "'finally'", "'for'", "'foreach'", "'function'", "'if'", "'import'", "'init'", "'new'", "'print'", "'printf'", "'public'", "'return'", "'sprintf'", "'static'", "'switch'", "'throw'", "'try'", "'while'", "'{'", "'|'", "'|='", "'||'", "'}'" ] class Eval(TreeParser): grammarFileName = "Eval.g" api_version = 1 tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(Eval, self).__init__(input, state, *args, **kwargs) self.dfa4 = self.DFA4( self, 4, eot = self.DFA4_eot, eof = self.DFA4_eof, min = self.DFA4_min, max = self.DFA4_max, accept = self.DFA4_accept, special = self.DFA4_special, transition = self.DFA4_transition ) self.delegates = [] # $ANTLR start "prog" # Eval.g:21:1: prog[cpy] : ( stmt )* ; def prog(self, cpy): self.cpy = cpy try: try: # Eval.g:28:2: ( ( stmt )* ) # Eval.g:28:4: ( stmt )* pass # Eval.g:28:4: ( stmt )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == BREAK or LA1_0 == CLASS or LA1_0 == CONTINUE or LA1_0 == DO_WHILE or LA1_0 == EXEC_STMT or (FOR <= LA1_0 <= FUNCTION) or (IF <= LA1_0 <= IMPORT) or (PRINT <= LA1_0 <= RETURN) or (SWITCH <= LA1_0 <= TRY) or LA1_0 == WHILE) : alt1 = 1 if alt1 == 1: # Eval.g:28:4: stmt pass self._state.following.append(self.FOLLOW_stmt_in_prog69) self.stmt() self._state.following.pop() else: break #loop1 #action start self.cpy.close() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "prog" # $ANTLR start "stmt" # Eval.g:31:1: stmt : ( import_stmt | exec_stmt | print_stmt | printf_stmt | break_stmt | continue_stmt | return_stmt | if_stmt | while_stmt | do_while_stmt | switch_stmt | throw_stmt | try_stmt | func_decl | class_decl | for_stmt | foreach_stmt ); def stmt(self, ): try: try: # Eval.g:32:2: ( import_stmt | exec_stmt | print_stmt | printf_stmt | break_stmt | continue_stmt | return_stmt | if_stmt | while_stmt | do_while_stmt | switch_stmt | throw_stmt | try_stmt | func_decl | class_decl | for_stmt | foreach_stmt ) alt2 = 17 LA2 = self.input.LA(1) if LA2 == IMPORT: alt2 = 1 elif LA2 == EXEC_STMT: alt2 = 2 elif LA2 == PRINT: alt2 = 3 elif LA2 == PRINTF: alt2 = 4 elif LA2 == BREAK: alt2 = 5 elif LA2 == CONTINUE: alt2 = 6 elif LA2 == RETURN: alt2 = 7 elif LA2 == IF: alt2 = 8 elif LA2 == WHILE: alt2 = 9 elif LA2 == DO_WHILE: alt2 = 10 elif LA2 == SWITCH: alt2 = 11 elif LA2 == THROW: alt2 = 12 elif LA2 == TRY: alt2 = 13 elif LA2 == FUNCTION: alt2 = 14 elif LA2 == CLASS: alt2 = 15 elif LA2 == FOR: alt2 = 16 elif LA2 == FOREACH: alt2 = 17 else: nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # Eval.g:32:4: import_stmt pass self._state.following.append(self.FOLLOW_import_stmt_in_stmt81) self.import_stmt() self._state.following.pop() elif alt2 == 2: # Eval.g:33:4: exec_stmt pass self._state.following.append(self.FOLLOW_exec_stmt_in_stmt86) self.exec_stmt() self._state.following.pop() elif alt2 == 3: # Eval.g:34:4: print_stmt pass self._state.following.append(self.FOLLOW_print_stmt_in_stmt91) self.print_stmt() self._state.following.pop() elif alt2 == 4: # Eval.g:34:17: printf_stmt pass self._state.following.append(self.FOLLOW_printf_stmt_in_stmt95) self.printf_stmt() self._state.following.pop() elif alt2 == 5: # Eval.g:35:4: break_stmt pass self._state.following.append(self.FOLLOW_break_stmt_in_stmt100) self.break_stmt() self._state.following.pop() elif alt2 == 6: # Eval.g:36:4: continue_stmt pass self._state.following.append(self.FOLLOW_continue_stmt_in_stmt105) self.continue_stmt() self._state.following.pop() elif alt2 == 7: # Eval.g:37:4: return_stmt pass self._state.following.append(self.FOLLOW_return_stmt_in_stmt110) self.return_stmt() self._state.following.pop() elif alt2 == 8: # Eval.g:38:4: if_stmt pass self._state.following.append(self.FOLLOW_if_stmt_in_stmt115) self.if_stmt() self._state.following.pop() elif alt2 == 9: # Eval.g:39:4: while_stmt pass self._state.following.append(self.FOLLOW_while_stmt_in_stmt120) self.while_stmt() self._state.following.pop() elif alt2 == 10: # Eval.g:40:4: do_while_stmt pass self._state.following.append(self.FOLLOW_do_while_stmt_in_stmt125) self.do_while_stmt() self._state.following.pop() elif alt2 == 11: # Eval.g:41:4: switch_stmt pass self._state.following.append(self.FOLLOW_switch_stmt_in_stmt130) self.switch_stmt() self._state.following.pop() elif alt2 == 12: # Eval.g:42:4: throw_stmt pass self._state.following.append(self.FOLLOW_throw_stmt_in_stmt135) self.throw_stmt() self._state.following.pop() elif alt2 == 13: # Eval.g:43:4: try_stmt pass self._state.following.append(self.FOLLOW_try_stmt_in_stmt140) self.try_stmt() self._state.following.pop() elif alt2 == 14: # Eval.g:44:4: func_decl pass self._state.following.append(self.FOLLOW_func_decl_in_stmt145) self.func_decl() self._state.following.pop() elif alt2 == 15: # Eval.g:45:4: class_decl pass self._state.following.append(self.FOLLOW_class_decl_in_stmt150) self.class_decl() self._state.following.pop() elif alt2 == 16: # Eval.g:46:4: for_stmt pass self._state.following.append(self.FOLLOW_for_stmt_in_stmt155) self.for_stmt() self._state.following.pop() elif alt2 == 17: # Eval.g:47:4: foreach_stmt pass self._state.following.append(self.FOLLOW_foreach_stmt_in_stmt160) self.foreach_stmt() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "stmt" # $ANTLR start "block" # Eval.g:52:1: block : ^( BLOCK ( stmt )* ) ; def block(self, ): self.cpy.block_enter() try: try: # Eval.g:59:2: ( ^( BLOCK ( stmt )* ) ) # Eval.g:59:4: ^( BLOCK ( stmt )* ) pass self.match(self.input, BLOCK, self.FOLLOW_BLOCK_in_block185) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:59:12: ( stmt )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == BREAK or LA3_0 == CLASS or LA3_0 == CONTINUE or LA3_0 == DO_WHILE or LA3_0 == EXEC_STMT or (FOR <= LA3_0 <= FUNCTION) or (IF <= LA3_0 <= IMPORT) or (PRINT <= LA3_0 <= RETURN) or (SWITCH <= LA3_0 <= TRY) or LA3_0 == WHILE) : alt3 = 1 if alt3 == 1: # Eval.g:59:12: stmt pass self._state.following.append(self.FOLLOW_stmt_in_block187) self.stmt() self._state.following.pop() else: break #loop3 self.match(self.input, UP, None) #action start self.cpy.block_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "block" # $ANTLR start "import_stmt" # Eval.g:62:1: import_stmt : ^( IMPORT (a= module |b= module '.*' )+ ) ; def import_stmt(self, ): a = None b = None try: try: # Eval.g:63:2: ( ^( IMPORT (a= module |b= module '.*' )+ ) ) # Eval.g:63:4: ^( IMPORT (a= module |b= module '.*' )+ ) pass self.match(self.input, IMPORT, self.FOLLOW_IMPORT_in_import_stmt201) self.match(self.input, DOWN, None) # Eval.g:64:3: (a= module |b= module '.*' )+ cnt4 = 0 while True: #loop4 alt4 = 3 alt4 = self.dfa4.predict(self.input) if alt4 == 1: # Eval.g:64:5: a= module pass self._state.following.append(self.FOLLOW_module_in_import_stmt209) a = self.module() self._state.following.pop() #action start self.cpy.op_import(a, None) #action end elif alt4 == 2: # Eval.g:66:5: b= module '.*' pass self._state.following.append(self.FOLLOW_module_in_import_stmt222) b = self.module() self._state.following.pop() self.match(self.input, 87, self.FOLLOW_87_in_import_stmt224) #action start self.cpy.op_import(b, '*') #action end else: if cnt4 >= 1: break #loop4 eee = EarlyExitException(4, self.input) raise eee cnt4 += 1 self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "import_stmt" # $ANTLR start "exec_stmt" # Eval.g:72:1: exec_stmt : ^( EXEC_STMT exec_list ) ; def exec_stmt(self, ): exec_list1 = None try: try: # Eval.g:73:2: ( ^( EXEC_STMT exec_list ) ) # Eval.g:73:4: ^( EXEC_STMT exec_list ) pass self.match(self.input, EXEC_STMT, self.FOLLOW_EXEC_STMT_in_exec_stmt250) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_exec_list_in_exec_stmt252) exec_list1 = self.exec_list() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.stmt(exec_list1) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "exec_stmt" # $ANTLR start "exec_expr" # Eval.g:76:1: exec_expr returns [text] : ( member_expr | ^( ASSIGN member_expr op= ( '=' | '+=' | '-=' | '*=' | '/=' | '%=' | '&=' | '^=' | '|=' ) expr ) | ^( POST_INC member_expr ) | ^( POST_DEC member_expr ) | ^( PRE_INC member_expr ) | ^( PRE_DEC member_expr ) ); def exec_expr(self, ): text = None op = None member_expr2 = None member_expr3 = None expr4 = None member_expr5 = None member_expr6 = None member_expr7 = None member_expr8 = None try: try: # Eval.g:77:2: ( member_expr | ^( ASSIGN member_expr op= ( '=' | '+=' | '-=' | '*=' | '/=' | '%=' | '&=' | '^=' | '|=' ) expr ) | ^( POST_INC member_expr ) | ^( POST_DEC member_expr ) | ^( PRE_INC member_expr ) | ^( PRE_DEC member_expr ) ) alt5 = 6 LA5 = self.input.LA(1) if LA5 == MEMBER: alt5 = 1 elif LA5 == ASSIGN: alt5 = 2 elif LA5 == POST_INC: alt5 = 3 elif LA5 == POST_DEC: alt5 = 4 elif LA5 == PRE_INC: alt5 = 5 elif LA5 == PRE_DEC: alt5 = 6 else: nvae = NoViableAltException("", 5, 0, self.input) raise nvae if alt5 == 1: # Eval.g:77:4: member_expr pass self._state.following.append(self.FOLLOW_member_expr_in_exec_expr270) member_expr2 = self.member_expr() self._state.following.pop() #action start text = member_expr2 #action end elif alt5 == 2: # Eval.g:79:4: ^( ASSIGN member_expr op= ( '=' | '+=' | '-=' | '*=' | '/=' | '%=' | '&=' | '^=' | '|=' ) expr ) pass self.match(self.input, ASSIGN, self.FOLLOW_ASSIGN_in_exec_expr280) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr282) member_expr3 = self.member_expr() self._state.following.pop() op = self.input.LT(1) if self.input.LA(1) == 71 or self.input.LA(1) == 74 or self.input.LA(1) == 78 or self.input.LA(1) == 81 or self.input.LA(1) == 85 or self.input.LA(1) == 90 or self.input.LA(1) == 95 or self.input.LA(1) == 103 or self.input.LA(1) == 134: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_expr_in_exec_expr306) expr4 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_assign(member_expr3, expr4, op.text) #action end elif alt5 == 3: # Eval.g:81:4: ^( POST_INC member_expr ) pass self.match(self.input, POST_INC, self.FOLLOW_POST_INC_in_exec_expr317) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr319) member_expr5 = self.member_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_inc(member_expr5) #action end elif alt5 == 4: # Eval.g:83:4: ^( POST_DEC member_expr ) pass self.match(self.input, POST_DEC, self.FOLLOW_POST_DEC_in_exec_expr330) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr332) member_expr6 = self.member_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_dec(member_expr6) #action end elif alt5 == 5: # Eval.g:85:4: ^( PRE_INC member_expr ) pass self.match(self.input, PRE_INC, self.FOLLOW_PRE_INC_in_exec_expr343) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr345) member_expr7 = self.member_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_inc(member_expr7) #action end elif alt5 == 6: # Eval.g:87:4: ^( PRE_DEC member_expr ) pass self.match(self.input, PRE_DEC, self.FOLLOW_PRE_DEC_in_exec_expr356) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr358) member_expr8 = self.member_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_dec(member_expr8) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "exec_expr" # $ANTLR start "exec_list" # Eval.g:90:1: exec_list returns [text] : ^( EXEC_LIST ( exec_expr )+ ) ; def exec_list(self, ): text = None exec_expr9 = None ps = [] try: try: # Eval.g:92:2: ( ^( EXEC_LIST ( exec_expr )+ ) ) # Eval.g:92:4: ^( EXEC_LIST ( exec_expr )+ ) pass self.match(self.input, EXEC_LIST, self.FOLLOW_EXEC_LIST_in_exec_list382) self.match(self.input, DOWN, None) # Eval.g:92:16: ( exec_expr )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == ASSIGN or LA6_0 == MEMBER or (POST_DEC <= LA6_0 <= PRE_INC)) : alt6 = 1 if alt6 == 1: # Eval.g:92:17: exec_expr pass self._state.following.append(self.FOLLOW_exec_expr_in_exec_list385) exec_expr9 = self.exec_expr() self._state.following.pop() #action start ps.append(exec_expr9) #action end else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 self.match(self.input, UP, None) #action start text = ', '.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "exec_list" # $ANTLR start "printf_stmt" # Eval.g:96:1: printf_stmt : ^( PRINTF expr ( expr_list )? ) ; def printf_stmt(self, ): expr10 = None expr_list11 = None try: try: # Eval.g:97:2: ( ^( PRINTF expr ( expr_list )? ) ) # Eval.g:97:4: ^( PRINTF expr ( expr_list )? ) pass self.match(self.input, PRINTF, self.FOLLOW_PRINTF_in_printf_stmt408) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_printf_stmt410) expr10 = self.expr() self._state.following.pop() # Eval.g:97:18: ( expr_list )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == EXPR_LIST) : alt7 = 1 if alt7 == 1: # Eval.g:97:18: expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_printf_stmt412) expr_list11 = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_printf(expr10, expr_list11) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "printf_stmt" # $ANTLR start "print_stmt" # Eval.g:100:1: print_stmt : ^( PRINT expr_list ) ; def print_stmt(self, ): expr_list12 = None try: try: # Eval.g:101:2: ( ^( PRINT expr_list ) ) # Eval.g:101:4: ^( PRINT expr_list ) pass self.match(self.input, PRINT, self.FOLLOW_PRINT_in_print_stmt429) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_list_in_print_stmt431) expr_list12 = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_print(expr_list12) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "print_stmt" # $ANTLR start "break_stmt" # Eval.g:107:1: break_stmt : BREAK ; def break_stmt(self, ): try: try: # Eval.g:108:2: ( BREAK ) # Eval.g:108:4: BREAK pass self.match(self.input, BREAK, self.FOLLOW_BREAK_in_break_stmt451) #action start self.cpy.op_break() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "break_stmt" # $ANTLR start "continue_stmt" # Eval.g:111:1: continue_stmt : CONTINUE ; def continue_stmt(self, ): try: try: # Eval.g:112:2: ( CONTINUE ) # Eval.g:112:4: CONTINUE pass self.match(self.input, CONTINUE, self.FOLLOW_CONTINUE_in_continue_stmt465) #action start self.cpy.op_continue() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "continue_stmt" # $ANTLR start "return_stmt" # Eval.g:115:1: return_stmt : ^( RETURN ( expr )? ) ; def return_stmt(self, ): expr13 = None try: try: # Eval.g:116:2: ( ^( RETURN ( expr )? ) ) # Eval.g:116:4: ^( RETURN ( expr )? ) pass self.match(self.input, RETURN, self.FOLLOW_RETURN_in_return_stmt480) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:116:13: ( expr )? alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == ARRAY or LA8_0 == BOOL or LA8_0 == FLOAT or LA8_0 == INT or LA8_0 == MEMBER or (NEGATIVE <= LA8_0 <= NEW) or (NULL <= LA8_0 <= OBJECT) or (SPRINTF <= LA8_0 <= STRING) or (68 <= LA8_0 <= 70) or (72 <= LA8_0 <= 73) or LA8_0 == 77 or LA8_0 == 79 or LA8_0 == 83 or LA8_0 == 89 or (93 <= LA8_0 <= 94) or LA8_0 == 96 or (98 <= LA8_0 <= 99) or LA8_0 == 102 or LA8_0 == 133 or LA8_0 == 135) : alt8 = 1 if alt8 == 1: # Eval.g:116:13: expr pass self._state.following.append(self.FOLLOW_expr_in_return_stmt482) expr13 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_return(expr13) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "return_stmt" # $ANTLR start "if_stmt" # Eval.g:121:1: if_stmt : if_clause ( else_if_clause )* ( else_clause )? ; def if_stmt(self, ): self.cpy.if_enter() try: try: # Eval.g:128:2: ( if_clause ( else_if_clause )* ( else_clause )? ) # Eval.g:128:4: if_clause ( else_if_clause )* ( else_clause )? pass self._state.following.append(self.FOLLOW_if_clause_in_if_stmt510) self.if_clause() self._state.following.pop() # Eval.g:128:14: ( else_if_clause )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == ELSE_IF) : alt9 = 1 if alt9 == 1: # Eval.g:128:14: else_if_clause pass self._state.following.append(self.FOLLOW_else_if_clause_in_if_stmt512) self.else_if_clause() self._state.following.pop() else: break #loop9 # Eval.g:128:30: ( else_clause )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == ELSE) : alt10 = 1 if alt10 == 1: # Eval.g:128:30: else_clause pass self._state.following.append(self.FOLLOW_else_clause_in_if_stmt515) self.else_clause() self._state.following.pop() #action start self.cpy.if_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "if_stmt" # $ANTLR start "if_clause" # Eval.g:130:1: if_clause : ^( IF expr block ) ; def if_clause(self, ): expr14 = None try: try: # Eval.g:131:2: ( ^( IF expr block ) ) # Eval.g:131:4: ^( IF expr block ) pass self.match(self.input, IF, self.FOLLOW_IF_in_if_clause527) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_if_clause529) expr14 = self.expr() self._state.following.pop() #action start self.cpy.op_if(expr14) #action end self._state.following.append(self.FOLLOW_block_in_if_clause533) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "if_clause" # $ANTLR start "else_if_clause" # Eval.g:133:1: else_if_clause : ^( ELSE_IF if_clause ) ; def else_if_clause(self, ): try: try: # Eval.g:134:2: ( ^( ELSE_IF if_clause ) ) # Eval.g:134:4: ^( ELSE_IF if_clause ) pass self.match(self.input, ELSE_IF, self.FOLLOW_ELSE_IF_in_else_if_clause545) #action start self.cpy.op_else_if() #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_if_clause_in_else_if_clause549) self.if_clause() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "else_if_clause" # $ANTLR start "else_clause" # Eval.g:136:1: else_clause : ^( ELSE block ) ; def else_clause(self, ): try: try: # Eval.g:137:2: ( ^( ELSE block ) ) # Eval.g:137:4: ^( ELSE block ) pass self.match(self.input, ELSE, self.FOLLOW_ELSE_in_else_clause561) #action start self.cpy.op_else() #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_block_in_else_clause565) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "else_clause" # $ANTLR start "while_stmt" # Eval.g:141:1: while_stmt : ^( WHILE expr block ) ; def while_stmt(self, ): expr15 = None try: try: # Eval.g:142:2: ( ^( WHILE expr block ) ) # Eval.g:142:4: ^( WHILE expr block ) pass self.match(self.input, WHILE, self.FOLLOW_WHILE_in_while_stmt579) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_while_stmt581) expr15 = self.expr() self._state.following.pop() #action start self.cpy.op_while(expr15) #action end self._state.following.append(self.FOLLOW_block_in_while_stmt585) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "while_stmt" # $ANTLR start "do_while_stmt" # Eval.g:145:1: do_while_stmt : ^( DO_WHILE block expr ) ; def do_while_stmt(self, ): expr16 = None try: try: # Eval.g:146:2: ( ^( DO_WHILE block expr ) ) # Eval.g:146:4: ^( DO_WHILE block expr ) pass self.match(self.input, DO_WHILE, self.FOLLOW_DO_WHILE_in_do_while_stmt598) #action start self.cpy.op_do_while_enter() #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_block_in_do_while_stmt604) self.block() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_do_while_stmt608) expr16 = self.expr() self._state.following.pop() #action start self.cpy.op_do_while_leave(expr16) #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "do_while_stmt" # $ANTLR start "switch_stmt" # Eval.g:153:1: switch_stmt : ^( SWITCH expr case_block ) ; def switch_stmt(self, ): expr17 = None try: try: # Eval.g:154:2: ( ^( SWITCH expr case_block ) ) # Eval.g:154:4: ^( SWITCH expr case_block ) pass self.match(self.input, SWITCH, self.FOLLOW_SWITCH_in_switch_stmt627) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_switch_stmt629) expr17 = self.expr() self._state.following.pop() #action start self.cpy.op_switch_enter(expr17) #action end self._state.following.append(self.FOLLOW_case_block_in_switch_stmt633) self.case_block() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_switch_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "switch_stmt" # $ANTLR start "case_block" # Eval.g:157:1: case_block : '{' ( case_clause )+ ( default_clause )? '}' ; def case_block(self, ): try: try: # Eval.g:158:2: ( '{' ( case_clause )+ ( default_clause )? '}' ) # Eval.g:158:4: '{' ( case_clause )+ ( default_clause )? '}' pass self.match(self.input, 132, self.FOLLOW_132_in_case_block648) # Eval.g:158:8: ( case_clause )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == CASE) : alt11 = 1 if alt11 == 1: # Eval.g:158:9: case_clause pass self._state.following.append(self.FOLLOW_case_clause_in_case_block651) self.case_clause() self._state.following.pop() else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 # Eval.g:158:23: ( default_clause )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == DEFAULT) : alt12 = 1 if alt12 == 1: # Eval.g:158:24: default_clause pass self._state.following.append(self.FOLLOW_default_clause_in_case_block656) self.default_clause() self._state.following.pop() self.match(self.input, 136, self.FOLLOW_136_in_case_block660) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "case_block" # $ANTLR start "case_clause" # Eval.g:160:1: case_clause : ^( CASE ( case_test )+ ( stmt )* break_stmt ) ; def case_clause(self, ): self.cpy.op_case_enter() try: try: # Eval.g:162:2: ( ^( CASE ( case_test )+ ( stmt )* break_stmt ) ) # Eval.g:162:4: ^( CASE ( case_test )+ ( stmt )* break_stmt ) pass self.match(self.input, CASE, self.FOLLOW_CASE_in_case_clause676) self.match(self.input, DOWN, None) # Eval.g:162:11: ( case_test )+ cnt13 = 0 while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == CASE) : alt13 = 1 if alt13 == 1: # Eval.g:162:11: case_test pass self._state.following.append(self.FOLLOW_case_test_in_case_clause678) self.case_test() self._state.following.pop() else: if cnt13 >= 1: break #loop13 eee = EarlyExitException(13, self.input) raise eee cnt13 += 1 #action start self.cpy.op_case() #action end # Eval.g:162:43: ( stmt )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == BREAK) : LA14_1 = self.input.LA(2) if (LA14_1 == BREAK or LA14_1 == CLASS or LA14_1 == CONTINUE or LA14_1 == DO_WHILE or LA14_1 == EXEC_STMT or (FOR <= LA14_1 <= FUNCTION) or (IF <= LA14_1 <= IMPORT) or (PRINT <= LA14_1 <= RETURN) or (SWITCH <= LA14_1 <= TRY) or LA14_1 == WHILE) : alt14 = 1 elif (LA14_0 == CLASS or LA14_0 == CONTINUE or LA14_0 == DO_WHILE or LA14_0 == EXEC_STMT or (FOR <= LA14_0 <= FUNCTION) or (IF <= LA14_0 <= IMPORT) or (PRINT <= LA14_0 <= RETURN) or (SWITCH <= LA14_0 <= TRY) or LA14_0 == WHILE) : alt14 = 1 if alt14 == 1: # Eval.g:162:43: stmt pass self._state.following.append(self.FOLLOW_stmt_in_case_clause683) self.stmt() self._state.following.pop() else: break #loop14 self._state.following.append(self.FOLLOW_break_stmt_in_case_clause686) self.break_stmt() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_case_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "case_clause" # $ANTLR start "case_test" # Eval.g:165:1: case_test : ^( CASE expr ) ; def case_test(self, ): expr18 = None try: try: # Eval.g:166:2: ( ^( CASE expr ) ) # Eval.g:166:4: ^( CASE expr ) pass self.match(self.input, CASE, self.FOLLOW_CASE_in_case_test702) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_case_test704) expr18 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_case_test(expr18) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "case_test" # $ANTLR start "default_clause" # Eval.g:169:1: default_clause : ^( DEFAULT ( stmt )* ) ; def default_clause(self, ): self.cpy.op_default_enter() try: try: # Eval.g:173:2: ( ^( DEFAULT ( stmt )* ) ) # Eval.g:173:4: ^( DEFAULT ( stmt )* ) pass self.match(self.input, DEFAULT, self.FOLLOW_DEFAULT_in_default_clause725) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:173:14: ( stmt )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == BREAK or LA15_0 == CLASS or LA15_0 == CONTINUE or LA15_0 == DO_WHILE or LA15_0 == EXEC_STMT or (FOR <= LA15_0 <= FUNCTION) or (IF <= LA15_0 <= IMPORT) or (PRINT <= LA15_0 <= RETURN) or (SWITCH <= LA15_0 <= TRY) or LA15_0 == WHILE) : alt15 = 1 if alt15 == 1: # Eval.g:173:14: stmt pass self._state.following.append(self.FOLLOW_stmt_in_default_clause727) self.stmt() self._state.following.pop() else: break #loop15 self.match(self.input, UP, None) #action start self.cpy.op_default_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "default_clause" # $ANTLR start "for_stmt" # Eval.g:178:1: for_stmt : ^( FOR (a= exec_list )? expr block (b= exec_list )? ) ; def for_stmt(self, ): a = None b = None expr19 = None try: try: # Eval.g:179:2: ( ^( FOR (a= exec_list )? expr block (b= exec_list )? ) ) # Eval.g:179:4: ^( FOR (a= exec_list )? expr block (b= exec_list )? ) pass self.match(self.input, FOR, self.FOLLOW_FOR_in_for_stmt746) self.match(self.input, DOWN, None) # Eval.g:179:10: (a= exec_list )? alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == EXEC_LIST) : alt16 = 1 if alt16 == 1: # Eval.g:179:11: a= exec_list pass self._state.following.append(self.FOLLOW_exec_list_in_for_stmt751) a = self.exec_list() self._state.following.pop() #action start self.cpy.stmt(a) #action end self._state.following.append(self.FOLLOW_expr_in_for_stmt759) expr19 = self.expr() self._state.following.pop() #action start self.cpy.op_while(expr19) #action end self._state.following.append(self.FOLLOW_block_in_for_stmt765) self.block() self._state.following.pop() #action start self.cpy.block_enter() #action end # Eval.g:183:3: (b= exec_list )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == EXEC_LIST) : alt17 = 1 if alt17 == 1: # Eval.g:183:4: b= exec_list pass self._state.following.append(self.FOLLOW_exec_list_in_for_stmt776) b = self.exec_list() self._state.following.pop() #action start self.cpy.stmt(b) #action end #action start self.cpy.block_leave() #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "for_stmt" # $ANTLR start "foreach_stmt" # Eval.g:188:1: foreach_stmt : ^( FOREACH expr ( ^( EACH k= ID v= each_val ) | ^( EACH v= each_val ) ) block ) ; def foreach_stmt(self, ): k = None v = None expr20 = None try: try: # Eval.g:189:2: ( ^( FOREACH expr ( ^( EACH k= ID v= each_val ) | ^( EACH v= each_val ) ) block ) ) # Eval.g:189:4: ^( FOREACH expr ( ^( EACH k= ID v= each_val ) | ^( EACH v= each_val ) ) block ) pass self.match(self.input, FOREACH, self.FOLLOW_FOREACH_in_foreach_stmt800) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_foreach_stmt802) expr20 = self.expr() self._state.following.pop() # Eval.g:190:3: ( ^( EACH k= ID v= each_val ) | ^( EACH v= each_val ) ) alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == EACH) : LA18_1 = self.input.LA(2) if (LA18_1 == 2) : LA18_2 = self.input.LA(3) if (LA18_2 == ID) : alt18 = 1 elif (LA18_2 == EACH_VAL) : alt18 = 2 else: nvae = NoViableAltException("", 18, 2, self.input) raise nvae else: nvae = NoViableAltException("", 18, 1, self.input) raise nvae else: nvae = NoViableAltException("", 18, 0, self.input) raise nvae if alt18 == 1: # Eval.g:190:5: ^( EACH k= ID v= each_val ) pass self.match(self.input, EACH, self.FOLLOW_EACH_in_foreach_stmt809) self.match(self.input, DOWN, None) k = self.match(self.input, ID, self.FOLLOW_ID_in_foreach_stmt813) self._state.following.append(self.FOLLOW_each_val_in_foreach_stmt817) v = self.each_val() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_foreach(expr20, k.text, v) #action end elif alt18 == 2: # Eval.g:192:5: ^( EACH v= each_val ) pass self.match(self.input, EACH, self.FOLLOW_EACH_in_foreach_stmt830) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_each_val_in_foreach_stmt834) v = self.each_val() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_foreach(expr20, None, v) #action end self._state.following.append(self.FOLLOW_block_in_foreach_stmt848) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "foreach_stmt" # $ANTLR start "each_val" # Eval.g:198:1: each_val returns [text] : ^( EACH_VAL ( ID )+ ) ; def each_val(self, ): text = None ID21 = None ps = [] try: try: # Eval.g:200:2: ( ^( EACH_VAL ( ID )+ ) ) # Eval.g:200:4: ^( EACH_VAL ( ID )+ ) pass self.match(self.input, EACH_VAL, self.FOLLOW_EACH_VAL_in_each_val871) self.match(self.input, DOWN, None) # Eval.g:200:15: ( ID )+ cnt19 = 0 while True: #loop19 alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == ID) : alt19 = 1 if alt19 == 1: # Eval.g:200:16: ID pass ID21 = self.match(self.input, ID, self.FOLLOW_ID_in_each_val874) #action start ps.append(ID21.text) #action end else: if cnt19 >= 1: break #loop19 eee = EarlyExitException(19, self.input) raise eee cnt19 += 1 self.match(self.input, UP, None) #action start text = ','.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "each_val" # $ANTLR start "throw_stmt" # Eval.g:205:1: throw_stmt : ^( THROW expr ) ; def throw_stmt(self, ): expr22 = None try: try: # Eval.g:206:2: ( ^( THROW expr ) ) # Eval.g:206:4: ^( THROW expr ) pass self.match(self.input, THROW, self.FOLLOW_THROW_in_throw_stmt897) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_throw_stmt899) expr22 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_throw(expr22) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "throw_stmt" # $ANTLR start "try_stmt" # Eval.g:209:1: try_stmt : ^( TRY block ( catch_clause )+ ( finally_clause )? ) ; def try_stmt(self, ): self.cpy.op_try() try: try: # Eval.g:211:2: ( ^( TRY block ( catch_clause )+ ( finally_clause )? ) ) # Eval.g:211:4: ^( TRY block ( catch_clause )+ ( finally_clause )? ) pass self.match(self.input, TRY, self.FOLLOW_TRY_in_try_stmt920) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_block_in_try_stmt922) self.block() self._state.following.pop() # Eval.g:211:16: ( catch_clause )+ cnt20 = 0 while True: #loop20 alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == CATCH) : alt20 = 1 if alt20 == 1: # Eval.g:211:16: catch_clause pass self._state.following.append(self.FOLLOW_catch_clause_in_try_stmt924) self.catch_clause() self._state.following.pop() else: if cnt20 >= 1: break #loop20 eee = EarlyExitException(20, self.input) raise eee cnt20 += 1 # Eval.g:211:30: ( finally_clause )? alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == FINALLY) : alt21 = 1 if alt21 == 1: # Eval.g:211:30: finally_clause pass self._state.following.append(self.FOLLOW_finally_clause_in_try_stmt927) self.finally_clause() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "try_stmt" # $ANTLR start "catch_clause" # Eval.g:213:1: catch_clause : ^( CATCH module ( ID )? block ) ; def catch_clause(self, ): ID24 = None module23 = None try: try: # Eval.g:214:2: ( ^( CATCH module ( ID )? block ) ) # Eval.g:214:4: ^( CATCH module ( ID )? block ) pass self.match(self.input, CATCH, self.FOLLOW_CATCH_in_catch_clause940) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_module_in_catch_clause942) module23 = self.module() self._state.following.pop() # Eval.g:214:19: ( ID )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == ID) : alt22 = 1 if alt22 == 1: # Eval.g:214:19: ID pass ID24 = self.match(self.input, ID, self.FOLLOW_ID_in_catch_clause944) #action start self.cpy.op_catch(module23, ID24.text) #action end self._state.following.append(self.FOLLOW_block_in_catch_clause953) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "catch_clause" # $ANTLR start "finally_clause" # Eval.g:218:1: finally_clause : ^( FINALLY block ) ; def finally_clause(self, ): self.cpy.op_finally() try: try: # Eval.g:220:2: ( ^( FINALLY block ) ) # Eval.g:220:4: ^( FINALLY block ) pass self.match(self.input, FINALLY, self.FOLLOW_FINALLY_in_finally_clause970) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_block_in_finally_clause972) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "finally_clause" # $ANTLR start "func_decl" # Eval.g:224:1: func_decl : ^( FUNCTION ID params block ) ; def func_decl(self, ): ID25 = None params26 = None try: try: # Eval.g:225:2: ( ^( FUNCTION ID params block ) ) # Eval.g:225:4: ^( FUNCTION ID params block ) pass self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_func_decl986) self.match(self.input, DOWN, None) ID25 = self.match(self.input, ID, self.FOLLOW_ID_in_func_decl988) self._state.following.append(self.FOLLOW_params_in_func_decl990) params26 = self.params() self._state.following.pop() #action start self.cpy.op_function(ID25.text, params26) #action end self._state.following.append(self.FOLLOW_block_in_func_decl998) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "func_decl" # $ANTLR start "params" # Eval.g:230:1: params returns [text] : ^( PARAMS ( param_decl )* ) ; def params(self, ): text = None param_decl27 = None ps = [] try: try: # Eval.g:232:2: ( ^( PARAMS ( param_decl )* ) ) # Eval.g:232:4: ^( PARAMS ( param_decl )* ) pass self.match(self.input, PARAMS, self.FOLLOW_PARAMS_in_params1021) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:232:13: ( param_decl )* while True: #loop23 alt23 = 2 LA23_0 = self.input.LA(1) if (LA23_0 == ID) : alt23 = 1 if alt23 == 1: # Eval.g:232:14: param_decl pass self._state.following.append(self.FOLLOW_param_decl_in_params1024) param_decl27 = self.param_decl() self._state.following.pop() #action start ps.append(param_decl27) #action end else: break #loop23 self.match(self.input, UP, None) #action start text = ', '.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "params" # $ANTLR start "param_decl" # Eval.g:235:1: param_decl returns [text] : ID ( '=' atom )? ; def param_decl(self, ): text = None ID28 = None atom29 = None try: try: # Eval.g:236:2: ( ID ( '=' atom )? ) # Eval.g:236:4: ID ( '=' atom )? pass ID28 = self.match(self.input, ID, self.FOLLOW_ID_in_param_decl1048) #action start text = ID28.text #action end # Eval.g:238:3: ( '=' atom )? alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == 95) : alt24 = 1 if alt24 == 1: # Eval.g:238:4: '=' atom pass self.match(self.input, 95, self.FOLLOW_95_in_param_decl1057) self._state.following.append(self.FOLLOW_atom_in_param_decl1059) atom29 = self.atom() self._state.following.pop() #action start text += ('=' + atom29) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "param_decl" # $ANTLR start "class_decl" # Eval.g:244:1: class_decl : ( ^( CLASS a= ID ( class_element )* ) | ^( CLASS b= ID c= ID ( class_element )* ) ); def class_decl(self, ): a = None b = None c = None try: try: # Eval.g:246:2: ( ^( CLASS a= ID ( class_element )* ) | ^( CLASS b= ID c= ID ( class_element )* ) ) alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == CLASS) : LA27_1 = self.input.LA(2) if (LA27_1 == 2) : LA27_2 = self.input.LA(3) if (LA27_2 == ID) : LA27_3 = self.input.LA(4) if (LA27_3 == ID) : alt27 = 2 elif (LA27_3 == 3 or LA27_3 == CONSTRUCTOR or LA27_3 == FUNCTION or LA27_3 == VAR) : alt27 = 1 else: nvae = NoViableAltException("", 27, 3, self.input) raise nvae else: nvae = NoViableAltException("", 27, 2, self.input) raise nvae else: nvae = NoViableAltException("", 27, 1, self.input) raise nvae else: nvae = NoViableAltException("", 27, 0, self.input) raise nvae if alt27 == 1: # Eval.g:246:4: ^( CLASS a= ID ( class_element )* ) pass self.match(self.input, CLASS, self.FOLLOW_CLASS_in_class_decl1087) self.match(self.input, DOWN, None) a = self.match(self.input, ID, self.FOLLOW_ID_in_class_decl1091) #action start self.cpy.op_class_enter(a.text, None) #action end # Eval.g:248:3: ( class_element )* while True: #loop25 alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == CONSTRUCTOR or LA25_0 == FUNCTION or LA25_0 == VAR) : alt25 = 1 if alt25 == 1: # Eval.g:248:3: class_element pass self._state.following.append(self.FOLLOW_class_element_in_class_decl1100) self.class_element() self._state.following.pop() else: break #loop25 self.match(self.input, UP, None) elif alt27 == 2: # Eval.g:249:4: ^( CLASS b= ID c= ID ( class_element )* ) pass self.match(self.input, CLASS, self.FOLLOW_CLASS_in_class_decl1108) self.match(self.input, DOWN, None) b = self.match(self.input, ID, self.FOLLOW_ID_in_class_decl1112) c = self.match(self.input, ID, self.FOLLOW_ID_in_class_decl1116) #action start self.cpy.op_class_enter(b.text, c.text) #action end # Eval.g:251:3: ( class_element )* while True: #loop26 alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == CONSTRUCTOR or LA26_0 == FUNCTION or LA26_0 == VAR) : alt26 = 1 if alt26 == 1: # Eval.g:251:3: class_element pass self._state.following.append(self.FOLLOW_class_element_in_class_decl1125) self.class_element() self._state.following.pop() else: break #loop26 self.match(self.input, UP, None) #action start self.cpy.op_class_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "class_decl" # $ANTLR start "class_element" # Eval.g:253:1: class_element : ( var_def | constructor | func_decl ); def class_element(self, ): try: try: # Eval.g:254:2: ( var_def | constructor | func_decl ) alt28 = 3 LA28 = self.input.LA(1) if LA28 == VAR: alt28 = 1 elif LA28 == CONSTRUCTOR: alt28 = 2 elif LA28 == FUNCTION: alt28 = 3 else: nvae = NoViableAltException("", 28, 0, self.input) raise nvae if alt28 == 1: # Eval.g:254:4: var_def pass self._state.following.append(self.FOLLOW_var_def_in_class_element1137) self.var_def() self._state.following.pop() elif alt28 == 2: # Eval.g:254:14: constructor pass self._state.following.append(self.FOLLOW_constructor_in_class_element1141) self.constructor() self._state.following.pop() elif alt28 == 3: # Eval.g:254:28: func_decl pass self._state.following.append(self.FOLLOW_func_decl_in_class_element1145) self.func_decl() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "class_element" # $ANTLR start "var_def" # Eval.g:256:1: var_def : ( ^( VAR ID ( expr )? ) | ^( VAR 'static' ID ( expr )? ) ); def var_def(self, ): ID30 = None ID32 = None expr31 = None expr33 = None try: try: # Eval.g:257:2: ( ^( VAR ID ( expr )? ) | ^( VAR 'static' ID ( expr )? ) ) alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == VAR) : LA31_1 = self.input.LA(2) if (LA31_1 == 2) : LA31_2 = self.input.LA(3) if (LA31_2 == ID) : alt31 = 1 elif (LA31_2 == 127) : alt31 = 2 else: nvae = NoViableAltException("", 31, 2, self.input) raise nvae else: nvae = NoViableAltException("", 31, 1, self.input) raise nvae else: nvae = NoViableAltException("", 31, 0, self.input) raise nvae if alt31 == 1: # Eval.g:257:4: ^( VAR ID ( expr )? ) pass self.match(self.input, VAR, self.FOLLOW_VAR_in_var_def1156) self.match(self.input, DOWN, None) ID30 = self.match(self.input, ID, self.FOLLOW_ID_in_var_def1158) # Eval.g:257:13: ( expr )? alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == ARRAY or LA29_0 == BOOL or LA29_0 == FLOAT or LA29_0 == INT or LA29_0 == MEMBER or (NEGATIVE <= LA29_0 <= NEW) or (NULL <= LA29_0 <= OBJECT) or (SPRINTF <= LA29_0 <= STRING) or (68 <= LA29_0 <= 70) or (72 <= LA29_0 <= 73) or LA29_0 == 77 or LA29_0 == 79 or LA29_0 == 83 or LA29_0 == 89 or (93 <= LA29_0 <= 94) or LA29_0 == 96 or (98 <= LA29_0 <= 99) or LA29_0 == 102 or LA29_0 == 133 or LA29_0 == 135) : alt29 = 1 if alt29 == 1: # Eval.g:257:13: expr pass self._state.following.append(self.FOLLOW_expr_in_var_def1160) expr31 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_var_def(False, ID30.text, expr31) #action end elif alt31 == 2: # Eval.g:259:4: ^( VAR 'static' ID ( expr )? ) pass self.match(self.input, VAR, self.FOLLOW_VAR_in_var_def1172) self.match(self.input, DOWN, None) self.match(self.input, 127, self.FOLLOW_127_in_var_def1174) ID32 = self.match(self.input, ID, self.FOLLOW_ID_in_var_def1176) # Eval.g:259:22: ( expr )? alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == ARRAY or LA30_0 == BOOL or LA30_0 == FLOAT or LA30_0 == INT or LA30_0 == MEMBER or (NEGATIVE <= LA30_0 <= NEW) or (NULL <= LA30_0 <= OBJECT) or (SPRINTF <= LA30_0 <= STRING) or (68 <= LA30_0 <= 70) or (72 <= LA30_0 <= 73) or LA30_0 == 77 or LA30_0 == 79 or LA30_0 == 83 or LA30_0 == 89 or (93 <= LA30_0 <= 94) or LA30_0 == 96 or (98 <= LA30_0 <= 99) or LA30_0 == 102 or LA30_0 == 133 or LA30_0 == 135) : alt30 = 1 if alt30 == 1: # Eval.g:259:22: expr pass self._state.following.append(self.FOLLOW_expr_in_var_def1178) expr33 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_var_def(True, ID32.text, expr33) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "var_def" # $ANTLR start "constructor" # Eval.g:262:1: constructor : ^( CONSTRUCTOR params block ) ; def constructor(self, ): params34 = None try: try: # Eval.g:263:2: ( ^( CONSTRUCTOR params block ) ) # Eval.g:263:4: ^( CONSTRUCTOR params block ) pass self.match(self.input, CONSTRUCTOR, self.FOLLOW_CONSTRUCTOR_in_constructor1195) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_params_in_constructor1197) params34 = self.params() self._state.following.pop() #action start self.cpy.op_construct(params34) #action end self._state.following.append(self.FOLLOW_block_in_constructor1205) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "constructor" # $ANTLR start "module" # Eval.g:270:1: module returns [text] : ^( MODULE ( ID )+ ) ; def module(self, ): text = None ID35 = None ps = [] try: try: # Eval.g:272:2: ( ^( MODULE ( ID )+ ) ) # Eval.g:272:4: ^( MODULE ( ID )+ ) pass self.match(self.input, MODULE, self.FOLLOW_MODULE_in_module1229) self.match(self.input, DOWN, None) # Eval.g:272:13: ( ID )+ cnt32 = 0 while True: #loop32 alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == ID) : alt32 = 1 if alt32 == 1: # Eval.g:272:14: ID pass ID35 = self.match(self.input, ID, self.FOLLOW_ID_in_module1232) #action start ps.append(ID35.text) #action end else: if cnt32 >= 1: break #loop32 eee = EarlyExitException(32, self.input) raise eee cnt32 += 1 self.match(self.input, UP, None) #action start text = '.'.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "module" # $ANTLR start "member_expr" # Eval.g:276:1: member_expr returns [text] : ^( MEMBER ( primary )+ ) ; def member_expr(self, ): text = None primary36 = None ps = [] try: try: # Eval.g:278:2: ( ^( MEMBER ( primary )+ ) ) # Eval.g:278:4: ^( MEMBER ( primary )+ ) pass self.match(self.input, MEMBER, self.FOLLOW_MEMBER_in_member_expr1263) self.match(self.input, DOWN, None) # Eval.g:278:13: ( primary )+ cnt33 = 0 while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == ID) : alt33 = 1 if alt33 == 1: # Eval.g:278:14: primary pass self._state.following.append(self.FOLLOW_primary_in_member_expr1266) primary36 = self.primary() self._state.following.pop() #action start ps.append(primary36) #action end else: if cnt33 >= 1: break #loop33 eee = EarlyExitException(33, self.input) raise eee cnt33 += 1 self.match(self.input, UP, None) #action start text = '.'.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "member_expr" # $ANTLR start "primary" # Eval.g:281:1: primary returns [text] : ID ( index_expr )* ( call_expr )? ; def primary(self, ): text = None ID39 = None index_expr37 = None call_expr38 = None a='' try: try: # Eval.g:283:2: ( ID ( index_expr )* ( call_expr )? ) # Eval.g:283:4: ID ( index_expr )* ( call_expr )? pass ID39 = self.match(self.input, ID, self.FOLLOW_ID_in_primary1295) # Eval.g:283:7: ( index_expr )* while True: #loop34 alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == INDEX or LA34_0 == SLICE) : alt34 = 1 if alt34 == 1: # Eval.g:283:8: index_expr pass self._state.following.append(self.FOLLOW_index_expr_in_primary1298) index_expr37 = self.index_expr() self._state.following.pop() #action start a += index_expr37 #action end else: break #loop34 # Eval.g:284:3: ( call_expr )? alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == CALL) : alt35 = 1 if alt35 == 1: # Eval.g:284:3: call_expr pass self._state.following.append(self.FOLLOW_call_expr_in_primary1305) call_expr38 = self.call_expr() self._state.following.pop() #action start b = call_expr38 if b == None: b = '' text = ID39.text + a + b #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "primary" # $ANTLR start "call_expr" # Eval.g:291:1: call_expr returns [text] : ^( CALL ( expr_list )? ) ; def call_expr(self, ): text = None expr_list40 = None try: try: # Eval.g:292:2: ( ^( CALL ( expr_list )? ) ) # Eval.g:292:4: ^( CALL ( expr_list )? ) pass self.match(self.input, CALL, self.FOLLOW_CALL_in_call_expr1324) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:292:11: ( expr_list )? alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == EXPR_LIST) : alt36 = 1 if alt36 == 1: # Eval.g:292:11: expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_call_expr1326) expr_list40 = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start s = expr_list40 if s == None: s = '' text = '(' + s + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "call_expr" # $ANTLR start "index_expr" # Eval.g:299:1: index_expr returns [text] : ( ^( INDEX expr ) | ^( SLICE a= expr (b= expr )? ) ); def index_expr(self, ): text = None a = None b = None expr41 = None try: try: # Eval.g:300:2: ( ^( INDEX expr ) | ^( SLICE a= expr (b= expr )? ) ) alt38 = 2 LA38_0 = self.input.LA(1) if (LA38_0 == INDEX) : alt38 = 1 elif (LA38_0 == SLICE) : alt38 = 2 else: nvae = NoViableAltException("", 38, 0, self.input) raise nvae if alt38 == 1: # Eval.g:300:4: ^( INDEX expr ) pass self.match(self.input, INDEX, self.FOLLOW_INDEX_in_index_expr1346) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_index_expr1348) expr41 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = '[' + expr41 + ']' #action end elif alt38 == 2: # Eval.g:302:4: ^( SLICE a= expr (b= expr )? ) pass self.match(self.input, SLICE, self.FOLLOW_SLICE_in_index_expr1359) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_index_expr1363) a = self.expr() self._state.following.pop() # Eval.g:302:20: (b= expr )? alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == ARRAY or LA37_0 == BOOL or LA37_0 == FLOAT or LA37_0 == INT or LA37_0 == MEMBER or (NEGATIVE <= LA37_0 <= NEW) or (NULL <= LA37_0 <= OBJECT) or (SPRINTF <= LA37_0 <= STRING) or (68 <= LA37_0 <= 70) or (72 <= LA37_0 <= 73) or LA37_0 == 77 or LA37_0 == 79 or LA37_0 == 83 or LA37_0 == 89 or (93 <= LA37_0 <= 94) or LA37_0 == 96 or (98 <= LA37_0 <= 99) or LA37_0 == 102 or LA37_0 == 133 or LA37_0 == 135) : alt37 = 1 if alt37 == 1: # Eval.g:302:20: b= expr pass self._state.following.append(self.FOLLOW_expr_in_index_expr1367) b = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start s = b if s == None: s = '' text = '[%s : %s]' %(a, s) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "index_expr" # $ANTLR start "expr_list" # Eval.g:311:1: expr_list returns [text] : ^( EXPR_LIST ( expr )+ ) ; def expr_list(self, ): text = None expr42 = None ps = [] try: try: # Eval.g:313:2: ( ^( EXPR_LIST ( expr )+ ) ) # Eval.g:313:4: ^( EXPR_LIST ( expr )+ ) pass self.match(self.input, EXPR_LIST, self.FOLLOW_EXPR_LIST_in_expr_list1394) self.match(self.input, DOWN, None) # Eval.g:313:16: ( expr )+ cnt39 = 0 while True: #loop39 alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == ARRAY or LA39_0 == BOOL or LA39_0 == FLOAT or LA39_0 == INT or LA39_0 == MEMBER or (NEGATIVE <= LA39_0 <= NEW) or (NULL <= LA39_0 <= OBJECT) or (SPRINTF <= LA39_0 <= STRING) or (68 <= LA39_0 <= 70) or (72 <= LA39_0 <= 73) or LA39_0 == 77 or LA39_0 == 79 or LA39_0 == 83 or LA39_0 == 89 or (93 <= LA39_0 <= 94) or LA39_0 == 96 or (98 <= LA39_0 <= 99) or LA39_0 == 102 or LA39_0 == 133 or LA39_0 == 135) : alt39 = 1 if alt39 == 1: # Eval.g:313:17: expr pass self._state.following.append(self.FOLLOW_expr_in_expr_list1397) expr42 = self.expr() self._state.following.pop() #action start ps.append(expr42) #action end else: if cnt39 >= 1: break #loop39 eee = EarlyExitException(39, self.input) raise eee cnt39 += 1 self.match(self.input, UP, None) #action start text = ', '.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "expr_list" # $ANTLR start "expr" # Eval.g:319:1: expr returns [text] : (a= relation_expr |a= logic_or_expr |a= logic_and_expr |a= bitwise_or_expr |a= bitwise_xor_expr |a= bitwise_and_expr |a= add_expr |a= mul_expr |a= not_expr |a= negative_expr |a= atom ); def expr(self, ): text = None a = None try: try: # Eval.g:320:2: (a= relation_expr |a= logic_or_expr |a= logic_and_expr |a= bitwise_or_expr |a= bitwise_xor_expr |a= bitwise_and_expr |a= add_expr |a= mul_expr |a= not_expr |a= negative_expr |a= atom ) alt40 = 11 LA40 = self.input.LA(1) if LA40 == 69 or LA40 == 93 or LA40 == 94 or LA40 == 96 or LA40 == 98 or LA40 == 99: alt40 = 1 elif LA40 == 135: alt40 = 2 elif LA40 == 72: alt40 = 3 elif LA40 == 133: alt40 = 4 elif LA40 == 102: alt40 = 5 elif LA40 == 73: alt40 = 6 elif LA40 == 79 or LA40 == 83: alt40 = 7 elif LA40 == 70 or LA40 == 77 or LA40 == 89: alt40 = 8 elif LA40 == 68: alt40 = 9 elif LA40 == NEGATIVE: alt40 = 10 elif LA40 == ARRAY or LA40 == BOOL or LA40 == FLOAT or LA40 == INT or LA40 == MEMBER or LA40 == NEW or LA40 == NULL or LA40 == OBJECT or LA40 == SPRINTF or LA40 == STRING: alt40 = 11 else: nvae = NoViableAltException("", 40, 0, self.input) raise nvae if alt40 == 1: # Eval.g:320:4: a= relation_expr pass self._state.following.append(self.FOLLOW_relation_expr_in_expr1423) a = self.relation_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 2: # Eval.g:321:4: a= logic_or_expr pass self._state.following.append(self.FOLLOW_logic_or_expr_in_expr1432) a = self.logic_or_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 3: # Eval.g:322:4: a= logic_and_expr pass self._state.following.append(self.FOLLOW_logic_and_expr_in_expr1441) a = self.logic_and_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 4: # Eval.g:323:4: a= bitwise_or_expr pass self._state.following.append(self.FOLLOW_bitwise_or_expr_in_expr1450) a = self.bitwise_or_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 5: # Eval.g:324:4: a= bitwise_xor_expr pass self._state.following.append(self.FOLLOW_bitwise_xor_expr_in_expr1459) a = self.bitwise_xor_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 6: # Eval.g:325:4: a= bitwise_and_expr pass self._state.following.append(self.FOLLOW_bitwise_and_expr_in_expr1468) a = self.bitwise_and_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 7: # Eval.g:326:4: a= add_expr pass self._state.following.append(self.FOLLOW_add_expr_in_expr1477) a = self.add_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 8: # Eval.g:327:4: a= mul_expr pass self._state.following.append(self.FOLLOW_mul_expr_in_expr1487) a = self.mul_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 9: # Eval.g:328:4: a= not_expr pass self._state.following.append(self.FOLLOW_not_expr_in_expr1497) a = self.not_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 10: # Eval.g:329:4: a= negative_expr pass self._state.following.append(self.FOLLOW_negative_expr_in_expr1507) a = self.negative_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 11: # Eval.g:330:4: a= atom pass self._state.following.append(self.FOLLOW_atom_in_expr1516) a = self.atom() self._state.following.pop() #action start text = a #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "expr" # $ANTLR start "logic_or_expr" # Eval.g:332:1: logic_or_expr returns [text] : ^( '||' b= expr c= expr ) ; def logic_or_expr(self, ): text = None b = None c = None try: try: # Eval.g:333:2: ( ^( '||' b= expr c= expr ) ) # Eval.g:333:4: ^( '||' b= expr c= expr ) pass self.match(self.input, 135, self.FOLLOW_135_in_logic_or_expr1534) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_logic_or_expr1538) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_logic_or_expr1542) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = '(' + b + ' or ' + c + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "logic_or_expr" # $ANTLR start "logic_and_expr" # Eval.g:336:1: logic_and_expr returns [text] : ^( '&&' b= expr c= expr ) ; def logic_and_expr(self, ): text = None b = None c = None try: try: # Eval.g:337:2: ( ^( '&&' b= expr c= expr ) ) # Eval.g:337:4: ^( '&&' b= expr c= expr ) pass self.match(self.input, 72, self.FOLLOW_72_in_logic_and_expr1561) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_logic_and_expr1565) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_logic_and_expr1569) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' and ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "logic_and_expr" # $ANTLR start "bitwise_or_expr" # Eval.g:340:1: bitwise_or_expr returns [text] : ^( '|' b= expr c= expr ) ; def bitwise_or_expr(self, ): text = None b = None c = None try: try: # Eval.g:341:2: ( ^( '|' b= expr c= expr ) ) # Eval.g:341:4: ^( '|' b= expr c= expr ) pass self.match(self.input, 133, self.FOLLOW_133_in_bitwise_or_expr1588) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_bitwise_or_expr1592) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_bitwise_or_expr1596) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' | ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "bitwise_or_expr" # $ANTLR start "bitwise_xor_expr" # Eval.g:344:1: bitwise_xor_expr returns [text] : ^( '^' b= expr c= expr ) ; def bitwise_xor_expr(self, ): text = None b = None c = None try: try: # Eval.g:345:2: ( ^( '^' b= expr c= expr ) ) # Eval.g:345:4: ^( '^' b= expr c= expr ) pass self.match(self.input, 102, self.FOLLOW_102_in_bitwise_xor_expr1615) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_bitwise_xor_expr1619) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_bitwise_xor_expr1623) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' ^ ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "bitwise_xor_expr" # $ANTLR start "bitwise_and_expr" # Eval.g:348:1: bitwise_and_expr returns [text] : ^( '&' b= expr c= expr ) ; def bitwise_and_expr(self, ): text = None b = None c = None try: try: # Eval.g:349:2: ( ^( '&' b= expr c= expr ) ) # Eval.g:349:4: ^( '&' b= expr c= expr ) pass self.match(self.input, 73, self.FOLLOW_73_in_bitwise_and_expr1642) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_bitwise_and_expr1646) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_bitwise_and_expr1650) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' & ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "bitwise_and_expr" # $ANTLR start "relation_expr" # Eval.g:352:1: relation_expr returns [text] : ^(op= ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) b= expr c= expr ) ; def relation_expr(self, ): text = None op = None b = None c = None try: try: # Eval.g:353:2: ( ^(op= ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) b= expr c= expr ) ) # Eval.g:353:4: ^(op= ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) b= expr c= expr ) pass op = self.input.LT(1) if self.input.LA(1) == 69 or (93 <= self.input.LA(1) <= 94) or self.input.LA(1) == 96 or (98 <= self.input.LA(1) <= 99): self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_relation_expr1687) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_relation_expr1691) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + op.text + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "relation_expr" # $ANTLR start "add_expr" # Eval.g:356:1: add_expr returns [text] : ^(op= ( '+' | '-' ) b= expr c= expr ) ; def add_expr(self, ): text = None op = None b = None c = None try: try: # Eval.g:357:2: ( ^(op= ( '+' | '-' ) b= expr c= expr ) ) # Eval.g:357:4: ^(op= ( '+' | '-' ) b= expr c= expr ) pass op = self.input.LT(1) if self.input.LA(1) == 79 or self.input.LA(1) == 83: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_add_expr1720) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_add_expr1724) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = '(' + b + ' ' + op.text + ' ' + c + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "add_expr" # $ANTLR start "mul_expr" # Eval.g:360:1: mul_expr returns [text] : ^(op= ( '*' | '/' | '%' ) b= expr c= expr ) ; def mul_expr(self, ): text = None op = None b = None c = None try: try: # Eval.g:361:2: ( ^(op= ( '*' | '/' | '%' ) b= expr c= expr ) ) # Eval.g:361:4: ^(op= ( '*' | '/' | '%' ) b= expr c= expr ) pass op = self.input.LT(1) if self.input.LA(1) == 70 or self.input.LA(1) == 77 or self.input.LA(1) == 89: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_mul_expr1755) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_mul_expr1759) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' ' + op.text + ' ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "mul_expr" # $ANTLR start "not_expr" # Eval.g:364:1: not_expr returns [text] : ^( '!' a= expr ) ; def not_expr(self, ): text = None a = None try: try: # Eval.g:365:2: ( ^( '!' a= expr ) ) # Eval.g:365:4: ^( '!' a= expr ) pass self.match(self.input, 68, self.FOLLOW_68_in_not_expr1778) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_not_expr1782) a = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = 'not (' + a + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "not_expr" # $ANTLR start "negative_expr" # Eval.g:368:1: negative_expr returns [text] : ^( NEGATIVE a= expr ) ; def negative_expr(self, ): text = None a = None try: try: # Eval.g:369:2: ( ^( NEGATIVE a= expr ) ) # Eval.g:369:4: ^( NEGATIVE a= expr ) pass self.match(self.input, NEGATIVE, self.FOLLOW_NEGATIVE_in_negative_expr1801) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_negative_expr1805) a = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = '- (' + a + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "negative_expr" # $ANTLR start "sprintf" # Eval.g:374:1: sprintf returns [text] : ^( SPRINTF expr (a= expr_list )? ) ; def sprintf(self, ): text = None a = None expr43 = None try: try: # Eval.g:375:2: ( ^( SPRINTF expr (a= expr_list )? ) ) # Eval.g:375:4: ^( SPRINTF expr (a= expr_list )? ) pass self.match(self.input, SPRINTF, self.FOLLOW_SPRINTF_in_sprintf1826) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_sprintf1828) expr43 = self.expr() self._state.following.pop() # Eval.g:375:20: (a= expr_list )? alt41 = 2 LA41_0 = self.input.LA(1) if (LA41_0 == EXPR_LIST) : alt41 = 1 if alt41 == 1: # Eval.g:375:20: a= expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_sprintf1832) a = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start s = a if not s: s='' text = expr43 + '%(' + s + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "sprintf" # $ANTLR start "new_clause" # Eval.g:383:1: new_clause returns [text] : ^( NEW module call_expr ) ; def new_clause(self, ): text = None module44 = None call_expr45 = None try: try: # Eval.g:384:2: ( ^( NEW module call_expr ) ) # Eval.g:384:4: ^( NEW module call_expr ) pass self.match(self.input, NEW, self.FOLLOW_NEW_in_new_clause1853) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_module_in_new_clause1855) module44 = self.module() self._state.following.pop() self._state.following.append(self.FOLLOW_call_expr_in_new_clause1857) call_expr45 = self.call_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = module44 + call_expr45 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "new_clause" # $ANTLR start "array_decl" # Eval.g:388:1: array_decl returns [text] : ^( ARRAY ( expr_list )? ) ; def array_decl(self, ): text = None expr_list46 = None try: try: # Eval.g:389:2: ( ^( ARRAY ( expr_list )? ) ) # Eval.g:389:4: ^( ARRAY ( expr_list )? ) pass self.match(self.input, ARRAY, self.FOLLOW_ARRAY_in_array_decl1877) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:389:12: ( expr_list )? alt42 = 2 LA42_0 = self.input.LA(1) if (LA42_0 == EXPR_LIST) : alt42 = 1 if alt42 == 1: # Eval.g:389:12: expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_array_decl1879) expr_list46 = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start s = expr_list46 if s == None: s = '' text = '[' + s + ']' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "array_decl" # $ANTLR start "object_decl" # Eval.g:396:1: object_decl returns [text] : ^( OBJECT ( property )* ) ; def object_decl(self, ): text = None property47 = None s = '' try: try: # Eval.g:398:2: ( ^( OBJECT ( property )* ) ) # Eval.g:398:4: ^( OBJECT ( property )* ) pass self.match(self.input, OBJECT, self.FOLLOW_OBJECT_in_object_decl1904) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:398:13: ( property )* while True: #loop43 alt43 = 2 LA43_0 = self.input.LA(1) if (LA43_0 == ID or LA43_0 == INT or LA43_0 == STRING) : alt43 = 1 if alt43 == 1: # Eval.g:398:14: property pass self._state.following.append(self.FOLLOW_property_in_object_decl1907) property47 = self.property() self._state.following.pop() #action start s += property47 #action end else: break #loop43 self.match(self.input, UP, None) #action start text = '{' + s + '}' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "object_decl" # $ANTLR start "property" # Eval.g:401:1: property returns [text] : a= ( ID | STRING | INT ) ':' expr ; def property(self, ): text = None a = None expr48 = None try: try: # Eval.g:402:2: (a= ( ID | STRING | INT ) ':' expr ) # Eval.g:402:4: a= ( ID | STRING | INT ) ':' expr pass a = self.input.LT(1) if self.input.LA(1) == ID or self.input.LA(1) == INT or self.input.LA(1) == STRING: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, 91, self.FOLLOW_91_in_property1944) self._state.following.append(self.FOLLOW_expr_in_property1946) expr48 = self.expr() self._state.following.pop() #action start text = a.text + ': ' + expr48 + ',' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "property" # $ANTLR start "atom" # Eval.g:407:1: atom returns [text] : (a= literal |a= member_expr |a= new_clause |a= array_decl |a= object_decl |a= sprintf ); def atom(self, ): text = None a = None try: try: # Eval.g:408:2: (a= literal |a= member_expr |a= new_clause |a= array_decl |a= object_decl |a= sprintf ) alt44 = 6 LA44 = self.input.LA(1) if LA44 == BOOL or LA44 == FLOAT or LA44 == INT or LA44 == NULL or LA44 == STRING: alt44 = 1 elif LA44 == MEMBER: alt44 = 2 elif LA44 == NEW: alt44 = 3 elif LA44 == ARRAY: alt44 = 4 elif LA44 == OBJECT: alt44 = 5 elif LA44 == SPRINTF: alt44 = 6 else: nvae = NoViableAltException("", 44, 0, self.input) raise nvae if alt44 == 1: # Eval.g:408:4: a= literal pass self._state.following.append(self.FOLLOW_literal_in_atom1967) a = self.literal() self._state.following.pop() #action start text = a #action end elif alt44 == 2: # Eval.g:409:4: a= member_expr pass self._state.following.append(self.FOLLOW_member_expr_in_atom1977) a = self.member_expr() self._state.following.pop() #action start text = a #action end elif alt44 == 3: # Eval.g:410:4: a= new_clause pass self._state.following.append(self.FOLLOW_new_clause_in_atom1986) a = self.new_clause() self._state.following.pop() #action start text = a #action end elif alt44 == 4: # Eval.g:411:4: a= array_decl pass self._state.following.append(self.FOLLOW_array_decl_in_atom1995) a = self.array_decl() self._state.following.pop() #action start text = a #action end elif alt44 == 5: # Eval.g:412:4: a= object_decl pass self._state.following.append(self.FOLLOW_object_decl_in_atom2004) a = self.object_decl() self._state.following.pop() #action start text = a #action end elif alt44 == 6: # Eval.g:413:4: a= sprintf pass self._state.following.append(self.FOLLOW_sprintf_in_atom2013) a = self.sprintf() self._state.following.pop() #action start text = a #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "atom" # $ANTLR start "literal" # Eval.g:415:1: literal returns [text] : ( NULL | BOOL | INT | FLOAT | STRING ); def literal(self, ): text = None BOOL49 = None INT50 = None FLOAT51 = None STRING52 = None try: try: # Eval.g:416:2: ( NULL | BOOL | INT | FLOAT | STRING ) alt45 = 5 LA45 = self.input.LA(1) if LA45 == NULL: alt45 = 1 elif LA45 == BOOL: alt45 = 2 elif LA45 == INT: alt45 = 3 elif LA45 == FLOAT: alt45 = 4 elif LA45 == STRING: alt45 = 5 else: nvae = NoViableAltException("", 45, 0, self.input) raise nvae if alt45 == 1: # Eval.g:416:4: NULL pass self.match(self.input, NULL, self.FOLLOW_NULL_in_literal2029) #action start text = 'None' #action end elif alt45 == 2: # Eval.g:417:4: BOOL pass BOOL49 = self.match(self.input, BOOL, self.FOLLOW_BOOL_in_literal2036) #action start text = BOOL49.text.capitalize() #action end elif alt45 == 3: # Eval.g:418:4: INT pass INT50 = self.match(self.input, INT, self.FOLLOW_INT_in_literal2043) #action start text = INT50.text #action end elif alt45 == 4: # Eval.g:419:4: FLOAT pass FLOAT51 = self.match(self.input, FLOAT, self.FOLLOW_FLOAT_in_literal2050) #action start text = FLOAT51.text #action end elif alt45 == 5: # Eval.g:420:4: STRING pass STRING52 = self.match(self.input, STRING, self.FOLLOW_STRING_in_literal2057) #action start text = STRING52.text #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "literal" # lookup tables for DFA #4 DFA4_eot = DFA.unpack( u"\10\uffff" ) DFA4_eof = DFA.unpack( u"\10\uffff" ) DFA4_min = DFA.unpack( u"\1\3\1\uffff\1\2\1\42\2\3\2\uffff" ) DFA4_max = DFA.unpack( u"\1\52\1\uffff\1\2\2\42\1\127\2\uffff" ) DFA4_accept = DFA.unpack( u"\1\uffff\1\3\4\uffff\1\1\1\2" ) DFA4_special = DFA.unpack( u"\10\uffff" ) DFA4_transition = [ DFA.unpack(u"\1\1\46\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"\1\3"), DFA.unpack(u"\1\4"), DFA.unpack(u"\1\5\36\uffff\1\4"), DFA.unpack(u"\1\6\46\uffff\1\6\54\uffff\1\7"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #4 class DFA4(DFA): pass FOLLOW_stmt_in_prog69 = frozenset([1, 9, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_import_stmt_in_stmt81 = frozenset([1]) FOLLOW_exec_stmt_in_stmt86 = frozenset([1]) FOLLOW_print_stmt_in_stmt91 = frozenset([1]) FOLLOW_printf_stmt_in_stmt95 = frozenset([1]) FOLLOW_break_stmt_in_stmt100 = frozenset([1]) FOLLOW_continue_stmt_in_stmt105 = frozenset([1]) FOLLOW_return_stmt_in_stmt110 = frozenset([1]) FOLLOW_if_stmt_in_stmt115 = frozenset([1]) FOLLOW_while_stmt_in_stmt120 = frozenset([1]) FOLLOW_do_while_stmt_in_stmt125 = frozenset([1]) FOLLOW_switch_stmt_in_stmt130 = frozenset([1]) FOLLOW_throw_stmt_in_stmt135 = frozenset([1]) FOLLOW_try_stmt_in_stmt140 = frozenset([1]) FOLLOW_func_decl_in_stmt145 = frozenset([1]) FOLLOW_class_decl_in_stmt150 = frozenset([1]) FOLLOW_for_stmt_in_stmt155 = frozenset([1]) FOLLOW_foreach_stmt_in_stmt160 = frozenset([1]) FOLLOW_BLOCK_in_block185 = frozenset([2]) FOLLOW_stmt_in_block187 = frozenset([3, 9, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_IMPORT_in_import_stmt201 = frozenset([2]) FOLLOW_module_in_import_stmt209 = frozenset([3, 42]) FOLLOW_module_in_import_stmt222 = frozenset([87]) FOLLOW_87_in_import_stmt224 = frozenset([3, 42]) FOLLOW_EXEC_STMT_in_exec_stmt250 = frozenset([2]) FOLLOW_exec_list_in_exec_stmt252 = frozenset([3]) FOLLOW_member_expr_in_exec_expr270 = frozenset([1]) FOLLOW_ASSIGN_in_exec_expr280 = frozenset([2]) FOLLOW_member_expr_in_exec_expr282 = frozenset([71, 74, 78, 81, 85, 90, 95, 103, 134]) FOLLOW_set_in_exec_expr286 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_exec_expr306 = frozenset([3]) FOLLOW_POST_INC_in_exec_expr317 = frozenset([2]) FOLLOW_member_expr_in_exec_expr319 = frozenset([3]) FOLLOW_POST_DEC_in_exec_expr330 = frozenset([2]) FOLLOW_member_expr_in_exec_expr332 = frozenset([3]) FOLLOW_PRE_INC_in_exec_expr343 = frozenset([2]) FOLLOW_member_expr_in_exec_expr345 = frozenset([3]) FOLLOW_PRE_DEC_in_exec_expr356 = frozenset([2]) FOLLOW_member_expr_in_exec_expr358 = frozenset([3]) FOLLOW_EXEC_LIST_in_exec_list382 = frozenset([2]) FOLLOW_exec_expr_in_exec_list385 = frozenset([3, 6, 41, 51, 52, 53, 54]) FOLLOW_PRINTF_in_printf_stmt408 = frozenset([2]) FOLLOW_expr_in_printf_stmt410 = frozenset([3, 28]) FOLLOW_expr_list_in_printf_stmt412 = frozenset([3]) FOLLOW_PRINT_in_print_stmt429 = frozenset([2]) FOLLOW_expr_list_in_print_stmt431 = frozenset([3]) FOLLOW_BREAK_in_break_stmt451 = frozenset([1]) FOLLOW_CONTINUE_in_continue_stmt465 = frozenset([1]) FOLLOW_RETURN_in_return_stmt480 = frozenset([2]) FOLLOW_expr_in_return_stmt482 = frozenset([3]) FOLLOW_if_clause_in_if_stmt510 = frozenset([1, 23, 24]) FOLLOW_else_if_clause_in_if_stmt512 = frozenset([1, 23, 24]) FOLLOW_else_clause_in_if_stmt515 = frozenset([1]) FOLLOW_IF_in_if_clause527 = frozenset([2]) FOLLOW_expr_in_if_clause529 = frozenset([7]) FOLLOW_block_in_if_clause533 = frozenset([3]) FOLLOW_ELSE_IF_in_else_if_clause545 = frozenset([2]) FOLLOW_if_clause_in_else_if_clause549 = frozenset([3]) FOLLOW_ELSE_in_else_clause561 = frozenset([2]) FOLLOW_block_in_else_clause565 = frozenset([3]) FOLLOW_WHILE_in_while_stmt579 = frozenset([2]) FOLLOW_expr_in_while_stmt581 = frozenset([7]) FOLLOW_block_in_while_stmt585 = frozenset([3]) FOLLOW_DO_WHILE_in_do_while_stmt598 = frozenset([2]) FOLLOW_block_in_do_while_stmt604 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_do_while_stmt608 = frozenset([3]) FOLLOW_SWITCH_in_switch_stmt627 = frozenset([2]) FOLLOW_expr_in_switch_stmt629 = frozenset([132]) FOLLOW_case_block_in_switch_stmt633 = frozenset([3]) FOLLOW_132_in_case_block648 = frozenset([11]) FOLLOW_case_clause_in_case_block651 = frozenset([11, 17, 136]) FOLLOW_default_clause_in_case_block656 = frozenset([136]) FOLLOW_136_in_case_block660 = frozenset([1]) FOLLOW_CASE_in_case_clause676 = frozenset([2]) FOLLOW_case_test_in_case_clause678 = frozenset([9, 11, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_stmt_in_case_clause683 = frozenset([9, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_break_stmt_in_case_clause686 = frozenset([3]) FOLLOW_CASE_in_case_test702 = frozenset([2]) FOLLOW_expr_in_case_test704 = frozenset([3]) FOLLOW_DEFAULT_in_default_clause725 = frozenset([2]) FOLLOW_stmt_in_default_clause727 = frozenset([3, 9, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_FOR_in_for_stmt746 = frozenset([2]) FOLLOW_exec_list_in_for_stmt751 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_for_stmt759 = frozenset([7]) FOLLOW_block_in_for_stmt765 = frozenset([3, 26]) FOLLOW_exec_list_in_for_stmt776 = frozenset([3]) FOLLOW_FOREACH_in_foreach_stmt800 = frozenset([2]) FOLLOW_expr_in_foreach_stmt802 = frozenset([21]) FOLLOW_EACH_in_foreach_stmt809 = frozenset([2]) FOLLOW_ID_in_foreach_stmt813 = frozenset([22]) FOLLOW_each_val_in_foreach_stmt817 = frozenset([3]) FOLLOW_EACH_in_foreach_stmt830 = frozenset([2]) FOLLOW_each_val_in_foreach_stmt834 = frozenset([3]) FOLLOW_block_in_foreach_stmt848 = frozenset([3]) FOLLOW_EACH_VAL_in_each_val871 = frozenset([2]) FOLLOW_ID_in_each_val874 = frozenset([3, 34]) FOLLOW_THROW_in_throw_stmt897 = frozenset([2]) FOLLOW_expr_in_throw_stmt899 = frozenset([3]) FOLLOW_TRY_in_try_stmt920 = frozenset([2]) FOLLOW_block_in_try_stmt922 = frozenset([12]) FOLLOW_catch_clause_in_try_stmt924 = frozenset([3, 12, 29]) FOLLOW_finally_clause_in_try_stmt927 = frozenset([3]) FOLLOW_CATCH_in_catch_clause940 = frozenset([2]) FOLLOW_module_in_catch_clause942 = frozenset([7, 34]) FOLLOW_ID_in_catch_clause944 = frozenset([7]) FOLLOW_block_in_catch_clause953 = frozenset([3]) FOLLOW_FINALLY_in_finally_clause970 = frozenset([2]) FOLLOW_block_in_finally_clause972 = frozenset([3]) FOLLOW_FUNCTION_in_func_decl986 = frozenset([2]) FOLLOW_ID_in_func_decl988 = frozenset([50]) FOLLOW_params_in_func_decl990 = frozenset([7]) FOLLOW_block_in_func_decl998 = frozenset([3]) FOLLOW_PARAMS_in_params1021 = frozenset([2]) FOLLOW_param_decl_in_params1024 = frozenset([3, 34]) FOLLOW_ID_in_param_decl1048 = frozenset([1, 95]) FOLLOW_95_in_param_decl1057 = frozenset([5, 8, 30, 39, 41, 44, 47, 48, 60, 61]) FOLLOW_atom_in_param_decl1059 = frozenset([1]) FOLLOW_CLASS_in_class_decl1087 = frozenset([2]) FOLLOW_ID_in_class_decl1091 = frozenset([3, 15, 33, 65]) FOLLOW_class_element_in_class_decl1100 = frozenset([3, 15, 33, 65]) FOLLOW_CLASS_in_class_decl1108 = frozenset([2]) FOLLOW_ID_in_class_decl1112 = frozenset([34]) FOLLOW_ID_in_class_decl1116 = frozenset([3, 15, 33, 65]) FOLLOW_class_element_in_class_decl1125 = frozenset([3, 15, 33, 65]) FOLLOW_var_def_in_class_element1137 = frozenset([1]) FOLLOW_constructor_in_class_element1141 = frozenset([1]) FOLLOW_func_decl_in_class_element1145 = frozenset([1]) FOLLOW_VAR_in_var_def1156 = frozenset([2]) FOLLOW_ID_in_var_def1158 = frozenset([3, 5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_var_def1160 = frozenset([3]) FOLLOW_VAR_in_var_def1172 = frozenset([2]) FOLLOW_127_in_var_def1174 = frozenset([34]) FOLLOW_ID_in_var_def1176 = frozenset([3, 5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_var_def1178 = frozenset([3]) FOLLOW_CONSTRUCTOR_in_constructor1195 = frozenset([2]) FOLLOW_params_in_constructor1197 = frozenset([7]) FOLLOW_block_in_constructor1205 = frozenset([3]) FOLLOW_MODULE_in_module1229 = frozenset([2]) FOLLOW_ID_in_module1232 = frozenset([3, 34]) FOLLOW_MEMBER_in_member_expr1263 = frozenset([2]) FOLLOW_primary_in_member_expr1266 = frozenset([3, 34]) FOLLOW_ID_in_primary1295 = frozenset([1, 10, 38, 59]) FOLLOW_index_expr_in_primary1298 = frozenset([1, 10, 38, 59]) FOLLOW_call_expr_in_primary1305 = frozenset([1]) FOLLOW_CALL_in_call_expr1324 = frozenset([2]) FOLLOW_expr_list_in_call_expr1326 = frozenset([3]) FOLLOW_INDEX_in_index_expr1346 = frozenset([2]) FOLLOW_expr_in_index_expr1348 = frozenset([3]) FOLLOW_SLICE_in_index_expr1359 = frozenset([2]) FOLLOW_expr_in_index_expr1363 = frozenset([3, 5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_index_expr1367 = frozenset([3]) FOLLOW_EXPR_LIST_in_expr_list1394 = frozenset([2]) FOLLOW_expr_in_expr_list1397 = frozenset([3, 5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_relation_expr_in_expr1423 = frozenset([1]) FOLLOW_logic_or_expr_in_expr1432 = frozenset([1]) FOLLOW_logic_and_expr_in_expr1441 = frozenset([1]) FOLLOW_bitwise_or_expr_in_expr1450 = frozenset([1]) FOLLOW_bitwise_xor_expr_in_expr1459 = frozenset([1]) FOLLOW_bitwise_and_expr_in_expr1468 = frozenset([1]) FOLLOW_add_expr_in_expr1477 = frozenset([1]) FOLLOW_mul_expr_in_expr1487 = frozenset([1]) FOLLOW_not_expr_in_expr1497 = frozenset([1]) FOLLOW_negative_expr_in_expr1507 = frozenset([1]) FOLLOW_atom_in_expr1516 = frozenset([1]) FOLLOW_135_in_logic_or_expr1534 = frozenset([2]) FOLLOW_expr_in_logic_or_expr1538 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_logic_or_expr1542 = frozenset([3]) FOLLOW_72_in_logic_and_expr1561 = frozenset([2]) FOLLOW_expr_in_logic_and_expr1565 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_logic_and_expr1569 = frozenset([3]) FOLLOW_133_in_bitwise_or_expr1588 = frozenset([2]) FOLLOW_expr_in_bitwise_or_expr1592 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_bitwise_or_expr1596 = frozenset([3]) FOLLOW_102_in_bitwise_xor_expr1615 = frozenset([2]) FOLLOW_expr_in_bitwise_xor_expr1619 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_bitwise_xor_expr1623 = frozenset([3]) FOLLOW_73_in_bitwise_and_expr1642 = frozenset([2]) FOLLOW_expr_in_bitwise_and_expr1646 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_bitwise_and_expr1650 = frozenset([3]) FOLLOW_set_in_relation_expr1671 = frozenset([2]) FOLLOW_expr_in_relation_expr1687 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_relation_expr1691 = frozenset([3]) FOLLOW_set_in_add_expr1712 = frozenset([2]) FOLLOW_expr_in_add_expr1720 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_add_expr1724 = frozenset([3]) FOLLOW_set_in_mul_expr1745 = frozenset([2]) FOLLOW_expr_in_mul_expr1755 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_mul_expr1759 = frozenset([3]) FOLLOW_68_in_not_expr1778 = frozenset([2]) FOLLOW_expr_in_not_expr1782 = frozenset([3]) FOLLOW_NEGATIVE_in_negative_expr1801 = frozenset([2]) FOLLOW_expr_in_negative_expr1805 = frozenset([3]) FOLLOW_SPRINTF_in_sprintf1826 = frozenset([2]) FOLLOW_expr_in_sprintf1828 = frozenset([3, 28]) FOLLOW_expr_list_in_sprintf1832 = frozenset([3]) FOLLOW_NEW_in_new_clause1853 = frozenset([2]) FOLLOW_module_in_new_clause1855 = frozenset([10]) FOLLOW_call_expr_in_new_clause1857 = frozenset([3]) FOLLOW_ARRAY_in_array_decl1877 = frozenset([2]) FOLLOW_expr_list_in_array_decl1879 = frozenset([3]) FOLLOW_OBJECT_in_object_decl1904 = frozenset([2]) FOLLOW_property_in_object_decl1907 = frozenset([3, 34, 39, 61]) FOLLOW_set_in_property1932 = frozenset([91]) FOLLOW_91_in_property1944 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_property1946 = frozenset([1]) FOLLOW_literal_in_atom1967 = frozenset([1]) FOLLOW_member_expr_in_atom1977 = frozenset([1]) FOLLOW_new_clause_in_atom1986 = frozenset([1]) FOLLOW_array_decl_in_atom1995 = frozenset([1]) FOLLOW_object_decl_in_atom2004 = frozenset([1]) FOLLOW_sprintf_in_atom2013 = frozenset([1]) FOLLOW_NULL_in_literal2029 = frozenset([1]) FOLLOW_BOOL_in_literal2036 = frozenset([1]) FOLLOW_INT_in_literal2043 = frozenset([1]) FOLLOW_FLOAT_in_literal2050 = frozenset([1]) FOLLOW_STRING_in_literal2057 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import WalkerMain main = WalkerMain(Eval) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "aegsea/ssdb-rocksdb", "path": "deps/cpy/Eval.py", "copies": "1", "size": "136440", "license": "bsd-3-clause", "hash": 2681639451850277000, "line_mean": 26.8448979592, "line_max": 437, "alpha_frac": 0.4493257109, "autogenerated": false, "ratio": 3.7453677015564524, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4694693412456452, "avg_score": null, "num_lines": null }
# $ANTLR 3.4 Eval.g 2012-12-09 16:07:29 import sys from antlr3 import * from antlr3.tree import * from antlr3.compat import set, frozenset from engine import CpyBuilder # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__68=68 T__69=69 T__70=70 T__71=71 T__72=72 T__73=73 T__74=74 T__75=75 T__76=76 T__77=77 T__78=78 T__79=79 T__80=80 T__81=81 T__82=82 T__83=83 T__84=84 T__85=85 T__86=86 T__87=87 T__88=88 T__89=89 T__90=90 T__91=91 T__92=92 T__93=93 T__94=94 T__95=95 T__96=96 T__97=97 T__98=98 T__99=99 T__100=100 T__101=101 T__102=102 T__103=103 T__104=104 T__105=105 T__106=106 T__107=107 T__108=108 T__109=109 T__110=110 T__111=111 T__112=112 T__113=113 T__114=114 T__115=115 T__116=116 T__117=117 T__118=118 T__119=119 T__120=120 T__121=121 T__122=122 T__123=123 T__124=124 T__125=125 T__126=126 T__127=127 T__128=128 T__129=129 T__130=130 T__131=131 T__132=132 T__133=133 T__134=134 T__135=135 T__136=136 ALPHA=4 ARRAY=5 ASSIGN=6 BLOCK=7 BOOL=8 BREAK=9 CALL=10 CASE=11 CATCH=12 CLASS=13 COMMENT=14 CONSTRUCTOR=15 CONTINUE=16 DEFAULT=17 DIGIT=18 DOUBLE_QUOTE_CHARS=19 DO_WHILE=20 EACH=21 EACH_VAL=22 ELSE=23 ELSE_IF=24 EMPTY_LINE=25 EXEC_LIST=26 EXEC_STMT=27 EXPR_LIST=28 FINALLY=29 FLOAT=30 FOR=31 FOREACH=32 FUNCTION=33 ID=34 ID_LIST=35 IF=36 IMPORT=37 INDEX=38 INT=39 LINECOMMENT=40 MEMBER=41 MODULE=42 NEGATIVE=43 NEW=44 NEWLINE=45 NOP=46 NULL=47 OBJECT=48 OP_ASSIGN=49 PARAMS=50 POST_DEC=51 POST_INC=52 PRE_DEC=53 PRE_INC=54 PRINT=55 PRINTF=56 RETURN=57 SINGLE_QUOTE_CHARS=58 SLICE=59 SPRINTF=60 STRING=61 SWITCH=62 THROW=63 TRY=64 VAR=65 WHILE=66 WS=67 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "ALPHA", "ARRAY", "ASSIGN", "BLOCK", "BOOL", "BREAK", "CALL", "CASE", "CATCH", "CLASS", "COMMENT", "CONSTRUCTOR", "CONTINUE", "DEFAULT", "DIGIT", "DOUBLE_QUOTE_CHARS", "DO_WHILE", "EACH", "EACH_VAL", "ELSE", "ELSE_IF", "EMPTY_LINE", "EXEC_LIST", "EXEC_STMT", "EXPR_LIST", "FINALLY", "FLOAT", "FOR", "FOREACH", "FUNCTION", "ID", "ID_LIST", "IF", "IMPORT", "INDEX", "INT", "LINECOMMENT", "MEMBER", "MODULE", "NEGATIVE", "NEW", "NEWLINE", "NOP", "NULL", "OBJECT", "OP_ASSIGN", "PARAMS", "POST_DEC", "POST_INC", "PRE_DEC", "PRE_INC", "PRINT", "PRINTF", "RETURN", "SINGLE_QUOTE_CHARS", "SLICE", "SPRINTF", "STRING", "SWITCH", "THROW", "TRY", "VAR", "WHILE", "WS", "'!'", "'!='", "'%'", "'%='", "'&&'", "'&'", "'&='", "'('", "')'", "'*'", "'*='", "'+'", "'++'", "'+='", "','", "'-'", "'--'", "'-='", "'.'", "'.*'", "'..'", "'/'", "'/='", "':'", "';'", "'<'", "'<='", "'='", "'=='", "'=>'", "'>'", "'>='", "'['", "']'", "'^'", "'^='", "'as'", "'break'", "'case'", "'catch'", "'class'", "'continue'", "'default'", "'do'", "'else'", "'extends'", "'finally'", "'for'", "'foreach'", "'function'", "'if'", "'import'", "'init'", "'new'", "'print'", "'printf'", "'public'", "'return'", "'sprintf'", "'static'", "'switch'", "'throw'", "'try'", "'while'", "'{'", "'|'", "'|='", "'||'", "'}'" ] class Eval(TreeParser): grammarFileName = "Eval.g" api_version = 1 tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(Eval, self).__init__(input, state, *args, **kwargs) self.dfa4 = self.DFA4( self, 4, eot = self.DFA4_eot, eof = self.DFA4_eof, min = self.DFA4_min, max = self.DFA4_max, accept = self.DFA4_accept, special = self.DFA4_special, transition = self.DFA4_transition ) self.delegates = [] # $ANTLR start "prog" # Eval.g:21:1: prog[cpy] : ( stmt )* ; def prog(self, cpy): self.cpy = cpy try: try: # Eval.g:28:2: ( ( stmt )* ) # Eval.g:28:4: ( stmt )* pass # Eval.g:28:4: ( stmt )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == BREAK or LA1_0 == CLASS or LA1_0 == CONTINUE or LA1_0 == DO_WHILE or LA1_0 == EXEC_STMT or (FOR <= LA1_0 <= FUNCTION) or (IF <= LA1_0 <= IMPORT) or (PRINT <= LA1_0 <= RETURN) or (SWITCH <= LA1_0 <= TRY) or LA1_0 == WHILE) : alt1 = 1 if alt1 == 1: # Eval.g:28:4: stmt pass self._state.following.append(self.FOLLOW_stmt_in_prog69) self.stmt() self._state.following.pop() else: break #loop1 #action start self.cpy.close() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "prog" # $ANTLR start "stmt" # Eval.g:31:1: stmt : ( import_stmt | exec_stmt | print_stmt | printf_stmt | break_stmt | continue_stmt | return_stmt | if_stmt | while_stmt | do_while_stmt | switch_stmt | throw_stmt | try_stmt | func_decl | class_decl | for_stmt | foreach_stmt ); def stmt(self, ): try: try: # Eval.g:32:2: ( import_stmt | exec_stmt | print_stmt | printf_stmt | break_stmt | continue_stmt | return_stmt | if_stmt | while_stmt | do_while_stmt | switch_stmt | throw_stmt | try_stmt | func_decl | class_decl | for_stmt | foreach_stmt ) alt2 = 17 LA2 = self.input.LA(1) if LA2 == IMPORT: alt2 = 1 elif LA2 == EXEC_STMT: alt2 = 2 elif LA2 == PRINT: alt2 = 3 elif LA2 == PRINTF: alt2 = 4 elif LA2 == BREAK: alt2 = 5 elif LA2 == CONTINUE: alt2 = 6 elif LA2 == RETURN: alt2 = 7 elif LA2 == IF: alt2 = 8 elif LA2 == WHILE: alt2 = 9 elif LA2 == DO_WHILE: alt2 = 10 elif LA2 == SWITCH: alt2 = 11 elif LA2 == THROW: alt2 = 12 elif LA2 == TRY: alt2 = 13 elif LA2 == FUNCTION: alt2 = 14 elif LA2 == CLASS: alt2 = 15 elif LA2 == FOR: alt2 = 16 elif LA2 == FOREACH: alt2 = 17 else: nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # Eval.g:32:4: import_stmt pass self._state.following.append(self.FOLLOW_import_stmt_in_stmt81) self.import_stmt() self._state.following.pop() elif alt2 == 2: # Eval.g:33:4: exec_stmt pass self._state.following.append(self.FOLLOW_exec_stmt_in_stmt86) self.exec_stmt() self._state.following.pop() elif alt2 == 3: # Eval.g:34:4: print_stmt pass self._state.following.append(self.FOLLOW_print_stmt_in_stmt91) self.print_stmt() self._state.following.pop() elif alt2 == 4: # Eval.g:34:17: printf_stmt pass self._state.following.append(self.FOLLOW_printf_stmt_in_stmt95) self.printf_stmt() self._state.following.pop() elif alt2 == 5: # Eval.g:35:4: break_stmt pass self._state.following.append(self.FOLLOW_break_stmt_in_stmt100) self.break_stmt() self._state.following.pop() elif alt2 == 6: # Eval.g:36:4: continue_stmt pass self._state.following.append(self.FOLLOW_continue_stmt_in_stmt105) self.continue_stmt() self._state.following.pop() elif alt2 == 7: # Eval.g:37:4: return_stmt pass self._state.following.append(self.FOLLOW_return_stmt_in_stmt110) self.return_stmt() self._state.following.pop() elif alt2 == 8: # Eval.g:38:4: if_stmt pass self._state.following.append(self.FOLLOW_if_stmt_in_stmt115) self.if_stmt() self._state.following.pop() elif alt2 == 9: # Eval.g:39:4: while_stmt pass self._state.following.append(self.FOLLOW_while_stmt_in_stmt120) self.while_stmt() self._state.following.pop() elif alt2 == 10: # Eval.g:40:4: do_while_stmt pass self._state.following.append(self.FOLLOW_do_while_stmt_in_stmt125) self.do_while_stmt() self._state.following.pop() elif alt2 == 11: # Eval.g:41:4: switch_stmt pass self._state.following.append(self.FOLLOW_switch_stmt_in_stmt130) self.switch_stmt() self._state.following.pop() elif alt2 == 12: # Eval.g:42:4: throw_stmt pass self._state.following.append(self.FOLLOW_throw_stmt_in_stmt135) self.throw_stmt() self._state.following.pop() elif alt2 == 13: # Eval.g:43:4: try_stmt pass self._state.following.append(self.FOLLOW_try_stmt_in_stmt140) self.try_stmt() self._state.following.pop() elif alt2 == 14: # Eval.g:44:4: func_decl pass self._state.following.append(self.FOLLOW_func_decl_in_stmt145) self.func_decl() self._state.following.pop() elif alt2 == 15: # Eval.g:45:4: class_decl pass self._state.following.append(self.FOLLOW_class_decl_in_stmt150) self.class_decl() self._state.following.pop() elif alt2 == 16: # Eval.g:46:4: for_stmt pass self._state.following.append(self.FOLLOW_for_stmt_in_stmt155) self.for_stmt() self._state.following.pop() elif alt2 == 17: # Eval.g:47:4: foreach_stmt pass self._state.following.append(self.FOLLOW_foreach_stmt_in_stmt160) self.foreach_stmt() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "stmt" # $ANTLR start "block" # Eval.g:52:1: block : ^( BLOCK ( stmt )* ) ; def block(self, ): self.cpy.block_enter() try: try: # Eval.g:59:2: ( ^( BLOCK ( stmt )* ) ) # Eval.g:59:4: ^( BLOCK ( stmt )* ) pass self.match(self.input, BLOCK, self.FOLLOW_BLOCK_in_block185) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:59:12: ( stmt )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == BREAK or LA3_0 == CLASS or LA3_0 == CONTINUE or LA3_0 == DO_WHILE or LA3_0 == EXEC_STMT or (FOR <= LA3_0 <= FUNCTION) or (IF <= LA3_0 <= IMPORT) or (PRINT <= LA3_0 <= RETURN) or (SWITCH <= LA3_0 <= TRY) or LA3_0 == WHILE) : alt3 = 1 if alt3 == 1: # Eval.g:59:12: stmt pass self._state.following.append(self.FOLLOW_stmt_in_block187) self.stmt() self._state.following.pop() else: break #loop3 self.match(self.input, UP, None) #action start self.cpy.block_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "block" # $ANTLR start "import_stmt" # Eval.g:62:1: import_stmt : ^( IMPORT (a= module |b= module '.*' )+ ) ; def import_stmt(self, ): a = None b = None try: try: # Eval.g:63:2: ( ^( IMPORT (a= module |b= module '.*' )+ ) ) # Eval.g:63:4: ^( IMPORT (a= module |b= module '.*' )+ ) pass self.match(self.input, IMPORT, self.FOLLOW_IMPORT_in_import_stmt201) self.match(self.input, DOWN, None) # Eval.g:64:3: (a= module |b= module '.*' )+ cnt4 = 0 while True: #loop4 alt4 = 3 alt4 = self.dfa4.predict(self.input) if alt4 == 1: # Eval.g:64:5: a= module pass self._state.following.append(self.FOLLOW_module_in_import_stmt209) a = self.module() self._state.following.pop() #action start self.cpy.op_import(a, None) #action end elif alt4 == 2: # Eval.g:66:5: b= module '.*' pass self._state.following.append(self.FOLLOW_module_in_import_stmt222) b = self.module() self._state.following.pop() self.match(self.input, 87, self.FOLLOW_87_in_import_stmt224) #action start self.cpy.op_import(b, '*') #action end else: if cnt4 >= 1: break #loop4 eee = EarlyExitException(4, self.input) raise eee cnt4 += 1 self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "import_stmt" # $ANTLR start "exec_stmt" # Eval.g:72:1: exec_stmt : ^( EXEC_STMT exec_list ) ; def exec_stmt(self, ): exec_list1 = None try: try: # Eval.g:73:2: ( ^( EXEC_STMT exec_list ) ) # Eval.g:73:4: ^( EXEC_STMT exec_list ) pass self.match(self.input, EXEC_STMT, self.FOLLOW_EXEC_STMT_in_exec_stmt250) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_exec_list_in_exec_stmt252) exec_list1 = self.exec_list() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.stmt(exec_list1) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "exec_stmt" # $ANTLR start "exec_expr" # Eval.g:76:1: exec_expr returns [text] : ( member_expr | ^( ASSIGN member_expr op= ( '=' | '+=' | '-=' | '*=' | '/=' | '%=' | '&=' | '^=' | '|=' ) expr ) | ^( POST_INC member_expr ) | ^( POST_DEC member_expr ) | ^( PRE_INC member_expr ) | ^( PRE_DEC member_expr ) ); def exec_expr(self, ): text = None op = None member_expr2 = None member_expr3 = None expr4 = None member_expr5 = None member_expr6 = None member_expr7 = None member_expr8 = None try: try: # Eval.g:77:2: ( member_expr | ^( ASSIGN member_expr op= ( '=' | '+=' | '-=' | '*=' | '/=' | '%=' | '&=' | '^=' | '|=' ) expr ) | ^( POST_INC member_expr ) | ^( POST_DEC member_expr ) | ^( PRE_INC member_expr ) | ^( PRE_DEC member_expr ) ) alt5 = 6 LA5 = self.input.LA(1) if LA5 == MEMBER: alt5 = 1 elif LA5 == ASSIGN: alt5 = 2 elif LA5 == POST_INC: alt5 = 3 elif LA5 == POST_DEC: alt5 = 4 elif LA5 == PRE_INC: alt5 = 5 elif LA5 == PRE_DEC: alt5 = 6 else: nvae = NoViableAltException("", 5, 0, self.input) raise nvae if alt5 == 1: # Eval.g:77:4: member_expr pass self._state.following.append(self.FOLLOW_member_expr_in_exec_expr270) member_expr2 = self.member_expr() self._state.following.pop() #action start text = member_expr2 #action end elif alt5 == 2: # Eval.g:79:4: ^( ASSIGN member_expr op= ( '=' | '+=' | '-=' | '*=' | '/=' | '%=' | '&=' | '^=' | '|=' ) expr ) pass self.match(self.input, ASSIGN, self.FOLLOW_ASSIGN_in_exec_expr280) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr282) member_expr3 = self.member_expr() self._state.following.pop() op = self.input.LT(1) if self.input.LA(1) == 71 or self.input.LA(1) == 74 or self.input.LA(1) == 78 or self.input.LA(1) == 81 or self.input.LA(1) == 85 or self.input.LA(1) == 90 or self.input.LA(1) == 95 or self.input.LA(1) == 103 or self.input.LA(1) == 134: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_expr_in_exec_expr306) expr4 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_assign(member_expr3, expr4, op.text) #action end elif alt5 == 3: # Eval.g:81:4: ^( POST_INC member_expr ) pass self.match(self.input, POST_INC, self.FOLLOW_POST_INC_in_exec_expr317) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr319) member_expr5 = self.member_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_inc(member_expr5) #action end elif alt5 == 4: # Eval.g:83:4: ^( POST_DEC member_expr ) pass self.match(self.input, POST_DEC, self.FOLLOW_POST_DEC_in_exec_expr330) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr332) member_expr6 = self.member_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_dec(member_expr6) #action end elif alt5 == 5: # Eval.g:85:4: ^( PRE_INC member_expr ) pass self.match(self.input, PRE_INC, self.FOLLOW_PRE_INC_in_exec_expr343) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr345) member_expr7 = self.member_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_inc(member_expr7) #action end elif alt5 == 6: # Eval.g:87:4: ^( PRE_DEC member_expr ) pass self.match(self.input, PRE_DEC, self.FOLLOW_PRE_DEC_in_exec_expr356) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr358) member_expr8 = self.member_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = self.cpy.op_dec(member_expr8) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "exec_expr" # $ANTLR start "exec_list" # Eval.g:90:1: exec_list returns [text] : ^( EXEC_LIST ( exec_expr )+ ) ; def exec_list(self, ): text = None exec_expr9 = None ps = [] try: try: # Eval.g:92:2: ( ^( EXEC_LIST ( exec_expr )+ ) ) # Eval.g:92:4: ^( EXEC_LIST ( exec_expr )+ ) pass self.match(self.input, EXEC_LIST, self.FOLLOW_EXEC_LIST_in_exec_list382) self.match(self.input, DOWN, None) # Eval.g:92:16: ( exec_expr )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == ASSIGN or LA6_0 == MEMBER or (POST_DEC <= LA6_0 <= PRE_INC)) : alt6 = 1 if alt6 == 1: # Eval.g:92:17: exec_expr pass self._state.following.append(self.FOLLOW_exec_expr_in_exec_list385) exec_expr9 = self.exec_expr() self._state.following.pop() #action start ps.append(exec_expr9) #action end else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 self.match(self.input, UP, None) #action start text = ', '.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "exec_list" # $ANTLR start "printf_stmt" # Eval.g:96:1: printf_stmt : ^( PRINTF expr ( expr_list )? ) ; def printf_stmt(self, ): expr10 = None expr_list11 = None try: try: # Eval.g:97:2: ( ^( PRINTF expr ( expr_list )? ) ) # Eval.g:97:4: ^( PRINTF expr ( expr_list )? ) pass self.match(self.input, PRINTF, self.FOLLOW_PRINTF_in_printf_stmt408) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_printf_stmt410) expr10 = self.expr() self._state.following.pop() # Eval.g:97:18: ( expr_list )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == EXPR_LIST) : alt7 = 1 if alt7 == 1: # Eval.g:97:18: expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_printf_stmt412) expr_list11 = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_printf(expr10, expr_list11) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "printf_stmt" # $ANTLR start "print_stmt" # Eval.g:100:1: print_stmt : ^( PRINT expr_list ) ; def print_stmt(self, ): expr_list12 = None try: try: # Eval.g:101:2: ( ^( PRINT expr_list ) ) # Eval.g:101:4: ^( PRINT expr_list ) pass self.match(self.input, PRINT, self.FOLLOW_PRINT_in_print_stmt429) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_list_in_print_stmt431) expr_list12 = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_print(expr_list12) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "print_stmt" # $ANTLR start "break_stmt" # Eval.g:107:1: break_stmt : BREAK ; def break_stmt(self, ): try: try: # Eval.g:108:2: ( BREAK ) # Eval.g:108:4: BREAK pass self.match(self.input, BREAK, self.FOLLOW_BREAK_in_break_stmt451) #action start self.cpy.op_break() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "break_stmt" # $ANTLR start "continue_stmt" # Eval.g:111:1: continue_stmt : CONTINUE ; def continue_stmt(self, ): try: try: # Eval.g:112:2: ( CONTINUE ) # Eval.g:112:4: CONTINUE pass self.match(self.input, CONTINUE, self.FOLLOW_CONTINUE_in_continue_stmt465) #action start self.cpy.op_continue() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "continue_stmt" # $ANTLR start "return_stmt" # Eval.g:115:1: return_stmt : ^( RETURN ( expr )? ) ; def return_stmt(self, ): expr13 = None try: try: # Eval.g:116:2: ( ^( RETURN ( expr )? ) ) # Eval.g:116:4: ^( RETURN ( expr )? ) pass self.match(self.input, RETURN, self.FOLLOW_RETURN_in_return_stmt480) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:116:13: ( expr )? alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == ARRAY or LA8_0 == BOOL or LA8_0 == FLOAT or LA8_0 == INT or LA8_0 == MEMBER or (NEGATIVE <= LA8_0 <= NEW) or (NULL <= LA8_0 <= OBJECT) or (SPRINTF <= LA8_0 <= STRING) or (68 <= LA8_0 <= 70) or (72 <= LA8_0 <= 73) or LA8_0 == 77 or LA8_0 == 79 or LA8_0 == 83 or LA8_0 == 89 or (93 <= LA8_0 <= 94) or LA8_0 == 96 or (98 <= LA8_0 <= 99) or LA8_0 == 102 or LA8_0 == 133 or LA8_0 == 135) : alt8 = 1 if alt8 == 1: # Eval.g:116:13: expr pass self._state.following.append(self.FOLLOW_expr_in_return_stmt482) expr13 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_return(expr13) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "return_stmt" # $ANTLR start "if_stmt" # Eval.g:121:1: if_stmt : if_clause ( else_if_clause )* ( else_clause )? ; def if_stmt(self, ): self.cpy.if_enter() try: try: # Eval.g:128:2: ( if_clause ( else_if_clause )* ( else_clause )? ) # Eval.g:128:4: if_clause ( else_if_clause )* ( else_clause )? pass self._state.following.append(self.FOLLOW_if_clause_in_if_stmt510) self.if_clause() self._state.following.pop() # Eval.g:128:14: ( else_if_clause )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == ELSE_IF) : alt9 = 1 if alt9 == 1: # Eval.g:128:14: else_if_clause pass self._state.following.append(self.FOLLOW_else_if_clause_in_if_stmt512) self.else_if_clause() self._state.following.pop() else: break #loop9 # Eval.g:128:30: ( else_clause )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == ELSE) : alt10 = 1 if alt10 == 1: # Eval.g:128:30: else_clause pass self._state.following.append(self.FOLLOW_else_clause_in_if_stmt515) self.else_clause() self._state.following.pop() #action start self.cpy.if_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "if_stmt" # $ANTLR start "if_clause" # Eval.g:130:1: if_clause : ^( IF expr block ) ; def if_clause(self, ): expr14 = None try: try: # Eval.g:131:2: ( ^( IF expr block ) ) # Eval.g:131:4: ^( IF expr block ) pass self.match(self.input, IF, self.FOLLOW_IF_in_if_clause527) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_if_clause529) expr14 = self.expr() self._state.following.pop() #action start self.cpy.op_if(expr14) #action end self._state.following.append(self.FOLLOW_block_in_if_clause533) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "if_clause" # $ANTLR start "else_if_clause" # Eval.g:133:1: else_if_clause : ^( ELSE_IF if_clause ) ; def else_if_clause(self, ): try: try: # Eval.g:134:2: ( ^( ELSE_IF if_clause ) ) # Eval.g:134:4: ^( ELSE_IF if_clause ) pass self.match(self.input, ELSE_IF, self.FOLLOW_ELSE_IF_in_else_if_clause545) #action start self.cpy.op_else_if() #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_if_clause_in_else_if_clause549) self.if_clause() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "else_if_clause" # $ANTLR start "else_clause" # Eval.g:136:1: else_clause : ^( ELSE block ) ; def else_clause(self, ): try: try: # Eval.g:137:2: ( ^( ELSE block ) ) # Eval.g:137:4: ^( ELSE block ) pass self.match(self.input, ELSE, self.FOLLOW_ELSE_in_else_clause561) #action start self.cpy.op_else() #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_block_in_else_clause565) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "else_clause" # $ANTLR start "while_stmt" # Eval.g:141:1: while_stmt : ^( WHILE expr block ) ; def while_stmt(self, ): expr15 = None try: try: # Eval.g:142:2: ( ^( WHILE expr block ) ) # Eval.g:142:4: ^( WHILE expr block ) pass self.match(self.input, WHILE, self.FOLLOW_WHILE_in_while_stmt579) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_while_stmt581) expr15 = self.expr() self._state.following.pop() #action start self.cpy.op_while(expr15) #action end self._state.following.append(self.FOLLOW_block_in_while_stmt585) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "while_stmt" # $ANTLR start "do_while_stmt" # Eval.g:145:1: do_while_stmt : ^( DO_WHILE block expr ) ; def do_while_stmt(self, ): expr16 = None try: try: # Eval.g:146:2: ( ^( DO_WHILE block expr ) ) # Eval.g:146:4: ^( DO_WHILE block expr ) pass self.match(self.input, DO_WHILE, self.FOLLOW_DO_WHILE_in_do_while_stmt598) #action start self.cpy.op_do_while_enter() #action end self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_block_in_do_while_stmt604) self.block() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_do_while_stmt608) expr16 = self.expr() self._state.following.pop() #action start self.cpy.op_do_while_leave(expr16) #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "do_while_stmt" # $ANTLR start "switch_stmt" # Eval.g:153:1: switch_stmt : ^( SWITCH expr case_block ) ; def switch_stmt(self, ): expr17 = None try: try: # Eval.g:154:2: ( ^( SWITCH expr case_block ) ) # Eval.g:154:4: ^( SWITCH expr case_block ) pass self.match(self.input, SWITCH, self.FOLLOW_SWITCH_in_switch_stmt627) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_switch_stmt629) expr17 = self.expr() self._state.following.pop() #action start self.cpy.op_switch_enter(expr17) #action end self._state.following.append(self.FOLLOW_case_block_in_switch_stmt633) self.case_block() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_switch_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "switch_stmt" # $ANTLR start "case_block" # Eval.g:157:1: case_block : '{' ( case_clause )+ ( default_clause )? '}' ; def case_block(self, ): try: try: # Eval.g:158:2: ( '{' ( case_clause )+ ( default_clause )? '}' ) # Eval.g:158:4: '{' ( case_clause )+ ( default_clause )? '}' pass self.match(self.input, 132, self.FOLLOW_132_in_case_block648) # Eval.g:158:8: ( case_clause )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == CASE) : alt11 = 1 if alt11 == 1: # Eval.g:158:9: case_clause pass self._state.following.append(self.FOLLOW_case_clause_in_case_block651) self.case_clause() self._state.following.pop() else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 # Eval.g:158:23: ( default_clause )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == DEFAULT) : alt12 = 1 if alt12 == 1: # Eval.g:158:24: default_clause pass self._state.following.append(self.FOLLOW_default_clause_in_case_block656) self.default_clause() self._state.following.pop() self.match(self.input, 136, self.FOLLOW_136_in_case_block660) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "case_block" # $ANTLR start "case_clause" # Eval.g:160:1: case_clause : ^( CASE ( case_test )+ ( stmt )* break_stmt ) ; def case_clause(self, ): self.cpy.op_case_enter() try: try: # Eval.g:162:2: ( ^( CASE ( case_test )+ ( stmt )* break_stmt ) ) # Eval.g:162:4: ^( CASE ( case_test )+ ( stmt )* break_stmt ) pass self.match(self.input, CASE, self.FOLLOW_CASE_in_case_clause676) self.match(self.input, DOWN, None) # Eval.g:162:11: ( case_test )+ cnt13 = 0 while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == CASE) : alt13 = 1 if alt13 == 1: # Eval.g:162:11: case_test pass self._state.following.append(self.FOLLOW_case_test_in_case_clause678) self.case_test() self._state.following.pop() else: if cnt13 >= 1: break #loop13 eee = EarlyExitException(13, self.input) raise eee cnt13 += 1 #action start self.cpy.op_case() #action end # Eval.g:162:43: ( stmt )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == BREAK) : LA14_1 = self.input.LA(2) if (LA14_1 == BREAK or LA14_1 == CLASS or LA14_1 == CONTINUE or LA14_1 == DO_WHILE or LA14_1 == EXEC_STMT or (FOR <= LA14_1 <= FUNCTION) or (IF <= LA14_1 <= IMPORT) or (PRINT <= LA14_1 <= RETURN) or (SWITCH <= LA14_1 <= TRY) or LA14_1 == WHILE) : alt14 = 1 elif (LA14_0 == CLASS or LA14_0 == CONTINUE or LA14_0 == DO_WHILE or LA14_0 == EXEC_STMT or (FOR <= LA14_0 <= FUNCTION) or (IF <= LA14_0 <= IMPORT) or (PRINT <= LA14_0 <= RETURN) or (SWITCH <= LA14_0 <= TRY) or LA14_0 == WHILE) : alt14 = 1 if alt14 == 1: # Eval.g:162:43: stmt pass self._state.following.append(self.FOLLOW_stmt_in_case_clause683) self.stmt() self._state.following.pop() else: break #loop14 self._state.following.append(self.FOLLOW_break_stmt_in_case_clause686) self.break_stmt() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_case_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "case_clause" # $ANTLR start "case_test" # Eval.g:165:1: case_test : ^( CASE expr ) ; def case_test(self, ): expr18 = None try: try: # Eval.g:166:2: ( ^( CASE expr ) ) # Eval.g:166:4: ^( CASE expr ) pass self.match(self.input, CASE, self.FOLLOW_CASE_in_case_test702) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_case_test704) expr18 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_case_test(expr18) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "case_test" # $ANTLR start "default_clause" # Eval.g:169:1: default_clause : ^( DEFAULT ( stmt )* ) ; def default_clause(self, ): self.cpy.op_default_enter() try: try: # Eval.g:173:2: ( ^( DEFAULT ( stmt )* ) ) # Eval.g:173:4: ^( DEFAULT ( stmt )* ) pass self.match(self.input, DEFAULT, self.FOLLOW_DEFAULT_in_default_clause725) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:173:14: ( stmt )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == BREAK or LA15_0 == CLASS or LA15_0 == CONTINUE or LA15_0 == DO_WHILE or LA15_0 == EXEC_STMT or (FOR <= LA15_0 <= FUNCTION) or (IF <= LA15_0 <= IMPORT) or (PRINT <= LA15_0 <= RETURN) or (SWITCH <= LA15_0 <= TRY) or LA15_0 == WHILE) : alt15 = 1 if alt15 == 1: # Eval.g:173:14: stmt pass self._state.following.append(self.FOLLOW_stmt_in_default_clause727) self.stmt() self._state.following.pop() else: break #loop15 self.match(self.input, UP, None) #action start self.cpy.op_default_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "default_clause" # $ANTLR start "for_stmt" # Eval.g:178:1: for_stmt : ^( FOR (a= exec_list )? expr block (b= exec_list )? ) ; def for_stmt(self, ): a = None b = None expr19 = None try: try: # Eval.g:179:2: ( ^( FOR (a= exec_list )? expr block (b= exec_list )? ) ) # Eval.g:179:4: ^( FOR (a= exec_list )? expr block (b= exec_list )? ) pass self.match(self.input, FOR, self.FOLLOW_FOR_in_for_stmt746) self.match(self.input, DOWN, None) # Eval.g:179:10: (a= exec_list )? alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == EXEC_LIST) : alt16 = 1 if alt16 == 1: # Eval.g:179:11: a= exec_list pass self._state.following.append(self.FOLLOW_exec_list_in_for_stmt751) a = self.exec_list() self._state.following.pop() #action start self.cpy.stmt(a) #action end self._state.following.append(self.FOLLOW_expr_in_for_stmt759) expr19 = self.expr() self._state.following.pop() #action start self.cpy.op_while(expr19) #action end self._state.following.append(self.FOLLOW_block_in_for_stmt765) self.block() self._state.following.pop() #action start self.cpy.block_enter() #action end # Eval.g:183:3: (b= exec_list )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == EXEC_LIST) : alt17 = 1 if alt17 == 1: # Eval.g:183:4: b= exec_list pass self._state.following.append(self.FOLLOW_exec_list_in_for_stmt776) b = self.exec_list() self._state.following.pop() #action start self.cpy.stmt(b) #action end #action start self.cpy.block_leave() #action end self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "for_stmt" # $ANTLR start "foreach_stmt" # Eval.g:188:1: foreach_stmt : ^( FOREACH expr ( ^( EACH k= ID v= each_val ) | ^( EACH v= each_val ) ) block ) ; def foreach_stmt(self, ): k = None v = None expr20 = None try: try: # Eval.g:189:2: ( ^( FOREACH expr ( ^( EACH k= ID v= each_val ) | ^( EACH v= each_val ) ) block ) ) # Eval.g:189:4: ^( FOREACH expr ( ^( EACH k= ID v= each_val ) | ^( EACH v= each_val ) ) block ) pass self.match(self.input, FOREACH, self.FOLLOW_FOREACH_in_foreach_stmt800) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_foreach_stmt802) expr20 = self.expr() self._state.following.pop() # Eval.g:190:3: ( ^( EACH k= ID v= each_val ) | ^( EACH v= each_val ) ) alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == EACH) : LA18_1 = self.input.LA(2) if (LA18_1 == 2) : LA18_2 = self.input.LA(3) if (LA18_2 == ID) : alt18 = 1 elif (LA18_2 == EACH_VAL) : alt18 = 2 else: nvae = NoViableAltException("", 18, 2, self.input) raise nvae else: nvae = NoViableAltException("", 18, 1, self.input) raise nvae else: nvae = NoViableAltException("", 18, 0, self.input) raise nvae if alt18 == 1: # Eval.g:190:5: ^( EACH k= ID v= each_val ) pass self.match(self.input, EACH, self.FOLLOW_EACH_in_foreach_stmt809) self.match(self.input, DOWN, None) k = self.match(self.input, ID, self.FOLLOW_ID_in_foreach_stmt813) self._state.following.append(self.FOLLOW_each_val_in_foreach_stmt817) v = self.each_val() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_foreach(expr20, k.text, v) #action end elif alt18 == 2: # Eval.g:192:5: ^( EACH v= each_val ) pass self.match(self.input, EACH, self.FOLLOW_EACH_in_foreach_stmt830) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_each_val_in_foreach_stmt834) v = self.each_val() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_foreach(expr20, None, v) #action end self._state.following.append(self.FOLLOW_block_in_foreach_stmt848) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "foreach_stmt" # $ANTLR start "each_val" # Eval.g:198:1: each_val returns [text] : ^( EACH_VAL ( ID )+ ) ; def each_val(self, ): text = None ID21 = None ps = [] try: try: # Eval.g:200:2: ( ^( EACH_VAL ( ID )+ ) ) # Eval.g:200:4: ^( EACH_VAL ( ID )+ ) pass self.match(self.input, EACH_VAL, self.FOLLOW_EACH_VAL_in_each_val871) self.match(self.input, DOWN, None) # Eval.g:200:15: ( ID )+ cnt19 = 0 while True: #loop19 alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == ID) : alt19 = 1 if alt19 == 1: # Eval.g:200:16: ID pass ID21 = self.match(self.input, ID, self.FOLLOW_ID_in_each_val874) #action start ps.append(ID21.text) #action end else: if cnt19 >= 1: break #loop19 eee = EarlyExitException(19, self.input) raise eee cnt19 += 1 self.match(self.input, UP, None) #action start text = ','.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "each_val" # $ANTLR start "throw_stmt" # Eval.g:205:1: throw_stmt : ^( THROW expr ) ; def throw_stmt(self, ): expr22 = None try: try: # Eval.g:206:2: ( ^( THROW expr ) ) # Eval.g:206:4: ^( THROW expr ) pass self.match(self.input, THROW, self.FOLLOW_THROW_in_throw_stmt897) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_throw_stmt899) expr22 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_throw(expr22) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "throw_stmt" # $ANTLR start "try_stmt" # Eval.g:209:1: try_stmt : ^( TRY block ( catch_clause )+ ( finally_clause )? ) ; def try_stmt(self, ): self.cpy.op_try() try: try: # Eval.g:211:2: ( ^( TRY block ( catch_clause )+ ( finally_clause )? ) ) # Eval.g:211:4: ^( TRY block ( catch_clause )+ ( finally_clause )? ) pass self.match(self.input, TRY, self.FOLLOW_TRY_in_try_stmt920) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_block_in_try_stmt922) self.block() self._state.following.pop() # Eval.g:211:16: ( catch_clause )+ cnt20 = 0 while True: #loop20 alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == CATCH) : alt20 = 1 if alt20 == 1: # Eval.g:211:16: catch_clause pass self._state.following.append(self.FOLLOW_catch_clause_in_try_stmt924) self.catch_clause() self._state.following.pop() else: if cnt20 >= 1: break #loop20 eee = EarlyExitException(20, self.input) raise eee cnt20 += 1 # Eval.g:211:30: ( finally_clause )? alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == FINALLY) : alt21 = 1 if alt21 == 1: # Eval.g:211:30: finally_clause pass self._state.following.append(self.FOLLOW_finally_clause_in_try_stmt927) self.finally_clause() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "try_stmt" # $ANTLR start "catch_clause" # Eval.g:213:1: catch_clause : ^( CATCH module ( ID )? block ) ; def catch_clause(self, ): ID24 = None module23 = None try: try: # Eval.g:214:2: ( ^( CATCH module ( ID )? block ) ) # Eval.g:214:4: ^( CATCH module ( ID )? block ) pass self.match(self.input, CATCH, self.FOLLOW_CATCH_in_catch_clause940) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_module_in_catch_clause942) module23 = self.module() self._state.following.pop() # Eval.g:214:19: ( ID )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == ID) : alt22 = 1 if alt22 == 1: # Eval.g:214:19: ID pass ID24 = self.match(self.input, ID, self.FOLLOW_ID_in_catch_clause944) #action start self.cpy.op_catch(module23, ID24.text) #action end self._state.following.append(self.FOLLOW_block_in_catch_clause953) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "catch_clause" # $ANTLR start "finally_clause" # Eval.g:218:1: finally_clause : ^( FINALLY block ) ; def finally_clause(self, ): self.cpy.op_finally() try: try: # Eval.g:220:2: ( ^( FINALLY block ) ) # Eval.g:220:4: ^( FINALLY block ) pass self.match(self.input, FINALLY, self.FOLLOW_FINALLY_in_finally_clause970) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_block_in_finally_clause972) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "finally_clause" # $ANTLR start "func_decl" # Eval.g:224:1: func_decl : ^( FUNCTION ID params block ) ; def func_decl(self, ): ID25 = None params26 = None try: try: # Eval.g:225:2: ( ^( FUNCTION ID params block ) ) # Eval.g:225:4: ^( FUNCTION ID params block ) pass self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_func_decl986) self.match(self.input, DOWN, None) ID25 = self.match(self.input, ID, self.FOLLOW_ID_in_func_decl988) self._state.following.append(self.FOLLOW_params_in_func_decl990) params26 = self.params() self._state.following.pop() #action start self.cpy.op_function(ID25.text, params26) #action end self._state.following.append(self.FOLLOW_block_in_func_decl998) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "func_decl" # $ANTLR start "params" # Eval.g:230:1: params returns [text] : ^( PARAMS ( param_decl )* ) ; def params(self, ): text = None param_decl27 = None ps = [] try: try: # Eval.g:232:2: ( ^( PARAMS ( param_decl )* ) ) # Eval.g:232:4: ^( PARAMS ( param_decl )* ) pass self.match(self.input, PARAMS, self.FOLLOW_PARAMS_in_params1021) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:232:13: ( param_decl )* while True: #loop23 alt23 = 2 LA23_0 = self.input.LA(1) if (LA23_0 == ID) : alt23 = 1 if alt23 == 1: # Eval.g:232:14: param_decl pass self._state.following.append(self.FOLLOW_param_decl_in_params1024) param_decl27 = self.param_decl() self._state.following.pop() #action start ps.append(param_decl27) #action end else: break #loop23 self.match(self.input, UP, None) #action start text = ', '.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "params" # $ANTLR start "param_decl" # Eval.g:235:1: param_decl returns [text] : ID ( '=' atom )? ; def param_decl(self, ): text = None ID28 = None atom29 = None try: try: # Eval.g:236:2: ( ID ( '=' atom )? ) # Eval.g:236:4: ID ( '=' atom )? pass ID28 = self.match(self.input, ID, self.FOLLOW_ID_in_param_decl1048) #action start text = ID28.text #action end # Eval.g:238:3: ( '=' atom )? alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == 95) : alt24 = 1 if alt24 == 1: # Eval.g:238:4: '=' atom pass self.match(self.input, 95, self.FOLLOW_95_in_param_decl1057) self._state.following.append(self.FOLLOW_atom_in_param_decl1059) atom29 = self.atom() self._state.following.pop() #action start text += ('=' + atom29) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "param_decl" # $ANTLR start "class_decl" # Eval.g:244:1: class_decl : ( ^( CLASS a= ID ( class_element )* ) | ^( CLASS b= ID c= ID ( class_element )* ) ); def class_decl(self, ): a = None b = None c = None try: try: # Eval.g:246:2: ( ^( CLASS a= ID ( class_element )* ) | ^( CLASS b= ID c= ID ( class_element )* ) ) alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == CLASS) : LA27_1 = self.input.LA(2) if (LA27_1 == 2) : LA27_2 = self.input.LA(3) if (LA27_2 == ID) : LA27_3 = self.input.LA(4) if (LA27_3 == ID) : alt27 = 2 elif (LA27_3 == 3 or LA27_3 == CONSTRUCTOR or LA27_3 == FUNCTION or LA27_3 == VAR) : alt27 = 1 else: nvae = NoViableAltException("", 27, 3, self.input) raise nvae else: nvae = NoViableAltException("", 27, 2, self.input) raise nvae else: nvae = NoViableAltException("", 27, 1, self.input) raise nvae else: nvae = NoViableAltException("", 27, 0, self.input) raise nvae if alt27 == 1: # Eval.g:246:4: ^( CLASS a= ID ( class_element )* ) pass self.match(self.input, CLASS, self.FOLLOW_CLASS_in_class_decl1087) self.match(self.input, DOWN, None) a = self.match(self.input, ID, self.FOLLOW_ID_in_class_decl1091) #action start self.cpy.op_class_enter(a.text, None) #action end # Eval.g:248:3: ( class_element )* while True: #loop25 alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == CONSTRUCTOR or LA25_0 == FUNCTION or LA25_0 == VAR) : alt25 = 1 if alt25 == 1: # Eval.g:248:3: class_element pass self._state.following.append(self.FOLLOW_class_element_in_class_decl1100) self.class_element() self._state.following.pop() else: break #loop25 self.match(self.input, UP, None) elif alt27 == 2: # Eval.g:249:4: ^( CLASS b= ID c= ID ( class_element )* ) pass self.match(self.input, CLASS, self.FOLLOW_CLASS_in_class_decl1108) self.match(self.input, DOWN, None) b = self.match(self.input, ID, self.FOLLOW_ID_in_class_decl1112) c = self.match(self.input, ID, self.FOLLOW_ID_in_class_decl1116) #action start self.cpy.op_class_enter(b.text, c.text) #action end # Eval.g:251:3: ( class_element )* while True: #loop26 alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == CONSTRUCTOR or LA26_0 == FUNCTION or LA26_0 == VAR) : alt26 = 1 if alt26 == 1: # Eval.g:251:3: class_element pass self._state.following.append(self.FOLLOW_class_element_in_class_decl1125) self.class_element() self._state.following.pop() else: break #loop26 self.match(self.input, UP, None) #action start self.cpy.op_class_leave() #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "class_decl" # $ANTLR start "class_element" # Eval.g:253:1: class_element : ( var_def | constructor | func_decl ); def class_element(self, ): try: try: # Eval.g:254:2: ( var_def | constructor | func_decl ) alt28 = 3 LA28 = self.input.LA(1) if LA28 == VAR: alt28 = 1 elif LA28 == CONSTRUCTOR: alt28 = 2 elif LA28 == FUNCTION: alt28 = 3 else: nvae = NoViableAltException("", 28, 0, self.input) raise nvae if alt28 == 1: # Eval.g:254:4: var_def pass self._state.following.append(self.FOLLOW_var_def_in_class_element1137) self.var_def() self._state.following.pop() elif alt28 == 2: # Eval.g:254:14: constructor pass self._state.following.append(self.FOLLOW_constructor_in_class_element1141) self.constructor() self._state.following.pop() elif alt28 == 3: # Eval.g:254:28: func_decl pass self._state.following.append(self.FOLLOW_func_decl_in_class_element1145) self.func_decl() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "class_element" # $ANTLR start "var_def" # Eval.g:256:1: var_def : ( ^( VAR ID ( expr )? ) | ^( VAR 'static' ID ( expr )? ) ); def var_def(self, ): ID30 = None ID32 = None expr31 = None expr33 = None try: try: # Eval.g:257:2: ( ^( VAR ID ( expr )? ) | ^( VAR 'static' ID ( expr )? ) ) alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == VAR) : LA31_1 = self.input.LA(2) if (LA31_1 == 2) : LA31_2 = self.input.LA(3) if (LA31_2 == ID) : alt31 = 1 elif (LA31_2 == 127) : alt31 = 2 else: nvae = NoViableAltException("", 31, 2, self.input) raise nvae else: nvae = NoViableAltException("", 31, 1, self.input) raise nvae else: nvae = NoViableAltException("", 31, 0, self.input) raise nvae if alt31 == 1: # Eval.g:257:4: ^( VAR ID ( expr )? ) pass self.match(self.input, VAR, self.FOLLOW_VAR_in_var_def1156) self.match(self.input, DOWN, None) ID30 = self.match(self.input, ID, self.FOLLOW_ID_in_var_def1158) # Eval.g:257:13: ( expr )? alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == ARRAY or LA29_0 == BOOL or LA29_0 == FLOAT or LA29_0 == INT or LA29_0 == MEMBER or (NEGATIVE <= LA29_0 <= NEW) or (NULL <= LA29_0 <= OBJECT) or (SPRINTF <= LA29_0 <= STRING) or (68 <= LA29_0 <= 70) or (72 <= LA29_0 <= 73) or LA29_0 == 77 or LA29_0 == 79 or LA29_0 == 83 or LA29_0 == 89 or (93 <= LA29_0 <= 94) or LA29_0 == 96 or (98 <= LA29_0 <= 99) or LA29_0 == 102 or LA29_0 == 133 or LA29_0 == 135) : alt29 = 1 if alt29 == 1: # Eval.g:257:13: expr pass self._state.following.append(self.FOLLOW_expr_in_var_def1160) expr31 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_var_def(False, ID30.text, expr31) #action end elif alt31 == 2: # Eval.g:259:4: ^( VAR 'static' ID ( expr )? ) pass self.match(self.input, VAR, self.FOLLOW_VAR_in_var_def1172) self.match(self.input, DOWN, None) self.match(self.input, 127, self.FOLLOW_127_in_var_def1174) ID32 = self.match(self.input, ID, self.FOLLOW_ID_in_var_def1176) # Eval.g:259:22: ( expr )? alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == ARRAY or LA30_0 == BOOL or LA30_0 == FLOAT or LA30_0 == INT or LA30_0 == MEMBER or (NEGATIVE <= LA30_0 <= NEW) or (NULL <= LA30_0 <= OBJECT) or (SPRINTF <= LA30_0 <= STRING) or (68 <= LA30_0 <= 70) or (72 <= LA30_0 <= 73) or LA30_0 == 77 or LA30_0 == 79 or LA30_0 == 83 or LA30_0 == 89 or (93 <= LA30_0 <= 94) or LA30_0 == 96 or (98 <= LA30_0 <= 99) or LA30_0 == 102 or LA30_0 == 133 or LA30_0 == 135) : alt30 = 1 if alt30 == 1: # Eval.g:259:22: expr pass self._state.following.append(self.FOLLOW_expr_in_var_def1178) expr33 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start self.cpy.op_var_def(True, ID32.text, expr33) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "var_def" # $ANTLR start "constructor" # Eval.g:262:1: constructor : ^( CONSTRUCTOR params block ) ; def constructor(self, ): params34 = None try: try: # Eval.g:263:2: ( ^( CONSTRUCTOR params block ) ) # Eval.g:263:4: ^( CONSTRUCTOR params block ) pass self.match(self.input, CONSTRUCTOR, self.FOLLOW_CONSTRUCTOR_in_constructor1195) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_params_in_constructor1197) params34 = self.params() self._state.following.pop() #action start self.cpy.op_construct(params34) #action end self._state.following.append(self.FOLLOW_block_in_constructor1205) self.block() self._state.following.pop() self.match(self.input, UP, None) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "constructor" # $ANTLR start "module" # Eval.g:270:1: module returns [text] : ^( MODULE ( ID )+ ) ; def module(self, ): text = None ID35 = None ps = [] try: try: # Eval.g:272:2: ( ^( MODULE ( ID )+ ) ) # Eval.g:272:4: ^( MODULE ( ID )+ ) pass self.match(self.input, MODULE, self.FOLLOW_MODULE_in_module1229) self.match(self.input, DOWN, None) # Eval.g:272:13: ( ID )+ cnt32 = 0 while True: #loop32 alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == ID) : alt32 = 1 if alt32 == 1: # Eval.g:272:14: ID pass ID35 = self.match(self.input, ID, self.FOLLOW_ID_in_module1232) #action start ps.append(ID35.text) #action end else: if cnt32 >= 1: break #loop32 eee = EarlyExitException(32, self.input) raise eee cnt32 += 1 self.match(self.input, UP, None) #action start text = '.'.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "module" # $ANTLR start "member_expr" # Eval.g:276:1: member_expr returns [text] : ^( MEMBER ( primary )+ ) ; def member_expr(self, ): text = None primary36 = None ps = [] try: try: # Eval.g:278:2: ( ^( MEMBER ( primary )+ ) ) # Eval.g:278:4: ^( MEMBER ( primary )+ ) pass self.match(self.input, MEMBER, self.FOLLOW_MEMBER_in_member_expr1263) self.match(self.input, DOWN, None) # Eval.g:278:13: ( primary )+ cnt33 = 0 while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == ID) : alt33 = 1 if alt33 == 1: # Eval.g:278:14: primary pass self._state.following.append(self.FOLLOW_primary_in_member_expr1266) primary36 = self.primary() self._state.following.pop() #action start ps.append(primary36) #action end else: if cnt33 >= 1: break #loop33 eee = EarlyExitException(33, self.input) raise eee cnt33 += 1 self.match(self.input, UP, None) #action start text = '.'.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "member_expr" # $ANTLR start "primary" # Eval.g:281:1: primary returns [text] : ID ( index_expr )* ( call_expr )? ; def primary(self, ): text = None ID39 = None index_expr37 = None call_expr38 = None a='' try: try: # Eval.g:283:2: ( ID ( index_expr )* ( call_expr )? ) # Eval.g:283:4: ID ( index_expr )* ( call_expr )? pass ID39 = self.match(self.input, ID, self.FOLLOW_ID_in_primary1295) # Eval.g:283:7: ( index_expr )* while True: #loop34 alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == INDEX or LA34_0 == SLICE) : alt34 = 1 if alt34 == 1: # Eval.g:283:8: index_expr pass self._state.following.append(self.FOLLOW_index_expr_in_primary1298) index_expr37 = self.index_expr() self._state.following.pop() #action start a += index_expr37 #action end else: break #loop34 # Eval.g:284:3: ( call_expr )? alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == CALL) : alt35 = 1 if alt35 == 1: # Eval.g:284:3: call_expr pass self._state.following.append(self.FOLLOW_call_expr_in_primary1305) call_expr38 = self.call_expr() self._state.following.pop() #action start b = call_expr38 if b == None: b = '' text = ID39.text + a + b #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "primary" # $ANTLR start "call_expr" # Eval.g:291:1: call_expr returns [text] : ^( CALL ( expr_list )? ) ; def call_expr(self, ): text = None expr_list40 = None try: try: # Eval.g:292:2: ( ^( CALL ( expr_list )? ) ) # Eval.g:292:4: ^( CALL ( expr_list )? ) pass self.match(self.input, CALL, self.FOLLOW_CALL_in_call_expr1324) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:292:11: ( expr_list )? alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == EXPR_LIST) : alt36 = 1 if alt36 == 1: # Eval.g:292:11: expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_call_expr1326) expr_list40 = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start s = expr_list40 if s == None: s = '' text = '(' + s + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "call_expr" # $ANTLR start "index_expr" # Eval.g:299:1: index_expr returns [text] : ( ^( INDEX expr ) | ^( SLICE a= expr (b= expr )? ) ); def index_expr(self, ): text = None a = None b = None expr41 = None try: try: # Eval.g:300:2: ( ^( INDEX expr ) | ^( SLICE a= expr (b= expr )? ) ) alt38 = 2 LA38_0 = self.input.LA(1) if (LA38_0 == INDEX) : alt38 = 1 elif (LA38_0 == SLICE) : alt38 = 2 else: nvae = NoViableAltException("", 38, 0, self.input) raise nvae if alt38 == 1: # Eval.g:300:4: ^( INDEX expr ) pass self.match(self.input, INDEX, self.FOLLOW_INDEX_in_index_expr1346) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_index_expr1348) expr41 = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = '[' + expr41 + ']' #action end elif alt38 == 2: # Eval.g:302:4: ^( SLICE a= expr (b= expr )? ) pass self.match(self.input, SLICE, self.FOLLOW_SLICE_in_index_expr1359) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_index_expr1363) a = self.expr() self._state.following.pop() # Eval.g:302:20: (b= expr )? alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == ARRAY or LA37_0 == BOOL or LA37_0 == FLOAT or LA37_0 == INT or LA37_0 == MEMBER or (NEGATIVE <= LA37_0 <= NEW) or (NULL <= LA37_0 <= OBJECT) or (SPRINTF <= LA37_0 <= STRING) or (68 <= LA37_0 <= 70) or (72 <= LA37_0 <= 73) or LA37_0 == 77 or LA37_0 == 79 or LA37_0 == 83 or LA37_0 == 89 or (93 <= LA37_0 <= 94) or LA37_0 == 96 or (98 <= LA37_0 <= 99) or LA37_0 == 102 or LA37_0 == 133 or LA37_0 == 135) : alt37 = 1 if alt37 == 1: # Eval.g:302:20: b= expr pass self._state.following.append(self.FOLLOW_expr_in_index_expr1367) b = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start s = b if s == None: s = '' text = '[%s : %s]' %(a, s) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "index_expr" # $ANTLR start "expr_list" # Eval.g:311:1: expr_list returns [text] : ^( EXPR_LIST ( expr )+ ) ; def expr_list(self, ): text = None expr42 = None ps = [] try: try: # Eval.g:313:2: ( ^( EXPR_LIST ( expr )+ ) ) # Eval.g:313:4: ^( EXPR_LIST ( expr )+ ) pass self.match(self.input, EXPR_LIST, self.FOLLOW_EXPR_LIST_in_expr_list1394) self.match(self.input, DOWN, None) # Eval.g:313:16: ( expr )+ cnt39 = 0 while True: #loop39 alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == ARRAY or LA39_0 == BOOL or LA39_0 == FLOAT or LA39_0 == INT or LA39_0 == MEMBER or (NEGATIVE <= LA39_0 <= NEW) or (NULL <= LA39_0 <= OBJECT) or (SPRINTF <= LA39_0 <= STRING) or (68 <= LA39_0 <= 70) or (72 <= LA39_0 <= 73) or LA39_0 == 77 or LA39_0 == 79 or LA39_0 == 83 or LA39_0 == 89 or (93 <= LA39_0 <= 94) or LA39_0 == 96 or (98 <= LA39_0 <= 99) or LA39_0 == 102 or LA39_0 == 133 or LA39_0 == 135) : alt39 = 1 if alt39 == 1: # Eval.g:313:17: expr pass self._state.following.append(self.FOLLOW_expr_in_expr_list1397) expr42 = self.expr() self._state.following.pop() #action start ps.append(expr42) #action end else: if cnt39 >= 1: break #loop39 eee = EarlyExitException(39, self.input) raise eee cnt39 += 1 self.match(self.input, UP, None) #action start text = ', '.join(ps) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "expr_list" # $ANTLR start "expr" # Eval.g:319:1: expr returns [text] : (a= relation_expr |a= logic_or_expr |a= logic_and_expr |a= bitwise_or_expr |a= bitwise_xor_expr |a= bitwise_and_expr |a= add_expr |a= mul_expr |a= not_expr |a= negative_expr |a= atom ); def expr(self, ): text = None a = None try: try: # Eval.g:320:2: (a= relation_expr |a= logic_or_expr |a= logic_and_expr |a= bitwise_or_expr |a= bitwise_xor_expr |a= bitwise_and_expr |a= add_expr |a= mul_expr |a= not_expr |a= negative_expr |a= atom ) alt40 = 11 LA40 = self.input.LA(1) if LA40 == 69 or LA40 == 93 or LA40 == 94 or LA40 == 96 or LA40 == 98 or LA40 == 99: alt40 = 1 elif LA40 == 135: alt40 = 2 elif LA40 == 72: alt40 = 3 elif LA40 == 133: alt40 = 4 elif LA40 == 102: alt40 = 5 elif LA40 == 73: alt40 = 6 elif LA40 == 79 or LA40 == 83: alt40 = 7 elif LA40 == 70 or LA40 == 77 or LA40 == 89: alt40 = 8 elif LA40 == 68: alt40 = 9 elif LA40 == NEGATIVE: alt40 = 10 elif LA40 == ARRAY or LA40 == BOOL or LA40 == FLOAT or LA40 == INT or LA40 == MEMBER or LA40 == NEW or LA40 == NULL or LA40 == OBJECT or LA40 == SPRINTF or LA40 == STRING: alt40 = 11 else: nvae = NoViableAltException("", 40, 0, self.input) raise nvae if alt40 == 1: # Eval.g:320:4: a= relation_expr pass self._state.following.append(self.FOLLOW_relation_expr_in_expr1423) a = self.relation_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 2: # Eval.g:321:4: a= logic_or_expr pass self._state.following.append(self.FOLLOW_logic_or_expr_in_expr1432) a = self.logic_or_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 3: # Eval.g:322:4: a= logic_and_expr pass self._state.following.append(self.FOLLOW_logic_and_expr_in_expr1441) a = self.logic_and_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 4: # Eval.g:323:4: a= bitwise_or_expr pass self._state.following.append(self.FOLLOW_bitwise_or_expr_in_expr1450) a = self.bitwise_or_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 5: # Eval.g:324:4: a= bitwise_xor_expr pass self._state.following.append(self.FOLLOW_bitwise_xor_expr_in_expr1459) a = self.bitwise_xor_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 6: # Eval.g:325:4: a= bitwise_and_expr pass self._state.following.append(self.FOLLOW_bitwise_and_expr_in_expr1468) a = self.bitwise_and_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 7: # Eval.g:326:4: a= add_expr pass self._state.following.append(self.FOLLOW_add_expr_in_expr1477) a = self.add_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 8: # Eval.g:327:4: a= mul_expr pass self._state.following.append(self.FOLLOW_mul_expr_in_expr1487) a = self.mul_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 9: # Eval.g:328:4: a= not_expr pass self._state.following.append(self.FOLLOW_not_expr_in_expr1497) a = self.not_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 10: # Eval.g:329:4: a= negative_expr pass self._state.following.append(self.FOLLOW_negative_expr_in_expr1507) a = self.negative_expr() self._state.following.pop() #action start text = a #action end elif alt40 == 11: # Eval.g:330:4: a= atom pass self._state.following.append(self.FOLLOW_atom_in_expr1516) a = self.atom() self._state.following.pop() #action start text = a #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "expr" # $ANTLR start "logic_or_expr" # Eval.g:332:1: logic_or_expr returns [text] : ^( '||' b= expr c= expr ) ; def logic_or_expr(self, ): text = None b = None c = None try: try: # Eval.g:333:2: ( ^( '||' b= expr c= expr ) ) # Eval.g:333:4: ^( '||' b= expr c= expr ) pass self.match(self.input, 135, self.FOLLOW_135_in_logic_or_expr1534) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_logic_or_expr1538) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_logic_or_expr1542) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = '(' + b + ' or ' + c + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "logic_or_expr" # $ANTLR start "logic_and_expr" # Eval.g:336:1: logic_and_expr returns [text] : ^( '&&' b= expr c= expr ) ; def logic_and_expr(self, ): text = None b = None c = None try: try: # Eval.g:337:2: ( ^( '&&' b= expr c= expr ) ) # Eval.g:337:4: ^( '&&' b= expr c= expr ) pass self.match(self.input, 72, self.FOLLOW_72_in_logic_and_expr1561) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_logic_and_expr1565) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_logic_and_expr1569) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' and ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "logic_and_expr" # $ANTLR start "bitwise_or_expr" # Eval.g:340:1: bitwise_or_expr returns [text] : ^( '|' b= expr c= expr ) ; def bitwise_or_expr(self, ): text = None b = None c = None try: try: # Eval.g:341:2: ( ^( '|' b= expr c= expr ) ) # Eval.g:341:4: ^( '|' b= expr c= expr ) pass self.match(self.input, 133, self.FOLLOW_133_in_bitwise_or_expr1588) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_bitwise_or_expr1592) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_bitwise_or_expr1596) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' | ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "bitwise_or_expr" # $ANTLR start "bitwise_xor_expr" # Eval.g:344:1: bitwise_xor_expr returns [text] : ^( '^' b= expr c= expr ) ; def bitwise_xor_expr(self, ): text = None b = None c = None try: try: # Eval.g:345:2: ( ^( '^' b= expr c= expr ) ) # Eval.g:345:4: ^( '^' b= expr c= expr ) pass self.match(self.input, 102, self.FOLLOW_102_in_bitwise_xor_expr1615) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_bitwise_xor_expr1619) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_bitwise_xor_expr1623) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' ^ ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "bitwise_xor_expr" # $ANTLR start "bitwise_and_expr" # Eval.g:348:1: bitwise_and_expr returns [text] : ^( '&' b= expr c= expr ) ; def bitwise_and_expr(self, ): text = None b = None c = None try: try: # Eval.g:349:2: ( ^( '&' b= expr c= expr ) ) # Eval.g:349:4: ^( '&' b= expr c= expr ) pass self.match(self.input, 73, self.FOLLOW_73_in_bitwise_and_expr1642) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_bitwise_and_expr1646) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_bitwise_and_expr1650) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' & ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "bitwise_and_expr" # $ANTLR start "relation_expr" # Eval.g:352:1: relation_expr returns [text] : ^(op= ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) b= expr c= expr ) ; def relation_expr(self, ): text = None op = None b = None c = None try: try: # Eval.g:353:2: ( ^(op= ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) b= expr c= expr ) ) # Eval.g:353:4: ^(op= ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) b= expr c= expr ) pass op = self.input.LT(1) if self.input.LA(1) == 69 or (93 <= self.input.LA(1) <= 94) or self.input.LA(1) == 96 or (98 <= self.input.LA(1) <= 99): self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_relation_expr1687) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_relation_expr1691) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + op.text + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "relation_expr" # $ANTLR start "add_expr" # Eval.g:356:1: add_expr returns [text] : ^(op= ( '+' | '-' ) b= expr c= expr ) ; def add_expr(self, ): text = None op = None b = None c = None try: try: # Eval.g:357:2: ( ^(op= ( '+' | '-' ) b= expr c= expr ) ) # Eval.g:357:4: ^(op= ( '+' | '-' ) b= expr c= expr ) pass op = self.input.LT(1) if self.input.LA(1) == 79 or self.input.LA(1) == 83: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_add_expr1720) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_add_expr1724) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = '(' + b + ' ' + op.text + ' ' + c + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "add_expr" # $ANTLR start "mul_expr" # Eval.g:360:1: mul_expr returns [text] : ^(op= ( '*' | '/' | '%' ) b= expr c= expr ) ; def mul_expr(self, ): text = None op = None b = None c = None try: try: # Eval.g:361:2: ( ^(op= ( '*' | '/' | '%' ) b= expr c= expr ) ) # Eval.g:361:4: ^(op= ( '*' | '/' | '%' ) b= expr c= expr ) pass op = self.input.LT(1) if self.input.LA(1) == 70 or self.input.LA(1) == 77 or self.input.LA(1) == 89: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_mul_expr1755) b = self.expr() self._state.following.pop() self._state.following.append(self.FOLLOW_expr_in_mul_expr1759) c = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = b + ' ' + op.text + ' ' + c #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "mul_expr" # $ANTLR start "not_expr" # Eval.g:364:1: not_expr returns [text] : ^( '!' a= expr ) ; def not_expr(self, ): text = None a = None try: try: # Eval.g:365:2: ( ^( '!' a= expr ) ) # Eval.g:365:4: ^( '!' a= expr ) pass self.match(self.input, 68, self.FOLLOW_68_in_not_expr1778) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_not_expr1782) a = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = 'not (' + a + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "not_expr" # $ANTLR start "negative_expr" # Eval.g:368:1: negative_expr returns [text] : ^( NEGATIVE a= expr ) ; def negative_expr(self, ): text = None a = None try: try: # Eval.g:369:2: ( ^( NEGATIVE a= expr ) ) # Eval.g:369:4: ^( NEGATIVE a= expr ) pass self.match(self.input, NEGATIVE, self.FOLLOW_NEGATIVE_in_negative_expr1801) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_negative_expr1805) a = self.expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = '- (' + a + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "negative_expr" # $ANTLR start "sprintf" # Eval.g:374:1: sprintf returns [text] : ^( SPRINTF expr (a= expr_list )? ) ; def sprintf(self, ): text = None a = None expr43 = None try: try: # Eval.g:375:2: ( ^( SPRINTF expr (a= expr_list )? ) ) # Eval.g:375:4: ^( SPRINTF expr (a= expr_list )? ) pass self.match(self.input, SPRINTF, self.FOLLOW_SPRINTF_in_sprintf1826) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_expr_in_sprintf1828) expr43 = self.expr() self._state.following.pop() # Eval.g:375:20: (a= expr_list )? alt41 = 2 LA41_0 = self.input.LA(1) if (LA41_0 == EXPR_LIST) : alt41 = 1 if alt41 == 1: # Eval.g:375:20: a= expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_sprintf1832) a = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start s = a if not s: s='' text = expr43 + '%(' + s + ')' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "sprintf" # $ANTLR start "new_clause" # Eval.g:383:1: new_clause returns [text] : ^( NEW module call_expr ) ; def new_clause(self, ): text = None module44 = None call_expr45 = None try: try: # Eval.g:384:2: ( ^( NEW module call_expr ) ) # Eval.g:384:4: ^( NEW module call_expr ) pass self.match(self.input, NEW, self.FOLLOW_NEW_in_new_clause1853) self.match(self.input, DOWN, None) self._state.following.append(self.FOLLOW_module_in_new_clause1855) module44 = self.module() self._state.following.pop() self._state.following.append(self.FOLLOW_call_expr_in_new_clause1857) call_expr45 = self.call_expr() self._state.following.pop() self.match(self.input, UP, None) #action start text = module44 + call_expr45 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "new_clause" # $ANTLR start "array_decl" # Eval.g:388:1: array_decl returns [text] : ^( ARRAY ( expr_list )? ) ; def array_decl(self, ): text = None expr_list46 = None try: try: # Eval.g:389:2: ( ^( ARRAY ( expr_list )? ) ) # Eval.g:389:4: ^( ARRAY ( expr_list )? ) pass self.match(self.input, ARRAY, self.FOLLOW_ARRAY_in_array_decl1877) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:389:12: ( expr_list )? alt42 = 2 LA42_0 = self.input.LA(1) if (LA42_0 == EXPR_LIST) : alt42 = 1 if alt42 == 1: # Eval.g:389:12: expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_array_decl1879) expr_list46 = self.expr_list() self._state.following.pop() self.match(self.input, UP, None) #action start s = expr_list46 if s == None: s = '' text = '[' + s + ']' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "array_decl" # $ANTLR start "object_decl" # Eval.g:396:1: object_decl returns [text] : ^( OBJECT ( property )* ) ; def object_decl(self, ): text = None property47 = None s = '' try: try: # Eval.g:398:2: ( ^( OBJECT ( property )* ) ) # Eval.g:398:4: ^( OBJECT ( property )* ) pass self.match(self.input, OBJECT, self.FOLLOW_OBJECT_in_object_decl1904) if self.input.LA(1) == DOWN: self.match(self.input, DOWN, None) # Eval.g:398:13: ( property )* while True: #loop43 alt43 = 2 LA43_0 = self.input.LA(1) if (LA43_0 == ID or LA43_0 == INT or LA43_0 == STRING) : alt43 = 1 if alt43 == 1: # Eval.g:398:14: property pass self._state.following.append(self.FOLLOW_property_in_object_decl1907) property47 = self.property() self._state.following.pop() #action start s += property47 #action end else: break #loop43 self.match(self.input, UP, None) #action start text = '{' + s + '}' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "object_decl" # $ANTLR start "property" # Eval.g:401:1: property returns [text] : a= ( ID | STRING | INT ) ':' expr ; def property(self, ): text = None a = None expr48 = None try: try: # Eval.g:402:2: (a= ( ID | STRING | INT ) ':' expr ) # Eval.g:402:4: a= ( ID | STRING | INT ) ':' expr pass a = self.input.LT(1) if self.input.LA(1) == ID or self.input.LA(1) == INT or self.input.LA(1) == STRING: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse self.match(self.input, 91, self.FOLLOW_91_in_property1944) self._state.following.append(self.FOLLOW_expr_in_property1946) expr48 = self.expr() self._state.following.pop() #action start text = a.text + ': ' + expr48 + ',' #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "property" # $ANTLR start "atom" # Eval.g:407:1: atom returns [text] : (a= literal |a= member_expr |a= new_clause |a= array_decl |a= object_decl |a= sprintf ); def atom(self, ): text = None a = None try: try: # Eval.g:408:2: (a= literal |a= member_expr |a= new_clause |a= array_decl |a= object_decl |a= sprintf ) alt44 = 6 LA44 = self.input.LA(1) if LA44 == BOOL or LA44 == FLOAT or LA44 == INT or LA44 == NULL or LA44 == STRING: alt44 = 1 elif LA44 == MEMBER: alt44 = 2 elif LA44 == NEW: alt44 = 3 elif LA44 == ARRAY: alt44 = 4 elif LA44 == OBJECT: alt44 = 5 elif LA44 == SPRINTF: alt44 = 6 else: nvae = NoViableAltException("", 44, 0, self.input) raise nvae if alt44 == 1: # Eval.g:408:4: a= literal pass self._state.following.append(self.FOLLOW_literal_in_atom1967) a = self.literal() self._state.following.pop() #action start text = a #action end elif alt44 == 2: # Eval.g:409:4: a= member_expr pass self._state.following.append(self.FOLLOW_member_expr_in_atom1977) a = self.member_expr() self._state.following.pop() #action start text = a #action end elif alt44 == 3: # Eval.g:410:4: a= new_clause pass self._state.following.append(self.FOLLOW_new_clause_in_atom1986) a = self.new_clause() self._state.following.pop() #action start text = a #action end elif alt44 == 4: # Eval.g:411:4: a= array_decl pass self._state.following.append(self.FOLLOW_array_decl_in_atom1995) a = self.array_decl() self._state.following.pop() #action start text = a #action end elif alt44 == 5: # Eval.g:412:4: a= object_decl pass self._state.following.append(self.FOLLOW_object_decl_in_atom2004) a = self.object_decl() self._state.following.pop() #action start text = a #action end elif alt44 == 6: # Eval.g:413:4: a= sprintf pass self._state.following.append(self.FOLLOW_sprintf_in_atom2013) a = self.sprintf() self._state.following.pop() #action start text = a #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "atom" # $ANTLR start "literal" # Eval.g:415:1: literal returns [text] : ( NULL | BOOL | INT | FLOAT | STRING ); def literal(self, ): text = None BOOL49 = None INT50 = None FLOAT51 = None STRING52 = None try: try: # Eval.g:416:2: ( NULL | BOOL | INT | FLOAT | STRING ) alt45 = 5 LA45 = self.input.LA(1) if LA45 == NULL: alt45 = 1 elif LA45 == BOOL: alt45 = 2 elif LA45 == INT: alt45 = 3 elif LA45 == FLOAT: alt45 = 4 elif LA45 == STRING: alt45 = 5 else: nvae = NoViableAltException("", 45, 0, self.input) raise nvae if alt45 == 1: # Eval.g:416:4: NULL pass self.match(self.input, NULL, self.FOLLOW_NULL_in_literal2029) #action start text = 'None' #action end elif alt45 == 2: # Eval.g:417:4: BOOL pass BOOL49 = self.match(self.input, BOOL, self.FOLLOW_BOOL_in_literal2036) #action start text = BOOL49.text.capitalize() #action end elif alt45 == 3: # Eval.g:418:4: INT pass INT50 = self.match(self.input, INT, self.FOLLOW_INT_in_literal2043) #action start text = INT50.text #action end elif alt45 == 4: # Eval.g:419:4: FLOAT pass FLOAT51 = self.match(self.input, FLOAT, self.FOLLOW_FLOAT_in_literal2050) #action start text = FLOAT51.text #action end elif alt45 == 5: # Eval.g:420:4: STRING pass STRING52 = self.match(self.input, STRING, self.FOLLOW_STRING_in_literal2057) #action start text = STRING52.text #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return text # $ANTLR end "literal" # lookup tables for DFA #4 DFA4_eot = DFA.unpack( u"\10\uffff" ) DFA4_eof = DFA.unpack( u"\10\uffff" ) DFA4_min = DFA.unpack( u"\1\3\1\uffff\1\2\1\42\2\3\2\uffff" ) DFA4_max = DFA.unpack( u"\1\52\1\uffff\1\2\2\42\1\127\2\uffff" ) DFA4_accept = DFA.unpack( u"\1\uffff\1\3\4\uffff\1\1\1\2" ) DFA4_special = DFA.unpack( u"\10\uffff" ) DFA4_transition = [ DFA.unpack(u"\1\1\46\uffff\1\2"), DFA.unpack(u""), DFA.unpack(u"\1\3"), DFA.unpack(u"\1\4"), DFA.unpack(u"\1\5\36\uffff\1\4"), DFA.unpack(u"\1\6\46\uffff\1\6\54\uffff\1\7"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #4 class DFA4(DFA): pass FOLLOW_stmt_in_prog69 = frozenset([1, 9, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_import_stmt_in_stmt81 = frozenset([1]) FOLLOW_exec_stmt_in_stmt86 = frozenset([1]) FOLLOW_print_stmt_in_stmt91 = frozenset([1]) FOLLOW_printf_stmt_in_stmt95 = frozenset([1]) FOLLOW_break_stmt_in_stmt100 = frozenset([1]) FOLLOW_continue_stmt_in_stmt105 = frozenset([1]) FOLLOW_return_stmt_in_stmt110 = frozenset([1]) FOLLOW_if_stmt_in_stmt115 = frozenset([1]) FOLLOW_while_stmt_in_stmt120 = frozenset([1]) FOLLOW_do_while_stmt_in_stmt125 = frozenset([1]) FOLLOW_switch_stmt_in_stmt130 = frozenset([1]) FOLLOW_throw_stmt_in_stmt135 = frozenset([1]) FOLLOW_try_stmt_in_stmt140 = frozenset([1]) FOLLOW_func_decl_in_stmt145 = frozenset([1]) FOLLOW_class_decl_in_stmt150 = frozenset([1]) FOLLOW_for_stmt_in_stmt155 = frozenset([1]) FOLLOW_foreach_stmt_in_stmt160 = frozenset([1]) FOLLOW_BLOCK_in_block185 = frozenset([2]) FOLLOW_stmt_in_block187 = frozenset([3, 9, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_IMPORT_in_import_stmt201 = frozenset([2]) FOLLOW_module_in_import_stmt209 = frozenset([3, 42]) FOLLOW_module_in_import_stmt222 = frozenset([87]) FOLLOW_87_in_import_stmt224 = frozenset([3, 42]) FOLLOW_EXEC_STMT_in_exec_stmt250 = frozenset([2]) FOLLOW_exec_list_in_exec_stmt252 = frozenset([3]) FOLLOW_member_expr_in_exec_expr270 = frozenset([1]) FOLLOW_ASSIGN_in_exec_expr280 = frozenset([2]) FOLLOW_member_expr_in_exec_expr282 = frozenset([71, 74, 78, 81, 85, 90, 95, 103, 134]) FOLLOW_set_in_exec_expr286 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_exec_expr306 = frozenset([3]) FOLLOW_POST_INC_in_exec_expr317 = frozenset([2]) FOLLOW_member_expr_in_exec_expr319 = frozenset([3]) FOLLOW_POST_DEC_in_exec_expr330 = frozenset([2]) FOLLOW_member_expr_in_exec_expr332 = frozenset([3]) FOLLOW_PRE_INC_in_exec_expr343 = frozenset([2]) FOLLOW_member_expr_in_exec_expr345 = frozenset([3]) FOLLOW_PRE_DEC_in_exec_expr356 = frozenset([2]) FOLLOW_member_expr_in_exec_expr358 = frozenset([3]) FOLLOW_EXEC_LIST_in_exec_list382 = frozenset([2]) FOLLOW_exec_expr_in_exec_list385 = frozenset([3, 6, 41, 51, 52, 53, 54]) FOLLOW_PRINTF_in_printf_stmt408 = frozenset([2]) FOLLOW_expr_in_printf_stmt410 = frozenset([3, 28]) FOLLOW_expr_list_in_printf_stmt412 = frozenset([3]) FOLLOW_PRINT_in_print_stmt429 = frozenset([2]) FOLLOW_expr_list_in_print_stmt431 = frozenset([3]) FOLLOW_BREAK_in_break_stmt451 = frozenset([1]) FOLLOW_CONTINUE_in_continue_stmt465 = frozenset([1]) FOLLOW_RETURN_in_return_stmt480 = frozenset([2]) FOLLOW_expr_in_return_stmt482 = frozenset([3]) FOLLOW_if_clause_in_if_stmt510 = frozenset([1, 23, 24]) FOLLOW_else_if_clause_in_if_stmt512 = frozenset([1, 23, 24]) FOLLOW_else_clause_in_if_stmt515 = frozenset([1]) FOLLOW_IF_in_if_clause527 = frozenset([2]) FOLLOW_expr_in_if_clause529 = frozenset([7]) FOLLOW_block_in_if_clause533 = frozenset([3]) FOLLOW_ELSE_IF_in_else_if_clause545 = frozenset([2]) FOLLOW_if_clause_in_else_if_clause549 = frozenset([3]) FOLLOW_ELSE_in_else_clause561 = frozenset([2]) FOLLOW_block_in_else_clause565 = frozenset([3]) FOLLOW_WHILE_in_while_stmt579 = frozenset([2]) FOLLOW_expr_in_while_stmt581 = frozenset([7]) FOLLOW_block_in_while_stmt585 = frozenset([3]) FOLLOW_DO_WHILE_in_do_while_stmt598 = frozenset([2]) FOLLOW_block_in_do_while_stmt604 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_do_while_stmt608 = frozenset([3]) FOLLOW_SWITCH_in_switch_stmt627 = frozenset([2]) FOLLOW_expr_in_switch_stmt629 = frozenset([132]) FOLLOW_case_block_in_switch_stmt633 = frozenset([3]) FOLLOW_132_in_case_block648 = frozenset([11]) FOLLOW_case_clause_in_case_block651 = frozenset([11, 17, 136]) FOLLOW_default_clause_in_case_block656 = frozenset([136]) FOLLOW_136_in_case_block660 = frozenset([1]) FOLLOW_CASE_in_case_clause676 = frozenset([2]) FOLLOW_case_test_in_case_clause678 = frozenset([9, 11, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_stmt_in_case_clause683 = frozenset([9, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_break_stmt_in_case_clause686 = frozenset([3]) FOLLOW_CASE_in_case_test702 = frozenset([2]) FOLLOW_expr_in_case_test704 = frozenset([3]) FOLLOW_DEFAULT_in_default_clause725 = frozenset([2]) FOLLOW_stmt_in_default_clause727 = frozenset([3, 9, 13, 16, 20, 27, 31, 32, 33, 36, 37, 55, 56, 57, 62, 63, 64, 66]) FOLLOW_FOR_in_for_stmt746 = frozenset([2]) FOLLOW_exec_list_in_for_stmt751 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_for_stmt759 = frozenset([7]) FOLLOW_block_in_for_stmt765 = frozenset([3, 26]) FOLLOW_exec_list_in_for_stmt776 = frozenset([3]) FOLLOW_FOREACH_in_foreach_stmt800 = frozenset([2]) FOLLOW_expr_in_foreach_stmt802 = frozenset([21]) FOLLOW_EACH_in_foreach_stmt809 = frozenset([2]) FOLLOW_ID_in_foreach_stmt813 = frozenset([22]) FOLLOW_each_val_in_foreach_stmt817 = frozenset([3]) FOLLOW_EACH_in_foreach_stmt830 = frozenset([2]) FOLLOW_each_val_in_foreach_stmt834 = frozenset([3]) FOLLOW_block_in_foreach_stmt848 = frozenset([3]) FOLLOW_EACH_VAL_in_each_val871 = frozenset([2]) FOLLOW_ID_in_each_val874 = frozenset([3, 34]) FOLLOW_THROW_in_throw_stmt897 = frozenset([2]) FOLLOW_expr_in_throw_stmt899 = frozenset([3]) FOLLOW_TRY_in_try_stmt920 = frozenset([2]) FOLLOW_block_in_try_stmt922 = frozenset([12]) FOLLOW_catch_clause_in_try_stmt924 = frozenset([3, 12, 29]) FOLLOW_finally_clause_in_try_stmt927 = frozenset([3]) FOLLOW_CATCH_in_catch_clause940 = frozenset([2]) FOLLOW_module_in_catch_clause942 = frozenset([7, 34]) FOLLOW_ID_in_catch_clause944 = frozenset([7]) FOLLOW_block_in_catch_clause953 = frozenset([3]) FOLLOW_FINALLY_in_finally_clause970 = frozenset([2]) FOLLOW_block_in_finally_clause972 = frozenset([3]) FOLLOW_FUNCTION_in_func_decl986 = frozenset([2]) FOLLOW_ID_in_func_decl988 = frozenset([50]) FOLLOW_params_in_func_decl990 = frozenset([7]) FOLLOW_block_in_func_decl998 = frozenset([3]) FOLLOW_PARAMS_in_params1021 = frozenset([2]) FOLLOW_param_decl_in_params1024 = frozenset([3, 34]) FOLLOW_ID_in_param_decl1048 = frozenset([1, 95]) FOLLOW_95_in_param_decl1057 = frozenset([5, 8, 30, 39, 41, 44, 47, 48, 60, 61]) FOLLOW_atom_in_param_decl1059 = frozenset([1]) FOLLOW_CLASS_in_class_decl1087 = frozenset([2]) FOLLOW_ID_in_class_decl1091 = frozenset([3, 15, 33, 65]) FOLLOW_class_element_in_class_decl1100 = frozenset([3, 15, 33, 65]) FOLLOW_CLASS_in_class_decl1108 = frozenset([2]) FOLLOW_ID_in_class_decl1112 = frozenset([34]) FOLLOW_ID_in_class_decl1116 = frozenset([3, 15, 33, 65]) FOLLOW_class_element_in_class_decl1125 = frozenset([3, 15, 33, 65]) FOLLOW_var_def_in_class_element1137 = frozenset([1]) FOLLOW_constructor_in_class_element1141 = frozenset([1]) FOLLOW_func_decl_in_class_element1145 = frozenset([1]) FOLLOW_VAR_in_var_def1156 = frozenset([2]) FOLLOW_ID_in_var_def1158 = frozenset([3, 5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_var_def1160 = frozenset([3]) FOLLOW_VAR_in_var_def1172 = frozenset([2]) FOLLOW_127_in_var_def1174 = frozenset([34]) FOLLOW_ID_in_var_def1176 = frozenset([3, 5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_var_def1178 = frozenset([3]) FOLLOW_CONSTRUCTOR_in_constructor1195 = frozenset([2]) FOLLOW_params_in_constructor1197 = frozenset([7]) FOLLOW_block_in_constructor1205 = frozenset([3]) FOLLOW_MODULE_in_module1229 = frozenset([2]) FOLLOW_ID_in_module1232 = frozenset([3, 34]) FOLLOW_MEMBER_in_member_expr1263 = frozenset([2]) FOLLOW_primary_in_member_expr1266 = frozenset([3, 34]) FOLLOW_ID_in_primary1295 = frozenset([1, 10, 38, 59]) FOLLOW_index_expr_in_primary1298 = frozenset([1, 10, 38, 59]) FOLLOW_call_expr_in_primary1305 = frozenset([1]) FOLLOW_CALL_in_call_expr1324 = frozenset([2]) FOLLOW_expr_list_in_call_expr1326 = frozenset([3]) FOLLOW_INDEX_in_index_expr1346 = frozenset([2]) FOLLOW_expr_in_index_expr1348 = frozenset([3]) FOLLOW_SLICE_in_index_expr1359 = frozenset([2]) FOLLOW_expr_in_index_expr1363 = frozenset([3, 5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_index_expr1367 = frozenset([3]) FOLLOW_EXPR_LIST_in_expr_list1394 = frozenset([2]) FOLLOW_expr_in_expr_list1397 = frozenset([3, 5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_relation_expr_in_expr1423 = frozenset([1]) FOLLOW_logic_or_expr_in_expr1432 = frozenset([1]) FOLLOW_logic_and_expr_in_expr1441 = frozenset([1]) FOLLOW_bitwise_or_expr_in_expr1450 = frozenset([1]) FOLLOW_bitwise_xor_expr_in_expr1459 = frozenset([1]) FOLLOW_bitwise_and_expr_in_expr1468 = frozenset([1]) FOLLOW_add_expr_in_expr1477 = frozenset([1]) FOLLOW_mul_expr_in_expr1487 = frozenset([1]) FOLLOW_not_expr_in_expr1497 = frozenset([1]) FOLLOW_negative_expr_in_expr1507 = frozenset([1]) FOLLOW_atom_in_expr1516 = frozenset([1]) FOLLOW_135_in_logic_or_expr1534 = frozenset([2]) FOLLOW_expr_in_logic_or_expr1538 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_logic_or_expr1542 = frozenset([3]) FOLLOW_72_in_logic_and_expr1561 = frozenset([2]) FOLLOW_expr_in_logic_and_expr1565 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_logic_and_expr1569 = frozenset([3]) FOLLOW_133_in_bitwise_or_expr1588 = frozenset([2]) FOLLOW_expr_in_bitwise_or_expr1592 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_bitwise_or_expr1596 = frozenset([3]) FOLLOW_102_in_bitwise_xor_expr1615 = frozenset([2]) FOLLOW_expr_in_bitwise_xor_expr1619 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_bitwise_xor_expr1623 = frozenset([3]) FOLLOW_73_in_bitwise_and_expr1642 = frozenset([2]) FOLLOW_expr_in_bitwise_and_expr1646 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_bitwise_and_expr1650 = frozenset([3]) FOLLOW_set_in_relation_expr1671 = frozenset([2]) FOLLOW_expr_in_relation_expr1687 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_relation_expr1691 = frozenset([3]) FOLLOW_set_in_add_expr1712 = frozenset([2]) FOLLOW_expr_in_add_expr1720 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_add_expr1724 = frozenset([3]) FOLLOW_set_in_mul_expr1745 = frozenset([2]) FOLLOW_expr_in_mul_expr1755 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_mul_expr1759 = frozenset([3]) FOLLOW_68_in_not_expr1778 = frozenset([2]) FOLLOW_expr_in_not_expr1782 = frozenset([3]) FOLLOW_NEGATIVE_in_negative_expr1801 = frozenset([2]) FOLLOW_expr_in_negative_expr1805 = frozenset([3]) FOLLOW_SPRINTF_in_sprintf1826 = frozenset([2]) FOLLOW_expr_in_sprintf1828 = frozenset([3, 28]) FOLLOW_expr_list_in_sprintf1832 = frozenset([3]) FOLLOW_NEW_in_new_clause1853 = frozenset([2]) FOLLOW_module_in_new_clause1855 = frozenset([10]) FOLLOW_call_expr_in_new_clause1857 = frozenset([3]) FOLLOW_ARRAY_in_array_decl1877 = frozenset([2]) FOLLOW_expr_list_in_array_decl1879 = frozenset([3]) FOLLOW_OBJECT_in_object_decl1904 = frozenset([2]) FOLLOW_property_in_object_decl1907 = frozenset([3, 34, 39, 61]) FOLLOW_set_in_property1932 = frozenset([91]) FOLLOW_91_in_property1944 = frozenset([5, 8, 30, 39, 41, 43, 44, 47, 48, 60, 61, 68, 69, 70, 72, 73, 77, 79, 83, 89, 93, 94, 96, 98, 99, 102, 133, 135]) FOLLOW_expr_in_property1946 = frozenset([1]) FOLLOW_literal_in_atom1967 = frozenset([1]) FOLLOW_member_expr_in_atom1977 = frozenset([1]) FOLLOW_new_clause_in_atom1986 = frozenset([1]) FOLLOW_array_decl_in_atom1995 = frozenset([1]) FOLLOW_object_decl_in_atom2004 = frozenset([1]) FOLLOW_sprintf_in_atom2013 = frozenset([1]) FOLLOW_NULL_in_literal2029 = frozenset([1]) FOLLOW_BOOL_in_literal2036 = frozenset([1]) FOLLOW_INT_in_literal2043 = frozenset([1]) FOLLOW_FLOAT_in_literal2050 = frozenset([1]) FOLLOW_STRING_in_literal2057 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import WalkerMain main = WalkerMain(Eval) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "kyle-wang/ssdb", "path": "deps/cpy/Eval.py", "copies": "35", "size": "141340", "license": "bsd-3-clause", "hash": -8684404744506362000, "line_mean": 26.8448979592, "line_max": 437, "alpha_frac": 0.4337484081, "autogenerated": false, "ratio": 3.799564504422162, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": null, "num_lines": null }
# $ANTLR 3.4 SpeakPython.g 2015-09-25 20:19:02 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 ARROW=4 AT=5 AT_GLOBAL_OPTIONS=6 AT_OPTIONS=7 AT_RESULTS=8 AT_TESTS=9 B_ARROW=10 COMMA=11 COMMENT=12 END_DQUOTE_STRING=13 END_SQUOTE_STRING=14 EQ=15 HASH_NAME=16 INSIDE_DQUOTE_STRING=17 INSIDE_SQUOTE_STRING=18 KLEENE=19 LA_BR=20 LC_BR=21 LR_BR=22 LS_BR=23 NEWLINE=24 NUM=25 OR=26 PLUS=27 QSTN=28 QUOTE_STRING=29 RA_BR=30 RC_BR=31 REGEX=32 REGEX_LABEL=33 RR_BR=34 RS_BR=35 SEMI=36 STAR=37 START_DQUOTE_STRING=38 START_SQUOTE_STRING=39 TILDE=40 UNDERSCORE_NUM=41 VAR_NAME=42 WHITE_SPACE=43 WORD=44 class SpeakPythonLexer(Lexer): grammarFileName = "SpeakPython.g" api_version = 1 def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(SpeakPythonLexer, self).__init__(input, state) self.delegates = [] commentMode = False; multiCommentMode = False; stringMode = False; # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # SpeakPython.g:321:8: ( '||' (~ ( '\\r' | '\\n' ) )* ) # SpeakPython.g:321:10: '||' (~ ( '\\r' | '\\n' ) )* pass self.match("||") # SpeakPython.g:321:15: (~ ( '\\r' | '\\n' ) )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((0 <= LA1_0 <= 9) or (11 <= LA1_0 <= 12) or (14 <= LA1_0 <= 65535)) : alt1 = 1 if alt1 == 1: # SpeakPython.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "START_SQUOTE_STRING" def mSTART_SQUOTE_STRING(self, ): try: # SpeakPython.g:330:29: ({...}? => '\\'' ) # SpeakPython.g:330:30: {...}? => '\\'' pass if not ((not (self.commentMode or self.multiCommentMode))): raise FailedPredicateException(self.input, "START_SQUOTE_STRING", "not (self.commentMode or self.multiCommentMode)") self.match(39) #action start self.stringMode = True; #action end finally: pass # $ANTLR end "START_SQUOTE_STRING" # $ANTLR start "START_DQUOTE_STRING" def mSTART_DQUOTE_STRING(self, ): try: # SpeakPython.g:331:29: ({...}? => '\"' ) # SpeakPython.g:331:30: {...}? => '\"' pass if not ((not (self.commentMode or self.multiCommentMode))): raise FailedPredicateException(self.input, "START_DQUOTE_STRING", "not (self.commentMode or self.multiCommentMode)") self.match(34) #action start self.stringMode = True; #action end finally: pass # $ANTLR end "START_DQUOTE_STRING" # $ANTLR start "INSIDE_SQUOTE_STRING" def mINSIDE_SQUOTE_STRING(self, ): try: # SpeakPython.g:333:30: ({...}? => (~ ( '\\'' ) )* ) # SpeakPython.g:333:31: {...}? => (~ ( '\\'' ) )* pass if not ((self.stringMode)): raise FailedPredicateException(self.input, "INSIDE_SQUOTE_STRING", "self.stringMode") # SpeakPython.g:333:52: (~ ( '\\'' ) )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((0 <= LA2_0 <= 38) or (40 <= LA2_0 <= 65535)) : alt2 = 1 if alt2 == 1: # SpeakPython.g: pass if (0 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop2 finally: pass # $ANTLR end "INSIDE_SQUOTE_STRING" # $ANTLR start "INSIDE_DQUOTE_STRING" def mINSIDE_DQUOTE_STRING(self, ): try: # SpeakPython.g:334:30: ({...}? => (~ ( '\"' ) )* ) # SpeakPython.g:334:31: {...}? => (~ ( '\"' ) )* pass if not ((self.stringMode)): raise FailedPredicateException(self.input, "INSIDE_DQUOTE_STRING", "self.stringMode") # SpeakPython.g:334:52: (~ ( '\"' ) )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if ((0 <= LA3_0 <= 33) or (35 <= LA3_0 <= 65535)) : alt3 = 1 if alt3 == 1: # SpeakPython.g: pass if (0 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop3 finally: pass # $ANTLR end "INSIDE_DQUOTE_STRING" # $ANTLR start "END_SQUOTE_STRING" def mEND_SQUOTE_STRING(self, ): try: # SpeakPython.g:336:27: ({...}? => '\\'' ) # SpeakPython.g:336:28: {...}? => '\\'' pass if not ((self.stringMode)): raise FailedPredicateException(self.input, "END_SQUOTE_STRING", "self.stringMode") self.match(39) #action start self.stringMode = False; #action end finally: pass # $ANTLR end "END_SQUOTE_STRING" # $ANTLR start "END_DQUOTE_STRING" def mEND_DQUOTE_STRING(self, ): try: # SpeakPython.g:337:27: ({...}? => '\"' ) # SpeakPython.g:337:28: {...}? => '\"' pass if not ((self.stringMode)): raise FailedPredicateException(self.input, "END_DQUOTE_STRING", "self.stringMode") self.match(34) #action start self.stringMode = False; #action end finally: pass # $ANTLR end "END_DQUOTE_STRING" # $ANTLR start "QUOTE_STRING" def mQUOTE_STRING(self, ): try: _type = QUOTE_STRING _channel = DEFAULT_CHANNEL # SpeakPython.g:339:13: ( ( START_SQUOTE_STRING INSIDE_SQUOTE_STRING END_SQUOTE_STRING ) | ( START_DQUOTE_STRING INSIDE_DQUOTE_STRING END_DQUOTE_STRING ) ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 39) and ((not (self.commentMode or self.multiCommentMode))): alt4 = 1 elif (LA4_0 == 34) and ((not (self.commentMode or self.multiCommentMode))): alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # SpeakPython.g:339:15: ( START_SQUOTE_STRING INSIDE_SQUOTE_STRING END_SQUOTE_STRING ) pass # SpeakPython.g:339:15: ( START_SQUOTE_STRING INSIDE_SQUOTE_STRING END_SQUOTE_STRING ) # SpeakPython.g:339:16: START_SQUOTE_STRING INSIDE_SQUOTE_STRING END_SQUOTE_STRING pass self.mSTART_SQUOTE_STRING() self.mINSIDE_SQUOTE_STRING() self.mEND_SQUOTE_STRING() elif alt4 == 2: # SpeakPython.g:340:5: ( START_DQUOTE_STRING INSIDE_DQUOTE_STRING END_DQUOTE_STRING ) pass # SpeakPython.g:340:5: ( START_DQUOTE_STRING INSIDE_DQUOTE_STRING END_DQUOTE_STRING ) # SpeakPython.g:340:6: START_DQUOTE_STRING INSIDE_DQUOTE_STRING END_DQUOTE_STRING pass self.mSTART_DQUOTE_STRING() self.mINSIDE_DQUOTE_STRING() self.mEND_DQUOTE_STRING() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "QUOTE_STRING" # $ANTLR start "NEWLINE" def mNEWLINE(self, ): try: _type = NEWLINE _channel = DEFAULT_CHANNEL # SpeakPython.g:343:8: ( ( '\\r' )? '\\n' ) # SpeakPython.g:343:10: ( '\\r' )? '\\n' pass # SpeakPython.g:343:10: ( '\\r' )? alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == 13) : alt5 = 1 if alt5 == 1: # SpeakPython.g:343:11: '\\r' pass self.match(13) self.match(10) #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NEWLINE" # $ANTLR start "WHITE_SPACE" def mWHITE_SPACE(self, ): try: _type = WHITE_SPACE _channel = DEFAULT_CHANNEL # SpeakPython.g:344:12: ( ( ' ' | '\\t' )+ ) # SpeakPython.g:344:14: ( ' ' | '\\t' )+ pass # SpeakPython.g:344:14: ( ' ' | '\\t' )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == 9 or LA6_0 == 32) : alt6 = 1 if alt6 == 1: # SpeakPython.g: pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WHITE_SPACE" # $ANTLR start "REGEX" def mREGEX(self, ): try: _type = REGEX _channel = DEFAULT_CHANNEL # SpeakPython.g:346:6: ({...}? => '/' ( . )+ '/r' ) # SpeakPython.g:346:7: {...}? => '/' ( . )+ '/r' pass if not ((not self.stringMode)): raise FailedPredicateException(self.input, "REGEX", "not self.stringMode") self.match(47) # SpeakPython.g:346:35: ( . )+ cnt7 = 0 while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 47) : LA7_1 = self.input.LA(2) if (LA7_1 == 114) : alt7 = 2 elif ((0 <= LA7_1 <= 113) or (115 <= LA7_1 <= 65535)) : alt7 = 1 elif ((0 <= LA7_0 <= 46) or (48 <= LA7_0 <= 65535)) : alt7 = 1 if alt7 == 1: # SpeakPython.g:346:35: . pass self.matchAny() else: if cnt7 >= 1: break #loop7 eee = EarlyExitException(7, self.input) raise eee cnt7 += 1 self.match("/r") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "REGEX" # $ANTLR start "QSTN" def mQSTN(self, ): try: _type = QSTN _channel = DEFAULT_CHANNEL # SpeakPython.g:348:5: ( '?' ) # SpeakPython.g:348:7: '?' pass self.match(63) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "QSTN" # $ANTLR start "TILDE" def mTILDE(self, ): try: _type = TILDE _channel = DEFAULT_CHANNEL # SpeakPython.g:349:6: ( '~' ) # SpeakPython.g:349:8: '~' pass self.match(126) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "TILDE" # $ANTLR start "B_ARROW" def mB_ARROW(self, ): try: _type = B_ARROW _channel = DEFAULT_CHANNEL # SpeakPython.g:350:8: ( '<-' ) # SpeakPython.g:350:10: '<-' pass self.match("<-") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "B_ARROW" # $ANTLR start "ARROW" def mARROW(self, ): try: _type = ARROW _channel = DEFAULT_CHANNEL # SpeakPython.g:351:6: ( '->' ) # SpeakPython.g:351:8: '->' pass self.match("->") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ARROW" # $ANTLR start "LS_BR" def mLS_BR(self, ): try: _type = LS_BR _channel = DEFAULT_CHANNEL # SpeakPython.g:352:6: ( '[' ) # SpeakPython.g:352:8: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LS_BR" # $ANTLR start "RS_BR" def mRS_BR(self, ): try: _type = RS_BR _channel = DEFAULT_CHANNEL # SpeakPython.g:353:6: ( ']' ) # SpeakPython.g:353:8: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RS_BR" # $ANTLR start "LC_BR" def mLC_BR(self, ): try: _type = LC_BR _channel = DEFAULT_CHANNEL # SpeakPython.g:354:6: ( '{' ) # SpeakPython.g:354:8: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LC_BR" # $ANTLR start "RC_BR" def mRC_BR(self, ): try: _type = RC_BR _channel = DEFAULT_CHANNEL # SpeakPython.g:355:6: ( '}' ) # SpeakPython.g:355:8: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RC_BR" # $ANTLR start "LR_BR" def mLR_BR(self, ): try: _type = LR_BR _channel = DEFAULT_CHANNEL # SpeakPython.g:356:6: ( '(' ) # SpeakPython.g:356:8: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LR_BR" # $ANTLR start "RR_BR" def mRR_BR(self, ): try: _type = RR_BR _channel = DEFAULT_CHANNEL # SpeakPython.g:357:6: ( ')' ) # SpeakPython.g:357:8: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RR_BR" # $ANTLR start "LA_BR" def mLA_BR(self, ): try: _type = LA_BR _channel = DEFAULT_CHANNEL # SpeakPython.g:358:6: ( '<' ) # SpeakPython.g:358:8: '<' pass self.match(60) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LA_BR" # $ANTLR start "RA_BR" def mRA_BR(self, ): try: _type = RA_BR _channel = DEFAULT_CHANNEL # SpeakPython.g:359:6: ( '>' ) # SpeakPython.g:359:8: '>' pass self.match(62) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RA_BR" # $ANTLR start "OR" def mOR(self, ): try: _type = OR _channel = DEFAULT_CHANNEL # SpeakPython.g:360:3: ( '|' ) # SpeakPython.g:360:5: '|' pass self.match(124) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OR" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # SpeakPython.g:361:6: ( ',' ) # SpeakPython.g:361:8: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "SEMI" def mSEMI(self, ): try: _type = SEMI _channel = DEFAULT_CHANNEL # SpeakPython.g:362:5: ( ';' ) # SpeakPython.g:362:7: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SEMI" # $ANTLR start "EQ" def mEQ(self, ): try: _type = EQ _channel = DEFAULT_CHANNEL # SpeakPython.g:363:3: ( '=' ) # SpeakPython.g:363:5: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EQ" # $ANTLR start "AT_TESTS" def mAT_TESTS(self, ): try: _type = AT_TESTS _channel = DEFAULT_CHANNEL # SpeakPython.g:364:9: ( '@tests' ) # SpeakPython.g:364:11: '@tests' pass self.match("@tests") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT_TESTS" # $ANTLR start "AT_RESULTS" def mAT_RESULTS(self, ): try: _type = AT_RESULTS _channel = DEFAULT_CHANNEL # SpeakPython.g:365:11: ( '@results' ) # SpeakPython.g:365:13: '@results' pass self.match("@results") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT_RESULTS" # $ANTLR start "AT_GLOBAL_OPTIONS" def mAT_GLOBAL_OPTIONS(self, ): try: _type = AT_GLOBAL_OPTIONS _channel = DEFAULT_CHANNEL # SpeakPython.g:366:18: ( '@globalOptions' ) # SpeakPython.g:366:20: '@globalOptions' pass self.match("@globalOptions") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT_GLOBAL_OPTIONS" # $ANTLR start "AT_OPTIONS" def mAT_OPTIONS(self, ): try: _type = AT_OPTIONS _channel = DEFAULT_CHANNEL # SpeakPython.g:367:11: ( '@options' ) # SpeakPython.g:367:13: '@options' pass self.match("@options") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT_OPTIONS" # $ANTLR start "AT" def mAT(self, ): try: _type = AT _channel = DEFAULT_CHANNEL # SpeakPython.g:368:3: ( '@' ) # SpeakPython.g:368:5: '@' pass self.match(64) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT" # $ANTLR start "PLUS" def mPLUS(self, ): try: _type = PLUS _channel = DEFAULT_CHANNEL # SpeakPython.g:369:5: ( '+' ) # SpeakPython.g:369:7: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUS" # $ANTLR start "STAR" def mSTAR(self, ): try: _type = STAR _channel = DEFAULT_CHANNEL # SpeakPython.g:370:5: ( '*' ) # SpeakPython.g:370:7: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STAR" # $ANTLR start "UNDERSCORE_NUM" def mUNDERSCORE_NUM(self, ): try: _type = UNDERSCORE_NUM _channel = DEFAULT_CHANNEL # SpeakPython.g:371:15: ( '_' ( '0' .. '9' )+ ) # SpeakPython.g:371:17: '_' ( '0' .. '9' )+ pass self.match(95) # SpeakPython.g:371:21: ( '0' .. '9' )+ cnt8 = 0 while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if ((48 <= LA8_0 <= 57)) : alt8 = 1 if alt8 == 1: # SpeakPython.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt8 >= 1: break #loop8 eee = EarlyExitException(8, self.input) raise eee cnt8 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "UNDERSCORE_NUM" # $ANTLR start "KLEENE" def mKLEENE(self, ): try: _type = KLEENE _channel = DEFAULT_CHANNEL # SpeakPython.g:372:7: ( 'k_' ) # SpeakPython.g:372:9: 'k_' pass self.match("k_") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "KLEENE" # $ANTLR start "REGEX_LABEL" def mREGEX_LABEL(self, ): try: _type = REGEX_LABEL _channel = DEFAULT_CHANNEL # SpeakPython.g:373:12: ( 'r_' ) # SpeakPython.g:373:14: 'r_' pass self.match("r_") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "REGEX_LABEL" # $ANTLR start "VAR_NAME" def mVAR_NAME(self, ): try: _type = VAR_NAME _channel = DEFAULT_CHANNEL # SpeakPython.g:375:9: ( '$' ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' )* ) # SpeakPython.g:375:11: '$' ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' )* pass self.match(36) if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # SpeakPython.g:375:33: ( 'a' .. 'z' | 'A' .. 'Z' )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if ((65 <= LA9_0 <= 90) or (97 <= LA9_0 <= 122)) : alt9 = 1 if alt9 == 1: # SpeakPython.g: pass if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop9 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "VAR_NAME" # $ANTLR start "HASH_NAME" def mHASH_NAME(self, ): try: _type = HASH_NAME _channel = DEFAULT_CHANNEL # SpeakPython.g:376:10: ( '#' ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* ) # SpeakPython.g:376:12: '#' ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* pass self.match(35) if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # SpeakPython.g:376:34: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* while True: #loop10 alt10 = 2 LA10_0 = self.input.LA(1) if ((48 <= LA10_0 <= 57) or (65 <= LA10_0 <= 90) or (97 <= LA10_0 <= 122)) : alt10 = 1 if alt10 == 1: # SpeakPython.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop10 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "HASH_NAME" # $ANTLR start "NUM" def mNUM(self, ): try: _type = NUM _channel = DEFAULT_CHANNEL # SpeakPython.g:377:4: ( ( '0' .. '9' )+ ) # SpeakPython.g:377:6: ( '0' .. '9' )+ pass # SpeakPython.g:377:6: ( '0' .. '9' )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((48 <= LA11_0 <= 57)) : alt11 = 1 if alt11 == 1: # SpeakPython.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NUM" # $ANTLR start "WORD" def mWORD(self, ): try: _type = WORD _channel = DEFAULT_CHANNEL # SpeakPython.g:378:5: ( ( 'a' .. 'z' | 'A' .. 'Z' )+ ) # SpeakPython.g:378:7: ( 'a' .. 'z' | 'A' .. 'Z' )+ pass # SpeakPython.g:378:7: ( 'a' .. 'z' | 'A' .. 'Z' )+ cnt12 = 0 while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if ((65 <= LA12_0 <= 90) or (97 <= LA12_0 <= 122)) : alt12 = 1 if alt12 == 1: # SpeakPython.g: pass if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WORD" def mTokens(self): # SpeakPython.g:1:8: ( COMMENT | QUOTE_STRING | NEWLINE | WHITE_SPACE | REGEX | QSTN | TILDE | B_ARROW | ARROW | LS_BR | RS_BR | LC_BR | RC_BR | LR_BR | RR_BR | LA_BR | RA_BR | OR | COMMA | SEMI | EQ | AT_TESTS | AT_RESULTS | AT_GLOBAL_OPTIONS | AT_OPTIONS | AT | PLUS | STAR | UNDERSCORE_NUM | KLEENE | REGEX_LABEL | VAR_NAME | HASH_NAME | NUM | WORD ) alt13 = 35 LA13_0 = self.input.LA(1) if (LA13_0 == 124) : LA13_1 = self.input.LA(2) if (LA13_1 == 124) : alt13 = 1 else: alt13 = 18 elif (LA13_0 == 34 or LA13_0 == 39) and ((not (self.commentMode or self.multiCommentMode))): alt13 = 2 elif (LA13_0 == 10 or LA13_0 == 13) : alt13 = 3 elif (LA13_0 == 9 or LA13_0 == 32) : alt13 = 4 elif (LA13_0 == 47) and ((not self.stringMode)): alt13 = 5 elif (LA13_0 == 63) : alt13 = 6 elif (LA13_0 == 126) : alt13 = 7 elif (LA13_0 == 60) : LA13_8 = self.input.LA(2) if (LA13_8 == 45) : alt13 = 8 else: alt13 = 16 elif (LA13_0 == 45) : alt13 = 9 elif (LA13_0 == 91) : alt13 = 10 elif (LA13_0 == 93) : alt13 = 11 elif (LA13_0 == 123) : alt13 = 12 elif (LA13_0 == 125) : alt13 = 13 elif (LA13_0 == 40) : alt13 = 14 elif (LA13_0 == 41) : alt13 = 15 elif (LA13_0 == 62) : alt13 = 17 elif (LA13_0 == 44) : alt13 = 19 elif (LA13_0 == 59) : alt13 = 20 elif (LA13_0 == 61) : alt13 = 21 elif (LA13_0 == 64) : LA13 = self.input.LA(2) if LA13 == 116: alt13 = 22 elif LA13 == 114: alt13 = 23 elif LA13 == 103: alt13 = 24 elif LA13 == 111: alt13 = 25 else: alt13 = 26 elif (LA13_0 == 43) : alt13 = 27 elif (LA13_0 == 42) : alt13 = 28 elif (LA13_0 == 95) : alt13 = 29 elif (LA13_0 == 107) : LA13_24 = self.input.LA(2) if (LA13_24 == 95) : alt13 = 30 else: alt13 = 35 elif (LA13_0 == 114) : LA13_25 = self.input.LA(2) if (LA13_25 == 95) : alt13 = 31 else: alt13 = 35 elif (LA13_0 == 36) : alt13 = 32 elif (LA13_0 == 35) : alt13 = 33 elif ((48 <= LA13_0 <= 57)) : alt13 = 34 elif ((65 <= LA13_0 <= 90) or (97 <= LA13_0 <= 106) or (108 <= LA13_0 <= 113) or (115 <= LA13_0 <= 122)) : alt13 = 35 else: nvae = NoViableAltException("", 13, 0, self.input) raise nvae if alt13 == 1: # SpeakPython.g:1:10: COMMENT pass self.mCOMMENT() elif alt13 == 2: # SpeakPython.g:1:18: QUOTE_STRING pass self.mQUOTE_STRING() elif alt13 == 3: # SpeakPython.g:1:31: NEWLINE pass self.mNEWLINE() elif alt13 == 4: # SpeakPython.g:1:39: WHITE_SPACE pass self.mWHITE_SPACE() elif alt13 == 5: # SpeakPython.g:1:51: REGEX pass self.mREGEX() elif alt13 == 6: # SpeakPython.g:1:57: QSTN pass self.mQSTN() elif alt13 == 7: # SpeakPython.g:1:62: TILDE pass self.mTILDE() elif alt13 == 8: # SpeakPython.g:1:68: B_ARROW pass self.mB_ARROW() elif alt13 == 9: # SpeakPython.g:1:76: ARROW pass self.mARROW() elif alt13 == 10: # SpeakPython.g:1:82: LS_BR pass self.mLS_BR() elif alt13 == 11: # SpeakPython.g:1:88: RS_BR pass self.mRS_BR() elif alt13 == 12: # SpeakPython.g:1:94: LC_BR pass self.mLC_BR() elif alt13 == 13: # SpeakPython.g:1:100: RC_BR pass self.mRC_BR() elif alt13 == 14: # SpeakPython.g:1:106: LR_BR pass self.mLR_BR() elif alt13 == 15: # SpeakPython.g:1:112: RR_BR pass self.mRR_BR() elif alt13 == 16: # SpeakPython.g:1:118: LA_BR pass self.mLA_BR() elif alt13 == 17: # SpeakPython.g:1:124: RA_BR pass self.mRA_BR() elif alt13 == 18: # SpeakPython.g:1:130: OR pass self.mOR() elif alt13 == 19: # SpeakPython.g:1:133: COMMA pass self.mCOMMA() elif alt13 == 20: # SpeakPython.g:1:139: SEMI pass self.mSEMI() elif alt13 == 21: # SpeakPython.g:1:144: EQ pass self.mEQ() elif alt13 == 22: # SpeakPython.g:1:147: AT_TESTS pass self.mAT_TESTS() elif alt13 == 23: # SpeakPython.g:1:156: AT_RESULTS pass self.mAT_RESULTS() elif alt13 == 24: # SpeakPython.g:1:167: AT_GLOBAL_OPTIONS pass self.mAT_GLOBAL_OPTIONS() elif alt13 == 25: # SpeakPython.g:1:185: AT_OPTIONS pass self.mAT_OPTIONS() elif alt13 == 26: # SpeakPython.g:1:196: AT pass self.mAT() elif alt13 == 27: # SpeakPython.g:1:199: PLUS pass self.mPLUS() elif alt13 == 28: # SpeakPython.g:1:204: STAR pass self.mSTAR() elif alt13 == 29: # SpeakPython.g:1:209: UNDERSCORE_NUM pass self.mUNDERSCORE_NUM() elif alt13 == 30: # SpeakPython.g:1:224: KLEENE pass self.mKLEENE() elif alt13 == 31: # SpeakPython.g:1:231: REGEX_LABEL pass self.mREGEX_LABEL() elif alt13 == 32: # SpeakPython.g:1:243: VAR_NAME pass self.mVAR_NAME() elif alt13 == 33: # SpeakPython.g:1:252: HASH_NAME pass self.mHASH_NAME() elif alt13 == 34: # SpeakPython.g:1:262: NUM pass self.mNUM() elif alt13 == 35: # SpeakPython.g:1:266: WORD pass self.mWORD() def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(SpeakPythonLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "netgio/voicecount", "path": "devicecode/SpeakPython/SpeakPythonLexer.py", "copies": "1", "size": "37426", "license": "mit", "hash": -8049881028853731000, "line_mean": 20.1925254813, "line_max": 361, "alpha_frac": 0.4177309892, "autogenerated": false, "ratio": 3.666699323993338, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9526450820205494, "avg_score": 0.011595898597568646, "num_lines": 1766 }
# $ANTLR 3.4 SpeakPythonJSGF.g 2015-09-25 20:19:04 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 ARROW=4 AT=5 AT_GLOBAL_OPTIONS=6 AT_OPTIONS=7 AT_RESULTS=8 AT_TESTS=9 B_ARROW=10 COMMA=11 COMMENT=12 END_DQUOTE_STRING=13 END_SQUOTE_STRING=14 EQ=15 HASH_NAME=16 INSIDE_DQUOTE_STRING=17 INSIDE_SQUOTE_STRING=18 KLEENE=19 LA_BR=20 LC_BR=21 LR_BR=22 LS_BR=23 NEWLINE=24 NUM=25 OR=26 PLUS=27 QSTN=28 QUOTE_STRING=29 RA_BR=30 RC_BR=31 REGEX=32 REGEX_LABEL=33 RR_BR=34 RS_BR=35 SEMI=36 STAR=37 START_DQUOTE_STRING=38 START_SQUOTE_STRING=39 TILDE=40 UNDERSCORE_NUM=41 VAR_NAME=42 WHITE_SPACE=43 WORD=44 class SpeakPythonJSGFLexer(Lexer): grammarFileName = "SpeakPythonJSGF.g" api_version = 1 def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(SpeakPythonJSGFLexer, self).__init__(input, state) self.delegates = [] commentMode = False; multiCommentMode = False; stringMode = False; # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:215:8: ( '||' (~ ( '\\r' | '\\n' ) )* ) # SpeakPythonJSGF.g:215:10: '||' (~ ( '\\r' | '\\n' ) )* pass self.match("||") # SpeakPythonJSGF.g:215:15: (~ ( '\\r' | '\\n' ) )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((0 <= LA1_0 <= 9) or (11 <= LA1_0 <= 12) or (14 <= LA1_0 <= 65535)) : alt1 = 1 if alt1 == 1: # SpeakPythonJSGF.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "START_SQUOTE_STRING" def mSTART_SQUOTE_STRING(self, ): try: # SpeakPythonJSGF.g:224:29: ({...}? => '\\'' ) # SpeakPythonJSGF.g:224:30: {...}? => '\\'' pass if not ((not (self.commentMode or self.multiCommentMode))): raise FailedPredicateException(self.input, "START_SQUOTE_STRING", "not (self.commentMode or self.multiCommentMode)") self.match(39) #action start self.stringMode = True; #action end finally: pass # $ANTLR end "START_SQUOTE_STRING" # $ANTLR start "START_DQUOTE_STRING" def mSTART_DQUOTE_STRING(self, ): try: # SpeakPythonJSGF.g:225:29: ({...}? => '\"' ) # SpeakPythonJSGF.g:225:30: {...}? => '\"' pass if not ((not (self.commentMode or self.multiCommentMode))): raise FailedPredicateException(self.input, "START_DQUOTE_STRING", "not (self.commentMode or self.multiCommentMode)") self.match(34) #action start self.stringMode = True; #action end finally: pass # $ANTLR end "START_DQUOTE_STRING" # $ANTLR start "INSIDE_SQUOTE_STRING" def mINSIDE_SQUOTE_STRING(self, ): try: # SpeakPythonJSGF.g:227:30: ({...}? => (~ ( '\\'' ) )* ) # SpeakPythonJSGF.g:227:31: {...}? => (~ ( '\\'' ) )* pass if not ((self.stringMode)): raise FailedPredicateException(self.input, "INSIDE_SQUOTE_STRING", "self.stringMode") # SpeakPythonJSGF.g:227:52: (~ ( '\\'' ) )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((0 <= LA2_0 <= 38) or (40 <= LA2_0 <= 65535)) : alt2 = 1 if alt2 == 1: # SpeakPythonJSGF.g: pass if (0 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop2 finally: pass # $ANTLR end "INSIDE_SQUOTE_STRING" # $ANTLR start "INSIDE_DQUOTE_STRING" def mINSIDE_DQUOTE_STRING(self, ): try: # SpeakPythonJSGF.g:228:30: ({...}? => (~ ( '\"' ) )* ) # SpeakPythonJSGF.g:228:31: {...}? => (~ ( '\"' ) )* pass if not ((self.stringMode)): raise FailedPredicateException(self.input, "INSIDE_DQUOTE_STRING", "self.stringMode") # SpeakPythonJSGF.g:228:52: (~ ( '\"' ) )* while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if ((0 <= LA3_0 <= 33) or (35 <= LA3_0 <= 65535)) : alt3 = 1 if alt3 == 1: # SpeakPythonJSGF.g: pass if (0 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop3 finally: pass # $ANTLR end "INSIDE_DQUOTE_STRING" # $ANTLR start "END_SQUOTE_STRING" def mEND_SQUOTE_STRING(self, ): try: # SpeakPythonJSGF.g:230:27: ({...}? => '\\'' ) # SpeakPythonJSGF.g:230:28: {...}? => '\\'' pass if not ((self.stringMode)): raise FailedPredicateException(self.input, "END_SQUOTE_STRING", "self.stringMode") self.match(39) #action start self.stringMode = False; #action end finally: pass # $ANTLR end "END_SQUOTE_STRING" # $ANTLR start "END_DQUOTE_STRING" def mEND_DQUOTE_STRING(self, ): try: # SpeakPythonJSGF.g:231:27: ({...}? => '\"' ) # SpeakPythonJSGF.g:231:28: {...}? => '\"' pass if not ((self.stringMode)): raise FailedPredicateException(self.input, "END_DQUOTE_STRING", "self.stringMode") self.match(34) #action start self.stringMode = False; #action end finally: pass # $ANTLR end "END_DQUOTE_STRING" # $ANTLR start "QUOTE_STRING" def mQUOTE_STRING(self, ): try: _type = QUOTE_STRING _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:233:13: ( ( START_SQUOTE_STRING INSIDE_SQUOTE_STRING END_SQUOTE_STRING ) | ( START_DQUOTE_STRING INSIDE_DQUOTE_STRING END_DQUOTE_STRING ) ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 39) and ((not (self.commentMode or self.multiCommentMode))): alt4 = 1 elif (LA4_0 == 34) and ((not (self.commentMode or self.multiCommentMode))): alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # SpeakPythonJSGF.g:233:15: ( START_SQUOTE_STRING INSIDE_SQUOTE_STRING END_SQUOTE_STRING ) pass # SpeakPythonJSGF.g:233:15: ( START_SQUOTE_STRING INSIDE_SQUOTE_STRING END_SQUOTE_STRING ) # SpeakPythonJSGF.g:233:16: START_SQUOTE_STRING INSIDE_SQUOTE_STRING END_SQUOTE_STRING pass self.mSTART_SQUOTE_STRING() self.mINSIDE_SQUOTE_STRING() self.mEND_SQUOTE_STRING() elif alt4 == 2: # SpeakPythonJSGF.g:234:5: ( START_DQUOTE_STRING INSIDE_DQUOTE_STRING END_DQUOTE_STRING ) pass # SpeakPythonJSGF.g:234:5: ( START_DQUOTE_STRING INSIDE_DQUOTE_STRING END_DQUOTE_STRING ) # SpeakPythonJSGF.g:234:6: START_DQUOTE_STRING INSIDE_DQUOTE_STRING END_DQUOTE_STRING pass self.mSTART_DQUOTE_STRING() self.mINSIDE_DQUOTE_STRING() self.mEND_DQUOTE_STRING() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "QUOTE_STRING" # $ANTLR start "NEWLINE" def mNEWLINE(self, ): try: _type = NEWLINE _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:237:8: ( ( '\\r' )? '\\n' ) # SpeakPythonJSGF.g:237:10: ( '\\r' )? '\\n' pass # SpeakPythonJSGF.g:237:10: ( '\\r' )? alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == 13) : alt5 = 1 if alt5 == 1: # SpeakPythonJSGF.g:237:11: '\\r' pass self.match(13) self.match(10) #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NEWLINE" # $ANTLR start "WHITE_SPACE" def mWHITE_SPACE(self, ): try: _type = WHITE_SPACE _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:238:12: ( ( ' ' | '\\t' )+ ) # SpeakPythonJSGF.g:238:14: ( ' ' | '\\t' )+ pass # SpeakPythonJSGF.g:238:14: ( ' ' | '\\t' )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == 9 or LA6_0 == 32) : alt6 = 1 if alt6 == 1: # SpeakPythonJSGF.g: pass if self.input.LA(1) == 9 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 #action start _channel = HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WHITE_SPACE" # $ANTLR start "REGEX" def mREGEX(self, ): try: _type = REGEX _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:240:6: ({...}? => '/' ( . )+ '/r' ) # SpeakPythonJSGF.g:240:7: {...}? => '/' ( . )+ '/r' pass if not ((not self.stringMode)): raise FailedPredicateException(self.input, "REGEX", "not self.stringMode") self.match(47) # SpeakPythonJSGF.g:240:35: ( . )+ cnt7 = 0 while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 47) : LA7_1 = self.input.LA(2) if (LA7_1 == 114) : alt7 = 2 elif ((0 <= LA7_1 <= 113) or (115 <= LA7_1 <= 65535)) : alt7 = 1 elif ((0 <= LA7_0 <= 46) or (48 <= LA7_0 <= 65535)) : alt7 = 1 if alt7 == 1: # SpeakPythonJSGF.g:240:35: . pass self.matchAny() else: if cnt7 >= 1: break #loop7 eee = EarlyExitException(7, self.input) raise eee cnt7 += 1 self.match("/r") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "REGEX" # $ANTLR start "QSTN" def mQSTN(self, ): try: _type = QSTN _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:242:5: ( '?' ) # SpeakPythonJSGF.g:242:7: '?' pass self.match(63) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "QSTN" # $ANTLR start "TILDE" def mTILDE(self, ): try: _type = TILDE _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:243:6: ( '~' ) # SpeakPythonJSGF.g:243:8: '~' pass self.match(126) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "TILDE" # $ANTLR start "B_ARROW" def mB_ARROW(self, ): try: _type = B_ARROW _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:244:8: ( '<-' ) # SpeakPythonJSGF.g:244:10: '<-' pass self.match("<-") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "B_ARROW" # $ANTLR start "ARROW" def mARROW(self, ): try: _type = ARROW _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:245:6: ( '->' ) # SpeakPythonJSGF.g:245:8: '->' pass self.match("->") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ARROW" # $ANTLR start "LS_BR" def mLS_BR(self, ): try: _type = LS_BR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:246:6: ( '[' ) # SpeakPythonJSGF.g:246:8: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LS_BR" # $ANTLR start "RS_BR" def mRS_BR(self, ): try: _type = RS_BR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:247:6: ( ']' ) # SpeakPythonJSGF.g:247:8: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RS_BR" # $ANTLR start "LC_BR" def mLC_BR(self, ): try: _type = LC_BR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:248:6: ( '{' ) # SpeakPythonJSGF.g:248:8: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LC_BR" # $ANTLR start "RC_BR" def mRC_BR(self, ): try: _type = RC_BR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:249:6: ( '}' ) # SpeakPythonJSGF.g:249:8: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RC_BR" # $ANTLR start "LR_BR" def mLR_BR(self, ): try: _type = LR_BR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:250:6: ( '(' ) # SpeakPythonJSGF.g:250:8: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LR_BR" # $ANTLR start "RR_BR" def mRR_BR(self, ): try: _type = RR_BR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:251:6: ( ')' ) # SpeakPythonJSGF.g:251:8: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RR_BR" # $ANTLR start "LA_BR" def mLA_BR(self, ): try: _type = LA_BR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:252:6: ( '<' ) # SpeakPythonJSGF.g:252:8: '<' pass self.match(60) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LA_BR" # $ANTLR start "RA_BR" def mRA_BR(self, ): try: _type = RA_BR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:253:6: ( '>' ) # SpeakPythonJSGF.g:253:8: '>' pass self.match(62) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RA_BR" # $ANTLR start "OR" def mOR(self, ): try: _type = OR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:254:3: ( '|' ) # SpeakPythonJSGF.g:254:5: '|' pass self.match(124) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OR" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:255:6: ( ',' ) # SpeakPythonJSGF.g:255:8: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "SEMI" def mSEMI(self, ): try: _type = SEMI _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:256:5: ( ';' ) # SpeakPythonJSGF.g:256:7: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SEMI" # $ANTLR start "EQ" def mEQ(self, ): try: _type = EQ _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:257:3: ( '=' ) # SpeakPythonJSGF.g:257:5: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EQ" # $ANTLR start "AT_TESTS" def mAT_TESTS(self, ): try: _type = AT_TESTS _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:258:9: ( '@tests' ) # SpeakPythonJSGF.g:258:11: '@tests' pass self.match("@tests") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT_TESTS" # $ANTLR start "AT_RESULTS" def mAT_RESULTS(self, ): try: _type = AT_RESULTS _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:259:11: ( '@results' ) # SpeakPythonJSGF.g:259:13: '@results' pass self.match("@results") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT_RESULTS" # $ANTLR start "AT_GLOBAL_OPTIONS" def mAT_GLOBAL_OPTIONS(self, ): try: _type = AT_GLOBAL_OPTIONS _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:260:18: ( '@globalOptions' ) # SpeakPythonJSGF.g:260:20: '@globalOptions' pass self.match("@globalOptions") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT_GLOBAL_OPTIONS" # $ANTLR start "AT_OPTIONS" def mAT_OPTIONS(self, ): try: _type = AT_OPTIONS _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:261:11: ( '@options' ) # SpeakPythonJSGF.g:261:13: '@options' pass self.match("@options") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT_OPTIONS" # $ANTLR start "AT" def mAT(self, ): try: _type = AT _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:262:3: ( '@' ) # SpeakPythonJSGF.g:262:5: '@' pass self.match(64) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "AT" # $ANTLR start "PLUS" def mPLUS(self, ): try: _type = PLUS _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:263:5: ( '+' ) # SpeakPythonJSGF.g:263:7: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "PLUS" # $ANTLR start "STAR" def mSTAR(self, ): try: _type = STAR _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:264:5: ( '*' ) # SpeakPythonJSGF.g:264:7: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STAR" # $ANTLR start "UNDERSCORE_NUM" def mUNDERSCORE_NUM(self, ): try: _type = UNDERSCORE_NUM _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:265:15: ( '_' ( '0' .. '9' )+ ) # SpeakPythonJSGF.g:265:17: '_' ( '0' .. '9' )+ pass self.match(95) # SpeakPythonJSGF.g:265:21: ( '0' .. '9' )+ cnt8 = 0 while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if ((48 <= LA8_0 <= 57)) : alt8 = 1 if alt8 == 1: # SpeakPythonJSGF.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt8 >= 1: break #loop8 eee = EarlyExitException(8, self.input) raise eee cnt8 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "UNDERSCORE_NUM" # $ANTLR start "KLEENE" def mKLEENE(self, ): try: _type = KLEENE _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:266:7: ( 'k_' ) # SpeakPythonJSGF.g:266:9: 'k_' pass self.match("k_") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "KLEENE" # $ANTLR start "REGEX_LABEL" def mREGEX_LABEL(self, ): try: _type = REGEX_LABEL _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:267:12: ( 'r_' ) # SpeakPythonJSGF.g:267:14: 'r_' pass self.match("r_") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "REGEX_LABEL" # $ANTLR start "VAR_NAME" def mVAR_NAME(self, ): try: _type = VAR_NAME _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:269:9: ( '$' ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' )* ) # SpeakPythonJSGF.g:269:11: '$' ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' )* pass self.match(36) if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # SpeakPythonJSGF.g:269:33: ( 'a' .. 'z' | 'A' .. 'Z' )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if ((65 <= LA9_0 <= 90) or (97 <= LA9_0 <= 122)) : alt9 = 1 if alt9 == 1: # SpeakPythonJSGF.g: pass if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop9 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "VAR_NAME" # $ANTLR start "HASH_NAME" def mHASH_NAME(self, ): try: _type = HASH_NAME _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:270:10: ( '#' ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* ) # SpeakPythonJSGF.g:270:12: '#' ( 'a' .. 'z' | 'A' .. 'Z' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* pass self.match(35) if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # SpeakPythonJSGF.g:270:34: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' )* while True: #loop10 alt10 = 2 LA10_0 = self.input.LA(1) if ((48 <= LA10_0 <= 57) or (65 <= LA10_0 <= 90) or (97 <= LA10_0 <= 122)) : alt10 = 1 if alt10 == 1: # SpeakPythonJSGF.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop10 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "HASH_NAME" # $ANTLR start "NUM" def mNUM(self, ): try: _type = NUM _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:271:4: ( ( '0' .. '9' )+ ) # SpeakPythonJSGF.g:271:6: ( '0' .. '9' )+ pass # SpeakPythonJSGF.g:271:6: ( '0' .. '9' )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((48 <= LA11_0 <= 57)) : alt11 = 1 if alt11 == 1: # SpeakPythonJSGF.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NUM" # $ANTLR start "WORD" def mWORD(self, ): try: _type = WORD _channel = DEFAULT_CHANNEL # SpeakPythonJSGF.g:272:5: ( ( 'a' .. 'z' | 'A' .. 'Z' )+ ) # SpeakPythonJSGF.g:272:7: ( 'a' .. 'z' | 'A' .. 'Z' )+ pass # SpeakPythonJSGF.g:272:7: ( 'a' .. 'z' | 'A' .. 'Z' )+ cnt12 = 0 while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if ((65 <= LA12_0 <= 90) or (97 <= LA12_0 <= 122)) : alt12 = 1 if alt12 == 1: # SpeakPythonJSGF.g: pass if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WORD" def mTokens(self): # SpeakPythonJSGF.g:1:8: ( COMMENT | QUOTE_STRING | NEWLINE | WHITE_SPACE | REGEX | QSTN | TILDE | B_ARROW | ARROW | LS_BR | RS_BR | LC_BR | RC_BR | LR_BR | RR_BR | LA_BR | RA_BR | OR | COMMA | SEMI | EQ | AT_TESTS | AT_RESULTS | AT_GLOBAL_OPTIONS | AT_OPTIONS | AT | PLUS | STAR | UNDERSCORE_NUM | KLEENE | REGEX_LABEL | VAR_NAME | HASH_NAME | NUM | WORD ) alt13 = 35 LA13_0 = self.input.LA(1) if (LA13_0 == 124) : LA13_1 = self.input.LA(2) if (LA13_1 == 124) : alt13 = 1 else: alt13 = 18 elif (LA13_0 == 34 or LA13_0 == 39) and ((not (self.commentMode or self.multiCommentMode))): alt13 = 2 elif (LA13_0 == 10 or LA13_0 == 13) : alt13 = 3 elif (LA13_0 == 9 or LA13_0 == 32) : alt13 = 4 elif (LA13_0 == 47) and ((not self.stringMode)): alt13 = 5 elif (LA13_0 == 63) : alt13 = 6 elif (LA13_0 == 126) : alt13 = 7 elif (LA13_0 == 60) : LA13_8 = self.input.LA(2) if (LA13_8 == 45) : alt13 = 8 else: alt13 = 16 elif (LA13_0 == 45) : alt13 = 9 elif (LA13_0 == 91) : alt13 = 10 elif (LA13_0 == 93) : alt13 = 11 elif (LA13_0 == 123) : alt13 = 12 elif (LA13_0 == 125) : alt13 = 13 elif (LA13_0 == 40) : alt13 = 14 elif (LA13_0 == 41) : alt13 = 15 elif (LA13_0 == 62) : alt13 = 17 elif (LA13_0 == 44) : alt13 = 19 elif (LA13_0 == 59) : alt13 = 20 elif (LA13_0 == 61) : alt13 = 21 elif (LA13_0 == 64) : LA13 = self.input.LA(2) if LA13 == 116: alt13 = 22 elif LA13 == 114: alt13 = 23 elif LA13 == 103: alt13 = 24 elif LA13 == 111: alt13 = 25 else: alt13 = 26 elif (LA13_0 == 43) : alt13 = 27 elif (LA13_0 == 42) : alt13 = 28 elif (LA13_0 == 95) : alt13 = 29 elif (LA13_0 == 107) : LA13_24 = self.input.LA(2) if (LA13_24 == 95) : alt13 = 30 else: alt13 = 35 elif (LA13_0 == 114) : LA13_25 = self.input.LA(2) if (LA13_25 == 95) : alt13 = 31 else: alt13 = 35 elif (LA13_0 == 36) : alt13 = 32 elif (LA13_0 == 35) : alt13 = 33 elif ((48 <= LA13_0 <= 57)) : alt13 = 34 elif ((65 <= LA13_0 <= 90) or (97 <= LA13_0 <= 106) or (108 <= LA13_0 <= 113) or (115 <= LA13_0 <= 122)) : alt13 = 35 else: nvae = NoViableAltException("", 13, 0, self.input) raise nvae if alt13 == 1: # SpeakPythonJSGF.g:1:10: COMMENT pass self.mCOMMENT() elif alt13 == 2: # SpeakPythonJSGF.g:1:18: QUOTE_STRING pass self.mQUOTE_STRING() elif alt13 == 3: # SpeakPythonJSGF.g:1:31: NEWLINE pass self.mNEWLINE() elif alt13 == 4: # SpeakPythonJSGF.g:1:39: WHITE_SPACE pass self.mWHITE_SPACE() elif alt13 == 5: # SpeakPythonJSGF.g:1:51: REGEX pass self.mREGEX() elif alt13 == 6: # SpeakPythonJSGF.g:1:57: QSTN pass self.mQSTN() elif alt13 == 7: # SpeakPythonJSGF.g:1:62: TILDE pass self.mTILDE() elif alt13 == 8: # SpeakPythonJSGF.g:1:68: B_ARROW pass self.mB_ARROW() elif alt13 == 9: # SpeakPythonJSGF.g:1:76: ARROW pass self.mARROW() elif alt13 == 10: # SpeakPythonJSGF.g:1:82: LS_BR pass self.mLS_BR() elif alt13 == 11: # SpeakPythonJSGF.g:1:88: RS_BR pass self.mRS_BR() elif alt13 == 12: # SpeakPythonJSGF.g:1:94: LC_BR pass self.mLC_BR() elif alt13 == 13: # SpeakPythonJSGF.g:1:100: RC_BR pass self.mRC_BR() elif alt13 == 14: # SpeakPythonJSGF.g:1:106: LR_BR pass self.mLR_BR() elif alt13 == 15: # SpeakPythonJSGF.g:1:112: RR_BR pass self.mRR_BR() elif alt13 == 16: # SpeakPythonJSGF.g:1:118: LA_BR pass self.mLA_BR() elif alt13 == 17: # SpeakPythonJSGF.g:1:124: RA_BR pass self.mRA_BR() elif alt13 == 18: # SpeakPythonJSGF.g:1:130: OR pass self.mOR() elif alt13 == 19: # SpeakPythonJSGF.g:1:133: COMMA pass self.mCOMMA() elif alt13 == 20: # SpeakPythonJSGF.g:1:139: SEMI pass self.mSEMI() elif alt13 == 21: # SpeakPythonJSGF.g:1:144: EQ pass self.mEQ() elif alt13 == 22: # SpeakPythonJSGF.g:1:147: AT_TESTS pass self.mAT_TESTS() elif alt13 == 23: # SpeakPythonJSGF.g:1:156: AT_RESULTS pass self.mAT_RESULTS() elif alt13 == 24: # SpeakPythonJSGF.g:1:167: AT_GLOBAL_OPTIONS pass self.mAT_GLOBAL_OPTIONS() elif alt13 == 25: # SpeakPythonJSGF.g:1:185: AT_OPTIONS pass self.mAT_OPTIONS() elif alt13 == 26: # SpeakPythonJSGF.g:1:196: AT pass self.mAT() elif alt13 == 27: # SpeakPythonJSGF.g:1:199: PLUS pass self.mPLUS() elif alt13 == 28: # SpeakPythonJSGF.g:1:204: STAR pass self.mSTAR() elif alt13 == 29: # SpeakPythonJSGF.g:1:209: UNDERSCORE_NUM pass self.mUNDERSCORE_NUM() elif alt13 == 30: # SpeakPythonJSGF.g:1:224: KLEENE pass self.mKLEENE() elif alt13 == 31: # SpeakPythonJSGF.g:1:231: REGEX_LABEL pass self.mREGEX_LABEL() elif alt13 == 32: # SpeakPythonJSGF.g:1:243: VAR_NAME pass self.mVAR_NAME() elif alt13 == 33: # SpeakPythonJSGF.g:1:252: HASH_NAME pass self.mHASH_NAME() elif alt13 == 34: # SpeakPythonJSGF.g:1:262: NUM pass self.mNUM() elif alt13 == 35: # SpeakPythonJSGF.g:1:266: WORD pass self.mWORD() def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(SpeakPythonJSGFLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "netgio/voicecount", "path": "devicecode/SpeakPython/SpeakPythonJSGFLexer.py", "copies": "1", "size": "38026", "license": "mit", "hash": 8031992712422180000, "line_mean": 20.5322763307, "line_max": 365, "alpha_frac": 0.4269184242, "autogenerated": false, "ratio": 3.568171155109318, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.44950895793093176, "avg_score": null, "num_lines": null }
# $ANTLR 3.5.1 /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g 2016-03-02 22:50:02 import sys from antlr3 import * from antlr3.compat import set, frozenset from antlr3.debug import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__11=11 T__12=12 T__13=13 T__14=14 T__15=15 T__16=16 T__17=17 T__18=18 T__19=19 T__20=20 T__21=21 T__22=22 T__23=23 T__24=24 T__25=25 T__26=26 T__27=27 T__28=28 T__29=29 T__30=30 T__31=31 T__32=32 T__33=33 T__34=34 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 T__40=40 T__41=41 T__42=42 T__43=43 T__44=44 T__45=45 T__46=46 T__47=47 T__48=48 T__49=49 T__50=50 T__51=51 T__52=52 T__53=53 T__54=54 T__55=55 T__56=56 T__57=57 T__58=58 T__59=59 T__60=60 T__61=61 T__62=62 T__63=63 T__64=64 T__65=65 T__66=66 T__67=67 T__68=68 T__69=69 T__70=70 T__71=71 T__72=72 T__73=73 T__74=74 T__75=75 ESC_SEQ=4 HEX_DIGIT=5 ID=6 NUMBER=7 OCTAL_ESC=8 STRING=9 UNICODE_ESC=10 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "ESC_SEQ", "HEX_DIGIT", "ID", "NUMBER", "OCTAL_ESC", "STRING", "UNICODE_ESC", "'('", "')'", "'*'", "'+'", "','", "'-'", "'/'", "':'", "';'", "'='", "'add'", "'and'", "'at'", "'background'", "'bool'", "'call'", "'circle'", "'color'", "'different?'", "'draw'", "'elif'", "'else'", "'end'", "'equals?'", "'false'", "'from'", "'function'", "'greater?'", "'height'", "'id'", "'if'", "'less?'", "'line'", "'list'", "'max:'", "'min:'", "'not'", "'number'", "'or'", "'params'", "'point'", "'point-width'", "'points'", "'polygon'", "'print'", "'radius'", "'random'", "'rectangle'", "'remove'", "'repeat'", "'return'", "'set'", "'shape'", "'start'", "'string'", "'to'", "'true'", "'var'", "'while'", "'width'", "'with'", "'x'", "'y'", "'{'", "'}'" ] class chabuildlyParser(DebugParser): grammarFileName = "/Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g" api_version = 1 tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() debug_socket = kwargs.pop('debug_socket', None) port = kwargs.pop('port', None) super(chabuildlyParser, self).__init__(input, state, *args, **kwargs) self.delegates = [] self.ruleLevel = 0 if self._dbg is None: proxy = DebugEventSocketProxy(self, debug=debug_socket, port=port) self.setDebugListener(proxy) proxy.handshake() ruleNames = [ "invalidRule", "rectangle", "vars", "function", "block", "loop", "term", "color", "random", "write", "factor", "params", "program", "statement", "listStmt", "mainFunction", "assignment", "conditional", "funcCall", "point", "line", "list", "boolOp", "bExpression", "cte", "type", "back", "drawingStmts", "circle", "exp", "returnStmt", "polygon", "shape", "expression", "drwShape" ] decisionCanBacktrack = [ False, # invalid decision False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False ] def getRuleLevel(self): return self.ruleLevel def incRuleLevel(self): self.ruleLevel += 1 def decRuleLevel(self): self.ruleLevel -= 1 def evalPredicate(self, result, predicate): self._dbg.semanticPredicate(result, predicate) return result # $ANTLR start "program" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:6:1: program : ( function )* mainFunction ; def program(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "program") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(6, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:6:9: ( ( function )* mainFunction ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:6:11: ( function )* mainFunction pass self._dbg.location(6, 11) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:6:11: ( function )* try: self._dbg.enterSubRule(1) while True: #loop1 alt1 = 2 try: self._dbg.enterDecision( 1, self.decisionCanBacktrack[1]) LA1_0 = self.input.LA(1) if (LA1_0 == 37) : alt1 = 1 finally: self._dbg.exitDecision(1) if alt1 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:6:11: function pass self._dbg.location(6, 11) self._state.following.append(self.FOLLOW_function_in_program20) self.function() self._state.following.pop() else: break #loop1 finally: self._dbg.exitSubRule(1) self._dbg.location(6, 21) self._state.following.append(self.FOLLOW_mainFunction_in_program23) self.mainFunction() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(6, 32+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "program") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "program" # $ANTLR start "mainFunction" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:8:1: mainFunction : 'start' '{' ( vars )* block '}' 'end' ; def mainFunction(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "mainFunction") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(8, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:8:13: ( 'start' '{' ( vars )* block '}' 'end' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:8:15: 'start' '{' ( vars )* block '}' 'end' pass self._dbg.location(8, 15) self.match(self.input, 64, self.FOLLOW_64_in_mainFunction30) self._dbg.location(8, 23) self.match(self.input, 74, self.FOLLOW_74_in_mainFunction32) self._dbg.location(8, 27) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:8:27: ( vars )* try: self._dbg.enterSubRule(2) while True: #loop2 alt2 = 2 try: self._dbg.enterDecision( 2, self.decisionCanBacktrack[2]) LA2_0 = self.input.LA(1) if (LA2_0 == 44 or LA2_0 == 68) : alt2 = 1 finally: self._dbg.exitDecision(2) if alt2 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:8:27: vars pass self._dbg.location(8, 27) self._state.following.append(self.FOLLOW_vars_in_mainFunction34) self.vars() self._state.following.pop() else: break #loop2 finally: self._dbg.exitSubRule(2) self._dbg.location(8, 33) self._state.following.append(self.FOLLOW_block_in_mainFunction37) self.block() self._state.following.pop() self._dbg.location(8, 39) self.match(self.input, 75, self.FOLLOW_75_in_mainFunction39) self._dbg.location(8, 43) self.match(self.input, 33, self.FOLLOW_33_in_mainFunction41) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(8, 47+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "mainFunction") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "mainFunction" # $ANTLR start "function" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:10:1: function : 'function' ID ':' params '{' ( vars )* block '}' 'end' ; def function(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "function") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(10, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:10:9: ( 'function' ID ':' params '{' ( vars )* block '}' 'end' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:10:11: 'function' ID ':' params '{' ( vars )* block '}' 'end' pass self._dbg.location(10, 11) self.match(self.input, 37, self.FOLLOW_37_in_function48) self._dbg.location(10, 22) self.match(self.input, ID, self.FOLLOW_ID_in_function50) self._dbg.location(10, 25) self.match(self.input, 18, self.FOLLOW_18_in_function52) self._dbg.location(10, 29) self._state.following.append(self.FOLLOW_params_in_function54) self.params() self._state.following.pop() self._dbg.location(10, 36) self.match(self.input, 74, self.FOLLOW_74_in_function56) self._dbg.location(10, 40) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:10:40: ( vars )* try: self._dbg.enterSubRule(3) while True: #loop3 alt3 = 2 try: self._dbg.enterDecision( 3, self.decisionCanBacktrack[3]) LA3_0 = self.input.LA(1) if (LA3_0 == 44 or LA3_0 == 68) : alt3 = 1 finally: self._dbg.exitDecision(3) if alt3 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:10:40: vars pass self._dbg.location(10, 40) self._state.following.append(self.FOLLOW_vars_in_function58) self.vars() self._state.following.pop() else: break #loop3 finally: self._dbg.exitSubRule(3) self._dbg.location(10, 46) self._state.following.append(self.FOLLOW_block_in_function61) self.block() self._state.following.pop() self._dbg.location(10, 52) self.match(self.input, 75, self.FOLLOW_75_in_function63) self._dbg.location(10, 56) self.match(self.input, 33, self.FOLLOW_33_in_function65) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(10, 60+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "function") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "function" # $ANTLR start "vars" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:12:1: vars : ( 'var' type ID | list ) ';' ; def vars(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "vars") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(12, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:12:6: ( ( 'var' type ID | list ) ';' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:12:8: ( 'var' type ID | list ) ';' pass self._dbg.location(12, 8) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:12:8: ( 'var' type ID | list ) alt4 = 2 try: self._dbg.enterSubRule(4) try: self._dbg.enterDecision( 4, self.decisionCanBacktrack[4]) LA4_0 = self.input.LA(1) if (LA4_0 == 68) : alt4 = 1 elif (LA4_0 == 44) : alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(4) if alt4 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:12:9: 'var' type ID pass self._dbg.location(12, 9) self.match(self.input, 68, self.FOLLOW_68_in_vars74) self._dbg.location(12, 15) self._state.following.append(self.FOLLOW_type_in_vars76) self.type() self._state.following.pop() self._dbg.location(12, 20) self.match(self.input, ID, self.FOLLOW_ID_in_vars78) elif alt4 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:12:25: list pass self._dbg.location(12, 25) self._state.following.append(self.FOLLOW_list_in_vars82) self.list() self._state.following.pop() finally: self._dbg.exitSubRule(4) self._dbg.location(12, 31) self.match(self.input, 19, self.FOLLOW_19_in_vars85) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(12, 33+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "vars") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "vars" # $ANTLR start "block" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:14:1: block : '{' ( statement )* '}' ; def block(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "block") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(14, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:14:7: ( '{' ( statement )* '}' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:14:10: '{' ( statement )* '}' pass self._dbg.location(14, 10) self.match(self.input, 74, self.FOLLOW_74_in_block94) self._dbg.location(14, 14) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:14:14: ( statement )* try: self._dbg.enterSubRule(5) while True: #loop5 alt5 = 2 try: self._dbg.enterDecision( 5, self.decisionCanBacktrack[5]) LA5_0 = self.input.LA(1) if (LA5_0 == 26 or LA5_0 == 30 or LA5_0 == 41 or LA5_0 == 44 or LA5_0 == 55 or LA5_0 == 57 or (60 <= LA5_0 <= 62)) : alt5 = 1 finally: self._dbg.exitDecision(5) if alt5 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:14:14: statement pass self._dbg.location(14, 14) self._state.following.append(self.FOLLOW_statement_in_block96) self.statement() self._state.following.pop() else: break #loop5 finally: self._dbg.exitSubRule(5) self._dbg.location(14, 25) self.match(self.input, 75, self.FOLLOW_75_in_block99) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(14, 27+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "block") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "block" # $ANTLR start "statement" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:1: statement : ( conditional | assignment | write | loop | returnStmt | funcCall | drawingStmts | listStmt ) ';' ; def statement(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "statement") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(16, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:11: ( ( conditional | assignment | write | loop | returnStmt | funcCall | drawingStmts | listStmt ) ';' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:13: ( conditional | assignment | write | loop | returnStmt | funcCall | drawingStmts | listStmt ) ';' pass self._dbg.location(16, 13) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:13: ( conditional | assignment | write | loop | returnStmt | funcCall | drawingStmts | listStmt ) alt6 = 8 try: self._dbg.enterSubRule(6) try: self._dbg.enterDecision( 6, self.decisionCanBacktrack[6]) LA6 = self.input.LA(1) if LA6 == 41: alt6 = 1 elif LA6 == 62: LA6_2 = self.input.LA(2) if (LA6_2 == ID) : alt6 = 2 elif (LA6_2 == 24) : alt6 = 7 else: nvae = NoViableAltException("", 6, 2, self.input) self._dbg.recognitionException(nvae) raise nvae elif LA6 == 55: alt6 = 3 elif LA6 == 60: alt6 = 4 elif LA6 == 61: alt6 = 5 elif LA6 == 26: alt6 = 6 elif LA6 == 30 or LA6 == 57: alt6 = 7 elif LA6 == 44: alt6 = 8 else: nvae = NoViableAltException("", 6, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(6) if alt6 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:14: conditional pass self._dbg.location(16, 14) self._state.following.append(self.FOLLOW_conditional_in_statement108) self.conditional() self._state.following.pop() elif alt6 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:26: assignment pass self._dbg.location(16, 26) self._state.following.append(self.FOLLOW_assignment_in_statement110) self.assignment() self._state.following.pop() elif alt6 == 3: self._dbg.enterAlt(3) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:37: write pass self._dbg.location(16, 37) self._state.following.append(self.FOLLOW_write_in_statement112) self.write() self._state.following.pop() elif alt6 == 4: self._dbg.enterAlt(4) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:43: loop pass self._dbg.location(16, 43) self._state.following.append(self.FOLLOW_loop_in_statement114) self.loop() self._state.following.pop() elif alt6 == 5: self._dbg.enterAlt(5) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:49: returnStmt pass self._dbg.location(16, 49) self._state.following.append(self.FOLLOW_returnStmt_in_statement117) self.returnStmt() self._state.following.pop() elif alt6 == 6: self._dbg.enterAlt(6) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:61: funcCall pass self._dbg.location(16, 61) self._state.following.append(self.FOLLOW_funcCall_in_statement120) self.funcCall() self._state.following.pop() elif alt6 == 7: self._dbg.enterAlt(7) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:71: drawingStmts pass self._dbg.location(16, 71) self._state.following.append(self.FOLLOW_drawingStmts_in_statement123) self.drawingStmts() self._state.following.pop() elif alt6 == 8: self._dbg.enterAlt(8) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:87: listStmt pass self._dbg.location(16, 87) self._state.following.append(self.FOLLOW_listStmt_in_statement128) self.listStmt() self._state.following.pop() finally: self._dbg.exitSubRule(6) self._dbg.location(16, 97) self.match(self.input, 19, self.FOLLOW_19_in_statement131) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(16, 99+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "statement") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "statement" # $ANTLR start "conditional" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:1: conditional : 'if' expression block ( 'elif' expression block )? ( 'else' block )? 'end' ; def conditional(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "conditional") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(18, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:13: ( 'if' expression block ( 'elif' expression block )? ( 'else' block )? 'end' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:15: 'if' expression block ( 'elif' expression block )? ( 'else' block )? 'end' pass self._dbg.location(18, 15) self.match(self.input, 41, self.FOLLOW_41_in_conditional139) self._dbg.location(18, 20) self._state.following.append(self.FOLLOW_expression_in_conditional141) self.expression() self._state.following.pop() self._dbg.location(18, 31) self._state.following.append(self.FOLLOW_block_in_conditional143) self.block() self._state.following.pop() self._dbg.location(18, 37) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:37: ( 'elif' expression block )? alt7 = 2 try: self._dbg.enterSubRule(7) try: self._dbg.enterDecision( 7, self.decisionCanBacktrack[7]) LA7_0 = self.input.LA(1) if (LA7_0 == 31) : alt7 = 1 finally: self._dbg.exitDecision(7) if alt7 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:38: 'elif' expression block pass self._dbg.location(18, 38) self.match(self.input, 31, self.FOLLOW_31_in_conditional146) self._dbg.location(18, 45) self._state.following.append(self.FOLLOW_expression_in_conditional148) self.expression() self._state.following.pop() self._dbg.location(18, 56) self._state.following.append(self.FOLLOW_block_in_conditional150) self.block() self._state.following.pop() finally: self._dbg.exitSubRule(7) self._dbg.location(18, 64) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:64: ( 'else' block )? alt8 = 2 try: self._dbg.enterSubRule(8) try: self._dbg.enterDecision( 8, self.decisionCanBacktrack[8]) LA8_0 = self.input.LA(1) if (LA8_0 == 32) : alt8 = 1 finally: self._dbg.exitDecision(8) if alt8 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:65: 'else' block pass self._dbg.location(18, 65) self.match(self.input, 32, self.FOLLOW_32_in_conditional155) self._dbg.location(18, 72) self._state.following.append(self.FOLLOW_block_in_conditional157) self.block() self._state.following.pop() finally: self._dbg.exitSubRule(8) self._dbg.location(18, 80) self.match(self.input, 33, self.FOLLOW_33_in_conditional161) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(18, 84+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "conditional") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "conditional" # $ANTLR start "write" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:20:1: write : 'print' ( expression | STRING ) ; def write(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "write") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(20, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:20:7: ( 'print' ( expression | STRING ) ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:20:9: 'print' ( expression | STRING ) pass self._dbg.location(20, 9) self.match(self.input, 55, self.FOLLOW_55_in_write169) self._dbg.location(20, 17) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:20:17: ( expression | STRING ) alt9 = 2 try: self._dbg.enterSubRule(9) try: self._dbg.enterDecision( 9, self.decisionCanBacktrack[9]) LA9_0 = self.input.LA(1) if ((ID <= LA9_0 <= NUMBER) or LA9_0 == 11 or LA9_0 == 14 or LA9_0 == 16 or LA9_0 == 26 or LA9_0 == 35 or LA9_0 == 47 or LA9_0 == 67) : alt9 = 1 elif (LA9_0 == STRING) : alt9 = 2 else: nvae = NoViableAltException("", 9, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(9) if alt9 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:20:18: expression pass self._dbg.location(20, 18) self._state.following.append(self.FOLLOW_expression_in_write172) self.expression() self._state.following.pop() elif alt9 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:20:30: STRING pass self._dbg.location(20, 30) self.match(self.input, STRING, self.FOLLOW_STRING_in_write175) finally: self._dbg.exitSubRule(9) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(20, 36+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "write") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "write" # $ANTLR start "expression" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:22:1: expression : bExpression ( boolOp bExpression )? ; def expression(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "expression") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(22, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:22:12: ( bExpression ( boolOp bExpression )? ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:22:15: bExpression ( boolOp bExpression )? pass self._dbg.location(22, 15) self._state.following.append(self.FOLLOW_bExpression_in_expression185) self.bExpression() self._state.following.pop() self._dbg.location(22, 27) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:22:27: ( boolOp bExpression )? alt10 = 2 try: self._dbg.enterSubRule(10) try: self._dbg.enterDecision( 10, self.decisionCanBacktrack[10]) LA10_0 = self.input.LA(1) if (LA10_0 == 22 or LA10_0 == 49) : alt10 = 1 finally: self._dbg.exitDecision(10) if alt10 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:22:28: boolOp bExpression pass self._dbg.location(22, 28) self._state.following.append(self.FOLLOW_boolOp_in_expression188) self.boolOp() self._state.following.pop() self._dbg.location(22, 35) self._state.following.append(self.FOLLOW_bExpression_in_expression190) self.bExpression() self._state.following.pop() finally: self._dbg.exitSubRule(10) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(22, 48+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "expression") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "expression" # $ANTLR start "bExpression" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:24:1: bExpression : ( exp ( 'less?' | 'greater?' | 'equals?' | 'different?' ) exp | 'true' | 'false' ); def bExpression(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "bExpression") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(24, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:24:13: ( exp ( 'less?' | 'greater?' | 'equals?' | 'different?' ) exp | 'true' | 'false' ) alt11 = 3 try: self._dbg.enterDecision( 11, self.decisionCanBacktrack[11]) LA11 = self.input.LA(1) if LA11 == ID or LA11 == NUMBER or LA11 == 11 or LA11 == 14 or LA11 == 16 or LA11 == 26 or LA11 == 47: alt11 = 1 elif LA11 == 67: alt11 = 2 elif LA11 == 35: alt11 = 3 else: nvae = NoViableAltException("", 11, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(11) if alt11 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:24:14: exp ( 'less?' | 'greater?' | 'equals?' | 'different?' ) exp pass self._dbg.location(24, 14) self._state.following.append(self.FOLLOW_exp_in_bExpression200) self.exp() self._state.following.pop() self._dbg.location(24, 18) if self.input.LA(1) == 29 or self.input.LA(1) == 34 or self.input.LA(1) == 38 or self.input.LA(1) == 42: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) self._dbg.recognitionException(mse) raise mse self._dbg.location(24, 68) self._state.following.append(self.FOLLOW_exp_in_bExpression218) self.exp() self._state.following.pop() elif alt11 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:24:74: 'true' pass self._dbg.location(24, 74) self.match(self.input, 67, self.FOLLOW_67_in_bExpression222) elif alt11 == 3: self._dbg.enterAlt(3) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:24:83: 'false' pass self._dbg.location(24, 83) self.match(self.input, 35, self.FOLLOW_35_in_bExpression226) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(24, 89+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "bExpression") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "bExpression" # $ANTLR start "params" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:1: params : 'params' ':' '(' ( type ID ( ',' type ID )* )? ')' ; def params(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "params") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(26, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:7: ( 'params' ':' '(' ( type ID ( ',' type ID )* )? ')' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:8: 'params' ':' '(' ( type ID ( ',' type ID )* )? ')' pass self._dbg.location(26, 8) self.match(self.input, 50, self.FOLLOW_50_in_params232) self._dbg.location(26, 17) self.match(self.input, 18, self.FOLLOW_18_in_params234) self._dbg.location(26, 21) self.match(self.input, 11, self.FOLLOW_11_in_params236) self._dbg.location(26, 25) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:25: ( type ID ( ',' type ID )* )? alt13 = 2 try: self._dbg.enterSubRule(13) try: self._dbg.enterDecision( 13, self.decisionCanBacktrack[13]) LA13_0 = self.input.LA(1) if (LA13_0 == 25 or LA13_0 == 48 or LA13_0 == 65) : alt13 = 1 finally: self._dbg.exitDecision(13) if alt13 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:27: type ID ( ',' type ID )* pass self._dbg.location(26, 27) self._state.following.append(self.FOLLOW_type_in_params240) self.type() self._state.following.pop() self._dbg.location(26, 32) self.match(self.input, ID, self.FOLLOW_ID_in_params242) self._dbg.location(26, 35) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:35: ( ',' type ID )* try: self._dbg.enterSubRule(12) while True: #loop12 alt12 = 2 try: self._dbg.enterDecision( 12, self.decisionCanBacktrack[12]) LA12_0 = self.input.LA(1) if (LA12_0 == 15) : alt12 = 1 finally: self._dbg.exitDecision(12) if alt12 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:37: ',' type ID pass self._dbg.location(26, 37) self.match(self.input, 15, self.FOLLOW_15_in_params246) self._dbg.location(26, 41) self._state.following.append(self.FOLLOW_type_in_params248) self.type() self._state.following.pop() self._dbg.location(26, 46) self.match(self.input, ID, self.FOLLOW_ID_in_params250) else: break #loop12 finally: self._dbg.exitSubRule(12) finally: self._dbg.exitSubRule(13) self._dbg.location(26, 53) self.match(self.input, 12, self.FOLLOW_12_in_params256) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(26, 55+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "params") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "params" # $ANTLR start "type" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:28:1: type : ( 'number' | 'string' | 'bool' ); def type(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "type") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(28, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:28:5: ( 'number' | 'string' | 'bool' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g: pass self._dbg.location(28, 5) if self.input.LA(1) == 25 or self.input.LA(1) == 48 or self.input.LA(1) == 65: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) self._dbg.recognitionException(mse) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(28, 30+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "type") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "type" # $ANTLR start "loop" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:30:1: loop : 'repeat' 'while' '(' expression ')' block 'end' ; def loop(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "loop") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(30, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:30:6: ( 'repeat' 'while' '(' expression ')' block 'end' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:30:9: 'repeat' 'while' '(' expression ')' block 'end' pass self._dbg.location(30, 9) self.match(self.input, 60, self.FOLLOW_60_in_loop276) self._dbg.location(30, 18) self.match(self.input, 69, self.FOLLOW_69_in_loop278) self._dbg.location(30, 26) self.match(self.input, 11, self.FOLLOW_11_in_loop280) self._dbg.location(30, 30) self._state.following.append(self.FOLLOW_expression_in_loop282) self.expression() self._state.following.pop() self._dbg.location(30, 41) self.match(self.input, 12, self.FOLLOW_12_in_loop284) self._dbg.location(30, 45) self._state.following.append(self.FOLLOW_block_in_loop286) self.block() self._state.following.pop() self._dbg.location(30, 51) self.match(self.input, 33, self.FOLLOW_33_in_loop288) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(30, 55+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "loop") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "loop" # $ANTLR start "exp" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:1: exp : ( term ( ( '+' | '-' ) term )* ) ; def exp(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "exp") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(32, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:5: ( ( term ( ( '+' | '-' ) term )* ) ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:7: ( term ( ( '+' | '-' ) term )* ) pass self._dbg.location(32, 7) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:7: ( term ( ( '+' | '-' ) term )* ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:8: term ( ( '+' | '-' ) term )* pass self._dbg.location(32, 8) self._state.following.append(self.FOLLOW_term_in_exp297) self.term() self._state.following.pop() self._dbg.location(32, 13) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:13: ( ( '+' | '-' ) term )* try: self._dbg.enterSubRule(14) while True: #loop14 alt14 = 2 try: self._dbg.enterDecision( 14, self.decisionCanBacktrack[14]) LA14_0 = self.input.LA(1) if (LA14_0 == 14 or LA14_0 == 16) : alt14 = 1 finally: self._dbg.exitDecision(14) if alt14 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:14: ( '+' | '-' ) term pass self._dbg.location(32, 14) if self.input.LA(1) == 14 or self.input.LA(1) == 16: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) self._dbg.recognitionException(mse) raise mse self._dbg.location(32, 24) self._state.following.append(self.FOLLOW_term_in_exp306) self.term() self._state.following.pop() else: break #loop14 finally: self._dbg.exitSubRule(14) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(32, 30+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "exp") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "exp" # $ANTLR start "term" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:1: term : ( factor ( ( '*' | '/' ) factor )* ) ; def term(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "term") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(34, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:6: ( ( factor ( ( '*' | '/' ) factor )* ) ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:8: ( factor ( ( '*' | '/' ) factor )* ) pass self._dbg.location(34, 8) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:8: ( factor ( ( '*' | '/' ) factor )* ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:9: factor ( ( '*' | '/' ) factor )* pass self._dbg.location(34, 9) self._state.following.append(self.FOLLOW_factor_in_term318) self.factor() self._state.following.pop() self._dbg.location(34, 16) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:16: ( ( '*' | '/' ) factor )* try: self._dbg.enterSubRule(15) while True: #loop15 alt15 = 2 try: self._dbg.enterDecision( 15, self.decisionCanBacktrack[15]) LA15_0 = self.input.LA(1) if (LA15_0 == 13 or LA15_0 == 17) : alt15 = 1 finally: self._dbg.exitDecision(15) if alt15 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:17: ( '*' | '/' ) factor pass self._dbg.location(34, 17) if self.input.LA(1) == 13 or self.input.LA(1) == 17: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) self._dbg.recognitionException(mse) raise mse self._dbg.location(34, 27) self._state.following.append(self.FOLLOW_factor_in_term327) self.factor() self._state.following.pop() else: break #loop15 finally: self._dbg.exitSubRule(15) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(34, 35+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "term") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "term" # $ANTLR start "factor" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:1: factor : ( ( '+' | '-' | 'not' )? ( cte | funcCall ) | '(' exp ')' ); def factor(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "factor") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(36, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:8: ( ( '+' | '-' | 'not' )? ( cte | funcCall ) | '(' exp ')' ) alt18 = 2 try: self._dbg.enterDecision( 18, self.decisionCanBacktrack[18]) LA18_0 = self.input.LA(1) if ((ID <= LA18_0 <= NUMBER) or LA18_0 == 14 or LA18_0 == 16 or LA18_0 == 26 or LA18_0 == 47) : alt18 = 1 elif (LA18_0 == 11) : alt18 = 2 else: nvae = NoViableAltException("", 18, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(18) if alt18 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:10: ( '+' | '-' | 'not' )? ( cte | funcCall ) pass self._dbg.location(36, 10) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:10: ( '+' | '-' | 'not' )? alt16 = 2 try: self._dbg.enterSubRule(16) try: self._dbg.enterDecision( 16, self.decisionCanBacktrack[16]) LA16_0 = self.input.LA(1) if (LA16_0 == 14 or LA16_0 == 16 or LA16_0 == 47) : alt16 = 1 finally: self._dbg.exitDecision(16) if alt16 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g: pass self._dbg.location(36, 10) if self.input.LA(1) == 14 or self.input.LA(1) == 16 or self.input.LA(1) == 47: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) self._dbg.recognitionException(mse) raise mse finally: self._dbg.exitSubRule(16) self._dbg.location(36, 30) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:30: ( cte | funcCall ) alt17 = 2 try: self._dbg.enterSubRule(17) try: self._dbg.enterDecision( 17, self.decisionCanBacktrack[17]) LA17_0 = self.input.LA(1) if ((ID <= LA17_0 <= NUMBER)) : alt17 = 1 elif (LA17_0 == 26) : alt17 = 2 else: nvae = NoViableAltException("", 17, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(17) if alt17 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:31: cte pass self._dbg.location(36, 31) self._state.following.append(self.FOLLOW_cte_in_factor351) self.cte() self._state.following.pop() elif alt17 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:35: funcCall pass self._dbg.location(36, 35) self._state.following.append(self.FOLLOW_funcCall_in_factor353) self.funcCall() self._state.following.pop() finally: self._dbg.exitSubRule(17) elif alt18 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:47: '(' exp ')' pass self._dbg.location(36, 47) self.match(self.input, 11, self.FOLLOW_11_in_factor358) self._dbg.location(36, 51) self._state.following.append(self.FOLLOW_exp_in_factor360) self.exp() self._state.following.pop() self._dbg.location(36, 55) self.match(self.input, 12, self.FOLLOW_12_in_factor362) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(36, 57+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "factor") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "factor" # $ANTLR start "assignment" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:38:1: assignment : 'set' ID '=' expression ; def assignment(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "assignment") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(38, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:38:12: ( 'set' ID '=' expression ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:38:14: 'set' ID '=' expression pass self._dbg.location(38, 14) self.match(self.input, 62, self.FOLLOW_62_in_assignment370) self._dbg.location(38, 20) self.match(self.input, ID, self.FOLLOW_ID_in_assignment372) self._dbg.location(38, 23) self.match(self.input, 20, self.FOLLOW_20_in_assignment374) self._dbg.location(38, 27) self._state.following.append(self.FOLLOW_expression_in_assignment376) self.expression() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(38, 36+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "assignment") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "assignment" # $ANTLR start "returnStmt" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:40:1: returnStmt : 'return' expression ; def returnStmt(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "returnStmt") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(40, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:40:12: ( 'return' expression ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:40:14: 'return' expression pass self._dbg.location(40, 14) self.match(self.input, 61, self.FOLLOW_61_in_returnStmt384) self._dbg.location(40, 23) self._state.following.append(self.FOLLOW_expression_in_returnStmt386) self.expression() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(40, 32+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "returnStmt") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "returnStmt" # $ANTLR start "funcCall" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:1: funcCall : 'call' ID '(' ( exp ( ',' exp )* )? ')' ; def funcCall(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "funcCall") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(42, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:10: ( 'call' ID '(' ( exp ( ',' exp )* )? ')' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:12: 'call' ID '(' ( exp ( ',' exp )* )? ')' pass self._dbg.location(42, 12) self.match(self.input, 26, self.FOLLOW_26_in_funcCall394) self._dbg.location(42, 19) self.match(self.input, ID, self.FOLLOW_ID_in_funcCall396) self._dbg.location(42, 22) self.match(self.input, 11, self.FOLLOW_11_in_funcCall398) self._dbg.location(42, 26) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:26: ( exp ( ',' exp )* )? alt20 = 2 try: self._dbg.enterSubRule(20) try: self._dbg.enterDecision( 20, self.decisionCanBacktrack[20]) LA20_0 = self.input.LA(1) if ((ID <= LA20_0 <= NUMBER) or LA20_0 == 11 or LA20_0 == 14 or LA20_0 == 16 or LA20_0 == 26 or LA20_0 == 47) : alt20 = 1 finally: self._dbg.exitDecision(20) if alt20 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:27: exp ( ',' exp )* pass self._dbg.location(42, 27) self._state.following.append(self.FOLLOW_exp_in_funcCall401) self.exp() self._state.following.pop() self._dbg.location(42, 31) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:31: ( ',' exp )* try: self._dbg.enterSubRule(19) while True: #loop19 alt19 = 2 try: self._dbg.enterDecision( 19, self.decisionCanBacktrack[19]) LA19_0 = self.input.LA(1) if (LA19_0 == 15) : alt19 = 1 finally: self._dbg.exitDecision(19) if alt19 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:33: ',' exp pass self._dbg.location(42, 33) self.match(self.input, 15, self.FOLLOW_15_in_funcCall405) self._dbg.location(42, 37) self._state.following.append(self.FOLLOW_exp_in_funcCall407) self.exp() self._state.following.pop() else: break #loop19 finally: self._dbg.exitSubRule(19) finally: self._dbg.exitSubRule(20) self._dbg.location(42, 46) self.match(self.input, 12, self.FOLLOW_12_in_funcCall414) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(42, 48+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "funcCall") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "funcCall" # $ANTLR start "cte" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:44:1: cte : ( ID | NUMBER ); def cte(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "cte") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(44, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:44:5: ( ID | NUMBER ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g: pass self._dbg.location(44, 5) if (ID <= self.input.LA(1) <= NUMBER): self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) self._dbg.recognitionException(mse) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(44, 17+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "cte") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "cte" # $ANTLR start "list" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:46:1: list : 'list' type 'id' '=' '(' ( cte )* ')' ; def list(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "list") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(46, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:46:6: ( 'list' type 'id' '=' '(' ( cte )* ')' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:46:8: 'list' type 'id' '=' '(' ( cte )* ')' pass self._dbg.location(46, 8) self.match(self.input, 44, self.FOLLOW_44_in_list434) self._dbg.location(46, 15) self._state.following.append(self.FOLLOW_type_in_list436) self.type() self._state.following.pop() self._dbg.location(46, 20) self.match(self.input, 40, self.FOLLOW_40_in_list438) self._dbg.location(46, 25) self.match(self.input, 20, self.FOLLOW_20_in_list440) self._dbg.location(46, 30) self.match(self.input, 11, self.FOLLOW_11_in_list443) self._dbg.location(46, 34) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:46:34: ( cte )* try: self._dbg.enterSubRule(21) while True: #loop21 alt21 = 2 try: self._dbg.enterDecision( 21, self.decisionCanBacktrack[21]) LA21_0 = self.input.LA(1) if ((ID <= LA21_0 <= NUMBER)) : alt21 = 1 finally: self._dbg.exitDecision(21) if alt21 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:46:35: cte pass self._dbg.location(46, 35) self._state.following.append(self.FOLLOW_cte_in_list446) self.cte() self._state.following.pop() else: break #loop21 finally: self._dbg.exitSubRule(21) self._dbg.location(46, 41) self.match(self.input, 12, self.FOLLOW_12_in_list450) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(46, 43+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "list") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "list" # $ANTLR start "listStmt" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:48:1: listStmt : 'list' 'id' ( 'add' cte | 'remove' cte ) ; def listStmt(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "listStmt") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(48, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:48:10: ( 'list' 'id' ( 'add' cte | 'remove' cte ) ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:48:12: 'list' 'id' ( 'add' cte | 'remove' cte ) pass self._dbg.location(48, 12) self.match(self.input, 44, self.FOLLOW_44_in_listStmt458) self._dbg.location(48, 19) self.match(self.input, 40, self.FOLLOW_40_in_listStmt460) self._dbg.location(48, 24) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:48:24: ( 'add' cte | 'remove' cte ) alt22 = 2 try: self._dbg.enterSubRule(22) try: self._dbg.enterDecision( 22, self.decisionCanBacktrack[22]) LA22_0 = self.input.LA(1) if (LA22_0 == 21) : alt22 = 1 elif (LA22_0 == 59) : alt22 = 2 else: nvae = NoViableAltException("", 22, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(22) if alt22 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:48:25: 'add' cte pass self._dbg.location(48, 25) self.match(self.input, 21, self.FOLLOW_21_in_listStmt463) self._dbg.location(48, 31) self._state.following.append(self.FOLLOW_cte_in_listStmt465) self.cte() self._state.following.pop() elif alt22 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:48:36: 'remove' cte pass self._dbg.location(48, 36) self.match(self.input, 59, self.FOLLOW_59_in_listStmt468) self._dbg.location(48, 45) self._state.following.append(self.FOLLOW_cte_in_listStmt470) self.cte() self._state.following.pop() finally: self._dbg.exitSubRule(22) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(48, 48+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "listStmt") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "listStmt" # $ANTLR start "boolOp" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:50:1: boolOp : ( 'and' | 'or' ); def boolOp(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "boolOp") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(50, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:50:8: ( 'and' | 'or' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g: pass self._dbg.location(50, 8) if self.input.LA(1) == 22 or self.input.LA(1) == 49: self.input.consume() self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) self._dbg.recognitionException(mse) raise mse except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(50, 20+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "boolOp") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "boolOp" # $ANTLR start "drawingStmts" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:52:1: drawingStmts : ( drwShape | back | random ); def drawingStmts(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "drawingStmts") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(52, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:52:14: ( drwShape | back | random ) alt23 = 3 try: self._dbg.enterDecision( 23, self.decisionCanBacktrack[23]) LA23 = self.input.LA(1) if LA23 == 30: alt23 = 1 elif LA23 == 62: alt23 = 2 elif LA23 == 57: alt23 = 3 else: nvae = NoViableAltException("", 23, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(23) if alt23 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:52:16: drwShape pass self._dbg.location(52, 16) self._state.following.append(self.FOLLOW_drwShape_in_drawingStmts490) self.drwShape() self._state.following.pop() elif alt23 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:52:27: back pass self._dbg.location(52, 27) self._state.following.append(self.FOLLOW_back_in_drawingStmts494) self.back() self._state.following.pop() elif alt23 == 3: self._dbg.enterAlt(3) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:52:34: random pass self._dbg.location(52, 34) self._state.following.append(self.FOLLOW_random_in_drawingStmts498) self.random() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(52, 39+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "drawingStmts") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "drawingStmts" # $ANTLR start "drwShape" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:54:1: drwShape : 'draw' 'shape' shape 'color' color 'point-width' cte ; def drwShape(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "drwShape") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(54, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:54:10: ( 'draw' 'shape' shape 'color' color 'point-width' cte ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:54:12: 'draw' 'shape' shape 'color' color 'point-width' cte pass self._dbg.location(54, 12) self.match(self.input, 30, self.FOLLOW_30_in_drwShape506) self._dbg.location(54, 19) self.match(self.input, 63, self.FOLLOW_63_in_drwShape508) self._dbg.location(54, 27) self._state.following.append(self.FOLLOW_shape_in_drwShape510) self.shape() self._state.following.pop() self._dbg.location(54, 33) self.match(self.input, 28, self.FOLLOW_28_in_drwShape512) self._dbg.location(54, 41) self._state.following.append(self.FOLLOW_color_in_drwShape514) self.color() self._state.following.pop() self._dbg.location(54, 47) self.match(self.input, 52, self.FOLLOW_52_in_drwShape516) self._dbg.location(54, 61) self._state.following.append(self.FOLLOW_cte_in_drwShape518) self.cte() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(54, 63+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "drwShape") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "drwShape" # $ANTLR start "shape" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:56:1: shape : ( line | polygon | circle | rectangle ); def shape(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "shape") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(56, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:56:7: ( line | polygon | circle | rectangle ) alt24 = 4 try: self._dbg.enterDecision( 24, self.decisionCanBacktrack[24]) LA24 = self.input.LA(1) if LA24 == 43: alt24 = 1 elif LA24 == 54: alt24 = 2 elif LA24 == 27: alt24 = 3 elif LA24 == 58: alt24 = 4 else: nvae = NoViableAltException("", 24, 0, self.input) self._dbg.recognitionException(nvae) raise nvae finally: self._dbg.exitDecision(24) if alt24 == 1: self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:56:9: line pass self._dbg.location(56, 9) self._state.following.append(self.FOLLOW_line_in_shape526) self.line() self._state.following.pop() elif alt24 == 2: self._dbg.enterAlt(2) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:56:16: polygon pass self._dbg.location(56, 16) self._state.following.append(self.FOLLOW_polygon_in_shape530) self.polygon() self._state.following.pop() elif alt24 == 3: self._dbg.enterAlt(3) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:56:26: circle pass self._dbg.location(56, 26) self._state.following.append(self.FOLLOW_circle_in_shape534) self.circle() self._state.following.pop() elif alt24 == 4: self._dbg.enterAlt(4) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:56:35: rectangle pass self._dbg.location(56, 35) self._state.following.append(self.FOLLOW_rectangle_in_shape538) self.rectangle() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(56, 43+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "shape") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "shape" # $ANTLR start "line" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:58:1: line : 'line' 'from' point 'to' point ; def line(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "line") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(58, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:58:6: ( 'line' 'from' point 'to' point ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:58:8: 'line' 'from' point 'to' point pass self._dbg.location(58, 8) self.match(self.input, 43, self.FOLLOW_43_in_line546) self._dbg.location(58, 15) self.match(self.input, 36, self.FOLLOW_36_in_line548) self._dbg.location(58, 22) self._state.following.append(self.FOLLOW_point_in_line550) self.point() self._state.following.pop() self._dbg.location(58, 28) self.match(self.input, 66, self.FOLLOW_66_in_line552) self._dbg.location(58, 33) self._state.following.append(self.FOLLOW_point_in_line554) self.point() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(58, 37+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "line") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "line" # $ANTLR start "polygon" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:60:1: polygon : 'polygon' 'with' 'points' 'list' ID ; def polygon(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "polygon") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(60, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:60:9: ( 'polygon' 'with' 'points' 'list' ID ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:60:10: 'polygon' 'with' 'points' 'list' ID pass self._dbg.location(60, 10) self.match(self.input, 54, self.FOLLOW_54_in_polygon561) self._dbg.location(60, 20) self.match(self.input, 71, self.FOLLOW_71_in_polygon563) self._dbg.location(60, 27) self.match(self.input, 53, self.FOLLOW_53_in_polygon565) self._dbg.location(60, 36) self.match(self.input, 44, self.FOLLOW_44_in_polygon567) self._dbg.location(60, 43) self.match(self.input, ID, self.FOLLOW_ID_in_polygon569) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(60, 44+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "polygon") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "polygon" # $ANTLR start "circle" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:62:1: circle : 'circle' 'at' point 'radius' cte ; def circle(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "circle") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(62, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:62:8: ( 'circle' 'at' point 'radius' cte ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:62:10: 'circle' 'at' point 'radius' cte pass self._dbg.location(62, 10) self.match(self.input, 27, self.FOLLOW_27_in_circle577) self._dbg.location(62, 19) self.match(self.input, 23, self.FOLLOW_23_in_circle579) self._dbg.location(62, 24) self._state.following.append(self.FOLLOW_point_in_circle581) self.point() self._state.following.pop() self._dbg.location(62, 30) self.match(self.input, 56, self.FOLLOW_56_in_circle583) self._dbg.location(62, 39) self._state.following.append(self.FOLLOW_cte_in_circle585) self.cte() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(62, 41+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "circle") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "circle" # $ANTLR start "rectangle" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:64:1: rectangle : 'rectangle' 'at' point 'width' cte 'height' cte ; def rectangle(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "rectangle") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(64, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:64:11: ( 'rectangle' 'at' point 'width' cte 'height' cte ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:64:13: 'rectangle' 'at' point 'width' cte 'height' cte pass self._dbg.location(64, 13) self.match(self.input, 58, self.FOLLOW_58_in_rectangle593) self._dbg.location(64, 25) self.match(self.input, 23, self.FOLLOW_23_in_rectangle595) self._dbg.location(64, 30) self._state.following.append(self.FOLLOW_point_in_rectangle597) self.point() self._state.following.pop() self._dbg.location(64, 36) self.match(self.input, 70, self.FOLLOW_70_in_rectangle599) self._dbg.location(64, 44) self._state.following.append(self.FOLLOW_cte_in_rectangle601) self.cte() self._state.following.pop() self._dbg.location(64, 48) self.match(self.input, 39, self.FOLLOW_39_in_rectangle603) self._dbg.location(64, 57) self._state.following.append(self.FOLLOW_cte_in_rectangle605) self.cte() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(64, 59+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "rectangle") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "rectangle" # $ANTLR start "point" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:66:1: point : 'point' 'x' ':' cte 'y' ':' cte ; def point(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "point") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(66, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:66:7: ( 'point' 'x' ':' cte 'y' ':' cte ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:66:9: 'point' 'x' ':' cte 'y' ':' cte pass self._dbg.location(66, 9) self.match(self.input, 51, self.FOLLOW_51_in_point613) self._dbg.location(66, 17) self.match(self.input, 72, self.FOLLOW_72_in_point615) self._dbg.location(66, 21) self.match(self.input, 18, self.FOLLOW_18_in_point617) self._dbg.location(66, 25) self._state.following.append(self.FOLLOW_cte_in_point619) self.cte() self._state.following.pop() self._dbg.location(66, 29) self.match(self.input, 73, self.FOLLOW_73_in_point621) self._dbg.location(66, 33) self.match(self.input, 18, self.FOLLOW_18_in_point623) self._dbg.location(66, 37) self._state.following.append(self.FOLLOW_cte_in_point625) self.cte() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(66, 39+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "point") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "point" # $ANTLR start "color" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:68:1: color : '(' cte ',' cte ',' cte ')' ; def color(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "color") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(68, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:68:6: ( '(' cte ',' cte ',' cte ')' ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:68:8: '(' cte ',' cte ',' cte ')' pass self._dbg.location(68, 8) self.match(self.input, 11, self.FOLLOW_11_in_color632) self._dbg.location(68, 12) self._state.following.append(self.FOLLOW_cte_in_color634) self.cte() self._state.following.pop() self._dbg.location(68, 16) self.match(self.input, 15, self.FOLLOW_15_in_color636) self._dbg.location(68, 20) self._state.following.append(self.FOLLOW_cte_in_color638) self.cte() self._state.following.pop() self._dbg.location(68, 24) self.match(self.input, 15, self.FOLLOW_15_in_color640) self._dbg.location(68, 28) self._state.following.append(self.FOLLOW_cte_in_color642) self.cte() self._state.following.pop() self._dbg.location(68, 32) self.match(self.input, 12, self.FOLLOW_12_in_color644) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(68, 34+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "color") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "color" # $ANTLR start "back" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:70:1: back : 'set' 'background' 'color' color ; def back(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "back") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(70, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:70:6: ( 'set' 'background' 'color' color ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:70:8: 'set' 'background' 'color' color pass self._dbg.location(70, 8) self.match(self.input, 62, self.FOLLOW_62_in_back652) self._dbg.location(70, 14) self.match(self.input, 24, self.FOLLOW_24_in_back654) self._dbg.location(70, 27) self.match(self.input, 28, self.FOLLOW_28_in_back656) self._dbg.location(70, 35) self._state.following.append(self.FOLLOW_color_in_back658) self.color() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(70, 39+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "back") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "back" # $ANTLR start "random" # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:72:1: random : 'random' 'number' 'min:' cte 'max:' cte ; def random(self, ): try: self._dbg.enterRule(self.getGrammarFileName(), "random") if self.getRuleLevel() == 0: self._dbg.commence(); self.incRuleLevel() self._dbg.location(72, 0+1) try: try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:72:8: ( 'random' 'number' 'min:' cte 'max:' cte ) self._dbg.enterAlt(1) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:72:10: 'random' 'number' 'min:' cte 'max:' cte pass self._dbg.location(72, 10) self.match(self.input, 57, self.FOLLOW_57_in_random666) self._dbg.location(72, 19) self.match(self.input, 48, self.FOLLOW_48_in_random668) self._dbg.location(72, 28) self.match(self.input, 46, self.FOLLOW_46_in_random670) self._dbg.location(72, 35) self._state.following.append(self.FOLLOW_cte_in_random672) self.cte() self._state.following.pop() self._dbg.location(72, 39) self.match(self.input, 45, self.FOLLOW_45_in_random674) self._dbg.location(72, 46) self._state.following.append(self.FOLLOW_cte_in_random676) self.cte() self._state.following.pop() except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass self._dbg.location(72, 48+1) finally: self._dbg.exitRule(self.getGrammarFileName(), "random") self.decRuleLevel() if self.getRuleLevel() == 0: self._dbg.terminate() return # $ANTLR end "random" FOLLOW_function_in_program20 = frozenset([37, 64]) FOLLOW_mainFunction_in_program23 = frozenset([1]) FOLLOW_64_in_mainFunction30 = frozenset([74]) FOLLOW_74_in_mainFunction32 = frozenset([44, 68, 74]) FOLLOW_vars_in_mainFunction34 = frozenset([44, 68, 74]) FOLLOW_block_in_mainFunction37 = frozenset([75]) FOLLOW_75_in_mainFunction39 = frozenset([33]) FOLLOW_33_in_mainFunction41 = frozenset([1]) FOLLOW_37_in_function48 = frozenset([6]) FOLLOW_ID_in_function50 = frozenset([18]) FOLLOW_18_in_function52 = frozenset([50]) FOLLOW_params_in_function54 = frozenset([74]) FOLLOW_74_in_function56 = frozenset([44, 68, 74]) FOLLOW_vars_in_function58 = frozenset([44, 68, 74]) FOLLOW_block_in_function61 = frozenset([75]) FOLLOW_75_in_function63 = frozenset([33]) FOLLOW_33_in_function65 = frozenset([1]) FOLLOW_68_in_vars74 = frozenset([25, 48, 65]) FOLLOW_type_in_vars76 = frozenset([6]) FOLLOW_ID_in_vars78 = frozenset([19]) FOLLOW_list_in_vars82 = frozenset([19]) FOLLOW_19_in_vars85 = frozenset([1]) FOLLOW_74_in_block94 = frozenset([26, 30, 41, 44, 55, 57, 60, 61, 62, 75]) FOLLOW_statement_in_block96 = frozenset([26, 30, 41, 44, 55, 57, 60, 61, 62, 75]) FOLLOW_75_in_block99 = frozenset([1]) FOLLOW_conditional_in_statement108 = frozenset([19]) FOLLOW_assignment_in_statement110 = frozenset([19]) FOLLOW_write_in_statement112 = frozenset([19]) FOLLOW_loop_in_statement114 = frozenset([19]) FOLLOW_returnStmt_in_statement117 = frozenset([19]) FOLLOW_funcCall_in_statement120 = frozenset([19]) FOLLOW_drawingStmts_in_statement123 = frozenset([19]) FOLLOW_listStmt_in_statement128 = frozenset([19]) FOLLOW_19_in_statement131 = frozenset([1]) FOLLOW_41_in_conditional139 = frozenset([6, 7, 11, 14, 16, 26, 35, 47, 67]) FOLLOW_expression_in_conditional141 = frozenset([74]) FOLLOW_block_in_conditional143 = frozenset([31, 32, 33]) FOLLOW_31_in_conditional146 = frozenset([6, 7, 11, 14, 16, 26, 35, 47, 67]) FOLLOW_expression_in_conditional148 = frozenset([74]) FOLLOW_block_in_conditional150 = frozenset([32, 33]) FOLLOW_32_in_conditional155 = frozenset([74]) FOLLOW_block_in_conditional157 = frozenset([33]) FOLLOW_33_in_conditional161 = frozenset([1]) FOLLOW_55_in_write169 = frozenset([6, 7, 9, 11, 14, 16, 26, 35, 47, 67]) FOLLOW_expression_in_write172 = frozenset([1]) FOLLOW_STRING_in_write175 = frozenset([1]) FOLLOW_bExpression_in_expression185 = frozenset([1, 22, 49]) FOLLOW_boolOp_in_expression188 = frozenset([6, 7, 11, 14, 16, 26, 35, 47, 67]) FOLLOW_bExpression_in_expression190 = frozenset([1]) FOLLOW_exp_in_bExpression200 = frozenset([29, 34, 38, 42]) FOLLOW_set_in_bExpression202 = frozenset([6, 7, 11, 14, 16, 26, 47]) FOLLOW_exp_in_bExpression218 = frozenset([1]) FOLLOW_67_in_bExpression222 = frozenset([1]) FOLLOW_35_in_bExpression226 = frozenset([1]) FOLLOW_50_in_params232 = frozenset([18]) FOLLOW_18_in_params234 = frozenset([11]) FOLLOW_11_in_params236 = frozenset([12, 25, 48, 65]) FOLLOW_type_in_params240 = frozenset([6]) FOLLOW_ID_in_params242 = frozenset([12, 15]) FOLLOW_15_in_params246 = frozenset([25, 48, 65]) FOLLOW_type_in_params248 = frozenset([6]) FOLLOW_ID_in_params250 = frozenset([12, 15]) FOLLOW_12_in_params256 = frozenset([1]) FOLLOW_60_in_loop276 = frozenset([69]) FOLLOW_69_in_loop278 = frozenset([11]) FOLLOW_11_in_loop280 = frozenset([6, 7, 11, 14, 16, 26, 35, 47, 67]) FOLLOW_expression_in_loop282 = frozenset([12]) FOLLOW_12_in_loop284 = frozenset([74]) FOLLOW_block_in_loop286 = frozenset([33]) FOLLOW_33_in_loop288 = frozenset([1]) FOLLOW_term_in_exp297 = frozenset([1, 14, 16]) FOLLOW_set_in_exp300 = frozenset([6, 7, 11, 14, 16, 26, 47]) FOLLOW_term_in_exp306 = frozenset([1, 14, 16]) FOLLOW_factor_in_term318 = frozenset([1, 13, 17]) FOLLOW_set_in_term321 = frozenset([6, 7, 11, 14, 16, 26, 47]) FOLLOW_factor_in_term327 = frozenset([1, 13, 17]) FOLLOW_cte_in_factor351 = frozenset([1]) FOLLOW_funcCall_in_factor353 = frozenset([1]) FOLLOW_11_in_factor358 = frozenset([6, 7, 11, 14, 16, 26, 47]) FOLLOW_exp_in_factor360 = frozenset([12]) FOLLOW_12_in_factor362 = frozenset([1]) FOLLOW_62_in_assignment370 = frozenset([6]) FOLLOW_ID_in_assignment372 = frozenset([20]) FOLLOW_20_in_assignment374 = frozenset([6, 7, 11, 14, 16, 26, 35, 47, 67]) FOLLOW_expression_in_assignment376 = frozenset([1]) FOLLOW_61_in_returnStmt384 = frozenset([6, 7, 11, 14, 16, 26, 35, 47, 67]) FOLLOW_expression_in_returnStmt386 = frozenset([1]) FOLLOW_26_in_funcCall394 = frozenset([6]) FOLLOW_ID_in_funcCall396 = frozenset([11]) FOLLOW_11_in_funcCall398 = frozenset([6, 7, 11, 12, 14, 16, 26, 47]) FOLLOW_exp_in_funcCall401 = frozenset([12, 15]) FOLLOW_15_in_funcCall405 = frozenset([6, 7, 11, 14, 16, 26, 47]) FOLLOW_exp_in_funcCall407 = frozenset([12, 15]) FOLLOW_12_in_funcCall414 = frozenset([1]) FOLLOW_44_in_list434 = frozenset([25, 48, 65]) FOLLOW_type_in_list436 = frozenset([40]) FOLLOW_40_in_list438 = frozenset([20]) FOLLOW_20_in_list440 = frozenset([11]) FOLLOW_11_in_list443 = frozenset([6, 7, 12]) FOLLOW_cte_in_list446 = frozenset([6, 7, 12]) FOLLOW_12_in_list450 = frozenset([1]) FOLLOW_44_in_listStmt458 = frozenset([40]) FOLLOW_40_in_listStmt460 = frozenset([21, 59]) FOLLOW_21_in_listStmt463 = frozenset([6, 7]) FOLLOW_cte_in_listStmt465 = frozenset([1]) FOLLOW_59_in_listStmt468 = frozenset([6, 7]) FOLLOW_cte_in_listStmt470 = frozenset([1]) FOLLOW_drwShape_in_drawingStmts490 = frozenset([1]) FOLLOW_back_in_drawingStmts494 = frozenset([1]) FOLLOW_random_in_drawingStmts498 = frozenset([1]) FOLLOW_30_in_drwShape506 = frozenset([63]) FOLLOW_63_in_drwShape508 = frozenset([27, 43, 54, 58]) FOLLOW_shape_in_drwShape510 = frozenset([28]) FOLLOW_28_in_drwShape512 = frozenset([11]) FOLLOW_color_in_drwShape514 = frozenset([52]) FOLLOW_52_in_drwShape516 = frozenset([6, 7]) FOLLOW_cte_in_drwShape518 = frozenset([1]) FOLLOW_line_in_shape526 = frozenset([1]) FOLLOW_polygon_in_shape530 = frozenset([1]) FOLLOW_circle_in_shape534 = frozenset([1]) FOLLOW_rectangle_in_shape538 = frozenset([1]) FOLLOW_43_in_line546 = frozenset([36]) FOLLOW_36_in_line548 = frozenset([51]) FOLLOW_point_in_line550 = frozenset([66]) FOLLOW_66_in_line552 = frozenset([51]) FOLLOW_point_in_line554 = frozenset([1]) FOLLOW_54_in_polygon561 = frozenset([71]) FOLLOW_71_in_polygon563 = frozenset([53]) FOLLOW_53_in_polygon565 = frozenset([44]) FOLLOW_44_in_polygon567 = frozenset([6]) FOLLOW_ID_in_polygon569 = frozenset([1]) FOLLOW_27_in_circle577 = frozenset([23]) FOLLOW_23_in_circle579 = frozenset([51]) FOLLOW_point_in_circle581 = frozenset([56]) FOLLOW_56_in_circle583 = frozenset([6, 7]) FOLLOW_cte_in_circle585 = frozenset([1]) FOLLOW_58_in_rectangle593 = frozenset([23]) FOLLOW_23_in_rectangle595 = frozenset([51]) FOLLOW_point_in_rectangle597 = frozenset([70]) FOLLOW_70_in_rectangle599 = frozenset([6, 7]) FOLLOW_cte_in_rectangle601 = frozenset([39]) FOLLOW_39_in_rectangle603 = frozenset([6, 7]) FOLLOW_cte_in_rectangle605 = frozenset([1]) FOLLOW_51_in_point613 = frozenset([72]) FOLLOW_72_in_point615 = frozenset([18]) FOLLOW_18_in_point617 = frozenset([6, 7]) FOLLOW_cte_in_point619 = frozenset([73]) FOLLOW_73_in_point621 = frozenset([18]) FOLLOW_18_in_point623 = frozenset([6, 7]) FOLLOW_cte_in_point625 = frozenset([1]) FOLLOW_11_in_color632 = frozenset([6, 7]) FOLLOW_cte_in_color634 = frozenset([15]) FOLLOW_15_in_color636 = frozenset([6, 7]) FOLLOW_cte_in_color638 = frozenset([15]) FOLLOW_15_in_color640 = frozenset([6, 7]) FOLLOW_cte_in_color642 = frozenset([12]) FOLLOW_12_in_color644 = frozenset([1]) FOLLOW_62_in_back652 = frozenset([24]) FOLLOW_24_in_back654 = frozenset([28]) FOLLOW_28_in_back656 = frozenset([11]) FOLLOW_color_in_back658 = frozenset([1]) FOLLOW_57_in_random666 = frozenset([48]) FOLLOW_48_in_random668 = frozenset([46]) FOLLOW_46_in_random670 = frozenset([6, 7]) FOLLOW_cte_in_random672 = frozenset([45]) FOLLOW_45_in_random674 = frozenset([6, 7]) FOLLOW_cte_in_random676 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("chabuildlyLexer", chabuildlyParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "montselozanod/ChabuScript", "path": "output/chabuildlyParser.py", "copies": "1", "size": "120793", "license": "mit", "hash": 6288906727162823000, "line_mean": 36.6067870486, "line_max": 199, "alpha_frac": 0.4642653134, "autogenerated": false, "ratio": 3.9142255346727155, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.48784908480727157, "avg_score": null, "num_lines": null }
# $ANTLR 3.5.1 /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g 2016-03-02 22:50:02 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__11=11 T__12=12 T__13=13 T__14=14 T__15=15 T__16=16 T__17=17 T__18=18 T__19=19 T__20=20 T__21=21 T__22=22 T__23=23 T__24=24 T__25=25 T__26=26 T__27=27 T__28=28 T__29=29 T__30=30 T__31=31 T__32=32 T__33=33 T__34=34 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 T__40=40 T__41=41 T__42=42 T__43=43 T__44=44 T__45=45 T__46=46 T__47=47 T__48=48 T__49=49 T__50=50 T__51=51 T__52=52 T__53=53 T__54=54 T__55=55 T__56=56 T__57=57 T__58=58 T__59=59 T__60=60 T__61=61 T__62=62 T__63=63 T__64=64 T__65=65 T__66=66 T__67=67 T__68=68 T__69=69 T__70=70 T__71=71 T__72=72 T__73=73 T__74=74 T__75=75 ESC_SEQ=4 HEX_DIGIT=5 ID=6 NUMBER=7 OCTAL_ESC=8 STRING=9 UNICODE_ESC=10 class chabuildlyLexer(Lexer): grammarFileName = "/Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g" api_version = 1 def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(chabuildlyLexer, self).__init__(input, state) self.delegates = [] self.dfa8 = self.DFA8( self, 8, eot = self.DFA8_eot, eof = self.DFA8_eof, min = self.DFA8_min, max = self.DFA8_max, accept = self.DFA8_accept, special = self.DFA8_special, transition = self.DFA8_transition ) # $ANTLR start "T__11" def mT__11(self, ): try: _type = T__11 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:7:7: ( '(' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:7:9: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__11" # $ANTLR start "T__12" def mT__12(self, ): try: _type = T__12 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:8:7: ( ')' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:8:9: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__12" # $ANTLR start "T__13" def mT__13(self, ): try: _type = T__13 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:9:7: ( '*' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:9:9: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__13" # $ANTLR start "T__14" def mT__14(self, ): try: _type = T__14 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:10:7: ( '+' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:10:9: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__14" # $ANTLR start "T__15" def mT__15(self, ): try: _type = T__15 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:11:7: ( ',' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:11:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__15" # $ANTLR start "T__16" def mT__16(self, ): try: _type = T__16 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:12:7: ( '-' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:12:9: '-' pass self.match(45) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__16" # $ANTLR start "T__17" def mT__17(self, ): try: _type = T__17 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:13:7: ( '/' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:13:9: '/' pass self.match(47) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__17" # $ANTLR start "T__18" def mT__18(self, ): try: _type = T__18 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:14:7: ( ':' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:14:9: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__18" # $ANTLR start "T__19" def mT__19(self, ): try: _type = T__19 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:15:7: ( ';' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:15:9: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__19" # $ANTLR start "T__20" def mT__20(self, ): try: _type = T__20 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:7: ( '=' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:16:9: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__20" # $ANTLR start "T__21" def mT__21(self, ): try: _type = T__21 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:17:7: ( 'add' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:17:9: 'add' pass self.match("add") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__21" # $ANTLR start "T__22" def mT__22(self, ): try: _type = T__22 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:7: ( 'and' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:18:9: 'and' pass self.match("and") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__22" # $ANTLR start "T__23" def mT__23(self, ): try: _type = T__23 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:19:7: ( 'at' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:19:9: 'at' pass self.match("at") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__23" # $ANTLR start "T__24" def mT__24(self, ): try: _type = T__24 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:20:7: ( 'background' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:20:9: 'background' pass self.match("background") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__24" # $ANTLR start "T__25" def mT__25(self, ): try: _type = T__25 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:21:7: ( 'bool' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:21:9: 'bool' pass self.match("bool") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__25" # $ANTLR start "T__26" def mT__26(self, ): try: _type = T__26 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:22:7: ( 'call' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:22:9: 'call' pass self.match("call") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__26" # $ANTLR start "T__27" def mT__27(self, ): try: _type = T__27 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:23:7: ( 'circle' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:23:9: 'circle' pass self.match("circle") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__27" # $ANTLR start "T__28" def mT__28(self, ): try: _type = T__28 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:24:7: ( 'color' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:24:9: 'color' pass self.match("color") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__28" # $ANTLR start "T__29" def mT__29(self, ): try: _type = T__29 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:25:7: ( 'different?' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:25:9: 'different?' pass self.match("different?") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__29" # $ANTLR start "T__30" def mT__30(self, ): try: _type = T__30 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:7: ( 'draw' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:26:9: 'draw' pass self.match("draw") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__30" # $ANTLR start "T__31" def mT__31(self, ): try: _type = T__31 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:27:7: ( 'elif' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:27:9: 'elif' pass self.match("elif") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__31" # $ANTLR start "T__32" def mT__32(self, ): try: _type = T__32 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:28:7: ( 'else' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:28:9: 'else' pass self.match("else") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__32" # $ANTLR start "T__33" def mT__33(self, ): try: _type = T__33 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:29:7: ( 'end' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:29:9: 'end' pass self.match("end") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__33" # $ANTLR start "T__34" def mT__34(self, ): try: _type = T__34 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:30:7: ( 'equals?' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:30:9: 'equals?' pass self.match("equals?") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__34" # $ANTLR start "T__35" def mT__35(self, ): try: _type = T__35 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:31:7: ( 'false' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:31:9: 'false' pass self.match("false") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__35" # $ANTLR start "T__36" def mT__36(self, ): try: _type = T__36 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:7: ( 'from' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:32:9: 'from' pass self.match("from") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__36" # $ANTLR start "T__37" def mT__37(self, ): try: _type = T__37 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:33:7: ( 'function' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:33:9: 'function' pass self.match("function") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__37" # $ANTLR start "T__38" def mT__38(self, ): try: _type = T__38 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:7: ( 'greater?' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:34:9: 'greater?' pass self.match("greater?") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__38" # $ANTLR start "T__39" def mT__39(self, ): try: _type = T__39 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:35:7: ( 'height' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:35:9: 'height' pass self.match("height") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__39" # $ANTLR start "T__40" def mT__40(self, ): try: _type = T__40 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:7: ( 'id' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:36:9: 'id' pass self.match("id") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__40" # $ANTLR start "T__41" def mT__41(self, ): try: _type = T__41 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:37:7: ( 'if' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:37:9: 'if' pass self.match("if") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__41" # $ANTLR start "T__42" def mT__42(self, ): try: _type = T__42 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:38:7: ( 'less?' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:38:9: 'less?' pass self.match("less?") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__42" # $ANTLR start "T__43" def mT__43(self, ): try: _type = T__43 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:39:7: ( 'line' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:39:9: 'line' pass self.match("line") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__43" # $ANTLR start "T__44" def mT__44(self, ): try: _type = T__44 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:40:7: ( 'list' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:40:9: 'list' pass self.match("list") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__44" # $ANTLR start "T__45" def mT__45(self, ): try: _type = T__45 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:41:7: ( 'max:' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:41:9: 'max:' pass self.match("max:") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__45" # $ANTLR start "T__46" def mT__46(self, ): try: _type = T__46 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:7: ( 'min:' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:42:9: 'min:' pass self.match("min:") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__46" # $ANTLR start "T__47" def mT__47(self, ): try: _type = T__47 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:43:7: ( 'not' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:43:9: 'not' pass self.match("not") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__47" # $ANTLR start "T__48" def mT__48(self, ): try: _type = T__48 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:44:7: ( 'number' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:44:9: 'number' pass self.match("number") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__48" # $ANTLR start "T__49" def mT__49(self, ): try: _type = T__49 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:45:7: ( 'or' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:45:9: 'or' pass self.match("or") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__49" # $ANTLR start "T__50" def mT__50(self, ): try: _type = T__50 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:46:7: ( 'params' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:46:9: 'params' pass self.match("params") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__50" # $ANTLR start "T__51" def mT__51(self, ): try: _type = T__51 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:47:7: ( 'point' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:47:9: 'point' pass self.match("point") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__51" # $ANTLR start "T__52" def mT__52(self, ): try: _type = T__52 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:48:7: ( 'point-width' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:48:9: 'point-width' pass self.match("point-width") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__52" # $ANTLR start "T__53" def mT__53(self, ): try: _type = T__53 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:49:7: ( 'points' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:49:9: 'points' pass self.match("points") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__53" # $ANTLR start "T__54" def mT__54(self, ): try: _type = T__54 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:50:7: ( 'polygon' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:50:9: 'polygon' pass self.match("polygon") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__54" # $ANTLR start "T__55" def mT__55(self, ): try: _type = T__55 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:51:7: ( 'print' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:51:9: 'print' pass self.match("print") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__55" # $ANTLR start "T__56" def mT__56(self, ): try: _type = T__56 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:52:7: ( 'radius' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:52:9: 'radius' pass self.match("radius") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__56" # $ANTLR start "T__57" def mT__57(self, ): try: _type = T__57 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:53:7: ( 'random' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:53:9: 'random' pass self.match("random") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__57" # $ANTLR start "T__58" def mT__58(self, ): try: _type = T__58 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:54:7: ( 'rectangle' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:54:9: 'rectangle' pass self.match("rectangle") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__58" # $ANTLR start "T__59" def mT__59(self, ): try: _type = T__59 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:55:7: ( 'remove' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:55:9: 'remove' pass self.match("remove") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__59" # $ANTLR start "T__60" def mT__60(self, ): try: _type = T__60 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:56:7: ( 'repeat' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:56:9: 'repeat' pass self.match("repeat") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__60" # $ANTLR start "T__61" def mT__61(self, ): try: _type = T__61 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:57:7: ( 'return' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:57:9: 'return' pass self.match("return") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__61" # $ANTLR start "T__62" def mT__62(self, ): try: _type = T__62 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:58:7: ( 'set' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:58:9: 'set' pass self.match("set") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__62" # $ANTLR start "T__63" def mT__63(self, ): try: _type = T__63 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:59:7: ( 'shape' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:59:9: 'shape' pass self.match("shape") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__63" # $ANTLR start "T__64" def mT__64(self, ): try: _type = T__64 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:60:7: ( 'start' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:60:9: 'start' pass self.match("start") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__64" # $ANTLR start "T__65" def mT__65(self, ): try: _type = T__65 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:61:7: ( 'string' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:61:9: 'string' pass self.match("string") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__65" # $ANTLR start "T__66" def mT__66(self, ): try: _type = T__66 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:62:7: ( 'to' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:62:9: 'to' pass self.match("to") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__66" # $ANTLR start "T__67" def mT__67(self, ): try: _type = T__67 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:63:7: ( 'true' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:63:9: 'true' pass self.match("true") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__67" # $ANTLR start "T__68" def mT__68(self, ): try: _type = T__68 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:64:7: ( 'var' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:64:9: 'var' pass self.match("var") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__68" # $ANTLR start "T__69" def mT__69(self, ): try: _type = T__69 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:65:7: ( 'while' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:65:9: 'while' pass self.match("while") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__69" # $ANTLR start "T__70" def mT__70(self, ): try: _type = T__70 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:66:7: ( 'width' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:66:9: 'width' pass self.match("width") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__70" # $ANTLR start "T__71" def mT__71(self, ): try: _type = T__71 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:67:7: ( 'with' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:67:9: 'with' pass self.match("with") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__71" # $ANTLR start "T__72" def mT__72(self, ): try: _type = T__72 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:68:7: ( 'x' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:68:9: 'x' pass self.match(120) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__72" # $ANTLR start "T__73" def mT__73(self, ): try: _type = T__73 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:69:7: ( 'y' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:69:9: 'y' pass self.match(121) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__73" # $ANTLR start "T__74" def mT__74(self, ): try: _type = T__74 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:70:7: ( '{' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:70:9: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__74" # $ANTLR start "T__75" def mT__75(self, ): try: _type = T__75 _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:71:7: ( '}' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:71:9: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__75" # $ANTLR start "ID" def mID(self, ): try: _type = ID _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:74:5: ( ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )* ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:74:7: ( 'a' .. 'z' | 'A' .. 'Z' | '_' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )* pass if (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:74:31: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((48 <= LA1_0 <= 57) or (65 <= LA1_0 <= 90) or LA1_0 == 95 or (97 <= LA1_0 <= 122)) : alt1 = 1 if alt1 == 1: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ID" # $ANTLR start "NUMBER" def mNUMBER(self, ): try: _type = NUMBER _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:77:8: ( ( '0' .. '9' )+ ( ( '.' ) ( '0' .. '9' )+ )? ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:77:10: ( '0' .. '9' )+ ( ( '.' ) ( '0' .. '9' )+ )? pass # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:77:10: ( '0' .. '9' )+ cnt2 = 0 while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((48 <= LA2_0 <= 57)) : alt2 = 1 if alt2 == 1: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt2 >= 1: break #loop2 eee = EarlyExitException(2, self.input) raise eee cnt2 += 1 # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:77:21: ( ( '.' ) ( '0' .. '9' )+ )? alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == 46) : alt4 = 1 if alt4 == 1: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:77:22: ( '.' ) ( '0' .. '9' )+ pass # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:77:22: ( '.' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:77:23: '.' pass self.match(46) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:77:27: ( '0' .. '9' )+ cnt3 = 0 while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if ((48 <= LA3_0 <= 57)) : alt3 = 1 if alt3 == 1: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt3 >= 1: break #loop3 eee = EarlyExitException(3, self.input) raise eee cnt3 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NUMBER" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:81:5: ( '\"' ( ESC_SEQ |~ ( '\\\\' | '\"' ) )* '\"' ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:81:8: '\"' ( ESC_SEQ |~ ( '\\\\' | '\"' ) )* '\"' pass self.match(34) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:81:12: ( ESC_SEQ |~ ( '\\\\' | '\"' ) )* while True: #loop5 alt5 = 3 LA5_0 = self.input.LA(1) if (LA5_0 == 92) : alt5 = 1 elif ((0 <= LA5_0 <= 33) or (35 <= LA5_0 <= 91) or (93 <= LA5_0 <= 65535)) : alt5 = 2 if alt5 == 1: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:81:14: ESC_SEQ pass self.mESC_SEQ() elif alt5 == 2: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:81:24: ~ ( '\\\\' | '\"' ) pass if (0 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop5 self.match(34) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "HEX_DIGIT" def mHEX_DIGIT(self, ): try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:86:11: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "HEX_DIGIT" # $ANTLR start "ESC_SEQ" def mESC_SEQ(self, ): try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:90:5: ( '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) | UNICODE_ESC | OCTAL_ESC ) alt6 = 3 LA6_0 = self.input.LA(1) if (LA6_0 == 92) : LA6 = self.input.LA(2) if LA6 == 34 or LA6 == 39 or LA6 == 92 or LA6 == 98 or LA6 == 102 or LA6 == 110 or LA6 == 114 or LA6 == 116: alt6 = 1 elif LA6 == 117: alt6 = 2 elif LA6 == 48 or LA6 == 49 or LA6 == 50 or LA6 == 51 or LA6 == 52 or LA6 == 53 or LA6 == 54 or LA6 == 55: alt6 = 3 else: nvae = NoViableAltException("", 6, 1, self.input) raise nvae else: nvae = NoViableAltException("", 6, 0, self.input) raise nvae if alt6 == 1: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:90:9: '\\\\' ( 'b' | 't' | 'n' | 'f' | 'r' | '\\\"' | '\\'' | '\\\\' ) pass self.match(92) if self.input.LA(1) == 34 or self.input.LA(1) == 39 or self.input.LA(1) == 92 or self.input.LA(1) == 98 or self.input.LA(1) == 102 or self.input.LA(1) == 110 or self.input.LA(1) == 114 or self.input.LA(1) == 116: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt6 == 2: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:91:9: UNICODE_ESC pass self.mUNICODE_ESC() elif alt6 == 3: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:92:9: OCTAL_ESC pass self.mOCTAL_ESC() finally: pass # $ANTLR end "ESC_SEQ" # $ANTLR start "OCTAL_ESC" def mOCTAL_ESC(self, ): try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:97:5: ( '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) | '\\\\' ( '0' .. '7' ) ) alt7 = 3 LA7_0 = self.input.LA(1) if (LA7_0 == 92) : LA7_1 = self.input.LA(2) if ((48 <= LA7_1 <= 51)) : LA7_2 = self.input.LA(3) if ((48 <= LA7_2 <= 55)) : LA7_4 = self.input.LA(4) if ((48 <= LA7_4 <= 55)) : alt7 = 1 else: alt7 = 2 else: alt7 = 3 elif ((52 <= LA7_1 <= 55)) : LA7_3 = self.input.LA(3) if ((48 <= LA7_3 <= 55)) : alt7 = 2 else: alt7 = 3 else: nvae = NoViableAltException("", 7, 1, self.input) raise nvae else: nvae = NoViableAltException("", 7, 0, self.input) raise nvae if alt7 == 1: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:97:9: '\\\\' ( '0' .. '3' ) ( '0' .. '7' ) ( '0' .. '7' ) pass self.match(92) if (48 <= self.input.LA(1) <= 51): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if (48 <= self.input.LA(1) <= 55): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if (48 <= self.input.LA(1) <= 55): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt7 == 2: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:98:9: '\\\\' ( '0' .. '7' ) ( '0' .. '7' ) pass self.match(92) if (48 <= self.input.LA(1) <= 55): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse if (48 <= self.input.LA(1) <= 55): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt7 == 3: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:99:9: '\\\\' ( '0' .. '7' ) pass self.match(92) if (48 <= self.input.LA(1) <= 55): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "OCTAL_ESC" # $ANTLR start "UNICODE_ESC" def mUNICODE_ESC(self, ): try: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:104:5: ( '\\\\' 'u' HEX_DIGIT HEX_DIGIT HEX_DIGIT HEX_DIGIT ) # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:104:9: '\\\\' 'u' HEX_DIGIT HEX_DIGIT HEX_DIGIT HEX_DIGIT pass self.match(92) self.match(117) self.mHEX_DIGIT() self.mHEX_DIGIT() self.mHEX_DIGIT() self.mHEX_DIGIT() finally: pass # $ANTLR end "UNICODE_ESC" def mTokens(self): # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:8: ( T__11 | T__12 | T__13 | T__14 | T__15 | T__16 | T__17 | T__18 | T__19 | T__20 | T__21 | T__22 | T__23 | T__24 | T__25 | T__26 | T__27 | T__28 | T__29 | T__30 | T__31 | T__32 | T__33 | T__34 | T__35 | T__36 | T__37 | T__38 | T__39 | T__40 | T__41 | T__42 | T__43 | T__44 | T__45 | T__46 | T__47 | T__48 | T__49 | T__50 | T__51 | T__52 | T__53 | T__54 | T__55 | T__56 | T__57 | T__58 | T__59 | T__60 | T__61 | T__62 | T__63 | T__64 | T__65 | T__66 | T__67 | T__68 | T__69 | T__70 | T__71 | T__72 | T__73 | T__74 | T__75 | ID | NUMBER | STRING ) alt8 = 68 alt8 = self.dfa8.predict(self.input) if alt8 == 1: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:10: T__11 pass self.mT__11() elif alt8 == 2: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:16: T__12 pass self.mT__12() elif alt8 == 3: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:22: T__13 pass self.mT__13() elif alt8 == 4: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:28: T__14 pass self.mT__14() elif alt8 == 5: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:34: T__15 pass self.mT__15() elif alt8 == 6: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:40: T__16 pass self.mT__16() elif alt8 == 7: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:46: T__17 pass self.mT__17() elif alt8 == 8: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:52: T__18 pass self.mT__18() elif alt8 == 9: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:58: T__19 pass self.mT__19() elif alt8 == 10: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:64: T__20 pass self.mT__20() elif alt8 == 11: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:70: T__21 pass self.mT__21() elif alt8 == 12: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:76: T__22 pass self.mT__22() elif alt8 == 13: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:82: T__23 pass self.mT__23() elif alt8 == 14: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:88: T__24 pass self.mT__24() elif alt8 == 15: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:94: T__25 pass self.mT__25() elif alt8 == 16: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:100: T__26 pass self.mT__26() elif alt8 == 17: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:106: T__27 pass self.mT__27() elif alt8 == 18: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:112: T__28 pass self.mT__28() elif alt8 == 19: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:118: T__29 pass self.mT__29() elif alt8 == 20: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:124: T__30 pass self.mT__30() elif alt8 == 21: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:130: T__31 pass self.mT__31() elif alt8 == 22: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:136: T__32 pass self.mT__32() elif alt8 == 23: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:142: T__33 pass self.mT__33() elif alt8 == 24: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:148: T__34 pass self.mT__34() elif alt8 == 25: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:154: T__35 pass self.mT__35() elif alt8 == 26: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:160: T__36 pass self.mT__36() elif alt8 == 27: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:166: T__37 pass self.mT__37() elif alt8 == 28: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:172: T__38 pass self.mT__38() elif alt8 == 29: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:178: T__39 pass self.mT__39() elif alt8 == 30: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:184: T__40 pass self.mT__40() elif alt8 == 31: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:190: T__41 pass self.mT__41() elif alt8 == 32: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:196: T__42 pass self.mT__42() elif alt8 == 33: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:202: T__43 pass self.mT__43() elif alt8 == 34: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:208: T__44 pass self.mT__44() elif alt8 == 35: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:214: T__45 pass self.mT__45() elif alt8 == 36: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:220: T__46 pass self.mT__46() elif alt8 == 37: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:226: T__47 pass self.mT__47() elif alt8 == 38: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:232: T__48 pass self.mT__48() elif alt8 == 39: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:238: T__49 pass self.mT__49() elif alt8 == 40: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:244: T__50 pass self.mT__50() elif alt8 == 41: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:250: T__51 pass self.mT__51() elif alt8 == 42: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:256: T__52 pass self.mT__52() elif alt8 == 43: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:262: T__53 pass self.mT__53() elif alt8 == 44: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:268: T__54 pass self.mT__54() elif alt8 == 45: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:274: T__55 pass self.mT__55() elif alt8 == 46: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:280: T__56 pass self.mT__56() elif alt8 == 47: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:286: T__57 pass self.mT__57() elif alt8 == 48: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:292: T__58 pass self.mT__58() elif alt8 == 49: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:298: T__59 pass self.mT__59() elif alt8 == 50: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:304: T__60 pass self.mT__60() elif alt8 == 51: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:310: T__61 pass self.mT__61() elif alt8 == 52: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:316: T__62 pass self.mT__62() elif alt8 == 53: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:322: T__63 pass self.mT__63() elif alt8 == 54: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:328: T__64 pass self.mT__64() elif alt8 == 55: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:334: T__65 pass self.mT__65() elif alt8 == 56: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:340: T__66 pass self.mT__66() elif alt8 == 57: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:346: T__67 pass self.mT__67() elif alt8 == 58: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:352: T__68 pass self.mT__68() elif alt8 == 59: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:358: T__69 pass self.mT__69() elif alt8 == 60: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:364: T__70 pass self.mT__70() elif alt8 == 61: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:370: T__71 pass self.mT__71() elif alt8 == 62: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:376: T__72 pass self.mT__72() elif alt8 == 63: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:382: T__73 pass self.mT__73() elif alt8 == 64: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:388: T__74 pass self.mT__74() elif alt8 == 65: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:394: T__75 pass self.mT__75() elif alt8 == 66: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:400: ID pass self.mID() elif alt8 == 67: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:403: NUMBER pass self.mNUMBER() elif alt8 == 68: # /Users/montselozanod/Documents/Tec/Compilers/Chabuildly/chabuildly.g:1:410: STRING pass self.mSTRING() # lookup tables for DFA #8 DFA8_eot = DFA.unpack( u"\13\uffff\23\42\1\115\1\116\5\uffff\2\42\1\121\17\42\1\142\1\143" u"\6\42\1\153\10\42\1\172\4\42\2\uffff\1\u0080\1\u0081\1\uffff\11" u"\42\1\u008b\6\42\2\uffff\5\42\1\u0097\1\42\1\uffff\12\42\1\u00a3" u"\3\42\1\uffff\1\42\1\u00a8\3\42\2\uffff\1\42\1\u00ad\1\u00ae\3" u"\42\1\u00b2\1\u00b3\1\u00b4\1\uffff\2\42\1\u00b7\4\42\1\u00bc\1" u"\u00bd\3\uffff\13\42\1\uffff\3\42\1\u00cc\1\uffff\2\42\1\u00cf" u"\1\42\2\uffff\1\42\1\u00d2\1\42\3\uffff\1\42\1\u00d5\1\uffff\3" u"\42\3\uffff\2\42\1\u00dd\1\42\1\u00df\6\42\1\u00e6\1\u00e7\1\42" u"\1\uffff\1\u00e9\1\u00ea\1\uffff\1\42\1\u00ec\1\uffff\2\42\1\uffff" u"\2\42\1\u00f1\1\u00f2\1\u00f3\1\uffff\1\u00f4\1\uffff\1\42\1\uffff" u"\1\u00f6\1\u00f7\1\42\1\u00f9\1\u00fa\1\u00fb\2\uffff\1\u00fc\2" u"\uffff\1\42\1\uffff\1\42\1\uffff\2\42\4\uffff\1\u0101\2\uffff\1" u"\42\4\uffff\2\42\1\u0105\2\uffff\3\42\1\uffff\1\u0109\1\u010a\3" u"\uffff" ) DFA8_eof = DFA.unpack( u"\u010b\uffff" ) DFA8_min = DFA.unpack( u"\1\42\12\uffff\1\144\2\141\1\151\1\154\1\141\1\162\1\145\1\144" u"\1\145\1\141\1\157\1\162\2\141\1\145\1\157\1\141\1\150\2\60\5\uffff" u"\2\144\1\60\1\143\1\157\1\154\1\162\1\154\1\146\1\141\1\151\1\144" u"\1\165\1\154\1\157\1\156\1\145\1\151\2\60\1\163\1\156\1\170\1\156" u"\1\164\1\155\1\60\1\162\2\151\1\144\1\143\1\164\2\141\1\60\1\165" u"\1\162\1\151\1\144\2\uffff\2\60\1\uffff\1\153\2\154\1\143\1\157" u"\1\146\1\167\1\146\1\145\1\60\1\141\1\163\1\155\1\143\1\141\1\147" u"\2\uffff\1\163\1\145\1\164\2\72\1\60\1\142\1\uffff\1\141\1\156" u"\1\171\1\156\1\151\1\144\1\164\1\157\1\145\1\165\1\60\1\160\1\162" u"\1\151\1\uffff\1\145\1\60\1\154\1\164\1\150\2\uffff\1\147\2\60" u"\1\154\1\162\1\145\3\60\1\uffff\1\154\1\145\1\60\2\164\1\150\1" u"\77\2\60\3\uffff\1\145\1\155\1\164\1\147\1\164\1\165\1\157\1\141" u"\1\166\1\141\1\162\1\uffff\1\145\1\164\1\156\1\60\1\uffff\1\145" u"\1\150\1\60\1\162\2\uffff\1\145\1\60\1\162\3\uffff\1\163\1\60\1" u"\uffff\1\151\1\145\1\164\3\uffff\1\162\1\163\1\55\1\157\1\60\1" u"\163\1\155\1\156\1\145\1\164\1\156\2\60\1\147\1\uffff\2\60\1\uffff" u"\1\157\1\60\1\uffff\1\145\1\77\1\uffff\1\157\1\162\3\60\1\uffff" u"\1\60\1\uffff\1\156\1\uffff\2\60\1\147\3\60\2\uffff\1\60\2\uffff" u"\1\165\1\uffff\1\156\1\uffff\1\156\1\77\4\uffff\1\60\2\uffff\1" u"\154\4\uffff\1\156\1\164\1\60\2\uffff\1\145\1\144\1\77\1\uffff" u"\2\60\3\uffff" ) DFA8_max = DFA.unpack( u"\1\175\12\uffff\1\164\2\157\1\162\1\161\1\165\1\162\1\145\1\146" u"\2\151\1\165\2\162\1\145\1\164\1\162\1\141\1\151\2\172\5\uffff" u"\2\144\1\172\1\143\1\157\1\154\1\162\1\154\1\146\1\141\1\163\1" u"\144\1\165\1\154\1\157\1\156\1\145\1\151\2\172\2\163\1\170\1\156" u"\1\164\1\155\1\172\1\162\1\154\1\151\1\156\2\164\1\141\1\162\1" u"\172\1\165\1\162\1\151\1\164\2\uffff\2\172\1\uffff\1\153\2\154" u"\1\143\1\157\1\146\1\167\1\146\1\145\1\172\1\141\1\163\1\155\1" u"\143\1\141\1\147\2\uffff\1\163\1\145\1\164\2\72\1\172\1\142\1\uffff" u"\1\141\1\156\1\171\1\156\1\151\1\144\1\164\1\157\1\145\1\165\1" u"\172\1\160\1\162\1\151\1\uffff\1\145\1\172\1\154\1\164\1\150\2" u"\uffff\1\147\2\172\1\154\1\162\1\145\3\172\1\uffff\1\154\1\145" u"\1\172\2\164\1\150\1\77\2\172\3\uffff\1\145\1\155\1\164\1\147\1" u"\164\1\165\1\157\1\141\1\166\1\141\1\162\1\uffff\1\145\1\164\1" u"\156\1\172\1\uffff\1\145\1\150\1\172\1\162\2\uffff\1\145\1\172" u"\1\162\3\uffff\1\163\1\172\1\uffff\1\151\1\145\1\164\3\uffff\1" u"\162\1\163\1\172\1\157\1\172\1\163\1\155\1\156\1\145\1\164\1\156" u"\2\172\1\147\1\uffff\2\172\1\uffff\1\157\1\172\1\uffff\1\145\1" u"\77\1\uffff\1\157\1\162\3\172\1\uffff\1\172\1\uffff\1\156\1\uffff" u"\2\172\1\147\3\172\2\uffff\1\172\2\uffff\1\165\1\uffff\1\156\1" u"\uffff\1\156\1\77\4\uffff\1\172\2\uffff\1\154\4\uffff\1\156\1\164" u"\1\172\2\uffff\1\145\1\144\1\77\1\uffff\2\172\3\uffff" ) DFA8_accept = DFA.unpack( u"\1\uffff\1\1\1\2\1\3\1\4\1\5\1\6\1\7\1\10\1\11\1\12\25\uffff\1" u"\100\1\101\1\102\1\103\1\104\50\uffff\1\76\1\77\2\uffff\1\15\20" u"\uffff\1\36\1\37\7\uffff\1\47\16\uffff\1\70\5\uffff\1\13\1\14\11" u"\uffff\1\27\11\uffff\1\43\1\44\1\45\13\uffff\1\64\4\uffff\1\72" u"\4\uffff\1\17\1\20\3\uffff\1\24\1\25\1\26\2\uffff\1\32\3\uffff" u"\1\40\1\41\1\42\16\uffff\1\71\2\uffff\1\75\2\uffff\1\22\2\uffff" u"\1\31\5\uffff\1\52\1\uffff\1\51\1\uffff\1\55\6\uffff\1\65\1\66" u"\1\uffff\1\73\1\74\1\uffff\1\21\1\uffff\1\30\2\uffff\1\35\1\46" u"\1\50\1\53\1\uffff\1\56\1\57\1\uffff\1\61\1\62\1\63\1\67\3\uffff" u"\1\34\1\54\3\uffff\1\33\2\uffff\1\23\1\60\1\16" ) DFA8_special = DFA.unpack( u"\u010b\uffff" ) DFA8_transition = [ DFA.unpack(u"\1\44\5\uffff\1\1\1\2\1\3\1\4\1\5\1\6\1\uffff\1\7\12" u"\43\1\10\1\11\1\uffff\1\12\3\uffff\32\42\4\uffff\1\42\1\uffff\1" u"\13\1\14\1\15\1\16\1\17\1\20\1\21\1\22\1\23\2\42\1\24\1\25\1\26" u"\1\27\1\30\1\42\1\31\1\32\1\33\1\42\1\34\1\35\1\36\1\37\1\42\1" u"\40\1\uffff\1\41"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\45\11\uffff\1\46\5\uffff\1\47"), DFA.unpack(u"\1\50\15\uffff\1\51"), DFA.unpack(u"\1\52\7\uffff\1\53\5\uffff\1\54"), DFA.unpack(u"\1\55\10\uffff\1\56"), DFA.unpack(u"\1\57\1\uffff\1\60\2\uffff\1\61"), DFA.unpack(u"\1\62\20\uffff\1\63\2\uffff\1\64"), DFA.unpack(u"\1\65"), DFA.unpack(u"\1\66"), DFA.unpack(u"\1\67\1\uffff\1\70"), DFA.unpack(u"\1\71\3\uffff\1\72"), DFA.unpack(u"\1\73\7\uffff\1\74"), DFA.unpack(u"\1\75\5\uffff\1\76"), DFA.unpack(u"\1\77"), DFA.unpack(u"\1\100\15\uffff\1\101\2\uffff\1\102"), DFA.unpack(u"\1\103\3\uffff\1\104"), DFA.unpack(u"\1\105\2\uffff\1\106\13\uffff\1\107"), DFA.unpack(u"\1\110\2\uffff\1\111"), DFA.unpack(u"\1\112"), DFA.unpack(u"\1\113\1\114"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\117"), DFA.unpack(u"\1\120"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\122"), DFA.unpack(u"\1\123"), DFA.unpack(u"\1\124"), DFA.unpack(u"\1\125"), DFA.unpack(u"\1\126"), DFA.unpack(u"\1\127"), DFA.unpack(u"\1\130"), DFA.unpack(u"\1\131\11\uffff\1\132"), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134"), DFA.unpack(u"\1\135"), DFA.unpack(u"\1\136"), DFA.unpack(u"\1\137"), DFA.unpack(u"\1\140"), DFA.unpack(u"\1\141"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\144"), DFA.unpack(u"\1\145\4\uffff\1\146"), DFA.unpack(u"\1\147"), DFA.unpack(u"\1\150"), DFA.unpack(u"\1\151"), DFA.unpack(u"\1\152"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\154"), DFA.unpack(u"\1\155\2\uffff\1\156"), DFA.unpack(u"\1\157"), DFA.unpack(u"\1\160\11\uffff\1\161"), DFA.unpack(u"\1\162\11\uffff\1\163\2\uffff\1\164\3\uffff\1\165"), DFA.unpack(u"\1\166"), DFA.unpack(u"\1\167"), DFA.unpack(u"\1\170\20\uffff\1\171"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\173"), DFA.unpack(u"\1\174"), DFA.unpack(u"\1\175"), DFA.unpack(u"\1\176\17\uffff\1\177"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u"\1\u0082"), DFA.unpack(u"\1\u0083"), DFA.unpack(u"\1\u0084"), DFA.unpack(u"\1\u0085"), DFA.unpack(u"\1\u0086"), DFA.unpack(u"\1\u0087"), DFA.unpack(u"\1\u0088"), DFA.unpack(u"\1\u0089"), DFA.unpack(u"\1\u008a"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u008c"), DFA.unpack(u"\1\u008d"), DFA.unpack(u"\1\u008e"), DFA.unpack(u"\1\u008f"), DFA.unpack(u"\1\u0090"), DFA.unpack(u"\1\u0091"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0092"), DFA.unpack(u"\1\u0093"), DFA.unpack(u"\1\u0094"), DFA.unpack(u"\1\u0095"), DFA.unpack(u"\1\u0096"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u0098"), DFA.unpack(u""), DFA.unpack(u"\1\u0099"), DFA.unpack(u"\1\u009a"), DFA.unpack(u"\1\u009b"), DFA.unpack(u"\1\u009c"), DFA.unpack(u"\1\u009d"), DFA.unpack(u"\1\u009e"), DFA.unpack(u"\1\u009f"), DFA.unpack(u"\1\u00a0"), DFA.unpack(u"\1\u00a1"), DFA.unpack(u"\1\u00a2"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00a4"), DFA.unpack(u"\1\u00a5"), DFA.unpack(u"\1\u00a6"), DFA.unpack(u""), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00a9"), DFA.unpack(u"\1\u00aa"), DFA.unpack(u"\1\u00ab"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ac"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\1\u00b0"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u"\1\u00b5"), DFA.unpack(u"\1\u00b6"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00b8"), DFA.unpack(u"\1\u00b9"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\1\u00bb"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00be"), DFA.unpack(u"\1\u00bf"), DFA.unpack(u"\1\u00c0"), DFA.unpack(u"\1\u00c1"), DFA.unpack(u"\1\u00c2"), DFA.unpack(u"\1\u00c3"), DFA.unpack(u"\1\u00c4"), DFA.unpack(u"\1\u00c5"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u"\1\u00c7"), DFA.unpack(u"\1\u00c8"), DFA.unpack(u""), DFA.unpack(u"\1\u00c9"), DFA.unpack(u"\1\u00ca"), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00d0"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00d1"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00d3"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00d4"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u"\1\u00d6"), DFA.unpack(u"\1\u00d7"), DFA.unpack(u"\1\u00d8"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00d9"), DFA.unpack(u"\1\u00da"), DFA.unpack(u"\1\u00db\2\uffff\12\42\7\uffff\32\42\4\uffff\1\42\1" u"\uffff\22\42\1\u00dc\7\42"), DFA.unpack(u"\1\u00de"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00e0"), DFA.unpack(u"\1\u00e1"), DFA.unpack(u"\1\u00e2"), DFA.unpack(u"\1\u00e3"), DFA.unpack(u"\1\u00e4"), DFA.unpack(u"\1\u00e5"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00e8"), DFA.unpack(u""), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u"\1\u00eb"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u"\1\u00ed"), DFA.unpack(u"\1\u00ee"), DFA.unpack(u""), DFA.unpack(u"\1\u00ef"), DFA.unpack(u"\1\u00f0"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u"\1\u00f5"), DFA.unpack(u""), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\1\u00f8"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00fd"), DFA.unpack(u""), DFA.unpack(u"\1\u00fe"), DFA.unpack(u""), DFA.unpack(u"\1\u00ff"), DFA.unpack(u"\1\u0100"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0102"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0103"), DFA.unpack(u"\1\u0104"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0106"), DFA.unpack(u"\1\u0107"), DFA.unpack(u"\1\u0108"), DFA.unpack(u""), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u"\12\42\7\uffff\32\42\4\uffff\1\42\1\uffff\32\42"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #8 class DFA8(DFA): pass def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(chabuildlyLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "montselozanod/ChabuScript", "path": "output/chabuildlyLexer.py", "copies": "1", "size": "77675", "license": "mit", "hash": -8241644204435380000, "line_mean": 25.4831230822, "line_max": 628, "alpha_frac": 0.5037785645, "autogenerated": false, "ratio": 2.7423739584804405, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.8691732084286286, "avg_score": 0.01088408773883113, "num_lines": 2933 }
# $ANTLR 3.5.2 Congress.g 2015-11-02 17:04:43 import sys from antlr3 import * from antlr3.tree import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__53=53 T__54=54 T__55=55 T__56=56 T__57=57 T__58=58 AND=4 ATOM=5 BYTESTRPREFIX=6 BYTES_CHAR_DQ=7 BYTES_CHAR_SQ=8 BYTES_ESC=9 BYTES_TESC=10 COLONMINUS=11 COLUMN_NAME=12 COLUMN_NUMBER=13 COMMA=14 COMMENT=15 DIGIT=16 EQUAL=17 EVENT=18 EXPONENT=19 FLOAT=20 FLOAT_EXP=21 FLOAT_NO_EXP=22 FLOAT_OBJ=23 FRAC_PART=24 HEX_DIGIT=25 ID=26 INT=27 INTEGER_OBJ=28 INT_PART=29 LBRACKET=30 LITERAL=31 LPAREN=32 MODAL=33 NAMED_PARAM=34 NEGATION=35 NOT=36 PROG=37 RBRACKET=38 RPAREN=39 RULE=40 SIGN=41 SLBYTESTRING=42 SLSTRING=43 STRING=44 STRING_ESC=45 STRING_OBJ=46 STRPREFIX=47 STRUCTURED_NAME=48 SYMBOL_OBJ=49 THEORY=50 VARIABLE=51 WS=52 # token names tokenNamesMap = { 0: "<invalid>", 1: "<EOR>", 2: "<DOWN>", 3: "<UP>", -1: "EOF", 53: "T__53", 54: "T__54", 55: "T__55", 56: "T__56", 57: "T__57", 58: "T__58", 4: "AND", 5: "ATOM", 6: "BYTESTRPREFIX", 7: "BYTES_CHAR_DQ", 8: "BYTES_CHAR_SQ", 9: "BYTES_ESC", 10: "BYTES_TESC", 11: "COLONMINUS", 12: "COLUMN_NAME", 13: "COLUMN_NUMBER", 14: "COMMA", 15: "COMMENT", 16: "DIGIT", 17: "EQUAL", 18: "EVENT", 19: "EXPONENT", 20: "FLOAT", 21: "FLOAT_EXP", 22: "FLOAT_NO_EXP", 23: "FLOAT_OBJ", 24: "FRAC_PART", 25: "HEX_DIGIT", 26: "ID", 27: "INT", 28: "INTEGER_OBJ", 29: "INT_PART", 30: "LBRACKET", 31: "LITERAL", 32: "LPAREN", 33: "MODAL", 34: "NAMED_PARAM", 35: "NEGATION", 36: "NOT", 37: "PROG", 38: "RBRACKET", 39: "RPAREN", 40: "RULE", 41: "SIGN", 42: "SLBYTESTRING", 43: "SLSTRING", 44: "STRING", 45: "STRING_ESC", 46: "STRING_OBJ", 47: "STRPREFIX", 48: "STRUCTURED_NAME", 49: "SYMBOL_OBJ", 50: "THEORY", 51: "VARIABLE", 52: "WS" } Token.registerTokenNamesMap(tokenNamesMap) # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "AND", "ATOM", "BYTESTRPREFIX", "BYTES_CHAR_DQ", "BYTES_CHAR_SQ", "BYTES_ESC", "BYTES_TESC", "COLONMINUS", "COLUMN_NAME", "COLUMN_NUMBER", "COMMA", "COMMENT", "DIGIT", "EQUAL", "EVENT", "EXPONENT", "FLOAT", "FLOAT_EXP", "FLOAT_NO_EXP", "FLOAT_OBJ", "FRAC_PART", "HEX_DIGIT", "ID", "INT", "INTEGER_OBJ", "INT_PART", "LBRACKET", "LITERAL", "LPAREN", "MODAL", "NAMED_PARAM", "NEGATION", "NOT", "PROG", "RBRACKET", "RPAREN", "RULE", "SIGN", "SLBYTESTRING", "SLSTRING", "STRING", "STRING_ESC", "STRING_OBJ", "STRPREFIX", "STRUCTURED_NAME", "SYMBOL_OBJ", "THEORY", "VARIABLE", "WS", "'.'", "':'", "';'", "'delete'", "'execute'", "'insert'" ] class CongressParser(Parser): grammarFileName = "Congress.g" api_version = 1 tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super().__init__(input, state, *args, **kwargs) self.dfa5 = self.DFA5( self, 5, eot = self.DFA5_eot, eof = self.DFA5_eof, min = self.DFA5_min, max = self.DFA5_max, accept = self.DFA5_accept, special = self.DFA5_special, transition = self.DFA5_transition ) self.delegates = [] self._adaptor = None self.adaptor = CommonTreeAdaptor() def getTreeAdaptor(self): return self._adaptor def setTreeAdaptor(self, adaptor): self._adaptor = adaptor adaptor = property(getTreeAdaptor, setTreeAdaptor) class prog_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "prog" # Congress.g:58:1: prog : ( ( statement )+ EOF -> ^( THEORY ( statement )+ ) | EOF ); def prog(self, ): retval = self.prog_return() retval.start = self.input.LT(1) root_0 = None EOF2 = None EOF3 = None statement1 = None EOF2_tree = None EOF3_tree = None stream_EOF = RewriteRuleTokenStream(self._adaptor, "token EOF") stream_statement = RewriteRuleSubtreeStream(self._adaptor, "rule statement") try: try: # Congress.g:59:5: ( ( statement )+ EOF -> ^( THEORY ( statement )+ ) | EOF ) alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 in {COMMENT, ID, NEGATION, 56, 57, 58}) : alt2 = 1 elif (LA2_0 == EOF) : alt2 = 2 else: nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # Congress.g:59:7: ( statement )+ EOF pass # Congress.g:59:7: ( statement )+ cnt1 = 0 while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 in {COMMENT, ID, NEGATION, 56, 57, 58}) : alt1 = 1 if alt1 == 1: # Congress.g:59:7: statement pass self._state.following.append(self.FOLLOW_statement_in_prog265) statement1 = self.statement() self._state.following.pop() stream_statement.add(statement1.tree) else: if cnt1 >= 1: break #loop1 eee = EarlyExitException(1, self.input) raise eee cnt1 += 1 EOF2 = self.match(self.input, EOF, self.FOLLOW_EOF_in_prog268) stream_EOF.add(EOF2) # AST Rewrite # elements: statement # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 59:22: -> ^( THEORY ( statement )+ ) # Congress.g:59:25: ^( THEORY ( statement )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(THEORY, "THEORY") , root_1) # Congress.g:59:34: ( statement )+ if not (stream_statement.hasNext()): raise RewriteEarlyExitException() while stream_statement.hasNext(): self._adaptor.addChild(root_1, stream_statement.nextTree()) stream_statement.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt2 == 2: # Congress.g:60:7: EOF pass root_0 = self._adaptor.nil() EOF3 = self.match(self.input, EOF, self.FOLLOW_EOF_in_prog285) EOF3_tree = self._adaptor.createWithPayload(EOF3) self._adaptor.addChild(root_0, EOF3_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "prog" class statement_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "statement" # Congress.g:65:1: statement : ( formula ( formula_terminator )? -> formula | COMMENT ); def statement(self, ): retval = self.statement_return() retval.start = self.input.LT(1) root_0 = None COMMENT6 = None formula4 = None formula_terminator5 = None COMMENT6_tree = None stream_formula_terminator = RewriteRuleSubtreeStream(self._adaptor, "rule formula_terminator") stream_formula = RewriteRuleSubtreeStream(self._adaptor, "rule formula") try: try: # Congress.g:66:5: ( formula ( formula_terminator )? -> formula | COMMENT ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 in {ID, NEGATION, 56, 57, 58}) : alt4 = 1 elif (LA4_0 == COMMENT) : alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # Congress.g:66:7: formula ( formula_terminator )? pass self._state.following.append(self.FOLLOW_formula_in_statement304) formula4 = self.formula() self._state.following.pop() stream_formula.add(formula4.tree) # Congress.g:66:15: ( formula_terminator )? alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 in {53, 55}) : alt3 = 1 if alt3 == 1: # Congress.g:66:15: formula_terminator pass self._state.following.append(self.FOLLOW_formula_terminator_in_statement306) formula_terminator5 = self.formula_terminator() self._state.following.pop() stream_formula_terminator.add(formula_terminator5.tree) # AST Rewrite # elements: formula # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 66:35: -> formula self._adaptor.addChild(root_0, stream_formula.nextTree()) retval.tree = root_0 elif alt4 == 2: # Congress.g:67:7: COMMENT pass root_0 = self._adaptor.nil() COMMENT6 = self.match(self.input, COMMENT, self.FOLLOW_COMMENT_in_statement319) COMMENT6_tree = self._adaptor.createWithPayload(COMMENT6) self._adaptor.addChild(root_0, COMMENT6_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "statement" class formula_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "formula" # Congress.g:70:1: formula : ( rule | fact | event ); def formula(self, ): retval = self.formula_return() retval.start = self.input.LT(1) root_0 = None rule7 = None fact8 = None event9 = None try: try: # Congress.g:71:5: ( rule | fact | event ) alt5 = 3 alt5 = self.dfa5.predict(self.input) if alt5 == 1: # Congress.g:71:7: rule pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_rule_in_formula336) rule7 = self.rule() self._state.following.pop() self._adaptor.addChild(root_0, rule7.tree) elif alt5 == 2: # Congress.g:72:7: fact pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_fact_in_formula344) fact8 = self.fact() self._state.following.pop() self._adaptor.addChild(root_0, fact8.tree) elif alt5 == 3: # Congress.g:73:7: event pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_event_in_formula352) event9 = self.event() self._state.following.pop() self._adaptor.addChild(root_0, event9.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "formula" class event_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "event" # Congress.g:86:1: event : event_op LBRACKET rule ( formula_terminator STRING )? RBRACKET -> ^( EVENT event_op rule ( STRING )? ) ; def event(self, ): retval = self.event_return() retval.start = self.input.LT(1) root_0 = None LBRACKET11 = None STRING14 = None RBRACKET15 = None event_op10 = None rule12 = None formula_terminator13 = None LBRACKET11_tree = None STRING14_tree = None RBRACKET15_tree = None stream_LBRACKET = RewriteRuleTokenStream(self._adaptor, "token LBRACKET") stream_RBRACKET = RewriteRuleTokenStream(self._adaptor, "token RBRACKET") stream_STRING = RewriteRuleTokenStream(self._adaptor, "token STRING") stream_formula_terminator = RewriteRuleSubtreeStream(self._adaptor, "rule formula_terminator") stream_rule = RewriteRuleSubtreeStream(self._adaptor, "rule rule") stream_event_op = RewriteRuleSubtreeStream(self._adaptor, "rule event_op") try: try: # Congress.g:87:5: ( event_op LBRACKET rule ( formula_terminator STRING )? RBRACKET -> ^( EVENT event_op rule ( STRING )? ) ) # Congress.g:87:7: event_op LBRACKET rule ( formula_terminator STRING )? RBRACKET pass self._state.following.append(self.FOLLOW_event_op_in_event379) event_op10 = self.event_op() self._state.following.pop() stream_event_op.add(event_op10.tree) LBRACKET11 = self.match(self.input, LBRACKET, self.FOLLOW_LBRACKET_in_event381) stream_LBRACKET.add(LBRACKET11) self._state.following.append(self.FOLLOW_rule_in_event383) rule12 = self.rule() self._state.following.pop() stream_rule.add(rule12.tree) # Congress.g:87:30: ( formula_terminator STRING )? alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 in {53, 55}) : alt6 = 1 if alt6 == 1: # Congress.g:87:31: formula_terminator STRING pass self._state.following.append(self.FOLLOW_formula_terminator_in_event386) formula_terminator13 = self.formula_terminator() self._state.following.pop() stream_formula_terminator.add(formula_terminator13.tree) STRING14 = self.match(self.input, STRING, self.FOLLOW_STRING_in_event388) stream_STRING.add(STRING14) RBRACKET15 = self.match(self.input, RBRACKET, self.FOLLOW_RBRACKET_in_event392) stream_RBRACKET.add(RBRACKET15) # AST Rewrite # elements: STRING, rule, event_op # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 87:68: -> ^( EVENT event_op rule ( STRING )? ) # Congress.g:87:71: ^( EVENT event_op rule ( STRING )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(EVENT, "EVENT") , root_1) self._adaptor.addChild(root_1, stream_event_op.nextTree()) self._adaptor.addChild(root_1, stream_rule.nextTree()) # Congress.g:87:93: ( STRING )? if stream_STRING.hasNext(): self._adaptor.addChild(root_1, stream_STRING.nextNode() ) stream_STRING.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "event" class event_op_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "event_op" # Congress.g:90:1: event_op : ( 'insert' | 'delete' ); def event_op(self, ): retval = self.event_op_return() retval.start = self.input.LT(1) root_0 = None set16 = None set16_tree = None try: try: # Congress.g:91:5: ( 'insert' | 'delete' ) # Congress.g: pass root_0 = self._adaptor.nil() set16 = self.input.LT(1) if self.input.LA(1) in {56, 58}: self.input.consume() self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set16)) self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "event_op" class formula_terminator_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "formula_terminator" # Congress.g:95:1: formula_terminator : ( ';' | '.' ); def formula_terminator(self, ): retval = self.formula_terminator_return() retval.start = self.input.LT(1) root_0 = None set17 = None set17_tree = None try: try: # Congress.g:96:5: ( ';' | '.' ) # Congress.g: pass root_0 = self._adaptor.nil() set17 = self.input.LT(1) if self.input.LA(1) in {53, 55}: self.input.consume() self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set17)) self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "formula_terminator" class rule_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "rule" # Congress.g:100:1: rule : literal_list COLONMINUS literal_list -> ^( RULE literal_list literal_list ) ; def rule(self, ): retval = self.rule_return() retval.start = self.input.LT(1) root_0 = None COLONMINUS19 = None literal_list18 = None literal_list20 = None COLONMINUS19_tree = None stream_COLONMINUS = RewriteRuleTokenStream(self._adaptor, "token COLONMINUS") stream_literal_list = RewriteRuleSubtreeStream(self._adaptor, "rule literal_list") try: try: # Congress.g:101:5: ( literal_list COLONMINUS literal_list -> ^( RULE literal_list literal_list ) ) # Congress.g:101:7: literal_list COLONMINUS literal_list pass self._state.following.append(self.FOLLOW_literal_list_in_rule472) literal_list18 = self.literal_list() self._state.following.pop() stream_literal_list.add(literal_list18.tree) COLONMINUS19 = self.match(self.input, COLONMINUS, self.FOLLOW_COLONMINUS_in_rule474) stream_COLONMINUS.add(COLONMINUS19) self._state.following.append(self.FOLLOW_literal_list_in_rule476) literal_list20 = self.literal_list() self._state.following.pop() stream_literal_list.add(literal_list20.tree) # AST Rewrite # elements: literal_list, literal_list # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 101:44: -> ^( RULE literal_list literal_list ) # Congress.g:101:47: ^( RULE literal_list literal_list ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(RULE, "RULE") , root_1) self._adaptor.addChild(root_1, stream_literal_list.nextTree()) self._adaptor.addChild(root_1, stream_literal_list.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "rule" class literal_list_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "literal_list" # Congress.g:104:1: literal_list : literal ( COMMA literal )* -> ^( AND ( literal )+ ) ; def literal_list(self, ): retval = self.literal_list_return() retval.start = self.input.LT(1) root_0 = None COMMA22 = None literal21 = None literal23 = None COMMA22_tree = None stream_COMMA = RewriteRuleTokenStream(self._adaptor, "token COMMA") stream_literal = RewriteRuleSubtreeStream(self._adaptor, "rule literal") try: try: # Congress.g:105:5: ( literal ( COMMA literal )* -> ^( AND ( literal )+ ) ) # Congress.g:105:7: literal ( COMMA literal )* pass self._state.following.append(self.FOLLOW_literal_in_literal_list503) literal21 = self.literal() self._state.following.pop() stream_literal.add(literal21.tree) # Congress.g:105:15: ( COMMA literal )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == COMMA) : alt7 = 1 if alt7 == 1: # Congress.g:105:16: COMMA literal pass COMMA22 = self.match(self.input, COMMA, self.FOLLOW_COMMA_in_literal_list506) stream_COMMA.add(COMMA22) self._state.following.append(self.FOLLOW_literal_in_literal_list508) literal23 = self.literal() self._state.following.pop() stream_literal.add(literal23.tree) else: break #loop7 # AST Rewrite # elements: literal # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 105:32: -> ^( AND ( literal )+ ) # Congress.g:105:35: ^( AND ( literal )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(AND, "AND") , root_1) # Congress.g:105:41: ( literal )+ if not (stream_literal.hasNext()): raise RewriteEarlyExitException() while stream_literal.hasNext(): self._adaptor.addChild(root_1, stream_literal.nextTree()) stream_literal.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "literal_list" class literal_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "literal" # Congress.g:108:1: literal : ( fact -> fact | NEGATION fact -> ^( NOT fact ) ); def literal(self, ): retval = self.literal_return() retval.start = self.input.LT(1) root_0 = None NEGATION25 = None fact24 = None fact26 = None NEGATION25_tree = None stream_NEGATION = RewriteRuleTokenStream(self._adaptor, "token NEGATION") stream_fact = RewriteRuleSubtreeStream(self._adaptor, "rule fact") try: try: # Congress.g:109:5: ( fact -> fact | NEGATION fact -> ^( NOT fact ) ) alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 in {ID, 56, 57, 58}) : alt8 = 1 elif (LA8_0 == NEGATION) : alt8 = 2 else: nvae = NoViableAltException("", 8, 0, self.input) raise nvae if alt8 == 1: # Congress.g:109:7: fact pass self._state.following.append(self.FOLLOW_fact_in_literal536) fact24 = self.fact() self._state.following.pop() stream_fact.add(fact24.tree) # AST Rewrite # elements: fact # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 109:23: -> fact self._adaptor.addChild(root_0, stream_fact.nextTree()) retval.tree = root_0 elif alt8 == 2: # Congress.g:110:7: NEGATION fact pass NEGATION25 = self.match(self.input, NEGATION, self.FOLLOW_NEGATION_in_literal559) stream_NEGATION.add(NEGATION25) self._state.following.append(self.FOLLOW_fact_in_literal561) fact26 = self.fact() self._state.following.pop() stream_fact.add(fact26.tree) # AST Rewrite # elements: fact # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 110:23: -> ^( NOT fact ) # Congress.g:110:26: ^( NOT fact ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(NOT, "NOT") , root_1) self._adaptor.addChild(root_1, stream_fact.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "literal" class fact_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "fact" # Congress.g:115:1: fact : ( atom | modal_op LBRACKET atom RBRACKET -> ^( MODAL modal_op atom ) ); def fact(self, ): retval = self.fact_return() retval.start = self.input.LT(1) root_0 = None LBRACKET29 = None RBRACKET31 = None atom27 = None modal_op28 = None atom30 = None LBRACKET29_tree = None RBRACKET31_tree = None stream_LBRACKET = RewriteRuleTokenStream(self._adaptor, "token LBRACKET") stream_RBRACKET = RewriteRuleTokenStream(self._adaptor, "token RBRACKET") stream_atom = RewriteRuleSubtreeStream(self._adaptor, "rule atom") stream_modal_op = RewriteRuleSubtreeStream(self._adaptor, "rule modal_op") try: try: # Congress.g:116:5: ( atom | modal_op LBRACKET atom RBRACKET -> ^( MODAL modal_op atom ) ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == ID) : alt9 = 1 elif (LA9_0 in {56, 57, 58}) : alt9 = 2 else: nvae = NoViableAltException("", 9, 0, self.input) raise nvae if alt9 == 1: # Congress.g:116:7: atom pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_atom_in_fact590) atom27 = self.atom() self._state.following.pop() self._adaptor.addChild(root_0, atom27.tree) elif alt9 == 2: # Congress.g:117:7: modal_op LBRACKET atom RBRACKET pass self._state.following.append(self.FOLLOW_modal_op_in_fact598) modal_op28 = self.modal_op() self._state.following.pop() stream_modal_op.add(modal_op28.tree) LBRACKET29 = self.match(self.input, LBRACKET, self.FOLLOW_LBRACKET_in_fact600) stream_LBRACKET.add(LBRACKET29) self._state.following.append(self.FOLLOW_atom_in_fact602) atom30 = self.atom() self._state.following.pop() stream_atom.add(atom30.tree) RBRACKET31 = self.match(self.input, RBRACKET, self.FOLLOW_RBRACKET_in_fact604) stream_RBRACKET.add(RBRACKET31) # AST Rewrite # elements: atom, modal_op # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 117:39: -> ^( MODAL modal_op atom ) # Congress.g:117:42: ^( MODAL modal_op atom ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(MODAL, "MODAL") , root_1) self._adaptor.addChild(root_1, stream_modal_op.nextTree()) self._adaptor.addChild(root_1, stream_atom.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "fact" class modal_op_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "modal_op" # Congress.g:120:1: modal_op : ( 'execute' | 'insert' | 'delete' ); def modal_op(self, ): retval = self.modal_op_return() retval.start = self.input.LT(1) root_0 = None set32 = None set32_tree = None try: try: # Congress.g:121:5: ( 'execute' | 'insert' | 'delete' ) # Congress.g: pass root_0 = self._adaptor.nil() set32 = self.input.LT(1) if self.input.LA(1) in {56, 57, 58}: self.input.consume() self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set32)) self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "modal_op" class atom_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "atom" # Congress.g:126:1: atom : relation_constant ( LPAREN ( parameter_list )? RPAREN )? -> ^( ATOM relation_constant ( parameter_list )? ) ; def atom(self, ): retval = self.atom_return() retval.start = self.input.LT(1) root_0 = None LPAREN34 = None RPAREN36 = None relation_constant33 = None parameter_list35 = None LPAREN34_tree = None RPAREN36_tree = None stream_RPAREN = RewriteRuleTokenStream(self._adaptor, "token RPAREN") stream_LPAREN = RewriteRuleTokenStream(self._adaptor, "token LPAREN") stream_relation_constant = RewriteRuleSubtreeStream(self._adaptor, "rule relation_constant") stream_parameter_list = RewriteRuleSubtreeStream(self._adaptor, "rule parameter_list") try: try: # Congress.g:127:5: ( relation_constant ( LPAREN ( parameter_list )? RPAREN )? -> ^( ATOM relation_constant ( parameter_list )? ) ) # Congress.g:127:7: relation_constant ( LPAREN ( parameter_list )? RPAREN )? pass self._state.following.append(self.FOLLOW_relation_constant_in_atom664) relation_constant33 = self.relation_constant() self._state.following.pop() stream_relation_constant.add(relation_constant33.tree) # Congress.g:127:25: ( LPAREN ( parameter_list )? RPAREN )? alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == LPAREN) : alt11 = 1 if alt11 == 1: # Congress.g:127:26: LPAREN ( parameter_list )? RPAREN pass LPAREN34 = self.match(self.input, LPAREN, self.FOLLOW_LPAREN_in_atom667) stream_LPAREN.add(LPAREN34) # Congress.g:127:33: ( parameter_list )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 in {FLOAT, ID, INT, STRING}) : alt10 = 1 if alt10 == 1: # Congress.g:127:33: parameter_list pass self._state.following.append(self.FOLLOW_parameter_list_in_atom669) parameter_list35 = self.parameter_list() self._state.following.pop() stream_parameter_list.add(parameter_list35.tree) RPAREN36 = self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_atom672) stream_RPAREN.add(RPAREN36) # AST Rewrite # elements: parameter_list, relation_constant # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 127:58: -> ^( ATOM relation_constant ( parameter_list )? ) # Congress.g:127:61: ^( ATOM relation_constant ( parameter_list )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(ATOM, "ATOM") , root_1) self._adaptor.addChild(root_1, stream_relation_constant.nextTree()) # Congress.g:127:86: ( parameter_list )? if stream_parameter_list.hasNext(): self._adaptor.addChild(root_1, stream_parameter_list.nextTree()) stream_parameter_list.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "atom" class parameter_list_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "parameter_list" # Congress.g:130:1: parameter_list : parameter ( COMMA parameter )* -> ( parameter )+ ; def parameter_list(self, ): retval = self.parameter_list_return() retval.start = self.input.LT(1) root_0 = None COMMA38 = None parameter37 = None parameter39 = None COMMA38_tree = None stream_COMMA = RewriteRuleTokenStream(self._adaptor, "token COMMA") stream_parameter = RewriteRuleSubtreeStream(self._adaptor, "rule parameter") try: try: # Congress.g:131:5: ( parameter ( COMMA parameter )* -> ( parameter )+ ) # Congress.g:131:7: parameter ( COMMA parameter )* pass self._state.following.append(self.FOLLOW_parameter_in_parameter_list702) parameter37 = self.parameter() self._state.following.pop() stream_parameter.add(parameter37.tree) # Congress.g:131:17: ( COMMA parameter )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == COMMA) : alt12 = 1 if alt12 == 1: # Congress.g:131:18: COMMA parameter pass COMMA38 = self.match(self.input, COMMA, self.FOLLOW_COMMA_in_parameter_list705) stream_COMMA.add(COMMA38) self._state.following.append(self.FOLLOW_parameter_in_parameter_list707) parameter39 = self.parameter() self._state.following.pop() stream_parameter.add(parameter39.tree) else: break #loop12 # AST Rewrite # elements: parameter # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 131:36: -> ( parameter )+ # Congress.g:131:39: ( parameter )+ if not (stream_parameter.hasNext()): raise RewriteEarlyExitException() while stream_parameter.hasNext(): self._adaptor.addChild(root_0, stream_parameter.nextTree()) stream_parameter.reset() retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "parameter_list" class parameter_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "parameter" # Congress.g:134:1: parameter : ( term -> term | column_ref EQUAL term -> ^( NAMED_PARAM column_ref term ) ); def parameter(self, ): retval = self.parameter_return() retval.start = self.input.LT(1) root_0 = None EQUAL42 = None term40 = None column_ref41 = None term43 = None EQUAL42_tree = None stream_EQUAL = RewriteRuleTokenStream(self._adaptor, "token EQUAL") stream_term = RewriteRuleSubtreeStream(self._adaptor, "rule term") stream_column_ref = RewriteRuleSubtreeStream(self._adaptor, "rule column_ref") try: try: # Congress.g:135:5: ( term -> term | column_ref EQUAL term -> ^( NAMED_PARAM column_ref term ) ) alt13 = 2 LA13 = self.input.LA(1) if LA13 in {INT}: LA13_1 = self.input.LA(2) if (LA13_1 in {COMMA, RPAREN}) : alt13 = 1 elif (LA13_1 == EQUAL) : alt13 = 2 else: nvae = NoViableAltException("", 13, 1, self.input) raise nvae elif LA13 in {FLOAT, STRING}: alt13 = 1 elif LA13 in {ID}: LA13_3 = self.input.LA(2) if (LA13_3 in {COMMA, RPAREN}) : alt13 = 1 elif (LA13_3 == EQUAL) : alt13 = 2 else: nvae = NoViableAltException("", 13, 3, self.input) raise nvae else: nvae = NoViableAltException("", 13, 0, self.input) raise nvae if alt13 == 1: # Congress.g:135:7: term pass self._state.following.append(self.FOLLOW_term_in_parameter731) term40 = self.term() self._state.following.pop() stream_term.add(term40.tree) # AST Rewrite # elements: term # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 135:12: -> term self._adaptor.addChild(root_0, stream_term.nextTree()) retval.tree = root_0 elif alt13 == 2: # Congress.g:136:7: column_ref EQUAL term pass self._state.following.append(self.FOLLOW_column_ref_in_parameter743) column_ref41 = self.column_ref() self._state.following.pop() stream_column_ref.add(column_ref41.tree) EQUAL42 = self.match(self.input, EQUAL, self.FOLLOW_EQUAL_in_parameter745) stream_EQUAL.add(EQUAL42) self._state.following.append(self.FOLLOW_term_in_parameter747) term43 = self.term() self._state.following.pop() stream_term.add(term43.tree) # AST Rewrite # elements: column_ref, term # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 136:29: -> ^( NAMED_PARAM column_ref term ) # Congress.g:136:32: ^( NAMED_PARAM column_ref term ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(NAMED_PARAM, "NAMED_PARAM") , root_1) self._adaptor.addChild(root_1, stream_column_ref.nextTree()) self._adaptor.addChild(root_1, stream_term.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "parameter" class column_ref_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "column_ref" # Congress.g:139:1: column_ref : ( ID -> ^( COLUMN_NAME ID ) | INT -> ^( COLUMN_NUMBER INT ) ); def column_ref(self, ): retval = self.column_ref_return() retval.start = self.input.LT(1) root_0 = None ID44 = None INT45 = None ID44_tree = None INT45_tree = None stream_INT = RewriteRuleTokenStream(self._adaptor, "token INT") stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") try: try: # Congress.g:140:5: ( ID -> ^( COLUMN_NAME ID ) | INT -> ^( COLUMN_NUMBER INT ) ) alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == ID) : alt14 = 1 elif (LA14_0 == INT) : alt14 = 2 else: nvae = NoViableAltException("", 14, 0, self.input) raise nvae if alt14 == 1: # Congress.g:140:7: ID pass ID44 = self.match(self.input, ID, self.FOLLOW_ID_in_column_ref774) stream_ID.add(ID44) # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 140:12: -> ^( COLUMN_NAME ID ) # Congress.g:140:16: ^( COLUMN_NAME ID ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(COLUMN_NAME, "COLUMN_NAME") , root_1) self._adaptor.addChild(root_1, stream_ID.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt14 == 2: # Congress.g:141:7: INT pass INT45 = self.match(self.input, INT, self.FOLLOW_INT_in_column_ref793) stream_INT.add(INT45) # AST Rewrite # elements: INT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 141:12: -> ^( COLUMN_NUMBER INT ) # Congress.g:141:16: ^( COLUMN_NUMBER INT ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(COLUMN_NUMBER, "COLUMN_NUMBER") , root_1) self._adaptor.addChild(root_1, stream_INT.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "column_ref" class term_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "term" # Congress.g:144:1: term : ( object_constant | variable ); def term(self, ): retval = self.term_return() retval.start = self.input.LT(1) root_0 = None object_constant46 = None variable47 = None try: try: # Congress.g:145:5: ( object_constant | variable ) alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 in {FLOAT, INT, STRING}) : alt15 = 1 elif (LA15_0 == ID) : alt15 = 2 else: nvae = NoViableAltException("", 15, 0, self.input) raise nvae if alt15 == 1: # Congress.g:145:7: object_constant pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_object_constant_in_term820) object_constant46 = self.object_constant() self._state.following.pop() self._adaptor.addChild(root_0, object_constant46.tree) elif alt15 == 2: # Congress.g:146:7: variable pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_variable_in_term828) variable47 = self.variable() self._state.following.pop() self._adaptor.addChild(root_0, variable47.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "term" class object_constant_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "object_constant" # Congress.g:149:1: object_constant : ( INT -> ^( INTEGER_OBJ INT ) | FLOAT -> ^( FLOAT_OBJ FLOAT ) | STRING -> ^( STRING_OBJ STRING ) ); def object_constant(self, ): retval = self.object_constant_return() retval.start = self.input.LT(1) root_0 = None INT48 = None FLOAT49 = None STRING50 = None INT48_tree = None FLOAT49_tree = None STRING50_tree = None stream_FLOAT = RewriteRuleTokenStream(self._adaptor, "token FLOAT") stream_INT = RewriteRuleTokenStream(self._adaptor, "token INT") stream_STRING = RewriteRuleTokenStream(self._adaptor, "token STRING") try: try: # Congress.g:150:5: ( INT -> ^( INTEGER_OBJ INT ) | FLOAT -> ^( FLOAT_OBJ FLOAT ) | STRING -> ^( STRING_OBJ STRING ) ) alt16 = 3 LA16 = self.input.LA(1) if LA16 in {INT}: alt16 = 1 elif LA16 in {FLOAT}: alt16 = 2 elif LA16 in {STRING}: alt16 = 3 else: nvae = NoViableAltException("", 16, 0, self.input) raise nvae if alt16 == 1: # Congress.g:150:7: INT pass INT48 = self.match(self.input, INT, self.FOLLOW_INT_in_object_constant845) stream_INT.add(INT48) # AST Rewrite # elements: INT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 150:16: -> ^( INTEGER_OBJ INT ) # Congress.g:150:19: ^( INTEGER_OBJ INT ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(INTEGER_OBJ, "INTEGER_OBJ") , root_1) self._adaptor.addChild(root_1, stream_INT.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt16 == 2: # Congress.g:151:7: FLOAT pass FLOAT49 = self.match(self.input, FLOAT, self.FOLLOW_FLOAT_in_object_constant866) stream_FLOAT.add(FLOAT49) # AST Rewrite # elements: FLOAT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 151:16: -> ^( FLOAT_OBJ FLOAT ) # Congress.g:151:19: ^( FLOAT_OBJ FLOAT ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(FLOAT_OBJ, "FLOAT_OBJ") , root_1) self._adaptor.addChild(root_1, stream_FLOAT.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt16 == 3: # Congress.g:152:7: STRING pass STRING50 = self.match(self.input, STRING, self.FOLLOW_STRING_in_object_constant885) stream_STRING.add(STRING50) # AST Rewrite # elements: STRING # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 152:16: -> ^( STRING_OBJ STRING ) # Congress.g:152:19: ^( STRING_OBJ STRING ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(STRING_OBJ, "STRING_OBJ") , root_1) self._adaptor.addChild(root_1, stream_STRING.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "object_constant" class variable_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "variable" # Congress.g:155:1: variable : ID -> ^( VARIABLE ID ) ; def variable(self, ): retval = self.variable_return() retval.start = self.input.LT(1) root_0 = None ID51 = None ID51_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") try: try: # Congress.g:156:5: ( ID -> ^( VARIABLE ID ) ) # Congress.g:156:7: ID pass ID51 = self.match(self.input, ID, self.FOLLOW_ID_in_variable912) stream_ID.add(ID51) # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 156:10: -> ^( VARIABLE ID ) # Congress.g:156:13: ^( VARIABLE ID ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(VARIABLE, "VARIABLE") , root_1) self._adaptor.addChild(root_1, stream_ID.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "variable" class relation_constant_return(ParserRuleReturnScope): def __init__(self): super().__init__() self.tree = None # $ANTLR start "relation_constant" # Congress.g:159:1: relation_constant : ID ( ':' ID )* ( SIGN )? -> ^( STRUCTURED_NAME ( ID )+ ( SIGN )? ) ; def relation_constant(self, ): retval = self.relation_constant_return() retval.start = self.input.LT(1) root_0 = None ID52 = None char_literal53 = None ID54 = None SIGN55 = None ID52_tree = None char_literal53_tree = None ID54_tree = None SIGN55_tree = None stream_SIGN = RewriteRuleTokenStream(self._adaptor, "token SIGN") stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_54 = RewriteRuleTokenStream(self._adaptor, "token 54") try: try: # Congress.g:160:5: ( ID ( ':' ID )* ( SIGN )? -> ^( STRUCTURED_NAME ( ID )+ ( SIGN )? ) ) # Congress.g:160:7: ID ( ':' ID )* ( SIGN )? pass ID52 = self.match(self.input, ID, self.FOLLOW_ID_in_relation_constant937) stream_ID.add(ID52) # Congress.g:160:10: ( ':' ID )* while True: #loop17 alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == 54) : alt17 = 1 if alt17 == 1: # Congress.g:160:11: ':' ID pass char_literal53 = self.match(self.input, 54, self.FOLLOW_54_in_relation_constant940) stream_54.add(char_literal53) ID54 = self.match(self.input, ID, self.FOLLOW_ID_in_relation_constant942) stream_ID.add(ID54) else: break #loop17 # Congress.g:160:20: ( SIGN )? alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == SIGN) : alt18 = 1 if alt18 == 1: # Congress.g:160:20: SIGN pass SIGN55 = self.match(self.input, SIGN, self.FOLLOW_SIGN_in_relation_constant946) stream_SIGN.add(SIGN55) # AST Rewrite # elements: ID, SIGN # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 160:26: -> ^( STRUCTURED_NAME ( ID )+ ( SIGN )? ) # Congress.g:160:29: ^( STRUCTURED_NAME ( ID )+ ( SIGN )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(STRUCTURED_NAME, "STRUCTURED_NAME") , root_1) # Congress.g:160:47: ( ID )+ if not (stream_ID.hasNext()): raise RewriteEarlyExitException() while stream_ID.hasNext(): self._adaptor.addChild(root_1, stream_ID.nextNode() ) stream_ID.reset() # Congress.g:160:51: ( SIGN )? if stream_SIGN.hasNext(): self._adaptor.addChild(root_1, stream_SIGN.nextNode() ) stream_SIGN.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException as re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "relation_constant" # lookup tables for DFA #5 DFA5_eot = DFA.unpack( "\124\uffff" ) DFA5_eof = DFA.unpack( "\1\uffff\1\10\4\uffff\1\10\4\uffff\1\10\4\uffff\1\10\10\uffff\1" "\10\72\uffff" ) DFA5_min = DFA.unpack( "\1\32\1\13\1\36\1\uffff\1\36\1\32\1\13\1\24\1\uffff\2\32\1\13\4" "\16\2\13\1\uffff\1\40\2\24\1\32\1\13\1\24\1\13\1\32\1\40\1\24\10" "\16\1\13\4\16\1\13\1\40\4\16\1\46\5\24\24\16\2\24\10\16" ) DFA5_max = DFA.unpack( "\2\72\1\36\1\uffff\1\36\1\32\1\72\1\54\1\uffff\1\72\1\32\1\72\4" "\47\1\72\1\66\1\uffff\1\66\2\54\1\32\1\46\1\54\1\72\1\32\1\46\1" "\54\10\47\1\66\4\47\1\46\1\66\4\47\1\46\5\54\24\47\2\54\10\47" ) DFA5_accept = DFA.unpack( "\3\uffff\1\1\4\uffff\1\2\11\uffff\1\3\101\uffff" ) DFA5_special = DFA.unpack( "\124\uffff" ) DFA5_transition = [ DFA.unpack("\1\1\10\uffff\1\3\24\uffff\1\2\1\4\1\2"), DFA.unpack("\1\3\2\uffff\1\3\1\10\12\uffff\1\10\5\uffff\1\7\2\uffff" "\1\10\5\uffff\1\6\13\uffff\1\10\1\5\4\10"), DFA.unpack("\1\11"), DFA.unpack(""), DFA.unpack("\1\12"), DFA.unpack("\1\13"), DFA.unpack("\1\3\2\uffff\1\3\1\10\12\uffff\1\10\5\uffff\1\7\2\uffff" "\1\10\21\uffff\1\10\1\uffff\4\10"), DFA.unpack("\1\15\5\uffff\1\17\1\14\13\uffff\1\20\4\uffff\1\16"), DFA.unpack(""), DFA.unpack("\1\21\10\uffff\1\22\24\uffff\3\22"), DFA.unpack("\1\23"), DFA.unpack("\1\3\2\uffff\1\3\1\10\12\uffff\1\10\5\uffff\1\7\2\uffff" "\1\10\5\uffff\1\6\13\uffff\1\10\1\5\4\10"), DFA.unpack("\1\24\2\uffff\1\25\25\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\2\uffff\1\25\25\uffff\1\20"), DFA.unpack("\1\3\2\uffff\1\3\1\10\12\uffff\1\10\10\uffff\1\10\21" "\uffff\1\10\1\uffff\4\10"), DFA.unpack("\1\22\2\uffff\1\22\21\uffff\1\30\5\uffff\1\31\2\uffff" "\1\27\14\uffff\1\26"), DFA.unpack(""), DFA.unpack("\1\34\5\uffff\1\31\2\uffff\1\33\14\uffff\1\32"), DFA.unpack("\1\36\5\uffff\1\40\1\35\20\uffff\1\37"), DFA.unpack("\1\42\5\uffff\1\44\1\41\20\uffff\1\43"), DFA.unpack("\1\45"), DFA.unpack("\1\22\2\uffff\1\22\21\uffff\1\30\5\uffff\1\31"), DFA.unpack("\1\47\5\uffff\1\51\1\46\13\uffff\1\52\4\uffff\1\50"), DFA.unpack("\1\3\2\uffff\1\3\1\10\12\uffff\1\10\10\uffff\1\10\21" "\uffff\1\10\1\uffff\4\10"), DFA.unpack("\1\53"), DFA.unpack("\1\34\5\uffff\1\31"), DFA.unpack("\1\55\5\uffff\1\57\1\54\13\uffff\1\60\4\uffff\1\56"), DFA.unpack("\1\24\2\uffff\1\61\25\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\2\uffff\1\61\25\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\22\2\uffff\1\22\21\uffff\1\30\5\uffff\1\31\2\uffff" "\1\27\14\uffff\1\26"), DFA.unpack("\1\62\2\uffff\1\63\25\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\2\uffff\1\63\25\uffff\1\52"), DFA.unpack("\1\22\2\uffff\1\22\27\uffff\1\31"), DFA.unpack("\1\34\5\uffff\1\31\2\uffff\1\33\14\uffff\1\32"), DFA.unpack("\1\64\2\uffff\1\65\25\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\2\uffff\1\65\25\uffff\1\60"), DFA.unpack("\1\31"), DFA.unpack("\1\67\5\uffff\1\71\1\66\20\uffff\1\70"), DFA.unpack("\1\73\5\uffff\1\75\1\72\20\uffff\1\74"), DFA.unpack("\1\77\5\uffff\1\101\1\76\20\uffff\1\100"), DFA.unpack("\1\103\5\uffff\1\105\1\102\20\uffff\1\104"), DFA.unpack("\1\107\5\uffff\1\111\1\106\20\uffff\1\110"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\24\30\uffff\1\20"), DFA.unpack("\1\62\2\uffff\1\112\25\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\2\uffff\1\112\25\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\64\2\uffff\1\113\25\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\2\uffff\1\113\25\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\115\5\uffff\1\117\1\114\20\uffff\1\116"), DFA.unpack("\1\121\5\uffff\1\123\1\120\20\uffff\1\122"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\62\30\uffff\1\52"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60"), DFA.unpack("\1\64\30\uffff\1\60") ] # class definition for DFA #5 class DFA5(DFA): pass FOLLOW_statement_in_prog265 = frozenset([15, 26, 35, 56, 57, 58]) FOLLOW_EOF_in_prog268 = frozenset([1]) FOLLOW_EOF_in_prog285 = frozenset([1]) FOLLOW_formula_in_statement304 = frozenset([1, 53, 55]) FOLLOW_formula_terminator_in_statement306 = frozenset([1]) FOLLOW_COMMENT_in_statement319 = frozenset([1]) FOLLOW_rule_in_formula336 = frozenset([1]) FOLLOW_fact_in_formula344 = frozenset([1]) FOLLOW_event_in_formula352 = frozenset([1]) FOLLOW_event_op_in_event379 = frozenset([30]) FOLLOW_LBRACKET_in_event381 = frozenset([26, 35, 56, 57, 58]) FOLLOW_rule_in_event383 = frozenset([38, 53, 55]) FOLLOW_formula_terminator_in_event386 = frozenset([44]) FOLLOW_STRING_in_event388 = frozenset([38]) FOLLOW_RBRACKET_in_event392 = frozenset([1]) FOLLOW_literal_list_in_rule472 = frozenset([11]) FOLLOW_COLONMINUS_in_rule474 = frozenset([26, 35, 56, 57, 58]) FOLLOW_literal_list_in_rule476 = frozenset([1]) FOLLOW_literal_in_literal_list503 = frozenset([1, 14]) FOLLOW_COMMA_in_literal_list506 = frozenset([26, 35, 56, 57, 58]) FOLLOW_literal_in_literal_list508 = frozenset([1, 14]) FOLLOW_fact_in_literal536 = frozenset([1]) FOLLOW_NEGATION_in_literal559 = frozenset([26, 56, 57, 58]) FOLLOW_fact_in_literal561 = frozenset([1]) FOLLOW_atom_in_fact590 = frozenset([1]) FOLLOW_modal_op_in_fact598 = frozenset([30]) FOLLOW_LBRACKET_in_fact600 = frozenset([26]) FOLLOW_atom_in_fact602 = frozenset([38]) FOLLOW_RBRACKET_in_fact604 = frozenset([1]) FOLLOW_relation_constant_in_atom664 = frozenset([1, 32]) FOLLOW_LPAREN_in_atom667 = frozenset([20, 26, 27, 39, 44]) FOLLOW_parameter_list_in_atom669 = frozenset([39]) FOLLOW_RPAREN_in_atom672 = frozenset([1]) FOLLOW_parameter_in_parameter_list702 = frozenset([1, 14]) FOLLOW_COMMA_in_parameter_list705 = frozenset([20, 26, 27, 44]) FOLLOW_parameter_in_parameter_list707 = frozenset([1, 14]) FOLLOW_term_in_parameter731 = frozenset([1]) FOLLOW_column_ref_in_parameter743 = frozenset([17]) FOLLOW_EQUAL_in_parameter745 = frozenset([20, 26, 27, 44]) FOLLOW_term_in_parameter747 = frozenset([1]) FOLLOW_ID_in_column_ref774 = frozenset([1]) FOLLOW_INT_in_column_ref793 = frozenset([1]) FOLLOW_object_constant_in_term820 = frozenset([1]) FOLLOW_variable_in_term828 = frozenset([1]) FOLLOW_INT_in_object_constant845 = frozenset([1]) FOLLOW_FLOAT_in_object_constant866 = frozenset([1]) FOLLOW_STRING_in_object_constant885 = frozenset([1]) FOLLOW_ID_in_variable912 = frozenset([1]) FOLLOW_ID_in_relation_constant937 = frozenset([1, 41, 54]) FOLLOW_54_in_relation_constant940 = frozenset([26]) FOLLOW_ID_in_relation_constant942 = frozenset([1, 41, 54]) FOLLOW_SIGN_in_relation_constant946 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("CongressLexer", CongressParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ramineni/my_congress", "path": "congress/datalog/Python3/CongressParser.py", "copies": "2", "size": "82627", "license": "apache-2.0", "hash": 3162882480360510000, "line_mean": 29.3107116654, "line_max": 147, "alpha_frac": 0.4974645092, "autogenerated": false, "ratio": 3.778443387598317, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5275907896798316, "avg_score": null, "num_lines": null }
# $ANTLR 3.5.2 Congress.g 2015-11-02 17:04:43 import sys from antlr3 import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__53=53 T__54=54 T__55=55 T__56=56 T__57=57 T__58=58 AND=4 ATOM=5 BYTESTRPREFIX=6 BYTES_CHAR_DQ=7 BYTES_CHAR_SQ=8 BYTES_ESC=9 BYTES_TESC=10 COLONMINUS=11 COLUMN_NAME=12 COLUMN_NUMBER=13 COMMA=14 COMMENT=15 DIGIT=16 EQUAL=17 EVENT=18 EXPONENT=19 FLOAT=20 FLOAT_EXP=21 FLOAT_NO_EXP=22 FLOAT_OBJ=23 FRAC_PART=24 HEX_DIGIT=25 ID=26 INT=27 INTEGER_OBJ=28 INT_PART=29 LBRACKET=30 LITERAL=31 LPAREN=32 MODAL=33 NAMED_PARAM=34 NEGATION=35 NOT=36 PROG=37 RBRACKET=38 RPAREN=39 RULE=40 SIGN=41 SLBYTESTRING=42 SLSTRING=43 STRING=44 STRING_ESC=45 STRING_OBJ=46 STRPREFIX=47 STRUCTURED_NAME=48 SYMBOL_OBJ=49 THEORY=50 VARIABLE=51 WS=52 # token names tokenNamesMap = { 0: "<invalid>", 1: "<EOR>", 2: "<DOWN>", 3: "<UP>", -1: "EOF", 53: "T__53", 54: "T__54", 55: "T__55", 56: "T__56", 57: "T__57", 58: "T__58", 4: "AND", 5: "ATOM", 6: "BYTESTRPREFIX", 7: "BYTES_CHAR_DQ", 8: "BYTES_CHAR_SQ", 9: "BYTES_ESC", 10: "BYTES_TESC", 11: "COLONMINUS", 12: "COLUMN_NAME", 13: "COLUMN_NUMBER", 14: "COMMA", 15: "COMMENT", 16: "DIGIT", 17: "EQUAL", 18: "EVENT", 19: "EXPONENT", 20: "FLOAT", 21: "FLOAT_EXP", 22: "FLOAT_NO_EXP", 23: "FLOAT_OBJ", 24: "FRAC_PART", 25: "HEX_DIGIT", 26: "ID", 27: "INT", 28: "INTEGER_OBJ", 29: "INT_PART", 30: "LBRACKET", 31: "LITERAL", 32: "LPAREN", 33: "MODAL", 34: "NAMED_PARAM", 35: "NEGATION", 36: "NOT", 37: "PROG", 38: "RBRACKET", 39: "RPAREN", 40: "RULE", 41: "SIGN", 42: "SLBYTESTRING", 43: "SLSTRING", 44: "STRING", 45: "STRING_ESC", 46: "STRING_OBJ", 47: "STRPREFIX", 48: "STRUCTURED_NAME", 49: "SYMBOL_OBJ", 50: "THEORY", 51: "VARIABLE", 52: "WS" } Token.registerTokenNamesMap(tokenNamesMap) class CongressLexer(Lexer): grammarFileName = "Congress.g" api_version = 1 def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super().__init__(input, state) self.delegates = [] self.dfa8 = self.DFA8( self, 8, eot = self.DFA8_eot, eof = self.DFA8_eof, min = self.DFA8_min, max = self.DFA8_max, accept = self.DFA8_accept, special = self.DFA8_special, transition = self.DFA8_transition ) self.dfa23 = self.DFA23( self, 23, eot = self.DFA23_eot, eof = self.DFA23_eof, min = self.DFA23_min, max = self.DFA23_max, accept = self.DFA23_accept, special = self.DFA23_special, transition = self.DFA23_transition ) self.dfa24 = self.DFA24( self, 24, eot = self.DFA24_eot, eof = self.DFA24_eof, min = self.DFA24_min, max = self.DFA24_max, accept = self.DFA24_accept, special = self.DFA24_special, transition = self.DFA24_transition ) self.dfa38 = self.DFA38( self, 38, eot = self.DFA38_eot, eof = self.DFA38_eof, min = self.DFA38_min, max = self.DFA38_max, accept = self.DFA38_accept, special = self.DFA38_special, transition = self.DFA38_transition ) # $ANTLR start "COLONMINUS" def mCOLONMINUS(self, ): try: _type = COLONMINUS _channel = DEFAULT_CHANNEL # Congress.g:7:12: ( ':-' ) # Congress.g:7:14: ':-' pass self.match(":-") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COLONMINUS" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # Congress.g:8:7: ( ',' ) # Congress.g:8:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "LBRACKET" def mLBRACKET(self, ): try: _type = LBRACKET _channel = DEFAULT_CHANNEL # Congress.g:9:10: ( '[' ) # Congress.g:9:12: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LBRACKET" # $ANTLR start "LPAREN" def mLPAREN(self, ): try: _type = LPAREN _channel = DEFAULT_CHANNEL # Congress.g:10:8: ( '(' ) # Congress.g:10:10: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LPAREN" # $ANTLR start "RBRACKET" def mRBRACKET(self, ): try: _type = RBRACKET _channel = DEFAULT_CHANNEL # Congress.g:11:10: ( ']' ) # Congress.g:11:12: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RBRACKET" # $ANTLR start "RPAREN" def mRPAREN(self, ): try: _type = RPAREN _channel = DEFAULT_CHANNEL # Congress.g:12:8: ( ')' ) # Congress.g:12:10: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RPAREN" # $ANTLR start "T__53" def mT__53(self, ): try: _type = T__53 _channel = DEFAULT_CHANNEL # Congress.g:13:7: ( '.' ) # Congress.g:13:9: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__53" # $ANTLR start "T__54" def mT__54(self, ): try: _type = T__54 _channel = DEFAULT_CHANNEL # Congress.g:14:7: ( ':' ) # Congress.g:14:9: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__54" # $ANTLR start "T__55" def mT__55(self, ): try: _type = T__55 _channel = DEFAULT_CHANNEL # Congress.g:15:7: ( ';' ) # Congress.g:15:9: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__55" # $ANTLR start "T__56" def mT__56(self, ): try: _type = T__56 _channel = DEFAULT_CHANNEL # Congress.g:16:7: ( 'delete' ) # Congress.g:16:9: 'delete' pass self.match("delete") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__56" # $ANTLR start "T__57" def mT__57(self, ): try: _type = T__57 _channel = DEFAULT_CHANNEL # Congress.g:17:7: ( 'execute' ) # Congress.g:17:9: 'execute' pass self.match("execute") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__57" # $ANTLR start "T__58" def mT__58(self, ): try: _type = T__58 _channel = DEFAULT_CHANNEL # Congress.g:18:7: ( 'insert' ) # Congress.g:18:9: 'insert' pass self.match("insert") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__58" # $ANTLR start "NEGATION" def mNEGATION(self, ): try: _type = NEGATION _channel = DEFAULT_CHANNEL # Congress.g:167:5: ( 'not' | 'NOT' | '!' ) alt1 = 3 LA1 = self.input.LA(1) if LA1 in {110}: alt1 = 1 elif LA1 in {78}: alt1 = 2 elif LA1 in {33}: alt1 = 3 else: nvae = NoViableAltException("", 1, 0, self.input) raise nvae if alt1 == 1: # Congress.g:167:7: 'not' pass self.match("not") elif alt1 == 2: # Congress.g:168:7: 'NOT' pass self.match("NOT") elif alt1 == 3: # Congress.g:169:7: '!' pass self.match(33) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NEGATION" # $ANTLR start "EQUAL" def mEQUAL(self, ): try: _type = EQUAL _channel = DEFAULT_CHANNEL # Congress.g:173:5: ( '=' ) # Congress.g:173:8: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EQUAL" # $ANTLR start "SIGN" def mSIGN(self, ): try: _type = SIGN _channel = DEFAULT_CHANNEL # Congress.g:177:5: ( '+' | '-' ) # Congress.g: pass if self.input.LA(1) in {43, 45}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SIGN" # $ANTLR start "INT" def mINT(self, ): try: _type = INT _channel = DEFAULT_CHANNEL # Congress.g:184:5: ( '1' .. '9' ( '0' .. '9' )* | ( '0' )+ | '0' ( 'o' | 'O' ) ( '0' .. '7' )+ | '0' ( 'x' | 'X' ) ( HEX_DIGIT )+ | '0' ( 'b' | 'B' ) ( '0' | '1' )+ ) alt7 = 5 LA7_0 = self.input.LA(1) if ((49 <= LA7_0 <= 57) or LA7_0 in {}) : alt7 = 1 elif (LA7_0 == 48) : LA7 = self.input.LA(2) if LA7 in {79, 111}: alt7 = 3 elif LA7 in {88, 120}: alt7 = 4 elif LA7 in {66, 98}: alt7 = 5 else: alt7 = 2 else: nvae = NoViableAltException("", 7, 0, self.input) raise nvae if alt7 == 1: # Congress.g:184:7: '1' .. '9' ( '0' .. '9' )* pass self.matchRange(49, 57) # Congress.g:184:16: ( '0' .. '9' )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((48 <= LA2_0 <= 57) or LA2_0 in {}) : alt2 = 1 if alt2 == 1: # Congress.g: pass if (48 <= self.input.LA(1) <= 57) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop2 elif alt7 == 2: # Congress.g:185:7: ( '0' )+ pass # Congress.g:185:7: ( '0' )+ cnt3 = 0 while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == 48) : alt3 = 1 if alt3 == 1: # Congress.g:185:7: '0' pass self.match(48) else: if cnt3 >= 1: break #loop3 eee = EarlyExitException(3, self.input) raise eee cnt3 += 1 elif alt7 == 3: # Congress.g:186:7: '0' ( 'o' | 'O' ) ( '0' .. '7' )+ pass self.match(48) if self.input.LA(1) in {79, 111}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # Congress.g:186:23: ( '0' .. '7' )+ cnt4 = 0 while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if ((48 <= LA4_0 <= 55) or LA4_0 in {}) : alt4 = 1 if alt4 == 1: # Congress.g: pass if (48 <= self.input.LA(1) <= 55) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt4 >= 1: break #loop4 eee = EarlyExitException(4, self.input) raise eee cnt4 += 1 elif alt7 == 4: # Congress.g:187:7: '0' ( 'x' | 'X' ) ( HEX_DIGIT )+ pass self.match(48) if self.input.LA(1) in {88, 120}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # Congress.g:187:23: ( HEX_DIGIT )+ cnt5 = 0 while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if ((48 <= LA5_0 <= 57) or (65 <= LA5_0 <= 70) or (97 <= LA5_0 <= 102) or LA5_0 in {}) : alt5 = 1 if alt5 == 1: # Congress.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt5 >= 1: break #loop5 eee = EarlyExitException(5, self.input) raise eee cnt5 += 1 elif alt7 == 5: # Congress.g:188:7: '0' ( 'b' | 'B' ) ( '0' | '1' )+ pass self.match(48) if self.input.LA(1) in {66, 98}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # Congress.g:188:23: ( '0' | '1' )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 in {48, 49}) : alt6 = 1 if alt6 == 1: # Congress.g: pass if self.input.LA(1) in {48, 49}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INT" # $ANTLR start "FLOAT" def mFLOAT(self, ): try: _type = FLOAT _channel = DEFAULT_CHANNEL # Congress.g:194:5: ( FLOAT_NO_EXP | FLOAT_EXP ) alt8 = 2 alt8 = self.dfa8.predict(self.input) if alt8 == 1: # Congress.g:194:7: FLOAT_NO_EXP pass self.mFLOAT_NO_EXP() elif alt8 == 2: # Congress.g:195:7: FLOAT_EXP pass self.mFLOAT_EXP() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FLOAT" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # Congress.g:218:5: ( ( STRPREFIX )? ( SLSTRING )+ | ( BYTESTRPREFIX ) ( SLBYTESTRING )+ ) alt12 = 2 LA12 = self.input.LA(1) if LA12 in {114}: LA12_1 = self.input.LA(2) if (LA12_1 in {66, 98}) : alt12 = 2 elif (LA12_1 in {34, 39}) : alt12 = 1 else: nvae = NoViableAltException("", 12, 1, self.input) raise nvae elif LA12 in {34, 39, 85, 117}: alt12 = 1 elif LA12 in {66, 98}: alt12 = 2 elif LA12 in {82}: LA12_4 = self.input.LA(2) if (LA12_4 in {66, 98}) : alt12 = 2 elif (LA12_4 in {34, 39}) : alt12 = 1 else: nvae = NoViableAltException("", 12, 4, self.input) raise nvae else: nvae = NoViableAltException("", 12, 0, self.input) raise nvae if alt12 == 1: # Congress.g:218:7: ( STRPREFIX )? ( SLSTRING )+ pass # Congress.g:218:7: ( STRPREFIX )? alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 in {82, 85, 114, 117}) : alt9 = 1 if alt9 == 1: # Congress.g: pass if self.input.LA(1) in {82, 85, 114, 117}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # Congress.g:218:20: ( SLSTRING )+ cnt10 = 0 while True: #loop10 alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 in {34, 39}) : alt10 = 1 if alt10 == 1: # Congress.g:218:21: SLSTRING pass self.mSLSTRING() else: if cnt10 >= 1: break #loop10 eee = EarlyExitException(10, self.input) raise eee cnt10 += 1 elif alt12 == 2: # Congress.g:219:7: ( BYTESTRPREFIX ) ( SLBYTESTRING )+ pass # Congress.g:219:7: ( BYTESTRPREFIX ) # Congress.g:219:8: BYTESTRPREFIX pass self.mBYTESTRPREFIX() # Congress.g:219:23: ( SLBYTESTRING )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 in {34, 39}) : alt11 = 1 if alt11 == 1: # Congress.g:219:24: SLBYTESTRING pass self.mSLBYTESTRING() else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "ID" def mID(self, ): try: _type = ID _channel = DEFAULT_CHANNEL # Congress.g:225:5: ( ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '.' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' | '.' )* ) # Congress.g:225:7: ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '.' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' | '.' )* pass if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122) or self.input.LA(1) in {46, 95}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # Congress.g:225:35: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' | '.' )* while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if ((48 <= LA13_0 <= 57) or (65 <= LA13_0 <= 90) or (97 <= LA13_0 <= 122) or LA13_0 in {46, 95}) : alt13 = 1 if alt13 == 1: # Congress.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122) or self.input.LA(1) in {46, 95}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop13 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ID" # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # Congress.g:230:5: ( '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' | '/*' ( options {greedy=false; } : . )* '*/' | '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) alt19 = 3 LA19_0 = self.input.LA(1) if (LA19_0 == 47) : LA19_1 = self.input.LA(2) if (LA19_1 == 47) : alt19 = 1 elif (LA19_1 == 42) : alt19 = 2 else: nvae = NoViableAltException("", 19, 1, self.input) raise nvae elif (LA19_0 == 35) : alt19 = 3 else: nvae = NoViableAltException("", 19, 0, self.input) raise nvae if alt19 == 1: # Congress.g:230:7: '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' pass self.match("//") # Congress.g:230:12: (~ ( '\\n' | '\\r' ) )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if ((0 <= LA14_0 <= 9) or (14 <= LA14_0 <= 65535) or LA14_0 in {11, 12}) : alt14 = 1 if alt14 == 1: # Congress.g: pass if (0 <= self.input.LA(1) <= 9) or (14 <= self.input.LA(1) <= 65535) or self.input.LA(1) in {11, 12}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop14 # Congress.g:230:26: ( '\\r' )? alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == 13) : alt15 = 1 if alt15 == 1: # Congress.g:230:26: '\\r' pass self.match(13) self.match(10) #action start _channel=HIDDEN; #action end elif alt19 == 2: # Congress.g:231:7: '/*' ( options {greedy=false; } : . )* '*/' pass self.match("/*") # Congress.g:231:12: ( options {greedy=false; } : . )* while True: #loop16 alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == 42) : LA16_1 = self.input.LA(2) if (LA16_1 == 47) : alt16 = 2 elif ((0 <= LA16_1 <= 46) or (48 <= LA16_1 <= 65535) or LA16_1 in {}) : alt16 = 1 elif ((0 <= LA16_0 <= 41) or (43 <= LA16_0 <= 65535) or LA16_0 in {}) : alt16 = 1 if alt16 == 1: # Congress.g:231:40: . pass self.matchAny() else: break #loop16 self.match("*/") #action start _channel=HIDDEN; #action end elif alt19 == 3: # Congress.g:232:7: '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' pass self.match(35) # Congress.g:232:11: (~ ( '\\n' | '\\r' ) )* while True: #loop17 alt17 = 2 LA17_0 = self.input.LA(1) if ((0 <= LA17_0 <= 9) or (14 <= LA17_0 <= 65535) or LA17_0 in {11, 12}) : alt17 = 1 if alt17 == 1: # Congress.g: pass if (0 <= self.input.LA(1) <= 9) or (14 <= self.input.LA(1) <= 65535) or self.input.LA(1) in {11, 12}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop17 # Congress.g:232:25: ( '\\r' )? alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == 13) : alt18 = 1 if alt18 == 1: # Congress.g:232:25: '\\r' pass self.match(13) self.match(10) #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # Congress.g:236:5: ( ( ' ' | '\\t' | '\\r' | '\\n' ) ) # Congress.g:236:7: ( ' ' | '\\t' | '\\r' | '\\n' ) pass if self.input.LA(1) in {9, 10, 13, 32}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "EXPONENT" def mEXPONENT(self, ): try: # Congress.g:250:5: ( ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ ) # Congress.g:250:7: ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ pass if self.input.LA(1) in {69, 101}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # Congress.g:250:17: ( '+' | '-' )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 in {43, 45}) : alt20 = 1 if alt20 == 1: # Congress.g: pass if self.input.LA(1) in {43, 45}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # Congress.g:250:28: ( '0' .. '9' )+ cnt21 = 0 while True: #loop21 alt21 = 2 LA21_0 = self.input.LA(1) if ((48 <= LA21_0 <= 57) or LA21_0 in {}) : alt21 = 1 if alt21 == 1: # Congress.g: pass if (48 <= self.input.LA(1) <= 57) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt21 >= 1: break #loop21 eee = EarlyExitException(21, self.input) raise eee cnt21 += 1 finally: pass # $ANTLR end "EXPONENT" # $ANTLR start "HEX_DIGIT" def mHEX_DIGIT(self, ): try: # Congress.g:255:5: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) ) # Congress.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "HEX_DIGIT" # $ANTLR start "DIGIT" def mDIGIT(self, ): try: # Congress.g:260:5: ( ( '0' .. '9' ) ) # Congress.g: pass if (48 <= self.input.LA(1) <= 57) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "DIGIT" # $ANTLR start "FLOAT_NO_EXP" def mFLOAT_NO_EXP(self, ): try: # Congress.g:265:5: ( ( INT_PART )? FRAC_PART | INT_PART '.' ) alt23 = 2 alt23 = self.dfa23.predict(self.input) if alt23 == 1: # Congress.g:265:7: ( INT_PART )? FRAC_PART pass # Congress.g:265:7: ( INT_PART )? alt22 = 2 LA22_0 = self.input.LA(1) if ((48 <= LA22_0 <= 57) or LA22_0 in {}) : alt22 = 1 if alt22 == 1: # Congress.g:265:7: INT_PART pass self.mINT_PART() self.mFRAC_PART() elif alt23 == 2: # Congress.g:266:7: INT_PART '.' pass self.mINT_PART() self.match(46) finally: pass # $ANTLR end "FLOAT_NO_EXP" # $ANTLR start "FLOAT_EXP" def mFLOAT_EXP(self, ): try: # Congress.g:271:5: ( ( INT_PART | FLOAT_NO_EXP ) EXPONENT ) # Congress.g:271:7: ( INT_PART | FLOAT_NO_EXP ) EXPONENT pass # Congress.g:271:7: ( INT_PART | FLOAT_NO_EXP ) alt24 = 2 alt24 = self.dfa24.predict(self.input) if alt24 == 1: # Congress.g:271:9: INT_PART pass self.mINT_PART() elif alt24 == 2: # Congress.g:271:20: FLOAT_NO_EXP pass self.mFLOAT_NO_EXP() self.mEXPONENT() finally: pass # $ANTLR end "FLOAT_EXP" # $ANTLR start "INT_PART" def mINT_PART(self, ): try: # Congress.g:276:5: ( ( DIGIT )+ ) # Congress.g:276:7: ( DIGIT )+ pass # Congress.g:276:7: ( DIGIT )+ cnt25 = 0 while True: #loop25 alt25 = 2 LA25_0 = self.input.LA(1) if ((48 <= LA25_0 <= 57) or LA25_0 in {}) : alt25 = 1 if alt25 == 1: # Congress.g: pass if (48 <= self.input.LA(1) <= 57) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt25 >= 1: break #loop25 eee = EarlyExitException(25, self.input) raise eee cnt25 += 1 finally: pass # $ANTLR end "INT_PART" # $ANTLR start "FRAC_PART" def mFRAC_PART(self, ): try: # Congress.g:281:5: ( '.' ( DIGIT )+ ) # Congress.g:281:7: '.' ( DIGIT )+ pass self.match(46) # Congress.g:281:11: ( DIGIT )+ cnt26 = 0 while True: #loop26 alt26 = 2 LA26_0 = self.input.LA(1) if ((48 <= LA26_0 <= 57) or LA26_0 in {}) : alt26 = 1 if alt26 == 1: # Congress.g: pass if (48 <= self.input.LA(1) <= 57) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt26 >= 1: break #loop26 eee = EarlyExitException(26, self.input) raise eee cnt26 += 1 finally: pass # $ANTLR end "FRAC_PART" # $ANTLR start "STRPREFIX" def mSTRPREFIX(self, ): try: # Congress.g:289:5: ( 'r' | 'R' | 'u' | 'U' ) # Congress.g: pass if self.input.LA(1) in {82, 85, 114, 117}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "STRPREFIX" # $ANTLR start "STRING_ESC" def mSTRING_ESC(self, ): try: # Congress.g:294:5: ( '\\\\' . ) # Congress.g:294:7: '\\\\' . pass self.match(92) self.matchAny() finally: pass # $ANTLR end "STRING_ESC" # $ANTLR start "SLSTRING" def mSLSTRING(self, ): try: # Congress.g:301:5: ( '\\'' ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\\'' ) )* '\\'' | '\"' ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\"' ) )* '\"' | '\\'\\'\\'' ( STRING_ESC |~ ( '\\\\' ) )* '\\'\\'\\'' | '\"\"\"' ( STRING_ESC |~ ( '\\\\' ) )* '\"\"\"' ) alt31 = 4 LA31_0 = self.input.LA(1) if (LA31_0 == 39) : LA31_1 = self.input.LA(2) if (LA31_1 == 39) : LA31_3 = self.input.LA(3) if (LA31_3 == 39) : alt31 = 3 else: alt31 = 1 elif ((0 <= LA31_1 <= 9) or (14 <= LA31_1 <= 38) or (40 <= LA31_1 <= 65535) or LA31_1 in {11, 12}) : alt31 = 1 else: nvae = NoViableAltException("", 31, 1, self.input) raise nvae elif (LA31_0 == 34) : LA31_2 = self.input.LA(2) if (LA31_2 == 34) : LA31_5 = self.input.LA(3) if (LA31_5 == 34) : alt31 = 4 else: alt31 = 2 elif ((0 <= LA31_2 <= 9) or (14 <= LA31_2 <= 33) or (35 <= LA31_2 <= 65535) or LA31_2 in {11, 12}) : alt31 = 2 else: nvae = NoViableAltException("", 31, 2, self.input) raise nvae else: nvae = NoViableAltException("", 31, 0, self.input) raise nvae if alt31 == 1: # Congress.g:301:7: '\\'' ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\\'' ) )* '\\'' pass self.match(39) # Congress.g:301:12: ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\\'' ) )* while True: #loop27 alt27 = 3 LA27_0 = self.input.LA(1) if (LA27_0 == 92) : alt27 = 1 elif ((0 <= LA27_0 <= 9) or (14 <= LA27_0 <= 38) or (40 <= LA27_0 <= 91) or (93 <= LA27_0 <= 65535) or LA27_0 in {11, 12}) : alt27 = 2 if alt27 == 1: # Congress.g:301:13: STRING_ESC pass self.mSTRING_ESC() elif alt27 == 2: # Congress.g:301:26: ~ ( '\\\\' | '\\r' | '\\n' | '\\'' ) pass if (0 <= self.input.LA(1) <= 9) or (14 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535) or self.input.LA(1) in {11, 12}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop27 self.match(39) elif alt31 == 2: # Congress.g:302:7: '\"' ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\"' ) )* '\"' pass self.match(34) # Congress.g:302:11: ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\"' ) )* while True: #loop28 alt28 = 3 LA28_0 = self.input.LA(1) if (LA28_0 == 92) : alt28 = 1 elif ((0 <= LA28_0 <= 9) or (14 <= LA28_0 <= 33) or (35 <= LA28_0 <= 91) or (93 <= LA28_0 <= 65535) or LA28_0 in {11, 12}) : alt28 = 2 if alt28 == 1: # Congress.g:302:12: STRING_ESC pass self.mSTRING_ESC() elif alt28 == 2: # Congress.g:302:25: ~ ( '\\\\' | '\\r' | '\\n' | '\"' ) pass if (0 <= self.input.LA(1) <= 9) or (14 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535) or self.input.LA(1) in {11, 12}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop28 self.match(34) elif alt31 == 3: # Congress.g:303:7: '\\'\\'\\'' ( STRING_ESC |~ ( '\\\\' ) )* '\\'\\'\\'' pass self.match("'''") # Congress.g:303:16: ( STRING_ESC |~ ( '\\\\' ) )* while True: #loop29 alt29 = 3 LA29_0 = self.input.LA(1) if (LA29_0 == 39) : LA29_1 = self.input.LA(2) if (LA29_1 == 39) : LA29_4 = self.input.LA(3) if (LA29_4 == 39) : LA29_5 = self.input.LA(4) if ((0 <= LA29_5 <= 65535) or LA29_5 in {}) : alt29 = 2 elif ((0 <= LA29_4 <= 38) or (40 <= LA29_4 <= 65535) or LA29_4 in {}) : alt29 = 2 elif ((0 <= LA29_1 <= 38) or (40 <= LA29_1 <= 65535) or LA29_1 in {}) : alt29 = 2 elif (LA29_0 == 92) : alt29 = 1 elif ((0 <= LA29_0 <= 38) or (40 <= LA29_0 <= 91) or (93 <= LA29_0 <= 65535) or LA29_0 in {}) : alt29 = 2 if alt29 == 1: # Congress.g:303:17: STRING_ESC pass self.mSTRING_ESC() elif alt29 == 2: # Congress.g:303:30: ~ ( '\\\\' ) pass if (0 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop29 self.match("'''") elif alt31 == 4: # Congress.g:304:7: '\"\"\"' ( STRING_ESC |~ ( '\\\\' ) )* '\"\"\"' pass self.match("\"\"\"") # Congress.g:304:13: ( STRING_ESC |~ ( '\\\\' ) )* while True: #loop30 alt30 = 3 LA30_0 = self.input.LA(1) if (LA30_0 == 34) : LA30_1 = self.input.LA(2) if (LA30_1 == 34) : LA30_4 = self.input.LA(3) if (LA30_4 == 34) : LA30_5 = self.input.LA(4) if ((0 <= LA30_5 <= 65535) or LA30_5 in {}) : alt30 = 2 elif ((0 <= LA30_4 <= 33) or (35 <= LA30_4 <= 65535) or LA30_4 in {}) : alt30 = 2 elif ((0 <= LA30_1 <= 33) or (35 <= LA30_1 <= 65535) or LA30_1 in {}) : alt30 = 2 elif (LA30_0 == 92) : alt30 = 1 elif ((0 <= LA30_0 <= 33) or (35 <= LA30_0 <= 91) or (93 <= LA30_0 <= 65535) or LA30_0 in {}) : alt30 = 2 if alt30 == 1: # Congress.g:304:14: STRING_ESC pass self.mSTRING_ESC() elif alt30 == 2: # Congress.g:304:27: ~ ( '\\\\' ) pass if (0 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop30 self.match("\"\"\"") finally: pass # $ANTLR end "SLSTRING" # $ANTLR start "BYTESTRPREFIX" def mBYTESTRPREFIX(self, ): try: # Congress.g:315:5: ( 'b' | 'B' | 'br' | 'Br' | 'bR' | 'BR' | 'rb' | 'rB' | 'Rb' | 'RB' ) alt32 = 10 LA32 = self.input.LA(1) if LA32 in {98}: LA32 = self.input.LA(2) if LA32 in {114}: alt32 = 3 elif LA32 in {82}: alt32 = 5 else: alt32 = 1 elif LA32 in {66}: LA32 = self.input.LA(2) if LA32 in {114}: alt32 = 4 elif LA32 in {82}: alt32 = 6 else: alt32 = 2 elif LA32 in {114}: LA32_3 = self.input.LA(2) if (LA32_3 == 98) : alt32 = 7 elif (LA32_3 == 66) : alt32 = 8 else: nvae = NoViableAltException("", 32, 3, self.input) raise nvae elif LA32 in {82}: LA32_4 = self.input.LA(2) if (LA32_4 == 98) : alt32 = 9 elif (LA32_4 == 66) : alt32 = 10 else: nvae = NoViableAltException("", 32, 4, self.input) raise nvae else: nvae = NoViableAltException("", 32, 0, self.input) raise nvae if alt32 == 1: # Congress.g:315:7: 'b' pass self.match(98) elif alt32 == 2: # Congress.g:315:13: 'B' pass self.match(66) elif alt32 == 3: # Congress.g:315:19: 'br' pass self.match("br") elif alt32 == 4: # Congress.g:315:26: 'Br' pass self.match("Br") elif alt32 == 5: # Congress.g:315:33: 'bR' pass self.match("bR") elif alt32 == 6: # Congress.g:315:40: 'BR' pass self.match("BR") elif alt32 == 7: # Congress.g:315:47: 'rb' pass self.match("rb") elif alt32 == 8: # Congress.g:315:54: 'rB' pass self.match("rB") elif alt32 == 9: # Congress.g:315:61: 'Rb' pass self.match("Rb") elif alt32 == 10: # Congress.g:315:68: 'RB' pass self.match("RB") finally: pass # $ANTLR end "BYTESTRPREFIX" # $ANTLR start "SLBYTESTRING" def mSLBYTESTRING(self, ): try: # Congress.g:320:5: ( '\\'' ( BYTES_CHAR_SQ | BYTES_ESC )* '\\'' | '\"' ( BYTES_CHAR_DQ | BYTES_ESC )* '\"' | '\\'\\'\\'' ( BYTES_CHAR_SQ | BYTES_TESC )* '\\'\\'\\'' | '\"\"\"' ( BYTES_CHAR_DQ | BYTES_TESC )* '\"\"\"' ) alt37 = 4 LA37_0 = self.input.LA(1) if (LA37_0 == 39) : LA37_1 = self.input.LA(2) if (LA37_1 == 39) : LA37_3 = self.input.LA(3) if (LA37_3 == 39) : alt37 = 3 else: alt37 = 1 elif ((0 <= LA37_1 <= 9) or (14 <= LA37_1 <= 38) or (40 <= LA37_1 <= 127) or LA37_1 in {11, 12}) : alt37 = 1 else: nvae = NoViableAltException("", 37, 1, self.input) raise nvae elif (LA37_0 == 34) : LA37_2 = self.input.LA(2) if (LA37_2 == 34) : LA37_5 = self.input.LA(3) if (LA37_5 == 34) : alt37 = 4 else: alt37 = 2 elif ((0 <= LA37_2 <= 9) or (14 <= LA37_2 <= 33) or (35 <= LA37_2 <= 127) or LA37_2 in {11, 12}) : alt37 = 2 else: nvae = NoViableAltException("", 37, 2, self.input) raise nvae else: nvae = NoViableAltException("", 37, 0, self.input) raise nvae if alt37 == 1: # Congress.g:320:7: '\\'' ( BYTES_CHAR_SQ | BYTES_ESC )* '\\'' pass self.match(39) # Congress.g:320:12: ( BYTES_CHAR_SQ | BYTES_ESC )* while True: #loop33 alt33 = 3 LA33_0 = self.input.LA(1) if ((0 <= LA33_0 <= 9) or (14 <= LA33_0 <= 38) or (40 <= LA33_0 <= 91) or (93 <= LA33_0 <= 127) or LA33_0 in {11, 12}) : alt33 = 1 elif (LA33_0 == 92) : alt33 = 2 if alt33 == 1: # Congress.g:320:13: BYTES_CHAR_SQ pass self.mBYTES_CHAR_SQ() elif alt33 == 2: # Congress.g:320:29: BYTES_ESC pass self.mBYTES_ESC() else: break #loop33 self.match(39) elif alt37 == 2: # Congress.g:321:7: '\"' ( BYTES_CHAR_DQ | BYTES_ESC )* '\"' pass self.match(34) # Congress.g:321:11: ( BYTES_CHAR_DQ | BYTES_ESC )* while True: #loop34 alt34 = 3 LA34_0 = self.input.LA(1) if ((0 <= LA34_0 <= 9) or (14 <= LA34_0 <= 33) or (35 <= LA34_0 <= 91) or (93 <= LA34_0 <= 127) or LA34_0 in {11, 12}) : alt34 = 1 elif (LA34_0 == 92) : alt34 = 2 if alt34 == 1: # Congress.g:321:12: BYTES_CHAR_DQ pass self.mBYTES_CHAR_DQ() elif alt34 == 2: # Congress.g:321:28: BYTES_ESC pass self.mBYTES_ESC() else: break #loop34 self.match(34) elif alt37 == 3: # Congress.g:322:7: '\\'\\'\\'' ( BYTES_CHAR_SQ | BYTES_TESC )* '\\'\\'\\'' pass self.match("'''") # Congress.g:322:16: ( BYTES_CHAR_SQ | BYTES_TESC )* while True: #loop35 alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == 39) : LA35_1 = self.input.LA(2) if (LA35_1 == 39) : LA35_3 = self.input.LA(3) if (LA35_3 == 39) : LA35_4 = self.input.LA(4) if ((0 <= LA35_4 <= 91) or (93 <= LA35_4 <= 127) or LA35_4 in {}) : alt35 = 1 elif ((0 <= LA35_3 <= 38) or (40 <= LA35_3 <= 91) or (93 <= LA35_3 <= 127) or LA35_3 in {}) : alt35 = 1 elif ((0 <= LA35_1 <= 38) or (40 <= LA35_1 <= 91) or (93 <= LA35_1 <= 127) or LA35_1 in {}) : alt35 = 1 elif ((0 <= LA35_0 <= 38) or (40 <= LA35_0 <= 91) or (93 <= LA35_0 <= 127) or LA35_0 in {}) : alt35 = 1 if alt35 == 1: # Congress.g: pass if (0 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop35 self.match("'''") elif alt37 == 4: # Congress.g:323:7: '\"\"\"' ( BYTES_CHAR_DQ | BYTES_TESC )* '\"\"\"' pass self.match("\"\"\"") # Congress.g:323:13: ( BYTES_CHAR_DQ | BYTES_TESC )* while True: #loop36 alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == 34) : LA36_1 = self.input.LA(2) if (LA36_1 == 34) : LA36_3 = self.input.LA(3) if (LA36_3 == 34) : LA36_4 = self.input.LA(4) if ((0 <= LA36_4 <= 91) or (93 <= LA36_4 <= 127) or LA36_4 in {}) : alt36 = 1 elif ((0 <= LA36_3 <= 33) or (35 <= LA36_3 <= 91) or (93 <= LA36_3 <= 127) or LA36_3 in {}) : alt36 = 1 elif ((0 <= LA36_1 <= 33) or (35 <= LA36_1 <= 91) or (93 <= LA36_1 <= 127) or LA36_1 in {}) : alt36 = 1 elif ((0 <= LA36_0 <= 33) or (35 <= LA36_0 <= 91) or (93 <= LA36_0 <= 127) or LA36_0 in {}) : alt36 = 1 if alt36 == 1: # Congress.g: pass if (0 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop36 self.match("\"\"\"") finally: pass # $ANTLR end "SLBYTESTRING" # $ANTLR start "BYTES_CHAR_SQ" def mBYTES_CHAR_SQ(self, ): try: # Congress.g:328:5: ( '\\u0000' .. '\\u0009' | '\\u000B' .. '\\u000C' | '\\u000E' .. '\\u0026' | '\\u0028' .. '\\u005B' | '\\u005D' .. '\\u007F' ) # Congress.g: pass if (0 <= self.input.LA(1) <= 9) or (14 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127) or self.input.LA(1) in {11, 12}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "BYTES_CHAR_SQ" # $ANTLR start "BYTES_CHAR_DQ" def mBYTES_CHAR_DQ(self, ): try: # Congress.g:337:5: ( '\\u0000' .. '\\u0009' | '\\u000B' .. '\\u000C' | '\\u000E' .. '\\u0021' | '\\u0023' .. '\\u005B' | '\\u005D' .. '\\u007F' ) # Congress.g: pass if (0 <= self.input.LA(1) <= 9) or (14 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127) or self.input.LA(1) in {11, 12}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "BYTES_CHAR_DQ" # $ANTLR start "BYTES_ESC" def mBYTES_ESC(self, ): try: # Congress.g:346:5: ( '\\\\' '\\u0000' .. '\\u007F' ) # Congress.g:346:7: '\\\\' '\\u0000' .. '\\u007F' pass self.match(92) self.matchRange(0, 127) finally: pass # $ANTLR end "BYTES_ESC" # $ANTLR start "BYTES_TESC" def mBYTES_TESC(self, ): try: # Congress.g:352:5: ( '\\u0000' .. '\\u005B' | '\\u005D' .. '\\u007F' ) # Congress.g: pass if (0 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127) or self.input.LA(1) in {}: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "BYTES_TESC" def mTokens(self): # Congress.g:1:8: ( COLONMINUS | COMMA | LBRACKET | LPAREN | RBRACKET | RPAREN | T__53 | T__54 | T__55 | T__56 | T__57 | T__58 | NEGATION | EQUAL | SIGN | INT | FLOAT | STRING | ID | COMMENT | WS ) alt38 = 21 alt38 = self.dfa38.predict(self.input) if alt38 == 1: # Congress.g:1:10: COLONMINUS pass self.mCOLONMINUS() elif alt38 == 2: # Congress.g:1:21: COMMA pass self.mCOMMA() elif alt38 == 3: # Congress.g:1:27: LBRACKET pass self.mLBRACKET() elif alt38 == 4: # Congress.g:1:36: LPAREN pass self.mLPAREN() elif alt38 == 5: # Congress.g:1:43: RBRACKET pass self.mRBRACKET() elif alt38 == 6: # Congress.g:1:52: RPAREN pass self.mRPAREN() elif alt38 == 7: # Congress.g:1:59: T__53 pass self.mT__53() elif alt38 == 8: # Congress.g:1:65: T__54 pass self.mT__54() elif alt38 == 9: # Congress.g:1:71: T__55 pass self.mT__55() elif alt38 == 10: # Congress.g:1:77: T__56 pass self.mT__56() elif alt38 == 11: # Congress.g:1:83: T__57 pass self.mT__57() elif alt38 == 12: # Congress.g:1:89: T__58 pass self.mT__58() elif alt38 == 13: # Congress.g:1:95: NEGATION pass self.mNEGATION() elif alt38 == 14: # Congress.g:1:104: EQUAL pass self.mEQUAL() elif alt38 == 15: # Congress.g:1:110: SIGN pass self.mSIGN() elif alt38 == 16: # Congress.g:1:115: INT pass self.mINT() elif alt38 == 17: # Congress.g:1:119: FLOAT pass self.mFLOAT() elif alt38 == 18: # Congress.g:1:125: STRING pass self.mSTRING() elif alt38 == 19: # Congress.g:1:132: ID pass self.mID() elif alt38 == 20: # Congress.g:1:135: COMMENT pass self.mCOMMENT() elif alt38 == 21: # Congress.g:1:143: WS pass self.mWS() # lookup tables for DFA #8 DFA8_eot = DFA.unpack( "\3\uffff\1\6\1\uffff\1\6\1\uffff" ) DFA8_eof = DFA.unpack( "\7\uffff" ) DFA8_min = DFA.unpack( "\2\56\2\60\1\uffff\1\60\1\uffff" ) DFA8_max = DFA.unpack( "\1\71\1\145\1\71\1\145\1\uffff\1\145\1\uffff" ) DFA8_accept = DFA.unpack( "\4\uffff\1\2\1\uffff\1\1" ) DFA8_special = DFA.unpack( "\7\uffff" ) DFA8_transition = [ DFA.unpack("\1\2\1\uffff\12\1"), DFA.unpack("\1\3\1\uffff\12\1\13\uffff\1\4\37\uffff\1\4"), DFA.unpack("\12\5"), DFA.unpack("\12\5\13\uffff\1\4\37\uffff\1\4"), DFA.unpack(""), DFA.unpack("\12\5\13\uffff\1\4\37\uffff\1\4"), DFA.unpack("") ] # class definition for DFA #8 class DFA8(DFA): pass # lookup tables for DFA #23 DFA23_eot = DFA.unpack( "\3\uffff\1\4\1\uffff" ) DFA23_eof = DFA.unpack( "\5\uffff" ) DFA23_min = DFA.unpack( "\2\56\1\uffff\1\60\1\uffff" ) DFA23_max = DFA.unpack( "\2\71\1\uffff\1\71\1\uffff" ) DFA23_accept = DFA.unpack( "\2\uffff\1\1\1\uffff\1\2" ) DFA23_special = DFA.unpack( "\5\uffff" ) DFA23_transition = [ DFA.unpack("\1\2\1\uffff\12\1"), DFA.unpack("\1\3\1\uffff\12\1"), DFA.unpack(""), DFA.unpack("\12\2"), DFA.unpack("") ] # class definition for DFA #23 class DFA23(DFA): pass # lookup tables for DFA #24 DFA24_eot = DFA.unpack( "\4\uffff" ) DFA24_eof = DFA.unpack( "\4\uffff" ) DFA24_min = DFA.unpack( "\2\56\2\uffff" ) DFA24_max = DFA.unpack( "\1\71\1\145\2\uffff" ) DFA24_accept = DFA.unpack( "\2\uffff\1\2\1\1" ) DFA24_special = DFA.unpack( "\4\uffff" ) DFA24_transition = [ DFA.unpack("\1\2\1\uffff\12\1"), DFA.unpack("\1\2\1\uffff\12\1\13\uffff\1\3\37\uffff\1\3"), DFA.unpack(""), DFA.unpack("") ] # class definition for DFA #24 class DFA24(DFA): pass # lookup tables for DFA #38 DFA38_eot = DFA.unpack( "\1\uffff\1\35\5\uffff\1\36\1\uffff\5\31\3\uffff\2\46\1\31\1\uffff" "\4\31\6\uffff\1\47\5\31\1\46\2\uffff\1\46\14\31\2\16\1\47\6\31\1" "\101\1\31\1\103\1\uffff\1\104\2\uffff" ) DFA38_eof = DFA.unpack( "\105\uffff" ) DFA38_min = DFA.unpack( "\1\11\1\55\5\uffff\1\56\1\uffff\1\145\1\170\1\156\1\157\1\117\3" "\uffff\2\56\1\42\1\uffff\4\42\6\uffff\1\56\1\154\1\145\1\163\1\164" "\1\124\1\56\2\uffff\1\56\10\42\1\53\1\145\1\143\1\145\3\56\1\164" "\1\165\1\162\1\145\2\164\1\56\1\145\1\56\1\uffff\1\56\2\uffff" ) DFA38_max = DFA.unpack( "\1\172\1\55\5\uffff\1\172\1\uffff\1\145\1\170\1\156\1\157\1\117" "\3\uffff\2\145\1\142\1\uffff\2\162\1\142\1\47\6\uffff\1\172\1\154" "\1\145\1\163\1\164\1\124\1\145\2\uffff\1\145\10\47\1\71\1\145\1" "\143\1\145\3\172\1\164\1\165\1\162\1\145\2\164\1\172\1\145\1\172" "\1\uffff\1\172\2\uffff" ) DFA38_accept = DFA.unpack( "\2\uffff\1\2\1\3\1\4\1\5\1\6\1\uffff\1\11\5\uffff\1\15\1\16\1\17" "\3\uffff\1\22\4\uffff\1\23\1\24\1\25\1\1\1\10\1\7\7\uffff\1\20\1" "\21\31\uffff\1\12\1\uffff\1\14\1\13" ) DFA38_special = DFA.unpack( "\105\uffff" ) DFA38_transition = [ DFA.unpack("\2\33\2\uffff\1\33\22\uffff\1\33\1\16\1\24\1\32\3\uffff" "\1\24\1\4\1\6\1\uffff\1\20\1\2\1\20\1\7\1\32\1\22\11\21\1\1\1\10" "\1\uffff\1\17\3\uffff\1\31\1\26\13\31\1\15\3\31\1\27\2\31\1\30\5" "\31\1\3\1\uffff\1\5\1\uffff\1\31\1\uffff\1\31\1\25\1\31\1\11\1\12" "\3\31\1\13\4\31\1\14\3\31\1\23\2\31\1\30\5\31"), DFA.unpack("\1\34"), DFA.unpack(""), DFA.unpack(""), DFA.unpack(""), DFA.unpack(""), DFA.unpack(""), DFA.unpack("\1\31\1\uffff\12\37\7\uffff\32\31\4\uffff\1\31\1\uffff" "\32\31"), DFA.unpack(""), DFA.unpack("\1\40"), DFA.unpack("\1\41"), DFA.unpack("\1\42"), DFA.unpack("\1\43"), DFA.unpack("\1\44"), DFA.unpack(""), DFA.unpack(""), DFA.unpack(""), DFA.unpack("\1\47\1\uffff\12\45\13\uffff\1\47\37\uffff\1\47"), DFA.unpack("\1\47\1\uffff\1\50\11\47\13\uffff\1\47\37\uffff\1\47"), DFA.unpack("\1\24\4\uffff\1\24\32\uffff\1\52\37\uffff\1\51"), DFA.unpack(""), DFA.unpack("\1\24\4\uffff\1\24\52\uffff\1\54\37\uffff\1\53"), DFA.unpack("\1\24\4\uffff\1\24\52\uffff\1\56\37\uffff\1\55"), DFA.unpack("\1\24\4\uffff\1\24\32\uffff\1\60\37\uffff\1\57"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack(""), DFA.unpack(""), DFA.unpack(""), DFA.unpack(""), DFA.unpack(""), DFA.unpack(""), DFA.unpack("\1\31\1\uffff\12\37\7\uffff\4\31\1\61\25\31\4\uffff" "\1\31\1\uffff\4\31\1\61\25\31"), DFA.unpack("\1\62"), DFA.unpack("\1\63"), DFA.unpack("\1\64"), DFA.unpack("\1\65"), DFA.unpack("\1\66"), DFA.unpack("\1\47\1\uffff\12\45\13\uffff\1\47\37\uffff\1\47"), DFA.unpack(""), DFA.unpack(""), DFA.unpack("\1\47\1\uffff\1\50\11\47\13\uffff\1\47\37\uffff\1\47"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack("\1\24\4\uffff\1\24"), DFA.unpack("\1\47\1\uffff\1\47\2\uffff\12\67"), DFA.unpack("\1\70"), DFA.unpack("\1\71"), DFA.unpack("\1\72"), DFA.unpack("\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" "\32\31"), DFA.unpack("\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" "\32\31"), DFA.unpack("\1\31\1\uffff\12\67\7\uffff\32\31\4\uffff\1\31\1\uffff" "\32\31"), DFA.unpack("\1\73"), DFA.unpack("\1\74"), DFA.unpack("\1\75"), DFA.unpack("\1\76"), DFA.unpack("\1\77"), DFA.unpack("\1\100"), DFA.unpack("\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" "\32\31"), DFA.unpack("\1\102"), DFA.unpack("\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" "\32\31"), DFA.unpack(""), DFA.unpack("\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" "\32\31"), DFA.unpack(""), DFA.unpack("") ] # class definition for DFA #38 class DFA38(DFA): pass def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(CongressLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ramineni/my_congress", "path": "congress/datalog/Python3/CongressLexer.py", "copies": "2", "size": "68168", "license": "apache-2.0", "hash": 440582133578715650, "line_mean": 23.7883636364, "line_max": 272, "alpha_frac": 0.3762175801, "autogenerated": false, "ratio": 3.4728208263283915, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4849038406428392, "avg_score": null, "num_lines": null }
# $ANTLR 3.5.2 interface.g 2019-06-25 12:24:53 import sys from antlr3 import * from antlr3.compat import set, frozenset import os import sys import interfaceIR from interfaceLexer import interfaceLexer def UnquoteString(quotedString): return quotedString[1:-1].decode('string_escape') def StripPostComment(comment): return comment[4:] def StripPreComment(comment): """Get text from C-style doxygen comment.""" commentLines=comment[3:-2].split(u'\n') strippedCommentLines=[] inVerbatim=False for commentLine in commentLines: if commentLine.startswith (' *'): commentLine = commentLine[2:] strippedCommentLines.append(commentLine) if commentLine.strip() == u'@verbatim': inVerbatim = True elif commentLine.strip() == u'@endverbatim': inVerbatim = False result = u'\n'.join(strippedCommentLines) return result # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__30=30 T__31=31 T__32=32 T__33=33 T__34=34 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 T__40=40 T__41=41 T__42=42 ALPHA=4 ALPHANUM=5 BITMASK=6 CPP_COMMENT=7 C_COMMENT=8 DEC_NUMBER=9 DEFINE=10 DOC_POST_COMMENT=11 DOC_PRE_COMMENT=12 ENUM=13 EVENT=14 FUNCTION=15 HANDLER=16 HEXNUM=17 HEX_NUMBER=18 IDENTIFIER=19 IN=20 NUM=21 OUT=22 QUOTED_STRING=23 REFERENCE=24 SCOPED_IDENTIFIER=25 SEMICOLON=26 STRUCT=27 USETYPES=28 WS=29 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "ALPHA", "ALPHANUM", "BITMASK", "CPP_COMMENT", "C_COMMENT", "DEC_NUMBER", "DEFINE", "DOC_POST_COMMENT", "DOC_PRE_COMMENT", "ENUM", "EVENT", "FUNCTION", "HANDLER", "HEXNUM", "HEX_NUMBER", "IDENTIFIER", "IN", "NUM", "OUT", "QUOTED_STRING", "REFERENCE", "SCOPED_IDENTIFIER", "SEMICOLON", "STRUCT", "USETYPES", "WS", "'('", "')'", "'*'", "'+'", "','", "'-'", "'..'", "'/'", "'='", "'['", "']'", "'{'", "'}'" ] class interfaceParser(Parser): grammarFileName = "interface.g" api_version = 1 tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(interfaceParser, self).__init__(input, state, *args, **kwargs) self.dfa14 = self.DFA14( self, 14, eot = self.DFA14_eot, eof = self.DFA14_eof, min = self.DFA14_min, max = self.DFA14_max, accept = self.DFA14_accept, special = self.DFA14_special, transition = self.DFA14_transition ) self.dfa16 = self.DFA16( self, 16, eot = self.DFA16_eot, eof = self.DFA16_eof, min = self.DFA16_min, max = self.DFA16_max, accept = self.DFA16_accept, special = self.DFA16_special, transition = self.DFA16_transition ) self.dfa20 = self.DFA20( self, 20, eot = self.DFA20_eot, eof = self.DFA20_eof, min = self.DFA20_min, max = self.DFA20_max, accept = self.DFA20_accept, special = self.DFA20_special, transition = self.DFA20_transition ) self.iface = interfaceIR.Interface() self.searchPath = [] self.compileErrors = 0 self.delegates = [] INVALID_NUMBER = 0xcdcdcdcd def getTokenErrorDisplay(self, t): """ Display a token for an error message. Since doc comments can be multi-line, only display the first line of the token. """ s = t.text if s is None: # No text -- fallback to default handler return super(self, Parser).getTokenErrorDisplay(t) else: s = s.split('\n', 2)[0] return repr(s) def getErrorHeader(self, e): """ What is the error header, normally line/character position information? """ source_name = self.getSourceName() if source_name is not None: return "{}:{}:{}: error:".format(source_name, e.line, e.charPositionInLine) return "{}:{}: error:".format(e.line, e.charPositionInLine) def getErrorHeaderForToken(self, token): """ What is the error header for a token, normally line/character position information? """ source_name = self.getSourceName() if source_name is not None: return "{}:{}:{}: error:".format(source_name, token.line, token.charPositionInLine) return "{}:{}: error:".format(token.line, token.charPositionInLine) def getWarningHeaderForToken(self, token): """ What is the warning header for a token, normally line/character position information? """ source_name = self.getSourceName() if source_name is not None: return "{}:{}:{}: warning:".format(source_name, token.line, token.charPositionInLine) return "{}:{}: warning:".format(token.line, token.charPositionInLine) def getLocationTuple(self, token): """ Returns a tuple specifying the exact location of a token: (path, line, col) """ return (self.getSourceName(), token.line, token.charPositionInLine) # $ANTLR start "direction" # interface.g:239:1: direction returns [direction] : ( IN | OUT ); def direction(self, ): direction = None try: try: # interface.g:240:5: ( IN | OUT ) alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == IN) : alt1 = 1 elif (LA1_0 == OUT) : alt1 = 2 else: nvae = NoViableAltException("", 1, 0, self.input) raise nvae if alt1 == 1: # interface.g:240:7: IN pass self.match(self.input, IN, self.FOLLOW_IN_in_direction520) #action start direction = interfaceIR.DIR_IN #action end elif alt1 == 2: # interface.g:241:7: OUT pass self.match(self.input, OUT, self.FOLLOW_OUT_in_direction534) #action start direction = interfaceIR.DIR_OUT #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return direction # $ANTLR end "direction" # $ANTLR start "number" # interface.g:245:1: number returns [value] : ( DEC_NUMBER | HEX_NUMBER ); def number(self, ): value = None DEC_NUMBER1 = None HEX_NUMBER2 = None try: try: # interface.g:246:5: ( DEC_NUMBER | HEX_NUMBER ) alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == DEC_NUMBER) : alt2 = 1 elif (LA2_0 == HEX_NUMBER) : alt2 = 2 else: nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # interface.g:246:7: DEC_NUMBER pass DEC_NUMBER1 = self.match(self.input, DEC_NUMBER, self.FOLLOW_DEC_NUMBER_in_number562) #action start value = int(DEC_NUMBER1.text, 10) #action end elif alt2 == 2: # interface.g:247:7: HEX_NUMBER pass HEX_NUMBER2 = self.match(self.input, HEX_NUMBER, self.FOLLOW_HEX_NUMBER_in_number575) #action start value = int(HEX_NUMBER2.text, 16) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return value # $ANTLR end "number" # $ANTLR start "integer" # interface.g:250:1: integer returns [value] : ( '+' DEC_NUMBER | '-' DEC_NUMBER | DEC_NUMBER | HEX_NUMBER ); def integer(self, ): value = None DEC_NUMBER3 = None DEC_NUMBER4 = None DEC_NUMBER5 = None HEX_NUMBER6 = None try: try: # interface.g:251:5: ( '+' DEC_NUMBER | '-' DEC_NUMBER | DEC_NUMBER | HEX_NUMBER ) alt3 = 4 LA3 = self.input.LA(1) if LA3 == 33: alt3 = 1 elif LA3 == 35: alt3 = 2 elif LA3 == DEC_NUMBER: alt3 = 3 elif LA3 == HEX_NUMBER: alt3 = 4 else: nvae = NoViableAltException("", 3, 0, self.input) raise nvae if alt3 == 1: # interface.g:251:7: '+' DEC_NUMBER pass self.match(self.input, 33, self.FOLLOW_33_in_integer601) DEC_NUMBER3 = self.match(self.input, DEC_NUMBER, self.FOLLOW_DEC_NUMBER_in_integer603) #action start value = int(DEC_NUMBER3.text, 10) #action end elif alt3 == 2: # interface.g:252:7: '-' DEC_NUMBER pass self.match(self.input, 35, self.FOLLOW_35_in_integer615) DEC_NUMBER4 = self.match(self.input, DEC_NUMBER, self.FOLLOW_DEC_NUMBER_in_integer617) #action start value = -int(DEC_NUMBER4.text, 10) #action end elif alt3 == 3: # interface.g:253:7: DEC_NUMBER pass DEC_NUMBER5 = self.match(self.input, DEC_NUMBER, self.FOLLOW_DEC_NUMBER_in_integer629) #action start value = int(DEC_NUMBER5.text, 10) #action end elif alt3 == 4: # interface.g:254:7: HEX_NUMBER pass HEX_NUMBER6 = self.match(self.input, HEX_NUMBER, self.FOLLOW_HEX_NUMBER_in_integer645) #action start value = int(HEX_NUMBER6.text, 16) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return value # $ANTLR end "integer" class defineValue_return(ParserRuleReturnScope): def __init__(self): super(interfaceParser.defineValue_return, self).__init__() self.value = None # $ANTLR start "defineValue" # interface.g:257:1: defineValue returns [value] : ( IDENTIFIER | SCOPED_IDENTIFIER ); def defineValue(self, ): retval = self.defineValue_return() retval.start = self.input.LT(1) IDENTIFIER7 = None SCOPED_IDENTIFIER8 = None try: try: # interface.g:258:5: ( IDENTIFIER | SCOPED_IDENTIFIER ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == IDENTIFIER) : alt4 = 1 elif (LA4_0 == SCOPED_IDENTIFIER) : alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # interface.g:258:7: IDENTIFIER pass IDENTIFIER7 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_defineValue674) #action start retval.value = int(self.iface.findDefinition(IDENTIFIER7.text).value) #action end elif alt4 == 2: # interface.g:259:7: SCOPED_IDENTIFIER pass SCOPED_IDENTIFIER8 = self.match(self.input, SCOPED_IDENTIFIER, self.FOLLOW_SCOPED_IDENTIFIER_in_defineValue691) #action start retval.value = int(self.iface.findDefinition(SCOPED_IDENTIFIER8.text).value) #action end retval.stop = self.input.LT(-1) except KeyError, e: self.emitErrorMessage(self.getErrorHeaderForToken(retval.start) + " No definition for {}".format(self.input.toString(retval.start, self.input.LT(-1)))) self.compileErrors += 1 except TypeError, e: self.emitErrorMessage(self.getErrorHeaderForToken(retval.start) + " {} is not an integer definition".format(self.input.toString(retval.start, self.input.LT(-1)))) self.compileErrors += 1 finally: pass return retval # $ANTLR end "defineValue" class simpleNumber_return(ParserRuleReturnScope): def __init__(self): super(interfaceParser.simpleNumber_return, self).__init__() self.value = None # $ANTLR start "simpleNumber" # interface.g:275:1: simpleNumber returns [value] : ( number | defineValue ); def simpleNumber(self, ): retval = self.simpleNumber_return() retval.start = self.input.LT(1) number9 = None defineValue10 = None try: try: # interface.g:276:5: ( number | defineValue ) alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == DEC_NUMBER or LA5_0 == HEX_NUMBER) : alt5 = 1 elif (LA5_0 == IDENTIFIER or LA5_0 == SCOPED_IDENTIFIER) : alt5 = 2 else: nvae = NoViableAltException("", 5, 0, self.input) raise nvae if alt5 == 1: # interface.g:276:7: number pass self._state.following.append(self.FOLLOW_number_in_simpleNumber728) number9 = self.number() self._state.following.pop() #action start retval.value = number9 #action end elif alt5 == 2: # interface.g:277:7: defineValue pass self._state.following.append(self.FOLLOW_defineValue_in_simpleNumber749) defineValue10 = self.defineValue() self._state.following.pop() #action start retval.value = ((defineValue10 is not None) and [defineValue10.value] or [None])[0] #action end retval.stop = self.input.LT(-1) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return retval # $ANTLR end "simpleNumber" # $ANTLR start "simpleExpression" # interface.g:280:1: simpleExpression returns [value] : ( integer | defineValue | '(' sumExpression ')' ); def simpleExpression(self, ): value = None integer11 = None defineValue12 = None sumExpression13 = None try: try: # interface.g:281:5: ( integer | defineValue | '(' sumExpression ')' ) alt6 = 3 LA6 = self.input.LA(1) if LA6 == DEC_NUMBER or LA6 == HEX_NUMBER or LA6 == 33 or LA6 == 35: alt6 = 1 elif LA6 == IDENTIFIER or LA6 == SCOPED_IDENTIFIER: alt6 = 2 elif LA6 == 30: alt6 = 3 else: nvae = NoViableAltException("", 6, 0, self.input) raise nvae if alt6 == 1: # interface.g:281:7: integer pass self._state.following.append(self.FOLLOW_integer_in_simpleExpression778) integer11 = self.integer() self._state.following.pop() #action start value = integer11 #action end elif alt6 == 2: # interface.g:282:7: defineValue pass self._state.following.append(self.FOLLOW_defineValue_in_simpleExpression802) defineValue12 = self.defineValue() self._state.following.pop() #action start value = ((defineValue12 is not None) and [defineValue12.value] or [None])[0] #action end elif alt6 == 3: # interface.g:283:7: '(' sumExpression ')' pass self.match(self.input, 30, self.FOLLOW_30_in_simpleExpression822) self._state.following.append(self.FOLLOW_sumExpression_in_simpleExpression824) sumExpression13 = self.sumExpression() self._state.following.pop() self.match(self.input, 31, self.FOLLOW_31_in_simpleExpression826) #action start value = sumExpression13 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return value # $ANTLR end "simpleExpression" # $ANTLR start "productExpression" # interface.g:286:1: productExpression returns [value] : initialValue= simpleExpression ( '*' mulValue= simpleExpression | '/' divValue= simpleExpression )* ; def productExpression(self, ): value = None initialValue = None mulValue = None divValue = None try: try: # interface.g:287:5: (initialValue= simpleExpression ( '*' mulValue= simpleExpression | '/' divValue= simpleExpression )* ) # interface.g:287:7: initialValue= simpleExpression ( '*' mulValue= simpleExpression | '/' divValue= simpleExpression )* pass self._state.following.append(self.FOLLOW_simpleExpression_in_productExpression851) initialValue = self.simpleExpression() self._state.following.pop() #action start value = initialValue #action end # interface.g:288:9: ( '*' mulValue= simpleExpression | '/' divValue= simpleExpression )* while True: #loop7 alt7 = 3 LA7_0 = self.input.LA(1) if (LA7_0 == 32) : alt7 = 1 elif (LA7_0 == 37) : alt7 = 2 if alt7 == 1: # interface.g:288:11: '*' mulValue= simpleExpression pass self.match(self.input, 32, self.FOLLOW_32_in_productExpression869) self._state.following.append(self.FOLLOW_simpleExpression_in_productExpression873) mulValue = self.simpleExpression() self._state.following.pop() #action start value *= mulValue #action end elif alt7 == 2: # interface.g:289:11: '/' divValue= simpleExpression pass self.match(self.input, 37, self.FOLLOW_37_in_productExpression887) self._state.following.append(self.FOLLOW_simpleExpression_in_productExpression891) divValue = self.simpleExpression() self._state.following.pop() #action start value /= divValue #action end else: break #loop7 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return value # $ANTLR end "productExpression" # $ANTLR start "sumExpression" # interface.g:293:1: sumExpression returns [value] : initialValue= productExpression ( '+' addValue= productExpression | '-' subValue= productExpression )* ; def sumExpression(self, ): value = None initialValue = None addValue = None subValue = None try: try: # interface.g:294:5: (initialValue= productExpression ( '+' addValue= productExpression | '-' subValue= productExpression )* ) # interface.g:294:7: initialValue= productExpression ( '+' addValue= productExpression | '-' subValue= productExpression )* pass self._state.following.append(self.FOLLOW_productExpression_in_sumExpression927) initialValue = self.productExpression() self._state.following.pop() #action start value = initialValue #action end # interface.g:295:9: ( '+' addValue= productExpression | '-' subValue= productExpression )* while True: #loop8 alt8 = 3 LA8_0 = self.input.LA(1) if (LA8_0 == 33) : alt8 = 1 elif (LA8_0 == 35) : alt8 = 2 if alt8 == 1: # interface.g:295:11: '+' addValue= productExpression pass self.match(self.input, 33, self.FOLLOW_33_in_sumExpression945) self._state.following.append(self.FOLLOW_productExpression_in_sumExpression949) addValue = self.productExpression() self._state.following.pop() #action start value += addValue #action end elif alt8 == 2: # interface.g:296:11: '-' subValue= productExpression pass self.match(self.input, 35, self.FOLLOW_35_in_sumExpression963) self._state.following.append(self.FOLLOW_productExpression_in_sumExpression967) subValue = self.productExpression() self._state.following.pop() #action start value -= subValue #action end else: break #loop8 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return value # $ANTLR end "sumExpression" # $ANTLR start "valueExpression" # interface.g:300:1: valueExpression returns [value] : ( sumExpression | QUOTED_STRING ); def valueExpression(self, ): value = None QUOTED_STRING15 = None sumExpression14 = None try: try: # interface.g:301:5: ( sumExpression | QUOTED_STRING ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == DEC_NUMBER or (HEX_NUMBER <= LA9_0 <= IDENTIFIER) or LA9_0 == SCOPED_IDENTIFIER or LA9_0 == 30 or LA9_0 == 33 or LA9_0 == 35) : alt9 = 1 elif (LA9_0 == QUOTED_STRING) : alt9 = 2 else: nvae = NoViableAltException("", 9, 0, self.input) raise nvae if alt9 == 1: # interface.g:301:7: sumExpression pass self._state.following.append(self.FOLLOW_sumExpression_in_valueExpression1001) sumExpression14 = self.sumExpression() self._state.following.pop() #action start value = sumExpression14 #action end elif alt9 == 2: # interface.g:302:7: QUOTED_STRING pass QUOTED_STRING15 = self.match(self.input, QUOTED_STRING, self.FOLLOW_QUOTED_STRING_in_valueExpression1014) #action start value = UnquoteString(QUOTED_STRING15.text) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return value # $ANTLR end "valueExpression" # $ANTLR start "arrayExpression" # interface.g:308:1: arrayExpression returns [size] : ( '[' simpleNumber ']' | '[' minSize= simpleNumber '..' maxSize= simpleNumber ']' ); def arrayExpression(self, ): size = None minSize = None maxSize = None simpleNumber16 = None try: try: # interface.g:309:5: ( '[' simpleNumber ']' | '[' minSize= simpleNumber '..' maxSize= simpleNumber ']' ) alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 39) : LA10 = self.input.LA(2) if LA10 == DEC_NUMBER: LA10_2 = self.input.LA(3) if (LA10_2 == 40) : alt10 = 1 elif (LA10_2 == 36) : alt10 = 2 else: nvae = NoViableAltException("", 10, 2, self.input) raise nvae elif LA10 == HEX_NUMBER: LA10_3 = self.input.LA(3) if (LA10_3 == 40) : alt10 = 1 elif (LA10_3 == 36) : alt10 = 2 else: nvae = NoViableAltException("", 10, 3, self.input) raise nvae elif LA10 == IDENTIFIER: LA10_4 = self.input.LA(3) if (LA10_4 == 40) : alt10 = 1 elif (LA10_4 == 36) : alt10 = 2 else: nvae = NoViableAltException("", 10, 4, self.input) raise nvae elif LA10 == SCOPED_IDENTIFIER: LA10_5 = self.input.LA(3) if (LA10_5 == 40) : alt10 = 1 elif (LA10_5 == 36) : alt10 = 2 else: nvae = NoViableAltException("", 10, 5, self.input) raise nvae else: nvae = NoViableAltException("", 10, 1, self.input) raise nvae else: nvae = NoViableAltException("", 10, 0, self.input) raise nvae if alt10 == 1: # interface.g:309:7: '[' simpleNumber ']' pass self.match(self.input, 39, self.FOLLOW_39_in_arrayExpression1043) self._state.following.append(self.FOLLOW_simpleNumber_in_arrayExpression1045) simpleNumber16 = self.simpleNumber() self._state.following.pop() self.match(self.input, 40, self.FOLLOW_40_in_arrayExpression1047) #action start size = ((simpleNumber16 is not None) and [simpleNumber16.value] or [None])[0] #action end elif alt10 == 2: # interface.g:311:7: '[' minSize= simpleNumber '..' maxSize= simpleNumber ']' pass self.match(self.input, 39, self.FOLLOW_39_in_arrayExpression1065) self._state.following.append(self.FOLLOW_simpleNumber_in_arrayExpression1069) minSize = self.simpleNumber() self._state.following.pop() self.match(self.input, 36, self.FOLLOW_36_in_arrayExpression1071) self._state.following.append(self.FOLLOW_simpleNumber_in_arrayExpression1075) maxSize = self.simpleNumber() self._state.following.pop() self.match(self.input, 40, self.FOLLOW_40_in_arrayExpression1077) #action start self.emitErrorMessage(self.getWarningHeaderForToken(minSize.start) + " Minimum lengths are deprecated and will be ignored.") size = ((maxSize is not None) and [maxSize.value] or [None])[0] #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return size # $ANTLR end "arrayExpression" # $ANTLR start "typeIdentifier" # interface.g:319:1: typeIdentifier returns [typeObj] : ( IDENTIFIER | SCOPED_IDENTIFIER ); def typeIdentifier(self, ): typeObj = None IDENTIFIER17 = None SCOPED_IDENTIFIER18 = None try: try: # interface.g:320:5: ( IDENTIFIER | SCOPED_IDENTIFIER ) alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == IDENTIFIER) : alt11 = 1 elif (LA11_0 == SCOPED_IDENTIFIER) : alt11 = 2 else: nvae = NoViableAltException("", 11, 0, self.input) raise nvae if alt11 == 1: # interface.g:320:7: IDENTIFIER pass IDENTIFIER17 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_typeIdentifier1108) #action start try: typeObj = self.iface.findType(IDENTIFIER17.text) except KeyError, e: self.compileErrors += 1 self.emitErrorMessage(self.getErrorHeaderForToken(IDENTIFIER17) + " Unknown type {}".format(e)) typeObj = interfaceIR.ERROR_TYPE #action end elif alt11 == 2: # interface.g:330:7: SCOPED_IDENTIFIER pass SCOPED_IDENTIFIER18 = self.match(self.input, SCOPED_IDENTIFIER, self.FOLLOW_SCOPED_IDENTIFIER_in_typeIdentifier1126) #action start try: typeObj = self.iface.findType(SCOPED_IDENTIFIER18.text) except KeyError, e: self.compileErrors += 1 self.emitErrorMessage(self.getErrorHeaderForToken(SCOPED_IDENTIFIER18) + " Unknown type {}".format(e)) typeObj = interfaceIR.ERROR_TYPE #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return typeObj # $ANTLR end "typeIdentifier" # $ANTLR start "docPostComments" # interface.g:342:1: docPostComments returns [comments] : ( DOC_POST_COMMENT )* ; def docPostComments(self, ): comments = None DOC_POST_COMMENT19 = None try: try: # interface.g:343:5: ( ( DOC_POST_COMMENT )* ) # interface.g:343:7: ( DOC_POST_COMMENT )* pass #action start comments = [] #action end # interface.g:344:7: ( DOC_POST_COMMENT )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == DOC_POST_COMMENT) : alt12 = 1 if alt12 == 1: # interface.g:344:9: DOC_POST_COMMENT pass DOC_POST_COMMENT19 = self.match(self.input, DOC_POST_COMMENT, self.FOLLOW_DOC_POST_COMMENT_in_docPostComments1167) #action start comments.append(StripPostComment(DOC_POST_COMMENT19.text)) #action end else: break #loop12 except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return comments # $ANTLR end "docPostComments" # $ANTLR start "docPreComment" # interface.g:349:1: docPreComment returns [comment] : DOC_PRE_COMMENT ; def docPreComment(self, ): comment = None DOC_PRE_COMMENT20 = None try: try: # interface.g:350:5: ( DOC_PRE_COMMENT ) # interface.g:350:7: DOC_PRE_COMMENT pass DOC_PRE_COMMENT20 = self.match(self.input, DOC_PRE_COMMENT, self.FOLLOW_DOC_PRE_COMMENT_in_docPreComment1211) #action start comment = StripPreComment(DOC_PRE_COMMENT20.text) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return comment # $ANTLR end "docPreComment" # $ANTLR start "defineDecl" # interface.g:353:1: defineDecl returns [define] : DEFINE IDENTIFIER '=' valueExpression ';' ; def defineDecl(self, ): define = None IDENTIFIER21 = None valueExpression22 = None try: try: # interface.g:354:5: ( DEFINE IDENTIFIER '=' valueExpression ';' ) # interface.g:354:7: DEFINE IDENTIFIER '=' valueExpression ';' pass self.match(self.input, DEFINE, self.FOLLOW_DEFINE_in_defineDecl1234) IDENTIFIER21 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_defineDecl1236) self.match(self.input, 38, self.FOLLOW_38_in_defineDecl1238) self._state.following.append(self.FOLLOW_valueExpression_in_defineDecl1240) valueExpression22 = self.valueExpression() self._state.following.pop() self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_defineDecl1242) #action start define = interfaceIR.Definition(IDENTIFIER21.text, self.getLocationTuple(IDENTIFIER21), valueExpression22) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return define # $ANTLR end "defineDecl" # $ANTLR start "namedValue" # interface.g:362:1: namedValue returns [namedValue] : IDENTIFIER ( '=' integer )? docPostComments ; def namedValue(self, ): namedValue = None IDENTIFIER23 = None integer24 = None docPostComments25 = None try: try: # interface.g:363:5: ( IDENTIFIER ( '=' integer )? docPostComments ) # interface.g:363:7: IDENTIFIER ( '=' integer )? docPostComments pass IDENTIFIER23 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_namedValue1273) # interface.g:363:18: ( '=' integer )? alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == 38) : alt13 = 1 if alt13 == 1: # interface.g:363:20: '=' integer pass self.match(self.input, 38, self.FOLLOW_38_in_namedValue1277) self._state.following.append(self.FOLLOW_integer_in_namedValue1279) integer24 = self.integer() self._state.following.pop() self._state.following.append(self.FOLLOW_docPostComments_in_namedValue1284) docPostComments25 = self.docPostComments() self._state.following.pop() #action start namedValue = interfaceIR.NamedValue(IDENTIFIER23.text, self.getLocationTuple(IDENTIFIER23), integer24) namedValue.comments = docPostComments25 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return namedValue # $ANTLR end "namedValue" # $ANTLR start "namedValueList" # interface.g:372:1: namedValueList returns [values] : (| namedValue | namedValue ',' docPostComments rest= namedValueList ); def namedValueList(self, ): values = None rest = None namedValue26 = None namedValue27 = None docPostComments28 = None try: try: # interface.g:373:5: (| namedValue | namedValue ',' docPostComments rest= namedValueList ) alt14 = 3 alt14 = self.dfa14.predict(self.input) if alt14 == 1: # interface.g:373:51: pass #action start values = [ ] #action end elif alt14 == 2: # interface.g:374:7: namedValue pass self._state.following.append(self.FOLLOW_namedValue_in_namedValueList1359) namedValue26 = self.namedValue() self._state.following.pop() #action start values = [ namedValue26 ] #action end elif alt14 == 3: # interface.g:375:7: namedValue ',' docPostComments rest= namedValueList pass self._state.following.append(self.FOLLOW_namedValue_in_namedValueList1402) namedValue27 = self.namedValue() self._state.following.pop() self.match(self.input, 34, self.FOLLOW_34_in_namedValueList1404) self._state.following.append(self.FOLLOW_docPostComments_in_namedValueList1406) docPostComments28 = self.docPostComments() self._state.following.pop() self._state.following.append(self.FOLLOW_namedValueList_in_namedValueList1410) rest = self.namedValueList() self._state.following.pop() #action start namedValue27.comments.extend(docPostComments28) values = [ namedValue27 ] values.extend(rest) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return values # $ANTLR end "namedValueList" # $ANTLR start "enumDecl" # interface.g:383:1: enumDecl returns [enum] : ENUM IDENTIFIER '{' namedValueList '}' ';' ; def enumDecl(self, ): enum = None IDENTIFIER29 = None namedValueList30 = None try: try: # interface.g:384:5: ( ENUM IDENTIFIER '{' namedValueList '}' ';' ) # interface.g:384:7: ENUM IDENTIFIER '{' namedValueList '}' ';' pass self.match(self.input, ENUM, self.FOLLOW_ENUM_in_enumDecl1441) IDENTIFIER29 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_enumDecl1443) self.match(self.input, 41, self.FOLLOW_41_in_enumDecl1445) self._state.following.append(self.FOLLOW_namedValueList_in_enumDecl1447) namedValueList30 = self.namedValueList() self._state.following.pop() self.match(self.input, 42, self.FOLLOW_42_in_enumDecl1449) self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_enumDecl1451) #action start enum = interfaceIR.EnumType(IDENTIFIER29.text, self.getLocationTuple(IDENTIFIER29), namedValueList30) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return enum # $ANTLR end "enumDecl" # $ANTLR start "bitmaskDecl" # interface.g:392:1: bitmaskDecl returns [bitmask] : BITMASK IDENTIFIER '{' namedValueList '}' ';' ; def bitmaskDecl(self, ): bitmask = None IDENTIFIER31 = None namedValueList32 = None try: try: # interface.g:393:5: ( BITMASK IDENTIFIER '{' namedValueList '}' ';' ) # interface.g:393:7: BITMASK IDENTIFIER '{' namedValueList '}' ';' pass self.match(self.input, BITMASK, self.FOLLOW_BITMASK_in_bitmaskDecl1482) IDENTIFIER31 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_bitmaskDecl1484) self.match(self.input, 41, self.FOLLOW_41_in_bitmaskDecl1486) self._state.following.append(self.FOLLOW_namedValueList_in_bitmaskDecl1488) namedValueList32 = self.namedValueList() self._state.following.pop() self.match(self.input, 42, self.FOLLOW_42_in_bitmaskDecl1490) self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_bitmaskDecl1492) #action start bitmask = interfaceIR.BitmaskType(IDENTIFIER31.text, self.getLocationTuple(IDENTIFIER31), namedValueList32) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return bitmask # $ANTLR end "bitmaskDecl" # $ANTLR start "referenceDecl" # interface.g:401:1: referenceDecl returns [ref] : REFERENCE IDENTIFIER ';' ; def referenceDecl(self, ): ref = None IDENTIFIER33 = None try: try: # interface.g:402:5: ( REFERENCE IDENTIFIER ';' ) # interface.g:402:7: REFERENCE IDENTIFIER ';' pass self.match(self.input, REFERENCE, self.FOLLOW_REFERENCE_in_referenceDecl1523) IDENTIFIER33 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_referenceDecl1525) self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_referenceDecl1527) #action start ref = interfaceIR.ReferenceType(IDENTIFIER33.text, self.getLocationTuple(IDENTIFIER33)) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return ref # $ANTLR end "referenceDecl" # $ANTLR start "compoundMember" # interface.g:409:1: compoundMember returns [member] : typeIdentifier IDENTIFIER ( arrayExpression )? ';' docPostComments ; def compoundMember(self, ): member = None IDENTIFIER35 = None typeIdentifier34 = None arrayExpression36 = None try: try: # interface.g:410:5: ( typeIdentifier IDENTIFIER ( arrayExpression )? ';' docPostComments ) # interface.g:410:7: typeIdentifier IDENTIFIER ( arrayExpression )? ';' docPostComments pass self._state.following.append(self.FOLLOW_typeIdentifier_in_compoundMember1558) typeIdentifier34 = self.typeIdentifier() self._state.following.pop() IDENTIFIER35 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_compoundMember1560) # interface.g:410:33: ( arrayExpression )? alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == 39) : alt15 = 1 if alt15 == 1: # interface.g:410:33: arrayExpression pass self._state.following.append(self.FOLLOW_arrayExpression_in_compoundMember1562) arrayExpression36 = self.arrayExpression() self._state.following.pop() self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_compoundMember1565) self._state.following.append(self.FOLLOW_docPostComments_in_compoundMember1567) self.docPostComments() self._state.following.pop() #action start if typeIdentifier34 == interfaceIR.OLD_HANDLER_TYPE or \ isinstance(typeIdentifier34, interfaceIR.HandlerReferenceType) or \ isinstance(typeIdentifier34, interfaceIR.HandlerType): self.compileErrors += 1 self.emitErrorMessage(self.getErrorHeaderForToken(typeIdentifier34) + " Cannot include handlers in a structure") member = None else: member = interfaceIR.MakeStructMember(self.iface, typeIdentifier34, IDENTIFIER35.text, self.getLocationTuple(IDENTIFIER35), arrayExpression36) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return member # $ANTLR end "compoundMember" # $ANTLR start "compoundMemberList" # interface.g:428:1: compoundMemberList returns [members] : ( compoundMember | compoundMember rest= compoundMemberList ); def compoundMemberList(self, ): members = None rest = None compoundMember37 = None compoundMember38 = None try: try: # interface.g:429:5: ( compoundMember | compoundMember rest= compoundMemberList ) alt16 = 2 alt16 = self.dfa16.predict(self.input) if alt16 == 1: # interface.g:429:7: compoundMember pass self._state.following.append(self.FOLLOW_compoundMember_in_compoundMemberList1598) compoundMember37 = self.compoundMember() self._state.following.pop() #action start members = [ compoundMember37 ] #action end elif alt16 == 2: # interface.g:430:7: compoundMember rest= compoundMemberList pass self._state.following.append(self.FOLLOW_compoundMember_in_compoundMemberList1627) compoundMember38 = self.compoundMember() self._state.following.pop() self._state.following.append(self.FOLLOW_compoundMemberList_in_compoundMemberList1631) rest = self.compoundMemberList() self._state.following.pop() #action start members = [ compoundMember38 ] members.extend(rest) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return members # $ANTLR end "compoundMemberList" # $ANTLR start "structDecl" # interface.g:437:1: structDecl returns [struct] : STRUCT IDENTIFIER '{' ( compoundMemberList )? '}' ';' ; def structDecl(self, ): struct = None IDENTIFIER39 = None compoundMemberList40 = None try: try: # interface.g:438:5: ( STRUCT IDENTIFIER '{' ( compoundMemberList )? '}' ';' ) # interface.g:438:7: STRUCT IDENTIFIER '{' ( compoundMemberList )? '}' ';' pass self.match(self.input, STRUCT, self.FOLLOW_STRUCT_in_structDecl1662) IDENTIFIER39 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_structDecl1664) self.match(self.input, 41, self.FOLLOW_41_in_structDecl1666) # interface.g:438:29: ( compoundMemberList )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == IDENTIFIER or LA17_0 == SCOPED_IDENTIFIER) : alt17 = 1 if alt17 == 1: # interface.g:438:29: compoundMemberList pass self._state.following.append(self.FOLLOW_compoundMemberList_in_structDecl1668) compoundMemberList40 = self.compoundMemberList() self._state.following.pop() self.match(self.input, 42, self.FOLLOW_42_in_structDecl1671) self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_structDecl1673) #action start struct = interfaceIR.StructType(IDENTIFIER39.text, self.getLocationTuple(IDENTIFIER39), compoundMemberList40) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return struct # $ANTLR end "structDecl" # $ANTLR start "formalParameter" # interface.g:446:1: formalParameter returns [parameter] : typeIdentifier IDENTIFIER ( arrayExpression )? ( direction )? docPostComments ; def formalParameter(self, ): parameter = None IDENTIFIER42 = None typeIdentifier41 = None arrayExpression43 = None direction44 = None docPostComments45 = None try: try: # interface.g:447:5: ( typeIdentifier IDENTIFIER ( arrayExpression )? ( direction )? docPostComments ) # interface.g:447:7: typeIdentifier IDENTIFIER ( arrayExpression )? ( direction )? docPostComments pass self._state.following.append(self.FOLLOW_typeIdentifier_in_formalParameter1704) typeIdentifier41 = self.typeIdentifier() self._state.following.pop() IDENTIFIER42 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_formalParameter1706) # interface.g:447:33: ( arrayExpression )? alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == 39) : alt18 = 1 if alt18 == 1: # interface.g:447:33: arrayExpression pass self._state.following.append(self.FOLLOW_arrayExpression_in_formalParameter1708) arrayExpression43 = self.arrayExpression() self._state.following.pop() # interface.g:447:50: ( direction )? alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == IN or LA19_0 == OUT) : alt19 = 1 if alt19 == 1: # interface.g:447:50: direction pass self._state.following.append(self.FOLLOW_direction_in_formalParameter1711) direction44 = self.direction() self._state.following.pop() self._state.following.append(self.FOLLOW_docPostComments_in_formalParameter1714) docPostComments45 = self.docPostComments() self._state.following.pop() #action start if typeIdentifier41 == interfaceIR.OLD_HANDLER_TYPE: self.emitErrorMessage(self.getWarningHeaderForToken(IDENTIFIER42) + " Parameters with type 'handler' are deprecated. " " Use the name of the handler instead: e.g. {} handler" .format(IDENTIFIER42.text)) parameter = interfaceIR.MakeParameter(self.iface, typeIdentifier41, IDENTIFIER42.text, self.getLocationTuple(IDENTIFIER42), arrayExpression43, direction44) parameter.comments = docPostComments45 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return parameter # $ANTLR end "formalParameter" # $ANTLR start "formalParameterList" # interface.g:465:1: formalParameterList returns [parameters] : ( formalParameter | formalParameter ',' docPostComments rest= formalParameterList ); def formalParameterList(self, ): parameters = None rest = None formalParameter46 = None formalParameter47 = None docPostComments48 = None try: try: # interface.g:466:5: ( formalParameter | formalParameter ',' docPostComments rest= formalParameterList ) alt20 = 2 alt20 = self.dfa20.predict(self.input) if alt20 == 1: # interface.g:466:7: formalParameter pass self._state.following.append(self.FOLLOW_formalParameter_in_formalParameterList1745) formalParameter46 = self.formalParameter() self._state.following.pop() #action start parameters = [ formalParameter46 ] #action end elif alt20 == 2: # interface.g:470:7: formalParameter ',' docPostComments rest= formalParameterList pass self._state.following.append(self.FOLLOW_formalParameter_in_formalParameterList1763) formalParameter47 = self.formalParameter() self._state.following.pop() self.match(self.input, 34, self.FOLLOW_34_in_formalParameterList1765) self._state.following.append(self.FOLLOW_docPostComments_in_formalParameterList1767) docPostComments48 = self.docPostComments() self._state.following.pop() self._state.following.append(self.FOLLOW_formalParameterList_in_formalParameterList1771) rest = self.formalParameterList() self._state.following.pop() #action start formalParameter47.comments.extend(docPostComments48) parameters = [ formalParameter47 ] parameters.extend(rest) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return parameters # $ANTLR end "formalParameterList" # $ANTLR start "functionDecl" # interface.g:478:1: functionDecl returns [function] : FUNCTION ( typeIdentifier )? IDENTIFIER '(' ( formalParameterList )? ')' ';' ; def functionDecl(self, ): function = None IDENTIFIER51 = None formalParameterList49 = None typeIdentifier50 = None try: try: # interface.g:479:5: ( FUNCTION ( typeIdentifier )? IDENTIFIER '(' ( formalParameterList )? ')' ';' ) # interface.g:479:7: FUNCTION ( typeIdentifier )? IDENTIFIER '(' ( formalParameterList )? ')' ';' pass self.match(self.input, FUNCTION, self.FOLLOW_FUNCTION_in_functionDecl1802) # interface.g:479:16: ( typeIdentifier )? alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == IDENTIFIER) : LA21_1 = self.input.LA(2) if (LA21_1 == IDENTIFIER) : alt21 = 1 elif (LA21_0 == SCOPED_IDENTIFIER) : alt21 = 1 if alt21 == 1: # interface.g:479:16: typeIdentifier pass self._state.following.append(self.FOLLOW_typeIdentifier_in_functionDecl1804) typeIdentifier50 = self.typeIdentifier() self._state.following.pop() IDENTIFIER51 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_functionDecl1807) self.match(self.input, 30, self.FOLLOW_30_in_functionDecl1809) # interface.g:479:47: ( formalParameterList )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == IDENTIFIER or LA22_0 == SCOPED_IDENTIFIER) : alt22 = 1 if alt22 == 1: # interface.g:479:47: formalParameterList pass self._state.following.append(self.FOLLOW_formalParameterList_in_functionDecl1811) formalParameterList49 = self.formalParameterList() self._state.following.pop() self.match(self.input, 31, self.FOLLOW_31_in_functionDecl1814) self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_functionDecl1816) #action start if formalParameterList49 == None: parameterList = [] else: parameterList = formalParameterList49 function = interfaceIR.Function(typeIdentifier50, IDENTIFIER51.text, self.getLocationTuple(IDENTIFIER51), parameterList) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return function # $ANTLR end "functionDecl" # $ANTLR start "handlerDecl" # interface.g:492:1: handlerDecl returns [handler] : HANDLER IDENTIFIER '(' ( formalParameterList )? ')' ';' ; def handlerDecl(self, ): handler = None IDENTIFIER53 = None formalParameterList52 = None try: try: # interface.g:493:5: ( HANDLER IDENTIFIER '(' ( formalParameterList )? ')' ';' ) # interface.g:493:7: HANDLER IDENTIFIER '(' ( formalParameterList )? ')' ';' pass self.match(self.input, HANDLER, self.FOLLOW_HANDLER_in_handlerDecl1847) IDENTIFIER53 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_handlerDecl1849) self.match(self.input, 30, self.FOLLOW_30_in_handlerDecl1851) # interface.g:493:30: ( formalParameterList )? alt23 = 2 LA23_0 = self.input.LA(1) if (LA23_0 == IDENTIFIER or LA23_0 == SCOPED_IDENTIFIER) : alt23 = 1 if alt23 == 1: # interface.g:493:30: formalParameterList pass self._state.following.append(self.FOLLOW_formalParameterList_in_handlerDecl1853) formalParameterList52 = self.formalParameterList() self._state.following.pop() self.match(self.input, 31, self.FOLLOW_31_in_handlerDecl1856) self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_handlerDecl1858) #action start if formalParameterList52 == None: parameterList = [] else: parameterList = formalParameterList52 handler = interfaceIR.HandlerType(IDENTIFIER53.text, self.getLocationTuple(IDENTIFIER53), parameterList) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return handler # $ANTLR end "handlerDecl" # $ANTLR start "eventDecl" # interface.g:505:1: eventDecl returns [event] : EVENT IDENTIFIER '(' ( formalParameterList )? ')' ';' ; def eventDecl(self, ): event = None IDENTIFIER55 = None formalParameterList54 = None try: try: # interface.g:506:5: ( EVENT IDENTIFIER '(' ( formalParameterList )? ')' ';' ) # interface.g:506:7: EVENT IDENTIFIER '(' ( formalParameterList )? ')' ';' pass self.match(self.input, EVENT, self.FOLLOW_EVENT_in_eventDecl1889) IDENTIFIER55 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_eventDecl1891) self.match(self.input, 30, self.FOLLOW_30_in_eventDecl1893) # interface.g:506:28: ( formalParameterList )? alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == IDENTIFIER or LA24_0 == SCOPED_IDENTIFIER) : alt24 = 1 if alt24 == 1: # interface.g:506:28: formalParameterList pass self._state.following.append(self.FOLLOW_formalParameterList_in_eventDecl1895) formalParameterList54 = self.formalParameterList() self._state.following.pop() self.match(self.input, 31, self.FOLLOW_31_in_eventDecl1898) self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_eventDecl1900) #action start if formalParameterList54 == None: parameterList = [] else: parameterList = formalParameterList54 event = interfaceIR.Event(IDENTIFIER55.text, self.getLocationTuple(IDENTIFIER55), parameterList) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return event # $ANTLR end "eventDecl" # $ANTLR start "declaration" # interface.g:518:1: declaration returns [declaration] : ( enumDecl | bitmaskDecl | referenceDecl | structDecl | functionDecl | handlerDecl | eventDecl | defineDecl ); def declaration(self, ): declaration = None enumDecl56 = None bitmaskDecl57 = None referenceDecl58 = None structDecl59 = None functionDecl60 = None handlerDecl61 = None eventDecl62 = None defineDecl63 = None try: try: # interface.g:519:5: ( enumDecl | bitmaskDecl | referenceDecl | structDecl | functionDecl | handlerDecl | eventDecl | defineDecl ) alt25 = 8 LA25 = self.input.LA(1) if LA25 == ENUM: alt25 = 1 elif LA25 == BITMASK: alt25 = 2 elif LA25 == REFERENCE: alt25 = 3 elif LA25 == STRUCT: alt25 = 4 elif LA25 == FUNCTION: alt25 = 5 elif LA25 == HANDLER: alt25 = 6 elif LA25 == EVENT: alt25 = 7 elif LA25 == DEFINE: alt25 = 8 else: nvae = NoViableAltException("", 25, 0, self.input) raise nvae if alt25 == 1: # interface.g:519:7: enumDecl pass self._state.following.append(self.FOLLOW_enumDecl_in_declaration1931) enumDecl56 = self.enumDecl() self._state.following.pop() #action start declaration = enumDecl56 #action end elif alt25 == 2: # interface.g:520:7: bitmaskDecl pass self._state.following.append(self.FOLLOW_bitmaskDecl_in_declaration1948) bitmaskDecl57 = self.bitmaskDecl() self._state.following.pop() #action start declaration = bitmaskDecl57 #action end elif alt25 == 3: # interface.g:521:7: referenceDecl pass self._state.following.append(self.FOLLOW_referenceDecl_in_declaration1962) referenceDecl58 = self.referenceDecl() self._state.following.pop() #action start declaration = referenceDecl58 #action end elif alt25 == 4: # interface.g:522:7: structDecl pass self._state.following.append(self.FOLLOW_structDecl_in_declaration1974) structDecl59 = self.structDecl() self._state.following.pop() #action start declaration = structDecl59 #action end elif alt25 == 5: # interface.g:523:7: functionDecl pass self._state.following.append(self.FOLLOW_functionDecl_in_declaration1989) functionDecl60 = self.functionDecl() self._state.following.pop() #action start declaration = functionDecl60 #action end elif alt25 == 6: # interface.g:524:7: handlerDecl pass self._state.following.append(self.FOLLOW_handlerDecl_in_declaration2002) handlerDecl61 = self.handlerDecl() self._state.following.pop() #action start declaration = handlerDecl61 #action end elif alt25 == 7: # interface.g:525:7: eventDecl pass self._state.following.append(self.FOLLOW_eventDecl_in_declaration2016) eventDecl62 = self.eventDecl() self._state.following.pop() #action start declaration = eventDecl62 #action end elif alt25 == 8: # interface.g:526:7: defineDecl pass self._state.following.append(self.FOLLOW_defineDecl_in_declaration2032) defineDecl63 = self.defineDecl() self._state.following.pop() #action start declaration = defineDecl63 #action end except RecognitionException, re: # Report recognition exceptions here with default handling. Do not want them to get caught # by generic handler below self.reportError(re) self.recover(self.input, re) except Exception, e: self.emitErrorMessage(self.getErrorHeaderForToken(self.getCurrentInputSymbol(self.input)) + " " + str(e)) self.compileErrors += 1 finally: pass return declaration # $ANTLR end "declaration" # $ANTLR start "documentedDeclaration" # interface.g:542:1: documentedDeclaration returns [declaration] : docPreComment declaration ; def documentedDeclaration(self, ): declaration = None declaration64 = None docPreComment65 = None try: try: # interface.g:543:5: ( docPreComment declaration ) # interface.g:543:7: docPreComment declaration pass self._state.following.append(self.FOLLOW_docPreComment_in_documentedDeclaration2072) docPreComment65 = self.docPreComment() self._state.following.pop() self._state.following.append(self.FOLLOW_declaration_in_documentedDeclaration2074) declaration64 = self.declaration() self._state.following.pop() #action start declaration = declaration64 if declaration: declaration.comment = docPreComment65 #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return declaration # $ANTLR end "documentedDeclaration" # $ANTLR start "filename" # interface.g:553:1: filename returns [filename] : ( IDENTIFIER | SCOPED_IDENTIFIER ); def filename(self, ): filename = None IDENTIFIER66 = None SCOPED_IDENTIFIER67 = None try: try: # interface.g:554:5: ( IDENTIFIER | SCOPED_IDENTIFIER ) alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == IDENTIFIER) : alt26 = 1 elif (LA26_0 == SCOPED_IDENTIFIER) : alt26 = 2 else: nvae = NoViableAltException("", 26, 0, self.input) raise nvae if alt26 == 1: # interface.g:554:7: IDENTIFIER pass IDENTIFIER66 = self.match(self.input, IDENTIFIER, self.FOLLOW_IDENTIFIER_in_filename2107) #action start filename = IDENTIFIER66.text #action end elif alt26 == 2: # interface.g:555:7: SCOPED_IDENTIFIER pass SCOPED_IDENTIFIER67 = self.match(self.input, SCOPED_IDENTIFIER, self.FOLLOW_SCOPED_IDENTIFIER_in_filename2125) #action start filename = SCOPED_IDENTIFIER67.text #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return filename # $ANTLR end "filename" # $ANTLR start "usetypesStmt" # interface.g:558:1: usetypesStmt : USETYPES filename ';' ; def usetypesStmt(self, ): filename68 = None try: try: # interface.g:559:5: ( USETYPES filename ';' ) # interface.g:559:7: USETYPES filename ';' pass self.match(self.input, USETYPES, self.FOLLOW_USETYPES_in_usetypesStmt2145) self._state.following.append(self.FOLLOW_filename_in_usetypesStmt2147) filename68 = self.filename() self._state.following.pop() self.match(self.input, SEMICOLON, self.FOLLOW_SEMICOLON_in_usetypesStmt2149) #action start if filename68.endswith(".api"): basename=filename68[:-4] fullFilename=filename68 else: basename=filename68 fullFilename=filename68 + ".api" self.iface.imports[basename] = ParseCode(fullFilename, self.searchPath) #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return # $ANTLR end "usetypesStmt" # $ANTLR start "apiDocument" # interface.g:575:1: apiDocument returns [iface] : ( ( docPreComment )+ ( usetypesStmt |firstDecl= documentedDeclaration ) )? ( usetypesStmt | declaration |laterDecl= documentedDeclaration )* EOF ; def apiDocument(self, ): iface = None firstDecl = None laterDecl = None docPreComment69 = None declaration70 = None try: try: # interface.g:576:5: ( ( ( docPreComment )+ ( usetypesStmt |firstDecl= documentedDeclaration ) )? ( usetypesStmt | declaration |laterDecl= documentedDeclaration )* EOF ) # interface.g:576:7: ( ( docPreComment )+ ( usetypesStmt |firstDecl= documentedDeclaration ) )? ( usetypesStmt | declaration |laterDecl= documentedDeclaration )* EOF pass # interface.g:576:7: ( ( docPreComment )+ ( usetypesStmt |firstDecl= documentedDeclaration ) )? alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == DOC_PRE_COMMENT) : LA29_1 = self.input.LA(2) if (LA29_1 == DOC_PRE_COMMENT or LA29_1 == USETYPES) : alt29 = 1 if alt29 == 1: # interface.g:576:9: ( docPreComment )+ ( usetypesStmt |firstDecl= documentedDeclaration ) pass # interface.g:576:9: ( docPreComment )+ cnt27 = 0 while True: #loop27 alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == DOC_PRE_COMMENT) : LA27_2 = self.input.LA(2) if (LA27_2 == DOC_PRE_COMMENT or LA27_2 == USETYPES) : alt27 = 1 if alt27 == 1: # interface.g:576:11: docPreComment pass self._state.following.append(self.FOLLOW_docPreComment_in_apiDocument2187) docPreComment69 = self.docPreComment() self._state.following.pop() #action start self.iface.comments.append(docPreComment69) #action end else: if cnt27 >= 1: break #loop27 eee = EarlyExitException(27, self.input) raise eee cnt27 += 1 # interface.g:577:13: ( usetypesStmt |firstDecl= documentedDeclaration ) alt28 = 2 LA28_0 = self.input.LA(1) if (LA28_0 == USETYPES) : alt28 = 1 elif (LA28_0 == DOC_PRE_COMMENT) : alt28 = 2 else: nvae = NoViableAltException("", 28, 0, self.input) raise nvae if alt28 == 1: # interface.g:577:16: usetypesStmt pass self._state.following.append(self.FOLLOW_usetypesStmt_in_apiDocument2209) self.usetypesStmt() self._state.following.pop() elif alt28 == 2: # interface.g:578:15: firstDecl= documentedDeclaration pass self._state.following.append(self.FOLLOW_documentedDeclaration_in_apiDocument2227) firstDecl = self.documentedDeclaration() self._state.following.pop() #action start if firstDecl: self.iface.addDeclaration(firstDecl) #action end # interface.g:584:7: ( usetypesStmt | declaration |laterDecl= documentedDeclaration )* while True: #loop30 alt30 = 4 LA30 = self.input.LA(1) if LA30 == USETYPES: alt30 = 1 elif LA30 == BITMASK or LA30 == DEFINE or LA30 == ENUM or LA30 == EVENT or LA30 == FUNCTION or LA30 == HANDLER or LA30 == REFERENCE or LA30 == STRUCT: alt30 = 2 elif LA30 == DOC_PRE_COMMENT: alt30 = 3 if alt30 == 1: # interface.g:584:9: usetypesStmt pass self._state.following.append(self.FOLLOW_usetypesStmt_in_apiDocument2266) self.usetypesStmt() self._state.following.pop() elif alt30 == 2: # interface.g:585:11: declaration pass self._state.following.append(self.FOLLOW_declaration_in_apiDocument2278) declaration70 = self.declaration() self._state.following.pop() #action start if declaration70: self.iface.addDeclaration(declaration70) #action end elif alt30 == 3: # interface.g:590:11: laterDecl= documentedDeclaration pass self._state.following.append(self.FOLLOW_documentedDeclaration_in_apiDocument2307) laterDecl = self.documentedDeclaration() self._state.following.pop() #action start if laterDecl: self.iface.addDeclaration(laterDecl) #action end else: break #loop30 self.match(self.input, EOF, self.FOLLOW_EOF_in_apiDocument2333) #action start iface = self.iface #action end except RecognitionException, re: self.reportError(re) self.recover(self.input, re) finally: pass return iface # $ANTLR end "apiDocument" # lookup tables for DFA #14 DFA14_eot = DFA.unpack( u"\15\uffff" ) DFA14_eof = DFA.unpack( u"\15\uffff" ) DFA14_min = DFA.unpack( u"\1\23\1\uffff\1\13\1\11\1\13\2\uffff\2\11\4\13" ) DFA14_max = DFA.unpack( u"\1\52\1\uffff\1\52\1\43\1\52\2\uffff\2\11\4\52" ) DFA14_accept = DFA.unpack( u"\1\uffff\1\1\3\uffff\1\2\1\3\6\uffff" ) DFA14_special = DFA.unpack( u"\15\uffff" ) DFA14_transition = [ DFA.unpack(u"\1\2\26\uffff\1\1"), DFA.unpack(u""), DFA.unpack(u"\1\4\26\uffff\1\6\3\uffff\1\3\3\uffff\1\5"), DFA.unpack(u"\1\11\10\uffff\1\12\16\uffff\1\7\1\uffff\1\10"), DFA.unpack(u"\1\4\26\uffff\1\6\7\uffff\1\5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\13"), DFA.unpack(u"\1\14"), DFA.unpack(u"\1\4\26\uffff\1\6\7\uffff\1\5"), DFA.unpack(u"\1\4\26\uffff\1\6\7\uffff\1\5"), DFA.unpack(u"\1\4\26\uffff\1\6\7\uffff\1\5"), DFA.unpack(u"\1\4\26\uffff\1\6\7\uffff\1\5") ] # class definition for DFA #14 class DFA14(DFA): pass # lookup tables for DFA #16 DFA16_eot = DFA.unpack( u"\24\uffff" ) DFA16_eof = DFA.unpack( u"\24\uffff" ) DFA16_min = DFA.unpack( u"\3\23\1\32\1\11\1\13\4\44\1\13\2\uffff\1\32\1\11\4\50\1\32" ) DFA16_max = DFA.unpack( u"\1\31\2\23\1\47\1\31\1\52\4\50\1\52\2\uffff\1\32\1\31\4\50\1\32" ) DFA16_accept = DFA.unpack( u"\13\uffff\1\1\1\2\7\uffff" ) DFA16_special = DFA.unpack( u"\24\uffff" ) DFA16_transition = [ DFA.unpack(u"\1\1\5\uffff\1\2"), DFA.unpack(u"\1\3"), DFA.unpack(u"\1\3"), DFA.unpack(u"\1\5\14\uffff\1\4"), DFA.unpack(u"\1\6\10\uffff\1\7\1\10\5\uffff\1\11"), DFA.unpack(u"\1\12\7\uffff\1\14\5\uffff\1\14\20\uffff\1\13"), DFA.unpack(u"\1\16\3\uffff\1\15"), DFA.unpack(u"\1\16\3\uffff\1\15"), DFA.unpack(u"\1\16\3\uffff\1\15"), DFA.unpack(u"\1\16\3\uffff\1\15"), DFA.unpack(u"\1\12\7\uffff\1\14\5\uffff\1\14\20\uffff\1\13"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\5"), DFA.unpack(u"\1\17\10\uffff\1\20\1\21\5\uffff\1\22"), DFA.unpack(u"\1\23"), DFA.unpack(u"\1\23"), DFA.unpack(u"\1\23"), DFA.unpack(u"\1\23"), DFA.unpack(u"\1\5") ] # class definition for DFA #16 class DFA16(DFA): pass # lookup tables for DFA #20 DFA20_eot = DFA.unpack( u"\25\uffff" ) DFA20_eof = DFA.unpack( u"\25\uffff" ) DFA20_min = DFA.unpack( u"\3\23\1\13\1\11\3\13\2\uffff\4\44\1\13\1\11\4\50\1\13" ) DFA20_max = DFA.unpack( u"\1\31\2\23\1\47\1\31\3\42\2\uffff\4\50\1\42\1\31\4\50\1\42" ) DFA20_accept = DFA.unpack( u"\10\uffff\1\1\1\2\13\uffff" ) DFA20_special = DFA.unpack( u"\25\uffff" ) DFA20_transition = [ DFA.unpack(u"\1\1\5\uffff\1\2"), DFA.unpack(u"\1\3"), DFA.unpack(u"\1\3"), DFA.unpack(u"\1\7\10\uffff\1\5\1\uffff\1\6\10\uffff\1\10\2\uffff" u"\1\11\4\uffff\1\4"), DFA.unpack(u"\1\12\10\uffff\1\13\1\14\5\uffff\1\15"), DFA.unpack(u"\1\7\23\uffff\1\10\2\uffff\1\11"), DFA.unpack(u"\1\7\23\uffff\1\10\2\uffff\1\11"), DFA.unpack(u"\1\7\23\uffff\1\10\2\uffff\1\11"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\17\3\uffff\1\16"), DFA.unpack(u"\1\17\3\uffff\1\16"), DFA.unpack(u"\1\17\3\uffff\1\16"), DFA.unpack(u"\1\17\3\uffff\1\16"), DFA.unpack(u"\1\7\10\uffff\1\5\1\uffff\1\6\10\uffff\1\10\2\uffff" u"\1\11"), DFA.unpack(u"\1\20\10\uffff\1\21\1\22\5\uffff\1\23"), DFA.unpack(u"\1\24"), DFA.unpack(u"\1\24"), DFA.unpack(u"\1\24"), DFA.unpack(u"\1\24"), DFA.unpack(u"\1\7\10\uffff\1\5\1\uffff\1\6\10\uffff\1\10\2\uffff" u"\1\11") ] # class definition for DFA #20 class DFA20(DFA): pass FOLLOW_IN_in_direction520 = frozenset([1]) FOLLOW_OUT_in_direction534 = frozenset([1]) FOLLOW_DEC_NUMBER_in_number562 = frozenset([1]) FOLLOW_HEX_NUMBER_in_number575 = frozenset([1]) FOLLOW_33_in_integer601 = frozenset([9]) FOLLOW_DEC_NUMBER_in_integer603 = frozenset([1]) FOLLOW_35_in_integer615 = frozenset([9]) FOLLOW_DEC_NUMBER_in_integer617 = frozenset([1]) FOLLOW_DEC_NUMBER_in_integer629 = frozenset([1]) FOLLOW_HEX_NUMBER_in_integer645 = frozenset([1]) FOLLOW_IDENTIFIER_in_defineValue674 = frozenset([1]) FOLLOW_SCOPED_IDENTIFIER_in_defineValue691 = frozenset([1]) FOLLOW_number_in_simpleNumber728 = frozenset([1]) FOLLOW_defineValue_in_simpleNumber749 = frozenset([1]) FOLLOW_integer_in_simpleExpression778 = frozenset([1]) FOLLOW_defineValue_in_simpleExpression802 = frozenset([1]) FOLLOW_30_in_simpleExpression822 = frozenset([9, 18, 19, 25, 30, 33, 35]) FOLLOW_sumExpression_in_simpleExpression824 = frozenset([31]) FOLLOW_31_in_simpleExpression826 = frozenset([1]) FOLLOW_simpleExpression_in_productExpression851 = frozenset([1, 32, 37]) FOLLOW_32_in_productExpression869 = frozenset([9, 18, 19, 25, 30, 33, 35]) FOLLOW_simpleExpression_in_productExpression873 = frozenset([1, 32, 37]) FOLLOW_37_in_productExpression887 = frozenset([9, 18, 19, 25, 30, 33, 35]) FOLLOW_simpleExpression_in_productExpression891 = frozenset([1, 32, 37]) FOLLOW_productExpression_in_sumExpression927 = frozenset([1, 33, 35]) FOLLOW_33_in_sumExpression945 = frozenset([9, 18, 19, 25, 30, 33, 35]) FOLLOW_productExpression_in_sumExpression949 = frozenset([1, 33, 35]) FOLLOW_35_in_sumExpression963 = frozenset([9, 18, 19, 25, 30, 33, 35]) FOLLOW_productExpression_in_sumExpression967 = frozenset([1, 33, 35]) FOLLOW_sumExpression_in_valueExpression1001 = frozenset([1]) FOLLOW_QUOTED_STRING_in_valueExpression1014 = frozenset([1]) FOLLOW_39_in_arrayExpression1043 = frozenset([9, 18, 19, 25]) FOLLOW_simpleNumber_in_arrayExpression1045 = frozenset([40]) FOLLOW_40_in_arrayExpression1047 = frozenset([1]) FOLLOW_39_in_arrayExpression1065 = frozenset([9, 18, 19, 25]) FOLLOW_simpleNumber_in_arrayExpression1069 = frozenset([36]) FOLLOW_36_in_arrayExpression1071 = frozenset([9, 18, 19, 25]) FOLLOW_simpleNumber_in_arrayExpression1075 = frozenset([40]) FOLLOW_40_in_arrayExpression1077 = frozenset([1]) FOLLOW_IDENTIFIER_in_typeIdentifier1108 = frozenset([1]) FOLLOW_SCOPED_IDENTIFIER_in_typeIdentifier1126 = frozenset([1]) FOLLOW_DOC_POST_COMMENT_in_docPostComments1167 = frozenset([1, 11]) FOLLOW_DOC_PRE_COMMENT_in_docPreComment1211 = frozenset([1]) FOLLOW_DEFINE_in_defineDecl1234 = frozenset([19]) FOLLOW_IDENTIFIER_in_defineDecl1236 = frozenset([38]) FOLLOW_38_in_defineDecl1238 = frozenset([9, 18, 19, 23, 25, 30, 33, 35]) FOLLOW_valueExpression_in_defineDecl1240 = frozenset([26]) FOLLOW_SEMICOLON_in_defineDecl1242 = frozenset([1]) FOLLOW_IDENTIFIER_in_namedValue1273 = frozenset([11, 38]) FOLLOW_38_in_namedValue1277 = frozenset([9, 18, 33, 35]) FOLLOW_integer_in_namedValue1279 = frozenset([11]) FOLLOW_docPostComments_in_namedValue1284 = frozenset([1]) FOLLOW_namedValue_in_namedValueList1359 = frozenset([1]) FOLLOW_namedValue_in_namedValueList1402 = frozenset([34]) FOLLOW_34_in_namedValueList1404 = frozenset([11, 19]) FOLLOW_docPostComments_in_namedValueList1406 = frozenset([19]) FOLLOW_namedValueList_in_namedValueList1410 = frozenset([1]) FOLLOW_ENUM_in_enumDecl1441 = frozenset([19]) FOLLOW_IDENTIFIER_in_enumDecl1443 = frozenset([41]) FOLLOW_41_in_enumDecl1445 = frozenset([19, 42]) FOLLOW_namedValueList_in_enumDecl1447 = frozenset([42]) FOLLOW_42_in_enumDecl1449 = frozenset([26]) FOLLOW_SEMICOLON_in_enumDecl1451 = frozenset([1]) FOLLOW_BITMASK_in_bitmaskDecl1482 = frozenset([19]) FOLLOW_IDENTIFIER_in_bitmaskDecl1484 = frozenset([41]) FOLLOW_41_in_bitmaskDecl1486 = frozenset([19, 42]) FOLLOW_namedValueList_in_bitmaskDecl1488 = frozenset([42]) FOLLOW_42_in_bitmaskDecl1490 = frozenset([26]) FOLLOW_SEMICOLON_in_bitmaskDecl1492 = frozenset([1]) FOLLOW_REFERENCE_in_referenceDecl1523 = frozenset([19]) FOLLOW_IDENTIFIER_in_referenceDecl1525 = frozenset([26]) FOLLOW_SEMICOLON_in_referenceDecl1527 = frozenset([1]) FOLLOW_typeIdentifier_in_compoundMember1558 = frozenset([19]) FOLLOW_IDENTIFIER_in_compoundMember1560 = frozenset([26, 39]) FOLLOW_arrayExpression_in_compoundMember1562 = frozenset([26]) FOLLOW_SEMICOLON_in_compoundMember1565 = frozenset([11]) FOLLOW_docPostComments_in_compoundMember1567 = frozenset([1]) FOLLOW_compoundMember_in_compoundMemberList1598 = frozenset([1]) FOLLOW_compoundMember_in_compoundMemberList1627 = frozenset([19, 25]) FOLLOW_compoundMemberList_in_compoundMemberList1631 = frozenset([1]) FOLLOW_STRUCT_in_structDecl1662 = frozenset([19]) FOLLOW_IDENTIFIER_in_structDecl1664 = frozenset([41]) FOLLOW_41_in_structDecl1666 = frozenset([19, 25, 42]) FOLLOW_compoundMemberList_in_structDecl1668 = frozenset([42]) FOLLOW_42_in_structDecl1671 = frozenset([26]) FOLLOW_SEMICOLON_in_structDecl1673 = frozenset([1]) FOLLOW_typeIdentifier_in_formalParameter1704 = frozenset([19]) FOLLOW_IDENTIFIER_in_formalParameter1706 = frozenset([11, 20, 22, 39]) FOLLOW_arrayExpression_in_formalParameter1708 = frozenset([11, 20, 22]) FOLLOW_direction_in_formalParameter1711 = frozenset([11]) FOLLOW_docPostComments_in_formalParameter1714 = frozenset([1]) FOLLOW_formalParameter_in_formalParameterList1745 = frozenset([1]) FOLLOW_formalParameter_in_formalParameterList1763 = frozenset([34]) FOLLOW_34_in_formalParameterList1765 = frozenset([11, 19, 25]) FOLLOW_docPostComments_in_formalParameterList1767 = frozenset([19, 25]) FOLLOW_formalParameterList_in_formalParameterList1771 = frozenset([1]) FOLLOW_FUNCTION_in_functionDecl1802 = frozenset([19, 25]) FOLLOW_typeIdentifier_in_functionDecl1804 = frozenset([19]) FOLLOW_IDENTIFIER_in_functionDecl1807 = frozenset([30]) FOLLOW_30_in_functionDecl1809 = frozenset([19, 25, 31]) FOLLOW_formalParameterList_in_functionDecl1811 = frozenset([31]) FOLLOW_31_in_functionDecl1814 = frozenset([26]) FOLLOW_SEMICOLON_in_functionDecl1816 = frozenset([1]) FOLLOW_HANDLER_in_handlerDecl1847 = frozenset([19]) FOLLOW_IDENTIFIER_in_handlerDecl1849 = frozenset([30]) FOLLOW_30_in_handlerDecl1851 = frozenset([19, 25, 31]) FOLLOW_formalParameterList_in_handlerDecl1853 = frozenset([31]) FOLLOW_31_in_handlerDecl1856 = frozenset([26]) FOLLOW_SEMICOLON_in_handlerDecl1858 = frozenset([1]) FOLLOW_EVENT_in_eventDecl1889 = frozenset([19]) FOLLOW_IDENTIFIER_in_eventDecl1891 = frozenset([30]) FOLLOW_30_in_eventDecl1893 = frozenset([19, 25, 31]) FOLLOW_formalParameterList_in_eventDecl1895 = frozenset([31]) FOLLOW_31_in_eventDecl1898 = frozenset([26]) FOLLOW_SEMICOLON_in_eventDecl1900 = frozenset([1]) FOLLOW_enumDecl_in_declaration1931 = frozenset([1]) FOLLOW_bitmaskDecl_in_declaration1948 = frozenset([1]) FOLLOW_referenceDecl_in_declaration1962 = frozenset([1]) FOLLOW_structDecl_in_declaration1974 = frozenset([1]) FOLLOW_functionDecl_in_declaration1989 = frozenset([1]) FOLLOW_handlerDecl_in_declaration2002 = frozenset([1]) FOLLOW_eventDecl_in_declaration2016 = frozenset([1]) FOLLOW_defineDecl_in_declaration2032 = frozenset([1]) FOLLOW_docPreComment_in_documentedDeclaration2072 = frozenset([6, 10, 13, 14, 15, 16, 24, 27]) FOLLOW_declaration_in_documentedDeclaration2074 = frozenset([1]) FOLLOW_IDENTIFIER_in_filename2107 = frozenset([1]) FOLLOW_SCOPED_IDENTIFIER_in_filename2125 = frozenset([1]) FOLLOW_USETYPES_in_usetypesStmt2145 = frozenset([19, 25]) FOLLOW_filename_in_usetypesStmt2147 = frozenset([26]) FOLLOW_SEMICOLON_in_usetypesStmt2149 = frozenset([1]) FOLLOW_docPreComment_in_apiDocument2187 = frozenset([12, 28]) FOLLOW_usetypesStmt_in_apiDocument2209 = frozenset([6, 10, 12, 13, 14, 15, 16, 24, 27, 28]) FOLLOW_documentedDeclaration_in_apiDocument2227 = frozenset([6, 10, 12, 13, 14, 15, 16, 24, 27, 28]) FOLLOW_usetypesStmt_in_apiDocument2266 = frozenset([6, 10, 12, 13, 14, 15, 16, 24, 27, 28]) FOLLOW_declaration_in_apiDocument2278 = frozenset([6, 10, 12, 13, 14, 15, 16, 24, 27, 28]) FOLLOW_documentedDeclaration_in_apiDocument2307 = frozenset([6, 10, 12, 13, 14, 15, 16, 24, 27, 28]) FOLLOW_EOF_in_apiDocument2333 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("interfaceLexer", interfaceParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) def ParseCode(apiFile, searchPath=[], ifaceName=None): if os.path.isabs(apiFile) or os.path.isfile(apiFile): apiPath = apiFile else: for path in searchPath: apiPath = os.path.join(path, apiFile) if os.path.isfile(apiPath): break else: # File not found in search path. Try as a relative path. # This will usually fail since the current directory should be in the search # path but at least will raise a reasonable exception apiPath = apiFile fileStream = ANTLRFileStream(apiPath, 'utf-8') lexer = interfaceLexer(fileStream) tokens = CommonTokenStream(lexer) parser = interfaceParser(tokens) parser.searchPath=searchPath baseName = os.path.splitext(os.path.basename(apiPath))[0] if ifaceName == None: parser.iface.name = baseName else: parser.iface.name = ifaceName parser.iface.baseName = baseName parser.iface.path = apiPath iface = parser.apiDocument() if (parser.getNumberOfSyntaxErrors() > 0 or parser.compileErrors > 0): return None if tokens.getTokens(): iface.text= ''.join([ token.text for token in tokens.getTokens() if token.type not in frozenset([ C_COMMENT, CPP_COMMENT, DOC_PRE_COMMENT, DOC_POST_COMMENT ]) ]) return iface if __name__ == '__main__': main(sys.argv)
{ "repo_name": "legatoproject/legato-af", "path": "framework/tools/ifgen/interfaceParser.py", "copies": "1", "size": "95887", "license": "mpl-2.0", "hash": 986767977394333000, "line_mean": 30.2641017281, "line_max": 201, "alpha_frac": 0.5170669642, "autogenerated": false, "ratio": 4.165739855765054, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5182806819965053, "avg_score": null, "num_lines": null }
# $ANTLR 3.5.2 interface.g 2019-06-25 12:24:53 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__30=30 T__31=31 T__32=32 T__33=33 T__34=34 T__35=35 T__36=36 T__37=37 T__38=38 T__39=39 T__40=40 T__41=41 T__42=42 ALPHA=4 ALPHANUM=5 BITMASK=6 CPP_COMMENT=7 C_COMMENT=8 DEC_NUMBER=9 DEFINE=10 DOC_POST_COMMENT=11 DOC_PRE_COMMENT=12 ENUM=13 EVENT=14 FUNCTION=15 HANDLER=16 HEXNUM=17 HEX_NUMBER=18 IDENTIFIER=19 IN=20 NUM=21 OUT=22 QUOTED_STRING=23 REFERENCE=24 SCOPED_IDENTIFIER=25 SEMICOLON=26 STRUCT=27 USETYPES=28 WS=29 class interfaceLexer(Lexer): grammarFileName = "interface.g" api_version = 1 def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(interfaceLexer, self).__init__(input, state) self.delegates = [] self.dfa13 = self.DFA13( self, 13, eot = self.DFA13_eot, eof = self.DFA13_eof, min = self.DFA13_min, max = self.DFA13_max, accept = self.DFA13_accept, special = self.DFA13_special, transition = self.DFA13_transition ) self.dfa16 = self.DFA16( self, 16, eot = self.DFA16_eot, eof = self.DFA16_eof, min = self.DFA16_min, max = self.DFA16_max, accept = self.DFA16_accept, special = self.DFA16_special, transition = self.DFA16_transition ) def getErrorHeader(self, e): """ What is the error header, normally line/character position information? """ source_name = self.getSourceName() if source_name is not None: return "{}:{}:{}: error:".format(source_name, e.line, e.charPositionInLine) return "{}:{}: error:".format(e.line, e.charPositionInLine) def getErrorMessage(self, e, tokenNames): """Give more user-friendly error messages for some lexing errors""" if isinstance(e, NoViableAltException): return "Unexpected character " + self.getCharErrorDisplay(e.c) else: return super(interfaceLexer, self).getErrorMessage(e, tokenNames) # $ANTLR start "T__30" def mT__30(self, ): try: _type = T__30 _channel = DEFAULT_CHANNEL # interface.g:27:7: ( '(' ) # interface.g:27:9: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__30" # $ANTLR start "T__31" def mT__31(self, ): try: _type = T__31 _channel = DEFAULT_CHANNEL # interface.g:28:7: ( ')' ) # interface.g:28:9: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__31" # $ANTLR start "T__32" def mT__32(self, ): try: _type = T__32 _channel = DEFAULT_CHANNEL # interface.g:29:7: ( '*' ) # interface.g:29:9: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__32" # $ANTLR start "T__33" def mT__33(self, ): try: _type = T__33 _channel = DEFAULT_CHANNEL # interface.g:30:7: ( '+' ) # interface.g:30:9: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__33" # $ANTLR start "T__34" def mT__34(self, ): try: _type = T__34 _channel = DEFAULT_CHANNEL # interface.g:31:7: ( ',' ) # interface.g:31:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__34" # $ANTLR start "T__35" def mT__35(self, ): try: _type = T__35 _channel = DEFAULT_CHANNEL # interface.g:32:7: ( '-' ) # interface.g:32:9: '-' pass self.match(45) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__35" # $ANTLR start "T__36" def mT__36(self, ): try: _type = T__36 _channel = DEFAULT_CHANNEL # interface.g:33:7: ( '..' ) # interface.g:33:9: '..' pass self.match("..") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__36" # $ANTLR start "T__37" def mT__37(self, ): try: _type = T__37 _channel = DEFAULT_CHANNEL # interface.g:34:7: ( '/' ) # interface.g:34:9: '/' pass self.match(47) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__37" # $ANTLR start "T__38" def mT__38(self, ): try: _type = T__38 _channel = DEFAULT_CHANNEL # interface.g:35:7: ( '=' ) # interface.g:35:9: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__38" # $ANTLR start "T__39" def mT__39(self, ): try: _type = T__39 _channel = DEFAULT_CHANNEL # interface.g:36:7: ( '[' ) # interface.g:36:9: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__39" # $ANTLR start "T__40" def mT__40(self, ): try: _type = T__40 _channel = DEFAULT_CHANNEL # interface.g:37:7: ( ']' ) # interface.g:37:9: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__40" # $ANTLR start "T__41" def mT__41(self, ): try: _type = T__41 _channel = DEFAULT_CHANNEL # interface.g:38:7: ( '{' ) # interface.g:38:9: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__41" # $ANTLR start "T__42" def mT__42(self, ): try: _type = T__42 _channel = DEFAULT_CHANNEL # interface.g:39:7: ( '}' ) # interface.g:39:9: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__42" # $ANTLR start "ALPHA" def mALPHA(self, ): try: # interface.g:182:16: ( 'a' .. 'z' | 'A' .. 'Z' ) # interface.g: pass if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "ALPHA" # $ANTLR start "NUM" def mNUM(self, ): try: # interface.g:183:14: ( '0' .. '9' ) # interface.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "NUM" # $ANTLR start "HEXNUM" def mHEXNUM(self, ): try: # interface.g:184:17: ( NUM | 'a' .. 'f' | 'A' .. 'F' ) # interface.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "HEXNUM" # $ANTLR start "ALPHANUM" def mALPHANUM(self, ): try: # interface.g:185:19: ( ALPHA | NUM ) # interface.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "ALPHANUM" # $ANTLR start "SEMICOLON" def mSEMICOLON(self, ): try: _type = SEMICOLON _channel = DEFAULT_CHANNEL # interface.g:191:11: ( ';' ) # interface.g:191:13: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SEMICOLON" # $ANTLR start "IN" def mIN(self, ): try: _type = IN _channel = DEFAULT_CHANNEL # interface.g:194:4: ( 'IN' ) # interface.g:194:6: 'IN' pass self.match("IN") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IN" # $ANTLR start "OUT" def mOUT(self, ): try: _type = OUT _channel = DEFAULT_CHANNEL # interface.g:195:5: ( 'OUT' ) # interface.g:195:7: 'OUT' pass self.match("OUT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "OUT" # $ANTLR start "FUNCTION" def mFUNCTION(self, ): try: _type = FUNCTION _channel = DEFAULT_CHANNEL # interface.g:196:10: ( 'FUNCTION' ) # interface.g:196:12: 'FUNCTION' pass self.match("FUNCTION") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FUNCTION" # $ANTLR start "HANDLER" def mHANDLER(self, ): try: _type = HANDLER _channel = DEFAULT_CHANNEL # interface.g:197:9: ( 'HANDLER' ) # interface.g:197:11: 'HANDLER' pass self.match("HANDLER") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "HANDLER" # $ANTLR start "EVENT" def mEVENT(self, ): try: _type = EVENT _channel = DEFAULT_CHANNEL # interface.g:198:7: ( 'EVENT' ) # interface.g:198:9: 'EVENT' pass self.match("EVENT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EVENT" # $ANTLR start "REFERENCE" def mREFERENCE(self, ): try: _type = REFERENCE _channel = DEFAULT_CHANNEL # interface.g:199:11: ( 'REFERENCE' ) # interface.g:199:13: 'REFERENCE' pass self.match("REFERENCE") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "REFERENCE" # $ANTLR start "DEFINE" def mDEFINE(self, ): try: _type = DEFINE _channel = DEFAULT_CHANNEL # interface.g:200:8: ( 'DEFINE' ) # interface.g:200:10: 'DEFINE' pass self.match("DEFINE") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DEFINE" # $ANTLR start "ENUM" def mENUM(self, ): try: _type = ENUM _channel = DEFAULT_CHANNEL # interface.g:201:6: ( 'ENUM' ) # interface.g:201:8: 'ENUM' pass self.match("ENUM") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ENUM" # $ANTLR start "BITMASK" def mBITMASK(self, ): try: _type = BITMASK _channel = DEFAULT_CHANNEL # interface.g:202:9: ( 'BITMASK' ) # interface.g:202:11: 'BITMASK' pass self.match("BITMASK") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BITMASK" # $ANTLR start "STRUCT" def mSTRUCT(self, ): try: _type = STRUCT _channel = DEFAULT_CHANNEL # interface.g:203:8: ( 'STRUCT' ) # interface.g:203:10: 'STRUCT' pass self.match("STRUCT") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRUCT" # $ANTLR start "USETYPES" def mUSETYPES(self, ): try: _type = USETYPES _channel = DEFAULT_CHANNEL # interface.g:204:10: ( 'USETYPES' ) # interface.g:204:12: 'USETYPES' pass self.match("USETYPES") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "USETYPES" # $ANTLR start "IDENTIFIER" def mIDENTIFIER(self, ): try: _type = IDENTIFIER _channel = DEFAULT_CHANNEL # interface.g:208:12: ( ALPHA ( ALPHANUM | '_' )* ) # interface.g:208:14: ALPHA ( ALPHANUM | '_' )* pass self.mALPHA() # interface.g:208:20: ( ALPHANUM | '_' )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if ((48 <= LA1_0 <= 57) or (65 <= LA1_0 <= 90) or LA1_0 == 95 or (97 <= LA1_0 <= 122)) : alt1 = 1 if alt1 == 1: # interface.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "IDENTIFIER" # $ANTLR start "SCOPED_IDENTIFIER" def mSCOPED_IDENTIFIER(self, ): try: _type = SCOPED_IDENTIFIER _channel = DEFAULT_CHANNEL # interface.g:211:19: ( IDENTIFIER '.' IDENTIFIER ) # interface.g:211:21: IDENTIFIER '.' IDENTIFIER pass self.mIDENTIFIER() self.match(46) self.mIDENTIFIER() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SCOPED_IDENTIFIER" # $ANTLR start "DEC_NUMBER" def mDEC_NUMBER(self, ): try: _type = DEC_NUMBER _channel = DEFAULT_CHANNEL number = None # interface.g:214:12: (number= ( '0' | '1' .. '9' ( NUM )* ) ) # interface.g:214:14: number= ( '0' | '1' .. '9' ( NUM )* ) pass # interface.g:214:21: ( '0' | '1' .. '9' ( NUM )* ) alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == 48) : alt3 = 1 elif ((49 <= LA3_0 <= 57)) : alt3 = 2 else: nvae = NoViableAltException("", 3, 0, self.input) raise nvae if alt3 == 1: # interface.g:214:23: '0' pass number = self.input.LA(1) self.match(48) elif alt3 == 2: # interface.g:214:29: '1' .. '9' ( NUM )* pass number = self.input.LA(1) self.matchRange(49, 57) # interface.g:214:38: ( NUM )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((48 <= LA2_0 <= 57)) : alt2 = 1 if alt2 == 1: # interface.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop2 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DEC_NUMBER" # $ANTLR start "HEX_NUMBER" def mHEX_NUMBER(self, ): try: _type = HEX_NUMBER _channel = DEFAULT_CHANNEL # interface.g:214:12: ( '0' ( 'x' | 'X' ) ( HEXNUM )+ ) # interface.g:214:14: '0' ( 'x' | 'X' ) ( HEXNUM )+ pass self.match(48) if self.input.LA(1) == 88 or self.input.LA(1) == 120: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # interface.g:214:31: ( HEXNUM )+ cnt4 = 0 while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if ((48 <= LA4_0 <= 57) or (65 <= LA4_0 <= 70) or (97 <= LA4_0 <= 102)) : alt4 = 1 if alt4 == 1: # interface.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt4 >= 1: break #loop4 eee = EarlyExitException(4, self.input) raise eee cnt4 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "HEX_NUMBER" # $ANTLR start "QUOTED_STRING" def mQUOTED_STRING(self, ): try: _type = QUOTED_STRING _channel = DEFAULT_CHANNEL # interface.g:217:15: ( '\"' (~ ( '\\\"' | '\\\\' ) | '\\\\' . )* '\"' | '\\'' (~ ( '\\'' | '\\\\' ) | '\\\\' . )* '\\'' ) alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 34) : alt7 = 1 elif (LA7_0 == 39) : alt7 = 2 else: nvae = NoViableAltException("", 7, 0, self.input) raise nvae if alt7 == 1: # interface.g:217:17: '\"' (~ ( '\\\"' | '\\\\' ) | '\\\\' . )* '\"' pass self.match(34) # interface.g:217:21: (~ ( '\\\"' | '\\\\' ) | '\\\\' . )* while True: #loop5 alt5 = 3 LA5_0 = self.input.LA(1) if ((0 <= LA5_0 <= 33) or (35 <= LA5_0 <= 91) or (93 <= LA5_0 <= 65535)) : alt5 = 1 elif (LA5_0 == 92) : alt5 = 2 if alt5 == 1: # interface.g:217:23: ~ ( '\\\"' | '\\\\' ) pass if (0 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt5 == 2: # interface.g:217:40: '\\\\' . pass self.match(92) self.matchAny() else: break #loop5 self.match(34) elif alt7 == 2: # interface.g:218:7: '\\'' (~ ( '\\'' | '\\\\' ) | '\\\\' . )* '\\'' pass self.match(39) # interface.g:218:12: (~ ( '\\'' | '\\\\' ) | '\\\\' . )* while True: #loop6 alt6 = 3 LA6_0 = self.input.LA(1) if ((0 <= LA6_0 <= 38) or (40 <= LA6_0 <= 91) or (93 <= LA6_0 <= 65535)) : alt6 = 1 elif (LA6_0 == 92) : alt6 = 2 if alt6 == 1: # interface.g:218:14: ~ ( '\\'' | '\\\\' ) pass if (0 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt6 == 2: # interface.g:218:31: '\\\\' . pass self.match(92) self.matchAny() else: break #loop6 self.match(39) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "QUOTED_STRING" # $ANTLR start "DOC_PRE_COMMENT" def mDOC_PRE_COMMENT(self, ): try: _type = DOC_PRE_COMMENT _channel = DEFAULT_CHANNEL # interface.g:222:17: ( '/**' ~ '*' (~ '*' | ( '*' )+ ~ ( '/' | '*' ) )+ '*/' ) # interface.g:222:19: '/**' ~ '*' (~ '*' | ( '*' )+ ~ ( '/' | '*' ) )+ '*/' pass self.match("/**") if (0 <= self.input.LA(1) <= 41) or (43 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # interface.g:222:30: (~ '*' | ( '*' )+ ~ ( '/' | '*' ) )+ cnt9 = 0 while True: #loop9 alt9 = 3 LA9_0 = self.input.LA(1) if (LA9_0 == 42) : LA9_1 = self.input.LA(2) if ((0 <= LA9_1 <= 46) or (48 <= LA9_1 <= 65535)) : alt9 = 2 elif ((0 <= LA9_0 <= 41) or (43 <= LA9_0 <= 65535)) : alt9 = 1 if alt9 == 1: # interface.g:222:31: ~ '*' pass if (0 <= self.input.LA(1) <= 41) or (43 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt9 == 2: # interface.g:222:38: ( '*' )+ ~ ( '/' | '*' ) pass # interface.g:222:38: ( '*' )+ cnt8 = 0 while True: #loop8 alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == 42) : alt8 = 1 if alt8 == 1: # interface.g:222:38: '*' pass self.match(42) else: if cnt8 >= 1: break #loop8 eee = EarlyExitException(8, self.input) raise eee cnt8 += 1 if (0 <= self.input.LA(1) <= 41) or (43 <= self.input.LA(1) <= 46) or (48 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt9 >= 1: break #loop9 eee = EarlyExitException(9, self.input) raise eee cnt9 += 1 self.match("*/") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOC_PRE_COMMENT" # $ANTLR start "DOC_POST_COMMENT" def mDOC_POST_COMMENT(self, ): try: _type = DOC_POST_COMMENT _channel = DEFAULT_CHANNEL # interface.g:225:18: ( '///<' (~ '\\n' )* ) # interface.g:225:20: '///<' (~ '\\n' )* pass self.match("///<") # interface.g:225:27: (~ '\\n' )* while True: #loop10 alt10 = 2 LA10_0 = self.input.LA(1) if ((0 <= LA10_0 <= 9) or (11 <= LA10_0 <= 65535)) : alt10 = 1 if alt10 == 1: # interface.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop10 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "DOC_POST_COMMENT" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # interface.g:228:4: ( ( ' ' | '\\t' | '\\n' )+ ) # interface.g:228:6: ( ' ' | '\\t' | '\\n' )+ pass # interface.g:228:6: ( ' ' | '\\t' | '\\n' )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((9 <= LA11_0 <= 10) or LA11_0 == 32) : alt11 = 1 if alt11 == 1: # interface.g: pass if (9 <= self.input.LA(1) <= 10) or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 #action start self.skip() #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "C_COMMENT" def mC_COMMENT(self, ): try: _type = C_COMMENT _channel = DEFAULT_CHANNEL # interface.g:231:11: ( '/*' (~ '*' | ( '*' )+ ~ ( '/' | '*' ) )+ ( '*' )+ '/' ) # interface.g:231:13: '/*' (~ '*' | ( '*' )+ ~ ( '/' | '*' ) )+ ( '*' )+ '/' pass self.match("/*") # interface.g:231:18: (~ '*' | ( '*' )+ ~ ( '/' | '*' ) )+ cnt13 = 0 while True: #loop13 alt13 = 3 alt13 = self.dfa13.predict(self.input) if alt13 == 1: # interface.g:231:19: ~ '*' pass if (0 <= self.input.LA(1) <= 41) or (43 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt13 == 2: # interface.g:231:26: ( '*' )+ ~ ( '/' | '*' ) pass # interface.g:231:26: ( '*' )+ cnt12 = 0 while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == 42) : alt12 = 1 if alt12 == 1: # interface.g:231:26: '*' pass self.match(42) else: if cnt12 >= 1: break #loop12 eee = EarlyExitException(12, self.input) raise eee cnt12 += 1 if (0 <= self.input.LA(1) <= 41) or (43 <= self.input.LA(1) <= 46) or (48 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt13 >= 1: break #loop13 eee = EarlyExitException(13, self.input) raise eee cnt13 += 1 # interface.g:231:47: ( '*' )+ cnt14 = 0 while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == 42) : alt14 = 1 if alt14 == 1: # interface.g:231:47: '*' pass self.match(42) else: if cnt14 >= 1: break #loop14 eee = EarlyExitException(14, self.input) raise eee cnt14 += 1 self.match(47) #action start self.skip() #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "C_COMMENT" # $ANTLR start "CPP_COMMENT" def mCPP_COMMENT(self, ): try: _type = CPP_COMMENT _channel = DEFAULT_CHANNEL # interface.g:234:13: ( '//' (~ '\\n' )* ) # interface.g:234:15: '//' (~ '\\n' )* pass self.match("//") # interface.g:234:20: (~ '\\n' )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if ((0 <= LA15_0 <= 9) or (11 <= LA15_0 <= 65535)) : alt15 = 1 if alt15 == 1: # interface.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop15 #action start self.skip() #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "CPP_COMMENT" def mTokens(self): # interface.g:1:8: ( T__30 | T__31 | T__32 | T__33 | T__34 | T__35 | T__36 | T__37 | T__38 | T__39 | T__40 | T__41 | T__42 | SEMICOLON | IN | OUT | FUNCTION | HANDLER | EVENT | REFERENCE | DEFINE | ENUM | BITMASK | STRUCT | USETYPES | IDENTIFIER | SCOPED_IDENTIFIER | DEC_NUMBER | HEX_NUMBER | QUOTED_STRING | DOC_PRE_COMMENT | DOC_POST_COMMENT | WS | C_COMMENT | CPP_COMMENT ) alt16 = 35 alt16 = self.dfa16.predict(self.input) if alt16 == 1: # interface.g:1:10: T__30 pass self.mT__30() elif alt16 == 2: # interface.g:1:16: T__31 pass self.mT__31() elif alt16 == 3: # interface.g:1:22: T__32 pass self.mT__32() elif alt16 == 4: # interface.g:1:28: T__33 pass self.mT__33() elif alt16 == 5: # interface.g:1:34: T__34 pass self.mT__34() elif alt16 == 6: # interface.g:1:40: T__35 pass self.mT__35() elif alt16 == 7: # interface.g:1:46: T__36 pass self.mT__36() elif alt16 == 8: # interface.g:1:52: T__37 pass self.mT__37() elif alt16 == 9: # interface.g:1:58: T__38 pass self.mT__38() elif alt16 == 10: # interface.g:1:64: T__39 pass self.mT__39() elif alt16 == 11: # interface.g:1:70: T__40 pass self.mT__40() elif alt16 == 12: # interface.g:1:76: T__41 pass self.mT__41() elif alt16 == 13: # interface.g:1:82: T__42 pass self.mT__42() elif alt16 == 14: # interface.g:1:88: SEMICOLON pass self.mSEMICOLON() elif alt16 == 15: # interface.g:1:98: IN pass self.mIN() elif alt16 == 16: # interface.g:1:101: OUT pass self.mOUT() elif alt16 == 17: # interface.g:1:105: FUNCTION pass self.mFUNCTION() elif alt16 == 18: # interface.g:1:114: HANDLER pass self.mHANDLER() elif alt16 == 19: # interface.g:1:122: EVENT pass self.mEVENT() elif alt16 == 20: # interface.g:1:128: REFERENCE pass self.mREFERENCE() elif alt16 == 21: # interface.g:1:138: DEFINE pass self.mDEFINE() elif alt16 == 22: # interface.g:1:145: ENUM pass self.mENUM() elif alt16 == 23: # interface.g:1:150: BITMASK pass self.mBITMASK() elif alt16 == 24: # interface.g:1:158: STRUCT pass self.mSTRUCT() elif alt16 == 25: # interface.g:1:165: USETYPES pass self.mUSETYPES() elif alt16 == 26: # interface.g:1:174: IDENTIFIER pass self.mIDENTIFIER() elif alt16 == 27: # interface.g:1:185: SCOPED_IDENTIFIER pass self.mSCOPED_IDENTIFIER() elif alt16 == 28: # interface.g:1:203: DEC_NUMBER pass self.mDEC_NUMBER() elif alt16 == 29: # interface.g:1:214: HEX_NUMBER pass self.mHEX_NUMBER() elif alt16 == 30: # interface.g:1:225: QUOTED_STRING pass self.mQUOTED_STRING() elif alt16 == 31: # interface.g:1:239: DOC_PRE_COMMENT pass self.mDOC_PRE_COMMENT() elif alt16 == 32: # interface.g:1:255: DOC_POST_COMMENT pass self.mDOC_POST_COMMENT() elif alt16 == 33: # interface.g:1:272: WS pass self.mWS() elif alt16 == 34: # interface.g:1:275: C_COMMENT pass self.mC_COMMENT() elif alt16 == 35: # interface.g:1:285: CPP_COMMENT pass self.mCPP_COMMENT() # lookup tables for DFA #13 DFA13_eot = DFA.unpack( u"\5\uffff" ) DFA13_eof = DFA.unpack( u"\5\uffff" ) DFA13_min = DFA.unpack( u"\2\0\3\uffff" ) DFA13_max = DFA.unpack( u"\2\uffff\3\uffff" ) DFA13_accept = DFA.unpack( u"\2\uffff\1\1\1\3\1\2" ) DFA13_special = DFA.unpack( u"\1\1\1\0\3\uffff" ) DFA13_transition = [ DFA.unpack(u"\52\2\1\1\uffd5\2"), DFA.unpack(u"\52\4\1\1\4\4\1\3\uffd0\4"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #13 class DFA13(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA13_1 = input.LA(1) s = -1 if (LA13_1 == 47): s = 3 elif (LA13_1 == 42): s = 1 elif ((0 <= LA13_1 <= 41) or (43 <= LA13_1 <= 46) or (48 <= LA13_1 <= 65535)): s = 4 if s >= 0: return s elif s == 1: LA13_0 = input.LA(1) s = -1 if (LA13_0 == 42): s = 1 elif ((0 <= LA13_0 <= 41) or (43 <= LA13_0 <= 65535)): s = 2 if s >= 0: return s nvae = NoViableAltException(self_.getDescription(), 13, _s, input) self_.error(nvae) raise nvae # lookup tables for DFA #16 DFA16_eot = DFA.unpack( u"\10\uffff\1\40\6\uffff\13\42\1\33\4\uffff\1\63\1\uffff\1\64\1\uffff" u"\1\42\1\uffff\12\42\3\uffff\1\63\2\uffff\1\102\11\42\2\uffff\1" u"\117\1\uffff\3\42\1\123\5\42\2\uffff\1\117\1\uffff\2\42\1\135\1" u"\uffff\5\42\2\uffff\2\42\1\uffff\1\42\1\147\1\42\1\151\1\42\1\uffff" u"\1\42\1\154\1\42\1\uffff\1\156\1\uffff\1\42\1\160\1\uffff\1\42" u"\1\uffff\1\162\1\uffff\1\163\2\uffff" ) DFA16_eof = DFA.unpack( u"\164\uffff" ) DFA16_min = DFA.unpack( u"\1\11\7\uffff\1\52\6\uffff\13\56\1\130\3\uffff\1\0\1\57\1\uffff" u"\1\56\1\uffff\1\56\1\uffff\12\56\1\uffff\1\0\1\uffff\1\74\2\uffff" u"\12\56\1\0\1\uffff\1\0\1\uffff\11\56\3\0\1\uffff\3\56\1\uffff\5" u"\56\2\0\2\56\1\uffff\5\56\1\uffff\3\56\1\uffff\1\56\1\uffff\2\56" u"\1\uffff\1\56\1\uffff\1\56\1\uffff\1\56\2\uffff" ) DFA16_max = DFA.unpack( u"\1\175\7\uffff\1\57\6\uffff\13\172\1\170\3\uffff\1\uffff\1\57\1" u"\uffff\1\172\1\uffff\1\172\1\uffff\12\172\1\uffff\1\uffff\1\uffff" u"\1\74\2\uffff\12\172\1\uffff\1\uffff\1\uffff\1\uffff\11\172\3\uffff" u"\1\uffff\3\172\1\uffff\5\172\2\uffff\2\172\1\uffff\5\172\1\uffff" u"\3\172\1\uffff\1\172\1\uffff\2\172\1\uffff\1\172\1\uffff\1\172" u"\1\uffff\1\172\2\uffff" ) DFA16_accept = DFA.unpack( u"\1\uffff\1\1\1\2\1\3\1\4\1\5\1\6\1\7\1\uffff\1\11\1\12\1\13\1\14" u"\1\15\1\16\14\uffff\1\34\1\36\1\41\2\uffff\1\10\1\uffff\1\32\1" u"\uffff\1\33\12\uffff\1\35\1\uffff\1\42\1\uffff\1\43\1\17\13\uffff" u"\1\37\1\uffff\1\20\14\uffff\1\40\3\uffff\1\26\11\uffff\1\23\5\uffff" u"\1\37\3\uffff\1\25\1\uffff\1\30\2\uffff\1\22\1\uffff\1\27\1\uffff" u"\1\21\1\uffff\1\31\1\24" ) DFA16_special = DFA.unpack( u"\36\uffff\1\10\21\uffff\1\6\16\uffff\1\5\1\uffff\1\3\12\uffff\1" u"\0\1\7\1\4\12\uffff\1\1\1\2\31\uffff" ) DFA16_transition = [ DFA.unpack(u"\2\35\25\uffff\1\35\1\uffff\1\34\4\uffff\1\34\1\1\1" u"\2\1\3\1\4\1\5\1\6\1\7\1\10\1\32\11\33\1\uffff\1\16\1\uffff\1\11" u"\3\uffff\1\31\1\26\1\31\1\25\1\23\1\21\1\31\1\22\1\17\5\31\1\20" u"\2\31\1\24\1\27\1\31\1\30\5\31\1\12\1\uffff\1\13\3\uffff\32\31" u"\1\14\1\uffff\1\15"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\36\4\uffff\1\37"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\15\43\1\41\14\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\24\43\1\45\5\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\24\43\1\46\5\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\1\47\31\43\4\uffff\1\43" u"\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\15\43\1\51\7\43\1\50\4" u"\43\4\uffff\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\52\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\53\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\10\43\1\54\21\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\23\43\1\55\6\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\22\43\1\56\7\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u"\1\57\37\uffff\1\57"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\52\61\1\60\uffd5\61"), DFA.unpack(u"\1\62"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\23\43\1\65\6\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\15\43\1\66\14\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\15\43\1\67\14\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\70\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\24\43\1\71\5\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\5\43\1\72\24\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\5\43\1\73\24\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\23\43\1\74\6\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\21\43\1\75\10\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\76\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u""), DFA.unpack(u"\52\77\1\61\4\77\1\100\uffd0\77"), DFA.unpack(u""), DFA.unpack(u"\1\101"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\2\43\1\103\27\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\3\43\1\104\26\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\15\43\1\105\14\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\14\43\1\106\15\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\107\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\10\43\1\110\21\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\14\43\1\111\15\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\24\43\1\112\5\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\23\43\1\113\6\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\52\114\1\115\uffd5\114"), DFA.unpack(u""), DFA.unpack(u"\12\116\1\uffff\ufff5\116"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\23\43\1\120\6\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\13\43\1\121\16\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\23\43\1\122\6\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\21\43\1\124\10\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\15\43\1\125\14\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\1\126\31\43\4\uffff\1\43" u"\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\2\43\1\127\27\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\30\43\1\130\1\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\52\114\1\131\uffd5\114"), DFA.unpack(u"\52\132\1\115\4\132\1\61\uffd0\132"), DFA.unpack(u"\12\116\1\uffff\ufff5\116"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\10\43\1\133\21\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\134\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\136\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\137\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\22\43\1\140\7\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\23\43\1\141\6\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\17\43\1\142\12\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\52\132\1\115\4\132\1\143\uffd0\132"), DFA.unpack(u"\52\114\1\131\uffd5\114"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\16\43\1\144\13\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\21\43\1\145\10\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\15\43\1\146\14\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\12\43\1\150\17\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\152\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\15\43\1\153\14\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\2\43\1\155\27\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\22\43\1\157\7\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\4\43\1\161\25\43\4\uffff" u"\1\43\1\uffff\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u""), DFA.unpack(u"\1\44\1\uffff\12\43\7\uffff\32\43\4\uffff\1\43\1\uffff" u"\32\43"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #16 class DFA16(DFA): pass def specialStateTransition(self_, s, input): # convince pylint that my self_ magic is ok ;) # pylint: disable-msg=E0213 # pretend we are a member of the recognizer # thus semantic predicates can be evaluated self = self_.recognizer _s = s if s == 0: LA16_76 = input.LA(1) s = -1 if (LA16_76 == 42): s = 89 elif ((0 <= LA16_76 <= 41) or (43 <= LA16_76 <= 65535)): s = 76 if s >= 0: return s elif s == 1: LA16_89 = input.LA(1) s = -1 if (LA16_89 == 47): s = 99 elif ((0 <= LA16_89 <= 41) or (43 <= LA16_89 <= 46) or (48 <= LA16_89 <= 65535)): s = 90 elif (LA16_89 == 42): s = 77 if s >= 0: return s elif s == 2: LA16_90 = input.LA(1) s = -1 if (LA16_90 == 42): s = 89 elif ((0 <= LA16_90 <= 41) or (43 <= LA16_90 <= 65535)): s = 76 if s >= 0: return s elif s == 3: LA16_65 = input.LA(1) s = -1 if ((0 <= LA16_65 <= 9) or (11 <= LA16_65 <= 65535)): s = 78 else: s = 79 if s >= 0: return s elif s == 4: LA16_78 = input.LA(1) s = -1 if ((0 <= LA16_78 <= 9) or (11 <= LA16_78 <= 65535)): s = 78 else: s = 79 if s >= 0: return s elif s == 5: LA16_63 = input.LA(1) s = -1 if ((0 <= LA16_63 <= 41) or (43 <= LA16_63 <= 65535)): s = 76 elif (LA16_63 == 42): s = 77 if s >= 0: return s elif s == 6: LA16_48 = input.LA(1) s = -1 if ((0 <= LA16_48 <= 41) or (43 <= LA16_48 <= 46) or (48 <= LA16_48 <= 65535)): s = 63 elif (LA16_48 == 47): s = 64 elif (LA16_48 == 42): s = 49 if s >= 0: return s elif s == 7: LA16_77 = input.LA(1) s = -1 if ((0 <= LA16_77 <= 41) or (43 <= LA16_77 <= 46) or (48 <= LA16_77 <= 65535)): s = 90 elif (LA16_77 == 42): s = 77 elif (LA16_77 == 47): s = 49 if s >= 0: return s elif s == 8: LA16_30 = input.LA(1) s = -1 if (LA16_30 == 42): s = 48 elif ((0 <= LA16_30 <= 41) or (43 <= LA16_30 <= 65535)): s = 49 if s >= 0: return s nvae = NoViableAltException(self_.getDescription(), 16, _s, input) self_.error(nvae) raise nvae def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(interfaceLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "legatoproject/legato-af", "path": "framework/tools/ifgen/interfaceLexer.py", "copies": "1", "size": "54588", "license": "mpl-2.0", "hash": -5986520868943103000, "line_mean": 23.3914209115, "line_max": 385, "alpha_frac": 0.4181688283, "autogenerated": false, "ratio": 3.208416598095686, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.908891121386961, "avg_score": 0.007534842505215078, "num_lines": 2238 }
# $ANTLR 3.5 Expr.g 2013-04-12 19:22:24 import sys from antlr3 import * from antlr3.compat import set, frozenset from antlr3.tree import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__68=68 T__69=69 T__70=70 T__71=71 T__72=72 T__73=73 T__74=74 T__75=75 T__76=76 T__77=77 T__78=78 T__79=79 T__80=80 T__81=81 T__82=82 T__83=83 T__84=84 T__85=85 T__86=86 T__87=87 T__88=88 T__89=89 T__90=90 T__91=91 T__92=92 T__93=93 T__94=94 T__95=95 T__96=96 T__97=97 T__98=98 T__99=99 T__100=100 T__101=101 T__102=102 T__103=103 T__104=104 T__105=105 T__106=106 T__107=107 T__108=108 T__109=109 T__110=110 T__111=111 T__112=112 T__113=113 T__114=114 T__115=115 T__116=116 T__117=117 T__118=118 T__119=119 T__120=120 T__121=121 T__122=122 T__123=123 T__124=124 T__125=125 T__126=126 T__127=127 T__128=128 T__129=129 T__130=130 T__131=131 T__132=132 T__133=133 T__134=134 T__135=135 T__136=136 ALPHA=4 ARRAY=5 ASSIGN=6 BLOCK=7 BOOL=8 BREAK=9 CALL=10 CASE=11 CATCH=12 CLASS=13 COMMENT=14 CONSTRUCTOR=15 CONTINUE=16 DEFAULT=17 DIGIT=18 DOUBLE_QUOTE_CHARS=19 DO_WHILE=20 EACH=21 EACH_VAL=22 ELSE=23 ELSE_IF=24 EMPTY_LINE=25 EXEC_LIST=26 EXEC_STMT=27 EXPR_LIST=28 FINALLY=29 FLOAT=30 FOR=31 FOREACH=32 FUNCTION=33 ID=34 ID_LIST=35 IF=36 IMPORT=37 INDEX=38 INT=39 LINECOMMENT=40 MEMBER=41 MODULE=42 NEGATIVE=43 NEW=44 NEWLINE=45 NOP=46 NULL=47 OBJECT=48 OP_ASSIGN=49 PARAMS=50 POST_DEC=51 POST_INC=52 PRE_DEC=53 PRE_INC=54 PRINT=55 PRINTF=56 RETURN=57 SINGLE_QUOTE_CHARS=58 SLICE=59 SPRINTF=60 STRING=61 SWITCH=62 THROW=63 TRY=64 VAR=65 WHILE=66 WS=67 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "ALPHA", "ARRAY", "ASSIGN", "BLOCK", "BOOL", "BREAK", "CALL", "CASE", "CATCH", "CLASS", "COMMENT", "CONSTRUCTOR", "CONTINUE", "DEFAULT", "DIGIT", "DOUBLE_QUOTE_CHARS", "DO_WHILE", "EACH", "EACH_VAL", "ELSE", "ELSE_IF", "EMPTY_LINE", "EXEC_LIST", "EXEC_STMT", "EXPR_LIST", "FINALLY", "FLOAT", "FOR", "FOREACH", "FUNCTION", "ID", "ID_LIST", "IF", "IMPORT", "INDEX", "INT", "LINECOMMENT", "MEMBER", "MODULE", "NEGATIVE", "NEW", "NEWLINE", "NOP", "NULL", "OBJECT", "OP_ASSIGN", "PARAMS", "POST_DEC", "POST_INC", "PRE_DEC", "PRE_INC", "PRINT", "PRINTF", "RETURN", "SINGLE_QUOTE_CHARS", "SLICE", "SPRINTF", "STRING", "SWITCH", "THROW", "TRY", "VAR", "WHILE", "WS", "'!'", "'!='", "'%'", "'%='", "'&&'", "'&'", "'&='", "'('", "')'", "'*'", "'*='", "'+'", "'++'", "'+='", "','", "'-'", "'--'", "'-='", "'.'", "'.*'", "'..'", "'/'", "'/='", "':'", "';'", "'<'", "'<='", "'='", "'=='", "'=>'", "'>'", "'>='", "'['", "']'", "'^'", "'^='", "'as'", "'break'", "'case'", "'catch'", "'class'", "'continue'", "'default'", "'do'", "'else'", "'extends'", "'finally'", "'for'", "'foreach'", "'function'", "'if'", "'import'", "'init'", "'new'", "'print'", "'printf'", "'public'", "'return'", "'sprintf'", "'static'", "'switch'", "'throw'", "'try'", "'while'", "'{'", "'|'", "'|='", "'||'", "'}'" ] class ExprParser(Parser): grammarFileName = "Expr.g" api_version = 1 tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(ExprParser, self).__init__(input, state, *args, **kwargs) self.dfa6 = self.DFA6( self, 6, eot = self.DFA6_eot, eof = self.DFA6_eof, min = self.DFA6_min, max = self.DFA6_max, accept = self.DFA6_accept, special = self.DFA6_special, transition = self.DFA6_transition ) self.delegates = [] self._adaptor = None self.adaptor = CommonTreeAdaptor() def getTreeAdaptor(self): return self._adaptor def setTreeAdaptor(self, adaptor): self._adaptor = adaptor adaptor = property(getTreeAdaptor, setTreeAdaptor) class prog_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.prog_return, self).__init__() self.tree = None # $ANTLR start "prog" # Expr.g:33:1: prog : ( EOF -> NOP | ( stmt )* ); def prog(self, ): retval = self.prog_return() retval.start = self.input.LT(1) root_0 = None EOF1 = None stmt2 = None EOF1_tree = None stream_EOF = RewriteRuleTokenStream(self._adaptor, "token EOF") try: try: # Expr.g:34:2: ( EOF -> NOP | ( stmt )* ) alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == EOF) : LA2_1 = self.input.LA(2) if (LA2_1 == EOF) : alt2 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 2, 1, self.input) raise nvae elif (LA2_0 == ID or LA2_0 == 80 or LA2_0 == 84 or LA2_0 == 92 or LA2_0 == 105 or (108 <= LA2_0 <= 109) or LA2_0 == 111 or (115 <= LA2_0 <= 119) or (122 <= LA2_0 <= 123) or LA2_0 == 125 or (128 <= LA2_0 <= 131)) : alt2 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # Expr.g:34:4: EOF pass EOF1 = self.match(self.input, EOF, self.FOLLOW_EOF_in_prog211) if self._state.backtracking == 0: stream_EOF.add(EOF1) # AST Rewrite # elements: # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 34:8: -> NOP self._adaptor.addChild(root_0, self._adaptor.createFromType(NOP, "NOP") ) retval.tree = root_0 elif alt2 == 2: # Expr.g:35:4: ( stmt )* pass root_0 = self._adaptor.nil() # Expr.g:35:4: ( stmt )* while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == ID or LA1_0 == 80 or LA1_0 == 84 or LA1_0 == 92 or LA1_0 == 105 or (108 <= LA1_0 <= 109) or LA1_0 == 111 or (115 <= LA1_0 <= 119) or (122 <= LA1_0 <= 123) or LA1_0 == 125 or (128 <= LA1_0 <= 131)) : alt1 = 1 if alt1 == 1: # Expr.g:35:4: stmt pass self._state.following.append(self.FOLLOW_stmt_in_prog220) stmt2 = self.stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, stmt2.tree) else: break #loop1 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "prog" class stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.stmt_return, self).__init__() self.tree = None # $ANTLR start "stmt" # Expr.g:38:1: stmt : ( ';' ->| exec_stmt | import_stmt | print_stmt | printf_stmt | break_stmt | continue_stmt | return_stmt | if_stmt | while_stmt | do_while_stmt | switch_stmt | for_stmt | foreach_stmt | throw_stmt | try_stmt | func_decl | class_decl ); def stmt(self, ): retval = self.stmt_return() retval.start = self.input.LT(1) root_0 = None char_literal3 = None exec_stmt4 = None import_stmt5 = None print_stmt6 = None printf_stmt7 = None break_stmt8 = None continue_stmt9 = None return_stmt10 = None if_stmt11 = None while_stmt12 = None do_while_stmt13 = None switch_stmt14 = None for_stmt15 = None foreach_stmt16 = None throw_stmt17 = None try_stmt18 = None func_decl19 = None class_decl20 = None char_literal3_tree = None stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") try: try: # Expr.g:39:2: ( ';' ->| exec_stmt | import_stmt | print_stmt | printf_stmt | break_stmt | continue_stmt | return_stmt | if_stmt | while_stmt | do_while_stmt | switch_stmt | for_stmt | foreach_stmt | throw_stmt | try_stmt | func_decl | class_decl ) alt3 = 18 LA3 = self.input.LA(1) if LA3 == 92: alt3 = 1 elif LA3 == ID or LA3 == 80 or LA3 == 84: alt3 = 2 elif LA3 == 119: alt3 = 3 elif LA3 == 122: alt3 = 4 elif LA3 == 123: alt3 = 5 elif LA3 == 105: alt3 = 6 elif LA3 == 109: alt3 = 7 elif LA3 == 125: alt3 = 8 elif LA3 == 118: alt3 = 9 elif LA3 == 131: alt3 = 10 elif LA3 == 111: alt3 = 11 elif LA3 == 128: alt3 = 12 elif LA3 == 115: alt3 = 13 elif LA3 == 116: alt3 = 14 elif LA3 == 129: alt3 = 15 elif LA3 == 130: alt3 = 16 elif LA3 == 117: alt3 = 17 elif LA3 == 108: alt3 = 18 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 3, 0, self.input) raise nvae if alt3 == 1: # Expr.g:39:4: ';' pass char_literal3 = self.match(self.input, 92, self.FOLLOW_92_in_stmt232) if self._state.backtracking == 0: stream_92.add(char_literal3) # AST Rewrite # elements: # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 39:8: -> root_0 = None retval.tree = root_0 elif alt3 == 2: # Expr.g:40:4: exec_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_exec_stmt_in_stmt239) exec_stmt4 = self.exec_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, exec_stmt4.tree) elif alt3 == 3: # Expr.g:41:4: import_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_import_stmt_in_stmt244) import_stmt5 = self.import_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, import_stmt5.tree) elif alt3 == 4: # Expr.g:42:4: print_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_print_stmt_in_stmt249) print_stmt6 = self.print_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, print_stmt6.tree) elif alt3 == 5: # Expr.g:42:17: printf_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_printf_stmt_in_stmt253) printf_stmt7 = self.printf_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, printf_stmt7.tree) elif alt3 == 6: # Expr.g:43:4: break_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_break_stmt_in_stmt258) break_stmt8 = self.break_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, break_stmt8.tree) elif alt3 == 7: # Expr.g:44:4: continue_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_continue_stmt_in_stmt263) continue_stmt9 = self.continue_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, continue_stmt9.tree) elif alt3 == 8: # Expr.g:45:4: return_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_return_stmt_in_stmt268) return_stmt10 = self.return_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, return_stmt10.tree) elif alt3 == 9: # Expr.g:46:4: if_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_if_stmt_in_stmt273) if_stmt11 = self.if_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, if_stmt11.tree) elif alt3 == 10: # Expr.g:47:4: while_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_while_stmt_in_stmt278) while_stmt12 = self.while_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, while_stmt12.tree) elif alt3 == 11: # Expr.g:48:4: do_while_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_do_while_stmt_in_stmt283) do_while_stmt13 = self.do_while_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, do_while_stmt13.tree) elif alt3 == 12: # Expr.g:49:4: switch_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_switch_stmt_in_stmt288) switch_stmt14 = self.switch_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, switch_stmt14.tree) elif alt3 == 13: # Expr.g:50:4: for_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_for_stmt_in_stmt293) for_stmt15 = self.for_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, for_stmt15.tree) elif alt3 == 14: # Expr.g:51:4: foreach_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_foreach_stmt_in_stmt298) foreach_stmt16 = self.foreach_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, foreach_stmt16.tree) elif alt3 == 15: # Expr.g:52:4: throw_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_throw_stmt_in_stmt303) throw_stmt17 = self.throw_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, throw_stmt17.tree) elif alt3 == 16: # Expr.g:53:4: try_stmt pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_try_stmt_in_stmt308) try_stmt18 = self.try_stmt() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, try_stmt18.tree) elif alt3 == 17: # Expr.g:54:4: func_decl pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_func_decl_in_stmt313) func_decl19 = self.func_decl() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, func_decl19.tree) elif alt3 == 18: # Expr.g:55:4: class_decl pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_class_decl_in_stmt318) class_decl20 = self.class_decl() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, class_decl20.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "stmt" class block_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.block_return, self).__init__() self.tree = None # $ANTLR start "block" # Expr.g:59:1: block : '{' ( stmt )* '}' -> ^( BLOCK ( stmt )* ) ; def block(self, ): retval = self.block_return() retval.start = self.input.LT(1) root_0 = None char_literal21 = None char_literal23 = None stmt22 = None char_literal21_tree = None char_literal23_tree = None stream_132 = RewriteRuleTokenStream(self._adaptor, "token 132") stream_136 = RewriteRuleTokenStream(self._adaptor, "token 136") stream_stmt = RewriteRuleSubtreeStream(self._adaptor, "rule stmt") try: try: # Expr.g:60:2: ( '{' ( stmt )* '}' -> ^( BLOCK ( stmt )* ) ) # Expr.g:60:4: '{' ( stmt )* '}' pass char_literal21 = self.match(self.input, 132, self.FOLLOW_132_in_block331) if self._state.backtracking == 0: stream_132.add(char_literal21) # Expr.g:60:8: ( stmt )* while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == ID or LA4_0 == 80 or LA4_0 == 84 or LA4_0 == 92 or LA4_0 == 105 or (108 <= LA4_0 <= 109) or LA4_0 == 111 or (115 <= LA4_0 <= 119) or (122 <= LA4_0 <= 123) or LA4_0 == 125 or (128 <= LA4_0 <= 131)) : alt4 = 1 if alt4 == 1: # Expr.g:60:8: stmt pass self._state.following.append(self.FOLLOW_stmt_in_block333) stmt22 = self.stmt() self._state.following.pop() if self._state.backtracking == 0: stream_stmt.add(stmt22.tree) else: break #loop4 char_literal23 = self.match(self.input, 136, self.FOLLOW_136_in_block336) if self._state.backtracking == 0: stream_136.add(char_literal23) # AST Rewrite # elements: stmt # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 61:3: -> ^( BLOCK ( stmt )* ) # Expr.g:61:6: ^( BLOCK ( stmt )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(BLOCK, "BLOCK") , root_1) # Expr.g:61:14: ( stmt )* while stream_stmt.hasNext(): self._adaptor.addChild(root_1, stream_stmt.nextTree()) stream_stmt.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "block" class import_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.import_stmt_return, self).__init__() self.tree = None # $ANTLR start "import_stmt" # Expr.g:64:1: import_stmt : 'import' module_path ( ',' module_path )* ';' -> ^( IMPORT ( module_path )+ ) ; def import_stmt(self, ): retval = self.import_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal24 = None char_literal26 = None char_literal28 = None module_path25 = None module_path27 = None string_literal24_tree = None char_literal26_tree = None char_literal28_tree = None stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_82 = RewriteRuleTokenStream(self._adaptor, "token 82") stream_119 = RewriteRuleTokenStream(self._adaptor, "token 119") stream_module_path = RewriteRuleSubtreeStream(self._adaptor, "rule module_path") try: try: # Expr.g:65:2: ( 'import' module_path ( ',' module_path )* ';' -> ^( IMPORT ( module_path )+ ) ) # Expr.g:65:4: 'import' module_path ( ',' module_path )* ';' pass string_literal24 = self.match(self.input, 119, self.FOLLOW_119_in_import_stmt358) if self._state.backtracking == 0: stream_119.add(string_literal24) self._state.following.append(self.FOLLOW_module_path_in_import_stmt360) module_path25 = self.module_path() self._state.following.pop() if self._state.backtracking == 0: stream_module_path.add(module_path25.tree) # Expr.g:65:25: ( ',' module_path )* while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if (LA5_0 == 82) : alt5 = 1 if alt5 == 1: # Expr.g:65:26: ',' module_path pass char_literal26 = self.match(self.input, 82, self.FOLLOW_82_in_import_stmt363) if self._state.backtracking == 0: stream_82.add(char_literal26) self._state.following.append(self.FOLLOW_module_path_in_import_stmt365) module_path27 = self.module_path() self._state.following.pop() if self._state.backtracking == 0: stream_module_path.add(module_path27.tree) else: break #loop5 char_literal28 = self.match(self.input, 92, self.FOLLOW_92_in_import_stmt369) if self._state.backtracking == 0: stream_92.add(char_literal28) # AST Rewrite # elements: module_path # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 66:3: -> ^( IMPORT ( module_path )+ ) # Expr.g:66:6: ^( IMPORT ( module_path )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(IMPORT, "IMPORT") , root_1) # Expr.g:66:15: ( module_path )+ if not (stream_module_path.hasNext()): raise RewriteEarlyExitException() while stream_module_path.hasNext(): self._adaptor.addChild(root_1, stream_module_path.nextTree()) stream_module_path.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "import_stmt" class module_path_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.module_path_return, self).__init__() self.tree = None # $ANTLR start "module_path" # Expr.g:68:1: module_path : ( module | module '.*' ); def module_path(self, ): retval = self.module_path_return() retval.start = self.input.LT(1) root_0 = None string_literal31 = None module29 = None module30 = None string_literal31_tree = None try: try: # Expr.g:69:2: ( module | module '.*' ) alt6 = 2 alt6 = self.dfa6.predict(self.input) if alt6 == 1: # Expr.g:69:4: module pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_module_in_module_path390) module29 = self.module() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, module29.tree) elif alt6 == 2: # Expr.g:70:4: module '.*' pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_module_in_module_path395) module30 = self.module() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, module30.tree) string_literal31 = self.match(self.input, 87, self.FOLLOW_87_in_module_path397) if self._state.backtracking == 0: string_literal31_tree = self._adaptor.createWithPayload(string_literal31) self._adaptor.addChild(root_0, string_literal31_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "module_path" class printf_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.printf_stmt_return, self).__init__() self.tree = None # $ANTLR start "printf_stmt" # Expr.g:73:1: printf_stmt : 'printf' '(' expr ( ',' expr_list )? ')' ';' -> ^( PRINTF expr ( expr_list )? ) ; def printf_stmt(self, ): retval = self.printf_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal32 = None char_literal33 = None char_literal35 = None char_literal37 = None char_literal38 = None expr34 = None expr_list36 = None string_literal32_tree = None char_literal33_tree = None char_literal35_tree = None char_literal37_tree = None char_literal38_tree = None stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_123 = RewriteRuleTokenStream(self._adaptor, "token 123") stream_82 = RewriteRuleTokenStream(self._adaptor, "token 82") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") stream_expr_list = RewriteRuleSubtreeStream(self._adaptor, "rule expr_list") try: try: # Expr.g:74:2: ( 'printf' '(' expr ( ',' expr_list )? ')' ';' -> ^( PRINTF expr ( expr_list )? ) ) # Expr.g:74:4: 'printf' '(' expr ( ',' expr_list )? ')' ';' pass string_literal32 = self.match(self.input, 123, self.FOLLOW_123_in_printf_stmt408) if self._state.backtracking == 0: stream_123.add(string_literal32) char_literal33 = self.match(self.input, 75, self.FOLLOW_75_in_printf_stmt410) if self._state.backtracking == 0: stream_75.add(char_literal33) self._state.following.append(self.FOLLOW_expr_in_printf_stmt412) expr34 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr34.tree) # Expr.g:74:22: ( ',' expr_list )? alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 82) : alt7 = 1 if alt7 == 1: # Expr.g:74:23: ',' expr_list pass char_literal35 = self.match(self.input, 82, self.FOLLOW_82_in_printf_stmt415) if self._state.backtracking == 0: stream_82.add(char_literal35) self._state.following.append(self.FOLLOW_expr_list_in_printf_stmt417) expr_list36 = self.expr_list() self._state.following.pop() if self._state.backtracking == 0: stream_expr_list.add(expr_list36.tree) char_literal37 = self.match(self.input, 76, self.FOLLOW_76_in_printf_stmt421) if self._state.backtracking == 0: stream_76.add(char_literal37) char_literal38 = self.match(self.input, 92, self.FOLLOW_92_in_printf_stmt423) if self._state.backtracking == 0: stream_92.add(char_literal38) # AST Rewrite # elements: expr_list, expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 75:3: -> ^( PRINTF expr ( expr_list )? ) # Expr.g:75:6: ^( PRINTF expr ( expr_list )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(PRINTF, "PRINTF") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) # Expr.g:75:20: ( expr_list )? if stream_expr_list.hasNext(): self._adaptor.addChild(root_1, stream_expr_list.nextTree()) stream_expr_list.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "printf_stmt" class print_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.print_stmt_return, self).__init__() self.tree = None # $ANTLR start "print_stmt" # Expr.g:78:1: print_stmt : ( 'print' ) expr_list ';' -> ^( PRINT expr_list ) ; def print_stmt(self, ): retval = self.print_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal39 = None char_literal41 = None expr_list40 = None string_literal39_tree = None char_literal41_tree = None stream_122 = RewriteRuleTokenStream(self._adaptor, "token 122") stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_expr_list = RewriteRuleSubtreeStream(self._adaptor, "rule expr_list") try: try: # Expr.g:81:2: ( ( 'print' ) expr_list ';' -> ^( PRINT expr_list ) ) # Expr.g:81:4: ( 'print' ) expr_list ';' pass # Expr.g:81:4: ( 'print' ) # Expr.g:81:5: 'print' pass string_literal39 = self.match(self.input, 122, self.FOLLOW_122_in_print_stmt452) if self._state.backtracking == 0: stream_122.add(string_literal39) self._state.following.append(self.FOLLOW_expr_list_in_print_stmt455) expr_list40 = self.expr_list() self._state.following.pop() if self._state.backtracking == 0: stream_expr_list.add(expr_list40.tree) char_literal41 = self.match(self.input, 92, self.FOLLOW_92_in_print_stmt457) if self._state.backtracking == 0: stream_92.add(char_literal41) # AST Rewrite # elements: expr_list # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 82:3: -> ^( PRINT expr_list ) # Expr.g:82:6: ^( PRINT expr_list ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(PRINT, "PRINT") , root_1) self._adaptor.addChild(root_1, stream_expr_list.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "print_stmt" class break_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.break_stmt_return, self).__init__() self.tree = None # $ANTLR start "break_stmt" # Expr.g:85:1: break_stmt : 'break' ';' -> BREAK ; def break_stmt(self, ): retval = self.break_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal42 = None char_literal43 = None string_literal42_tree = None char_literal43_tree = None stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_105 = RewriteRuleTokenStream(self._adaptor, "token 105") try: try: # Expr.g:86:2: ( 'break' ';' -> BREAK ) # Expr.g:86:4: 'break' ';' pass string_literal42 = self.match(self.input, 105, self.FOLLOW_105_in_break_stmt478) if self._state.backtracking == 0: stream_105.add(string_literal42) char_literal43 = self.match(self.input, 92, self.FOLLOW_92_in_break_stmt480) if self._state.backtracking == 0: stream_92.add(char_literal43) # AST Rewrite # elements: # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 87:3: -> BREAK self._adaptor.addChild(root_0, self._adaptor.createFromType(BREAK, "BREAK") ) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "break_stmt" class continue_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.continue_stmt_return, self).__init__() self.tree = None # $ANTLR start "continue_stmt" # Expr.g:89:1: continue_stmt : 'continue' ';' -> CONTINUE ; def continue_stmt(self, ): retval = self.continue_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal44 = None char_literal45 = None string_literal44_tree = None char_literal45_tree = None stream_109 = RewriteRuleTokenStream(self._adaptor, "token 109") stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") try: try: # Expr.g:90:2: ( 'continue' ';' -> CONTINUE ) # Expr.g:90:4: 'continue' ';' pass string_literal44 = self.match(self.input, 109, self.FOLLOW_109_in_continue_stmt496) if self._state.backtracking == 0: stream_109.add(string_literal44) char_literal45 = self.match(self.input, 92, self.FOLLOW_92_in_continue_stmt498) if self._state.backtracking == 0: stream_92.add(char_literal45) # AST Rewrite # elements: # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 91:3: -> CONTINUE self._adaptor.addChild(root_0, self._adaptor.createFromType(CONTINUE, "CONTINUE") ) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "continue_stmt" class return_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.return_stmt_return, self).__init__() self.tree = None # $ANTLR start "return_stmt" # Expr.g:93:1: return_stmt : 'return' ( expr )? ';' -> ^( RETURN ( expr )? ) ; def return_stmt(self, ): retval = self.return_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal46 = None char_literal48 = None expr47 = None string_literal46_tree = None char_literal48_tree = None stream_125 = RewriteRuleTokenStream(self._adaptor, "token 125") stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:94:2: ( 'return' ( expr )? ';' -> ^( RETURN ( expr )? ) ) # Expr.g:94:4: 'return' ( expr )? ';' pass string_literal46 = self.match(self.input, 125, self.FOLLOW_125_in_return_stmt514) if self._state.backtracking == 0: stream_125.add(string_literal46) # Expr.g:94:13: ( expr )? alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == BOOL or LA8_0 == FLOAT or LA8_0 == ID or LA8_0 == INT or LA8_0 == NULL or LA8_0 == STRING or LA8_0 == 68 or LA8_0 == 75 or LA8_0 == 83 or LA8_0 == 100 or LA8_0 == 121 or LA8_0 == 126 or LA8_0 == 132) : alt8 = 1 if alt8 == 1: # Expr.g:94:13: expr pass self._state.following.append(self.FOLLOW_expr_in_return_stmt516) expr47 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr47.tree) char_literal48 = self.match(self.input, 92, self.FOLLOW_92_in_return_stmt519) if self._state.backtracking == 0: stream_92.add(char_literal48) # AST Rewrite # elements: expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 95:3: -> ^( RETURN ( expr )? ) # Expr.g:95:6: ^( RETURN ( expr )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(RETURN, "RETURN") , root_1) # Expr.g:95:15: ( expr )? if stream_expr.hasNext(): self._adaptor.addChild(root_1, stream_expr.nextTree()) stream_expr.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "return_stmt" class if_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.if_stmt_return, self).__init__() self.tree = None # $ANTLR start "if_stmt" # Expr.g:98:1: if_stmt : if_clause ( else_if_clause )* ( else_clause )? ; def if_stmt(self, ): retval = self.if_stmt_return() retval.start = self.input.LT(1) root_0 = None if_clause49 = None else_if_clause50 = None else_clause51 = None try: try: # Expr.g:99:2: ( if_clause ( else_if_clause )* ( else_clause )? ) # Expr.g:99:4: if_clause ( else_if_clause )* ( else_clause )? pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_if_clause_in_if_stmt541) if_clause49 = self.if_clause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, if_clause49.tree) # Expr.g:99:14: ( else_if_clause )* while True: #loop9 alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == 112) : LA9_1 = self.input.LA(2) if (LA9_1 == 118) : alt9 = 1 if alt9 == 1: # Expr.g:99:14: else_if_clause pass self._state.following.append(self.FOLLOW_else_if_clause_in_if_stmt543) else_if_clause50 = self.else_if_clause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, else_if_clause50.tree) else: break #loop9 # Expr.g:99:30: ( else_clause )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 112) : alt10 = 1 if alt10 == 1: # Expr.g:99:30: else_clause pass self._state.following.append(self.FOLLOW_else_clause_in_if_stmt546) else_clause51 = self.else_clause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, else_clause51.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "if_stmt" class if_clause_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.if_clause_return, self).__init__() self.tree = None # $ANTLR start "if_clause" # Expr.g:101:1: if_clause : 'if' '(' expr ')' block -> ^( IF expr block ) ; def if_clause(self, ): retval = self.if_clause_return() retval.start = self.input.LT(1) root_0 = None string_literal52 = None char_literal53 = None char_literal55 = None expr54 = None block56 = None string_literal52_tree = None char_literal53_tree = None char_literal55_tree = None stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_118 = RewriteRuleTokenStream(self._adaptor, "token 118") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:102:2: ( 'if' '(' expr ')' block -> ^( IF expr block ) ) # Expr.g:102:4: 'if' '(' expr ')' block pass string_literal52 = self.match(self.input, 118, self.FOLLOW_118_in_if_clause557) if self._state.backtracking == 0: stream_118.add(string_literal52) char_literal53 = self.match(self.input, 75, self.FOLLOW_75_in_if_clause559) if self._state.backtracking == 0: stream_75.add(char_literal53) self._state.following.append(self.FOLLOW_expr_in_if_clause561) expr54 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr54.tree) char_literal55 = self.match(self.input, 76, self.FOLLOW_76_in_if_clause563) if self._state.backtracking == 0: stream_76.add(char_literal55) self._state.following.append(self.FOLLOW_block_in_if_clause565) block56 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block56.tree) # AST Rewrite # elements: block, expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 103:3: -> ^( IF expr block ) # Expr.g:103:6: ^( IF expr block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(IF, "IF") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "if_clause" class else_if_clause_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.else_if_clause_return, self).__init__() self.tree = None # $ANTLR start "else_if_clause" # Expr.g:105:1: else_if_clause : 'else' if_clause -> ^( ELSE_IF if_clause ) ; def else_if_clause(self, ): retval = self.else_if_clause_return() retval.start = self.input.LT(1) root_0 = None string_literal57 = None if_clause58 = None string_literal57_tree = None stream_112 = RewriteRuleTokenStream(self._adaptor, "token 112") stream_if_clause = RewriteRuleSubtreeStream(self._adaptor, "rule if_clause") try: try: # Expr.g:106:2: ( 'else' if_clause -> ^( ELSE_IF if_clause ) ) # Expr.g:106:4: 'else' if_clause pass string_literal57 = self.match(self.input, 112, self.FOLLOW_112_in_else_if_clause587) if self._state.backtracking == 0: stream_112.add(string_literal57) self._state.following.append(self.FOLLOW_if_clause_in_else_if_clause589) if_clause58 = self.if_clause() self._state.following.pop() if self._state.backtracking == 0: stream_if_clause.add(if_clause58.tree) # AST Rewrite # elements: if_clause # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 107:3: -> ^( ELSE_IF if_clause ) # Expr.g:107:6: ^( ELSE_IF if_clause ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(ELSE_IF, "ELSE_IF") , root_1) self._adaptor.addChild(root_1, stream_if_clause.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "else_if_clause" class else_clause_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.else_clause_return, self).__init__() self.tree = None # $ANTLR start "else_clause" # Expr.g:109:1: else_clause : 'else' block -> ^( ELSE block ) ; def else_clause(self, ): retval = self.else_clause_return() retval.start = self.input.LT(1) root_0 = None string_literal59 = None block60 = None string_literal59_tree = None stream_112 = RewriteRuleTokenStream(self._adaptor, "token 112") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") try: try: # Expr.g:110:2: ( 'else' block -> ^( ELSE block ) ) # Expr.g:110:4: 'else' block pass string_literal59 = self.match(self.input, 112, self.FOLLOW_112_in_else_clause609) if self._state.backtracking == 0: stream_112.add(string_literal59) self._state.following.append(self.FOLLOW_block_in_else_clause611) block60 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block60.tree) # AST Rewrite # elements: block # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 111:3: -> ^( ELSE block ) # Expr.g:111:6: ^( ELSE block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(ELSE, "ELSE") , root_1) self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "else_clause" class while_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.while_stmt_return, self).__init__() self.tree = None # $ANTLR start "while_stmt" # Expr.g:114:1: while_stmt : 'while' '(' expr ')' block -> ^( WHILE expr block ) ; def while_stmt(self, ): retval = self.while_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal61 = None char_literal62 = None char_literal64 = None expr63 = None block65 = None string_literal61_tree = None char_literal62_tree = None char_literal64_tree = None stream_131 = RewriteRuleTokenStream(self._adaptor, "token 131") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:115:2: ( 'while' '(' expr ')' block -> ^( WHILE expr block ) ) # Expr.g:115:4: 'while' '(' expr ')' block pass string_literal61 = self.match(self.input, 131, self.FOLLOW_131_in_while_stmt632) if self._state.backtracking == 0: stream_131.add(string_literal61) char_literal62 = self.match(self.input, 75, self.FOLLOW_75_in_while_stmt634) if self._state.backtracking == 0: stream_75.add(char_literal62) self._state.following.append(self.FOLLOW_expr_in_while_stmt636) expr63 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr63.tree) char_literal64 = self.match(self.input, 76, self.FOLLOW_76_in_while_stmt638) if self._state.backtracking == 0: stream_76.add(char_literal64) self._state.following.append(self.FOLLOW_block_in_while_stmt640) block65 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block65.tree) # AST Rewrite # elements: expr, block # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 116:3: -> ^( WHILE expr block ) # Expr.g:116:6: ^( WHILE expr block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(WHILE, "WHILE") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "while_stmt" class do_while_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.do_while_stmt_return, self).__init__() self.tree = None # $ANTLR start "do_while_stmt" # Expr.g:119:1: do_while_stmt : 'do' block 'while' '(' expr ')' ';' -> ^( DO_WHILE block expr ) ; def do_while_stmt(self, ): retval = self.do_while_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal66 = None string_literal68 = None char_literal69 = None char_literal71 = None char_literal72 = None block67 = None expr70 = None string_literal66_tree = None string_literal68_tree = None char_literal69_tree = None char_literal71_tree = None char_literal72_tree = None stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_111 = RewriteRuleTokenStream(self._adaptor, "token 111") stream_131 = RewriteRuleTokenStream(self._adaptor, "token 131") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:120:2: ( 'do' block 'while' '(' expr ')' ';' -> ^( DO_WHILE block expr ) ) # Expr.g:120:4: 'do' block 'while' '(' expr ')' ';' pass string_literal66 = self.match(self.input, 111, self.FOLLOW_111_in_do_while_stmt663) if self._state.backtracking == 0: stream_111.add(string_literal66) self._state.following.append(self.FOLLOW_block_in_do_while_stmt665) block67 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block67.tree) string_literal68 = self.match(self.input, 131, self.FOLLOW_131_in_do_while_stmt667) if self._state.backtracking == 0: stream_131.add(string_literal68) char_literal69 = self.match(self.input, 75, self.FOLLOW_75_in_do_while_stmt669) if self._state.backtracking == 0: stream_75.add(char_literal69) self._state.following.append(self.FOLLOW_expr_in_do_while_stmt671) expr70 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr70.tree) char_literal71 = self.match(self.input, 76, self.FOLLOW_76_in_do_while_stmt673) if self._state.backtracking == 0: stream_76.add(char_literal71) char_literal72 = self.match(self.input, 92, self.FOLLOW_92_in_do_while_stmt675) if self._state.backtracking == 0: stream_92.add(char_literal72) # AST Rewrite # elements: expr, block # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 121:3: -> ^( DO_WHILE block expr ) # Expr.g:121:6: ^( DO_WHILE block expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(DO_WHILE, "DO_WHILE") , root_1) self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "do_while_stmt" class switch_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.switch_stmt_return, self).__init__() self.tree = None # $ANTLR start "switch_stmt" # Expr.g:124:1: switch_stmt : 'switch' '(' expr ')' case_block -> ^( SWITCH expr case_block ) ; def switch_stmt(self, ): retval = self.switch_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal73 = None char_literal74 = None char_literal76 = None expr75 = None case_block77 = None string_literal73_tree = None char_literal74_tree = None char_literal76_tree = None stream_128 = RewriteRuleTokenStream(self._adaptor, "token 128") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_case_block = RewriteRuleSubtreeStream(self._adaptor, "rule case_block") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:125:2: ( 'switch' '(' expr ')' case_block -> ^( SWITCH expr case_block ) ) # Expr.g:125:4: 'switch' '(' expr ')' case_block pass string_literal73 = self.match(self.input, 128, self.FOLLOW_128_in_switch_stmt698) if self._state.backtracking == 0: stream_128.add(string_literal73) char_literal74 = self.match(self.input, 75, self.FOLLOW_75_in_switch_stmt700) if self._state.backtracking == 0: stream_75.add(char_literal74) self._state.following.append(self.FOLLOW_expr_in_switch_stmt702) expr75 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr75.tree) char_literal76 = self.match(self.input, 76, self.FOLLOW_76_in_switch_stmt704) if self._state.backtracking == 0: stream_76.add(char_literal76) self._state.following.append(self.FOLLOW_case_block_in_switch_stmt706) case_block77 = self.case_block() self._state.following.pop() if self._state.backtracking == 0: stream_case_block.add(case_block77.tree) # AST Rewrite # elements: case_block, expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 126:3: -> ^( SWITCH expr case_block ) # Expr.g:126:6: ^( SWITCH expr case_block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(SWITCH, "SWITCH") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_1, stream_case_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "switch_stmt" class case_block_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.case_block_return, self).__init__() self.tree = None # $ANTLR start "case_block" # Expr.g:128:1: case_block : '{' ( case_clause )+ ( default_clause )? '}' ; def case_block(self, ): retval = self.case_block_return() retval.start = self.input.LT(1) root_0 = None char_literal78 = None char_literal81 = None case_clause79 = None default_clause80 = None char_literal78_tree = None char_literal81_tree = None try: try: # Expr.g:129:2: ( '{' ( case_clause )+ ( default_clause )? '}' ) # Expr.g:129:4: '{' ( case_clause )+ ( default_clause )? '}' pass root_0 = self._adaptor.nil() char_literal78 = self.match(self.input, 132, self.FOLLOW_132_in_case_block728) if self._state.backtracking == 0: char_literal78_tree = self._adaptor.createWithPayload(char_literal78) self._adaptor.addChild(root_0, char_literal78_tree) # Expr.g:129:8: ( case_clause )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == 106) : alt11 = 1 if alt11 == 1: # Expr.g:129:9: case_clause pass self._state.following.append(self.FOLLOW_case_clause_in_case_block731) case_clause79 = self.case_clause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, case_clause79.tree) else: if cnt11 >= 1: break #loop11 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 # Expr.g:129:23: ( default_clause )? alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == 110) : alt12 = 1 if alt12 == 1: # Expr.g:129:24: default_clause pass self._state.following.append(self.FOLLOW_default_clause_in_case_block736) default_clause80 = self.default_clause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, default_clause80.tree) char_literal81 = self.match(self.input, 136, self.FOLLOW_136_in_case_block740) if self._state.backtracking == 0: char_literal81_tree = self._adaptor.createWithPayload(char_literal81) self._adaptor.addChild(root_0, char_literal81_tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "case_block" class case_clause_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.case_clause_return, self).__init__() self.tree = None # $ANTLR start "case_clause" # Expr.g:131:1: case_clause : ( case_test )+ ( stmt )* break_stmt -> ^( CASE ( case_test )+ ( stmt )* break_stmt ) ; def case_clause(self, ): retval = self.case_clause_return() retval.start = self.input.LT(1) root_0 = None case_test82 = None stmt83 = None break_stmt84 = None stream_case_test = RewriteRuleSubtreeStream(self._adaptor, "rule case_test") stream_stmt = RewriteRuleSubtreeStream(self._adaptor, "rule stmt") stream_break_stmt = RewriteRuleSubtreeStream(self._adaptor, "rule break_stmt") try: try: # Expr.g:132:2: ( ( case_test )+ ( stmt )* break_stmt -> ^( CASE ( case_test )+ ( stmt )* break_stmt ) ) # Expr.g:132:4: ( case_test )+ ( stmt )* break_stmt pass # Expr.g:132:4: ( case_test )+ cnt13 = 0 while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == 106) : alt13 = 1 if alt13 == 1: # Expr.g:132:4: case_test pass self._state.following.append(self.FOLLOW_case_test_in_case_clause750) case_test82 = self.case_test() self._state.following.pop() if self._state.backtracking == 0: stream_case_test.add(case_test82.tree) else: if cnt13 >= 1: break #loop13 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(13, self.input) raise eee cnt13 += 1 # Expr.g:132:15: ( stmt )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == 105) : LA14_1 = self.input.LA(2) if (LA14_1 == 92) : LA14_3 = self.input.LA(3) if (LA14_3 == ID or LA14_3 == 80 or LA14_3 == 84 or LA14_3 == 92 or LA14_3 == 105 or (108 <= LA14_3 <= 109) or LA14_3 == 111 or (115 <= LA14_3 <= 119) or (122 <= LA14_3 <= 123) or LA14_3 == 125 or (128 <= LA14_3 <= 131)) : alt14 = 1 elif (LA14_0 == ID or LA14_0 == 80 or LA14_0 == 84 or LA14_0 == 92 or (108 <= LA14_0 <= 109) or LA14_0 == 111 or (115 <= LA14_0 <= 119) or (122 <= LA14_0 <= 123) or LA14_0 == 125 or (128 <= LA14_0 <= 131)) : alt14 = 1 if alt14 == 1: # Expr.g:132:15: stmt pass self._state.following.append(self.FOLLOW_stmt_in_case_clause753) stmt83 = self.stmt() self._state.following.pop() if self._state.backtracking == 0: stream_stmt.add(stmt83.tree) else: break #loop14 self._state.following.append(self.FOLLOW_break_stmt_in_case_clause756) break_stmt84 = self.break_stmt() self._state.following.pop() if self._state.backtracking == 0: stream_break_stmt.add(break_stmt84.tree) # AST Rewrite # elements: stmt, case_test, break_stmt # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 133:3: -> ^( CASE ( case_test )+ ( stmt )* break_stmt ) # Expr.g:133:6: ^( CASE ( case_test )+ ( stmt )* break_stmt ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(CASE, "CASE") , root_1) # Expr.g:133:13: ( case_test )+ if not (stream_case_test.hasNext()): raise RewriteEarlyExitException() while stream_case_test.hasNext(): self._adaptor.addChild(root_1, stream_case_test.nextTree()) stream_case_test.reset() # Expr.g:133:24: ( stmt )* while stream_stmt.hasNext(): self._adaptor.addChild(root_1, stream_stmt.nextTree()) stream_stmt.reset(); self._adaptor.addChild(root_1, stream_break_stmt.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "case_clause" class case_test_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.case_test_return, self).__init__() self.tree = None # $ANTLR start "case_test" # Expr.g:135:1: case_test : 'case' expr ':' -> ^( CASE expr ) ; def case_test(self, ): retval = self.case_test_return() retval.start = self.input.LT(1) root_0 = None string_literal85 = None char_literal87 = None expr86 = None string_literal85_tree = None char_literal87_tree = None stream_91 = RewriteRuleTokenStream(self._adaptor, "token 91") stream_106 = RewriteRuleTokenStream(self._adaptor, "token 106") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:136:2: ( 'case' expr ':' -> ^( CASE expr ) ) # Expr.g:136:4: 'case' expr ':' pass string_literal85 = self.match(self.input, 106, self.FOLLOW_106_in_case_test782) if self._state.backtracking == 0: stream_106.add(string_literal85) self._state.following.append(self.FOLLOW_expr_in_case_test784) expr86 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr86.tree) char_literal87 = self.match(self.input, 91, self.FOLLOW_91_in_case_test786) if self._state.backtracking == 0: stream_91.add(char_literal87) # AST Rewrite # elements: expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 137:3: -> ^( CASE expr ) # Expr.g:137:6: ^( CASE expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(CASE, "CASE") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "case_test" class default_clause_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.default_clause_return, self).__init__() self.tree = None # $ANTLR start "default_clause" # Expr.g:139:1: default_clause : 'default' ':' ( stmt )* -> ^( DEFAULT ( stmt )* ) ; def default_clause(self, ): retval = self.default_clause_return() retval.start = self.input.LT(1) root_0 = None string_literal88 = None char_literal89 = None stmt90 = None string_literal88_tree = None char_literal89_tree = None stream_110 = RewriteRuleTokenStream(self._adaptor, "token 110") stream_91 = RewriteRuleTokenStream(self._adaptor, "token 91") stream_stmt = RewriteRuleSubtreeStream(self._adaptor, "rule stmt") try: try: # Expr.g:140:2: ( 'default' ':' ( stmt )* -> ^( DEFAULT ( stmt )* ) ) # Expr.g:140:4: 'default' ':' ( stmt )* pass string_literal88 = self.match(self.input, 110, self.FOLLOW_110_in_default_clause806) if self._state.backtracking == 0: stream_110.add(string_literal88) char_literal89 = self.match(self.input, 91, self.FOLLOW_91_in_default_clause808) if self._state.backtracking == 0: stream_91.add(char_literal89) # Expr.g:140:18: ( stmt )* while True: #loop15 alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == ID or LA15_0 == 80 or LA15_0 == 84 or LA15_0 == 92 or LA15_0 == 105 or (108 <= LA15_0 <= 109) or LA15_0 == 111 or (115 <= LA15_0 <= 119) or (122 <= LA15_0 <= 123) or LA15_0 == 125 or (128 <= LA15_0 <= 131)) : alt15 = 1 if alt15 == 1: # Expr.g:140:18: stmt pass self._state.following.append(self.FOLLOW_stmt_in_default_clause810) stmt90 = self.stmt() self._state.following.pop() if self._state.backtracking == 0: stream_stmt.add(stmt90.tree) else: break #loop15 # AST Rewrite # elements: stmt # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 141:3: -> ^( DEFAULT ( stmt )* ) # Expr.g:141:6: ^( DEFAULT ( stmt )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(DEFAULT, "DEFAULT") , root_1) # Expr.g:141:16: ( stmt )* while stream_stmt.hasNext(): self._adaptor.addChild(root_1, stream_stmt.nextTree()) stream_stmt.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "default_clause" class for_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.for_stmt_return, self).__init__() self.tree = None # $ANTLR start "for_stmt" # Expr.g:144:1: for_stmt : 'for' '(' (a= exec_list )? ';' expr ';' (b= exec_list )? ')' block -> ^( FOR ( $a)? expr block ( $b)? ) ; def for_stmt(self, ): retval = self.for_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal91 = None char_literal92 = None char_literal93 = None char_literal95 = None char_literal96 = None a = None b = None expr94 = None block97 = None string_literal91_tree = None char_literal92_tree = None char_literal93_tree = None char_literal95_tree = None char_literal96_tree = None stream_115 = RewriteRuleTokenStream(self._adaptor, "token 115") stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") stream_exec_list = RewriteRuleSubtreeStream(self._adaptor, "rule exec_list") try: try: # Expr.g:145:2: ( 'for' '(' (a= exec_list )? ';' expr ';' (b= exec_list )? ')' block -> ^( FOR ( $a)? expr block ( $b)? ) ) # Expr.g:145:4: 'for' '(' (a= exec_list )? ';' expr ';' (b= exec_list )? ')' block pass string_literal91 = self.match(self.input, 115, self.FOLLOW_115_in_for_stmt833) if self._state.backtracking == 0: stream_115.add(string_literal91) char_literal92 = self.match(self.input, 75, self.FOLLOW_75_in_for_stmt835) if self._state.backtracking == 0: stream_75.add(char_literal92) # Expr.g:145:15: (a= exec_list )? alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == ID or LA16_0 == 80 or LA16_0 == 84) : alt16 = 1 if alt16 == 1: # Expr.g:145:15: a= exec_list pass self._state.following.append(self.FOLLOW_exec_list_in_for_stmt839) a = self.exec_list() self._state.following.pop() if self._state.backtracking == 0: stream_exec_list.add(a.tree) char_literal93 = self.match(self.input, 92, self.FOLLOW_92_in_for_stmt842) if self._state.backtracking == 0: stream_92.add(char_literal93) self._state.following.append(self.FOLLOW_expr_in_for_stmt844) expr94 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr94.tree) char_literal95 = self.match(self.input, 92, self.FOLLOW_92_in_for_stmt846) if self._state.backtracking == 0: stream_92.add(char_literal95) # Expr.g:145:41: (b= exec_list )? alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == ID or LA17_0 == 80 or LA17_0 == 84) : alt17 = 1 if alt17 == 1: # Expr.g:145:41: b= exec_list pass self._state.following.append(self.FOLLOW_exec_list_in_for_stmt850) b = self.exec_list() self._state.following.pop() if self._state.backtracking == 0: stream_exec_list.add(b.tree) char_literal96 = self.match(self.input, 76, self.FOLLOW_76_in_for_stmt853) if self._state.backtracking == 0: stream_76.add(char_literal96) self._state.following.append(self.FOLLOW_block_in_for_stmt855) block97 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block97.tree) # AST Rewrite # elements: expr, block, a, b # token labels: # rule labels: retval, b, a # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) if b is not None: stream_b = RewriteRuleSubtreeStream(self._adaptor, "rule b", b.tree) else: stream_b = RewriteRuleSubtreeStream(self._adaptor, "token b", None) if a is not None: stream_a = RewriteRuleSubtreeStream(self._adaptor, "rule a", a.tree) else: stream_a = RewriteRuleSubtreeStream(self._adaptor, "token a", None) root_0 = self._adaptor.nil() # 146:3: -> ^( FOR ( $a)? expr block ( $b)? ) # Expr.g:146:6: ^( FOR ( $a)? expr block ( $b)? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(FOR, "FOR") , root_1) # Expr.g:146:13: ( $a)? if stream_a.hasNext(): self._adaptor.addChild(root_1, stream_a.nextTree()) stream_a.reset(); self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_1, stream_block.nextTree()) # Expr.g:146:28: ( $b)? if stream_b.hasNext(): self._adaptor.addChild(root_1, stream_b.nextTree()) stream_b.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "for_stmt" class foreach_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.foreach_stmt_return, self).__init__() self.tree = None # $ANTLR start "foreach_stmt" # Expr.g:149:1: foreach_stmt : 'foreach' '(' expr 'as' each ')' block -> ^( FOREACH expr each block ) ; def foreach_stmt(self, ): retval = self.foreach_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal98 = None char_literal99 = None string_literal101 = None char_literal103 = None expr100 = None each102 = None block104 = None string_literal98_tree = None char_literal99_tree = None string_literal101_tree = None char_literal103_tree = None stream_116 = RewriteRuleTokenStream(self._adaptor, "token 116") stream_104 = RewriteRuleTokenStream(self._adaptor, "token 104") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") stream_each = RewriteRuleSubtreeStream(self._adaptor, "rule each") try: try: # Expr.g:150:2: ( 'foreach' '(' expr 'as' each ')' block -> ^( FOREACH expr each block ) ) # Expr.g:150:4: 'foreach' '(' expr 'as' each ')' block pass string_literal98 = self.match(self.input, 116, self.FOLLOW_116_in_foreach_stmt886) if self._state.backtracking == 0: stream_116.add(string_literal98) char_literal99 = self.match(self.input, 75, self.FOLLOW_75_in_foreach_stmt888) if self._state.backtracking == 0: stream_75.add(char_literal99) self._state.following.append(self.FOLLOW_expr_in_foreach_stmt890) expr100 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr100.tree) string_literal101 = self.match(self.input, 104, self.FOLLOW_104_in_foreach_stmt892) if self._state.backtracking == 0: stream_104.add(string_literal101) self._state.following.append(self.FOLLOW_each_in_foreach_stmt894) each102 = self.each() self._state.following.pop() if self._state.backtracking == 0: stream_each.add(each102.tree) char_literal103 = self.match(self.input, 76, self.FOLLOW_76_in_foreach_stmt896) if self._state.backtracking == 0: stream_76.add(char_literal103) self._state.following.append(self.FOLLOW_block_in_foreach_stmt898) block104 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block104.tree) # AST Rewrite # elements: expr, block, each # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 151:3: -> ^( FOREACH expr each block ) # Expr.g:151:6: ^( FOREACH expr each block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(FOREACH, "FOREACH") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_1, stream_each.nextTree()) self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "foreach_stmt" class each_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.each_return, self).__init__() self.tree = None # $ANTLR start "each" # Expr.g:153:1: each : ( each_val -> ^( EACH each_val ) | ID '=>' each_val -> ^( EACH ID each_val ) ); def each(self, ): retval = self.each_return() retval.start = self.input.LT(1) root_0 = None ID106 = None string_literal107 = None each_val105 = None each_val108 = None ID106_tree = None string_literal107_tree = None stream_97 = RewriteRuleTokenStream(self._adaptor, "token 97") stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_each_val = RewriteRuleSubtreeStream(self._adaptor, "rule each_val") try: try: # Expr.g:154:2: ( each_val -> ^( EACH each_val ) | ID '=>' each_val -> ^( EACH ID each_val ) ) alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == ID) : LA18_1 = self.input.LA(2) if (LA18_1 == 97) : alt18 = 2 elif (LA18_1 == 76 or LA18_1 == 82) : alt18 = 1 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 18, 1, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 18, 0, self.input) raise nvae if alt18 == 1: # Expr.g:154:4: each_val pass self._state.following.append(self.FOLLOW_each_val_in_each922) each_val105 = self.each_val() self._state.following.pop() if self._state.backtracking == 0: stream_each_val.add(each_val105.tree) # AST Rewrite # elements: each_val # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 155:3: -> ^( EACH each_val ) # Expr.g:155:6: ^( EACH each_val ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(EACH, "EACH") , root_1) self._adaptor.addChild(root_1, stream_each_val.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt18 == 2: # Expr.g:156:4: ID '=>' each_val pass ID106 = self.match(self.input, ID, self.FOLLOW_ID_in_each937) if self._state.backtracking == 0: stream_ID.add(ID106) string_literal107 = self.match(self.input, 97, self.FOLLOW_97_in_each939) if self._state.backtracking == 0: stream_97.add(string_literal107) self._state.following.append(self.FOLLOW_each_val_in_each941) each_val108 = self.each_val() self._state.following.pop() if self._state.backtracking == 0: stream_each_val.add(each_val108.tree) # AST Rewrite # elements: each_val, ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 157:3: -> ^( EACH ID each_val ) # Expr.g:157:6: ^( EACH ID each_val ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(EACH, "EACH") , root_1) self._adaptor.addChild(root_1, stream_ID.nextNode() ) self._adaptor.addChild(root_1, stream_each_val.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "each" class each_val_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.each_val_return, self).__init__() self.tree = None # $ANTLR start "each_val" # Expr.g:159:1: each_val : ID ( ',' ID )* -> ^( EACH_VAL ( ID )+ ) ; def each_val(self, ): retval = self.each_val_return() retval.start = self.input.LT(1) root_0 = None ID109 = None char_literal110 = None ID111 = None ID109_tree = None char_literal110_tree = None ID111_tree = None stream_82 = RewriteRuleTokenStream(self._adaptor, "token 82") stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") try: try: # Expr.g:160:2: ( ID ( ',' ID )* -> ^( EACH_VAL ( ID )+ ) ) # Expr.g:160:4: ID ( ',' ID )* pass ID109 = self.match(self.input, ID, self.FOLLOW_ID_in_each_val963) if self._state.backtracking == 0: stream_ID.add(ID109) # Expr.g:160:7: ( ',' ID )* while True: #loop19 alt19 = 2 LA19_0 = self.input.LA(1) if (LA19_0 == 82) : alt19 = 1 if alt19 == 1: # Expr.g:160:8: ',' ID pass char_literal110 = self.match(self.input, 82, self.FOLLOW_82_in_each_val966) if self._state.backtracking == 0: stream_82.add(char_literal110) ID111 = self.match(self.input, ID, self.FOLLOW_ID_in_each_val968) if self._state.backtracking == 0: stream_ID.add(ID111) else: break #loop19 # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 161:3: -> ^( EACH_VAL ( ID )+ ) # Expr.g:161:6: ^( EACH_VAL ( ID )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(EACH_VAL, "EACH_VAL") , root_1) # Expr.g:161:17: ( ID )+ if not (stream_ID.hasNext()): raise RewriteEarlyExitException() while stream_ID.hasNext(): self._adaptor.addChild(root_1, stream_ID.nextNode() ) stream_ID.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "each_val" class throw_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.throw_stmt_return, self).__init__() self.tree = None # $ANTLR start "throw_stmt" # Expr.g:165:1: throw_stmt : 'throw' expr ';' -> ^( THROW expr ) ; def throw_stmt(self, ): retval = self.throw_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal112 = None char_literal114 = None expr113 = None string_literal112_tree = None char_literal114_tree = None stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_129 = RewriteRuleTokenStream(self._adaptor, "token 129") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:166:2: ( 'throw' expr ';' -> ^( THROW expr ) ) # Expr.g:166:4: 'throw' expr ';' pass string_literal112 = self.match(self.input, 129, self.FOLLOW_129_in_throw_stmt993) if self._state.backtracking == 0: stream_129.add(string_literal112) self._state.following.append(self.FOLLOW_expr_in_throw_stmt995) expr113 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr113.tree) char_literal114 = self.match(self.input, 92, self.FOLLOW_92_in_throw_stmt997) if self._state.backtracking == 0: stream_92.add(char_literal114) # AST Rewrite # elements: expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 167:3: -> ^( THROW expr ) # Expr.g:167:6: ^( THROW expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(THROW, "THROW") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "throw_stmt" class try_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.try_stmt_return, self).__init__() self.tree = None # $ANTLR start "try_stmt" # Expr.g:169:1: try_stmt : 'try' block ( catch_clause )+ ( finally_clause )? -> ^( TRY block ( catch_clause )+ ( finally_clause )? ) ; def try_stmt(self, ): retval = self.try_stmt_return() retval.start = self.input.LT(1) root_0 = None string_literal115 = None block116 = None catch_clause117 = None finally_clause118 = None string_literal115_tree = None stream_130 = RewriteRuleTokenStream(self._adaptor, "token 130") stream_catch_clause = RewriteRuleSubtreeStream(self._adaptor, "rule catch_clause") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") stream_finally_clause = RewriteRuleSubtreeStream(self._adaptor, "rule finally_clause") try: try: # Expr.g:170:2: ( 'try' block ( catch_clause )+ ( finally_clause )? -> ^( TRY block ( catch_clause )+ ( finally_clause )? ) ) # Expr.g:170:4: 'try' block ( catch_clause )+ ( finally_clause )? pass string_literal115 = self.match(self.input, 130, self.FOLLOW_130_in_try_stmt1017) if self._state.backtracking == 0: stream_130.add(string_literal115) self._state.following.append(self.FOLLOW_block_in_try_stmt1019) block116 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block116.tree) # Expr.g:170:16: ( catch_clause )+ cnt20 = 0 while True: #loop20 alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == 107) : alt20 = 1 if alt20 == 1: # Expr.g:170:16: catch_clause pass self._state.following.append(self.FOLLOW_catch_clause_in_try_stmt1021) catch_clause117 = self.catch_clause() self._state.following.pop() if self._state.backtracking == 0: stream_catch_clause.add(catch_clause117.tree) else: if cnt20 >= 1: break #loop20 if self._state.backtracking > 0: raise BacktrackingFailed eee = EarlyExitException(20, self.input) raise eee cnt20 += 1 # Expr.g:170:30: ( finally_clause )? alt21 = 2 LA21_0 = self.input.LA(1) if (LA21_0 == 114) : alt21 = 1 if alt21 == 1: # Expr.g:170:30: finally_clause pass self._state.following.append(self.FOLLOW_finally_clause_in_try_stmt1024) finally_clause118 = self.finally_clause() self._state.following.pop() if self._state.backtracking == 0: stream_finally_clause.add(finally_clause118.tree) # AST Rewrite # elements: finally_clause, catch_clause, block # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 171:3: -> ^( TRY block ( catch_clause )+ ( finally_clause )? ) # Expr.g:171:6: ^( TRY block ( catch_clause )+ ( finally_clause )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(TRY, "TRY") , root_1) self._adaptor.addChild(root_1, stream_block.nextTree()) # Expr.g:171:18: ( catch_clause )+ if not (stream_catch_clause.hasNext()): raise RewriteEarlyExitException() while stream_catch_clause.hasNext(): self._adaptor.addChild(root_1, stream_catch_clause.nextTree()) stream_catch_clause.reset() # Expr.g:171:32: ( finally_clause )? if stream_finally_clause.hasNext(): self._adaptor.addChild(root_1, stream_finally_clause.nextTree()) stream_finally_clause.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "try_stmt" class catch_clause_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.catch_clause_return, self).__init__() self.tree = None # $ANTLR start "catch_clause" # Expr.g:173:1: catch_clause : 'catch' '(' module ( ID )? ')' block -> ^( CATCH module ( ID )? block ) ; def catch_clause(self, ): retval = self.catch_clause_return() retval.start = self.input.LT(1) root_0 = None string_literal119 = None char_literal120 = None ID122 = None char_literal123 = None module121 = None block124 = None string_literal119_tree = None char_literal120_tree = None ID122_tree = None char_literal123_tree = None stream_107 = RewriteRuleTokenStream(self._adaptor, "token 107") stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_module = RewriteRuleSubtreeStream(self._adaptor, "rule module") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") try: try: # Expr.g:174:2: ( 'catch' '(' module ( ID )? ')' block -> ^( CATCH module ( ID )? block ) ) # Expr.g:174:4: 'catch' '(' module ( ID )? ')' block pass string_literal119 = self.match(self.input, 107, self.FOLLOW_107_in_catch_clause1051) if self._state.backtracking == 0: stream_107.add(string_literal119) char_literal120 = self.match(self.input, 75, self.FOLLOW_75_in_catch_clause1053) if self._state.backtracking == 0: stream_75.add(char_literal120) self._state.following.append(self.FOLLOW_module_in_catch_clause1055) module121 = self.module() self._state.following.pop() if self._state.backtracking == 0: stream_module.add(module121.tree) # Expr.g:174:23: ( ID )? alt22 = 2 LA22_0 = self.input.LA(1) if (LA22_0 == ID) : alt22 = 1 if alt22 == 1: # Expr.g:174:23: ID pass ID122 = self.match(self.input, ID, self.FOLLOW_ID_in_catch_clause1057) if self._state.backtracking == 0: stream_ID.add(ID122) char_literal123 = self.match(self.input, 76, self.FOLLOW_76_in_catch_clause1060) if self._state.backtracking == 0: stream_76.add(char_literal123) self._state.following.append(self.FOLLOW_block_in_catch_clause1062) block124 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block124.tree) # AST Rewrite # elements: block, ID, module # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 175:3: -> ^( CATCH module ( ID )? block ) # Expr.g:175:6: ^( CATCH module ( ID )? block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(CATCH, "CATCH") , root_1) self._adaptor.addChild(root_1, stream_module.nextTree()) # Expr.g:175:21: ( ID )? if stream_ID.hasNext(): self._adaptor.addChild(root_1, stream_ID.nextNode() ) stream_ID.reset(); self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "catch_clause" class finally_clause_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.finally_clause_return, self).__init__() self.tree = None # $ANTLR start "finally_clause" # Expr.g:177:1: finally_clause : 'finally' block -> ^( FINALLY block ) ; def finally_clause(self, ): retval = self.finally_clause_return() retval.start = self.input.LT(1) root_0 = None string_literal125 = None block126 = None string_literal125_tree = None stream_114 = RewriteRuleTokenStream(self._adaptor, "token 114") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") try: try: # Expr.g:178:2: ( 'finally' block -> ^( FINALLY block ) ) # Expr.g:178:4: 'finally' block pass string_literal125 = self.match(self.input, 114, self.FOLLOW_114_in_finally_clause1087) if self._state.backtracking == 0: stream_114.add(string_literal125) self._state.following.append(self.FOLLOW_block_in_finally_clause1089) block126 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block126.tree) # AST Rewrite # elements: block # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 179:3: -> ^( FINALLY block ) # Expr.g:179:6: ^( FINALLY block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(FINALLY, "FINALLY") , root_1) self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "finally_clause" class func_decl_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.func_decl_return, self).__init__() self.tree = None # $ANTLR start "func_decl" # Expr.g:183:1: func_decl : 'function' ID params block -> ^( FUNCTION ID params block ) ; def func_decl(self, ): retval = self.func_decl_return() retval.start = self.input.LT(1) root_0 = None string_literal127 = None ID128 = None params129 = None block130 = None string_literal127_tree = None ID128_tree = None stream_117 = RewriteRuleTokenStream(self._adaptor, "token 117") stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") stream_params = RewriteRuleSubtreeStream(self._adaptor, "rule params") try: try: # Expr.g:184:2: ( 'function' ID params block -> ^( FUNCTION ID params block ) ) # Expr.g:184:4: 'function' ID params block pass string_literal127 = self.match(self.input, 117, self.FOLLOW_117_in_func_decl1111) if self._state.backtracking == 0: stream_117.add(string_literal127) ID128 = self.match(self.input, ID, self.FOLLOW_ID_in_func_decl1113) if self._state.backtracking == 0: stream_ID.add(ID128) self._state.following.append(self.FOLLOW_params_in_func_decl1115) params129 = self.params() self._state.following.pop() if self._state.backtracking == 0: stream_params.add(params129.tree) self._state.following.append(self.FOLLOW_block_in_func_decl1117) block130 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block130.tree) # AST Rewrite # elements: block, ID, params # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 185:3: -> ^( FUNCTION ID params block ) # Expr.g:185:6: ^( FUNCTION ID params block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(FUNCTION, "FUNCTION") , root_1) self._adaptor.addChild(root_1, stream_ID.nextNode() ) self._adaptor.addChild(root_1, stream_params.nextTree()) self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "func_decl" class params_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.params_return, self).__init__() self.tree = None # $ANTLR start "params" # Expr.g:187:1: params : '(' ( param_decl )? ( ',' param_decl )* ')' -> ^( PARAMS ( param_decl )* ) ; def params(self, ): retval = self.params_return() retval.start = self.input.LT(1) root_0 = None char_literal131 = None char_literal133 = None char_literal135 = None param_decl132 = None param_decl134 = None char_literal131_tree = None char_literal133_tree = None char_literal135_tree = None stream_82 = RewriteRuleTokenStream(self._adaptor, "token 82") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_param_decl = RewriteRuleSubtreeStream(self._adaptor, "rule param_decl") try: try: # Expr.g:188:2: ( '(' ( param_decl )? ( ',' param_decl )* ')' -> ^( PARAMS ( param_decl )* ) ) # Expr.g:188:4: '(' ( param_decl )? ( ',' param_decl )* ')' pass char_literal131 = self.match(self.input, 75, self.FOLLOW_75_in_params1141) if self._state.backtracking == 0: stream_75.add(char_literal131) # Expr.g:188:8: ( param_decl )? alt23 = 2 LA23_0 = self.input.LA(1) if (LA23_0 == ID) : alt23 = 1 if alt23 == 1: # Expr.g:188:8: param_decl pass self._state.following.append(self.FOLLOW_param_decl_in_params1143) param_decl132 = self.param_decl() self._state.following.pop() if self._state.backtracking == 0: stream_param_decl.add(param_decl132.tree) # Expr.g:188:20: ( ',' param_decl )* while True: #loop24 alt24 = 2 LA24_0 = self.input.LA(1) if (LA24_0 == 82) : alt24 = 1 if alt24 == 1: # Expr.g:188:21: ',' param_decl pass char_literal133 = self.match(self.input, 82, self.FOLLOW_82_in_params1147) if self._state.backtracking == 0: stream_82.add(char_literal133) self._state.following.append(self.FOLLOW_param_decl_in_params1149) param_decl134 = self.param_decl() self._state.following.pop() if self._state.backtracking == 0: stream_param_decl.add(param_decl134.tree) else: break #loop24 char_literal135 = self.match(self.input, 76, self.FOLLOW_76_in_params1153) if self._state.backtracking == 0: stream_76.add(char_literal135) # AST Rewrite # elements: param_decl # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 189:3: -> ^( PARAMS ( param_decl )* ) # Expr.g:189:6: ^( PARAMS ( param_decl )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(PARAMS, "PARAMS") , root_1) # Expr.g:189:15: ( param_decl )* while stream_param_decl.hasNext(): self._adaptor.addChild(root_1, stream_param_decl.nextTree()) stream_param_decl.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "params" class param_decl_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.param_decl_return, self).__init__() self.tree = None # $ANTLR start "param_decl" # Expr.g:191:1: param_decl : ID ( '=' atom )? ; def param_decl(self, ): retval = self.param_decl_return() retval.start = self.input.LT(1) root_0 = None ID136 = None char_literal137 = None atom138 = None ID136_tree = None char_literal137_tree = None try: try: # Expr.g:192:2: ( ID ( '=' atom )? ) # Expr.g:192:4: ID ( '=' atom )? pass root_0 = self._adaptor.nil() ID136 = self.match(self.input, ID, self.FOLLOW_ID_in_param_decl1174) if self._state.backtracking == 0: ID136_tree = self._adaptor.createWithPayload(ID136) self._adaptor.addChild(root_0, ID136_tree) # Expr.g:192:7: ( '=' atom )? alt25 = 2 LA25_0 = self.input.LA(1) if (LA25_0 == 95) : alt25 = 1 if alt25 == 1: # Expr.g:192:8: '=' atom pass char_literal137 = self.match(self.input, 95, self.FOLLOW_95_in_param_decl1177) if self._state.backtracking == 0: char_literal137_tree = self._adaptor.createWithPayload(char_literal137) self._adaptor.addChild(root_0, char_literal137_tree) self._state.following.append(self.FOLLOW_atom_in_param_decl1179) atom138 = self.atom() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, atom138.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "param_decl" class class_decl_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.class_decl_return, self).__init__() self.tree = None # $ANTLR start "class_decl" # Expr.g:195:1: class_decl : 'class' ID ( 'extends' ID )? '{' ( class_element )* '}' -> ^( CLASS ID ( ID )? ( class_element )* ) ; def class_decl(self, ): retval = self.class_decl_return() retval.start = self.input.LT(1) root_0 = None string_literal139 = None ID140 = None string_literal141 = None ID142 = None char_literal143 = None char_literal145 = None class_element144 = None string_literal139_tree = None ID140_tree = None string_literal141_tree = None ID142_tree = None char_literal143_tree = None char_literal145_tree = None stream_132 = RewriteRuleTokenStream(self._adaptor, "token 132") stream_113 = RewriteRuleTokenStream(self._adaptor, "token 113") stream_108 = RewriteRuleTokenStream(self._adaptor, "token 108") stream_136 = RewriteRuleTokenStream(self._adaptor, "token 136") stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_class_element = RewriteRuleSubtreeStream(self._adaptor, "rule class_element") try: try: # Expr.g:196:2: ( 'class' ID ( 'extends' ID )? '{' ( class_element )* '}' -> ^( CLASS ID ( ID )? ( class_element )* ) ) # Expr.g:196:4: 'class' ID ( 'extends' ID )? '{' ( class_element )* '}' pass string_literal139 = self.match(self.input, 108, self.FOLLOW_108_in_class_decl1192) if self._state.backtracking == 0: stream_108.add(string_literal139) ID140 = self.match(self.input, ID, self.FOLLOW_ID_in_class_decl1194) if self._state.backtracking == 0: stream_ID.add(ID140) # Expr.g:196:15: ( 'extends' ID )? alt26 = 2 LA26_0 = self.input.LA(1) if (LA26_0 == 113) : alt26 = 1 if alt26 == 1: # Expr.g:196:16: 'extends' ID pass string_literal141 = self.match(self.input, 113, self.FOLLOW_113_in_class_decl1197) if self._state.backtracking == 0: stream_113.add(string_literal141) ID142 = self.match(self.input, ID, self.FOLLOW_ID_in_class_decl1199) if self._state.backtracking == 0: stream_ID.add(ID142) char_literal143 = self.match(self.input, 132, self.FOLLOW_132_in_class_decl1205) if self._state.backtracking == 0: stream_132.add(char_literal143) # Expr.g:197:7: ( class_element )* while True: #loop27 alt27 = 2 LA27_0 = self.input.LA(1) if (LA27_0 == 117 or LA27_0 == 124) : alt27 = 1 if alt27 == 1: # Expr.g:197:7: class_element pass self._state.following.append(self.FOLLOW_class_element_in_class_decl1207) class_element144 = self.class_element() self._state.following.pop() if self._state.backtracking == 0: stream_class_element.add(class_element144.tree) else: break #loop27 char_literal145 = self.match(self.input, 136, self.FOLLOW_136_in_class_decl1210) if self._state.backtracking == 0: stream_136.add(char_literal145) # AST Rewrite # elements: ID, ID, class_element # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 198:3: -> ^( CLASS ID ( ID )? ( class_element )* ) # Expr.g:198:6: ^( CLASS ID ( ID )? ( class_element )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(CLASS, "CLASS") , root_1) self._adaptor.addChild(root_1, stream_ID.nextNode() ) # Expr.g:198:17: ( ID )? if stream_ID.hasNext(): self._adaptor.addChild(root_1, stream_ID.nextNode() ) stream_ID.reset(); # Expr.g:198:21: ( class_element )* while stream_class_element.hasNext(): self._adaptor.addChild(root_1, stream_class_element.nextTree()) stream_class_element.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "class_decl" class class_element_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.class_element_return, self).__init__() self.tree = None # $ANTLR start "class_element" # Expr.g:200:1: class_element : ( var_def | constructor | func_decl ); def class_element(self, ): retval = self.class_element_return() retval.start = self.input.LT(1) root_0 = None var_def146 = None constructor147 = None func_decl148 = None try: try: # Expr.g:201:2: ( var_def | constructor | func_decl ) alt28 = 3 LA28_0 = self.input.LA(1) if (LA28_0 == 124) : alt28 = 1 elif (LA28_0 == 117) : LA28_2 = self.input.LA(2) if (LA28_2 == 120) : alt28 = 2 elif (LA28_2 == ID) : alt28 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 28, 2, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 28, 0, self.input) raise nvae if alt28 == 1: # Expr.g:201:4: var_def pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_var_def_in_class_element1236) var_def146 = self.var_def() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, var_def146.tree) elif alt28 == 2: # Expr.g:201:14: constructor pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_constructor_in_class_element1240) constructor147 = self.constructor() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, constructor147.tree) elif alt28 == 3: # Expr.g:201:28: func_decl pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_func_decl_in_class_element1244) func_decl148 = self.func_decl() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, func_decl148.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "class_element" class var_def_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.var_def_return, self).__init__() self.tree = None # $ANTLR start "var_def" # Expr.g:203:1: var_def : ( 'public' ID ( '=' expr )? ';' -> ^( VAR ID ( expr )? ) | 'public' 'static' ID ( '=' expr )? ';' -> ^( VAR 'static' ID ( expr )? ) ); def var_def(self, ): retval = self.var_def_return() retval.start = self.input.LT(1) root_0 = None string_literal149 = None ID150 = None char_literal151 = None char_literal153 = None string_literal154 = None string_literal155 = None ID156 = None char_literal157 = None char_literal159 = None expr152 = None expr158 = None string_literal149_tree = None ID150_tree = None char_literal151_tree = None char_literal153_tree = None string_literal154_tree = None string_literal155_tree = None ID156_tree = None char_literal157_tree = None char_literal159_tree = None stream_127 = RewriteRuleTokenStream(self._adaptor, "token 127") stream_95 = RewriteRuleTokenStream(self._adaptor, "token 95") stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_124 = RewriteRuleTokenStream(self._adaptor, "token 124") stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:204:2: ( 'public' ID ( '=' expr )? ';' -> ^( VAR ID ( expr )? ) | 'public' 'static' ID ( '=' expr )? ';' -> ^( VAR 'static' ID ( expr )? ) ) alt31 = 2 LA31_0 = self.input.LA(1) if (LA31_0 == 124) : LA31_1 = self.input.LA(2) if (LA31_1 == ID) : alt31 = 1 elif (LA31_1 == 127) : alt31 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 31, 1, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 31, 0, self.input) raise nvae if alt31 == 1: # Expr.g:204:4: 'public' ID ( '=' expr )? ';' pass string_literal149 = self.match(self.input, 124, self.FOLLOW_124_in_var_def1254) if self._state.backtracking == 0: stream_124.add(string_literal149) ID150 = self.match(self.input, ID, self.FOLLOW_ID_in_var_def1256) if self._state.backtracking == 0: stream_ID.add(ID150) # Expr.g:204:16: ( '=' expr )? alt29 = 2 LA29_0 = self.input.LA(1) if (LA29_0 == 95) : alt29 = 1 if alt29 == 1: # Expr.g:204:17: '=' expr pass char_literal151 = self.match(self.input, 95, self.FOLLOW_95_in_var_def1259) if self._state.backtracking == 0: stream_95.add(char_literal151) self._state.following.append(self.FOLLOW_expr_in_var_def1261) expr152 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr152.tree) char_literal153 = self.match(self.input, 92, self.FOLLOW_92_in_var_def1265) if self._state.backtracking == 0: stream_92.add(char_literal153) # AST Rewrite # elements: expr, ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 205:3: -> ^( VAR ID ( expr )? ) # Expr.g:205:6: ^( VAR ID ( expr )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(VAR, "VAR") , root_1) self._adaptor.addChild(root_1, stream_ID.nextNode() ) # Expr.g:205:15: ( expr )? if stream_expr.hasNext(): self._adaptor.addChild(root_1, stream_expr.nextTree()) stream_expr.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt31 == 2: # Expr.g:206:4: 'public' 'static' ID ( '=' expr )? ';' pass string_literal154 = self.match(self.input, 124, self.FOLLOW_124_in_var_def1283) if self._state.backtracking == 0: stream_124.add(string_literal154) string_literal155 = self.match(self.input, 127, self.FOLLOW_127_in_var_def1285) if self._state.backtracking == 0: stream_127.add(string_literal155) ID156 = self.match(self.input, ID, self.FOLLOW_ID_in_var_def1287) if self._state.backtracking == 0: stream_ID.add(ID156) # Expr.g:206:25: ( '=' expr )? alt30 = 2 LA30_0 = self.input.LA(1) if (LA30_0 == 95) : alt30 = 1 if alt30 == 1: # Expr.g:206:26: '=' expr pass char_literal157 = self.match(self.input, 95, self.FOLLOW_95_in_var_def1290) if self._state.backtracking == 0: stream_95.add(char_literal157) self._state.following.append(self.FOLLOW_expr_in_var_def1292) expr158 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr158.tree) char_literal159 = self.match(self.input, 92, self.FOLLOW_92_in_var_def1296) if self._state.backtracking == 0: stream_92.add(char_literal159) # AST Rewrite # elements: expr, ID, 127 # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 207:3: -> ^( VAR 'static' ID ( expr )? ) # Expr.g:207:6: ^( VAR 'static' ID ( expr )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(VAR, "VAR") , root_1) self._adaptor.addChild(root_1, stream_127.nextNode() ) self._adaptor.addChild(root_1, stream_ID.nextNode() ) # Expr.g:207:24: ( expr )? if stream_expr.hasNext(): self._adaptor.addChild(root_1, stream_expr.nextTree()) stream_expr.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "var_def" class constructor_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.constructor_return, self).__init__() self.tree = None # $ANTLR start "constructor" # Expr.g:209:1: constructor : 'function' 'init' params block -> ^( CONSTRUCTOR params block ) ; def constructor(self, ): retval = self.constructor_return() retval.start = self.input.LT(1) root_0 = None string_literal160 = None string_literal161 = None params162 = None block163 = None string_literal160_tree = None string_literal161_tree = None stream_117 = RewriteRuleTokenStream(self._adaptor, "token 117") stream_120 = RewriteRuleTokenStream(self._adaptor, "token 120") stream_block = RewriteRuleSubtreeStream(self._adaptor, "rule block") stream_params = RewriteRuleSubtreeStream(self._adaptor, "rule params") try: try: # Expr.g:210:2: ( 'function' 'init' params block -> ^( CONSTRUCTOR params block ) ) # Expr.g:210:4: 'function' 'init' params block pass string_literal160 = self.match(self.input, 117, self.FOLLOW_117_in_constructor1321) if self._state.backtracking == 0: stream_117.add(string_literal160) string_literal161 = self.match(self.input, 120, self.FOLLOW_120_in_constructor1323) if self._state.backtracking == 0: stream_120.add(string_literal161) self._state.following.append(self.FOLLOW_params_in_constructor1325) params162 = self.params() self._state.following.pop() if self._state.backtracking == 0: stream_params.add(params162.tree) self._state.following.append(self.FOLLOW_block_in_constructor1327) block163 = self.block() self._state.following.pop() if self._state.backtracking == 0: stream_block.add(block163.tree) # AST Rewrite # elements: params, block # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 211:3: -> ^( CONSTRUCTOR params block ) # Expr.g:211:6: ^( CONSTRUCTOR params block ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(CONSTRUCTOR, "CONSTRUCTOR") , root_1) self._adaptor.addChild(root_1, stream_params.nextTree()) self._adaptor.addChild(root_1, stream_block.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "constructor" class member_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.member_expr_return, self).__init__() self.tree = None # $ANTLR start "member_expr" # Expr.g:217:1: member_expr : primary ( '.' primary )* -> ^( MEMBER ( primary )+ ) ; def member_expr(self, ): retval = self.member_expr_return() retval.start = self.input.LT(1) root_0 = None char_literal165 = None primary164 = None primary166 = None char_literal165_tree = None stream_86 = RewriteRuleTokenStream(self._adaptor, "token 86") stream_primary = RewriteRuleSubtreeStream(self._adaptor, "rule primary") try: try: # Expr.g:218:2: ( primary ( '.' primary )* -> ^( MEMBER ( primary )+ ) ) # Expr.g:218:4: primary ( '.' primary )* pass self._state.following.append(self.FOLLOW_primary_in_member_expr1354) primary164 = self.primary() self._state.following.pop() if self._state.backtracking == 0: stream_primary.add(primary164.tree) # Expr.g:218:12: ( '.' primary )* while True: #loop32 alt32 = 2 LA32_0 = self.input.LA(1) if (LA32_0 == 86) : alt32 = 1 if alt32 == 1: # Expr.g:218:13: '.' primary pass char_literal165 = self.match(self.input, 86, self.FOLLOW_86_in_member_expr1357) if self._state.backtracking == 0: stream_86.add(char_literal165) self._state.following.append(self.FOLLOW_primary_in_member_expr1359) primary166 = self.primary() self._state.following.pop() if self._state.backtracking == 0: stream_primary.add(primary166.tree) else: break #loop32 # AST Rewrite # elements: primary # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 219:3: -> ^( MEMBER ( primary )+ ) # Expr.g:219:6: ^( MEMBER ( primary )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(MEMBER, "MEMBER") , root_1) # Expr.g:219:15: ( primary )+ if not (stream_primary.hasNext()): raise RewriteEarlyExitException() while stream_primary.hasNext(): self._adaptor.addChild(root_1, stream_primary.nextTree()) stream_primary.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "member_expr" class primary_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.primary_return, self).__init__() self.tree = None # $ANTLR start "primary" # Expr.g:221:1: primary : ID ( index_expr )* ( call_expr )? ; def primary(self, ): retval = self.primary_return() retval.start = self.input.LT(1) root_0 = None ID167 = None index_expr168 = None call_expr169 = None ID167_tree = None try: try: # Expr.g:222:2: ( ID ( index_expr )* ( call_expr )? ) # Expr.g:222:4: ID ( index_expr )* ( call_expr )? pass root_0 = self._adaptor.nil() ID167 = self.match(self.input, ID, self.FOLLOW_ID_in_primary1382) if self._state.backtracking == 0: ID167_tree = self._adaptor.createWithPayload(ID167) self._adaptor.addChild(root_0, ID167_tree) # Expr.g:222:7: ( index_expr )* while True: #loop33 alt33 = 2 LA33_0 = self.input.LA(1) if (LA33_0 == 100) : alt33 = 1 if alt33 == 1: # Expr.g:222:7: index_expr pass self._state.following.append(self.FOLLOW_index_expr_in_primary1384) index_expr168 = self.index_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, index_expr168.tree) else: break #loop33 # Expr.g:222:19: ( call_expr )? alt34 = 2 LA34_0 = self.input.LA(1) if (LA34_0 == 75) : alt34 = 1 if alt34 == 1: # Expr.g:222:19: call_expr pass self._state.following.append(self.FOLLOW_call_expr_in_primary1387) call_expr169 = self.call_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, call_expr169.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "primary" class call_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.call_expr_return, self).__init__() self.tree = None # $ANTLR start "call_expr" # Expr.g:224:1: call_expr : '(' ( expr_list )? ')' -> ^( CALL ( expr_list )? ) ; def call_expr(self, ): retval = self.call_expr_return() retval.start = self.input.LT(1) root_0 = None char_literal170 = None char_literal172 = None expr_list171 = None char_literal170_tree = None char_literal172_tree = None stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_expr_list = RewriteRuleSubtreeStream(self._adaptor, "rule expr_list") try: try: # Expr.g:225:2: ( '(' ( expr_list )? ')' -> ^( CALL ( expr_list )? ) ) # Expr.g:225:4: '(' ( expr_list )? ')' pass char_literal170 = self.match(self.input, 75, self.FOLLOW_75_in_call_expr1398) if self._state.backtracking == 0: stream_75.add(char_literal170) # Expr.g:225:8: ( expr_list )? alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == BOOL or LA35_0 == FLOAT or LA35_0 == ID or LA35_0 == INT or LA35_0 == NULL or LA35_0 == STRING or LA35_0 == 68 or LA35_0 == 75 or LA35_0 == 83 or LA35_0 == 100 or LA35_0 == 121 or LA35_0 == 126 or LA35_0 == 132) : alt35 = 1 if alt35 == 1: # Expr.g:225:8: expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_call_expr1400) expr_list171 = self.expr_list() self._state.following.pop() if self._state.backtracking == 0: stream_expr_list.add(expr_list171.tree) char_literal172 = self.match(self.input, 76, self.FOLLOW_76_in_call_expr1403) if self._state.backtracking == 0: stream_76.add(char_literal172) # AST Rewrite # elements: expr_list # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 226:3: -> ^( CALL ( expr_list )? ) # Expr.g:226:6: ^( CALL ( expr_list )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(CALL, "CALL") , root_1) # Expr.g:226:13: ( expr_list )? if stream_expr_list.hasNext(): self._adaptor.addChild(root_1, stream_expr_list.nextTree()) stream_expr_list.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "call_expr" class index_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.index_expr_return, self).__init__() self.tree = None # $ANTLR start "index_expr" # Expr.g:228:1: index_expr options {backtrack=true; } : ( '[' expr ']' -> ^( INDEX expr ) | '[' expr '..' ( expr )? ']' -> ^( SLICE expr ( expr )? ) ); def index_expr(self, ): retval = self.index_expr_return() retval.start = self.input.LT(1) root_0 = None char_literal173 = None char_literal175 = None char_literal176 = None string_literal178 = None char_literal180 = None expr174 = None expr177 = None expr179 = None char_literal173_tree = None char_literal175_tree = None char_literal176_tree = None string_literal178_tree = None char_literal180_tree = None stream_101 = RewriteRuleTokenStream(self._adaptor, "token 101") stream_88 = RewriteRuleTokenStream(self._adaptor, "token 88") stream_100 = RewriteRuleTokenStream(self._adaptor, "token 100") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:232:2: ( '[' expr ']' -> ^( INDEX expr ) | '[' expr '..' ( expr )? ']' -> ^( SLICE expr ( expr )? ) ) alt37 = 2 LA37_0 = self.input.LA(1) if (LA37_0 == 100) : LA37_1 = self.input.LA(2) if (self.synpred1_Expr()) : alt37 = 1 elif (True) : alt37 = 2 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 37, 1, self.input) raise nvae else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 37, 0, self.input) raise nvae if alt37 == 1: # Expr.g:232:4: '[' expr ']' pass char_literal173 = self.match(self.input, 100, self.FOLLOW_100_in_index_expr1439) if self._state.backtracking == 0: stream_100.add(char_literal173) self._state.following.append(self.FOLLOW_expr_in_index_expr1441) expr174 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr174.tree) char_literal175 = self.match(self.input, 101, self.FOLLOW_101_in_index_expr1443) if self._state.backtracking == 0: stream_101.add(char_literal175) # AST Rewrite # elements: expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 233:3: -> ^( INDEX expr ) # Expr.g:233:6: ^( INDEX expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(INDEX, "INDEX") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt37 == 2: # Expr.g:234:4: '[' expr '..' ( expr )? ']' pass char_literal176 = self.match(self.input, 100, self.FOLLOW_100_in_index_expr1458) if self._state.backtracking == 0: stream_100.add(char_literal176) self._state.following.append(self.FOLLOW_expr_in_index_expr1460) expr177 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr177.tree) string_literal178 = self.match(self.input, 88, self.FOLLOW_88_in_index_expr1462) if self._state.backtracking == 0: stream_88.add(string_literal178) # Expr.g:234:18: ( expr )? alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == BOOL or LA36_0 == FLOAT or LA36_0 == ID or LA36_0 == INT or LA36_0 == NULL or LA36_0 == STRING or LA36_0 == 68 or LA36_0 == 75 or LA36_0 == 83 or LA36_0 == 100 or LA36_0 == 121 or LA36_0 == 126 or LA36_0 == 132) : alt36 = 1 if alt36 == 1: # Expr.g:234:18: expr pass self._state.following.append(self.FOLLOW_expr_in_index_expr1464) expr179 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr179.tree) char_literal180 = self.match(self.input, 101, self.FOLLOW_101_in_index_expr1467) if self._state.backtracking == 0: stream_101.add(char_literal180) # AST Rewrite # elements: expr, expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 235:3: -> ^( SLICE expr ( expr )? ) # Expr.g:235:6: ^( SLICE expr ( expr )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(SLICE, "SLICE") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) # Expr.g:235:19: ( expr )? if stream_expr.hasNext(): self._adaptor.addChild(root_1, stream_expr.nextTree()) stream_expr.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "index_expr" class exec_list_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.exec_list_return, self).__init__() self.tree = None # $ANTLR start "exec_list" # Expr.g:239:1: exec_list : exec_expr ( ',' exec_expr )* -> ^( EXEC_LIST ( exec_expr )+ ) ; def exec_list(self, ): retval = self.exec_list_return() retval.start = self.input.LT(1) root_0 = None char_literal182 = None exec_expr181 = None exec_expr183 = None char_literal182_tree = None stream_82 = RewriteRuleTokenStream(self._adaptor, "token 82") stream_exec_expr = RewriteRuleSubtreeStream(self._adaptor, "rule exec_expr") try: try: # Expr.g:240:2: ( exec_expr ( ',' exec_expr )* -> ^( EXEC_LIST ( exec_expr )+ ) ) # Expr.g:240:4: exec_expr ( ',' exec_expr )* pass self._state.following.append(self.FOLLOW_exec_expr_in_exec_list1492) exec_expr181 = self.exec_expr() self._state.following.pop() if self._state.backtracking == 0: stream_exec_expr.add(exec_expr181.tree) # Expr.g:240:14: ( ',' exec_expr )* while True: #loop38 alt38 = 2 LA38_0 = self.input.LA(1) if (LA38_0 == 82) : alt38 = 1 if alt38 == 1: # Expr.g:240:15: ',' exec_expr pass char_literal182 = self.match(self.input, 82, self.FOLLOW_82_in_exec_list1495) if self._state.backtracking == 0: stream_82.add(char_literal182) self._state.following.append(self.FOLLOW_exec_expr_in_exec_list1497) exec_expr183 = self.exec_expr() self._state.following.pop() if self._state.backtracking == 0: stream_exec_expr.add(exec_expr183.tree) else: break #loop38 # AST Rewrite # elements: exec_expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 241:3: -> ^( EXEC_LIST ( exec_expr )+ ) # Expr.g:241:6: ^( EXEC_LIST ( exec_expr )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(EXEC_LIST, "EXEC_LIST") , root_1) # Expr.g:241:18: ( exec_expr )+ if not (stream_exec_expr.hasNext()): raise RewriteEarlyExitException() while stream_exec_expr.hasNext(): self._adaptor.addChild(root_1, stream_exec_expr.nextTree()) stream_exec_expr.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "exec_list" class member_list_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.member_list_return, self).__init__() self.tree = None # $ANTLR start "member_list" # Expr.g:243:1: member_list : member_expr ( ',' member_expr )* ; def member_list(self, ): retval = self.member_list_return() retval.start = self.input.LT(1) root_0 = None char_literal185 = None member_expr184 = None member_expr186 = None char_literal185_tree = None try: try: # Expr.g:244:2: ( member_expr ( ',' member_expr )* ) # Expr.g:244:4: member_expr ( ',' member_expr )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_member_expr_in_member_list1520) member_expr184 = self.member_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, member_expr184.tree) # Expr.g:244:16: ( ',' member_expr )* while True: #loop39 alt39 = 2 LA39_0 = self.input.LA(1) if (LA39_0 == 82) : alt39 = 1 if alt39 == 1: # Expr.g:244:17: ',' member_expr pass char_literal185 = self.match(self.input, 82, self.FOLLOW_82_in_member_list1523) if self._state.backtracking == 0: char_literal185_tree = self._adaptor.createWithPayload(char_literal185) self._adaptor.addChild(root_0, char_literal185_tree) self._state.following.append(self.FOLLOW_member_expr_in_member_list1525) member_expr186 = self.member_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, member_expr186.tree) else: break #loop39 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "member_list" class exec_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.exec_expr_return, self).__init__() self.tree = None # $ANTLR start "exec_expr" # Expr.g:246:1: exec_expr : ( member_expr ( assign_op expr -> ^( ASSIGN member_expr assign_op expr ) | '++' -> ^( POST_INC member_expr ) | '--' -> ^( POST_DEC member_expr ) | -> member_expr ) | '++' member_expr -> ^( PRE_INC member_expr ) | '--' member_expr -> ^( PRE_DEC member_expr ) ); def exec_expr(self, ): retval = self.exec_expr_return() retval.start = self.input.LT(1) root_0 = None string_literal190 = None string_literal191 = None string_literal192 = None string_literal194 = None member_expr187 = None assign_op188 = None expr189 = None member_expr193 = None member_expr195 = None string_literal190_tree = None string_literal191_tree = None string_literal192_tree = None string_literal194_tree = None stream_80 = RewriteRuleTokenStream(self._adaptor, "token 80") stream_84 = RewriteRuleTokenStream(self._adaptor, "token 84") stream_member_expr = RewriteRuleSubtreeStream(self._adaptor, "rule member_expr") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") stream_assign_op = RewriteRuleSubtreeStream(self._adaptor, "rule assign_op") try: try: # Expr.g:247:2: ( member_expr ( assign_op expr -> ^( ASSIGN member_expr assign_op expr ) | '++' -> ^( POST_INC member_expr ) | '--' -> ^( POST_DEC member_expr ) | -> member_expr ) | '++' member_expr -> ^( PRE_INC member_expr ) | '--' member_expr -> ^( PRE_DEC member_expr ) ) alt41 = 3 LA41 = self.input.LA(1) if LA41 == ID: alt41 = 1 elif LA41 == 80: alt41 = 2 elif LA41 == 84: alt41 = 3 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 41, 0, self.input) raise nvae if alt41 == 1: # Expr.g:247:4: member_expr ( assign_op expr -> ^( ASSIGN member_expr assign_op expr ) | '++' -> ^( POST_INC member_expr ) | '--' -> ^( POST_DEC member_expr ) | -> member_expr ) pass self._state.following.append(self.FOLLOW_member_expr_in_exec_expr1537) member_expr187 = self.member_expr() self._state.following.pop() if self._state.backtracking == 0: stream_member_expr.add(member_expr187.tree) # Expr.g:248:3: ( assign_op expr -> ^( ASSIGN member_expr assign_op expr ) | '++' -> ^( POST_INC member_expr ) | '--' -> ^( POST_DEC member_expr ) | -> member_expr ) alt40 = 4 LA40 = self.input.LA(1) if LA40 == 71 or LA40 == 74 or LA40 == 78 or LA40 == 81 or LA40 == 85 or LA40 == 90 or LA40 == 95 or LA40 == 103 or LA40 == 134: alt40 = 1 elif LA40 == 80: alt40 = 2 elif LA40 == 84: alt40 = 3 elif LA40 == 76 or LA40 == 82 or LA40 == 92: alt40 = 4 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 40, 0, self.input) raise nvae if alt40 == 1: # Expr.g:248:4: assign_op expr pass self._state.following.append(self.FOLLOW_assign_op_in_exec_expr1542) assign_op188 = self.assign_op() self._state.following.pop() if self._state.backtracking == 0: stream_assign_op.add(assign_op188.tree) self._state.following.append(self.FOLLOW_expr_in_exec_expr1544) expr189 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr189.tree) # AST Rewrite # elements: member_expr, expr, assign_op # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 249:4: -> ^( ASSIGN member_expr assign_op expr ) # Expr.g:249:7: ^( ASSIGN member_expr assign_op expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(ASSIGN, "ASSIGN") , root_1) self._adaptor.addChild(root_1, stream_member_expr.nextTree()) self._adaptor.addChild(root_1, stream_assign_op.nextTree()) self._adaptor.addChild(root_1, stream_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt40 == 2: # Expr.g:250:5: '++' pass string_literal190 = self.match(self.input, 80, self.FOLLOW_80_in_exec_expr1565) if self._state.backtracking == 0: stream_80.add(string_literal190) # AST Rewrite # elements: member_expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 251:4: -> ^( POST_INC member_expr ) # Expr.g:251:7: ^( POST_INC member_expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(POST_INC, "POST_INC") , root_1) self._adaptor.addChild(root_1, stream_member_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt40 == 3: # Expr.g:252:5: '--' pass string_literal191 = self.match(self.input, 84, self.FOLLOW_84_in_exec_expr1582) if self._state.backtracking == 0: stream_84.add(string_literal191) # AST Rewrite # elements: member_expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 253:4: -> ^( POST_DEC member_expr ) # Expr.g:253:7: ^( POST_DEC member_expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(POST_DEC, "POST_DEC") , root_1) self._adaptor.addChild(root_1, stream_member_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt40 == 4: # Expr.g:255:4: pass # AST Rewrite # elements: member_expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 255:4: -> member_expr self._adaptor.addChild(root_0, stream_member_expr.nextTree()) retval.tree = root_0 elif alt41 == 2: # Expr.g:257:4: '++' member_expr pass string_literal192 = self.match(self.input, 80, self.FOLLOW_80_in_exec_expr1613) if self._state.backtracking == 0: stream_80.add(string_literal192) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr1615) member_expr193 = self.member_expr() self._state.following.pop() if self._state.backtracking == 0: stream_member_expr.add(member_expr193.tree) # AST Rewrite # elements: member_expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 258:3: -> ^( PRE_INC member_expr ) # Expr.g:258:6: ^( PRE_INC member_expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(PRE_INC, "PRE_INC") , root_1) self._adaptor.addChild(root_1, stream_member_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt41 == 3: # Expr.g:259:4: '--' member_expr pass string_literal194 = self.match(self.input, 84, self.FOLLOW_84_in_exec_expr1630) if self._state.backtracking == 0: stream_84.add(string_literal194) self._state.following.append(self.FOLLOW_member_expr_in_exec_expr1632) member_expr195 = self.member_expr() self._state.following.pop() if self._state.backtracking == 0: stream_member_expr.add(member_expr195.tree) # AST Rewrite # elements: member_expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 260:3: -> ^( PRE_DEC member_expr ) # Expr.g:260:6: ^( PRE_DEC member_expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(PRE_DEC, "PRE_DEC") , root_1) self._adaptor.addChild(root_1, stream_member_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "exec_expr" class assign_op_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.assign_op_return, self).__init__() self.tree = None # $ANTLR start "assign_op" # Expr.g:262:1: assign_op : ( '=' | '+=' | '-=' | '*=' | '/=' | '%=' | '&=' | '^=' | '|=' ); def assign_op(self, ): retval = self.assign_op_return() retval.start = self.input.LT(1) root_0 = None set196 = None set196_tree = None try: try: # Expr.g:263:2: ( '=' | '+=' | '-=' | '*=' | '/=' | '%=' | '&=' | '^=' | '|=' ) # Expr.g: pass root_0 = self._adaptor.nil() set196 = self.input.LT(1) if self.input.LA(1) == 71 or self.input.LA(1) == 74 or self.input.LA(1) == 78 or self.input.LA(1) == 81 or self.input.LA(1) == 85 or self.input.LA(1) == 90 or self.input.LA(1) == 95 or self.input.LA(1) == 103 or self.input.LA(1) == 134: self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set196)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "assign_op" class exec_stmt_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.exec_stmt_return, self).__init__() self.tree = None # $ANTLR start "exec_stmt" # Expr.g:265:1: exec_stmt : exec_list ';' -> ^( EXEC_STMT exec_list ) ; def exec_stmt(self, ): retval = self.exec_stmt_return() retval.start = self.input.LT(1) root_0 = None char_literal198 = None exec_list197 = None char_literal198_tree = None stream_92 = RewriteRuleTokenStream(self._adaptor, "token 92") stream_exec_list = RewriteRuleSubtreeStream(self._adaptor, "rule exec_list") try: try: # Expr.g:266:2: ( exec_list ';' -> ^( EXEC_STMT exec_list ) ) # Expr.g:266:4: exec_list ';' pass self._state.following.append(self.FOLLOW_exec_list_in_exec_stmt1678) exec_list197 = self.exec_list() self._state.following.pop() if self._state.backtracking == 0: stream_exec_list.add(exec_list197.tree) char_literal198 = self.match(self.input, 92, self.FOLLOW_92_in_exec_stmt1680) if self._state.backtracking == 0: stream_92.add(char_literal198) # AST Rewrite # elements: exec_list # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 267:3: -> ^( EXEC_STMT exec_list ) # Expr.g:267:6: ^( EXEC_STMT exec_list ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(EXEC_STMT, "EXEC_STMT") , root_1) self._adaptor.addChild(root_1, stream_exec_list.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "exec_stmt" class expr_list_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.expr_list_return, self).__init__() self.tree = None # $ANTLR start "expr_list" # Expr.g:272:1: expr_list : expr ( ',' expr )* ( ',' )? -> ^( EXPR_LIST ( expr )+ ) ; def expr_list(self, ): retval = self.expr_list_return() retval.start = self.input.LT(1) root_0 = None char_literal200 = None char_literal202 = None expr199 = None expr201 = None char_literal200_tree = None char_literal202_tree = None stream_82 = RewriteRuleTokenStream(self._adaptor, "token 82") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:273:2: ( expr ( ',' expr )* ( ',' )? -> ^( EXPR_LIST ( expr )+ ) ) # Expr.g:273:4: expr ( ',' expr )* ( ',' )? pass self._state.following.append(self.FOLLOW_expr_in_expr_list1703) expr199 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr199.tree) # Expr.g:273:9: ( ',' expr )* while True: #loop42 alt42 = 2 LA42_0 = self.input.LA(1) if (LA42_0 == 82) : LA42_1 = self.input.LA(2) if (LA42_1 == BOOL or LA42_1 == FLOAT or LA42_1 == ID or LA42_1 == INT or LA42_1 == NULL or LA42_1 == STRING or LA42_1 == 68 or LA42_1 == 75 or LA42_1 == 83 or LA42_1 == 100 or LA42_1 == 121 or LA42_1 == 126 or LA42_1 == 132) : alt42 = 1 if alt42 == 1: # Expr.g:273:10: ',' expr pass char_literal200 = self.match(self.input, 82, self.FOLLOW_82_in_expr_list1706) if self._state.backtracking == 0: stream_82.add(char_literal200) self._state.following.append(self.FOLLOW_expr_in_expr_list1708) expr201 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr201.tree) else: break #loop42 # Expr.g:273:21: ( ',' )? alt43 = 2 LA43_0 = self.input.LA(1) if (LA43_0 == 82) : alt43 = 1 if alt43 == 1: # Expr.g:273:21: ',' pass char_literal202 = self.match(self.input, 82, self.FOLLOW_82_in_expr_list1712) if self._state.backtracking == 0: stream_82.add(char_literal202) # AST Rewrite # elements: expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 274:3: -> ^( EXPR_LIST ( expr )+ ) # Expr.g:274:6: ^( EXPR_LIST ( expr )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(EXPR_LIST, "EXPR_LIST") , root_1) # Expr.g:274:18: ( expr )+ if not (stream_expr.hasNext()): raise RewriteEarlyExitException() while stream_expr.hasNext(): self._adaptor.addChild(root_1, stream_expr.nextTree()) stream_expr.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "expr_list" class expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.expr_return, self).__init__() self.tree = None # $ANTLR start "expr" # Expr.g:276:1: expr : logic_or_expr ; def expr(self, ): retval = self.expr_return() retval.start = self.input.LT(1) root_0 = None logic_or_expr203 = None try: try: # Expr.g:277:2: ( logic_or_expr ) # Expr.g:277:4: logic_or_expr pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_logic_or_expr_in_expr1734) logic_or_expr203 = self.logic_or_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logic_or_expr203.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "expr" class logic_or_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.logic_or_expr_return, self).__init__() self.tree = None # $ANTLR start "logic_or_expr" # Expr.g:279:1: logic_or_expr : logic_and_expr ( '||' ^ logic_and_expr )* ; def logic_or_expr(self, ): retval = self.logic_or_expr_return() retval.start = self.input.LT(1) root_0 = None string_literal205 = None logic_and_expr204 = None logic_and_expr206 = None string_literal205_tree = None try: try: # Expr.g:280:2: ( logic_and_expr ( '||' ^ logic_and_expr )* ) # Expr.g:280:4: logic_and_expr ( '||' ^ logic_and_expr )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_logic_and_expr_in_logic_or_expr1744) logic_and_expr204 = self.logic_and_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logic_and_expr204.tree) # Expr.g:280:19: ( '||' ^ logic_and_expr )* while True: #loop44 alt44 = 2 LA44_0 = self.input.LA(1) if (LA44_0 == 135) : alt44 = 1 if alt44 == 1: # Expr.g:280:20: '||' ^ logic_and_expr pass string_literal205 = self.match(self.input, 135, self.FOLLOW_135_in_logic_or_expr1747) if self._state.backtracking == 0: string_literal205_tree = self._adaptor.createWithPayload(string_literal205) root_0 = self._adaptor.becomeRoot(string_literal205_tree, root_0) self._state.following.append(self.FOLLOW_logic_and_expr_in_logic_or_expr1750) logic_and_expr206 = self.logic_and_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, logic_and_expr206.tree) else: break #loop44 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "logic_or_expr" class logic_and_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.logic_and_expr_return, self).__init__() self.tree = None # $ANTLR start "logic_and_expr" # Expr.g:282:1: logic_and_expr : bitwise_or_expr ( '&&' ^ bitwise_or_expr )* ; def logic_and_expr(self, ): retval = self.logic_and_expr_return() retval.start = self.input.LT(1) root_0 = None string_literal208 = None bitwise_or_expr207 = None bitwise_or_expr209 = None string_literal208_tree = None try: try: # Expr.g:283:2: ( bitwise_or_expr ( '&&' ^ bitwise_or_expr )* ) # Expr.g:283:4: bitwise_or_expr ( '&&' ^ bitwise_or_expr )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwise_or_expr_in_logic_and_expr1762) bitwise_or_expr207 = self.bitwise_or_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwise_or_expr207.tree) # Expr.g:283:20: ( '&&' ^ bitwise_or_expr )* while True: #loop45 alt45 = 2 LA45_0 = self.input.LA(1) if (LA45_0 == 72) : alt45 = 1 if alt45 == 1: # Expr.g:283:21: '&&' ^ bitwise_or_expr pass string_literal208 = self.match(self.input, 72, self.FOLLOW_72_in_logic_and_expr1765) if self._state.backtracking == 0: string_literal208_tree = self._adaptor.createWithPayload(string_literal208) root_0 = self._adaptor.becomeRoot(string_literal208_tree, root_0) self._state.following.append(self.FOLLOW_bitwise_or_expr_in_logic_and_expr1768) bitwise_or_expr209 = self.bitwise_or_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwise_or_expr209.tree) else: break #loop45 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "logic_and_expr" class bitwise_or_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.bitwise_or_expr_return, self).__init__() self.tree = None # $ANTLR start "bitwise_or_expr" # Expr.g:285:1: bitwise_or_expr : bitwise_xor_expr ( '|' ^ bitwise_xor_expr )* ; def bitwise_or_expr(self, ): retval = self.bitwise_or_expr_return() retval.start = self.input.LT(1) root_0 = None char_literal211 = None bitwise_xor_expr210 = None bitwise_xor_expr212 = None char_literal211_tree = None try: try: # Expr.g:286:2: ( bitwise_xor_expr ( '|' ^ bitwise_xor_expr )* ) # Expr.g:286:4: bitwise_xor_expr ( '|' ^ bitwise_xor_expr )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwise_xor_expr_in_bitwise_or_expr1780) bitwise_xor_expr210 = self.bitwise_xor_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwise_xor_expr210.tree) # Expr.g:286:21: ( '|' ^ bitwise_xor_expr )* while True: #loop46 alt46 = 2 LA46_0 = self.input.LA(1) if (LA46_0 == 133) : alt46 = 1 if alt46 == 1: # Expr.g:286:22: '|' ^ bitwise_xor_expr pass char_literal211 = self.match(self.input, 133, self.FOLLOW_133_in_bitwise_or_expr1783) if self._state.backtracking == 0: char_literal211_tree = self._adaptor.createWithPayload(char_literal211) root_0 = self._adaptor.becomeRoot(char_literal211_tree, root_0) self._state.following.append(self.FOLLOW_bitwise_xor_expr_in_bitwise_or_expr1786) bitwise_xor_expr212 = self.bitwise_xor_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwise_xor_expr212.tree) else: break #loop46 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "bitwise_or_expr" class bitwise_xor_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.bitwise_xor_expr_return, self).__init__() self.tree = None # $ANTLR start "bitwise_xor_expr" # Expr.g:288:1: bitwise_xor_expr : bitwise_and_expr ( '^' ^ bitwise_and_expr )* ; def bitwise_xor_expr(self, ): retval = self.bitwise_xor_expr_return() retval.start = self.input.LT(1) root_0 = None char_literal214 = None bitwise_and_expr213 = None bitwise_and_expr215 = None char_literal214_tree = None try: try: # Expr.g:289:2: ( bitwise_and_expr ( '^' ^ bitwise_and_expr )* ) # Expr.g:289:4: bitwise_and_expr ( '^' ^ bitwise_and_expr )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_bitwise_and_expr_in_bitwise_xor_expr1798) bitwise_and_expr213 = self.bitwise_and_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwise_and_expr213.tree) # Expr.g:289:21: ( '^' ^ bitwise_and_expr )* while True: #loop47 alt47 = 2 LA47_0 = self.input.LA(1) if (LA47_0 == 102) : alt47 = 1 if alt47 == 1: # Expr.g:289:22: '^' ^ bitwise_and_expr pass char_literal214 = self.match(self.input, 102, self.FOLLOW_102_in_bitwise_xor_expr1801) if self._state.backtracking == 0: char_literal214_tree = self._adaptor.createWithPayload(char_literal214) root_0 = self._adaptor.becomeRoot(char_literal214_tree, root_0) self._state.following.append(self.FOLLOW_bitwise_and_expr_in_bitwise_xor_expr1804) bitwise_and_expr215 = self.bitwise_and_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, bitwise_and_expr215.tree) else: break #loop47 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "bitwise_xor_expr" class bitwise_and_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.bitwise_and_expr_return, self).__init__() self.tree = None # $ANTLR start "bitwise_and_expr" # Expr.g:291:1: bitwise_and_expr : relation_expr ( '&' ^ relation_expr )* ; def bitwise_and_expr(self, ): retval = self.bitwise_and_expr_return() retval.start = self.input.LT(1) root_0 = None char_literal217 = None relation_expr216 = None relation_expr218 = None char_literal217_tree = None try: try: # Expr.g:292:2: ( relation_expr ( '&' ^ relation_expr )* ) # Expr.g:292:4: relation_expr ( '&' ^ relation_expr )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_relation_expr_in_bitwise_and_expr1816) relation_expr216 = self.relation_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, relation_expr216.tree) # Expr.g:292:18: ( '&' ^ relation_expr )* while True: #loop48 alt48 = 2 LA48_0 = self.input.LA(1) if (LA48_0 == 73) : alt48 = 1 if alt48 == 1: # Expr.g:292:19: '&' ^ relation_expr pass char_literal217 = self.match(self.input, 73, self.FOLLOW_73_in_bitwise_and_expr1819) if self._state.backtracking == 0: char_literal217_tree = self._adaptor.createWithPayload(char_literal217) root_0 = self._adaptor.becomeRoot(char_literal217_tree, root_0) self._state.following.append(self.FOLLOW_relation_expr_in_bitwise_and_expr1822) relation_expr218 = self.relation_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, relation_expr218.tree) else: break #loop48 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "bitwise_and_expr" class relation_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.relation_expr_return, self).__init__() self.tree = None # $ANTLR start "relation_expr" # Expr.g:294:1: relation_expr : add_expr ( ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) ^ add_expr )? ; def relation_expr(self, ): retval = self.relation_expr_return() retval.start = self.input.LT(1) root_0 = None set220 = None add_expr219 = None add_expr221 = None set220_tree = None try: try: # Expr.g:295:2: ( add_expr ( ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) ^ add_expr )? ) # Expr.g:295:4: add_expr ( ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) ^ add_expr )? pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_add_expr_in_relation_expr1834) add_expr219 = self.add_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, add_expr219.tree) # Expr.g:295:13: ( ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) ^ add_expr )? alt49 = 2 LA49_0 = self.input.LA(1) if (LA49_0 == 69 or (93 <= LA49_0 <= 94) or LA49_0 == 96 or (98 <= LA49_0 <= 99)) : alt49 = 1 if alt49 == 1: # Expr.g:295:14: ( '<' | '>' | '<=' | '>=' | '==' | '!=' ) ^ add_expr pass set220 = self.input.LT(1) set220 = self.input.LT(1) if self.input.LA(1) == 69 or (93 <= self.input.LA(1) <= 94) or self.input.LA(1) == 96 or (98 <= self.input.LA(1) <= 99): self.input.consume() if self._state.backtracking == 0: root_0 = self._adaptor.becomeRoot(self._adaptor.createWithPayload(set220), root_0) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_add_expr_in_relation_expr1852) add_expr221 = self.add_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, add_expr221.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "relation_expr" class add_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.add_expr_return, self).__init__() self.tree = None # $ANTLR start "add_expr" # Expr.g:297:1: add_expr : mul_expr ( ( '+' | '-' ) ^ mul_expr )* ; def add_expr(self, ): retval = self.add_expr_return() retval.start = self.input.LT(1) root_0 = None set223 = None mul_expr222 = None mul_expr224 = None set223_tree = None try: try: # Expr.g:298:2: ( mul_expr ( ( '+' | '-' ) ^ mul_expr )* ) # Expr.g:298:4: mul_expr ( ( '+' | '-' ) ^ mul_expr )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_mul_expr_in_add_expr1864) mul_expr222 = self.mul_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, mul_expr222.tree) # Expr.g:298:13: ( ( '+' | '-' ) ^ mul_expr )* while True: #loop50 alt50 = 2 LA50_0 = self.input.LA(1) if (LA50_0 == 79 or LA50_0 == 83) : alt50 = 1 if alt50 == 1: # Expr.g:298:14: ( '+' | '-' ) ^ mul_expr pass set223 = self.input.LT(1) set223 = self.input.LT(1) if self.input.LA(1) == 79 or self.input.LA(1) == 83: self.input.consume() if self._state.backtracking == 0: root_0 = self._adaptor.becomeRoot(self._adaptor.createWithPayload(set223), root_0) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_mul_expr_in_add_expr1874) mul_expr224 = self.mul_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, mul_expr224.tree) else: break #loop50 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "add_expr" class mul_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.mul_expr_return, self).__init__() self.tree = None # $ANTLR start "mul_expr" # Expr.g:300:1: mul_expr : not_expr ( ( '*' | '/' | '%' ) ^ not_expr )* ; def mul_expr(self, ): retval = self.mul_expr_return() retval.start = self.input.LT(1) root_0 = None set226 = None not_expr225 = None not_expr227 = None set226_tree = None try: try: # Expr.g:301:2: ( not_expr ( ( '*' | '/' | '%' ) ^ not_expr )* ) # Expr.g:301:4: not_expr ( ( '*' | '/' | '%' ) ^ not_expr )* pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_not_expr_in_mul_expr1886) not_expr225 = self.not_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, not_expr225.tree) # Expr.g:301:13: ( ( '*' | '/' | '%' ) ^ not_expr )* while True: #loop51 alt51 = 2 LA51_0 = self.input.LA(1) if (LA51_0 == 70 or LA51_0 == 77 or LA51_0 == 89) : alt51 = 1 if alt51 == 1: # Expr.g:301:14: ( '*' | '/' | '%' ) ^ not_expr pass set226 = self.input.LT(1) set226 = self.input.LT(1) if self.input.LA(1) == 70 or self.input.LA(1) == 77 or self.input.LA(1) == 89: self.input.consume() if self._state.backtracking == 0: root_0 = self._adaptor.becomeRoot(self._adaptor.createWithPayload(set226), root_0) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse self._state.following.append(self.FOLLOW_not_expr_in_mul_expr1898) not_expr227 = self.not_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, not_expr227.tree) else: break #loop51 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "mul_expr" class not_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.not_expr_return, self).__init__() self.tree = None # $ANTLR start "not_expr" # Expr.g:303:1: not_expr : (op= '!' )? negative_expr -> {$op != None}? ^( '!' negative_expr ) -> negative_expr ; def not_expr(self, ): retval = self.not_expr_return() retval.start = self.input.LT(1) root_0 = None op = None negative_expr228 = None op_tree = None stream_68 = RewriteRuleTokenStream(self._adaptor, "token 68") stream_negative_expr = RewriteRuleSubtreeStream(self._adaptor, "rule negative_expr") try: try: # Expr.g:304:2: ( (op= '!' )? negative_expr -> {$op != None}? ^( '!' negative_expr ) -> negative_expr ) # Expr.g:304:4: (op= '!' )? negative_expr pass # Expr.g:304:6: (op= '!' )? alt52 = 2 LA52_0 = self.input.LA(1) if (LA52_0 == 68) : alt52 = 1 if alt52 == 1: # Expr.g:304:6: op= '!' pass op = self.match(self.input, 68, self.FOLLOW_68_in_not_expr1912) if self._state.backtracking == 0: stream_68.add(op) self._state.following.append(self.FOLLOW_negative_expr_in_not_expr1915) negative_expr228 = self.negative_expr() self._state.following.pop() if self._state.backtracking == 0: stream_negative_expr.add(negative_expr228.tree) # AST Rewrite # elements: negative_expr, negative_expr, 68 # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() if op != None: # 305:3: -> {$op != None}? ^( '!' negative_expr ) # Expr.g:306:4: ^( '!' negative_expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( stream_68.nextNode() , root_1) self._adaptor.addChild(root_1, stream_negative_expr.nextTree()) self._adaptor.addChild(root_0, root_1) else: # 307:4: -> negative_expr self._adaptor.addChild(root_0, stream_negative_expr.nextTree()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "not_expr" class negative_expr_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.negative_expr_return, self).__init__() self.tree = None # $ANTLR start "negative_expr" # Expr.g:309:1: negative_expr : (op= '-' )? atom -> {$op != None}? ^( NEGATIVE atom ) -> atom ; def negative_expr(self, ): retval = self.negative_expr_return() retval.start = self.input.LT(1) root_0 = None op = None atom229 = None op_tree = None stream_83 = RewriteRuleTokenStream(self._adaptor, "token 83") stream_atom = RewriteRuleSubtreeStream(self._adaptor, "rule atom") try: try: # Expr.g:310:2: ( (op= '-' )? atom -> {$op != None}? ^( NEGATIVE atom ) -> atom ) # Expr.g:310:4: (op= '-' )? atom pass # Expr.g:310:4: (op= '-' )? alt53 = 2 LA53_0 = self.input.LA(1) if (LA53_0 == 83) : alt53 = 1 if alt53 == 1: # Expr.g:310:5: op= '-' pass op = self.match(self.input, 83, self.FOLLOW_83_in_negative_expr1950) if self._state.backtracking == 0: stream_83.add(op) self._state.following.append(self.FOLLOW_atom_in_negative_expr1954) atom229 = self.atom() self._state.following.pop() if self._state.backtracking == 0: stream_atom.add(atom229.tree) # AST Rewrite # elements: atom, atom # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() if op != None: # 311:3: -> {$op != None}? ^( NEGATIVE atom ) # Expr.g:312:4: ^( NEGATIVE atom ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(NEGATIVE, "NEGATIVE") , root_1) self._adaptor.addChild(root_1, stream_atom.nextTree()) self._adaptor.addChild(root_0, root_1) else: # 313:4: -> atom self._adaptor.addChild(root_0, stream_atom.nextTree()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "negative_expr" class atom_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.atom_return, self).__init__() self.tree = None # $ANTLR start "atom" # Expr.g:316:1: atom : ( literal | member_expr | array_decl | object_decl | new_clause | sprintf | '(' expr ')' -> expr ); def atom(self, ): retval = self.atom_return() retval.start = self.input.LT(1) root_0 = None char_literal236 = None char_literal238 = None literal230 = None member_expr231 = None array_decl232 = None object_decl233 = None new_clause234 = None sprintf235 = None expr237 = None char_literal236_tree = None char_literal238_tree = None stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") try: try: # Expr.g:317:2: ( literal | member_expr | array_decl | object_decl | new_clause | sprintf | '(' expr ')' -> expr ) alt54 = 7 LA54 = self.input.LA(1) if LA54 == BOOL or LA54 == FLOAT or LA54 == INT or LA54 == NULL or LA54 == STRING: alt54 = 1 elif LA54 == ID: alt54 = 2 elif LA54 == 100: alt54 = 3 elif LA54 == 132: alt54 = 4 elif LA54 == 121: alt54 = 5 elif LA54 == 126: alt54 = 6 elif LA54 == 75: alt54 = 7 else: if self._state.backtracking > 0: raise BacktrackingFailed nvae = NoViableAltException("", 54, 0, self.input) raise nvae if alt54 == 1: # Expr.g:317:4: literal pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_literal_in_atom1987) literal230 = self.literal() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, literal230.tree) elif alt54 == 2: # Expr.g:318:4: member_expr pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_member_expr_in_atom1992) member_expr231 = self.member_expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, member_expr231.tree) elif alt54 == 3: # Expr.g:319:4: array_decl pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_array_decl_in_atom1997) array_decl232 = self.array_decl() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, array_decl232.tree) elif alt54 == 4: # Expr.g:320:4: object_decl pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_object_decl_in_atom2002) object_decl233 = self.object_decl() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, object_decl233.tree) elif alt54 == 5: # Expr.g:321:4: new_clause pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_new_clause_in_atom2007) new_clause234 = self.new_clause() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, new_clause234.tree) elif alt54 == 6: # Expr.g:322:4: sprintf pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_sprintf_in_atom2012) sprintf235 = self.sprintf() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, sprintf235.tree) elif alt54 == 7: # Expr.g:323:4: '(' expr ')' pass char_literal236 = self.match(self.input, 75, self.FOLLOW_75_in_atom2017) if self._state.backtracking == 0: stream_75.add(char_literal236) self._state.following.append(self.FOLLOW_expr_in_atom2019) expr237 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr237.tree) char_literal238 = self.match(self.input, 76, self.FOLLOW_76_in_atom2021) if self._state.backtracking == 0: stream_76.add(char_literal238) # AST Rewrite # elements: expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 323:17: -> expr self._adaptor.addChild(root_0, stream_expr.nextTree()) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "atom" class literal_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.literal_return, self).__init__() self.tree = None # $ANTLR start "literal" # Expr.g:325:1: literal : ( BOOL | NULL | INT | FLOAT | STRING ); def literal(self, ): retval = self.literal_return() retval.start = self.input.LT(1) root_0 = None set239 = None set239_tree = None try: try: # Expr.g:326:2: ( BOOL | NULL | INT | FLOAT | STRING ) # Expr.g: pass root_0 = self._adaptor.nil() set239 = self.input.LT(1) if self.input.LA(1) == BOOL or self.input.LA(1) == FLOAT or self.input.LA(1) == INT or self.input.LA(1) == NULL or self.input.LA(1) == STRING: self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set239)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "literal" class new_clause_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.new_clause_return, self).__init__() self.tree = None # $ANTLR start "new_clause" # Expr.g:329:1: new_clause : 'new' module call_expr -> ^( NEW module call_expr ) ; def new_clause(self, ): retval = self.new_clause_return() retval.start = self.input.LT(1) root_0 = None string_literal240 = None module241 = None call_expr242 = None string_literal240_tree = None stream_121 = RewriteRuleTokenStream(self._adaptor, "token 121") stream_module = RewriteRuleSubtreeStream(self._adaptor, "rule module") stream_call_expr = RewriteRuleSubtreeStream(self._adaptor, "rule call_expr") try: try: # Expr.g:330:2: ( 'new' module call_expr -> ^( NEW module call_expr ) ) # Expr.g:330:4: 'new' module call_expr pass string_literal240 = self.match(self.input, 121, self.FOLLOW_121_in_new_clause2062) if self._state.backtracking == 0: stream_121.add(string_literal240) self._state.following.append(self.FOLLOW_module_in_new_clause2064) module241 = self.module() self._state.following.pop() if self._state.backtracking == 0: stream_module.add(module241.tree) self._state.following.append(self.FOLLOW_call_expr_in_new_clause2066) call_expr242 = self.call_expr() self._state.following.pop() if self._state.backtracking == 0: stream_call_expr.add(call_expr242.tree) # AST Rewrite # elements: module, call_expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 331:3: -> ^( NEW module call_expr ) # Expr.g:331:6: ^( NEW module call_expr ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(NEW, "NEW") , root_1) self._adaptor.addChild(root_1, stream_module.nextTree()) self._adaptor.addChild(root_1, stream_call_expr.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "new_clause" class module_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.module_return, self).__init__() self.tree = None # $ANTLR start "module" # Expr.g:333:1: module : ID ( '.' ID )* -> ^( MODULE ( ID )+ ) ; def module(self, ): retval = self.module_return() retval.start = self.input.LT(1) root_0 = None ID243 = None char_literal244 = None ID245 = None ID243_tree = None char_literal244_tree = None ID245_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_86 = RewriteRuleTokenStream(self._adaptor, "token 86") try: try: # Expr.g:334:2: ( ID ( '.' ID )* -> ^( MODULE ( ID )+ ) ) # Expr.g:334:4: ID ( '.' ID )* pass ID243 = self.match(self.input, ID, self.FOLLOW_ID_in_module2088) if self._state.backtracking == 0: stream_ID.add(ID243) # Expr.g:334:7: ( '.' ID )* while True: #loop55 alt55 = 2 LA55_0 = self.input.LA(1) if (LA55_0 == 86) : alt55 = 1 if alt55 == 1: # Expr.g:334:8: '.' ID pass char_literal244 = self.match(self.input, 86, self.FOLLOW_86_in_module2091) if self._state.backtracking == 0: stream_86.add(char_literal244) ID245 = self.match(self.input, ID, self.FOLLOW_ID_in_module2093) if self._state.backtracking == 0: stream_ID.add(ID245) else: break #loop55 # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 335:3: -> ^( MODULE ( ID )+ ) # Expr.g:335:6: ^( MODULE ( ID )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(MODULE, "MODULE") , root_1) # Expr.g:335:15: ( ID )+ if not (stream_ID.hasNext()): raise RewriteEarlyExitException() while stream_ID.hasNext(): self._adaptor.addChild(root_1, stream_ID.nextNode() ) stream_ID.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "module" class array_decl_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.array_decl_return, self).__init__() self.tree = None # $ANTLR start "array_decl" # Expr.g:339:1: array_decl : '[' ( expr_list )? ']' -> ^( ARRAY ( expr_list )? ) ; def array_decl(self, ): retval = self.array_decl_return() retval.start = self.input.LT(1) root_0 = None char_literal246 = None char_literal248 = None expr_list247 = None char_literal246_tree = None char_literal248_tree = None stream_101 = RewriteRuleTokenStream(self._adaptor, "token 101") stream_100 = RewriteRuleTokenStream(self._adaptor, "token 100") stream_expr_list = RewriteRuleSubtreeStream(self._adaptor, "rule expr_list") try: try: # Expr.g:340:2: ( '[' ( expr_list )? ']' -> ^( ARRAY ( expr_list )? ) ) # Expr.g:340:4: '[' ( expr_list )? ']' pass char_literal246 = self.match(self.input, 100, self.FOLLOW_100_in_array_decl2118) if self._state.backtracking == 0: stream_100.add(char_literal246) # Expr.g:340:8: ( expr_list )? alt56 = 2 LA56_0 = self.input.LA(1) if (LA56_0 == BOOL or LA56_0 == FLOAT or LA56_0 == ID or LA56_0 == INT or LA56_0 == NULL or LA56_0 == STRING or LA56_0 == 68 or LA56_0 == 75 or LA56_0 == 83 or LA56_0 == 100 or LA56_0 == 121 or LA56_0 == 126 or LA56_0 == 132) : alt56 = 1 if alt56 == 1: # Expr.g:340:8: expr_list pass self._state.following.append(self.FOLLOW_expr_list_in_array_decl2120) expr_list247 = self.expr_list() self._state.following.pop() if self._state.backtracking == 0: stream_expr_list.add(expr_list247.tree) char_literal248 = self.match(self.input, 101, self.FOLLOW_101_in_array_decl2123) if self._state.backtracking == 0: stream_101.add(char_literal248) # AST Rewrite # elements: expr_list # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 341:3: -> ^( ARRAY ( expr_list )? ) # Expr.g:341:6: ^( ARRAY ( expr_list )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(ARRAY, "ARRAY") , root_1) # Expr.g:341:14: ( expr_list )? if stream_expr_list.hasNext(): self._adaptor.addChild(root_1, stream_expr_list.nextTree()) stream_expr_list.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "array_decl" class object_decl_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.object_decl_return, self).__init__() self.tree = None # $ANTLR start "object_decl" # Expr.g:344:1: object_decl : '{' ( property )? ( ',' property )* ( ',' )? '}' -> ^( OBJECT ( property )* ) ; def object_decl(self, ): retval = self.object_decl_return() retval.start = self.input.LT(1) root_0 = None char_literal249 = None char_literal251 = None char_literal253 = None char_literal254 = None property250 = None property252 = None char_literal249_tree = None char_literal251_tree = None char_literal253_tree = None char_literal254_tree = None stream_132 = RewriteRuleTokenStream(self._adaptor, "token 132") stream_136 = RewriteRuleTokenStream(self._adaptor, "token 136") stream_82 = RewriteRuleTokenStream(self._adaptor, "token 82") stream_property = RewriteRuleSubtreeStream(self._adaptor, "rule property") try: try: # Expr.g:345:2: ( '{' ( property )? ( ',' property )* ( ',' )? '}' -> ^( OBJECT ( property )* ) ) # Expr.g:345:4: '{' ( property )? ( ',' property )* ( ',' )? '}' pass char_literal249 = self.match(self.input, 132, self.FOLLOW_132_in_object_decl2145) if self._state.backtracking == 0: stream_132.add(char_literal249) # Expr.g:345:8: ( property )? alt57 = 2 LA57_0 = self.input.LA(1) if (LA57_0 == ID or LA57_0 == INT or LA57_0 == STRING) : alt57 = 1 if alt57 == 1: # Expr.g:345:8: property pass self._state.following.append(self.FOLLOW_property_in_object_decl2147) property250 = self.property() self._state.following.pop() if self._state.backtracking == 0: stream_property.add(property250.tree) # Expr.g:345:18: ( ',' property )* while True: #loop58 alt58 = 2 LA58_0 = self.input.LA(1) if (LA58_0 == 82) : LA58_1 = self.input.LA(2) if (LA58_1 == ID or LA58_1 == INT or LA58_1 == STRING) : alt58 = 1 if alt58 == 1: # Expr.g:345:19: ',' property pass char_literal251 = self.match(self.input, 82, self.FOLLOW_82_in_object_decl2151) if self._state.backtracking == 0: stream_82.add(char_literal251) self._state.following.append(self.FOLLOW_property_in_object_decl2153) property252 = self.property() self._state.following.pop() if self._state.backtracking == 0: stream_property.add(property252.tree) else: break #loop58 # Expr.g:345:34: ( ',' )? alt59 = 2 LA59_0 = self.input.LA(1) if (LA59_0 == 82) : alt59 = 1 if alt59 == 1: # Expr.g:345:34: ',' pass char_literal253 = self.match(self.input, 82, self.FOLLOW_82_in_object_decl2157) if self._state.backtracking == 0: stream_82.add(char_literal253) char_literal254 = self.match(self.input, 136, self.FOLLOW_136_in_object_decl2160) if self._state.backtracking == 0: stream_136.add(char_literal254) # AST Rewrite # elements: property # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 346:3: -> ^( OBJECT ( property )* ) # Expr.g:346:6: ^( OBJECT ( property )* ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(OBJECT, "OBJECT") , root_1) # Expr.g:346:15: ( property )* while stream_property.hasNext(): self._adaptor.addChild(root_1, stream_property.nextTree()) stream_property.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "object_decl" class property_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.property_return, self).__init__() self.tree = None # $ANTLR start "property" # Expr.g:348:1: property : ( ID | STRING | INT ) ':' expr ; def property(self, ): retval = self.property_return() retval.start = self.input.LT(1) root_0 = None set255 = None char_literal256 = None expr257 = None set255_tree = None char_literal256_tree = None try: try: # Expr.g:349:2: ( ( ID | STRING | INT ) ':' expr ) # Expr.g:349:4: ( ID | STRING | INT ) ':' expr pass root_0 = self._adaptor.nil() set255 = self.input.LT(1) if self.input.LA(1) == ID or self.input.LA(1) == INT or self.input.LA(1) == STRING: self.input.consume() if self._state.backtracking == 0: self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set255)) self._state.errorRecovery = False else: if self._state.backtracking > 0: raise BacktrackingFailed mse = MismatchedSetException(None, self.input) raise mse char_literal256 = self.match(self.input, 91, self.FOLLOW_91_in_property2193) if self._state.backtracking == 0: char_literal256_tree = self._adaptor.createWithPayload(char_literal256) self._adaptor.addChild(root_0, char_literal256_tree) self._state.following.append(self.FOLLOW_expr_in_property2195) expr257 = self.expr() self._state.following.pop() if self._state.backtracking == 0: self._adaptor.addChild(root_0, expr257.tree) retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "property" class sprintf_return(ParserRuleReturnScope): def __init__(self): super(ExprParser.sprintf_return, self).__init__() self.tree = None # $ANTLR start "sprintf" # Expr.g:353:1: sprintf : 'sprintf' '(' expr ( ',' expr_list )? ')' -> ^( SPRINTF expr ( expr_list )? ) ; def sprintf(self, ): retval = self.sprintf_return() retval.start = self.input.LT(1) root_0 = None string_literal258 = None char_literal259 = None char_literal261 = None char_literal263 = None expr260 = None expr_list262 = None string_literal258_tree = None char_literal259_tree = None char_literal261_tree = None char_literal263_tree = None stream_126 = RewriteRuleTokenStream(self._adaptor, "token 126") stream_82 = RewriteRuleTokenStream(self._adaptor, "token 82") stream_75 = RewriteRuleTokenStream(self._adaptor, "token 75") stream_76 = RewriteRuleTokenStream(self._adaptor, "token 76") stream_expr = RewriteRuleSubtreeStream(self._adaptor, "rule expr") stream_expr_list = RewriteRuleSubtreeStream(self._adaptor, "rule expr_list") try: try: # Expr.g:354:2: ( 'sprintf' '(' expr ( ',' expr_list )? ')' -> ^( SPRINTF expr ( expr_list )? ) ) # Expr.g:354:4: 'sprintf' '(' expr ( ',' expr_list )? ')' pass string_literal258 = self.match(self.input, 126, self.FOLLOW_126_in_sprintf2207) if self._state.backtracking == 0: stream_126.add(string_literal258) char_literal259 = self.match(self.input, 75, self.FOLLOW_75_in_sprintf2209) if self._state.backtracking == 0: stream_75.add(char_literal259) self._state.following.append(self.FOLLOW_expr_in_sprintf2211) expr260 = self.expr() self._state.following.pop() if self._state.backtracking == 0: stream_expr.add(expr260.tree) # Expr.g:354:23: ( ',' expr_list )? alt60 = 2 LA60_0 = self.input.LA(1) if (LA60_0 == 82) : alt60 = 1 if alt60 == 1: # Expr.g:354:24: ',' expr_list pass char_literal261 = self.match(self.input, 82, self.FOLLOW_82_in_sprintf2214) if self._state.backtracking == 0: stream_82.add(char_literal261) self._state.following.append(self.FOLLOW_expr_list_in_sprintf2216) expr_list262 = self.expr_list() self._state.following.pop() if self._state.backtracking == 0: stream_expr_list.add(expr_list262.tree) char_literal263 = self.match(self.input, 76, self.FOLLOW_76_in_sprintf2220) if self._state.backtracking == 0: stream_76.add(char_literal263) # AST Rewrite # elements: expr_list, expr # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: if self._state.backtracking == 0: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 355:3: -> ^( SPRINTF expr ( expr_list )? ) # Expr.g:355:6: ^( SPRINTF expr ( expr_list )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(SPRINTF, "SPRINTF") , root_1) self._adaptor.addChild(root_1, stream_expr.nextTree()) # Expr.g:355:21: ( expr_list )? if stream_expr_list.hasNext(): self._adaptor.addChild(root_1, stream_expr_list.nextTree()) stream_expr_list.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) if self._state.backtracking == 0: retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "sprintf" # $ANTLR start "synpred1_Expr" def synpred1_Expr_fragment(self, ): # Expr.g:232:4: ( '[' expr ']' ) # Expr.g:232:4: '[' expr ']' pass root_0 = self._adaptor.nil() self.match(self.input, 100, self.FOLLOW_100_in_synpred1_Expr1439) self._state.following.append(self.FOLLOW_expr_in_synpred1_Expr1441) self.expr() self._state.following.pop() self.match(self.input, 101, self.FOLLOW_101_in_synpred1_Expr1443) # $ANTLR end "synpred1_Expr" def synpred1_Expr(self): self._state.backtracking += 1 start = self.input.mark() try: self.synpred1_Expr_fragment() except BacktrackingFailed: success = False else: success = True self.input.rewind(start) self._state.backtracking -= 1 return success # lookup tables for DFA #6 DFA6_eot = DFA.unpack( u"\6\uffff" ) DFA6_eof = DFA.unpack( u"\6\uffff" ) DFA6_min = DFA.unpack( u"\1\42\1\122\1\42\2\uffff\1\122" ) DFA6_max = DFA.unpack( u"\1\42\1\134\1\42\2\uffff\1\134" ) DFA6_accept = DFA.unpack( u"\3\uffff\1\1\1\2\1\uffff" ) DFA6_special = DFA.unpack( u"\6\uffff" ) DFA6_transition = [ DFA.unpack(u"\1\1"), DFA.unpack(u"\1\3\3\uffff\1\2\1\4\4\uffff\1\3"), DFA.unpack(u"\1\5"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\3\3\uffff\1\2\1\4\4\uffff\1\3") ] # class definition for DFA #6 class DFA6(DFA): pass FOLLOW_EOF_in_prog211 = frozenset([1]) FOLLOW_stmt_in_prog220 = frozenset([1, 34, 80, 84, 92, 105, 108, 109, 111, 115, 116, 117, 118, 119, 122, 123, 125, 128, 129, 130, 131]) FOLLOW_92_in_stmt232 = frozenset([1]) FOLLOW_exec_stmt_in_stmt239 = frozenset([1]) FOLLOW_import_stmt_in_stmt244 = frozenset([1]) FOLLOW_print_stmt_in_stmt249 = frozenset([1]) FOLLOW_printf_stmt_in_stmt253 = frozenset([1]) FOLLOW_break_stmt_in_stmt258 = frozenset([1]) FOLLOW_continue_stmt_in_stmt263 = frozenset([1]) FOLLOW_return_stmt_in_stmt268 = frozenset([1]) FOLLOW_if_stmt_in_stmt273 = frozenset([1]) FOLLOW_while_stmt_in_stmt278 = frozenset([1]) FOLLOW_do_while_stmt_in_stmt283 = frozenset([1]) FOLLOW_switch_stmt_in_stmt288 = frozenset([1]) FOLLOW_for_stmt_in_stmt293 = frozenset([1]) FOLLOW_foreach_stmt_in_stmt298 = frozenset([1]) FOLLOW_throw_stmt_in_stmt303 = frozenset([1]) FOLLOW_try_stmt_in_stmt308 = frozenset([1]) FOLLOW_func_decl_in_stmt313 = frozenset([1]) FOLLOW_class_decl_in_stmt318 = frozenset([1]) FOLLOW_132_in_block331 = frozenset([34, 80, 84, 92, 105, 108, 109, 111, 115, 116, 117, 118, 119, 122, 123, 125, 128, 129, 130, 131, 136]) FOLLOW_stmt_in_block333 = frozenset([34, 80, 84, 92, 105, 108, 109, 111, 115, 116, 117, 118, 119, 122, 123, 125, 128, 129, 130, 131, 136]) FOLLOW_136_in_block336 = frozenset([1]) FOLLOW_119_in_import_stmt358 = frozenset([34]) FOLLOW_module_path_in_import_stmt360 = frozenset([82, 92]) FOLLOW_82_in_import_stmt363 = frozenset([34]) FOLLOW_module_path_in_import_stmt365 = frozenset([82, 92]) FOLLOW_92_in_import_stmt369 = frozenset([1]) FOLLOW_module_in_module_path390 = frozenset([1]) FOLLOW_module_in_module_path395 = frozenset([87]) FOLLOW_87_in_module_path397 = frozenset([1]) FOLLOW_123_in_printf_stmt408 = frozenset([75]) FOLLOW_75_in_printf_stmt410 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_printf_stmt412 = frozenset([76, 82]) FOLLOW_82_in_printf_stmt415 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_list_in_printf_stmt417 = frozenset([76]) FOLLOW_76_in_printf_stmt421 = frozenset([92]) FOLLOW_92_in_printf_stmt423 = frozenset([1]) FOLLOW_122_in_print_stmt452 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_list_in_print_stmt455 = frozenset([92]) FOLLOW_92_in_print_stmt457 = frozenset([1]) FOLLOW_105_in_break_stmt478 = frozenset([92]) FOLLOW_92_in_break_stmt480 = frozenset([1]) FOLLOW_109_in_continue_stmt496 = frozenset([92]) FOLLOW_92_in_continue_stmt498 = frozenset([1]) FOLLOW_125_in_return_stmt514 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 92, 100, 121, 126, 132]) FOLLOW_expr_in_return_stmt516 = frozenset([92]) FOLLOW_92_in_return_stmt519 = frozenset([1]) FOLLOW_if_clause_in_if_stmt541 = frozenset([1, 112]) FOLLOW_else_if_clause_in_if_stmt543 = frozenset([1, 112]) FOLLOW_else_clause_in_if_stmt546 = frozenset([1]) FOLLOW_118_in_if_clause557 = frozenset([75]) FOLLOW_75_in_if_clause559 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_if_clause561 = frozenset([76]) FOLLOW_76_in_if_clause563 = frozenset([132]) FOLLOW_block_in_if_clause565 = frozenset([1]) FOLLOW_112_in_else_if_clause587 = frozenset([118]) FOLLOW_if_clause_in_else_if_clause589 = frozenset([1]) FOLLOW_112_in_else_clause609 = frozenset([132]) FOLLOW_block_in_else_clause611 = frozenset([1]) FOLLOW_131_in_while_stmt632 = frozenset([75]) FOLLOW_75_in_while_stmt634 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_while_stmt636 = frozenset([76]) FOLLOW_76_in_while_stmt638 = frozenset([132]) FOLLOW_block_in_while_stmt640 = frozenset([1]) FOLLOW_111_in_do_while_stmt663 = frozenset([132]) FOLLOW_block_in_do_while_stmt665 = frozenset([131]) FOLLOW_131_in_do_while_stmt667 = frozenset([75]) FOLLOW_75_in_do_while_stmt669 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_do_while_stmt671 = frozenset([76]) FOLLOW_76_in_do_while_stmt673 = frozenset([92]) FOLLOW_92_in_do_while_stmt675 = frozenset([1]) FOLLOW_128_in_switch_stmt698 = frozenset([75]) FOLLOW_75_in_switch_stmt700 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_switch_stmt702 = frozenset([76]) FOLLOW_76_in_switch_stmt704 = frozenset([132]) FOLLOW_case_block_in_switch_stmt706 = frozenset([1]) FOLLOW_132_in_case_block728 = frozenset([106]) FOLLOW_case_clause_in_case_block731 = frozenset([106, 110, 136]) FOLLOW_default_clause_in_case_block736 = frozenset([136]) FOLLOW_136_in_case_block740 = frozenset([1]) FOLLOW_case_test_in_case_clause750 = frozenset([34, 80, 84, 92, 105, 106, 108, 109, 111, 115, 116, 117, 118, 119, 122, 123, 125, 128, 129, 130, 131]) FOLLOW_stmt_in_case_clause753 = frozenset([34, 80, 84, 92, 105, 108, 109, 111, 115, 116, 117, 118, 119, 122, 123, 125, 128, 129, 130, 131]) FOLLOW_break_stmt_in_case_clause756 = frozenset([1]) FOLLOW_106_in_case_test782 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_case_test784 = frozenset([91]) FOLLOW_91_in_case_test786 = frozenset([1]) FOLLOW_110_in_default_clause806 = frozenset([91]) FOLLOW_91_in_default_clause808 = frozenset([1, 34, 80, 84, 92, 105, 108, 109, 111, 115, 116, 117, 118, 119, 122, 123, 125, 128, 129, 130, 131]) FOLLOW_stmt_in_default_clause810 = frozenset([1, 34, 80, 84, 92, 105, 108, 109, 111, 115, 116, 117, 118, 119, 122, 123, 125, 128, 129, 130, 131]) FOLLOW_115_in_for_stmt833 = frozenset([75]) FOLLOW_75_in_for_stmt835 = frozenset([34, 80, 84, 92]) FOLLOW_exec_list_in_for_stmt839 = frozenset([92]) FOLLOW_92_in_for_stmt842 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_for_stmt844 = frozenset([92]) FOLLOW_92_in_for_stmt846 = frozenset([34, 76, 80, 84]) FOLLOW_exec_list_in_for_stmt850 = frozenset([76]) FOLLOW_76_in_for_stmt853 = frozenset([132]) FOLLOW_block_in_for_stmt855 = frozenset([1]) FOLLOW_116_in_foreach_stmt886 = frozenset([75]) FOLLOW_75_in_foreach_stmt888 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_foreach_stmt890 = frozenset([104]) FOLLOW_104_in_foreach_stmt892 = frozenset([34]) FOLLOW_each_in_foreach_stmt894 = frozenset([76]) FOLLOW_76_in_foreach_stmt896 = frozenset([132]) FOLLOW_block_in_foreach_stmt898 = frozenset([1]) FOLLOW_each_val_in_each922 = frozenset([1]) FOLLOW_ID_in_each937 = frozenset([97]) FOLLOW_97_in_each939 = frozenset([34]) FOLLOW_each_val_in_each941 = frozenset([1]) FOLLOW_ID_in_each_val963 = frozenset([1, 82]) FOLLOW_82_in_each_val966 = frozenset([34]) FOLLOW_ID_in_each_val968 = frozenset([1, 82]) FOLLOW_129_in_throw_stmt993 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_throw_stmt995 = frozenset([92]) FOLLOW_92_in_throw_stmt997 = frozenset([1]) FOLLOW_130_in_try_stmt1017 = frozenset([132]) FOLLOW_block_in_try_stmt1019 = frozenset([107]) FOLLOW_catch_clause_in_try_stmt1021 = frozenset([1, 107, 114]) FOLLOW_finally_clause_in_try_stmt1024 = frozenset([1]) FOLLOW_107_in_catch_clause1051 = frozenset([75]) FOLLOW_75_in_catch_clause1053 = frozenset([34]) FOLLOW_module_in_catch_clause1055 = frozenset([34, 76]) FOLLOW_ID_in_catch_clause1057 = frozenset([76]) FOLLOW_76_in_catch_clause1060 = frozenset([132]) FOLLOW_block_in_catch_clause1062 = frozenset([1]) FOLLOW_114_in_finally_clause1087 = frozenset([132]) FOLLOW_block_in_finally_clause1089 = frozenset([1]) FOLLOW_117_in_func_decl1111 = frozenset([34]) FOLLOW_ID_in_func_decl1113 = frozenset([75]) FOLLOW_params_in_func_decl1115 = frozenset([132]) FOLLOW_block_in_func_decl1117 = frozenset([1]) FOLLOW_75_in_params1141 = frozenset([34, 76, 82]) FOLLOW_param_decl_in_params1143 = frozenset([76, 82]) FOLLOW_82_in_params1147 = frozenset([34]) FOLLOW_param_decl_in_params1149 = frozenset([76, 82]) FOLLOW_76_in_params1153 = frozenset([1]) FOLLOW_ID_in_param_decl1174 = frozenset([1, 95]) FOLLOW_95_in_param_decl1177 = frozenset([8, 30, 34, 39, 47, 61, 75, 100, 121, 126, 132]) FOLLOW_atom_in_param_decl1179 = frozenset([1]) FOLLOW_108_in_class_decl1192 = frozenset([34]) FOLLOW_ID_in_class_decl1194 = frozenset([113, 132]) FOLLOW_113_in_class_decl1197 = frozenset([34]) FOLLOW_ID_in_class_decl1199 = frozenset([132]) FOLLOW_132_in_class_decl1205 = frozenset([117, 124, 136]) FOLLOW_class_element_in_class_decl1207 = frozenset([117, 124, 136]) FOLLOW_136_in_class_decl1210 = frozenset([1]) FOLLOW_var_def_in_class_element1236 = frozenset([1]) FOLLOW_constructor_in_class_element1240 = frozenset([1]) FOLLOW_func_decl_in_class_element1244 = frozenset([1]) FOLLOW_124_in_var_def1254 = frozenset([34]) FOLLOW_ID_in_var_def1256 = frozenset([92, 95]) FOLLOW_95_in_var_def1259 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_var_def1261 = frozenset([92]) FOLLOW_92_in_var_def1265 = frozenset([1]) FOLLOW_124_in_var_def1283 = frozenset([127]) FOLLOW_127_in_var_def1285 = frozenset([34]) FOLLOW_ID_in_var_def1287 = frozenset([92, 95]) FOLLOW_95_in_var_def1290 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_var_def1292 = frozenset([92]) FOLLOW_92_in_var_def1296 = frozenset([1]) FOLLOW_117_in_constructor1321 = frozenset([120]) FOLLOW_120_in_constructor1323 = frozenset([75]) FOLLOW_params_in_constructor1325 = frozenset([132]) FOLLOW_block_in_constructor1327 = frozenset([1]) FOLLOW_primary_in_member_expr1354 = frozenset([1, 86]) FOLLOW_86_in_member_expr1357 = frozenset([34]) FOLLOW_primary_in_member_expr1359 = frozenset([1, 86]) FOLLOW_ID_in_primary1382 = frozenset([1, 75, 100]) FOLLOW_index_expr_in_primary1384 = frozenset([1, 75, 100]) FOLLOW_call_expr_in_primary1387 = frozenset([1]) FOLLOW_75_in_call_expr1398 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 76, 83, 100, 121, 126, 132]) FOLLOW_expr_list_in_call_expr1400 = frozenset([76]) FOLLOW_76_in_call_expr1403 = frozenset([1]) FOLLOW_100_in_index_expr1439 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_index_expr1441 = frozenset([101]) FOLLOW_101_in_index_expr1443 = frozenset([1]) FOLLOW_100_in_index_expr1458 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_index_expr1460 = frozenset([88]) FOLLOW_88_in_index_expr1462 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 101, 121, 126, 132]) FOLLOW_expr_in_index_expr1464 = frozenset([101]) FOLLOW_101_in_index_expr1467 = frozenset([1]) FOLLOW_exec_expr_in_exec_list1492 = frozenset([1, 82]) FOLLOW_82_in_exec_list1495 = frozenset([34, 80, 84]) FOLLOW_exec_expr_in_exec_list1497 = frozenset([1, 82]) FOLLOW_member_expr_in_member_list1520 = frozenset([1, 82]) FOLLOW_82_in_member_list1523 = frozenset([34]) FOLLOW_member_expr_in_member_list1525 = frozenset([1, 82]) FOLLOW_member_expr_in_exec_expr1537 = frozenset([1, 71, 74, 78, 80, 81, 84, 85, 90, 95, 103, 134]) FOLLOW_assign_op_in_exec_expr1542 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_exec_expr1544 = frozenset([1]) FOLLOW_80_in_exec_expr1565 = frozenset([1]) FOLLOW_84_in_exec_expr1582 = frozenset([1]) FOLLOW_80_in_exec_expr1613 = frozenset([34]) FOLLOW_member_expr_in_exec_expr1615 = frozenset([1]) FOLLOW_84_in_exec_expr1630 = frozenset([34]) FOLLOW_member_expr_in_exec_expr1632 = frozenset([1]) FOLLOW_exec_list_in_exec_stmt1678 = frozenset([92]) FOLLOW_92_in_exec_stmt1680 = frozenset([1]) FOLLOW_expr_in_expr_list1703 = frozenset([1, 82]) FOLLOW_82_in_expr_list1706 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_expr_list1708 = frozenset([1, 82]) FOLLOW_82_in_expr_list1712 = frozenset([1]) FOLLOW_logic_or_expr_in_expr1734 = frozenset([1]) FOLLOW_logic_and_expr_in_logic_or_expr1744 = frozenset([1, 135]) FOLLOW_135_in_logic_or_expr1747 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_logic_and_expr_in_logic_or_expr1750 = frozenset([1, 135]) FOLLOW_bitwise_or_expr_in_logic_and_expr1762 = frozenset([1, 72]) FOLLOW_72_in_logic_and_expr1765 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_bitwise_or_expr_in_logic_and_expr1768 = frozenset([1, 72]) FOLLOW_bitwise_xor_expr_in_bitwise_or_expr1780 = frozenset([1, 133]) FOLLOW_133_in_bitwise_or_expr1783 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_bitwise_xor_expr_in_bitwise_or_expr1786 = frozenset([1, 133]) FOLLOW_bitwise_and_expr_in_bitwise_xor_expr1798 = frozenset([1, 102]) FOLLOW_102_in_bitwise_xor_expr1801 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_bitwise_and_expr_in_bitwise_xor_expr1804 = frozenset([1, 102]) FOLLOW_relation_expr_in_bitwise_and_expr1816 = frozenset([1, 73]) FOLLOW_73_in_bitwise_and_expr1819 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_relation_expr_in_bitwise_and_expr1822 = frozenset([1, 73]) FOLLOW_add_expr_in_relation_expr1834 = frozenset([1, 69, 93, 94, 96, 98, 99]) FOLLOW_set_in_relation_expr1837 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_add_expr_in_relation_expr1852 = frozenset([1]) FOLLOW_mul_expr_in_add_expr1864 = frozenset([1, 79, 83]) FOLLOW_set_in_add_expr1867 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_mul_expr_in_add_expr1874 = frozenset([1, 79, 83]) FOLLOW_not_expr_in_mul_expr1886 = frozenset([1, 70, 77, 89]) FOLLOW_set_in_mul_expr1889 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_not_expr_in_mul_expr1898 = frozenset([1, 70, 77, 89]) FOLLOW_68_in_not_expr1912 = frozenset([8, 30, 34, 39, 47, 61, 75, 83, 100, 121, 126, 132]) FOLLOW_negative_expr_in_not_expr1915 = frozenset([1]) FOLLOW_83_in_negative_expr1950 = frozenset([8, 30, 34, 39, 47, 61, 75, 100, 121, 126, 132]) FOLLOW_atom_in_negative_expr1954 = frozenset([1]) FOLLOW_literal_in_atom1987 = frozenset([1]) FOLLOW_member_expr_in_atom1992 = frozenset([1]) FOLLOW_array_decl_in_atom1997 = frozenset([1]) FOLLOW_object_decl_in_atom2002 = frozenset([1]) FOLLOW_new_clause_in_atom2007 = frozenset([1]) FOLLOW_sprintf_in_atom2012 = frozenset([1]) FOLLOW_75_in_atom2017 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_atom2019 = frozenset([76]) FOLLOW_76_in_atom2021 = frozenset([1]) FOLLOW_121_in_new_clause2062 = frozenset([34]) FOLLOW_module_in_new_clause2064 = frozenset([75]) FOLLOW_call_expr_in_new_clause2066 = frozenset([1]) FOLLOW_ID_in_module2088 = frozenset([1, 86]) FOLLOW_86_in_module2091 = frozenset([34]) FOLLOW_ID_in_module2093 = frozenset([1, 86]) FOLLOW_100_in_array_decl2118 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 101, 121, 126, 132]) FOLLOW_expr_list_in_array_decl2120 = frozenset([101]) FOLLOW_101_in_array_decl2123 = frozenset([1]) FOLLOW_132_in_object_decl2145 = frozenset([34, 39, 61, 82, 136]) FOLLOW_property_in_object_decl2147 = frozenset([82, 136]) FOLLOW_82_in_object_decl2151 = frozenset([34, 39, 61]) FOLLOW_property_in_object_decl2153 = frozenset([82, 136]) FOLLOW_82_in_object_decl2157 = frozenset([136]) FOLLOW_136_in_object_decl2160 = frozenset([1]) FOLLOW_set_in_property2181 = frozenset([91]) FOLLOW_91_in_property2193 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_property2195 = frozenset([1]) FOLLOW_126_in_sprintf2207 = frozenset([75]) FOLLOW_75_in_sprintf2209 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_sprintf2211 = frozenset([76, 82]) FOLLOW_82_in_sprintf2214 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_list_in_sprintf2216 = frozenset([76]) FOLLOW_76_in_sprintf2220 = frozenset([1]) FOLLOW_100_in_synpred1_Expr1439 = frozenset([8, 30, 34, 39, 47, 61, 68, 75, 83, 100, 121, 126, 132]) FOLLOW_expr_in_synpred1_Expr1441 = frozenset([101]) FOLLOW_101_in_synpred1_Expr1443 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("ExprLexer", ExprParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "left2right/ssdb", "path": "deps/cpy/ExprParser.py", "copies": "36", "size": "309324", "license": "bsd-3-clause", "hash": 3331183865364005400, "line_mean": 31.4001256939, "line_max": 292, "alpha_frac": 0.488335855, "autogenerated": false, "ratio": 3.952820303115496, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": null, "num_lines": null }
# $ANTLR 3.5 Expr.g 2013-04-12 19:22:24 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__68=68 T__69=69 T__70=70 T__71=71 T__72=72 T__73=73 T__74=74 T__75=75 T__76=76 T__77=77 T__78=78 T__79=79 T__80=80 T__81=81 T__82=82 T__83=83 T__84=84 T__85=85 T__86=86 T__87=87 T__88=88 T__89=89 T__90=90 T__91=91 T__92=92 T__93=93 T__94=94 T__95=95 T__96=96 T__97=97 T__98=98 T__99=99 T__100=100 T__101=101 T__102=102 T__103=103 T__104=104 T__105=105 T__106=106 T__107=107 T__108=108 T__109=109 T__110=110 T__111=111 T__112=112 T__113=113 T__114=114 T__115=115 T__116=116 T__117=117 T__118=118 T__119=119 T__120=120 T__121=121 T__122=122 T__123=123 T__124=124 T__125=125 T__126=126 T__127=127 T__128=128 T__129=129 T__130=130 T__131=131 T__132=132 T__133=133 T__134=134 T__135=135 T__136=136 ALPHA=4 ARRAY=5 ASSIGN=6 BLOCK=7 BOOL=8 BREAK=9 CALL=10 CASE=11 CATCH=12 CLASS=13 COMMENT=14 CONSTRUCTOR=15 CONTINUE=16 DEFAULT=17 DIGIT=18 DOUBLE_QUOTE_CHARS=19 DO_WHILE=20 EACH=21 EACH_VAL=22 ELSE=23 ELSE_IF=24 EMPTY_LINE=25 EXEC_LIST=26 EXEC_STMT=27 EXPR_LIST=28 FINALLY=29 FLOAT=30 FOR=31 FOREACH=32 FUNCTION=33 ID=34 ID_LIST=35 IF=36 IMPORT=37 INDEX=38 INT=39 LINECOMMENT=40 MEMBER=41 MODULE=42 NEGATIVE=43 NEW=44 NEWLINE=45 NOP=46 NULL=47 OBJECT=48 OP_ASSIGN=49 PARAMS=50 POST_DEC=51 POST_INC=52 PRE_DEC=53 PRE_INC=54 PRINT=55 PRINTF=56 RETURN=57 SINGLE_QUOTE_CHARS=58 SLICE=59 SPRINTF=60 STRING=61 SWITCH=62 THROW=63 TRY=64 VAR=65 WHILE=66 WS=67 class ExprLexer(Lexer): grammarFileName = "Expr.g" api_version = 1 def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(ExprLexer, self).__init__(input, state) self.delegates = [] self.dfa15 = self.DFA15( self, 15, eot = self.DFA15_eot, eof = self.DFA15_eof, min = self.DFA15_min, max = self.DFA15_max, accept = self.DFA15_accept, special = self.DFA15_special, transition = self.DFA15_transition ) # $ANTLR start "T__68" def mT__68(self, ): try: _type = T__68 _channel = DEFAULT_CHANNEL # Expr.g:7:7: ( '!' ) # Expr.g:7:9: '!' pass self.match(33) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__68" # $ANTLR start "T__69" def mT__69(self, ): try: _type = T__69 _channel = DEFAULT_CHANNEL # Expr.g:8:7: ( '!=' ) # Expr.g:8:9: '!=' pass self.match("!=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__69" # $ANTLR start "T__70" def mT__70(self, ): try: _type = T__70 _channel = DEFAULT_CHANNEL # Expr.g:9:7: ( '%' ) # Expr.g:9:9: '%' pass self.match(37) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__70" # $ANTLR start "T__71" def mT__71(self, ): try: _type = T__71 _channel = DEFAULT_CHANNEL # Expr.g:10:7: ( '%=' ) # Expr.g:10:9: '%=' pass self.match("%=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__71" # $ANTLR start "T__72" def mT__72(self, ): try: _type = T__72 _channel = DEFAULT_CHANNEL # Expr.g:11:7: ( '&&' ) # Expr.g:11:9: '&&' pass self.match("&&") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__72" # $ANTLR start "T__73" def mT__73(self, ): try: _type = T__73 _channel = DEFAULT_CHANNEL # Expr.g:12:7: ( '&' ) # Expr.g:12:9: '&' pass self.match(38) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__73" # $ANTLR start "T__74" def mT__74(self, ): try: _type = T__74 _channel = DEFAULT_CHANNEL # Expr.g:13:7: ( '&=' ) # Expr.g:13:9: '&=' pass self.match("&=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__74" # $ANTLR start "T__75" def mT__75(self, ): try: _type = T__75 _channel = DEFAULT_CHANNEL # Expr.g:14:7: ( '(' ) # Expr.g:14:9: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__75" # $ANTLR start "T__76" def mT__76(self, ): try: _type = T__76 _channel = DEFAULT_CHANNEL # Expr.g:15:7: ( ')' ) # Expr.g:15:9: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__76" # $ANTLR start "T__77" def mT__77(self, ): try: _type = T__77 _channel = DEFAULT_CHANNEL # Expr.g:16:7: ( '*' ) # Expr.g:16:9: '*' pass self.match(42) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__77" # $ANTLR start "T__78" def mT__78(self, ): try: _type = T__78 _channel = DEFAULT_CHANNEL # Expr.g:17:7: ( '*=' ) # Expr.g:17:9: '*=' pass self.match("*=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__78" # $ANTLR start "T__79" def mT__79(self, ): try: _type = T__79 _channel = DEFAULT_CHANNEL # Expr.g:18:7: ( '+' ) # Expr.g:18:9: '+' pass self.match(43) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__79" # $ANTLR start "T__80" def mT__80(self, ): try: _type = T__80 _channel = DEFAULT_CHANNEL # Expr.g:19:7: ( '++' ) # Expr.g:19:9: '++' pass self.match("++") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__80" # $ANTLR start "T__81" def mT__81(self, ): try: _type = T__81 _channel = DEFAULT_CHANNEL # Expr.g:20:7: ( '+=' ) # Expr.g:20:9: '+=' pass self.match("+=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__81" # $ANTLR start "T__82" def mT__82(self, ): try: _type = T__82 _channel = DEFAULT_CHANNEL # Expr.g:21:7: ( ',' ) # Expr.g:21:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__82" # $ANTLR start "T__83" def mT__83(self, ): try: _type = T__83 _channel = DEFAULT_CHANNEL # Expr.g:22:7: ( '-' ) # Expr.g:22:9: '-' pass self.match(45) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__83" # $ANTLR start "T__84" def mT__84(self, ): try: _type = T__84 _channel = DEFAULT_CHANNEL # Expr.g:23:7: ( '--' ) # Expr.g:23:9: '--' pass self.match("--") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__84" # $ANTLR start "T__85" def mT__85(self, ): try: _type = T__85 _channel = DEFAULT_CHANNEL # Expr.g:24:7: ( '-=' ) # Expr.g:24:9: '-=' pass self.match("-=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__85" # $ANTLR start "T__86" def mT__86(self, ): try: _type = T__86 _channel = DEFAULT_CHANNEL # Expr.g:25:7: ( '.' ) # Expr.g:25:9: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__86" # $ANTLR start "T__87" def mT__87(self, ): try: _type = T__87 _channel = DEFAULT_CHANNEL # Expr.g:26:7: ( '.*' ) # Expr.g:26:9: '.*' pass self.match(".*") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__87" # $ANTLR start "T__88" def mT__88(self, ): try: _type = T__88 _channel = DEFAULT_CHANNEL # Expr.g:27:7: ( '..' ) # Expr.g:27:9: '..' pass self.match("..") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__88" # $ANTLR start "T__89" def mT__89(self, ): try: _type = T__89 _channel = DEFAULT_CHANNEL # Expr.g:28:7: ( '/' ) # Expr.g:28:9: '/' pass self.match(47) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__89" # $ANTLR start "T__90" def mT__90(self, ): try: _type = T__90 _channel = DEFAULT_CHANNEL # Expr.g:29:7: ( '/=' ) # Expr.g:29:9: '/=' pass self.match("/=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__90" # $ANTLR start "T__91" def mT__91(self, ): try: _type = T__91 _channel = DEFAULT_CHANNEL # Expr.g:30:7: ( ':' ) # Expr.g:30:9: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__91" # $ANTLR start "T__92" def mT__92(self, ): try: _type = T__92 _channel = DEFAULT_CHANNEL # Expr.g:31:7: ( ';' ) # Expr.g:31:9: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__92" # $ANTLR start "T__93" def mT__93(self, ): try: _type = T__93 _channel = DEFAULT_CHANNEL # Expr.g:32:7: ( '<' ) # Expr.g:32:9: '<' pass self.match(60) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__93" # $ANTLR start "T__94" def mT__94(self, ): try: _type = T__94 _channel = DEFAULT_CHANNEL # Expr.g:33:7: ( '<=' ) # Expr.g:33:9: '<=' pass self.match("<=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__94" # $ANTLR start "T__95" def mT__95(self, ): try: _type = T__95 _channel = DEFAULT_CHANNEL # Expr.g:34:7: ( '=' ) # Expr.g:34:9: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__95" # $ANTLR start "T__96" def mT__96(self, ): try: _type = T__96 _channel = DEFAULT_CHANNEL # Expr.g:35:7: ( '==' ) # Expr.g:35:9: '==' pass self.match("==") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__96" # $ANTLR start "T__97" def mT__97(self, ): try: _type = T__97 _channel = DEFAULT_CHANNEL # Expr.g:36:7: ( '=>' ) # Expr.g:36:9: '=>' pass self.match("=>") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__97" # $ANTLR start "T__98" def mT__98(self, ): try: _type = T__98 _channel = DEFAULT_CHANNEL # Expr.g:37:7: ( '>' ) # Expr.g:37:9: '>' pass self.match(62) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__98" # $ANTLR start "T__99" def mT__99(self, ): try: _type = T__99 _channel = DEFAULT_CHANNEL # Expr.g:38:7: ( '>=' ) # Expr.g:38:9: '>=' pass self.match(">=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__99" # $ANTLR start "T__100" def mT__100(self, ): try: _type = T__100 _channel = DEFAULT_CHANNEL # Expr.g:39:8: ( '[' ) # Expr.g:39:10: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__100" # $ANTLR start "T__101" def mT__101(self, ): try: _type = T__101 _channel = DEFAULT_CHANNEL # Expr.g:40:8: ( ']' ) # Expr.g:40:10: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__101" # $ANTLR start "T__102" def mT__102(self, ): try: _type = T__102 _channel = DEFAULT_CHANNEL # Expr.g:41:8: ( '^' ) # Expr.g:41:10: '^' pass self.match(94) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__102" # $ANTLR start "T__103" def mT__103(self, ): try: _type = T__103 _channel = DEFAULT_CHANNEL # Expr.g:42:8: ( '^=' ) # Expr.g:42:10: '^=' pass self.match("^=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__103" # $ANTLR start "T__104" def mT__104(self, ): try: _type = T__104 _channel = DEFAULT_CHANNEL # Expr.g:43:8: ( 'as' ) # Expr.g:43:10: 'as' pass self.match("as") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__104" # $ANTLR start "T__105" def mT__105(self, ): try: _type = T__105 _channel = DEFAULT_CHANNEL # Expr.g:44:8: ( 'break' ) # Expr.g:44:10: 'break' pass self.match("break") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__105" # $ANTLR start "T__106" def mT__106(self, ): try: _type = T__106 _channel = DEFAULT_CHANNEL # Expr.g:45:8: ( 'case' ) # Expr.g:45:10: 'case' pass self.match("case") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__106" # $ANTLR start "T__107" def mT__107(self, ): try: _type = T__107 _channel = DEFAULT_CHANNEL # Expr.g:46:8: ( 'catch' ) # Expr.g:46:10: 'catch' pass self.match("catch") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__107" # $ANTLR start "T__108" def mT__108(self, ): try: _type = T__108 _channel = DEFAULT_CHANNEL # Expr.g:47:8: ( 'class' ) # Expr.g:47:10: 'class' pass self.match("class") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__108" # $ANTLR start "T__109" def mT__109(self, ): try: _type = T__109 _channel = DEFAULT_CHANNEL # Expr.g:48:8: ( 'continue' ) # Expr.g:48:10: 'continue' pass self.match("continue") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__109" # $ANTLR start "T__110" def mT__110(self, ): try: _type = T__110 _channel = DEFAULT_CHANNEL # Expr.g:49:8: ( 'default' ) # Expr.g:49:10: 'default' pass self.match("default") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__110" # $ANTLR start "T__111" def mT__111(self, ): try: _type = T__111 _channel = DEFAULT_CHANNEL # Expr.g:50:8: ( 'do' ) # Expr.g:50:10: 'do' pass self.match("do") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__111" # $ANTLR start "T__112" def mT__112(self, ): try: _type = T__112 _channel = DEFAULT_CHANNEL # Expr.g:51:8: ( 'else' ) # Expr.g:51:10: 'else' pass self.match("else") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__112" # $ANTLR start "T__113" def mT__113(self, ): try: _type = T__113 _channel = DEFAULT_CHANNEL # Expr.g:52:8: ( 'extends' ) # Expr.g:52:10: 'extends' pass self.match("extends") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__113" # $ANTLR start "T__114" def mT__114(self, ): try: _type = T__114 _channel = DEFAULT_CHANNEL # Expr.g:53:8: ( 'finally' ) # Expr.g:53:10: 'finally' pass self.match("finally") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__114" # $ANTLR start "T__115" def mT__115(self, ): try: _type = T__115 _channel = DEFAULT_CHANNEL # Expr.g:54:8: ( 'for' ) # Expr.g:54:10: 'for' pass self.match("for") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__115" # $ANTLR start "T__116" def mT__116(self, ): try: _type = T__116 _channel = DEFAULT_CHANNEL # Expr.g:55:8: ( 'foreach' ) # Expr.g:55:10: 'foreach' pass self.match("foreach") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__116" # $ANTLR start "T__117" def mT__117(self, ): try: _type = T__117 _channel = DEFAULT_CHANNEL # Expr.g:56:8: ( 'function' ) # Expr.g:56:10: 'function' pass self.match("function") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__117" # $ANTLR start "T__118" def mT__118(self, ): try: _type = T__118 _channel = DEFAULT_CHANNEL # Expr.g:57:8: ( 'if' ) # Expr.g:57:10: 'if' pass self.match("if") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__118" # $ANTLR start "T__119" def mT__119(self, ): try: _type = T__119 _channel = DEFAULT_CHANNEL # Expr.g:58:8: ( 'import' ) # Expr.g:58:10: 'import' pass self.match("import") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__119" # $ANTLR start "T__120" def mT__120(self, ): try: _type = T__120 _channel = DEFAULT_CHANNEL # Expr.g:59:8: ( 'init' ) # Expr.g:59:10: 'init' pass self.match("init") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__120" # $ANTLR start "T__121" def mT__121(self, ): try: _type = T__121 _channel = DEFAULT_CHANNEL # Expr.g:60:8: ( 'new' ) # Expr.g:60:10: 'new' pass self.match("new") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__121" # $ANTLR start "T__122" def mT__122(self, ): try: _type = T__122 _channel = DEFAULT_CHANNEL # Expr.g:61:8: ( 'print' ) # Expr.g:61:10: 'print' pass self.match("print") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__122" # $ANTLR start "T__123" def mT__123(self, ): try: _type = T__123 _channel = DEFAULT_CHANNEL # Expr.g:62:8: ( 'printf' ) # Expr.g:62:10: 'printf' pass self.match("printf") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__123" # $ANTLR start "T__124" def mT__124(self, ): try: _type = T__124 _channel = DEFAULT_CHANNEL # Expr.g:63:8: ( 'public' ) # Expr.g:63:10: 'public' pass self.match("public") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__124" # $ANTLR start "T__125" def mT__125(self, ): try: _type = T__125 _channel = DEFAULT_CHANNEL # Expr.g:64:8: ( 'return' ) # Expr.g:64:10: 'return' pass self.match("return") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__125" # $ANTLR start "T__126" def mT__126(self, ): try: _type = T__126 _channel = DEFAULT_CHANNEL # Expr.g:65:8: ( 'sprintf' ) # Expr.g:65:10: 'sprintf' pass self.match("sprintf") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__126" # $ANTLR start "T__127" def mT__127(self, ): try: _type = T__127 _channel = DEFAULT_CHANNEL # Expr.g:66:8: ( 'static' ) # Expr.g:66:10: 'static' pass self.match("static") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__127" # $ANTLR start "T__128" def mT__128(self, ): try: _type = T__128 _channel = DEFAULT_CHANNEL # Expr.g:67:8: ( 'switch' ) # Expr.g:67:10: 'switch' pass self.match("switch") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__128" # $ANTLR start "T__129" def mT__129(self, ): try: _type = T__129 _channel = DEFAULT_CHANNEL # Expr.g:68:8: ( 'throw' ) # Expr.g:68:10: 'throw' pass self.match("throw") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__129" # $ANTLR start "T__130" def mT__130(self, ): try: _type = T__130 _channel = DEFAULT_CHANNEL # Expr.g:69:8: ( 'try' ) # Expr.g:69:10: 'try' pass self.match("try") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__130" # $ANTLR start "T__131" def mT__131(self, ): try: _type = T__131 _channel = DEFAULT_CHANNEL # Expr.g:70:8: ( 'while' ) # Expr.g:70:10: 'while' pass self.match("while") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__131" # $ANTLR start "T__132" def mT__132(self, ): try: _type = T__132 _channel = DEFAULT_CHANNEL # Expr.g:71:8: ( '{' ) # Expr.g:71:10: '{' pass self.match(123) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__132" # $ANTLR start "T__133" def mT__133(self, ): try: _type = T__133 _channel = DEFAULT_CHANNEL # Expr.g:72:8: ( '|' ) # Expr.g:72:10: '|' pass self.match(124) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__133" # $ANTLR start "T__134" def mT__134(self, ): try: _type = T__134 _channel = DEFAULT_CHANNEL # Expr.g:73:8: ( '|=' ) # Expr.g:73:10: '|=' pass self.match("|=") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__134" # $ANTLR start "T__135" def mT__135(self, ): try: _type = T__135 _channel = DEFAULT_CHANNEL # Expr.g:74:8: ( '||' ) # Expr.g:74:10: '||' pass self.match("||") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__135" # $ANTLR start "T__136" def mT__136(self, ): try: _type = T__136 _channel = DEFAULT_CHANNEL # Expr.g:75:8: ( '}' ) # Expr.g:75:10: '}' pass self.match(125) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__136" # $ANTLR start "NULL" def mNULL(self, ): try: _type = NULL _channel = DEFAULT_CHANNEL # Expr.g:363:2: ( 'null' ) # Expr.g:363:4: 'null' pass self.match("null") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NULL" # $ANTLR start "BOOL" def mBOOL(self, ): try: _type = BOOL _channel = DEFAULT_CHANNEL # Expr.g:364:2: ( 'true' | 'false' ) alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == 116) : alt1 = 1 elif (LA1_0 == 102) : alt1 = 2 else: nvae = NoViableAltException("", 1, 0, self.input) raise nvae if alt1 == 1: # Expr.g:364:4: 'true' pass self.match("true") elif alt1 == 2: # Expr.g:364:13: 'false' pass self.match("false") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "BOOL" # $ANTLR start "ID" def mID(self, ): try: _type = ID _channel = DEFAULT_CHANNEL # Expr.g:367:2: ( ( ALPHA | '_' | '$' ) ( ALPHA | '_' | DIGIT )* ) # Expr.g:367:4: ( ALPHA | '_' | '$' ) ( ALPHA | '_' | DIGIT )* pass if self.input.LA(1) == 36 or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # Expr.g:367:24: ( ALPHA | '_' | DIGIT )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((48 <= LA2_0 <= 57) or (65 <= LA2_0 <= 90) or LA2_0 == 95 or (97 <= LA2_0 <= 122)) : alt2 = 1 if alt2 == 1: # Expr.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop2 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ID" # $ANTLR start "INT" def mINT(self, ): try: _type = INT _channel = DEFAULT_CHANNEL # Expr.g:371:2: ( ( DIGIT )+ ) # Expr.g:371:4: ( DIGIT )+ pass # Expr.g:371:4: ( DIGIT )+ cnt3 = 0 while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if ((48 <= LA3_0 <= 57)) : alt3 = 1 if alt3 == 1: # Expr.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt3 >= 1: break #loop3 eee = EarlyExitException(3, self.input) raise eee cnt3 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INT" # $ANTLR start "FLOAT" def mFLOAT(self, ): try: _type = FLOAT _channel = DEFAULT_CHANNEL # Expr.g:374:2: ( INT '.' ( DIGIT )* ) # Expr.g:374:4: INT '.' ( DIGIT )* pass self.mINT() self.match(46) # Expr.g:374:12: ( DIGIT )* while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if ((48 <= LA4_0 <= 57)) : alt4 = 1 if alt4 == 1: # Expr.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop4 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FLOAT" # $ANTLR start "ALPHA" def mALPHA(self, ): try: # Expr.g:377:2: ( 'a' .. 'z' | 'A' .. 'Z' ) # Expr.g: pass if (65 <= self.input.LA(1) <= 90) or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "ALPHA" # $ANTLR start "DIGIT" def mDIGIT(self, ): try: # Expr.g:380:2: ( '0' .. '9' ) # Expr.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "DIGIT" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # Expr.g:384:2: ( '\"' ( DOUBLE_QUOTE_CHARS )* '\"' | '\\'' ( SINGLE_QUOTE_CHARS )* '\\'' ) alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == 34) : alt7 = 1 elif (LA7_0 == 39) : alt7 = 2 else: nvae = NoViableAltException("", 7, 0, self.input) raise nvae if alt7 == 1: # Expr.g:384:4: '\"' ( DOUBLE_QUOTE_CHARS )* '\"' pass self.match(34) # Expr.g:384:8: ( DOUBLE_QUOTE_CHARS )* while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if ((0 <= LA5_0 <= 33) or (35 <= LA5_0 <= 65535)) : alt5 = 1 if alt5 == 1: # Expr.g:384:8: DOUBLE_QUOTE_CHARS pass self.mDOUBLE_QUOTE_CHARS() else: break #loop5 self.match(34) elif alt7 == 2: # Expr.g:385:4: '\\'' ( SINGLE_QUOTE_CHARS )* '\\'' pass self.match(39) # Expr.g:385:9: ( SINGLE_QUOTE_CHARS )* while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if ((0 <= LA6_0 <= 38) or (40 <= LA6_0 <= 65535)) : alt6 = 1 if alt6 == 1: # Expr.g:385:9: SINGLE_QUOTE_CHARS pass self.mSINGLE_QUOTE_CHARS() else: break #loop6 self.match(39) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "DOUBLE_QUOTE_CHARS" def mDOUBLE_QUOTE_CHARS(self, ): try: # Expr.g:388:2: (~ ( '\"' ) | '\\\\' '\"' | '\\\\' '\\\\' ) alt8 = 3 LA8_0 = self.input.LA(1) if (LA8_0 == 92) : LA8 = self.input.LA(2) if LA8 == 34: alt8 = 2 elif LA8 == 92: alt8 = 3 else: alt8 = 1 elif ((0 <= LA8_0 <= 33) or (35 <= LA8_0 <= 91) or (93 <= LA8_0 <= 65535)) : alt8 = 1 else: nvae = NoViableAltException("", 8, 0, self.input) raise nvae if alt8 == 1: # Expr.g:388:4: ~ ( '\"' ) pass if (0 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt8 == 2: # Expr.g:390:4: '\\\\' '\"' pass self.match(92) self.match(34) elif alt8 == 3: # Expr.g:391:4: '\\\\' '\\\\' pass self.match(92) self.match(92) finally: pass # $ANTLR end "DOUBLE_QUOTE_CHARS" # $ANTLR start "SINGLE_QUOTE_CHARS" def mSINGLE_QUOTE_CHARS(self, ): try: # Expr.g:394:2: (~ ( '\\'' ) | '\\\\' '\\'' | '\\\\' '\\\\' ) alt9 = 3 LA9_0 = self.input.LA(1) if (LA9_0 == 92) : LA9 = self.input.LA(2) if LA9 == 39: alt9 = 2 elif LA9 == 92: alt9 = 3 else: alt9 = 1 elif ((0 <= LA9_0 <= 38) or (40 <= LA9_0 <= 91) or (93 <= LA9_0 <= 65535)) : alt9 = 1 else: nvae = NoViableAltException("", 9, 0, self.input) raise nvae if alt9 == 1: # Expr.g:394:4: ~ ( '\\'' ) pass if (0 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse elif alt9 == 2: # Expr.g:395:4: '\\\\' '\\'' pass self.match(92) self.match(39) elif alt9 == 3: # Expr.g:396:4: '\\\\' '\\\\' pass self.match(92) self.match(92) finally: pass # $ANTLR end "SINGLE_QUOTE_CHARS" # $ANTLR start "NEWLINE" def mNEWLINE(self, ): try: # Expr.g:400:2: ( ( '\\r' )? '\\n' ) # Expr.g:400:4: ( '\\r' )? '\\n' pass # Expr.g:400:4: ( '\\r' )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 13) : alt10 = 1 if alt10 == 1: # Expr.g:400:4: '\\r' pass self.match(13) self.match(10) finally: pass # $ANTLR end "NEWLINE" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # Expr.g:404:2: ( ( ' ' | '\\t' | '\\r' | '\\n' )+ ) # Expr.g:404:4: ( ' ' | '\\t' | '\\r' | '\\n' )+ pass # Expr.g:404:4: ( ' ' | '\\t' | '\\r' | '\\n' )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if ((9 <= LA11_0 <= 10) or LA11_0 == 13 or LA11_0 == 32) : alt11 = 1 if alt11 == 1: # Expr.g: pass if (9 <= self.input.LA(1) <= 10) or self.input.LA(1) == 13 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # Expr.g:407:2: ( '/*' ( options {greedy=false; } : . )* '*/' ) # Expr.g:407:4: '/*' ( options {greedy=false; } : . )* '*/' pass self.match("/*") # Expr.g:407:9: ( options {greedy=false; } : . )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == 42) : LA12_1 = self.input.LA(2) if (LA12_1 == 47) : alt12 = 2 elif ((0 <= LA12_1 <= 46) or (48 <= LA12_1 <= 65535)) : alt12 = 1 elif ((0 <= LA12_0 <= 41) or (43 <= LA12_0 <= 65535)) : alt12 = 1 if alt12 == 1: # Expr.g:407:34: . pass self.matchAny() else: break #loop12 self.match("*/") #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "LINECOMMENT" def mLINECOMMENT(self, ): try: _type = LINECOMMENT _channel = DEFAULT_CHANNEL # Expr.g:410:2: ( ( '//' | '#' ) (~ ( '\\r' | '\\n' ) )* NEWLINE ) # Expr.g:410:4: ( '//' | '#' ) (~ ( '\\r' | '\\n' ) )* NEWLINE pass # Expr.g:410:4: ( '//' | '#' ) alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == 47) : alt13 = 1 elif (LA13_0 == 35) : alt13 = 2 else: nvae = NoViableAltException("", 13, 0, self.input) raise nvae if alt13 == 1: # Expr.g:410:5: '//' pass self.match("//") elif alt13 == 2: # Expr.g:410:10: '#' pass self.match(35) # Expr.g:410:15: (~ ( '\\r' | '\\n' ) )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if ((0 <= LA14_0 <= 9) or (11 <= LA14_0 <= 12) or (14 <= LA14_0 <= 65535)) : alt14 = 1 if alt14 == 1: # Expr.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop14 self.mNEWLINE() #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LINECOMMENT" def mTokens(self): # Expr.g:1:8: ( T__68 | T__69 | T__70 | T__71 | T__72 | T__73 | T__74 | T__75 | T__76 | T__77 | T__78 | T__79 | T__80 | T__81 | T__82 | T__83 | T__84 | T__85 | T__86 | T__87 | T__88 | T__89 | T__90 | T__91 | T__92 | T__93 | T__94 | T__95 | T__96 | T__97 | T__98 | T__99 | T__100 | T__101 | T__102 | T__103 | T__104 | T__105 | T__106 | T__107 | T__108 | T__109 | T__110 | T__111 | T__112 | T__113 | T__114 | T__115 | T__116 | T__117 | T__118 | T__119 | T__120 | T__121 | T__122 | T__123 | T__124 | T__125 | T__126 | T__127 | T__128 | T__129 | T__130 | T__131 | T__132 | T__133 | T__134 | T__135 | T__136 | NULL | BOOL | ID | INT | FLOAT | STRING | WS | COMMENT | LINECOMMENT ) alt15 = 78 alt15 = self.dfa15.predict(self.input) if alt15 == 1: # Expr.g:1:10: T__68 pass self.mT__68() elif alt15 == 2: # Expr.g:1:16: T__69 pass self.mT__69() elif alt15 == 3: # Expr.g:1:22: T__70 pass self.mT__70() elif alt15 == 4: # Expr.g:1:28: T__71 pass self.mT__71() elif alt15 == 5: # Expr.g:1:34: T__72 pass self.mT__72() elif alt15 == 6: # Expr.g:1:40: T__73 pass self.mT__73() elif alt15 == 7: # Expr.g:1:46: T__74 pass self.mT__74() elif alt15 == 8: # Expr.g:1:52: T__75 pass self.mT__75() elif alt15 == 9: # Expr.g:1:58: T__76 pass self.mT__76() elif alt15 == 10: # Expr.g:1:64: T__77 pass self.mT__77() elif alt15 == 11: # Expr.g:1:70: T__78 pass self.mT__78() elif alt15 == 12: # Expr.g:1:76: T__79 pass self.mT__79() elif alt15 == 13: # Expr.g:1:82: T__80 pass self.mT__80() elif alt15 == 14: # Expr.g:1:88: T__81 pass self.mT__81() elif alt15 == 15: # Expr.g:1:94: T__82 pass self.mT__82() elif alt15 == 16: # Expr.g:1:100: T__83 pass self.mT__83() elif alt15 == 17: # Expr.g:1:106: T__84 pass self.mT__84() elif alt15 == 18: # Expr.g:1:112: T__85 pass self.mT__85() elif alt15 == 19: # Expr.g:1:118: T__86 pass self.mT__86() elif alt15 == 20: # Expr.g:1:124: T__87 pass self.mT__87() elif alt15 == 21: # Expr.g:1:130: T__88 pass self.mT__88() elif alt15 == 22: # Expr.g:1:136: T__89 pass self.mT__89() elif alt15 == 23: # Expr.g:1:142: T__90 pass self.mT__90() elif alt15 == 24: # Expr.g:1:148: T__91 pass self.mT__91() elif alt15 == 25: # Expr.g:1:154: T__92 pass self.mT__92() elif alt15 == 26: # Expr.g:1:160: T__93 pass self.mT__93() elif alt15 == 27: # Expr.g:1:166: T__94 pass self.mT__94() elif alt15 == 28: # Expr.g:1:172: T__95 pass self.mT__95() elif alt15 == 29: # Expr.g:1:178: T__96 pass self.mT__96() elif alt15 == 30: # Expr.g:1:184: T__97 pass self.mT__97() elif alt15 == 31: # Expr.g:1:190: T__98 pass self.mT__98() elif alt15 == 32: # Expr.g:1:196: T__99 pass self.mT__99() elif alt15 == 33: # Expr.g:1:202: T__100 pass self.mT__100() elif alt15 == 34: # Expr.g:1:209: T__101 pass self.mT__101() elif alt15 == 35: # Expr.g:1:216: T__102 pass self.mT__102() elif alt15 == 36: # Expr.g:1:223: T__103 pass self.mT__103() elif alt15 == 37: # Expr.g:1:230: T__104 pass self.mT__104() elif alt15 == 38: # Expr.g:1:237: T__105 pass self.mT__105() elif alt15 == 39: # Expr.g:1:244: T__106 pass self.mT__106() elif alt15 == 40: # Expr.g:1:251: T__107 pass self.mT__107() elif alt15 == 41: # Expr.g:1:258: T__108 pass self.mT__108() elif alt15 == 42: # Expr.g:1:265: T__109 pass self.mT__109() elif alt15 == 43: # Expr.g:1:272: T__110 pass self.mT__110() elif alt15 == 44: # Expr.g:1:279: T__111 pass self.mT__111() elif alt15 == 45: # Expr.g:1:286: T__112 pass self.mT__112() elif alt15 == 46: # Expr.g:1:293: T__113 pass self.mT__113() elif alt15 == 47: # Expr.g:1:300: T__114 pass self.mT__114() elif alt15 == 48: # Expr.g:1:307: T__115 pass self.mT__115() elif alt15 == 49: # Expr.g:1:314: T__116 pass self.mT__116() elif alt15 == 50: # Expr.g:1:321: T__117 pass self.mT__117() elif alt15 == 51: # Expr.g:1:328: T__118 pass self.mT__118() elif alt15 == 52: # Expr.g:1:335: T__119 pass self.mT__119() elif alt15 == 53: # Expr.g:1:342: T__120 pass self.mT__120() elif alt15 == 54: # Expr.g:1:349: T__121 pass self.mT__121() elif alt15 == 55: # Expr.g:1:356: T__122 pass self.mT__122() elif alt15 == 56: # Expr.g:1:363: T__123 pass self.mT__123() elif alt15 == 57: # Expr.g:1:370: T__124 pass self.mT__124() elif alt15 == 58: # Expr.g:1:377: T__125 pass self.mT__125() elif alt15 == 59: # Expr.g:1:384: T__126 pass self.mT__126() elif alt15 == 60: # Expr.g:1:391: T__127 pass self.mT__127() elif alt15 == 61: # Expr.g:1:398: T__128 pass self.mT__128() elif alt15 == 62: # Expr.g:1:405: T__129 pass self.mT__129() elif alt15 == 63: # Expr.g:1:412: T__130 pass self.mT__130() elif alt15 == 64: # Expr.g:1:419: T__131 pass self.mT__131() elif alt15 == 65: # Expr.g:1:426: T__132 pass self.mT__132() elif alt15 == 66: # Expr.g:1:433: T__133 pass self.mT__133() elif alt15 == 67: # Expr.g:1:440: T__134 pass self.mT__134() elif alt15 == 68: # Expr.g:1:447: T__135 pass self.mT__135() elif alt15 == 69: # Expr.g:1:454: T__136 pass self.mT__136() elif alt15 == 70: # Expr.g:1:461: NULL pass self.mNULL() elif alt15 == 71: # Expr.g:1:466: BOOL pass self.mBOOL() elif alt15 == 72: # Expr.g:1:471: ID pass self.mID() elif alt15 == 73: # Expr.g:1:474: INT pass self.mINT() elif alt15 == 74: # Expr.g:1:478: FLOAT pass self.mFLOAT() elif alt15 == 75: # Expr.g:1:484: STRING pass self.mSTRING() elif alt15 == 76: # Expr.g:1:491: WS pass self.mWS() elif alt15 == 77: # Expr.g:1:494: COMMENT pass self.mCOMMENT() elif alt15 == 78: # Expr.g:1:502: LINECOMMENT pass self.mLINECOMMENT() # lookup tables for DFA #15 DFA15_eot = DFA.unpack( u"\1\uffff\1\52\1\54\1\57\2\uffff\1\61\1\64\1\uffff\1\67\1\72\1\75" u"\2\uffff\1\77\1\102\1\104\2\uffff\1\106\15\44\1\uffff\1\144\2\uffff" u"\1\145\41\uffff\1\147\5\44\1\156\6\44\1\165\15\44\6\uffff\6\44" u"\1\uffff\3\44\1\u008e\2\44\1\uffff\2\44\1\u0093\10\44\1\u009c\3" u"\44\1\u00a0\4\44\1\u00a5\3\44\1\uffff\3\44\1\u00ac\1\uffff\1\u00ad" u"\7\44\1\uffff\1\u00b5\1\44\1\u00b7\1\uffff\1\u00b8\1\u00b9\2\44" u"\1\uffff\4\44\1\u00b5\1\44\2\uffff\1\u00c2\5\44\1\u00c8\1\uffff" u"\1\u00c9\3\uffff\6\44\1\u00d0\1\u00d1\1\uffff\1\u00d2\1\u00d3\1" u"\44\1\u00d5\1\u00d6\2\uffff\1\44\1\u00d8\1\u00d9\1\u00da\1\u00db" u"\1\44\4\uffff\1\u00dd\2\uffff\1\u00de\4\uffff\1\u00df\3\uffff" ) DFA15_eof = DFA.unpack( u"\u00e0\uffff" ) DFA15_min = DFA.unpack( u"\1\11\2\75\1\46\2\uffff\1\75\1\53\1\uffff\1\55\2\52\2\uffff\3\75" u"\2\uffff\1\75\1\163\1\162\1\141\1\145\1\154\1\141\1\146\1\145\1" u"\162\1\145\1\160\2\150\1\uffff\1\75\2\uffff\1\56\41\uffff\1\60" u"\1\145\1\163\1\141\1\156\1\146\1\60\1\163\1\164\1\156\1\162\1\156" u"\1\154\1\60\1\160\1\151\1\167\1\154\1\151\1\142\1\164\1\162\1\141" u"\1\151\1\162\1\165\1\151\6\uffff\1\141\1\145\1\143\1\163\1\164" u"\1\141\1\uffff\2\145\1\141\1\60\1\143\1\163\1\uffff\1\157\1\164" u"\1\60\1\154\1\156\1\154\1\165\1\151\2\164\1\157\1\60\1\145\1\154" u"\1\153\1\60\1\150\1\163\1\151\1\165\1\60\1\156\1\154\1\141\1\uffff" u"\1\164\1\145\1\162\1\60\1\uffff\1\60\1\164\1\151\1\162\1\156\1" u"\151\1\143\1\167\1\uffff\1\60\1\145\1\60\1\uffff\2\60\1\156\1\154" u"\1\uffff\1\144\1\154\1\143\1\151\1\60\1\164\2\uffff\1\60\1\143" u"\1\156\1\164\1\143\1\150\1\60\1\uffff\1\60\3\uffff\1\165\1\164" u"\1\163\1\171\1\150\1\157\2\60\1\uffff\2\60\1\146\2\60\2\uffff\1" u"\145\4\60\1\156\4\uffff\1\60\2\uffff\1\60\4\uffff\1\60\3\uffff" ) DFA15_max = DFA.unpack( u"\1\175\3\75\2\uffff\2\75\1\uffff\1\75\1\56\1\75\2\uffff\1\75\1" u"\76\1\75\2\uffff\1\75\1\163\1\162\2\157\1\170\1\165\1\156\2\165" u"\1\145\1\167\1\162\1\150\1\uffff\1\174\2\uffff\1\71\41\uffff\1" u"\172\1\145\1\164\1\141\1\156\1\146\1\172\1\163\1\164\1\156\1\162" u"\1\156\1\154\1\172\1\160\1\151\1\167\1\154\1\151\1\142\1\164\1" u"\162\1\141\1\151\1\162\1\171\1\151\6\uffff\1\141\1\145\1\143\1" u"\163\1\164\1\141\1\uffff\2\145\1\141\1\172\1\143\1\163\1\uffff" u"\1\157\1\164\1\172\1\154\1\156\1\154\1\165\1\151\2\164\1\157\1" u"\172\1\145\1\154\1\153\1\172\1\150\1\163\1\151\1\165\1\172\1\156" u"\1\154\1\141\1\uffff\1\164\1\145\1\162\1\172\1\uffff\1\172\1\164" u"\1\151\1\162\1\156\1\151\1\143\1\167\1\uffff\1\172\1\145\1\172" u"\1\uffff\2\172\1\156\1\154\1\uffff\1\144\1\154\1\143\1\151\1\172" u"\1\164\2\uffff\1\172\1\143\1\156\1\164\1\143\1\150\1\172\1\uffff" u"\1\172\3\uffff\1\165\1\164\1\163\1\171\1\150\1\157\2\172\1\uffff" u"\2\172\1\146\2\172\2\uffff\1\145\4\172\1\156\4\uffff\1\172\2\uffff" u"\1\172\4\uffff\1\172\3\uffff" ) DFA15_accept = DFA.unpack( u"\4\uffff\1\10\1\11\2\uffff\1\17\3\uffff\1\30\1\31\3\uffff\1\41" u"\1\42\16\uffff\1\101\1\uffff\1\105\1\110\1\uffff\1\113\1\114\1" u"\116\1\2\1\1\1\4\1\3\1\5\1\7\1\6\1\13\1\12\1\15\1\16\1\14\1\21" u"\1\22\1\20\1\24\1\25\1\23\1\27\1\115\1\26\1\33\1\32\1\35\1\36\1" u"\34\1\40\1\37\1\44\1\43\33\uffff\1\103\1\104\1\102\1\111\1\112" u"\1\45\6\uffff\1\54\6\uffff\1\63\30\uffff\1\60\4\uffff\1\66\10\uffff" u"\1\77\3\uffff\1\47\4\uffff\1\55\6\uffff\1\65\1\106\7\uffff\1\107" u"\1\uffff\1\46\1\50\1\51\10\uffff\1\67\5\uffff\1\76\1\100\6\uffff" u"\1\64\1\70\1\71\1\72\1\uffff\1\74\1\75\1\uffff\1\53\1\56\1\57\1" u"\61\1\uffff\1\73\1\52\1\62" ) DFA15_special = DFA.unpack( u"\u00e0\uffff" ) DFA15_transition = [ DFA.unpack(u"\2\47\2\uffff\1\47\22\uffff\1\47\1\1\1\46\1\50\1\44" u"\1\2\1\3\1\46\1\4\1\5\1\6\1\7\1\10\1\11\1\12\1\13\12\45\1\14\1" u"\15\1\16\1\17\1\20\2\uffff\32\44\1\21\1\uffff\1\22\1\23\1\44\1" u"\uffff\1\24\1\25\1\26\1\27\1\30\1\31\2\44\1\32\4\44\1\33\1\44\1" u"\34\1\44\1\35\1\36\1\37\2\44\1\40\3\44\1\41\1\42\1\43"), DFA.unpack(u"\1\51"), DFA.unpack(u"\1\53"), DFA.unpack(u"\1\55\26\uffff\1\56"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\60"), DFA.unpack(u"\1\62\21\uffff\1\63"), DFA.unpack(u""), DFA.unpack(u"\1\65\17\uffff\1\66"), DFA.unpack(u"\1\70\3\uffff\1\71"), DFA.unpack(u"\1\74\4\uffff\1\50\15\uffff\1\73"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\76"), DFA.unpack(u"\1\100\1\101"), DFA.unpack(u"\1\103"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\105"), DFA.unpack(u"\1\107"), DFA.unpack(u"\1\110"), DFA.unpack(u"\1\111\12\uffff\1\112\2\uffff\1\113"), DFA.unpack(u"\1\114\11\uffff\1\115"), DFA.unpack(u"\1\116\13\uffff\1\117"), DFA.unpack(u"\1\123\7\uffff\1\120\5\uffff\1\121\5\uffff\1\122"), DFA.unpack(u"\1\124\6\uffff\1\125\1\126"), DFA.unpack(u"\1\127\17\uffff\1\130"), DFA.unpack(u"\1\131\2\uffff\1\132"), DFA.unpack(u"\1\133"), DFA.unpack(u"\1\134\3\uffff\1\135\2\uffff\1\136"), DFA.unpack(u"\1\137\11\uffff\1\140"), DFA.unpack(u"\1\141"), DFA.unpack(u""), DFA.unpack(u"\1\142\76\uffff\1\143"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\146\1\uffff\12\45"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\150"), DFA.unpack(u"\1\151\1\152"), DFA.unpack(u"\1\153"), DFA.unpack(u"\1\154"), DFA.unpack(u"\1\155"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\157"), DFA.unpack(u"\1\160"), DFA.unpack(u"\1\161"), DFA.unpack(u"\1\162"), DFA.unpack(u"\1\163"), DFA.unpack(u"\1\164"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\166"), DFA.unpack(u"\1\167"), DFA.unpack(u"\1\170"), DFA.unpack(u"\1\171"), DFA.unpack(u"\1\172"), DFA.unpack(u"\1\173"), DFA.unpack(u"\1\174"), DFA.unpack(u"\1\175"), DFA.unpack(u"\1\176"), DFA.unpack(u"\1\177"), DFA.unpack(u"\1\u0080"), DFA.unpack(u"\1\u0082\3\uffff\1\u0081"), DFA.unpack(u"\1\u0083"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u0084"), DFA.unpack(u"\1\u0085"), DFA.unpack(u"\1\u0086"), DFA.unpack(u"\1\u0087"), DFA.unpack(u"\1\u0088"), DFA.unpack(u"\1\u0089"), DFA.unpack(u""), DFA.unpack(u"\1\u008a"), DFA.unpack(u"\1\u008b"), DFA.unpack(u"\1\u008c"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\4\44\1\u008d" u"\25\44"), DFA.unpack(u"\1\u008f"), DFA.unpack(u"\1\u0090"), DFA.unpack(u""), DFA.unpack(u"\1\u0091"), DFA.unpack(u"\1\u0092"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u0094"), DFA.unpack(u"\1\u0095"), DFA.unpack(u"\1\u0096"), DFA.unpack(u"\1\u0097"), DFA.unpack(u"\1\u0098"), DFA.unpack(u"\1\u0099"), DFA.unpack(u"\1\u009a"), DFA.unpack(u"\1\u009b"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u009d"), DFA.unpack(u"\1\u009e"), DFA.unpack(u"\1\u009f"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00a1"), DFA.unpack(u"\1\u00a2"), DFA.unpack(u"\1\u00a3"), DFA.unpack(u"\1\u00a4"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00a6"), DFA.unpack(u"\1\u00a7"), DFA.unpack(u"\1\u00a8"), DFA.unpack(u""), DFA.unpack(u"\1\u00a9"), DFA.unpack(u"\1\u00aa"), DFA.unpack(u"\1\u00ab"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00ae"), DFA.unpack(u"\1\u00af"), DFA.unpack(u"\1\u00b0"), DFA.unpack(u"\1\u00b1"), DFA.unpack(u"\1\u00b2"), DFA.unpack(u"\1\u00b3"), DFA.unpack(u"\1\u00b4"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00b6"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00ba"), DFA.unpack(u"\1\u00bb"), DFA.unpack(u""), DFA.unpack(u"\1\u00bc"), DFA.unpack(u"\1\u00bd"), DFA.unpack(u"\1\u00be"), DFA.unpack(u"\1\u00bf"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00c0"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\5\44\1\u00c1" u"\24\44"), DFA.unpack(u"\1\u00c3"), DFA.unpack(u"\1\u00c4"), DFA.unpack(u"\1\u00c5"), DFA.unpack(u"\1\u00c6"), DFA.unpack(u"\1\u00c7"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00ca"), DFA.unpack(u"\1\u00cb"), DFA.unpack(u"\1\u00cc"), DFA.unpack(u"\1\u00cd"), DFA.unpack(u"\1\u00ce"), DFA.unpack(u"\1\u00cf"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00d4"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\u00d7"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u"\1\u00dc"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\12\44\7\uffff\32\44\4\uffff\1\44\1\uffff\32\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #15 class DFA15(DFA): pass def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(ExprLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "lingdecong/ssdb_study", "path": "deps/cpy/ExprLexer.py", "copies": "36", "size": "68008", "license": "bsd-3-clause", "hash": 7907525342318916000, "line_mean": 19.3616766467, "line_max": 683, "alpha_frac": 0.4092900835, "autogenerated": false, "ratio": 3.1204918784986693, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": null, "num_lines": null }
# $ANTLR 3.5 /Users/tim/opencode/congress/congress/datalog/Congress.g 2015-08-03 09:06:21 import sys from antlr3 import * from antlr3.compat import set, frozenset from antlr3.tree import * # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__53=53 T__54=54 T__55=55 T__56=56 T__57=57 T__58=58 AND=4 ATOM=5 BYTESTRPREFIX=6 BYTES_CHAR_DQ=7 BYTES_CHAR_SQ=8 BYTES_ESC=9 BYTES_TESC=10 COLONMINUS=11 COLUMN_NAME=12 COLUMN_NUMBER=13 COMMA=14 COMMENT=15 DIGIT=16 EQUAL=17 EVENT=18 EXPONENT=19 FLOAT=20 FLOAT_EXP=21 FLOAT_NO_EXP=22 FLOAT_OBJ=23 FRAC_PART=24 HEX_DIGIT=25 ID=26 INT=27 INTEGER_OBJ=28 INT_PART=29 LBRACKET=30 LITERAL=31 LPAREN=32 MODAL=33 NAMED_PARAM=34 NEGATION=35 NOT=36 PROG=37 RBRACKET=38 RPAREN=39 RULE=40 SIGN=41 SLBYTESTRING=42 SLSTRING=43 STRING=44 STRING_ESC=45 STRING_OBJ=46 STRPREFIX=47 STRUCTURED_NAME=48 SYMBOL_OBJ=49 THEORY=50 VARIABLE=51 WS=52 # token names tokenNames = [ "<invalid>", "<EOR>", "<DOWN>", "<UP>", "AND", "ATOM", "BYTESTRPREFIX", "BYTES_CHAR_DQ", "BYTES_CHAR_SQ", "BYTES_ESC", "BYTES_TESC", "COLONMINUS", "COLUMN_NAME", "COLUMN_NUMBER", "COMMA", "COMMENT", "DIGIT", "EQUAL", "EVENT", "EXPONENT", "FLOAT", "FLOAT_EXP", "FLOAT_NO_EXP", "FLOAT_OBJ", "FRAC_PART", "HEX_DIGIT", "ID", "INT", "INTEGER_OBJ", "INT_PART", "LBRACKET", "LITERAL", "LPAREN", "MODAL", "NAMED_PARAM", "NEGATION", "NOT", "PROG", "RBRACKET", "RPAREN", "RULE", "SIGN", "SLBYTESTRING", "SLSTRING", "STRING", "STRING_ESC", "STRING_OBJ", "STRPREFIX", "STRUCTURED_NAME", "SYMBOL_OBJ", "THEORY", "VARIABLE", "WS", "'.'", "':'", "';'", "'delete'", "'execute'", "'insert'" ] class CongressParser(Parser): grammarFileName = "/Users/tim/opencode/congress/congress/datalog/Congress.g" api_version = 1 tokenNames = tokenNames def __init__(self, input, state=None, *args, **kwargs): if state is None: state = RecognizerSharedState() super(CongressParser, self).__init__(input, state, *args, **kwargs) self.dfa5 = self.DFA5( self, 5, eot = self.DFA5_eot, eof = self.DFA5_eof, min = self.DFA5_min, max = self.DFA5_max, accept = self.DFA5_accept, special = self.DFA5_special, transition = self.DFA5_transition ) self.delegates = [] self._adaptor = None self.adaptor = CommonTreeAdaptor() def getTreeAdaptor(self): return self._adaptor def setTreeAdaptor(self, adaptor): self._adaptor = adaptor adaptor = property(getTreeAdaptor, setTreeAdaptor) class prog_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.prog_return, self).__init__() self.tree = None # $ANTLR start "prog" # /Users/tim/opencode/congress/congress/datalog/Congress.g:58:1: prog : ( ( statement )+ EOF -> ^( THEORY ( statement )+ ) | EOF ); def prog(self, ): retval = self.prog_return() retval.start = self.input.LT(1) root_0 = None EOF2 = None EOF3 = None statement1 = None EOF2_tree = None EOF3_tree = None stream_EOF = RewriteRuleTokenStream(self._adaptor, "token EOF") stream_statement = RewriteRuleSubtreeStream(self._adaptor, "rule statement") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:59:5: ( ( statement )+ EOF -> ^( THEORY ( statement )+ ) | EOF ) alt2 = 2 LA2_0 = self.input.LA(1) if (LA2_0 == COMMENT or LA2_0 == ID or LA2_0 == NEGATION or (56 <= LA2_0 <= 58)) : alt2 = 1 elif (LA2_0 == EOF) : alt2 = 2 else: nvae = NoViableAltException("", 2, 0, self.input) raise nvae if alt2 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:59:7: ( statement )+ EOF pass # /Users/tim/opencode/congress/congress/datalog/Congress.g:59:7: ( statement )+ cnt1 = 0 while True: #loop1 alt1 = 2 LA1_0 = self.input.LA(1) if (LA1_0 == COMMENT or LA1_0 == ID or LA1_0 == NEGATION or (56 <= LA1_0 <= 58)) : alt1 = 1 if alt1 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:59:7: statement pass self._state.following.append(self.FOLLOW_statement_in_prog265) statement1 = self.statement() self._state.following.pop() stream_statement.add(statement1.tree) else: if cnt1 >= 1: break #loop1 eee = EarlyExitException(1, self.input) raise eee cnt1 += 1 EOF2 = self.match(self.input, EOF, self.FOLLOW_EOF_in_prog268) stream_EOF.add(EOF2) # AST Rewrite # elements: statement # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 59:22: -> ^( THEORY ( statement )+ ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:59:25: ^( THEORY ( statement )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(THEORY, "THEORY") , root_1) # /Users/tim/opencode/congress/congress/datalog/Congress.g:59:34: ( statement )+ if not (stream_statement.hasNext()): raise RewriteEarlyExitException() while stream_statement.hasNext(): self._adaptor.addChild(root_1, stream_statement.nextTree()) stream_statement.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt2 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:60:7: EOF pass root_0 = self._adaptor.nil() EOF3 = self.match(self.input, EOF, self.FOLLOW_EOF_in_prog285) EOF3_tree = self._adaptor.createWithPayload(EOF3) self._adaptor.addChild(root_0, EOF3_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "prog" class statement_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.statement_return, self).__init__() self.tree = None # $ANTLR start "statement" # /Users/tim/opencode/congress/congress/datalog/Congress.g:65:1: statement : ( formula ( formula_terminator )? -> formula | COMMENT ); def statement(self, ): retval = self.statement_return() retval.start = self.input.LT(1) root_0 = None COMMENT6 = None formula4 = None formula_terminator5 = None COMMENT6_tree = None stream_formula_terminator = RewriteRuleSubtreeStream(self._adaptor, "rule formula_terminator") stream_formula = RewriteRuleSubtreeStream(self._adaptor, "rule formula") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:66:5: ( formula ( formula_terminator )? -> formula | COMMENT ) alt4 = 2 LA4_0 = self.input.LA(1) if (LA4_0 == ID or LA4_0 == NEGATION or (56 <= LA4_0 <= 58)) : alt4 = 1 elif (LA4_0 == COMMENT) : alt4 = 2 else: nvae = NoViableAltException("", 4, 0, self.input) raise nvae if alt4 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:66:7: formula ( formula_terminator )? pass self._state.following.append(self.FOLLOW_formula_in_statement304) formula4 = self.formula() self._state.following.pop() stream_formula.add(formula4.tree) # /Users/tim/opencode/congress/congress/datalog/Congress.g:66:15: ( formula_terminator )? alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == 53 or LA3_0 == 55) : alt3 = 1 if alt3 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:66:15: formula_terminator pass self._state.following.append(self.FOLLOW_formula_terminator_in_statement306) formula_terminator5 = self.formula_terminator() self._state.following.pop() stream_formula_terminator.add(formula_terminator5.tree) # AST Rewrite # elements: formula # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 66:35: -> formula self._adaptor.addChild(root_0, stream_formula.nextTree()) retval.tree = root_0 elif alt4 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:67:7: COMMENT pass root_0 = self._adaptor.nil() COMMENT6 = self.match(self.input, COMMENT, self.FOLLOW_COMMENT_in_statement319) COMMENT6_tree = self._adaptor.createWithPayload(COMMENT6) self._adaptor.addChild(root_0, COMMENT6_tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "statement" class formula_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.formula_return, self).__init__() self.tree = None # $ANTLR start "formula" # /Users/tim/opencode/congress/congress/datalog/Congress.g:70:1: formula : ( rule | fact | event ); def formula(self, ): retval = self.formula_return() retval.start = self.input.LT(1) root_0 = None rule7 = None fact8 = None event9 = None try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:71:5: ( rule | fact | event ) alt5 = 3 alt5 = self.dfa5.predict(self.input) if alt5 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:71:7: rule pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_rule_in_formula336) rule7 = self.rule() self._state.following.pop() self._adaptor.addChild(root_0, rule7.tree) elif alt5 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:72:7: fact pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_fact_in_formula344) fact8 = self.fact() self._state.following.pop() self._adaptor.addChild(root_0, fact8.tree) elif alt5 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:73:7: event pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_event_in_formula352) event9 = self.event() self._state.following.pop() self._adaptor.addChild(root_0, event9.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "formula" class event_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.event_return, self).__init__() self.tree = None # $ANTLR start "event" # /Users/tim/opencode/congress/congress/datalog/Congress.g:86:1: event : event_op LBRACKET rule ( formula_terminator STRING )? RBRACKET -> ^( EVENT event_op rule ( STRING )? ) ; def event(self, ): retval = self.event_return() retval.start = self.input.LT(1) root_0 = None LBRACKET11 = None STRING14 = None RBRACKET15 = None event_op10 = None rule12 = None formula_terminator13 = None LBRACKET11_tree = None STRING14_tree = None RBRACKET15_tree = None stream_LBRACKET = RewriteRuleTokenStream(self._adaptor, "token LBRACKET") stream_STRING = RewriteRuleTokenStream(self._adaptor, "token STRING") stream_RBRACKET = RewriteRuleTokenStream(self._adaptor, "token RBRACKET") stream_event_op = RewriteRuleSubtreeStream(self._adaptor, "rule event_op") stream_formula_terminator = RewriteRuleSubtreeStream(self._adaptor, "rule formula_terminator") stream_rule = RewriteRuleSubtreeStream(self._adaptor, "rule rule") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:87:5: ( event_op LBRACKET rule ( formula_terminator STRING )? RBRACKET -> ^( EVENT event_op rule ( STRING )? ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:87:7: event_op LBRACKET rule ( formula_terminator STRING )? RBRACKET pass self._state.following.append(self.FOLLOW_event_op_in_event379) event_op10 = self.event_op() self._state.following.pop() stream_event_op.add(event_op10.tree) LBRACKET11 = self.match(self.input, LBRACKET, self.FOLLOW_LBRACKET_in_event381) stream_LBRACKET.add(LBRACKET11) self._state.following.append(self.FOLLOW_rule_in_event383) rule12 = self.rule() self._state.following.pop() stream_rule.add(rule12.tree) # /Users/tim/opencode/congress/congress/datalog/Congress.g:87:30: ( formula_terminator STRING )? alt6 = 2 LA6_0 = self.input.LA(1) if (LA6_0 == 53 or LA6_0 == 55) : alt6 = 1 if alt6 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:87:31: formula_terminator STRING pass self._state.following.append(self.FOLLOW_formula_terminator_in_event386) formula_terminator13 = self.formula_terminator() self._state.following.pop() stream_formula_terminator.add(formula_terminator13.tree) STRING14 = self.match(self.input, STRING, self.FOLLOW_STRING_in_event388) stream_STRING.add(STRING14) RBRACKET15 = self.match(self.input, RBRACKET, self.FOLLOW_RBRACKET_in_event392) stream_RBRACKET.add(RBRACKET15) # AST Rewrite # elements: rule, STRING, event_op # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 87:68: -> ^( EVENT event_op rule ( STRING )? ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:87:71: ^( EVENT event_op rule ( STRING )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(EVENT, "EVENT") , root_1) self._adaptor.addChild(root_1, stream_event_op.nextTree()) self._adaptor.addChild(root_1, stream_rule.nextTree()) # /Users/tim/opencode/congress/congress/datalog/Congress.g:87:93: ( STRING )? if stream_STRING.hasNext(): self._adaptor.addChild(root_1, stream_STRING.nextNode() ) stream_STRING.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "event" class event_op_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.event_op_return, self).__init__() self.tree = None # $ANTLR start "event_op" # /Users/tim/opencode/congress/congress/datalog/Congress.g:90:1: event_op : ( 'insert' | 'delete' ); def event_op(self, ): retval = self.event_op_return() retval.start = self.input.LT(1) root_0 = None set16 = None set16_tree = None try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:91:5: ( 'insert' | 'delete' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass root_0 = self._adaptor.nil() set16 = self.input.LT(1) if self.input.LA(1) == 56 or self.input.LA(1) == 58: self.input.consume() self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set16)) self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "event_op" class formula_terminator_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.formula_terminator_return, self).__init__() self.tree = None # $ANTLR start "formula_terminator" # /Users/tim/opencode/congress/congress/datalog/Congress.g:95:1: formula_terminator : ( ';' | '.' ); def formula_terminator(self, ): retval = self.formula_terminator_return() retval.start = self.input.LT(1) root_0 = None set17 = None set17_tree = None try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:96:5: ( ';' | '.' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass root_0 = self._adaptor.nil() set17 = self.input.LT(1) if self.input.LA(1) == 53 or self.input.LA(1) == 55: self.input.consume() self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set17)) self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "formula_terminator" class rule_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.rule_return, self).__init__() self.tree = None # $ANTLR start "rule" # /Users/tim/opencode/congress/congress/datalog/Congress.g:100:1: rule : literal_list COLONMINUS literal_list -> ^( RULE literal_list literal_list ) ; def rule(self, ): retval = self.rule_return() retval.start = self.input.LT(1) root_0 = None COLONMINUS19 = None literal_list18 = None literal_list20 = None COLONMINUS19_tree = None stream_COLONMINUS = RewriteRuleTokenStream(self._adaptor, "token COLONMINUS") stream_literal_list = RewriteRuleSubtreeStream(self._adaptor, "rule literal_list") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:101:5: ( literal_list COLONMINUS literal_list -> ^( RULE literal_list literal_list ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:101:7: literal_list COLONMINUS literal_list pass self._state.following.append(self.FOLLOW_literal_list_in_rule472) literal_list18 = self.literal_list() self._state.following.pop() stream_literal_list.add(literal_list18.tree) COLONMINUS19 = self.match(self.input, COLONMINUS, self.FOLLOW_COLONMINUS_in_rule474) stream_COLONMINUS.add(COLONMINUS19) self._state.following.append(self.FOLLOW_literal_list_in_rule476) literal_list20 = self.literal_list() self._state.following.pop() stream_literal_list.add(literal_list20.tree) # AST Rewrite # elements: literal_list, literal_list # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 101:44: -> ^( RULE literal_list literal_list ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:101:47: ^( RULE literal_list literal_list ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(RULE, "RULE") , root_1) self._adaptor.addChild(root_1, stream_literal_list.nextTree()) self._adaptor.addChild(root_1, stream_literal_list.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "rule" class literal_list_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.literal_list_return, self).__init__() self.tree = None # $ANTLR start "literal_list" # /Users/tim/opencode/congress/congress/datalog/Congress.g:104:1: literal_list : literal ( COMMA literal )* -> ^( AND ( literal )+ ) ; def literal_list(self, ): retval = self.literal_list_return() retval.start = self.input.LT(1) root_0 = None COMMA22 = None literal21 = None literal23 = None COMMA22_tree = None stream_COMMA = RewriteRuleTokenStream(self._adaptor, "token COMMA") stream_literal = RewriteRuleSubtreeStream(self._adaptor, "rule literal") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:105:5: ( literal ( COMMA literal )* -> ^( AND ( literal )+ ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:105:7: literal ( COMMA literal )* pass self._state.following.append(self.FOLLOW_literal_in_literal_list503) literal21 = self.literal() self._state.following.pop() stream_literal.add(literal21.tree) # /Users/tim/opencode/congress/congress/datalog/Congress.g:105:15: ( COMMA literal )* while True: #loop7 alt7 = 2 LA7_0 = self.input.LA(1) if (LA7_0 == COMMA) : alt7 = 1 if alt7 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:105:16: COMMA literal pass COMMA22 = self.match(self.input, COMMA, self.FOLLOW_COMMA_in_literal_list506) stream_COMMA.add(COMMA22) self._state.following.append(self.FOLLOW_literal_in_literal_list508) literal23 = self.literal() self._state.following.pop() stream_literal.add(literal23.tree) else: break #loop7 # AST Rewrite # elements: literal # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 105:32: -> ^( AND ( literal )+ ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:105:35: ^( AND ( literal )+ ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(AND, "AND") , root_1) # /Users/tim/opencode/congress/congress/datalog/Congress.g:105:41: ( literal )+ if not (stream_literal.hasNext()): raise RewriteEarlyExitException() while stream_literal.hasNext(): self._adaptor.addChild(root_1, stream_literal.nextTree()) stream_literal.reset() self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "literal_list" class literal_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.literal_return, self).__init__() self.tree = None # $ANTLR start "literal" # /Users/tim/opencode/congress/congress/datalog/Congress.g:108:1: literal : ( fact -> fact | NEGATION fact -> ^( NOT fact ) ); def literal(self, ): retval = self.literal_return() retval.start = self.input.LT(1) root_0 = None NEGATION25 = None fact24 = None fact26 = None NEGATION25_tree = None stream_NEGATION = RewriteRuleTokenStream(self._adaptor, "token NEGATION") stream_fact = RewriteRuleSubtreeStream(self._adaptor, "rule fact") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:109:5: ( fact -> fact | NEGATION fact -> ^( NOT fact ) ) alt8 = 2 LA8_0 = self.input.LA(1) if (LA8_0 == ID or (56 <= LA8_0 <= 58)) : alt8 = 1 elif (LA8_0 == NEGATION) : alt8 = 2 else: nvae = NoViableAltException("", 8, 0, self.input) raise nvae if alt8 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:109:7: fact pass self._state.following.append(self.FOLLOW_fact_in_literal536) fact24 = self.fact() self._state.following.pop() stream_fact.add(fact24.tree) # AST Rewrite # elements: fact # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 109:23: -> fact self._adaptor.addChild(root_0, stream_fact.nextTree()) retval.tree = root_0 elif alt8 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:110:7: NEGATION fact pass NEGATION25 = self.match(self.input, NEGATION, self.FOLLOW_NEGATION_in_literal559) stream_NEGATION.add(NEGATION25) self._state.following.append(self.FOLLOW_fact_in_literal561) fact26 = self.fact() self._state.following.pop() stream_fact.add(fact26.tree) # AST Rewrite # elements: fact # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 110:23: -> ^( NOT fact ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:110:26: ^( NOT fact ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(NOT, "NOT") , root_1) self._adaptor.addChild(root_1, stream_fact.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "literal" class fact_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.fact_return, self).__init__() self.tree = None # $ANTLR start "fact" # /Users/tim/opencode/congress/congress/datalog/Congress.g:115:1: fact : ( atom | modal_op LBRACKET atom RBRACKET -> ^( MODAL modal_op atom ) ); def fact(self, ): retval = self.fact_return() retval.start = self.input.LT(1) root_0 = None LBRACKET29 = None RBRACKET31 = None atom27 = None modal_op28 = None atom30 = None LBRACKET29_tree = None RBRACKET31_tree = None stream_LBRACKET = RewriteRuleTokenStream(self._adaptor, "token LBRACKET") stream_RBRACKET = RewriteRuleTokenStream(self._adaptor, "token RBRACKET") stream_modal_op = RewriteRuleSubtreeStream(self._adaptor, "rule modal_op") stream_atom = RewriteRuleSubtreeStream(self._adaptor, "rule atom") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:116:5: ( atom | modal_op LBRACKET atom RBRACKET -> ^( MODAL modal_op atom ) ) alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == ID) : alt9 = 1 elif ((56 <= LA9_0 <= 58)) : alt9 = 2 else: nvae = NoViableAltException("", 9, 0, self.input) raise nvae if alt9 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:116:7: atom pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_atom_in_fact590) atom27 = self.atom() self._state.following.pop() self._adaptor.addChild(root_0, atom27.tree) elif alt9 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:117:7: modal_op LBRACKET atom RBRACKET pass self._state.following.append(self.FOLLOW_modal_op_in_fact598) modal_op28 = self.modal_op() self._state.following.pop() stream_modal_op.add(modal_op28.tree) LBRACKET29 = self.match(self.input, LBRACKET, self.FOLLOW_LBRACKET_in_fact600) stream_LBRACKET.add(LBRACKET29) self._state.following.append(self.FOLLOW_atom_in_fact602) atom30 = self.atom() self._state.following.pop() stream_atom.add(atom30.tree) RBRACKET31 = self.match(self.input, RBRACKET, self.FOLLOW_RBRACKET_in_fact604) stream_RBRACKET.add(RBRACKET31) # AST Rewrite # elements: modal_op, atom # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 117:39: -> ^( MODAL modal_op atom ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:117:42: ^( MODAL modal_op atom ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(MODAL, "MODAL") , root_1) self._adaptor.addChild(root_1, stream_modal_op.nextTree()) self._adaptor.addChild(root_1, stream_atom.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "fact" class modal_op_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.modal_op_return, self).__init__() self.tree = None # $ANTLR start "modal_op" # /Users/tim/opencode/congress/congress/datalog/Congress.g:120:1: modal_op : ( 'execute' | 'insert' | 'delete' ); def modal_op(self, ): retval = self.modal_op_return() retval.start = self.input.LT(1) root_0 = None set32 = None set32_tree = None try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:121:5: ( 'execute' | 'insert' | 'delete' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass root_0 = self._adaptor.nil() set32 = self.input.LT(1) if (56 <= self.input.LA(1) <= 58): self.input.consume() self._adaptor.addChild(root_0, self._adaptor.createWithPayload(set32)) self._state.errorRecovery = False else: mse = MismatchedSetException(None, self.input) raise mse retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "modal_op" class atom_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.atom_return, self).__init__() self.tree = None # $ANTLR start "atom" # /Users/tim/opencode/congress/congress/datalog/Congress.g:126:1: atom : relation_constant ( LPAREN ( parameter_list )? RPAREN )? -> ^( ATOM relation_constant ( parameter_list )? ) ; def atom(self, ): retval = self.atom_return() retval.start = self.input.LT(1) root_0 = None LPAREN34 = None RPAREN36 = None relation_constant33 = None parameter_list35 = None LPAREN34_tree = None RPAREN36_tree = None stream_LPAREN = RewriteRuleTokenStream(self._adaptor, "token LPAREN") stream_RPAREN = RewriteRuleTokenStream(self._adaptor, "token RPAREN") stream_relation_constant = RewriteRuleSubtreeStream(self._adaptor, "rule relation_constant") stream_parameter_list = RewriteRuleSubtreeStream(self._adaptor, "rule parameter_list") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:127:5: ( relation_constant ( LPAREN ( parameter_list )? RPAREN )? -> ^( ATOM relation_constant ( parameter_list )? ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:127:7: relation_constant ( LPAREN ( parameter_list )? RPAREN )? pass self._state.following.append(self.FOLLOW_relation_constant_in_atom664) relation_constant33 = self.relation_constant() self._state.following.pop() stream_relation_constant.add(relation_constant33.tree) # /Users/tim/opencode/congress/congress/datalog/Congress.g:127:25: ( LPAREN ( parameter_list )? RPAREN )? alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == LPAREN) : alt11 = 1 if alt11 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:127:26: LPAREN ( parameter_list )? RPAREN pass LPAREN34 = self.match(self.input, LPAREN, self.FOLLOW_LPAREN_in_atom667) stream_LPAREN.add(LPAREN34) # /Users/tim/opencode/congress/congress/datalog/Congress.g:127:33: ( parameter_list )? alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == FLOAT or (ID <= LA10_0 <= INT) or LA10_0 == STRING) : alt10 = 1 if alt10 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:127:33: parameter_list pass self._state.following.append(self.FOLLOW_parameter_list_in_atom669) parameter_list35 = self.parameter_list() self._state.following.pop() stream_parameter_list.add(parameter_list35.tree) RPAREN36 = self.match(self.input, RPAREN, self.FOLLOW_RPAREN_in_atom672) stream_RPAREN.add(RPAREN36) # AST Rewrite # elements: parameter_list, relation_constant # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 127:58: -> ^( ATOM relation_constant ( parameter_list )? ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:127:61: ^( ATOM relation_constant ( parameter_list )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(ATOM, "ATOM") , root_1) self._adaptor.addChild(root_1, stream_relation_constant.nextTree()) # /Users/tim/opencode/congress/congress/datalog/Congress.g:127:86: ( parameter_list )? if stream_parameter_list.hasNext(): self._adaptor.addChild(root_1, stream_parameter_list.nextTree()) stream_parameter_list.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "atom" class parameter_list_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.parameter_list_return, self).__init__() self.tree = None # $ANTLR start "parameter_list" # /Users/tim/opencode/congress/congress/datalog/Congress.g:130:1: parameter_list : parameter ( COMMA parameter )* -> ( parameter )+ ; def parameter_list(self, ): retval = self.parameter_list_return() retval.start = self.input.LT(1) root_0 = None COMMA38 = None parameter37 = None parameter39 = None COMMA38_tree = None stream_COMMA = RewriteRuleTokenStream(self._adaptor, "token COMMA") stream_parameter = RewriteRuleSubtreeStream(self._adaptor, "rule parameter") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:131:5: ( parameter ( COMMA parameter )* -> ( parameter )+ ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:131:7: parameter ( COMMA parameter )* pass self._state.following.append(self.FOLLOW_parameter_in_parameter_list702) parameter37 = self.parameter() self._state.following.pop() stream_parameter.add(parameter37.tree) # /Users/tim/opencode/congress/congress/datalog/Congress.g:131:17: ( COMMA parameter )* while True: #loop12 alt12 = 2 LA12_0 = self.input.LA(1) if (LA12_0 == COMMA) : alt12 = 1 if alt12 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:131:18: COMMA parameter pass COMMA38 = self.match(self.input, COMMA, self.FOLLOW_COMMA_in_parameter_list705) stream_COMMA.add(COMMA38) self._state.following.append(self.FOLLOW_parameter_in_parameter_list707) parameter39 = self.parameter() self._state.following.pop() stream_parameter.add(parameter39.tree) else: break #loop12 # AST Rewrite # elements: parameter # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 131:36: -> ( parameter )+ # /Users/tim/opencode/congress/congress/datalog/Congress.g:131:39: ( parameter )+ if not (stream_parameter.hasNext()): raise RewriteEarlyExitException() while stream_parameter.hasNext(): self._adaptor.addChild(root_0, stream_parameter.nextTree()) stream_parameter.reset() retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "parameter_list" class parameter_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.parameter_return, self).__init__() self.tree = None # $ANTLR start "parameter" # /Users/tim/opencode/congress/congress/datalog/Congress.g:134:1: parameter : ( term -> term | column_ref EQUAL term -> ^( NAMED_PARAM column_ref term ) ); def parameter(self, ): retval = self.parameter_return() retval.start = self.input.LT(1) root_0 = None EQUAL42 = None term40 = None column_ref41 = None term43 = None EQUAL42_tree = None stream_EQUAL = RewriteRuleTokenStream(self._adaptor, "token EQUAL") stream_term = RewriteRuleSubtreeStream(self._adaptor, "rule term") stream_column_ref = RewriteRuleSubtreeStream(self._adaptor, "rule column_ref") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:135:5: ( term -> term | column_ref EQUAL term -> ^( NAMED_PARAM column_ref term ) ) alt13 = 2 LA13 = self.input.LA(1) if LA13 == INT: LA13_1 = self.input.LA(2) if (LA13_1 == COMMA or LA13_1 == RPAREN) : alt13 = 1 elif (LA13_1 == EQUAL) : alt13 = 2 else: nvae = NoViableAltException("", 13, 1, self.input) raise nvae elif LA13 == FLOAT or LA13 == STRING: alt13 = 1 elif LA13 == ID: LA13_3 = self.input.LA(2) if (LA13_3 == COMMA or LA13_3 == RPAREN) : alt13 = 1 elif (LA13_3 == EQUAL) : alt13 = 2 else: nvae = NoViableAltException("", 13, 3, self.input) raise nvae else: nvae = NoViableAltException("", 13, 0, self.input) raise nvae if alt13 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:135:7: term pass self._state.following.append(self.FOLLOW_term_in_parameter731) term40 = self.term() self._state.following.pop() stream_term.add(term40.tree) # AST Rewrite # elements: term # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 135:12: -> term self._adaptor.addChild(root_0, stream_term.nextTree()) retval.tree = root_0 elif alt13 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:136:7: column_ref EQUAL term pass self._state.following.append(self.FOLLOW_column_ref_in_parameter743) column_ref41 = self.column_ref() self._state.following.pop() stream_column_ref.add(column_ref41.tree) EQUAL42 = self.match(self.input, EQUAL, self.FOLLOW_EQUAL_in_parameter745) stream_EQUAL.add(EQUAL42) self._state.following.append(self.FOLLOW_term_in_parameter747) term43 = self.term() self._state.following.pop() stream_term.add(term43.tree) # AST Rewrite # elements: column_ref, term # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 136:29: -> ^( NAMED_PARAM column_ref term ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:136:32: ^( NAMED_PARAM column_ref term ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(NAMED_PARAM, "NAMED_PARAM") , root_1) self._adaptor.addChild(root_1, stream_column_ref.nextTree()) self._adaptor.addChild(root_1, stream_term.nextTree()) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "parameter" class column_ref_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.column_ref_return, self).__init__() self.tree = None # $ANTLR start "column_ref" # /Users/tim/opencode/congress/congress/datalog/Congress.g:139:1: column_ref : ( ID -> ^( COLUMN_NAME ID ) | INT -> ^( COLUMN_NUMBER INT ) ); def column_ref(self, ): retval = self.column_ref_return() retval.start = self.input.LT(1) root_0 = None ID44 = None INT45 = None ID44_tree = None INT45_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_INT = RewriteRuleTokenStream(self._adaptor, "token INT") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:140:5: ( ID -> ^( COLUMN_NAME ID ) | INT -> ^( COLUMN_NUMBER INT ) ) alt14 = 2 LA14_0 = self.input.LA(1) if (LA14_0 == ID) : alt14 = 1 elif (LA14_0 == INT) : alt14 = 2 else: nvae = NoViableAltException("", 14, 0, self.input) raise nvae if alt14 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:140:7: ID pass ID44 = self.match(self.input, ID, self.FOLLOW_ID_in_column_ref774) stream_ID.add(ID44) # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 140:12: -> ^( COLUMN_NAME ID ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:140:16: ^( COLUMN_NAME ID ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(COLUMN_NAME, "COLUMN_NAME") , root_1) self._adaptor.addChild(root_1, stream_ID.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt14 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:141:7: INT pass INT45 = self.match(self.input, INT, self.FOLLOW_INT_in_column_ref793) stream_INT.add(INT45) # AST Rewrite # elements: INT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 141:12: -> ^( COLUMN_NUMBER INT ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:141:16: ^( COLUMN_NUMBER INT ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(COLUMN_NUMBER, "COLUMN_NUMBER") , root_1) self._adaptor.addChild(root_1, stream_INT.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "column_ref" class term_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.term_return, self).__init__() self.tree = None # $ANTLR start "term" # /Users/tim/opencode/congress/congress/datalog/Congress.g:144:1: term : ( object_constant | variable ); def term(self, ): retval = self.term_return() retval.start = self.input.LT(1) root_0 = None object_constant46 = None variable47 = None try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:145:5: ( object_constant | variable ) alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == FLOAT or LA15_0 == INT or LA15_0 == STRING) : alt15 = 1 elif (LA15_0 == ID) : alt15 = 2 else: nvae = NoViableAltException("", 15, 0, self.input) raise nvae if alt15 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:145:7: object_constant pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_object_constant_in_term820) object_constant46 = self.object_constant() self._state.following.pop() self._adaptor.addChild(root_0, object_constant46.tree) elif alt15 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:146:7: variable pass root_0 = self._adaptor.nil() self._state.following.append(self.FOLLOW_variable_in_term828) variable47 = self.variable() self._state.following.pop() self._adaptor.addChild(root_0, variable47.tree) retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "term" class object_constant_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.object_constant_return, self).__init__() self.tree = None # $ANTLR start "object_constant" # /Users/tim/opencode/congress/congress/datalog/Congress.g:149:1: object_constant : ( INT -> ^( INTEGER_OBJ INT ) | FLOAT -> ^( FLOAT_OBJ FLOAT ) | STRING -> ^( STRING_OBJ STRING ) ); def object_constant(self, ): retval = self.object_constant_return() retval.start = self.input.LT(1) root_0 = None INT48 = None FLOAT49 = None STRING50 = None INT48_tree = None FLOAT49_tree = None STRING50_tree = None stream_FLOAT = RewriteRuleTokenStream(self._adaptor, "token FLOAT") stream_STRING = RewriteRuleTokenStream(self._adaptor, "token STRING") stream_INT = RewriteRuleTokenStream(self._adaptor, "token INT") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:150:5: ( INT -> ^( INTEGER_OBJ INT ) | FLOAT -> ^( FLOAT_OBJ FLOAT ) | STRING -> ^( STRING_OBJ STRING ) ) alt16 = 3 LA16 = self.input.LA(1) if LA16 == INT: alt16 = 1 elif LA16 == FLOAT: alt16 = 2 elif LA16 == STRING: alt16 = 3 else: nvae = NoViableAltException("", 16, 0, self.input) raise nvae if alt16 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:150:7: INT pass INT48 = self.match(self.input, INT, self.FOLLOW_INT_in_object_constant845) stream_INT.add(INT48) # AST Rewrite # elements: INT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 150:16: -> ^( INTEGER_OBJ INT ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:150:19: ^( INTEGER_OBJ INT ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(INTEGER_OBJ, "INTEGER_OBJ") , root_1) self._adaptor.addChild(root_1, stream_INT.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt16 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:151:7: FLOAT pass FLOAT49 = self.match(self.input, FLOAT, self.FOLLOW_FLOAT_in_object_constant866) stream_FLOAT.add(FLOAT49) # AST Rewrite # elements: FLOAT # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 151:16: -> ^( FLOAT_OBJ FLOAT ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:151:19: ^( FLOAT_OBJ FLOAT ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(FLOAT_OBJ, "FLOAT_OBJ") , root_1) self._adaptor.addChild(root_1, stream_FLOAT.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 elif alt16 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:152:7: STRING pass STRING50 = self.match(self.input, STRING, self.FOLLOW_STRING_in_object_constant885) stream_STRING.add(STRING50) # AST Rewrite # elements: STRING # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 152:16: -> ^( STRING_OBJ STRING ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:152:19: ^( STRING_OBJ STRING ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(STRING_OBJ, "STRING_OBJ") , root_1) self._adaptor.addChild(root_1, stream_STRING.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "object_constant" class variable_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.variable_return, self).__init__() self.tree = None # $ANTLR start "variable" # /Users/tim/opencode/congress/congress/datalog/Congress.g:155:1: variable : ID -> ^( VARIABLE ID ) ; def variable(self, ): retval = self.variable_return() retval.start = self.input.LT(1) root_0 = None ID51 = None ID51_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:156:5: ( ID -> ^( VARIABLE ID ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:156:7: ID pass ID51 = self.match(self.input, ID, self.FOLLOW_ID_in_variable912) stream_ID.add(ID51) # AST Rewrite # elements: ID # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 156:10: -> ^( VARIABLE ID ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:156:13: ^( VARIABLE ID ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(VARIABLE, "VARIABLE") , root_1) self._adaptor.addChild(root_1, stream_ID.nextNode() ) self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "variable" class relation_constant_return(ParserRuleReturnScope): def __init__(self): super(CongressParser.relation_constant_return, self).__init__() self.tree = None # $ANTLR start "relation_constant" # /Users/tim/opencode/congress/congress/datalog/Congress.g:159:1: relation_constant : ID ( ':' ID )* ( SIGN )? -> ^( STRUCTURED_NAME ( ID )+ ( SIGN )? ) ; def relation_constant(self, ): retval = self.relation_constant_return() retval.start = self.input.LT(1) root_0 = None ID52 = None char_literal53 = None ID54 = None SIGN55 = None ID52_tree = None char_literal53_tree = None ID54_tree = None SIGN55_tree = None stream_ID = RewriteRuleTokenStream(self._adaptor, "token ID") stream_SIGN = RewriteRuleTokenStream(self._adaptor, "token SIGN") stream_54 = RewriteRuleTokenStream(self._adaptor, "token 54") try: try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:5: ( ID ( ':' ID )* ( SIGN )? -> ^( STRUCTURED_NAME ( ID )+ ( SIGN )? ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:7: ID ( ':' ID )* ( SIGN )? pass ID52 = self.match(self.input, ID, self.FOLLOW_ID_in_relation_constant937) stream_ID.add(ID52) # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:10: ( ':' ID )* while True: #loop17 alt17 = 2 LA17_0 = self.input.LA(1) if (LA17_0 == 54) : alt17 = 1 if alt17 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:11: ':' ID pass char_literal53 = self.match(self.input, 54, self.FOLLOW_54_in_relation_constant940) stream_54.add(char_literal53) ID54 = self.match(self.input, ID, self.FOLLOW_ID_in_relation_constant942) stream_ID.add(ID54) else: break #loop17 # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:20: ( SIGN )? alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == SIGN) : alt18 = 1 if alt18 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:20: SIGN pass SIGN55 = self.match(self.input, SIGN, self.FOLLOW_SIGN_in_relation_constant946) stream_SIGN.add(SIGN55) # AST Rewrite # elements: ID, SIGN # token labels: # rule labels: retval # token list labels: # rule list labels: # wildcard labels: retval.tree = root_0 if retval is not None: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "rule retval", retval.tree) else: stream_retval = RewriteRuleSubtreeStream(self._adaptor, "token retval", None) root_0 = self._adaptor.nil() # 160:26: -> ^( STRUCTURED_NAME ( ID )+ ( SIGN )? ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:29: ^( STRUCTURED_NAME ( ID )+ ( SIGN )? ) root_1 = self._adaptor.nil() root_1 = self._adaptor.becomeRoot( self._adaptor.createFromType(STRUCTURED_NAME, "STRUCTURED_NAME") , root_1) # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:47: ( ID )+ if not (stream_ID.hasNext()): raise RewriteEarlyExitException() while stream_ID.hasNext(): self._adaptor.addChild(root_1, stream_ID.nextNode() ) stream_ID.reset() # /Users/tim/opencode/congress/congress/datalog/Congress.g:160:51: ( SIGN )? if stream_SIGN.hasNext(): self._adaptor.addChild(root_1, stream_SIGN.nextNode() ) stream_SIGN.reset(); self._adaptor.addChild(root_0, root_1) retval.tree = root_0 retval.stop = self.input.LT(-1) retval.tree = self._adaptor.rulePostProcessing(root_0) self._adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop) except RecognitionException, re: self.reportError(re) self.recover(self.input, re) retval.tree = self._adaptor.errorNode(self.input, retval.start, self.input.LT(-1), re) finally: pass return retval # $ANTLR end "relation_constant" # lookup tables for DFA #5 DFA5_eot = DFA.unpack( u"\124\uffff" ) DFA5_eof = DFA.unpack( u"\1\uffff\1\10\4\uffff\1\10\4\uffff\1\10\4\uffff\1\10\10\uffff\1" u"\10\72\uffff" ) DFA5_min = DFA.unpack( u"\1\32\1\13\1\36\1\uffff\1\36\1\32\1\13\1\24\1\uffff\2\32\1\13\4" u"\16\2\13\1\uffff\1\40\2\24\1\32\1\13\1\24\1\13\1\32\1\40\1\24\10" u"\16\1\13\4\16\1\13\1\40\4\16\1\46\5\24\24\16\2\24\10\16" ) DFA5_max = DFA.unpack( u"\2\72\1\36\1\uffff\1\36\1\32\1\72\1\54\1\uffff\1\72\1\32\1\72\4" u"\47\1\72\1\66\1\uffff\1\66\2\54\1\32\1\46\1\54\1\72\1\32\1\46\1" u"\54\10\47\1\66\4\47\1\46\1\66\4\47\1\46\5\54\24\47\2\54\10\47" ) DFA5_accept = DFA.unpack( u"\3\uffff\1\1\4\uffff\1\2\11\uffff\1\3\101\uffff" ) DFA5_special = DFA.unpack( u"\124\uffff" ) DFA5_transition = [ DFA.unpack(u"\1\1\10\uffff\1\3\24\uffff\1\2\1\4\1\2"), DFA.unpack(u"\1\3\2\uffff\1\3\1\10\12\uffff\1\10\5\uffff\1\7\2\uffff" u"\1\10\5\uffff\1\6\13\uffff\1\10\1\5\4\10"), DFA.unpack(u"\1\11"), DFA.unpack(u""), DFA.unpack(u"\1\12"), DFA.unpack(u"\1\13"), DFA.unpack(u"\1\3\2\uffff\1\3\1\10\12\uffff\1\10\5\uffff\1\7\2\uffff" u"\1\10\21\uffff\1\10\1\uffff\4\10"), DFA.unpack(u"\1\15\5\uffff\1\17\1\14\13\uffff\1\20\4\uffff\1\16"), DFA.unpack(u""), DFA.unpack(u"\1\21\10\uffff\1\22\24\uffff\3\22"), DFA.unpack(u"\1\23"), DFA.unpack(u"\1\3\2\uffff\1\3\1\10\12\uffff\1\10\5\uffff\1\7\2\uffff" u"\1\10\5\uffff\1\6\13\uffff\1\10\1\5\4\10"), DFA.unpack(u"\1\24\2\uffff\1\25\25\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\2\uffff\1\25\25\uffff\1\20"), DFA.unpack(u"\1\3\2\uffff\1\3\1\10\12\uffff\1\10\10\uffff\1\10\21" u"\uffff\1\10\1\uffff\4\10"), DFA.unpack(u"\1\22\2\uffff\1\22\21\uffff\1\30\5\uffff\1\31\2\uffff" u"\1\27\14\uffff\1\26"), DFA.unpack(u""), DFA.unpack(u"\1\34\5\uffff\1\31\2\uffff\1\33\14\uffff\1\32"), DFA.unpack(u"\1\36\5\uffff\1\40\1\35\20\uffff\1\37"), DFA.unpack(u"\1\42\5\uffff\1\44\1\41\20\uffff\1\43"), DFA.unpack(u"\1\45"), DFA.unpack(u"\1\22\2\uffff\1\22\21\uffff\1\30\5\uffff\1\31"), DFA.unpack(u"\1\47\5\uffff\1\51\1\46\13\uffff\1\52\4\uffff\1\50"), DFA.unpack(u"\1\3\2\uffff\1\3\1\10\12\uffff\1\10\10\uffff\1\10\21" u"\uffff\1\10\1\uffff\4\10"), DFA.unpack(u"\1\53"), DFA.unpack(u"\1\34\5\uffff\1\31"), DFA.unpack(u"\1\55\5\uffff\1\57\1\54\13\uffff\1\60\4\uffff\1\56"), DFA.unpack(u"\1\24\2\uffff\1\61\25\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\2\uffff\1\61\25\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\22\2\uffff\1\22\21\uffff\1\30\5\uffff\1\31\2\uffff" u"\1\27\14\uffff\1\26"), DFA.unpack(u"\1\62\2\uffff\1\63\25\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\2\uffff\1\63\25\uffff\1\52"), DFA.unpack(u"\1\22\2\uffff\1\22\27\uffff\1\31"), DFA.unpack(u"\1\34\5\uffff\1\31\2\uffff\1\33\14\uffff\1\32"), DFA.unpack(u"\1\64\2\uffff\1\65\25\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\2\uffff\1\65\25\uffff\1\60"), DFA.unpack(u"\1\31"), DFA.unpack(u"\1\67\5\uffff\1\71\1\66\20\uffff\1\70"), DFA.unpack(u"\1\73\5\uffff\1\75\1\72\20\uffff\1\74"), DFA.unpack(u"\1\77\5\uffff\1\101\1\76\20\uffff\1\100"), DFA.unpack(u"\1\103\5\uffff\1\105\1\102\20\uffff\1\104"), DFA.unpack(u"\1\107\5\uffff\1\111\1\106\20\uffff\1\110"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\24\30\uffff\1\20"), DFA.unpack(u"\1\62\2\uffff\1\112\25\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\2\uffff\1\112\25\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\64\2\uffff\1\113\25\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\2\uffff\1\113\25\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\115\5\uffff\1\117\1\114\20\uffff\1\116"), DFA.unpack(u"\1\121\5\uffff\1\123\1\120\20\uffff\1\122"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\62\30\uffff\1\52"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60"), DFA.unpack(u"\1\64\30\uffff\1\60") ] # class definition for DFA #5 class DFA5(DFA): pass FOLLOW_statement_in_prog265 = frozenset([15, 26, 35, 56, 57, 58]) FOLLOW_EOF_in_prog268 = frozenset([1]) FOLLOW_EOF_in_prog285 = frozenset([1]) FOLLOW_formula_in_statement304 = frozenset([1, 53, 55]) FOLLOW_formula_terminator_in_statement306 = frozenset([1]) FOLLOW_COMMENT_in_statement319 = frozenset([1]) FOLLOW_rule_in_formula336 = frozenset([1]) FOLLOW_fact_in_formula344 = frozenset([1]) FOLLOW_event_in_formula352 = frozenset([1]) FOLLOW_event_op_in_event379 = frozenset([30]) FOLLOW_LBRACKET_in_event381 = frozenset([26, 35, 56, 57, 58]) FOLLOW_rule_in_event383 = frozenset([38, 53, 55]) FOLLOW_formula_terminator_in_event386 = frozenset([44]) FOLLOW_STRING_in_event388 = frozenset([38]) FOLLOW_RBRACKET_in_event392 = frozenset([1]) FOLLOW_literal_list_in_rule472 = frozenset([11]) FOLLOW_COLONMINUS_in_rule474 = frozenset([26, 35, 56, 57, 58]) FOLLOW_literal_list_in_rule476 = frozenset([1]) FOLLOW_literal_in_literal_list503 = frozenset([1, 14]) FOLLOW_COMMA_in_literal_list506 = frozenset([26, 35, 56, 57, 58]) FOLLOW_literal_in_literal_list508 = frozenset([1, 14]) FOLLOW_fact_in_literal536 = frozenset([1]) FOLLOW_NEGATION_in_literal559 = frozenset([26, 56, 57, 58]) FOLLOW_fact_in_literal561 = frozenset([1]) FOLLOW_atom_in_fact590 = frozenset([1]) FOLLOW_modal_op_in_fact598 = frozenset([30]) FOLLOW_LBRACKET_in_fact600 = frozenset([26]) FOLLOW_atom_in_fact602 = frozenset([38]) FOLLOW_RBRACKET_in_fact604 = frozenset([1]) FOLLOW_relation_constant_in_atom664 = frozenset([1, 32]) FOLLOW_LPAREN_in_atom667 = frozenset([20, 26, 27, 39, 44]) FOLLOW_parameter_list_in_atom669 = frozenset([39]) FOLLOW_RPAREN_in_atom672 = frozenset([1]) FOLLOW_parameter_in_parameter_list702 = frozenset([1, 14]) FOLLOW_COMMA_in_parameter_list705 = frozenset([20, 26, 27, 44]) FOLLOW_parameter_in_parameter_list707 = frozenset([1, 14]) FOLLOW_term_in_parameter731 = frozenset([1]) FOLLOW_column_ref_in_parameter743 = frozenset([17]) FOLLOW_EQUAL_in_parameter745 = frozenset([20, 26, 27, 44]) FOLLOW_term_in_parameter747 = frozenset([1]) FOLLOW_ID_in_column_ref774 = frozenset([1]) FOLLOW_INT_in_column_ref793 = frozenset([1]) FOLLOW_object_constant_in_term820 = frozenset([1]) FOLLOW_variable_in_term828 = frozenset([1]) FOLLOW_INT_in_object_constant845 = frozenset([1]) FOLLOW_FLOAT_in_object_constant866 = frozenset([1]) FOLLOW_STRING_in_object_constant885 = frozenset([1]) FOLLOW_ID_in_variable912 = frozenset([1]) FOLLOW_ID_in_relation_constant937 = frozenset([1, 41, 54]) FOLLOW_54_in_relation_constant940 = frozenset([26]) FOLLOW_ID_in_relation_constant942 = frozenset([1, 41, 54]) FOLLOW_SIGN_in_relation_constant946 = frozenset([1]) def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import ParserMain main = ParserMain("CongressLexer", CongressParser) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ekcs/congress", "path": "congress/datalog/CongressParser.py", "copies": "3", "size": "87659", "license": "apache-2.0", "hash": -3476326878491219000, "line_mean": 31.3464944649, "line_max": 193, "alpha_frac": 0.5207223445, "autogenerated": false, "ratio": 3.699784746549614, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5720507091049614, "avg_score": null, "num_lines": null }
# $ANTLR 3.5 /Users/tim/opencode/congress/congress/datalog/Congress.g 2015-08-03 09:06:22 import sys from antlr3 import * from antlr3.compat import set, frozenset # for convenience in actions HIDDEN = BaseRecognizer.HIDDEN # token types EOF=-1 T__53=53 T__54=54 T__55=55 T__56=56 T__57=57 T__58=58 AND=4 ATOM=5 BYTESTRPREFIX=6 BYTES_CHAR_DQ=7 BYTES_CHAR_SQ=8 BYTES_ESC=9 BYTES_TESC=10 COLONMINUS=11 COLUMN_NAME=12 COLUMN_NUMBER=13 COMMA=14 COMMENT=15 DIGIT=16 EQUAL=17 EVENT=18 EXPONENT=19 FLOAT=20 FLOAT_EXP=21 FLOAT_NO_EXP=22 FLOAT_OBJ=23 FRAC_PART=24 HEX_DIGIT=25 ID=26 INT=27 INTEGER_OBJ=28 INT_PART=29 LBRACKET=30 LITERAL=31 LPAREN=32 MODAL=33 NAMED_PARAM=34 NEGATION=35 NOT=36 PROG=37 RBRACKET=38 RPAREN=39 RULE=40 SIGN=41 SLBYTESTRING=42 SLSTRING=43 STRING=44 STRING_ESC=45 STRING_OBJ=46 STRPREFIX=47 STRUCTURED_NAME=48 SYMBOL_OBJ=49 THEORY=50 VARIABLE=51 WS=52 class CongressLexer(Lexer): grammarFileName = "/Users/tim/opencode/congress/congress/datalog/Congress.g" api_version = 1 def __init__(self, input=None, state=None): if state is None: state = RecognizerSharedState() super(CongressLexer, self).__init__(input, state) self.delegates = [] self.dfa8 = self.DFA8( self, 8, eot = self.DFA8_eot, eof = self.DFA8_eof, min = self.DFA8_min, max = self.DFA8_max, accept = self.DFA8_accept, special = self.DFA8_special, transition = self.DFA8_transition ) self.dfa23 = self.DFA23( self, 23, eot = self.DFA23_eot, eof = self.DFA23_eof, min = self.DFA23_min, max = self.DFA23_max, accept = self.DFA23_accept, special = self.DFA23_special, transition = self.DFA23_transition ) self.dfa24 = self.DFA24( self, 24, eot = self.DFA24_eot, eof = self.DFA24_eof, min = self.DFA24_min, max = self.DFA24_max, accept = self.DFA24_accept, special = self.DFA24_special, transition = self.DFA24_transition ) self.dfa38 = self.DFA38( self, 38, eot = self.DFA38_eot, eof = self.DFA38_eof, min = self.DFA38_min, max = self.DFA38_max, accept = self.DFA38_accept, special = self.DFA38_special, transition = self.DFA38_transition ) # $ANTLR start "COLONMINUS" def mCOLONMINUS(self, ): try: _type = COLONMINUS _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:7:12: ( ':-' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:7:14: ':-' pass self.match(":-") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COLONMINUS" # $ANTLR start "COMMA" def mCOMMA(self, ): try: _type = COMMA _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:8:7: ( ',' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:8:9: ',' pass self.match(44) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMA" # $ANTLR start "LBRACKET" def mLBRACKET(self, ): try: _type = LBRACKET _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:9:10: ( '[' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:9:12: '[' pass self.match(91) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LBRACKET" # $ANTLR start "LPAREN" def mLPAREN(self, ): try: _type = LPAREN _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:10:8: ( '(' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:10:10: '(' pass self.match(40) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "LPAREN" # $ANTLR start "RBRACKET" def mRBRACKET(self, ): try: _type = RBRACKET _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:11:10: ( ']' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:11:12: ']' pass self.match(93) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RBRACKET" # $ANTLR start "RPAREN" def mRPAREN(self, ): try: _type = RPAREN _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:12:8: ( ')' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:12:10: ')' pass self.match(41) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "RPAREN" # $ANTLR start "T__53" def mT__53(self, ): try: _type = T__53 _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:13:7: ( '.' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:13:9: '.' pass self.match(46) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__53" # $ANTLR start "T__54" def mT__54(self, ): try: _type = T__54 _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:14:7: ( ':' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:14:9: ':' pass self.match(58) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__54" # $ANTLR start "T__55" def mT__55(self, ): try: _type = T__55 _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:15:7: ( ';' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:15:9: ';' pass self.match(59) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__55" # $ANTLR start "T__56" def mT__56(self, ): try: _type = T__56 _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:16:7: ( 'delete' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:16:9: 'delete' pass self.match("delete") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__56" # $ANTLR start "T__57" def mT__57(self, ): try: _type = T__57 _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:17:7: ( 'execute' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:17:9: 'execute' pass self.match("execute") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__57" # $ANTLR start "T__58" def mT__58(self, ): try: _type = T__58 _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:18:7: ( 'insert' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:18:9: 'insert' pass self.match("insert") self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "T__58" # $ANTLR start "NEGATION" def mNEGATION(self, ): try: _type = NEGATION _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:167:5: ( 'not' | 'NOT' | '!' ) alt1 = 3 LA1 = self.input.LA(1) if LA1 == 110: alt1 = 1 elif LA1 == 78: alt1 = 2 elif LA1 == 33: alt1 = 3 else: nvae = NoViableAltException("", 1, 0, self.input) raise nvae if alt1 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:167:7: 'not' pass self.match("not") elif alt1 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:168:7: 'NOT' pass self.match("NOT") elif alt1 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:169:7: '!' pass self.match(33) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "NEGATION" # $ANTLR start "EQUAL" def mEQUAL(self, ): try: _type = EQUAL _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:173:5: ( '=' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:173:8: '=' pass self.match(61) self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "EQUAL" # $ANTLR start "SIGN" def mSIGN(self, ): try: _type = SIGN _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:177:5: ( '+' | '-' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if self.input.LA(1) == 43 or self.input.LA(1) == 45: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "SIGN" # $ANTLR start "INT" def mINT(self, ): try: _type = INT _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:184:5: ( '1' .. '9' ( '0' .. '9' )* | ( '0' )+ | '0' ( 'o' | 'O' ) ( '0' .. '7' )+ | '0' ( 'x' | 'X' ) ( HEX_DIGIT )+ | '0' ( 'b' | 'B' ) ( '0' | '1' )+ ) alt7 = 5 LA7_0 = self.input.LA(1) if ((49 <= LA7_0 <= 57)) : alt7 = 1 elif (LA7_0 == 48) : LA7 = self.input.LA(2) if LA7 == 79 or LA7 == 111: alt7 = 3 elif LA7 == 88 or LA7 == 120: alt7 = 4 elif LA7 == 66 or LA7 == 98: alt7 = 5 else: alt7 = 2 else: nvae = NoViableAltException("", 7, 0, self.input) raise nvae if alt7 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:184:7: '1' .. '9' ( '0' .. '9' )* pass self.matchRange(49, 57) # /Users/tim/opencode/congress/congress/datalog/Congress.g:184:16: ( '0' .. '9' )* while True: #loop2 alt2 = 2 LA2_0 = self.input.LA(1) if ((48 <= LA2_0 <= 57)) : alt2 = 1 if alt2 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop2 elif alt7 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:185:7: ( '0' )+ pass # /Users/tim/opencode/congress/congress/datalog/Congress.g:185:7: ( '0' )+ cnt3 = 0 while True: #loop3 alt3 = 2 LA3_0 = self.input.LA(1) if (LA3_0 == 48) : alt3 = 1 if alt3 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:185:7: '0' pass self.match(48) else: if cnt3 >= 1: break #loop3 eee = EarlyExitException(3, self.input) raise eee cnt3 += 1 elif alt7 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:186:7: '0' ( 'o' | 'O' ) ( '0' .. '7' )+ pass self.match(48) if self.input.LA(1) == 79 or self.input.LA(1) == 111: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/tim/opencode/congress/congress/datalog/Congress.g:186:23: ( '0' .. '7' )+ cnt4 = 0 while True: #loop4 alt4 = 2 LA4_0 = self.input.LA(1) if ((48 <= LA4_0 <= 55)) : alt4 = 1 if alt4 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 55): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt4 >= 1: break #loop4 eee = EarlyExitException(4, self.input) raise eee cnt4 += 1 elif alt7 == 4: # /Users/tim/opencode/congress/congress/datalog/Congress.g:187:7: '0' ( 'x' | 'X' ) ( HEX_DIGIT )+ pass self.match(48) if self.input.LA(1) == 88 or self.input.LA(1) == 120: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/tim/opencode/congress/congress/datalog/Congress.g:187:23: ( HEX_DIGIT )+ cnt5 = 0 while True: #loop5 alt5 = 2 LA5_0 = self.input.LA(1) if ((48 <= LA5_0 <= 57) or (65 <= LA5_0 <= 70) or (97 <= LA5_0 <= 102)) : alt5 = 1 if alt5 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt5 >= 1: break #loop5 eee = EarlyExitException(5, self.input) raise eee cnt5 += 1 elif alt7 == 5: # /Users/tim/opencode/congress/congress/datalog/Congress.g:188:7: '0' ( 'b' | 'B' ) ( '0' | '1' )+ pass self.match(48) if self.input.LA(1) == 66 or self.input.LA(1) == 98: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/tim/opencode/congress/congress/datalog/Congress.g:188:23: ( '0' | '1' )+ cnt6 = 0 while True: #loop6 alt6 = 2 LA6_0 = self.input.LA(1) if ((48 <= LA6_0 <= 49)) : alt6 = 1 if alt6 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 49): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt6 >= 1: break #loop6 eee = EarlyExitException(6, self.input) raise eee cnt6 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "INT" # $ANTLR start "FLOAT" def mFLOAT(self, ): try: _type = FLOAT _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:194:5: ( FLOAT_NO_EXP | FLOAT_EXP ) alt8 = 2 alt8 = self.dfa8.predict(self.input) if alt8 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:194:7: FLOAT_NO_EXP pass self.mFLOAT_NO_EXP() elif alt8 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:195:7: FLOAT_EXP pass self.mFLOAT_EXP() self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "FLOAT" # $ANTLR start "STRING" def mSTRING(self, ): try: _type = STRING _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:218:5: ( ( STRPREFIX )? ( SLSTRING )+ | ( BYTESTRPREFIX ) ( SLBYTESTRING )+ ) alt12 = 2 LA12 = self.input.LA(1) if LA12 == 114: LA12_1 = self.input.LA(2) if (LA12_1 == 66 or LA12_1 == 98) : alt12 = 2 elif (LA12_1 == 34 or LA12_1 == 39) : alt12 = 1 else: nvae = NoViableAltException("", 12, 1, self.input) raise nvae elif LA12 == 34 or LA12 == 39 or LA12 == 85 or LA12 == 117: alt12 = 1 elif LA12 == 66 or LA12 == 98: alt12 = 2 elif LA12 == 82: LA12_4 = self.input.LA(2) if (LA12_4 == 66 or LA12_4 == 98) : alt12 = 2 elif (LA12_4 == 34 or LA12_4 == 39) : alt12 = 1 else: nvae = NoViableAltException("", 12, 4, self.input) raise nvae else: nvae = NoViableAltException("", 12, 0, self.input) raise nvae if alt12 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:218:7: ( STRPREFIX )? ( SLSTRING )+ pass # /Users/tim/opencode/congress/congress/datalog/Congress.g:218:7: ( STRPREFIX )? alt9 = 2 LA9_0 = self.input.LA(1) if (LA9_0 == 82 or LA9_0 == 85 or LA9_0 == 114 or LA9_0 == 117) : alt9 = 1 if alt9 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if self.input.LA(1) == 82 or self.input.LA(1) == 85 or self.input.LA(1) == 114 or self.input.LA(1) == 117: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/tim/opencode/congress/congress/datalog/Congress.g:218:20: ( SLSTRING )+ cnt10 = 0 while True: #loop10 alt10 = 2 LA10_0 = self.input.LA(1) if (LA10_0 == 34 or LA10_0 == 39) : alt10 = 1 if alt10 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:218:21: SLSTRING pass self.mSLSTRING() else: if cnt10 >= 1: break #loop10 eee = EarlyExitException(10, self.input) raise eee cnt10 += 1 elif alt12 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:219:7: ( BYTESTRPREFIX ) ( SLBYTESTRING )+ pass # /Users/tim/opencode/congress/congress/datalog/Congress.g:219:7: ( BYTESTRPREFIX ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:219:8: BYTESTRPREFIX pass self.mBYTESTRPREFIX() # /Users/tim/opencode/congress/congress/datalog/Congress.g:219:23: ( SLBYTESTRING )+ cnt11 = 0 while True: #loop11 alt11 = 2 LA11_0 = self.input.LA(1) if (LA11_0 == 34 or LA11_0 == 39) : alt11 = 1 if alt11 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:219:24: SLBYTESTRING pass self.mSLBYTESTRING() else: if cnt11 >= 1: break #loop11 eee = EarlyExitException(11, self.input) raise eee cnt11 += 1 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "STRING" # $ANTLR start "ID" def mID(self, ): try: _type = ID _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:225:5: ( ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '.' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' | '.' )* ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:225:7: ( 'a' .. 'z' | 'A' .. 'Z' | '_' | '.' ) ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' | '.' )* pass if self.input.LA(1) == 46 or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/tim/opencode/congress/congress/datalog/Congress.g:225:35: ( 'a' .. 'z' | 'A' .. 'Z' | '0' .. '9' | '_' | '.' )* while True: #loop13 alt13 = 2 LA13_0 = self.input.LA(1) if (LA13_0 == 46 or (48 <= LA13_0 <= 57) or (65 <= LA13_0 <= 90) or LA13_0 == 95 or (97 <= LA13_0 <= 122)) : alt13 = 1 if alt13 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if self.input.LA(1) == 46 or (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 90) or self.input.LA(1) == 95 or (97 <= self.input.LA(1) <= 122): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop13 self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "ID" # $ANTLR start "COMMENT" def mCOMMENT(self, ): try: _type = COMMENT _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:230:5: ( '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' | '/*' ( options {greedy=false; } : . )* '*/' | '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' ) alt19 = 3 LA19_0 = self.input.LA(1) if (LA19_0 == 47) : LA19_1 = self.input.LA(2) if (LA19_1 == 47) : alt19 = 1 elif (LA19_1 == 42) : alt19 = 2 else: nvae = NoViableAltException("", 19, 1, self.input) raise nvae elif (LA19_0 == 35) : alt19 = 3 else: nvae = NoViableAltException("", 19, 0, self.input) raise nvae if alt19 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:230:7: '//' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' pass self.match("//") # /Users/tim/opencode/congress/congress/datalog/Congress.g:230:12: (~ ( '\\n' | '\\r' ) )* while True: #loop14 alt14 = 2 LA14_0 = self.input.LA(1) if ((0 <= LA14_0 <= 9) or (11 <= LA14_0 <= 12) or (14 <= LA14_0 <= 65535)) : alt14 = 1 if alt14 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop14 # /Users/tim/opencode/congress/congress/datalog/Congress.g:230:26: ( '\\r' )? alt15 = 2 LA15_0 = self.input.LA(1) if (LA15_0 == 13) : alt15 = 1 if alt15 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:230:26: '\\r' pass self.match(13) self.match(10) #action start _channel=HIDDEN; #action end elif alt19 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:231:7: '/*' ( options {greedy=false; } : . )* '*/' pass self.match("/*") # /Users/tim/opencode/congress/congress/datalog/Congress.g:231:12: ( options {greedy=false; } : . )* while True: #loop16 alt16 = 2 LA16_0 = self.input.LA(1) if (LA16_0 == 42) : LA16_1 = self.input.LA(2) if (LA16_1 == 47) : alt16 = 2 elif ((0 <= LA16_1 <= 46) or (48 <= LA16_1 <= 65535)) : alt16 = 1 elif ((0 <= LA16_0 <= 41) or (43 <= LA16_0 <= 65535)) : alt16 = 1 if alt16 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:231:40: . pass self.matchAny() else: break #loop16 self.match("*/") #action start _channel=HIDDEN; #action end elif alt19 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:232:7: '#' (~ ( '\\n' | '\\r' ) )* ( '\\r' )? '\\n' pass self.match(35) # /Users/tim/opencode/congress/congress/datalog/Congress.g:232:11: (~ ( '\\n' | '\\r' ) )* while True: #loop17 alt17 = 2 LA17_0 = self.input.LA(1) if ((0 <= LA17_0 <= 9) or (11 <= LA17_0 <= 12) or (14 <= LA17_0 <= 65535)) : alt17 = 1 if alt17 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop17 # /Users/tim/opencode/congress/congress/datalog/Congress.g:232:25: ( '\\r' )? alt18 = 2 LA18_0 = self.input.LA(1) if (LA18_0 == 13) : alt18 = 1 if alt18 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:232:25: '\\r' pass self.match(13) self.match(10) #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "COMMENT" # $ANTLR start "WS" def mWS(self, ): try: _type = WS _channel = DEFAULT_CHANNEL # /Users/tim/opencode/congress/congress/datalog/Congress.g:236:5: ( ( ' ' | '\\t' | '\\r' | '\\n' ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:236:7: ( ' ' | '\\t' | '\\r' | '\\n' ) pass if (9 <= self.input.LA(1) <= 10) or self.input.LA(1) == 13 or self.input.LA(1) == 32: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse #action start _channel=HIDDEN; #action end self._state.type = _type self._state.channel = _channel finally: pass # $ANTLR end "WS" # $ANTLR start "EXPONENT" def mEXPONENT(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:250:5: ( ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:250:7: ( 'e' | 'E' ) ( '+' | '-' )? ( '0' .. '9' )+ pass if self.input.LA(1) == 69 or self.input.LA(1) == 101: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/tim/opencode/congress/congress/datalog/Congress.g:250:17: ( '+' | '-' )? alt20 = 2 LA20_0 = self.input.LA(1) if (LA20_0 == 43 or LA20_0 == 45) : alt20 = 1 if alt20 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if self.input.LA(1) == 43 or self.input.LA(1) == 45: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse # /Users/tim/opencode/congress/congress/datalog/Congress.g:250:28: ( '0' .. '9' )+ cnt21 = 0 while True: #loop21 alt21 = 2 LA21_0 = self.input.LA(1) if ((48 <= LA21_0 <= 57)) : alt21 = 1 if alt21 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt21 >= 1: break #loop21 eee = EarlyExitException(21, self.input) raise eee cnt21 += 1 finally: pass # $ANTLR end "EXPONENT" # $ANTLR start "HEX_DIGIT" def mHEX_DIGIT(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:255:5: ( ( '0' .. '9' | 'a' .. 'f' | 'A' .. 'F' ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 57) or (65 <= self.input.LA(1) <= 70) or (97 <= self.input.LA(1) <= 102): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "HEX_DIGIT" # $ANTLR start "DIGIT" def mDIGIT(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:260:5: ( ( '0' .. '9' ) ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "DIGIT" # $ANTLR start "FLOAT_NO_EXP" def mFLOAT_NO_EXP(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:265:5: ( ( INT_PART )? FRAC_PART | INT_PART '.' ) alt23 = 2 alt23 = self.dfa23.predict(self.input) if alt23 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:265:7: ( INT_PART )? FRAC_PART pass # /Users/tim/opencode/congress/congress/datalog/Congress.g:265:7: ( INT_PART )? alt22 = 2 LA22_0 = self.input.LA(1) if ((48 <= LA22_0 <= 57)) : alt22 = 1 if alt22 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:265:7: INT_PART pass self.mINT_PART() self.mFRAC_PART() elif alt23 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:266:7: INT_PART '.' pass self.mINT_PART() self.match(46) finally: pass # $ANTLR end "FLOAT_NO_EXP" # $ANTLR start "FLOAT_EXP" def mFLOAT_EXP(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:271:5: ( ( INT_PART | FLOAT_NO_EXP ) EXPONENT ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:271:7: ( INT_PART | FLOAT_NO_EXP ) EXPONENT pass # /Users/tim/opencode/congress/congress/datalog/Congress.g:271:7: ( INT_PART | FLOAT_NO_EXP ) alt24 = 2 alt24 = self.dfa24.predict(self.input) if alt24 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:271:9: INT_PART pass self.mINT_PART() elif alt24 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:271:20: FLOAT_NO_EXP pass self.mFLOAT_NO_EXP() self.mEXPONENT() finally: pass # $ANTLR end "FLOAT_EXP" # $ANTLR start "INT_PART" def mINT_PART(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:276:5: ( ( DIGIT )+ ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:276:7: ( DIGIT )+ pass # /Users/tim/opencode/congress/congress/datalog/Congress.g:276:7: ( DIGIT )+ cnt25 = 0 while True: #loop25 alt25 = 2 LA25_0 = self.input.LA(1) if ((48 <= LA25_0 <= 57)) : alt25 = 1 if alt25 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt25 >= 1: break #loop25 eee = EarlyExitException(25, self.input) raise eee cnt25 += 1 finally: pass # $ANTLR end "INT_PART" # $ANTLR start "FRAC_PART" def mFRAC_PART(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:281:5: ( '.' ( DIGIT )+ ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:281:7: '.' ( DIGIT )+ pass self.match(46) # /Users/tim/opencode/congress/congress/datalog/Congress.g:281:11: ( DIGIT )+ cnt26 = 0 while True: #loop26 alt26 = 2 LA26_0 = self.input.LA(1) if ((48 <= LA26_0 <= 57)) : alt26 = 1 if alt26 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (48 <= self.input.LA(1) <= 57): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: if cnt26 >= 1: break #loop26 eee = EarlyExitException(26, self.input) raise eee cnt26 += 1 finally: pass # $ANTLR end "FRAC_PART" # $ANTLR start "STRPREFIX" def mSTRPREFIX(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:289:5: ( 'r' | 'R' | 'u' | 'U' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if self.input.LA(1) == 82 or self.input.LA(1) == 85 or self.input.LA(1) == 114 or self.input.LA(1) == 117: self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "STRPREFIX" # $ANTLR start "STRING_ESC" def mSTRING_ESC(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:294:5: ( '\\\\' . ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:294:7: '\\\\' . pass self.match(92) self.matchAny() finally: pass # $ANTLR end "STRING_ESC" # $ANTLR start "SLSTRING" def mSLSTRING(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:301:5: ( '\\'' ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\\'' ) )* '\\'' | '\"' ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\"' ) )* '\"' | '\\'\\'\\'' ( STRING_ESC |~ ( '\\\\' ) )* '\\'\\'\\'' | '\"\"\"' ( STRING_ESC |~ ( '\\\\' ) )* '\"\"\"' ) alt31 = 4 LA31_0 = self.input.LA(1) if (LA31_0 == 39) : LA31_1 = self.input.LA(2) if (LA31_1 == 39) : LA31_3 = self.input.LA(3) if (LA31_3 == 39) : alt31 = 3 else: alt31 = 1 elif ((0 <= LA31_1 <= 9) or (11 <= LA31_1 <= 12) or (14 <= LA31_1 <= 38) or (40 <= LA31_1 <= 65535)) : alt31 = 1 else: nvae = NoViableAltException("", 31, 1, self.input) raise nvae elif (LA31_0 == 34) : LA31_2 = self.input.LA(2) if (LA31_2 == 34) : LA31_5 = self.input.LA(3) if (LA31_5 == 34) : alt31 = 4 else: alt31 = 2 elif ((0 <= LA31_2 <= 9) or (11 <= LA31_2 <= 12) or (14 <= LA31_2 <= 33) or (35 <= LA31_2 <= 65535)) : alt31 = 2 else: nvae = NoViableAltException("", 31, 2, self.input) raise nvae else: nvae = NoViableAltException("", 31, 0, self.input) raise nvae if alt31 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:301:7: '\\'' ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\\'' ) )* '\\'' pass self.match(39) # /Users/tim/opencode/congress/congress/datalog/Congress.g:301:12: ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\\'' ) )* while True: #loop27 alt27 = 3 LA27_0 = self.input.LA(1) if (LA27_0 == 92) : alt27 = 1 elif ((0 <= LA27_0 <= 9) or (11 <= LA27_0 <= 12) or (14 <= LA27_0 <= 38) or (40 <= LA27_0 <= 91) or (93 <= LA27_0 <= 65535)) : alt27 = 2 if alt27 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:301:13: STRING_ESC pass self.mSTRING_ESC() elif alt27 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:301:26: ~ ( '\\\\' | '\\r' | '\\n' | '\\'' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop27 self.match(39) elif alt31 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:302:7: '\"' ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\"' ) )* '\"' pass self.match(34) # /Users/tim/opencode/congress/congress/datalog/Congress.g:302:11: ( STRING_ESC |~ ( '\\\\' | '\\r' | '\\n' | '\"' ) )* while True: #loop28 alt28 = 3 LA28_0 = self.input.LA(1) if (LA28_0 == 92) : alt28 = 1 elif ((0 <= LA28_0 <= 9) or (11 <= LA28_0 <= 12) or (14 <= LA28_0 <= 33) or (35 <= LA28_0 <= 91) or (93 <= LA28_0 <= 65535)) : alt28 = 2 if alt28 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:302:12: STRING_ESC pass self.mSTRING_ESC() elif alt28 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:302:25: ~ ( '\\\\' | '\\r' | '\\n' | '\"' ) pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop28 self.match(34) elif alt31 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:303:7: '\\'\\'\\'' ( STRING_ESC |~ ( '\\\\' ) )* '\\'\\'\\'' pass self.match("'''") # /Users/tim/opencode/congress/congress/datalog/Congress.g:303:16: ( STRING_ESC |~ ( '\\\\' ) )* while True: #loop29 alt29 = 3 LA29_0 = self.input.LA(1) if (LA29_0 == 39) : LA29_1 = self.input.LA(2) if (LA29_1 == 39) : LA29_4 = self.input.LA(3) if (LA29_4 == 39) : LA29_5 = self.input.LA(4) if ((0 <= LA29_5 <= 65535)) : alt29 = 2 elif ((0 <= LA29_4 <= 38) or (40 <= LA29_4 <= 65535)) : alt29 = 2 elif ((0 <= LA29_1 <= 38) or (40 <= LA29_1 <= 65535)) : alt29 = 2 elif (LA29_0 == 92) : alt29 = 1 elif ((0 <= LA29_0 <= 38) or (40 <= LA29_0 <= 91) or (93 <= LA29_0 <= 65535)) : alt29 = 2 if alt29 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:303:17: STRING_ESC pass self.mSTRING_ESC() elif alt29 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:303:30: ~ ( '\\\\' ) pass if (0 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop29 self.match("'''") elif alt31 == 4: # /Users/tim/opencode/congress/congress/datalog/Congress.g:304:7: '\"\"\"' ( STRING_ESC |~ ( '\\\\' ) )* '\"\"\"' pass self.match("\"\"\"") # /Users/tim/opencode/congress/congress/datalog/Congress.g:304:13: ( STRING_ESC |~ ( '\\\\' ) )* while True: #loop30 alt30 = 3 LA30_0 = self.input.LA(1) if (LA30_0 == 34) : LA30_1 = self.input.LA(2) if (LA30_1 == 34) : LA30_4 = self.input.LA(3) if (LA30_4 == 34) : LA30_5 = self.input.LA(4) if ((0 <= LA30_5 <= 65535)) : alt30 = 2 elif ((0 <= LA30_4 <= 33) or (35 <= LA30_4 <= 65535)) : alt30 = 2 elif ((0 <= LA30_1 <= 33) or (35 <= LA30_1 <= 65535)) : alt30 = 2 elif (LA30_0 == 92) : alt30 = 1 elif ((0 <= LA30_0 <= 33) or (35 <= LA30_0 <= 91) or (93 <= LA30_0 <= 65535)) : alt30 = 2 if alt30 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:304:14: STRING_ESC pass self.mSTRING_ESC() elif alt30 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:304:27: ~ ( '\\\\' ) pass if (0 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 65535): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop30 self.match("\"\"\"") finally: pass # $ANTLR end "SLSTRING" # $ANTLR start "BYTESTRPREFIX" def mBYTESTRPREFIX(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:5: ( 'b' | 'B' | 'br' | 'Br' | 'bR' | 'BR' | 'rb' | 'rB' | 'Rb' | 'RB' ) alt32 = 10 LA32 = self.input.LA(1) if LA32 == 98: LA32 = self.input.LA(2) if LA32 == 114: alt32 = 3 elif LA32 == 82: alt32 = 5 else: alt32 = 1 elif LA32 == 66: LA32 = self.input.LA(2) if LA32 == 114: alt32 = 4 elif LA32 == 82: alt32 = 6 else: alt32 = 2 elif LA32 == 114: LA32_3 = self.input.LA(2) if (LA32_3 == 98) : alt32 = 7 elif (LA32_3 == 66) : alt32 = 8 else: nvae = NoViableAltException("", 32, 3, self.input) raise nvae elif LA32 == 82: LA32_4 = self.input.LA(2) if (LA32_4 == 98) : alt32 = 9 elif (LA32_4 == 66) : alt32 = 10 else: nvae = NoViableAltException("", 32, 4, self.input) raise nvae else: nvae = NoViableAltException("", 32, 0, self.input) raise nvae if alt32 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:7: 'b' pass self.match(98) elif alt32 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:13: 'B' pass self.match(66) elif alt32 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:19: 'br' pass self.match("br") elif alt32 == 4: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:26: 'Br' pass self.match("Br") elif alt32 == 5: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:33: 'bR' pass self.match("bR") elif alt32 == 6: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:40: 'BR' pass self.match("BR") elif alt32 == 7: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:47: 'rb' pass self.match("rb") elif alt32 == 8: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:54: 'rB' pass self.match("rB") elif alt32 == 9: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:61: 'Rb' pass self.match("Rb") elif alt32 == 10: # /Users/tim/opencode/congress/congress/datalog/Congress.g:315:68: 'RB' pass self.match("RB") finally: pass # $ANTLR end "BYTESTRPREFIX" # $ANTLR start "SLBYTESTRING" def mSLBYTESTRING(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:320:5: ( '\\'' ( BYTES_CHAR_SQ | BYTES_ESC )* '\\'' | '\"' ( BYTES_CHAR_DQ | BYTES_ESC )* '\"' | '\\'\\'\\'' ( BYTES_CHAR_SQ | BYTES_TESC )* '\\'\\'\\'' | '\"\"\"' ( BYTES_CHAR_DQ | BYTES_TESC )* '\"\"\"' ) alt37 = 4 LA37_0 = self.input.LA(1) if (LA37_0 == 39) : LA37_1 = self.input.LA(2) if (LA37_1 == 39) : LA37_3 = self.input.LA(3) if (LA37_3 == 39) : alt37 = 3 else: alt37 = 1 elif ((0 <= LA37_1 <= 9) or (11 <= LA37_1 <= 12) or (14 <= LA37_1 <= 38) or (40 <= LA37_1 <= 127)) : alt37 = 1 else: nvae = NoViableAltException("", 37, 1, self.input) raise nvae elif (LA37_0 == 34) : LA37_2 = self.input.LA(2) if (LA37_2 == 34) : LA37_5 = self.input.LA(3) if (LA37_5 == 34) : alt37 = 4 else: alt37 = 2 elif ((0 <= LA37_2 <= 9) or (11 <= LA37_2 <= 12) or (14 <= LA37_2 <= 33) or (35 <= LA37_2 <= 127)) : alt37 = 2 else: nvae = NoViableAltException("", 37, 2, self.input) raise nvae else: nvae = NoViableAltException("", 37, 0, self.input) raise nvae if alt37 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:320:7: '\\'' ( BYTES_CHAR_SQ | BYTES_ESC )* '\\'' pass self.match(39) # /Users/tim/opencode/congress/congress/datalog/Congress.g:320:12: ( BYTES_CHAR_SQ | BYTES_ESC )* while True: #loop33 alt33 = 3 LA33_0 = self.input.LA(1) if ((0 <= LA33_0 <= 9) or (11 <= LA33_0 <= 12) or (14 <= LA33_0 <= 38) or (40 <= LA33_0 <= 91) or (93 <= LA33_0 <= 127)) : alt33 = 1 elif (LA33_0 == 92) : alt33 = 2 if alt33 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:320:13: BYTES_CHAR_SQ pass self.mBYTES_CHAR_SQ() elif alt33 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:320:29: BYTES_ESC pass self.mBYTES_ESC() else: break #loop33 self.match(39) elif alt37 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:321:7: '\"' ( BYTES_CHAR_DQ | BYTES_ESC )* '\"' pass self.match(34) # /Users/tim/opencode/congress/congress/datalog/Congress.g:321:11: ( BYTES_CHAR_DQ | BYTES_ESC )* while True: #loop34 alt34 = 3 LA34_0 = self.input.LA(1) if ((0 <= LA34_0 <= 9) or (11 <= LA34_0 <= 12) or (14 <= LA34_0 <= 33) or (35 <= LA34_0 <= 91) or (93 <= LA34_0 <= 127)) : alt34 = 1 elif (LA34_0 == 92) : alt34 = 2 if alt34 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:321:12: BYTES_CHAR_DQ pass self.mBYTES_CHAR_DQ() elif alt34 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:321:28: BYTES_ESC pass self.mBYTES_ESC() else: break #loop34 self.match(34) elif alt37 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:322:7: '\\'\\'\\'' ( BYTES_CHAR_SQ | BYTES_TESC )* '\\'\\'\\'' pass self.match("'''") # /Users/tim/opencode/congress/congress/datalog/Congress.g:322:16: ( BYTES_CHAR_SQ | BYTES_TESC )* while True: #loop35 alt35 = 2 LA35_0 = self.input.LA(1) if (LA35_0 == 39) : LA35_1 = self.input.LA(2) if (LA35_1 == 39) : LA35_3 = self.input.LA(3) if (LA35_3 == 39) : LA35_4 = self.input.LA(4) if ((0 <= LA35_4 <= 91) or (93 <= LA35_4 <= 127)) : alt35 = 1 elif ((0 <= LA35_3 <= 38) or (40 <= LA35_3 <= 91) or (93 <= LA35_3 <= 127)) : alt35 = 1 elif ((0 <= LA35_1 <= 38) or (40 <= LA35_1 <= 91) or (93 <= LA35_1 <= 127)) : alt35 = 1 elif ((0 <= LA35_0 <= 38) or (40 <= LA35_0 <= 91) or (93 <= LA35_0 <= 127)) : alt35 = 1 if alt35 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (0 <= self.input.LA(1) <= 91) or (14 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop35 self.match("'''") elif alt37 == 4: # /Users/tim/opencode/congress/congress/datalog/Congress.g:323:7: '\"\"\"' ( BYTES_CHAR_DQ | BYTES_TESC )* '\"\"\"' pass self.match("\"\"\"") # /Users/tim/opencode/congress/congress/datalog/Congress.g:323:13: ( BYTES_CHAR_DQ | BYTES_TESC )* while True: #loop36 alt36 = 2 LA36_0 = self.input.LA(1) if (LA36_0 == 34) : LA36_1 = self.input.LA(2) if (LA36_1 == 34) : LA36_3 = self.input.LA(3) if (LA36_3 == 34) : LA36_4 = self.input.LA(4) if ((0 <= LA36_4 <= 91) or (93 <= LA36_4 <= 127)) : alt36 = 1 elif ((0 <= LA36_3 <= 33) or (35 <= LA36_3 <= 91) or (93 <= LA36_3 <= 127)) : alt36 = 1 elif ((0 <= LA36_1 <= 33) or (35 <= LA36_1 <= 91) or (93 <= LA36_1 <= 127)) : alt36 = 1 elif ((0 <= LA36_0 <= 33) or (35 <= LA36_0 <= 91) or (93 <= LA36_0 <= 127)) : alt36 = 1 if alt36 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (0 <= self.input.LA(1) <= 91) or (14 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse else: break #loop36 self.match("\"\"\"") finally: pass # $ANTLR end "SLBYTESTRING" # $ANTLR start "BYTES_CHAR_SQ" def mBYTES_CHAR_SQ(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:328:5: ( '\\u0000' .. '\\u0009' | '\\u000B' .. '\\u000C' | '\\u000E' .. '\\u0026' | '\\u0028' .. '\\u005B' | '\\u005D' .. '\\u007F' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 38) or (40 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "BYTES_CHAR_SQ" # $ANTLR start "BYTES_CHAR_DQ" def mBYTES_CHAR_DQ(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:337:5: ( '\\u0000' .. '\\u0009' | '\\u000B' .. '\\u000C' | '\\u000E' .. '\\u0021' | '\\u0023' .. '\\u005B' | '\\u005D' .. '\\u007F' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (0 <= self.input.LA(1) <= 9) or (11 <= self.input.LA(1) <= 12) or (14 <= self.input.LA(1) <= 33) or (35 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "BYTES_CHAR_DQ" # $ANTLR start "BYTES_ESC" def mBYTES_ESC(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:346:5: ( '\\\\' '\\u0000' .. '\\u007F' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g:346:7: '\\\\' '\\u0000' .. '\\u007F' pass self.match(92) self.matchRange(0, 127) finally: pass # $ANTLR end "BYTES_ESC" # $ANTLR start "BYTES_TESC" def mBYTES_TESC(self, ): try: # /Users/tim/opencode/congress/congress/datalog/Congress.g:352:5: ( '\\u0000' .. '\\u005B' | '\\u005D' .. '\\u007F' ) # /Users/tim/opencode/congress/congress/datalog/Congress.g: pass if (0 <= self.input.LA(1) <= 91) or (93 <= self.input.LA(1) <= 127): self.input.consume() else: mse = MismatchedSetException(None, self.input) self.recover(mse) raise mse finally: pass # $ANTLR end "BYTES_TESC" def mTokens(self): # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:8: ( COLONMINUS | COMMA | LBRACKET | LPAREN | RBRACKET | RPAREN | T__53 | T__54 | T__55 | T__56 | T__57 | T__58 | NEGATION | EQUAL | SIGN | INT | FLOAT | STRING | ID | COMMENT | WS ) alt38 = 21 alt38 = self.dfa38.predict(self.input) if alt38 == 1: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:10: COLONMINUS pass self.mCOLONMINUS() elif alt38 == 2: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:21: COMMA pass self.mCOMMA() elif alt38 == 3: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:27: LBRACKET pass self.mLBRACKET() elif alt38 == 4: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:36: LPAREN pass self.mLPAREN() elif alt38 == 5: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:43: RBRACKET pass self.mRBRACKET() elif alt38 == 6: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:52: RPAREN pass self.mRPAREN() elif alt38 == 7: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:59: T__53 pass self.mT__53() elif alt38 == 8: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:65: T__54 pass self.mT__54() elif alt38 == 9: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:71: T__55 pass self.mT__55() elif alt38 == 10: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:77: T__56 pass self.mT__56() elif alt38 == 11: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:83: T__57 pass self.mT__57() elif alt38 == 12: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:89: T__58 pass self.mT__58() elif alt38 == 13: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:95: NEGATION pass self.mNEGATION() elif alt38 == 14: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:104: EQUAL pass self.mEQUAL() elif alt38 == 15: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:110: SIGN pass self.mSIGN() elif alt38 == 16: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:115: INT pass self.mINT() elif alt38 == 17: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:119: FLOAT pass self.mFLOAT() elif alt38 == 18: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:125: STRING pass self.mSTRING() elif alt38 == 19: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:132: ID pass self.mID() elif alt38 == 20: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:135: COMMENT pass self.mCOMMENT() elif alt38 == 21: # /Users/tim/opencode/congress/congress/datalog/Congress.g:1:143: WS pass self.mWS() # lookup tables for DFA #8 DFA8_eot = DFA.unpack( u"\3\uffff\1\6\1\uffff\1\6\1\uffff" ) DFA8_eof = DFA.unpack( u"\7\uffff" ) DFA8_min = DFA.unpack( u"\2\56\2\60\1\uffff\1\60\1\uffff" ) DFA8_max = DFA.unpack( u"\1\71\1\145\1\71\1\145\1\uffff\1\145\1\uffff" ) DFA8_accept = DFA.unpack( u"\4\uffff\1\2\1\uffff\1\1" ) DFA8_special = DFA.unpack( u"\7\uffff" ) DFA8_transition = [ DFA.unpack(u"\1\2\1\uffff\12\1"), DFA.unpack(u"\1\3\1\uffff\12\1\13\uffff\1\4\37\uffff\1\4"), DFA.unpack(u"\12\5"), DFA.unpack(u"\12\5\13\uffff\1\4\37\uffff\1\4"), DFA.unpack(u""), DFA.unpack(u"\12\5\13\uffff\1\4\37\uffff\1\4"), DFA.unpack(u"") ] # class definition for DFA #8 class DFA8(DFA): pass # lookup tables for DFA #23 DFA23_eot = DFA.unpack( u"\3\uffff\1\4\1\uffff" ) DFA23_eof = DFA.unpack( u"\5\uffff" ) DFA23_min = DFA.unpack( u"\2\56\1\uffff\1\60\1\uffff" ) DFA23_max = DFA.unpack( u"\2\71\1\uffff\1\71\1\uffff" ) DFA23_accept = DFA.unpack( u"\2\uffff\1\1\1\uffff\1\2" ) DFA23_special = DFA.unpack( u"\5\uffff" ) DFA23_transition = [ DFA.unpack(u"\1\2\1\uffff\12\1"), DFA.unpack(u"\1\3\1\uffff\12\1"), DFA.unpack(u""), DFA.unpack(u"\12\2"), DFA.unpack(u"") ] # class definition for DFA #23 class DFA23(DFA): pass # lookup tables for DFA #24 DFA24_eot = DFA.unpack( u"\4\uffff" ) DFA24_eof = DFA.unpack( u"\4\uffff" ) DFA24_min = DFA.unpack( u"\2\56\2\uffff" ) DFA24_max = DFA.unpack( u"\1\71\1\145\2\uffff" ) DFA24_accept = DFA.unpack( u"\2\uffff\1\2\1\1" ) DFA24_special = DFA.unpack( u"\4\uffff" ) DFA24_transition = [ DFA.unpack(u"\1\2\1\uffff\12\1"), DFA.unpack(u"\1\2\1\uffff\12\1\13\uffff\1\3\37\uffff\1\3"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #24 class DFA24(DFA): pass # lookup tables for DFA #38 DFA38_eot = DFA.unpack( u"\1\uffff\1\35\5\uffff\1\36\1\uffff\5\31\3\uffff\2\46\1\31\1\uffff" u"\4\31\6\uffff\1\47\5\31\1\46\2\uffff\1\46\14\31\2\16\1\47\6\31" u"\1\101\1\31\1\103\1\uffff\1\104\2\uffff" ) DFA38_eof = DFA.unpack( u"\105\uffff" ) DFA38_min = DFA.unpack( u"\1\11\1\55\5\uffff\1\56\1\uffff\1\145\1\170\1\156\1\157\1\117\3" u"\uffff\2\56\1\42\1\uffff\4\42\6\uffff\1\56\1\154\1\145\1\163\1" u"\164\1\124\1\56\2\uffff\1\56\10\42\1\53\1\145\1\143\1\145\3\56" u"\1\164\1\165\1\162\1\145\2\164\1\56\1\145\1\56\1\uffff\1\56\2\uffff" ) DFA38_max = DFA.unpack( u"\1\172\1\55\5\uffff\1\172\1\uffff\1\145\1\170\1\156\1\157\1\117" u"\3\uffff\2\145\1\142\1\uffff\2\162\1\142\1\47\6\uffff\1\172\1\154" u"\1\145\1\163\1\164\1\124\1\145\2\uffff\1\145\10\47\1\71\1\145\1" u"\143\1\145\3\172\1\164\1\165\1\162\1\145\2\164\1\172\1\145\1\172" u"\1\uffff\1\172\2\uffff" ) DFA38_accept = DFA.unpack( u"\2\uffff\1\2\1\3\1\4\1\5\1\6\1\uffff\1\11\5\uffff\1\15\1\16\1\17" u"\3\uffff\1\22\4\uffff\1\23\1\24\1\25\1\1\1\10\1\7\7\uffff\1\20" u"\1\21\31\uffff\1\12\1\uffff\1\14\1\13" ) DFA38_special = DFA.unpack( u"\105\uffff" ) DFA38_transition = [ DFA.unpack(u"\2\33\2\uffff\1\33\22\uffff\1\33\1\16\1\24\1\32\3\uffff" u"\1\24\1\4\1\6\1\uffff\1\20\1\2\1\20\1\7\1\32\1\22\11\21\1\1\1\10" u"\1\uffff\1\17\3\uffff\1\31\1\26\13\31\1\15\3\31\1\27\2\31\1\30" u"\5\31\1\3\1\uffff\1\5\1\uffff\1\31\1\uffff\1\31\1\25\1\31\1\11" u"\1\12\3\31\1\13\4\31\1\14\3\31\1\23\2\31\1\30\5\31"), DFA.unpack(u"\1\34"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\31\1\uffff\12\37\7\uffff\32\31\4\uffff\1\31\1\uffff" u"\32\31"), DFA.unpack(u""), DFA.unpack(u"\1\40"), DFA.unpack(u"\1\41"), DFA.unpack(u"\1\42"), DFA.unpack(u"\1\43"), DFA.unpack(u"\1\44"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\47\1\uffff\12\45\13\uffff\1\47\37\uffff\1\47"), DFA.unpack(u"\1\47\1\uffff\1\50\11\47\13\uffff\1\47\37\uffff\1\47"), DFA.unpack(u"\1\24\4\uffff\1\24\32\uffff\1\52\37\uffff\1\51"), DFA.unpack(u""), DFA.unpack(u"\1\24\4\uffff\1\24\52\uffff\1\54\37\uffff\1\53"), DFA.unpack(u"\1\24\4\uffff\1\24\52\uffff\1\56\37\uffff\1\55"), DFA.unpack(u"\1\24\4\uffff\1\24\32\uffff\1\60\37\uffff\1\57"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\31\1\uffff\12\37\7\uffff\4\31\1\61\25\31\4\uffff" u"\1\31\1\uffff\4\31\1\61\25\31"), DFA.unpack(u"\1\62"), DFA.unpack(u"\1\63"), DFA.unpack(u"\1\64"), DFA.unpack(u"\1\65"), DFA.unpack(u"\1\66"), DFA.unpack(u"\1\47\1\uffff\12\45\13\uffff\1\47\37\uffff\1\47"), DFA.unpack(u""), DFA.unpack(u""), DFA.unpack(u"\1\47\1\uffff\1\50\11\47\13\uffff\1\47\37\uffff\1\47"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u"\1\24\4\uffff\1\24"), DFA.unpack(u"\1\47\1\uffff\1\47\2\uffff\12\67"), DFA.unpack(u"\1\70"), DFA.unpack(u"\1\71"), DFA.unpack(u"\1\72"), DFA.unpack(u"\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" u"\32\31"), DFA.unpack(u"\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" u"\32\31"), DFA.unpack(u"\1\31\1\uffff\12\67\7\uffff\32\31\4\uffff\1\31\1\uffff" u"\32\31"), DFA.unpack(u"\1\73"), DFA.unpack(u"\1\74"), DFA.unpack(u"\1\75"), DFA.unpack(u"\1\76"), DFA.unpack(u"\1\77"), DFA.unpack(u"\1\100"), DFA.unpack(u"\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" u"\32\31"), DFA.unpack(u"\1\102"), DFA.unpack(u"\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" u"\32\31"), DFA.unpack(u""), DFA.unpack(u"\1\31\1\uffff\12\31\7\uffff\32\31\4\uffff\1\31\1\uffff" u"\32\31"), DFA.unpack(u""), DFA.unpack(u"") ] # class definition for DFA #38 class DFA38(DFA): pass def main(argv, stdin=sys.stdin, stdout=sys.stdout, stderr=sys.stderr): from antlr3.main import LexerMain main = LexerMain(CongressLexer) main.stdin = stdin main.stdout = stdout main.stderr = stderr main.execute(argv) if __name__ == '__main__': main(sys.argv)
{ "repo_name": "ekcs/congress", "path": "congress/datalog/CongressLexer.py", "copies": "3", "size": "75903", "license": "apache-2.0", "hash": -1519084461670277600, "line_mean": 26.7626188734, "line_max": 318, "alpha_frac": 0.4280463223, "autogenerated": false, "ratio": 3.3918580748949863, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5319904397194986, "avg_score": null, "num_lines": null }
# $ apt-get install python-bs4 # $ easy_install beautifulsoup4 # $ pip install beautifulsoup4 # $ python setup.py install # https://www.crummy.com/software/BeautifulSoup/bs4/doc/ html_doc = """ <html><head><title>The Dormouse's story</title></head> <body> <p class="title"><b>The Dormouse's story</b></p> <p class="story">Once upon a time there were three little sisters; and their names were <a href="http://example.com/elsie" class="sister" id="link1">Elsie</a>, <a href="http://example.com/lacie" class="sister" id="link2">Lacie</a> and <a href="http://example.com/tillie" class="sister" id="link3">Tillie</a>; and they lived at the bottom of a well.</p> <p class="story">...</p> """ from bs4 import BeautifulSoup soup = BeautifulSoup(html_doc, 'html.parser') print(soup.prettify()) # <html> # <head> # <title> # The Dormouse's story # </title> # </head> # <body> # <p class="title"> # <b> # The Dormouse's story # </b> # </p> # <p class="story"> # Once upon a time there were three little sisters; and their names were # <a class="sister" href="http://example.com/elsie" id="link1"> # Elsie # </a> # , # <a class="sister" href="http://example.com/lacie" id="link2"> # Lacie # </a> # and # <a class="sister" href="http://example.com/tillie" id="link2"> # Tillie # </a> # ; and they lived at the bottom of a well. # </p> # <p class="story"> # ... # </p> # </body> # </html> soup.title # <title>The Dormouse's story</title> soup.title.name # u'title' soup.title.string # u'The Dormouse's story' soup.title.parent.name # u'head' soup.p # <p class="title"><b>The Dormouse's story</b></p> soup.p['class'] # u'title' soup.a # <a class="sister" href="http://example.com/elsie" id="link1">Elsie</a> soup.find_all('a') # [<a class="sister" href="http://example.com/elsie" id="link1">Elsie</a>, # <a class="sister" href="http://example.com/lacie" id="link2">Lacie</a>, # <a class="sister" href="http://example.com/tillie" id="link3">Tillie</a>] soup.find(id="link3") # <a class="sister" href="http://example.com/tillie" id="link3">Tillie</a> for link in soup.find_all('a'): print(link.get('href')) # http://example.com/elsie # http://example.com/lacie # http://example.com/tillie print(soup.get_text()) # The Dormouse's story # # The Dormouse's story # # Once upon a time there were three little sisters; and their names were # Elsie, # Lacie and # Tillie; # and they lived at the bottom of a well. # # ...
{ "repo_name": "gdsglgf/tutorials", "path": "python/beautifulsoup4/bs_guide.py", "copies": "1", "size": "2500", "license": "mit", "hash": 3836297942533356500, "line_mean": 22.819047619, "line_max": 87, "alpha_frac": 0.6344, "autogenerated": false, "ratio": 2.5536261491317673, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.36880261491317673, "avg_score": null, "num_lines": null }
#+ # NAME: # DISK # # PURPOSE: # This function returns a byte array containing a disk. The # disk is centered at x, y, and has radius r. The array is nx, # ny in size and has byte type. Pixel values of 1 indicate that # the center of a pixel is within r of x,y. Pixel values of 0 # indicate the opposite. The center of each pixel is the # integer position of that pixel. # # CATEGORY: # Array creation. # # CALLING SEQUENCE: # # diskarr = disk(R, X, Y, Nx, Ny) # or # diskarr = disk(R, Ctr, Sz) # which is the same as # diskarr = disk(R, [X, Y], [Nx, Ny]) # # INPUTS: # There are two ways to enter the inputs. If Nx is defined, then: # R: radius of the disk, may be fractional. # X: X position of the center of the disk, may be fractional. # Y: Y position of the center of the disk, may be fractional. # Nx: width of the output array. # Ny: height of the output array. # Otherwise: # R: Radius of the disk, may be fractional. # Ctr: Position of the center of the disk, 2-element vector. # Sz: Size of the output array, 2-element vector. # # KEYWORDS: # STATUS: (returned) Set to 1 if any part of the disk is # outside the image boundaries. # # OUTPUTS: # This function returns a byte array as described above. # # PROCEDURE: # Each pixel is evaluated to see whether it is within r of # (x,y). If so, the value is set to 1. Otherwise it is 0. # # SIDE EFFECTS: # STATUS is set in caller. # # EXAMPLE: # # tvscl, DISK(6.4, 9.9, 10.1, 30, 30) # tvscl, DISK(6.4, [9.9, 10.1], [30, 30], STATUS=STATUS) # print, STATUS # tvscl, DISK(6.4, [ 3, 10.1], [30, 30], STATUS=STATUS) # print, STATUS # tvscl, DISK(6.4, [27, 10.1], [30, 30], STATUS=STATUS) # print, STATUS # tvscl, DISK(6.4, [ 9.9, 3], [30, 30], STATUS=STATUS) # print, STATUS # tvscl, DISK(6.4, [ 9.9, 27], [30, 30], STATUS=STATUS) # print, STATUS # # MODIFICATION HISTORY: # Written by: Joseph Harrington, Cornell. 2003 April 4 # jh@oobleck.astro.cornell.edu # # 2004 Feb 27 jh added alternate input method # 2005 Nov 16 jh added STATUS, simplified disk calculation, # use double precision #- import numpy as np def disk(r, ctr, size, status=False): # return status retstatus = status # check if disk is off image status = 0 if (ctr[0] - r < 0 or ctr[0] + r > size[0]-1 or ctr[1] - r < 0 or ctr[1] + r > size[1]-1 ): status = 1 # calculate pixel distance from center # print('disk size:', size) ind = np.indices(size) fdisk = (ind[0]-ctr[0])**2.0 + (ind[1]-ctr[1])**2.0 # return mask disk (and status if requested) ret = fdisk <= r**2.0 if retstatus: ret = ret, status return ret
{ "repo_name": "zkbt/mosasaurus", "path": "mosasaurus/disk.py", "copies": "1", "size": "2671", "license": "mit", "hash": 2780961353420315000, "line_mean": 25.4455445545, "line_max": 66, "alpha_frac": 0.6458255335, "autogenerated": false, "ratio": 2.551098376313276, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.3696923909813276, "avg_score": null, "num_lines": null }
import os import sys import string import argparse import shlex import platform import traceback import subprocess import email import smtplib import itertools import logging import tempfile import locale from email.mime.text import MIMEText from datetime import datetime, date, time, timedelta locale.setlocale(locale.LC_ALL, '') # use system's locale logging.basicConfig(format='%(asctime)s - %(levelname)s - %(message)s',level=logging.DEBUG) class ProgError(Exception): pass class snapshot: def __init__(self, args): # Default snapshot arguments, if --argsfile is not used. # --CreateDir: Create destination directory if it does not exist. self.default_snapshot_args = ['--CreateDir', '--AutoBackupSize:512', '-L0', '-Gx' ] # Those arguments can not be used in the snapshot arguments file because they are used by this script. self.bad_snapshot_args = ['-W', '--LogFile', '-h' ] # Date format used in backup file names. Should not be changed. self.dateformat = '%Y%m%d-%H%M%S' self.args = args self.backup_file = None self.backup_commandline = None self.backup_nr = None self.backup_type = None self.machine = None self.drive = None self.failed = False self.exception = None self.logfilename = None self.logtext = None self.returncode = None self.deletetime_all = None self.deletetime_diff = None self.deleted_files = [] def split_args(self, s): lex = shlex.shlex(s, posix=True) lex.whitespace_split = True lex.escape = '' lex.commenters = '' return list(lex) def read_snapshot_args(self, argsfile): if not os.path.isfile(argsfile): raise(ProgError('The snapshot arguments file \'{0}\' was not found!'.format(argsfile))) with open(argsfile, 'r') as logfile: argstr = logfile.read() arglist = self.split_args(argstr) for arg in arglist: for bad_arg in self.bad_snapshot_args: if arg.lower().startswith(bad_arg.lower()): raise(ProgError('Argument "{0}" can not be used in snapshot arguments file "{1}", because this argument is used by this script itself!'.format(arg, argsfile))) return arglist def dismantle(self, file): name = os.path.splitext(file)[0] # remove extension parts = name.split('_') if len(parts) != 5: raise(ProgError('{0}: invalid backup file name. It must be composed of five_parts separated by \'_\'.'.format(file))) nr = parts[2] if not nr.startswith('b'): raise(ProgError('{0}: invalid backup number. It must start with \'b\' followed by a number.'.format(file))) nr = nr[1:] if not nr.isdigit(): raise(ProgError('{0}: invalid backup number. It must start with \'b\' followed by a number.'.format(file))) nr = int(nr) type = parts[4] if type != 'full' and type != 'diff': raise(ProgError('{0}: invalid type \'{1}\'.'.format(file, type))) ds = parts[3]; if len(ds) != 15: raise(ProgError('{0}: invalid date part \'{1}\'.'.format(file, parts[1]))) dd = datetime.strptime(ds, self.dateformat) return (file, nr, type, dd) def makemachinefilter(self, machine, drive): def findmachine(x) : return x.startswith(machine + '_' + drive + '_') return findmachine def findhsh(self, x) : return x.endswith('.hsh') def findsna(self, x) : return x.endswith('.sna') def get_existing_backups(self): # get all backup files which belong to this machine and drive filesall = filter(self.findsna, os.listdir(self.args.backupdir)) files = filter(self.makemachinefilter(self.machine, self.drive), filesall) # get parts of each file name struct = map(self.dismantle, files) if not struct: struct = [] return struct def delete_backupfiles(self, files): logging.debug(files) retval = [] for filename in files: base = os.path.splitext(filename)[0].lower() for f in sorted(os.listdir(self.args.backupdir)): f = f.lower() if not os.path.isfile(f): dpath = os.path.join(self.args.backupdir, f) [dbase, dext] = os.path.splitext(f) if base == dbase: # delete only *.hsh and *.sn* files if dext.startswith('.sn') or dext == '.hsh': logging.info('Deleting {0}'.format(dpath)) retval.append(dpath) if not self.args.simulate: os.remove(dpath) return retval def dobackup(self): self.machine = platform.node().lower() self.drive = self.args.drive.lower() if self.drive.endswith(':'): self.drive = self.drive[:-1] # check if snapshot command exists if not os.path.isfile(self.args.cmd): raise(ProgError('The snapshot executable \'{0}\' was not found!'.format(self.args.cmd))) if not os.access(self.args.cmd, os.X_OK): raise(ProgError('The snapshot executable \'{0}\' is not executable!'.format(self.args.cmd))) # check if backup dir is not a file and create it if os.path.isfile(self.args.backupdir): raise(ProgError('The backup directory \'{0}\' is not a directory !!!'.format(self.args.backupdir))) # read snapshot args file snapshot_args = self.default_snapshot_args if self.args.argsfile: snapshot_args = self.read_snapshot_args(self.args.argsfile) self.args.backupdir = os.path.abspath(self.args.backupdir) if not os.path.isdir(self.args.backupdir): os.makedirs(self.args.backupdir) struct = self.get_existing_backups() # Sort by backup number and date. The last one in the list is the most recent backup. struct = sorted(struct, key=lambda x: (x[1], x[3])) # filter out all full backups fullbackups = [ s for s in struct if s[2] == 'full' ] # determine last full backup lastfull = None if len(fullbackups) > 0: lastfull = fullbackups[-1] hshfile = os.path.join(self.args.backupdir, lastfull[0][:-4] + '.hsh') if not os.path.isfile(hshfile): raise(ProgError('Hash file of last full backup {0} does not exist!'.format(hshfile))) # determine number of differential backups since last full backup count_diffs = 0 if lastfull: diffbackups = [ s for s in struct if s[1] == lastfull[1] and s[2] == 'diff' ] count_diffs = len(diffbackups) # make this a differential backup if full backup exists and the number of differential # backups is below --diffcount self.backup_type = 'diff' if not lastfull: self.backup_type = 'full' self.backup_nr = 1 else: self.backup_nr = lastfull[1] if count_diffs >= self.args.diffcount: self.backup_type = 'full' self.backup_nr = self.backup_nr + 1 # create file name of backup date = datetime.now() self.backup_file = os.path.join(self.args.backupdir, '{0}_{1}_b{2}_{3}_{4}.sna'.format(self.machine, self.drive, self.backup_nr, date.strftime(self.dateformat), self.backup_type)) # create backup command line backup_cmd = [self.args.cmd, self.drive + ':', self.backup_file, '-W'] + snapshot_args # if diff backup add reference to hash file of full backup if self.backup_type == 'diff': logging.info('Performing differential backup based on hash file {0}.'.format(hshfile)) backup_cmd = backup_cmd + [ '-h' + hshfile ] # exclude files if self.args.exclude: # merge exclude arguments into a single list excludes = [el for elements in self.args.exclude for el in elements] exstr = string.join(map(lambda s: '"{0}"'.format(s) if '@' in s else s, excludes), ',') backup_cmd = backup_cmd + [ '--exclude:' + exstr ] # log to temp logfile with tempfile.NamedTemporaryFile(delete=False, suffix = ".log") as logfile: self.logfilename = logfile.name backup_cmd = backup_cmd + [ '--LogFile:' + self.logfilename ] self.backup_commandline = string.join(backup_cmd) logging.info("Executing: " + self.backup_commandline) # do it if (not self.args.simulate): self.returncode = subprocess.call(backup_cmd) else: self.returncode = 0 with open(self.logfilename, 'r') as logfile: self.logtext = logfile.read() if self.returncode != 0: raise(ProgError('Snapshot returned with errorcode {0}!'.format(self.returncode))) def docleanup(self): # clean up old backups struct = self.get_existing_backups() now = datetime.now() delfiles = set() # delete differential backups older then x days if not self.args.deletediff is None: self.deletetime_diff = now - timedelta(days = self.args.deletediff) logging.info('Deleting differential backups <= {0}'.format(self.deletetime_diff)) delfiles.update([ f for f in struct if f[2] == 'diff' and f[3] <= self.deletetime_diff ]) # delete all backups older then x days if not self.args.delete is None: self.deletetime_all = now - timedelta(days = self.args.delete) logging.info('Deleting all backups <= {0}'.format(self.deletetime_all)) delfiles.update([ f for f in struct if f[3] <= self.deletetime_all ]) # do not delete full backups which have diff backups that are kept. keep_id = set([ f[1] for f in struct if not f in delfiles ]) delfiles.difference_update([ f for f in delfiles if f[1] in keep_id and f[2] == 'full' ]) delfiles = [ f[0] for f in delfiles ] # actually delete the files self.deleted_files = self.delete_backupfiles(delfiles) def mail(self, body): # mail the stuff if self.args.mail_to: msg = MIMEText(body, 'text') msg['Subject'] = '{0}Snapshot of {1} drive {2} {3}'.format('SIMULATED ' if self.args.simulate else '', self.machine, self.args.drive, 'FAILED' if self.failed else 'SUCCESSFULL') msg['From'] = self.args.mail_from msg['To'] = self.args.mail_to msg['Date'] = email.utils.formatdate(localtime=True) msg.add_header('X-SnapshotBackup', 'Yes') # force base64 encoding msg._headers = [h for h in msg._headers if h[0] != 'Content-Transfer-Encoding'] email.encoders.encode_base64(msg) if (self.args.mail_ssl): server = smtplib.SMTP_SSL(self.args.mail_smtp) else: server = smtplib.SMTP(self.args.mail_smtp) if self.args.mail_debug: server.set_debuglevel(1) # log in, if credentials are given if self.args.mail_user != None or self.args.mail_password != None: server.login(self.args.mail_user, self.args.mail_password) try: server.sendmail(self.args.mail_from, self.args.mail_to, msg.as_string()) finally: server.quit() def execute(self): # We catch any exceptions during backup and cleanup and # add that to the mail. try: # execute snapshot backup self.dobackup() # perform cleanup self.docleanup() except (KeyboardInterrupt, SystemExit): raise except Exception, ex: logging.exception(ex.message) self.exception = traceback.format_exc() self.failed = True if self.logfilename: os.remove(self.logfilename) # gather information into readable form body = '' if self.args.simulate: body = body + 'Simulation: YES\n' if self.machine: body = body + 'Machine: {0}\n'.format(self.machine) if self.drive: body = body + 'Drive: {0}\n'.format(self.drive) if self.backup_type: body = body + 'Backup Type: {0}\n'.format(self.backup_type) if self.backup_nr: body = body + 'Backup Number: {0}\n'.format(self.backup_nr) if self.backup_file: body = body + 'Backup File: {0}\n'.format(self.backup_file) if self.backup_commandline: body = body + 'Backup Command: {0}\n'.format(self.backup_commandline) if not self.returncode is None: body = body + 'Return Value: {0}\n'.format(self.returncode) if self.exception: body = body + '\nException:\n{0}\n'.format(self.exception) if self.logtext: body = body + '\nOutput of snapshot:{0}\n'.format(self.logtext) if self.deletetime_all or self.deletetime_diff: body = body + '\nCLEANUP:\n' if self.deletetime_all: body = body + 'Deleted all backups <= {0}\n'.format(self.deletetime_all.strftime("%x %X")) if self.deletetime_diff: body = body + 'Deleted differental backups <= {0}\n'.format(self.deletetime_diff.strftime("%x %X")) body = body + 'Deleted files:\n' for f in self.deleted_files: body = body + ' {0}\n'.format(f) logging.info('\n' + body) self.mail(body) logging.info("Finished!") if __name__ == "__main__": parser = argparse.ArgumentParser(formatter_class=argparse.ArgumentDefaultsHelpFormatter) # paths parser.add_argument('backupdir', help='directory containing the backup files') parser.add_argument('drive', help='drive to back up. e.g. C:') # general options parser.add_argument('--cmd', default='snapshot.exe', help='Path for snapshot binary snapshot64.exe or snapshot.exe.') parser.add_argument('--diffcount', type=int, default=0, metavar='X', help='Create X differential backups after every full backup. 0 = only full backups.') parser.add_argument('--exclude', nargs='*', action='append', help='Excludes given file(s) or folder(s)') parser.add_argument('--argsfile', '-af', metavar='ARGS_FILE', help='Additional command line arguments for snapshot are read form this file. If not specified, the following arguments are used by default: --CreateDir --AutoBackupSize:512 -L0 -Gx -W.') parser.add_argument('--simulate', action='store_true', help='Does not call snapshot nor deletes any files. All messages are printed and mail is sent.') parser.add_argument('--delete', '-d', type=int, metavar='DAYS', help='Delete all backups which are older then DAYS days. Full backups are not deleted if there are any differential backups depending on them which are kept.') parser.add_argument('--deletediff', '-dd', type=int, metavar='DAYS', help='Delete differential backups which are older then DAYS days.') # mail options mailgroup = parser.add_argument_group('mail options') mailgroup.add_argument('--mail-to', help='Mail address for status mail.') mailgroup.add_argument('--mail-from', help='Sender mail address for mail. Required if --mail_to is specified.') mailgroup.add_argument('--mail-smtp', help='Smtp server for mailing. Required if --mail_to is specified.') mailgroup.add_argument('--mail-ssl', help='Use SSL (port 465) for sending mail.', action='store_true') mailgroup.add_argument('--mail-user', help='User for mailing if authentication is needed.') mailgroup.add_argument('--mail-password', help='User for mailing if authentication is needed.') mailgroup.add_argument('--mail-debug', help='Outputs messages for debugging mail issues.', action='store_true') args = parser.parse_args() if args.mail_to: argerr = [] if not args.mail_from: argerr = argerr + ['The argument mail_from is missing.'] if not args.mail_smtp: argerr = argerr + ['The argument mail_smtp is missing.'] if len(argerr) > 0: parser.print_help() sys.stderr.write('\n{0}\n'.format(string.join(argerr, '\n'))) os._exit(1) snapshot = snapshot(args) snapshot.execute()
{ "repo_name": "nharrer/snaprunner", "path": "snaprunner.py", "copies": "1", "size": "16957", "license": "mit", "hash": 4423937347965149700, "line_mean": 40.4596577017, "line_max": 253, "alpha_frac": 0.5922038096, "autogenerated": false, "ratio": 3.8838754008245533, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4976079210424553, "avg_score": null, "num_lines": null }
#! /usr/bin/env python ''' Name ---- gaussian File ---- gaussian.py Description ----------- Routines for evaluating, estimating parameters of, and fitting Gaussians. Package Contents ---------------- N-dimensional functions: gaussian(x, width=1., center=0., height=None, params=None) Evaluate the Gaussian function with given parameters at x (n-dimensional). fitgaussian(y, x) Calculates a Gaussian fit to (y, x) data, returns (width, center, height). 1-dimensional functions: gaussianguess(y, x=None) Crudely estimates the parameters of a Gaussian that fits the (y, x) data. Examples: --------- See fitgaussian() example. Revisions --------- 2007-09-17 0.1 jh@physics.ucf.edu Initial version 0.01, portions adapted from http://www.scipy.org/Cookbook/FittingData. 2007-10-02 0.2 jh@physics.ucf.edu Started making N-dimensional, put width before center in args. 2007-11-13 0.3 jh@physics.ucf.edu Made N-dimensional. 2008-12-02 0.4 nlust@physics.ucf.edu Made fit gaussian return errors, and fixed a bug generating initial guesses 2009-10-25 0.5 jh@physics.ucf.edu Standardized all headers, fixed an error in a fitgaussian example, added example ">>>"s and plot labels. ''' import numpy as np import scipy.optimize as so import disk as d def gaussian(x, width=1.0, center=0.0, height=None, bgpars=[0.0, 0.0, 0.0]): """ Evaluates the Gaussian and a background with given parameters at locations in x. Parameters ---------- x : ndarray (any shape) Abcissa values. Arranged as the output of np.indices() but may be float. The highest dimension must be equal to the number of other dimensions (i.e., if x has 6 dimensions, the highest dimension must have length 5, and each of those must give the coordinate along the respective axis). May also be 1-dimensional. Default: np.indices(y.shape). width : array_like The width of the Gaussian function, sometimes called sigma. If scalar, assumed constant for all dimensions. If array, must be linear and the same length as the first dimension of x. In this case, each element gives the width of the function in the corresponding dimension. Default: [1.]. center : array_like The mean value of the Gaussian function, sometimes called x0. Same scalar/array behavior as width. Default: [0.]. height : scalar The height of the Gaussian at its center. If not set, initialized to the value that makes the Gaussian integrate to 1. If you want it to integrate to another number, leave height alone and multiply the result by that other number instead. Must be scalar. Default: [product(1./sqrt(2 * pi * width**2))]. bgpars : ndarray or tuple, 3-element Background parameters, the elements determine a X- and Y-linearly dependant level, of the form: f = Y*bgparam[0] + X*bgparam[1] + bgparam[2] (Not tested for 1D yet). Returns ------- results : ndarray, same shape as x (or first element of x if multidimensional) This function returns the Gaussian function of the given width(s), center(s), and height applied to its input plus a linear background level. The Gaussian function is: f(x) = 1./sqrt(2 * pi * width**2) * exp(-0.5 * ((x - center) / width)**2). It is defined in multiple dimensions as the product of orthogonal, single-dimension Gaussians. Examples -------- >>> import matplotlib.pyplot as plt >>> import gaussian as g >>> x = np.arange(-10., 10.005, 0.01) >>> plt.plot(x, g.gaussian(x)) >>> plt.title('Gaussian') >>> plt.xlabel('Abcissa') >>> plt.ylabel('Ordinate') >>> # use an array [3] as a single parameter vector >>> z = np.array([2., 2, 3]) >>> plt.plot(x, g.gaussian(x, *z)) >>> # Test that it integrates to 1. >>> a = np.indices([100, 100]) - 50 >>> print(np.sum(g.gaussian(a, 3, 3))) 0.999999999999997 >>> print(np.sum(g.gaussian(a, np.array([1,2]), np.array([2,3])))) 1.0000000107 >>> plt.clf() >>> plt.imshow(g.gaussian(a, [3,5], [7,3])) >>> plt.title('2D Gaussian') >>> plt.xlabel('X') >>> plt.ylabel('Y') >>> A gaussian + a linear background level: >>> g2 = g.gaussian(x, width=(1.2, 1.15), center=(13.2,15.75), height=4.3, >>> bgpars=[0.05, 0.01, 1.0]) >>> plt.figure(1) >>> plt.clf() >>> plt.imshow(g2, origin='lower_left', interpolation='nearest') >>> plt.colorbar() >>> plt.title('2D Gaussian') >>> plt.xlabel('X') >>> plt.ylabel('Y') >>> plt.figure(2) >>> plt.clf() >>> plt.plot(g2[13,:]) >>> plt.title('X slice of 2D Gaussian') >>> plt.xlabel('X') >>> plt.ylabel('Z') >>> plt.figure(3) >>> plt.clf() >>> plt.plot(g2[:,16]) >>> plt.title('Y slice of 2D Gaussian') >>> plt.xlabel('Y') >>> plt.ylabel('Z') Revisions --------- 2007-09-17 0.1 jh@physics.ucf.edu Initial version 0.01 2007-10-02 0.2 jh@physics.ucf.edu Started making N-dimensional, put width before center in args. 2007-11-13 0.3 jh@physics.ucf.edu Fixed docs, bugs, added param, made N-dimensional 2009-10-01 0.4 jh@physics.ucf.edu Fixed docs. 2009-10-25 0.5 jh@physics.ucf.edu Added examples and plot labels. 2011-05-03 patricio Params option no longer sopported, Added bgpars to add a background. pcubillos@fulbrightmail.org """ ndim = np.ndim(x) - 1 if ndim == 0: # We use an indexing trick below that fails for 1D case. ndim = 1 oldshape = np.shape(x) x.shape = (1, x.shape[0]) # Make center a ndarray: if type(center) != np.ndarray: center += np.zeros(ndim) # Make width a ndarray: if type(width) != np.ndarray: width += np.zeros(ndim) r2pi = np.sqrt(2. * np.pi) # Define height if needed: if height == None: height = np.product(1. / (width * r2pi)) ponent = 0.0 for i in np.arange(ndim): ponent += ( (x[i] - center[i]) / width[i] )**2 if 'oldshape' in locals(): x.shape = oldshape # Set up the background: if ndim == 2: background = x[0]*bgpars[0] + x[1]*bgpars[1] + bgpars[2] else: # it must be 1D: background = x*bgpars[0] + bgpars[2] return height * np.exp(-0.5 * ponent) + background def old_gaussianguess(y, x=None, mask=None): """ Crudely estimates the parameters of a Gaussian that fits the (y, x) data. Parameters ---------- y : ndarray Array giving the function values. x : ndarray, same shape as y (optional) An array of the same shape as y giving the abcissas of y (if missing, uses array indices). Must be sorted ascending (which is not checked). Returns ------- param : tuple, 3 elements This function returns a tuple giving extimates of the (width, center, height) of a Gaussian that might fit the input data. See 'param' input parameter of gaussian() for format of this tuple. Notes ----- Currently only works for 1D data. If the data do not look Gaussian, and certainly if they contain spikes higher/lower than the peak of the real Gaussian, the parameter estimates will be poor. x must be sorted ascending (which is not checked). Method: The most extreme element of y (or its neighbor if a border element) is the location and height of the peak. The routine looks for the width at 0.6 of this maximum. Todo: When expanding to 2D, take arrays of X and Y coords rather than a (redundant) 2D array. This will prevent irregular grids. 2011-05-05 patricio: This function doesnt work for 2D, I don't even know if it works for 1D. If I ever have time I'll see what can we do. The function below seems to work fine for our 2D data. Examples -------- >>> import gaussian as g >>> x = np.arange(-10., 10.05, 0.1) >>> y = g.gaussian(x) >>> print(g.gaussianguess(y, x)) (0.99999999999999645, -3.5527136788005009e-14, 0.3989422804014327) Revisions --------- 2007-09-17 0.1 jh@physics.ucf.edu Initial version 0.01 2007-11-13 0.2 jh@physics.ucf.edu Fixed docs, return order. 2008-12-02 0.3 nlust@physics.ucf.edu Fixed a bug where if an initial guess was not provided, it would error out 2009-10-25 0.4 jh@physics.ucf.edu Converted to standard doc header. """ if y.ndim != 1 : raise ArrayShapeError, "y must be 1D, for now." if x == None : x = np.indices(y.shape)[0] else: if x.shape == (1, y.shape): oldshape = x.shape x.shape = y.shape elif x.shape != y.shape : raise ArrayShapeError, "x must have same shape as y (and be sorted)." # Default mask: if mask == None: mask = np.ones(np.shape(y)) ymax = np.amax(y*mask) #iymax = np.where(y == ymax)[0][0] iymax = np.argmax(y*mask) ymin = np.amin(y*mask) #iymin = np.where(y == ymin)[0][0] iymin = np.argmin(y*mask) if np.abs(ymin) >= np.abs(ymax): icenter = iymin else: icenter = iymax icenter = np.clip(icenter, 1, x.size-2) center = x[icenter] height = y[icenter] gtsigma = np.where(y > (0.6 * height)) width = (x[gtsigma[0].max()] - x[gtsigma[0].min()] ) / 2. if 'oldshape' in locals(): x.shape = oldshape return (width, center, height) def gaussianguess(data, mask=None, yxguess=None): # Default mask: if mask == None: mask = np.ones(np.shape(data)) # Center position guess, looking the max value: if yxguess == None: gcenter = np.unravel_index(np.argmax(data*mask), np.shape(data)) else: gcenter = np.around(yxguess[0]), np.around(yxguess[1]) # Height guess is value at gcenter position: gheight = data[gcenter] # The width guess is the sum of the number of pixels that are # greater than two sigma of the values in the x and y direction. # This gives a (very) rough guess, in pixels, how wide the PSF is. sigma = np.array( [np.std(data[:, gcenter[1]]), # y std (of central column) np.std(data[gcenter[0], :])] ) # x std (of central row) gwidth = ( np.sum((data*mask)[:, gcenter[1]] > 2*sigma[0])/2.0, np.sum((data*mask)[gcenter[0], :] > 2*sigma[1])/2.0 ) return (gwidth, gcenter, gheight) def fitgaussian(y, x=None, bgpars=None, fitbg=0, guess=None, mask=None, weights=None, maskg=False, yxguess=None): """ Fits an N-dimensional Gaussian to (value, coordinate) data. Parameters ---------- y : ndarray Array giving the values of the function. x : ndarray (optional) Array (any shape) giving the abcissas of y (if missing, uses np.indices(y). The highest dimension must be equal to the number of other dimensions (i.e., if x has 6 dimensions, the highest dimension must have length 5). The rest of the dimensions must have the same shape as y. Must be sorted ascending (which is not checked), if guess is not given. bgpars : ndarray or tuple, 3-elements Background parameters, the elements determine a X- and Y-linearly dependant level, of the form: f = Y*bgparam[0] + X*bgparam[1] + bgparam[2] (Not tested for 1D yet). fitbg : Integer This flag indicates the level of background fitting: fitbg=0: No fitting, estimate the bg as median(data). fitbg=1: Fit a constant to the bg (bg = c). fitbg=2: Fit a plane as bg (bg = a*x + b*y + c). guess : tuple, (width, center, height) Tuple giving an initial guess of the Gaussian parameters for the optimizer. If supplied, x and y can be any shape and need not be sorted. See gaussian() for meaning and format of this tuple. mask : ndarray Same shape as y. Values where its corresponding mask value is 0 are disregarded for the minimization. Only values where the mask value is 1 are considered. weights : ndarray Same shape as y. This array defines weights for the minimization, for scientific data the weights should be 1/sqrt(variance). Returns ------- params : ndarray This array contains the best fitting values parameters: width, center, height, and if requested, bgpars. with: width : The fitted Gaussian widths in each dimension. center : The fitted Gaussian center coordinate in each dimension. height : The fitted height. err : ndarray An array containing the concatenated uncertainties corresponding to the values of params. For example, 2D input gives np.array([widthyerr, widthxerr, centeryerr, centerxerr, heighterr]). Notes ----- If the input does not look anything like a Gaussian, the result might not even be the best fit to that. Method: First guess the parameters (if no guess is provided), then call a Levenberg-Marquardt optimizer to finish the job. Examples -------- >>> import matplotlib.pyplot as plt >>> import gaussian as g >>> # parameters for X >>> lx = -3. # low end of range >>> hx = 5. # high end of range >>> dx = 0.05 # step >>> # parameters of the noise >>> nc = 0.0 # noice center >>> ns = 1.0 # noise width >>> na = 0.2 # noise amplitude >>> # 1D Example >>> # parameters of the underlying Gaussian >>> wd = 1.1 # width >>> ct = 1.2 # center >>> ht = 2.2 # height >>> # x and y data to fit >>> x = np.arange(lx, hx + dx / 2., dx) >>> x += na * np.random.normal(nc, ns, x.size) >>> y = g.gaussian(x, wd, ct, ht) + na * np.random.normal(nc, ns, x.size) >>> s = x.argsort() # sort, in case noise violated order >>> xs = x[s] >>> ys = y[s] >>> # calculate guess and fit >>> (width, center, height) = g.gaussianguess(ys, xs) >>> (fw, fc, fh, err) = g.fitgaussian(ys, xs) >>> # plot results >>> plt.clf() >>> plt.plot(xs, ys) >>> plt.plot(xs, g.gaussian(xs, wd, ct, ht)) >>> plt.plot(xs, g.gaussian(xs, width, center, height)) >>> plt.plot(xs, g.gaussian(xs, fw, fc, fh)) >>> plt.title('Gaussian Data, Guess, and Fit') >>> plt.xlabel('Abcissa') >>> plt.ylabel('Ordinate') >>> # plot residuals >>> plt.clf() >>> plt.plot(xs, ys - g.gaussian(xs, fw, fc, fh)) >>> plt.title('Gaussian Fit Residuals') >>> plt.xlabel('Abcissa') >>> plt.ylabel('Ordinate') >>> # 2D Example >>> # parameters of the underlying Gaussian >>> wd = (1.1, 3.2) # width >>> ct = (1.2, 3.1) # center >>> ht = 2.2 # height >>> # x and y data to fit >>> nx = (hx - lx) / dx + 1 >>> x = np.indices((nx, nx)) * dx + lx >>> y = g.gaussian(x, wd, ct, ht) + na * np.random.normal(nc, ns, x.shape[1:]) >>> # calculate guess and fit >>> #(width, center, height) = g.gaussianguess(y, x) # not in 2D yet... >>> (fw, fc, fh, err) = g.fitgaussian(y, x, (wd, ct, ht)) >>> # plot results >>> plt.clf() >>> plt.title('2D Gaussian Given') >>> plt.xlabel('X') >>> plt.ylabel('Y') >>> plt.imshow( g.gaussian(x, wd, ct, ht)) >>> plt.clf() >>> plt.title('2D Gaussian With Noise') >>> plt.xlabel('X') >>> plt.ylabel('Y') >>> plt.imshow(y) >>> #plt.imshow( g.gaussian(x, width, center, height)) # not in 2D yet... >>> plt.clf() >>> plt.title('2D Gaussian Fit') >>> plt.xlabel('X') >>> plt.ylabel('Y') >>> plt.imshow( g.gaussian(x, fw, fc, fh)) >>> plt.clf() >>> plt.title('2D Gaussian Fit Residuals') >>> plt.xlabel('X') >>> plt.ylabel('Y') >>> plt.imshow(y - g.gaussian(x, fw, fc, fh)) >>> # All cases benefit from... >>> # show difference between fit and underlying Gaussian >>> # Random data, your answers WILL VARY. >>> np.array(fw) - np.array(wd) array([ 0.00210398, -0.00937687]) >>> np.array(fc) - np.array(ct) array([-0.00260803, 0.00555011]) >>> np.array(fh) - np.array(ht) 0.0030143371034774269 >>> Last Example: >>> x = np.indices((30,30)) >>> g1 = g.gaussian(x, width=(1.2, 1.15), center=(13.2,15.75), height=1e4, >>> bgpars=[0.0, 0.0, 100.0]) >>> error = np.sqrt(g1) * np.random.randn(30,30) >>> y = g1 + error >>> var = g1 >>> >>> plt.figure(1) >>> plt.clf() >>> plt.imshow(y, origin='lower_left', interpolation='nearest') >>> plt.colorbar() >>> plt.title('2D Gaussian') >>> plt.xlabel('X') >>> plt.ylabel('Y') >>> >>> guess = ((1.2,1.2),(13,16.),1e4) >>> reload(g) >>> fit = g.fitgaussian(y, x, bgpars=[0.0, 0.0, 110.], fitbg=1, guess=guess, >>> mask=None, weights=1/np.sqrt(var)) >>> print(fit[0]) Revisions --------- 2007-09-17 Joe Initial version, portions adapted from http://www.scipy.org/Cookbook/FittingData. jh@physics.ucf.edu 2007-11-13 Joe Made N-dimensional. 2008-12-02 Nate Included error calculation, and return Fixed a bug in which if the initial guess was None, and incorrect shape array was generated. This caused gaussian guess to fail. nlust@physics.ucf.edu 2009-10-25 Converted to standard doc header, fixed examples to return 4 parameters. 2011-05-03 patricio Added mask, weights, and background-fitting options. pcubillos@fulbrightmail.org """ if x == None: x = np.indices(np.shape(y)) else: if ( ((x.ndim == 1) and (x.shape != y.shape)) or ((x.ndim > 1) and (x.shape[1:] != y.shape))): raise ValueError, "x must give coordinates of points in y." # Default mask: all good if mask == None: mask = np.ones(np.shape(y)) # Default weights: no weighting if weights == None: weights = np.ones(np.shape(y)) # Mask the gaussian if requested: medmask = np.copy(mask) if maskg and (yxguess != None or guess != None): if yxguess != None: center = yxguess elif guess != None: center = guess[1] medmask *= (1 - d.disk(3, center, np.shape(y))) # Estimate the median of the image: medbg = np.median(y[np.where(medmask)]) if bgpars == None: bgpars = [0.0, 0.0, medbg] # get a guess if not provided if guess == None: if yxguess == None: guess = gaussianguess(y-medbg, mask=mask) else: guess = gaussianguess(y-medbg, mask=mask, yxguess=yxguess) # "ravel" the guess gparams = np.append(guess[0], guess[1]) gparams = np.append(gparams, guess[2]) # Background params to fit: if fitbg == 0: bgparams = [] elif fitbg == 1: bgparams = bgpars[2] elif fitbg == 2: bgparams = bgpars # Concatenate sets of parameters we want to fit: params = np.append(gparams, bgparams) # Rest of parameters needed by residuals: args = (x, y, mask, weights, bgpars, fitbg) # The fit: p, cov, info, mesg, success = so.leastsq(residuals, params, args, full_output=True) try: err = np.sqrt(np.diagonal(cov)) except: err = None return p, err def residuals(params, x, data, mask, weights, bgpars, fitbg): """ Calculates the residuals between data and a gaussian model determined by the rest of the parameters. Used in fitgaussian. Parameters ---------- params : 1D ndarray This array contains the parameters desired to fit with fitgaussian, depending on fitbg, the number of elements varies. x : ndarray Array (any shape) giving the abcissas of data. data : ndarray Array giving the values of the function. mask : ndarray Same shape as data. Values where its corresponding mask value is 0 are disregarded for the minimization. Only values where the mask value is 1 are considered. weights : ndarray Same shape as data. This array defines weights for the minimization, for scientific data the weights should be 1/sqrt(variance). bgpars : ndarray or tuple, 3-elements Background parameters, the elements determine a X- and Y-linearly dependant level, of the form: background = Y*bgparam[0] + X*bgparam[1] + bgparam[2] fitbg : Integer This flag indicates the level of background fitting: fitbg=0: No fitting, estimate the bg as median(data). fitbg=1: Fit a constant to the bg (bg = c). fitbg=2: Fit a plane as bg (bg = a*x + b*y + c). Returns ------- residuals : 1D ndarray An array of the (unmasked) weighted residuals between data and a gaussian model determined by params (and bgpars when necessary). Examples -------- Revisions --------- 2011-05-03 patricio Initial version. pcubillos@fulbrightmail.org """ # Use bgpars as default for background parameters, if those values # are being fitted update them: bgparams = bgpars if fitbg == 1: bgparams[2] = params[-1] # update params = params[0:-1] # remove last parameters from params elif fitbg == 2: bgparams = params[-3:] # update params = params[0:-3] # remove last parameters # Extract width, center, and height from params: data_dims = np.ndim(data) params_len = len(params) width = params[0 : data_dims] center = params[data_dims:2*data_dims] if params_len - 2*data_dims == 1: height = params[2*data_dims] else: # when height is None, queda la cagada, avoid this case. height = None # Produce the model: model = gaussian(x, width, center, height, bgparams).squeeze() # Calculate residuals: res = (model - data) * weights # Return only unmasked values: return res[np.where(mask)] def gaussians(x, param): """ Evaluate more than 1 gaussian. """ ndim = x.ndim - 1 if ndim == 0: # We use an indexing trick below that fails for 1D case. ndim = 1 oldshape = x.shape x.shape = (1, x.shape[0]) # The number of gaussians: ngauss = np.shape(param)[0] if ngauss == 1: param = [param] result = np.zeros(x[0].shape) for k in np.arange(ngauss): # Unpack parameters pdim = len(param[k]) if pdim % 2: # pdim is odd (when height is specified) pdim = (pdim - 1) / 2 height = param[k][-1] else: # pdim is even pdim = pdim / 2 height = None width = param[k][ : pdim] center = param[k][pdim : 2 * pdim] if type(center) != np.ndarray: center += np.zeros(ndim) if type(width) != np.ndarray: width += np.zeros(ndim) if height == None: height = np.product(1.0 / (width * np.sqrt(2.0 * np.pi))) ponent = 0.0 for i in np.arange(ndim): ponent += ( (x[i] - center[i]) / width[i] )**2.0 result += height * np.exp(-0.5 * ponent) if 'oldshape' in locals(): # reshape it back if necessary x.shape = oldshape return result def fitgaussians(y, x=None, guess=None, sigma=1.0): """ Fit position and flux of a data image with gaussians, same sigma is applied to all dispersions. Parameters: ----------- y : array_like Array giving the values of the function. x : array_like (optional) Array (any shape) giving the abcissas of y (if missing, uses np.indices(y). guess : 2D-tuple, [[width1, center1, height1], [width2, center2, height2], ... ] Tuple giving an initial guess of the Gaussian parameters for the optimizer. If supplied, x and y can be any shape and need not be sorted. See gaussian() for meaning and format of this tuple. """ if x == None: x = np.indices(y.shape)[0] else: if ( ((x.ndim == 1) and (x.shape != y.shape)) or ((x.ndim > 1) and (x.shape[1:] != y.shape))): raise ValueError, "x must give coordinates of points in y." # "ravel" the guess ngauss = np.shape(guess)[0] params = np.ravel(guess) params = np.append(guess, sigma) # Minimize residuals of the fit: p, cov, info, mesg, success = so.leastsq(resids, params, args=(x,ngauss,y), full_output=True) sigma = p[-1] p = np.reshape(p [0:-1], (ngauss, len(p [0:-1])/ngauss)) iscov = 0 if cov==None else 1 extra = (p, sigma, iscov, cov, info, mesg) return np.array(p[0,0:2]), extra def resids(param, x, ngauss, y): sigma = param[-1] param = np.reshape(param[0:-1], (ngauss, len(param[0:-1])/ngauss)) gss = [] for k in np.arange(ngauss): gauss = np.append(sigma, np.append(sigma, param[k])) gss = np.append(gss,gauss) p = np.reshape(gss, (ngauss,len(gss)/ngauss)) return np.ravel(gaussians(x,param=p)-y)
{ "repo_name": "zkbt/mosasaurus", "path": "mosasaurus/gaussian.py", "copies": "1", "size": "25888", "license": "mit", "hash": -2577163128737240600, "line_mean": 31.4818067754, "line_max": 91, "alpha_frac": 0.586565204, "autogenerated": false, "ratio": 3.422527763088313, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.45090929670883134, "avg_score": null, "num_lines": null }
# $autorun # $show-in-menu # Calc freq from cpw_design import cpw import pya import sys sys.stderr = sys.stdout class MenuAction(pya.Action): def __init__(self, title, shortcut, action): self.title = title self.shortcut = shortcut self.action = action def triggered(self): self.action() def calc_freq(): #Load View app = pya.Application.instance() mw = app.main_window() lv = mw.current_view() ly = lv.active_cellview().layout() dbu = ly.dbu if lv==None: raise Exception("No view selected") total_length = 0.0 #CPW consists of 6um wide polygons cpw_width = 10.0 #Difference in length after rounding corners delta_r = 42.29 lv.transaction("Calculate Frequency") selected_objects = lv.each_object_selected() for obj in selected_objects: if obj.shape.is_path() and not obj.is_cell_inst(): shape = obj.shape polygon = shape.polygon a = polygon.area() m = obj.trans().mag * ly.dbu total_length += a * m * m / cpw_width #subtract difference from rounding corners total_length -= (shape.path.num_points()-2)*delta_r freq = str(cpw(l=total_length).fn()*1e-9) + " GHz" pya.MessageBox().info("Frequency", freq, pya.MessageBox().b_ok()) x = MenuAction("Calculate Frequency", "", calc_freq) app = pya.Application.instance() mw = app.main_window() menu = mw.menu() menu.insert_separator("tools_menu.end", "sep_freq") menu.insert_item("tools_menu.end", "freq", x)
{ "repo_name": "calebjordan/klayout-macros", "path": "pymacros/CPW Frequency.py", "copies": "1", "size": "1628", "license": "mit", "hash": 5682894012418105000, "line_mean": 23.3134328358, "line_max": 69, "alpha_frac": 0.593980344, "autogenerated": false, "ratio": 3.501075268817204, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.45950556128172043, "avg_score": null, "num_lines": null }
# $description: Make CPW out of Path # $autorun # $show-in-menu import pya import sys sys.stderr = sys.stdout class MenuAction(pya.Action): def __init__(self, title, shortcut, action): self.title = title self.shortcut = shortcut self.action = action def triggered(self): self.action() def make_cpw(): #Load View app = pya.Application.instance() mw = app.main_window() lv = mw.current_view() ly = lv.active_cellview().layout() dbu = ly.dbu center_radius = 100.0/dbu #Curve radius center_width = 10./dbu #Center conductor width s_width = 7./dbu#Center - Outer conductor spacing keepout_width = center_width * 0.4 #Keepout spacing ri = center_radius - .5*center_width #Inner radius ro = center_radius + .5*center_width # Outer radius n = 10/dbu #Number of points per curve cpw_layer = ly.layer(1,0) keepout_layer = ly.layer(1,6) if lv==None: raise Exception("No view selected") lv.transaction("Make CPW") selected_objects = lv.each_object_selected() print("x") for obj in selected_objects: if obj.shape.is_path() and not obj.is_cell_inst(): inner = pya.Path() outer = pya.Path() keepout = pya.Path() print(obj.shape.path) inner = obj.shape.path outer = obj.shape.path keepout = obj.shape.path #Adjust widths inner.width = center_width outer.width = inner.width + 2*s_width keepout.width = outer.width + 2*keepout_width #Round Corners inner = [inner.polygon().round_corners(ri, ro, n)] outer = [outer.polygon().round_corners(ri-s_width,ro+s_width, n)] keepout = keepout.polygon().round_corners(ri-s_width-keepout_width, ro+s_width+keepout_width, n) #Subtract inner from outer ep = pya.EdgeProcessor() outer_minus_inner = ep.boolean_p2p(outer, inner, pya.EdgeProcessor().ModeANotB, True, False) for p in outer_minus_inner: lv.active_cellview().cell.shapes(cpw_layer).insert(p) # lv.active_cellview().cell.shapes(cpw_layer).insert(outer_minus_inner[0]) lv.active_cellview().cell.shapes(keepout_layer).insert(keepout) lv.commit() #pya.MessageBox.info("Test", "It worked bitches", pya.MessageBox.b_ok()) x = MenuAction("Make CPW", "", make_cpw) app = pya.Application.instance() mw = app.main_window() menu = mw.menu() menu.insert_separator("tools_menu.end", "sep_cpw") menu.insert_item("tools_menu.end", "cpw", x)
{ "repo_name": "calebjordan/klayout-macros", "path": "pymacros/Make CPW.py", "copies": "1", "size": "2760", "license": "mit", "hash": 5836841302612969000, "line_mean": 31.1046511628, "line_max": 108, "alpha_frac": 0.5807971014, "autogenerated": false, "ratio": 3.4936708860759493, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9396933979416471, "avg_score": 0.03550680161189564, "num_lines": 86 }
# $description: Make Grounding Straps crossing CPW Paths # $autorun # $show-in-menu import pya import sys sys.stderr = sys.stdout import json from numpy import sqrt, float64, array, nan, isnan class MenuAction(pya.Action): def __init__(self, title, shortcut, action): self.title = title self.shortcut = shortcut self.action = action def triggered(self): self.action() def make_gnd_straps(): #Load View app = pya.Application.instance() mw = app.main_window() lv = mw.current_view() ly = lv.active_cellview().layout() dbu = ly.dbu if lv==None: raise Exception("No view selected") # Ground Strap parameters d = 300/dbu #100 um separation l = 22/dbu #22 um long w = 8/dbu #8um wide gs_layer = ly.layer(2,0) lv.transaction("Make Grounding Straps") selected_objects = lv.each_object_selected() for obj in selected_objects: print(obj.shape()) m = [] points = [] strap_points = [] pts_per_segment = [] try: if obj.shape().is_path() and not obj.is_cell_inst(): pth = obj.shape().path for pt in pth.each_point(): points.append(pt) for i in range(0, len(points)-1): #Calculate Slope of cpw and calculate perpendicular slope dx = points[i+1].x - points[i].x dy = points[i+1].y - points[i].y m.append(-float64(dx)/float64(dy)) #Calculate distance between points dist = sqrt((points[i+1].x - points[i].x)**2 + (points[i+1].y - points[i].y)**2) di = d x_offset = .5*l/sqrt(1 + m[i]**2) y_offset = .5*m[i]*l/sqrt(1+m[i]**2) #Check for inf slopes if isnan(x_offset): x_offset = l/2 if isnan(y_offset): y_offset = l/2 while di < dist: new_x = points[i].x + di/dist*(points[i+1].x-points[i].x) new_y = points[i].y + di/dist*(points[i+1].y-points[i].y) firstpt = pya.Point(new_x+x_offset, new_y+y_offset) endpt = pya.Point(new_x-x_offset, new_y-y_offset) strap =pya.Path( [firstpt, endpt], w) lv.active_cellview().cell.shapes(gs_layer).insert(strap) di+=d pts_per_segment.append(di/d) print("Writing {} straps".format(di/d)) except StopIteration: pya.MessageBox.info("Test", "It worked bitches", pya.MessageBox.b_ok()) lv.commit() #pya.MessageBox.info("Test", "It worked bitches", pya.MessageBox.b_ok()) x = MenuAction("Make Ground Straps", "", make_gnd_straps) app = pya.Application.instance() mw = app.main_window() menu = mw.menu() menu.insert_separator("tools_menu.end", "sep_gnd_straps") menu.insert_item("tools_menu.end", "gnd_straps", x)
{ "repo_name": "calebjordan/klayout-macros", "path": "pymacros/Make Ground Straps.py", "copies": "1", "size": "3233", "license": "mit", "hash": 7588953903091675000, "line_mean": 33.7741935484, "line_max": 101, "alpha_frac": 0.4992267244, "autogenerated": false, "ratio": 3.568432671081678, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.45676593954816774, "avg_score": null, "num_lines": null }
# $description: Run Shapes in FastHenry # $autorun # $show-in-menu import pya import sys import types from os.path import curdir, join import os sys.stderr = sys.stdout class MenuAction(pya.Action): def __init__(self, title, shortcut, action): self.title = title self.shortcut = shortcut self.action = action def triggered(self): self.action() def writeInputFile(self, clicked): global fh lv = pya.Application.instance().main_window().current_view() selected_objects = lv.each_object_selected() ly = lv.active_cellview().layout() dbu = ly.dbu # Take Inputs nwincInput = self.nwincInput.text nhincInput = self.nhincInput.text startFreq = self.startFreqInput.text stopFreq = self.stopFreqInput.text numPts = self.ptsInput.text fh = FastHenryFile(nwinc=nwincInput, nhinc=nhincInput, pen_depth=85e-3, start_freq=startFreq, stop_freq=stopFreq, numpts=numPts) i=0 for obj in selected_objects: if obj.shape.is_path() and not obj.is_cell_inst(): name = obj.shape.property('1') if name is None: name = str(i) i = i+1 pts = [] pth = obj.shape.path # create point object for each point for i, pt in enumerate(pth.each_point()): p = point(name + str(i), float(pt.x*dbu), float(pt.y*dbu)) pts.append(p) # create shape sh = shape(name, pts, width=pth.width*dbu) fh.shapes.append(sh) self.inputFilePreview.setText(str(fh)) # Write file and call fasthenry fh.print_to_file() def callFastHenry(self, clicked): global fh out, result = fh.call_fh() # Display Results self.outputPreview.setText(result) def runInFastHenry(): # Load View app = pya.Application.instance() mw = app.main_window() lv = mw.current_view() ly = lv.active_cellview().layout() dbu = ly.dbu # Setup GUI ui_path = join("/Users/caleb/Development/klayout-macros/pymacros", "FastHenryGui.ui") ui_file = pya.QFile(ui_path) parent = pya.Application.instance().main_window() ui_file.open(pya.QIODevice.ReadOnly) form = pya.QFormBuilder().load(ui_file, parent) ui_file.close() # Bind Functions form.writeInputBtn.clicked(types.MethodType(writeInputFile, form)) form.runBtn.clicked(types.MethodType(callFastHenry, form)) # Load Shapes if lv is None: raise Exception("No view selected") selected_objects = lv.each_object_selected() i=0 for obj in selected_objects: if obj.shape.is_path() and not obj.is_cell_inst(): name = obj.shape.property('1') if name is None: name = str(i) i = i+1 print(name) form.traceComboBox.addItem(name) form.exec_() # Declare fh object globally, so different functions can access fh = [] # Add to Menu x = MenuAction("Run in FastHenry", "", runInFastHenry) app = pya.Application.instance() mw = app.main_window() menu = mw.menu() menu.insert_separator("tools_menu.end", "sep_fh") menu.insert_item("tools_menu.end", "fh", x) import time from subprocess import Popen, PIPE import subprocess from os.path import join, curdir, abspath class point: def __init__(self, label, x, y, z=0): self.label = label self.x = x self.y = y self.z = z def __repr__(self): return "N{} x={} y={} z={}\n".format(self.label, self.x, self.y, self.z) class segment: def __init__(self, label, point1, point2, width, height=.1): self.label = label self.point1 = point1 self.point2 = point2 self.width = width self.height = height def __repr__(self): return "E{} N{} N{} w={} h={}\n".format(self.label, self.point1.label, self.point2.label, self.width, self.height) class shape: def __init__(self, label, points, width="10", height=.1): self.label = label self.points = points self.segments = [] self.width = width self.height = height for i in range(len(points)-1): label_str = "{}{}".format(label, i) self.segments.append(segment(label_str, points[i], points[i+1], width, height)) def __repr__(self): string = "\n* Shape {}\n".format(self.label) for point in self.points: string += str(point) for seg in self.segments: string += str(seg) return string class FastHenryFile(): def __init__(self, filename='test', comments='', pen_depth=85e-3, units="um", nwinc=10, nhinc=10, start_freq = 1, stop_freq = 1, numpts = 1): self.filename = str(filename) + ".inp" self.dir = "/Users/caleb/Development/klayout-macros/pymacros" self.path = join(self.dir, self.filename) self.comments = str(comments) self.pen_depth = float(pen_depth) self.units = units self.nwinc = int(nwinc) self.nhinc = int(nhinc) self.start_freq = float(start_freq) self.stop_freq = float(stop_freq) self.numpts = float(numpts) # Elements self.points = [] self.segments = [] self.groundplanes = [] self.shapes = [] print(self.path) def header(self): string = "* {}\n".format(self.filename) string += "* Generated on {}\n".format(time.strftime("%X %x")) for line in self.comments.splitlines(): string += "*{}\n".format(line) return string def footer(self): string = "\n* Define Frequency\n" string += ".freq fmin={} fmax={} ndec={}\n".format(self.start_freq, self.stop_freq, self.numpts) string += ".end" return string def externals(self): string = "\n*------------ Externals ------------\n" for shape in self.shapes: string += "\n* {}\n".format(shape.label) string += ".external N{} N{}\n".format(shape.points[0].label, shape.points[-1].label) return string def params(self): string = "\n*------------ Params ------------\n" string +=".Units um\n" string += "\n.default lambda={}\n\n".format(self.pen_depth) string += ".default nwinc={} nhinc={}\n".format(self.nwinc, self.nhinc) return string def print_shapes(self): string = "\n*------------ Shapes ------------\n" for s in self.shapes: string += str(s) return string def __repr__(self): string = self.header() + self.params() + self.print_shapes() + self.externals() + self.footer() return string def print_to_file(self): print('Printing {}..\n'.format(self.path)) with open(self.path, 'w') as f: f.write(str(self)) print("Done\n") def call_fh(self): print(self.path) out = Popen('fasthenry ' + self.path) #out = os.popen('ls') while 1: if out.readline() == "": break print(out.readline()) f = open(join(self.dir, 'Zc.mat'), 'r') result = out.read() return out, result def call_fastHenry(self): with Popen(["ls", self.path], stdout=PIPE, bufsize=1, universal_newlines=True) as p: for line in p.stdout: print(line) f = open(join(self.dir, 'Zc.mat'), 'r') result = f.read() return out, result
{ "repo_name": "calebjordan/klayout-macros", "path": "pymacros/Run in FastHenry.py", "copies": "1", "size": "7610", "license": "mit", "hash": 6883596304056364000, "line_mean": 29.3227091633, "line_max": 104, "alpha_frac": 0.5645203679, "autogenerated": false, "ratio": 3.473299863076221, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.9474667641808017, "avg_score": 0.012630517833640865, "num_lines": 251 }
# $description: Split into layer cells # $autorun # $show-in-menu import pya import sys sys.stderr = sys.stdout class MenuAction(pya.Action): def __init__(self, title, shortcut, action): self.title = title self.shortcut = shortcut self.action = action def triggered(self): self.action() def make_layer_cells(): #Load View app = pya.Application.instance() mw = app.main_window() lv = mw.current_view() ly = lv.active_cellview().layout() dbu = ly.dbu if lv==None: raise Exception("No view selected") cv = lv.cellview(lv.active_cellview_index()) #Loop through layers for layer in [1,2,3]: new_cell = ly.create_cell(cv.cell.display_title() + "L" + str(layer)) # Loop through instances for inst in cv.cell.each_inst(): #Calculate location of instances itrans = pya.ICplxTrans.from_trans(pya.CplxTrans()) box = inst.bbox().transformed(itrans) x = box.center().x y = box.center().y #Create new cell to represent given layer new_subcell = ly.create_cell(inst.cell.display_title() + "L" + str(layer)) #Map Bounding box and shape layers to new layer lm = pya.LayerMapping() lm.map(ly.layer(1,3), ly.layer(1,3)) lm.map(ly.layer(layer, 0), ly.layer(layer, 0)) lm.map(ly.layer(layer,1), ly.layer(layer, 0)) #Create Instance Array to place into cell array = pya.CellInstArray() #Copy shapes, place, and insert array.cell_index=new_subcell.cell_index() new_subcell.copy_shapes(inst.cell, lm) array.trans = pya.Trans(pya.Point(x,y)) new_cell.insert(array) x = MenuAction("Make Layer Cells", "", make_layer_cells) app = pya.Application.instance() mw = app.main_window() menu = mw.menu() menu.insert_separator("@hcp_context_menu.end", "sep_layer_cells") menu.insert_item("@hcp_context_menu.end", "layer_cells", x)
{ "repo_name": "calebjordan/klayout-macros", "path": "pymacros/Make Layer Cells.py", "copies": "1", "size": "2057", "license": "mit", "hash": -7878870032128678000, "line_mean": 27.985915493, "line_max": 82, "alpha_frac": 0.5950413223, "autogenerated": false, "ratio": 3.4056291390728477, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.45006704613728477, "avg_score": null, "num_lines": null }
# $description: Write Image Distribution from Wafer # $autorun # $show-in-menu import pya import sys from math import copysign from numpy import arange sys.stderr = sys.stdout class MenuAction(pya.Action): def __init__(self, title, shortcut, action): self.title = title self.shortcut = shortcut self.action = action def triggered(self): self.action() def write_distribution(job_file, cv, dbu): #For cellinstarray in wafer #Loop through various layouts on wafer #For cellinst in cellinstarray #Loop through all dies in particular layout, (cell selection) #For images in cellinst #Loop through images in die, writing entry for each image for inst in cv.cell.each_inst(): subcell = inst.cell # Determine indexes for cell selection if copysign(1, inst.a.x) == 1: start_index_x = 0 else: start_index_x = 1 if copysign(1, inst.b.y) == 1: start_index_y = 0 else: start_index_y = 1 x_index = arange(copysign(start_index_x, inst.a.x), copysign(inst.na, inst.a.x) + copysign(start_index_x, inst.a.x), copysign(1, inst.a.x)) y_index = arange(copysign(start_index_y, inst.b.y), copysign(inst.nb, inst.b.y) + copysign(start_index_y, inst.b.y), copysign(1, inst.b.y)) # Write each die type print("\nPrinting {} dies containing {}".format(inst.na*inst.nb, subcell.basic_name())) for i in x_index: for j in y_index: print("\tPrinting die at {:.0f}, {:.0f}".format(i, j)) for image in subcell.each_inst(): #Get position itrans = pya.ICplxTrans.from_trans(pya.CplxTrans()) box = image.bbox().transformed(itrans) x = box.center().x*dbu/1000. y = box.center().y*dbu/1000. #Write definition text = 'START_SECTION IMAGE_DISTRIBUTION\n' text += '\tIMAGE_ID "{}"\n'.format(image.cell.basic_name()) text += '\tINSTANCE_ID "{}"\n'.format("<Default>") text += '\tCELL_SELECTION "{:.0f}" "{:.0f}"\n'.format(i, j) text += '\tDISTRIBUTION_ACTION "I"\n' text += '\tOPTIMIZE_ROUTE "N"\n' text += '\tIMAGE_CELL_SHIFT {:.06f} {:.06f}\n'.format(x, y) text += 'END_SECTION\n\n' print(text) job_file.write(text) #for image in subcell.each_inst(): #print(image.cell.basic_name()) '''text = 'START_SECTION IMAGE_DISTRIBUTION\n' text += '\tIMAGE_ID "{}"\n'.format() text += '\tINSTANCE_ID "{}"\n'.format() text += '\tCELL_SELECTION "{}" "{}"\n'.format() text += '\tDISTRIBUTION_ACTION "I"\n' text += '\tOPTIMIZE_ROUTE "N"\n' text += '\tIMAGE_CELL_SHIFT {} {}\n'.format() text += 'END_SECTION\n\n' ''' def write_images(): #Load View app = pya.Application.instance() mw = app.main_window() lv = mw.current_view() ly = lv.active_cellview().layout() dbu = ly.dbu if lv==None: raise Exception("No view selected") cv = lv.cellview(lv.active_cellview_index()) # get the current cell view (Make sure you're running this on your mask) if (cv.cell.name.lower() != "wafer"): raise "Make your \"Wafer\" cell your current view." if not cv.is_valid(): raise "No layout selected" #Get parameters filename = pya.FileDialog.ask_save_file_name("ASML Job file", "test.asml", "ASML files (*.asml *.txt)") if filename: job_file = open(filename, 'a') #Print image distribution write_distribution(job_file, cv, dbu) #Print layer definition #Print process data #Print reticle data job_file.close() x = MenuAction("Write Image Distribution", "", write_images) app = pya.Application.instance() mw = app.main_window() menu = mw.menu() menu.insert_separator("@hcp_context_menu.end", "sep_write_images") menu.insert_item("@hcp_context_menu.end", "write_images", x)
{ "repo_name": "calebjordan/klayout-macros", "path": "pymacros/Write Images.py", "copies": "1", "size": "4299", "license": "mit", "hash": -298507358363718300, "line_mean": 31.5757575758, "line_max": 143, "alpha_frac": 0.5510583857, "autogenerated": false, "ratio": 3.4781553398058254, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4529213725505825, "avg_score": null, "num_lines": null }
# $description: Write Instances and Placements to ASML job file # $autorun # $show-in-menu import pya import sys from datetime import datetime sys.stderr = sys.stdout class MenuAction(pya.Action): def __init__(self, title, shortcut, action): self.title = title self.shortcut = shortcut self.action = action def triggered(self): self.action() def print_general(filename): cell_width = 8.1 cell_height = 8.1 job_name = "Si0x Test Wafer" text = "" text += 'START_SECTION GENERAL\n' text += '\tCOMMENT "Job: {}"\n'.format(job_name) text += '\t "Generated on {}"\n'.format(datetime.today().strftime("%x %X")) text += '\t "Caleb Howington"\n' text += '\tMACHINE_TYPE "PAS5500/300"\n' text += '\tRETICLE_SIZE 6\n' text += '\tWFR_DIAMETER 100.000000\n' text += '\tWFR_NOTCH "N"\n' text += '\tCELL_SIZE {} {}\n'.format(cell_width, cell_height) text += '\tROUND_EDGE_CLEARANCE 1.000000\n' text += '\tFLAT_EDGE_CLEARANCE 0.000000\n' text += '\tEDGE_EXCLUSION 1.000000\n' text += '\tCOVER_MODE "W"\n' text += '\tNUMBER_DIES 3 14\n' text += '\tMIN_NUMBER_DIES 1\n' text += '\tPLACEMENT_MODE "O"\n' text += '\tMATRIX_SHIFT {} {}\n'.format(cell_width/2, cell_height/2) text += '\tPREALIGN_METHOD "STANDARD"\n' text += '\tWAFER_ROTATION 0.000000\n' text += '\tCOMBINE_ZERO_FIRST "N"\n' text += '\tMATCHING_SET_ID "DEFAULT"\n' text += 'END_SECTION\n\n' print(text) filename.write(text) def print_image_definitions(filename, cv, reticle_id, dbu): # Scale for Mask, e.g. 4x scale = 4 #Calculate location of instances for inst in cv.cell.each_inst(): itrans = pya.ICplxTrans.from_trans(pya.CplxTrans()) box = inst.bbox().transformed(itrans) width = box.width()*dbu*scale/1000 height = box.height()*dbu*scale/1000 x = box.center().x*dbu*scale/1000. y = box.center().y*dbu*scale/1000. job_file_text = "START_SECTION IMAGE_DEFINITION\n" job_file_text += "\tIMAGE_ID \"{}\"\n".format(inst.cell.basic_name()) job_file_text += "\tRETICLE_ID \"{}\"\n".format(reticle_id) job_file_text += "\tIMAGE_SIZE {:.06f} {:.06f}\n".format(width, height) job_file_text += "\tIMAGE_SHIFT {:.06f} {:.06f}\n".format(x, y) job_file_text += "\tMASK_SIZE {:.06f} {:.06f}\n".format(width, height) job_file_text += "\tMASK_SHIFT {:.06f} {:.06f}\n".format(x, y) job_file_text += "\tVARIANT_ID \"\"\n" job_file_text += "END_SECTION\n\n" print(job_file_text) filename.write(job_file_text) def write_distribution(): #For cellinstarray in wafer #Loop through various layouts on wafer #For cellinst in cellinstarray #Loop through all dies in particular layout, (cell selection) #For images in cellinst #Loop through images in die, writing entry for each image text = 'START_SECTION IMAGE_DISTRIBUTION\n' text += '\tIMAGE_ID "{}"\n'.format() text += '\tINSTANCE_ID "{}"\n'.format() text += '\tCELL_SELECTION "{}" "{}"\n'.format() text += '\tDISTRIBUTION_ACTION "I"\n' text += '\tOPTIMIZE_ROUTE "N"\n' text += '\tIMAGE_CELL_SHIFT {} {}\n'.format() text += 'END_SECTION\n\n' def write_instances(): #Load View app = pya.Application.instance() mw = app.main_window() lv = mw.current_view() ly = lv.active_cellview().layout() dbu = ly.dbu if lv==None: raise Exception("No view selected") cv = lv.cellview(lv.active_cellview_index()) # get the current cell view (Make sure you're running this on your mask) if (cv.cell.name.lower() != "mask"): raise "Make your \"Mask\" cell your current view." if not cv.is_valid(): raise "No layout selected" #Get parameters reticle_id = pya.InputDialog.get_string("Reticle ID", "Specify the reticle ID", "mask") filename = pya.FileDialog.ask_save_file_name("ASML Job file", "test.asml", "ASML files (*.asml *.txt)") if filename: job_file = open(filename, 'w') #Print general print_general(job_file) #Print image definitions print_image_definitions(job_file, cv, reticle_id, dbu) #Print image distribution #Print layer definition #Print process data #Print reticle data job_file.close() x = MenuAction("Write Instances", "", write_instances) app = pya.Application.instance() mw = app.main_window() menu = mw.menu() menu.insert_separator("@hcp_context_menu.end", "sep_write_instances") menu.insert_item("@hcp_context_menu.end", "write_instances", x)
{ "repo_name": "calebjordan/klayout-macros", "path": "pymacros/Write Instances.py", "copies": "1", "size": "5658", "license": "mit", "hash": -2575742470663776000, "line_mean": 35.2692307692, "line_max": 123, "alpha_frac": 0.5040650407, "autogenerated": false, "ratio": 3.6503225806451614, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4654387621345161, "avg_score": null, "num_lines": null }
# $description: Write Mask Placements to Excel Spreadsheet # $autorun # $show-in-menu import pya import sys from datetime import datetime #import pandas as pd import numpy as np sys.stderr = sys.stdout class MenuAction(pya.Action): def __init__(self, title, shortcut, action): self.title = title self.shortcut = shortcut self.action = action def triggered(self): self.action() def print_image_definitions(filename, cv, reticle_id, dbu): # Scale for Mask, e.g. 4x scale = 4 job_sheet_text = "Name,Width,Height,X,Y\n" #Calculate location of instances for inst in cv.cell.each_inst(): itrans = pya.ICplxTrans.from_trans(pya.CplxTrans()) box = inst.bbox().transformed(itrans) width = box.width()*dbu*scale/1000 height = box.height()*dbu*scale/1000 x = box.center().x*dbu*scale/1000. y = box.center().y*dbu*scale/1000. job_file_text = "START_SECTION IMAGE_DEFINITION\n" job_file_text += "\tIMAGE_ID \"{}\"\n".format(inst.cell.basic_name()) job_file_text += "\tRETICLE_ID \"{}\"\n".format(reticle_id) job_file_text += "\tIMAGE_SIZE {:.06f} {:.06f}\n".format(width, height) job_file_text += "\tIMAGE_SHIFT {:.06f} {:.06f}\n".format(x, y) job_file_text += "\tMASK_SIZE {:.06f} {:.06f}\n".format(width, height) job_file_text += "\tMASK_SHIFT {:.06f} {:.06f}\n".format(x, y) job_file_text += "\tVARIANT_ID \"\"\n" job_file_text += "END_SECTION\n\n" job_sheet_text += str(inst.cell.basic_name()) + "," job_sheet_text += str(width/scale) + "," job_sheet_text += str(height/scale) + "," job_sheet_text += str(x/scale) + "," job_sheet_text += str(y/scale) + "\n" print(job_sheet_text) filename.write(job_file_text) def write_instances(): #Load View app = pya.Application.instance() mw = app.main_window() lv = mw.current_view() ly = lv.active_cellview().layout() dbu = ly.dbu if lv==None: raise Exception("No view selected") cv = lv.cellview(lv.active_cellview_index()) # get the current cell view (Make sure you're running this on your mask) #if (cv.cell.name.lower() != "mask"): #raise "Make your \"Mask\" cell your current view." if not cv.is_valid(): raise "No layout selected" #Get parameters reticle_id = pya.InputDialog.get_string("Reticle ID", "Specify the reticle ID", "mask") filename = pya.FileDialog.ask_save_file_name("ASML Job file", "test.asml", "ASML files (*.asml *.txt)") if filename: job_file = open(filename, 'w') #Print general print_general(job_file) #Print image definitions print_image_definitions(job_file, cv, reticle_id, dbu) #Print image distribution #Print layer definition #Print process data #Print reticle data job_file.close() x = MenuAction("Write Instances to Excel", "", write_instances) app = pya.Application.instance() mw = app.main_window() menu = mw.menu() menu.insert_separator("@hcp_context_menu.end", "sep_write_instances_to_excel") menu.insert_item("@hcp_context_menu.end", "write_instances_to_excel", x)
{ "repo_name": "calebjordan/klayout-macros", "path": "pymacros/Write Instances to Excel.py", "copies": "1", "size": "3440", "license": "mit", "hash": 3477924449895213600, "line_mean": 29.990990991, "line_max": 111, "alpha_frac": 0.5787790698, "autogenerated": false, "ratio": 3.3495618305744888, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.4428340900374489, "avg_score": null, "num_lines": null }
""" Helper functions for date time conversion. """ __version__ = "$Revision-Id:$" import datetime import rfc822 import time _ISO8601_DATETIME_FORMAT = r"%Y-%m-%dT%H:%M:%SZ" def convertToDatetime(datetimeString): """ If all conversion tries fail C{None} is returned. Supported formats are: Time ticks since 1970 (e.g., 0.0) ISO8601 (e.g., 2000-01-01T10:10:10Z) RFC822 (e.g., Wed, 02 Oct 2002 13:00:00 GMT) @note: Date and time is represented in local time zone. """ dtConversionFuncs = [convertFromTimeStamp, convertFromIso8601, convertFromRfc822] for dtConversionFunc in dtConversionFuncs: try: return dtConversionFunc(datetimeString) except ValueError: datetimeValue = None return datetimeValue def convertFromTimeStamp(timeStamp): """ Converts the time stamp to a C{datetime.datetime} object. @note: Date and time is represented in local time zone. @raise ValueError: To indicate failed conversion. """ try: timeStamp = float(timeStamp) except TypeError: raise ValueError() dt = datetime.datetime.fromtimestamp(timeStamp) return _convertToLocaltime(dt, _LocalTimezone()) def _convertToLocaltime(dt, srcTimeZone): dt = dt.replace(tzinfo=srcTimeZone) dt = dt.astimezone(_LocalTimezone()) return dt.replace(tzinfo=None) def convertFromRfc822(rfc822Format): """ Converts the RFC822 formatted date time string to a C{datetime.datetime} object. @note: Date and time is represented in local time zone. @raise ValueError: To indicate failed conversion. """ timeStruct = rfc822.parsedate(rfc822Format) if not timeStruct is None: dt = datetime.datetime(*(timeStruct[0:6])) return _convertToLocaltime(dt, _UtcTimezone()) else: raise ValueError() def convertFromIso8601(iso8601Format): """ Converts the ISO8601 formatted date time string to a C{datetime.datetime} object. @note: Date and time is represented in local time zone. @raise ValueError: To indicate failed conversion. """ try: timeStruct = time.strptime(iso8601Format, _ISO8601_DATETIME_FORMAT) except TypeError: raise ValueError() dt = datetime.datetime(*(timeStruct)[0:6]) return _convertToLocaltime(dt, _UtcTimezone()) def convertToIso8601(dt): """ Converts a C{datetime.datetime} object to an ISO8601 formatted date time string. @note: Date and time is represented in UTC time zone. @raise ValueError: To indicate failed conversion. """ try: dt = dt.replace(tzinfo=_LocalTimezone()) dt = dt.astimezone(_UtcTimezone()) return dt.strftime(_ISO8601_DATETIME_FORMAT) except AttributeError: raise ValueError() class _UtcTimezone(datetime.tzinfo): def utcoffset(self, _): return datetime.timedelta(0) def dst(self, _): return datetime.timedelta(0) class _LocalTimezone(datetime.tzinfo): def __init__(self): datetime.tzinfo.__init__(self) self._standardOffset = datetime.timedelta(seconds=-time.timezone) self._dstOffset = self._standardOffset if time.daylight: self._dstOffset = datetime.timedelta(seconds=-time.altzone) self._destDifference = self._dstOffset - self._standardOffset def utcoffset(self, dt): if self._isDst(dt): return self._dstOffset else: return self._standardOffset def dst(self, dt): if self._isDst(dt): return self._destDifference else: return datetime.timedelta(0) @staticmethod def _isDst(dt): tt = (dt.year, dt.month, dt.day, dt.hour, dt.minute, dt.second, dt.weekday(), 0, -1) try: stamp = time.mktime(tt) tt = time.localtime(stamp) return tt.tm_isdst > 0 except (ValueError, OverflowError): return False
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/persistence/common/datetime_util.py", "copies": "1", "size": "5906", "license": "bsd-3-clause", "hash": 6246323827197065000, "line_mean": 31.7485714286, "line_max": 75, "alpha_frac": 0.6567897054, "autogenerated": false, "ratio": 4.1679604798870855, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.009942043810490287, "num_lines": 175 }
""" Testing domain property base classes. """ import unittest from datafinder.core.configuration.properties import domain from datafinder.core.configuration.properties import property_type __version__ = "$Revision-Id:$" class _City(domain.DomainObject): name = domain.DomainProperty(property_type.StringType(), "", "City Name", "Name of the city.") zip = domain.DomainProperty(property_type.StringType(), "", "ZIP", "The postal code of the city.") class _Address(domain.DomainObject): street = domain.DomainProperty(property_type.StringType(), "", "Street", "This is the street name.") streetNumber = domain.DomainProperty(property_type.NumberType(), None, "Street Number", "This is the street number.") city = domain.DomainProperty(property_type.DomainObjectType(_City), _City(), "City", "This is the city.") class _Author(domain.DomainObject): name = domain.DomainProperty(property_type.StringType(), None, "Name", "This is the author name") mainAddress = domain.DomainProperty(property_type.DomainObjectType(_Address), _Address(), "Addresses", "The main address.") addresses = domain.DomainProperty(property_type.ListType([property_type.DomainObjectType(_Address)]), None, "Addresses", "These are additional addresses.") def __init__(self, name="", mainAddress=None, addresses=None): domain.DomainObject.__init__(self) self.name = name if not mainAddress is None: self.mainAddress = mainAddress if not addresses is None: self.addresses = addresses @name.setValidate def _validateName(self): if self.name is None or len(self.name) == 0: raise ValueError("Name should not be empty.") class DomainObjectTestCase(unittest.TestCase): """ Tests behavior of domain objects and properties. """ def testDomainPropertyRepresentation(self): domainProperty = domain.DomainProperty(property_type.StringType()) self.assertEquals(repr(domainProperty), ": String\n") def testDomainObjectRepresentation(self): self.assertEquals(repr(_City()), "name: '' zip: ''") self.assertEquals(repr(domain.DomainObject()), "") def testValueAccess(self): """ Tests how to set and get values from the domain property. """ anAuthor = _Author("Marc") anAuthor.mainAddress.street = "New Street" anotherAuthor = _Author("Pierre") anotherAuthor.mainAddress.city.name = "Paris" self.assertEquals(anAuthor.name, "Marc") self.assertEquals(anAuthor.mainAddress.street, "New Street") self.assertEquals(anotherAuthor.name, "Pierre") self.assertEquals(anotherAuthor.mainAddress.city.name, "Paris") def testWalk(self): """ Tests retrieval of descriptive information of a property. """ anAuthor = _Author("Pierre") for counter, propertyInfo in enumerate(anAuthor.walk()): instance, name, descriptor, value = propertyInfo if counter == 0: self.assertEquals(instance, anAuthor) self.assertEquals(name, "addresses") self.assertEquals(descriptor, _Author.addresses) self.assertEquals(value, anAuthor.addresses) elif counter == 1: self.assertEquals(instance, anAuthor) self.assertEquals(name, "mainAddress") self.assertEquals(descriptor, _Author.mainAddress) self.assertEquals(value, anAuthor.mainAddress) else: self.assertEquals(instance, anAuthor) self.assertEquals(name, "name") self.assertEquals(descriptor, _Author.name) self.assertEquals(value, anAuthor.name) def testWalkRecursively(self): anAuthor = _Author("Arthur") fullPropertyInfo = [propertyInfo for propertyInfo in anAuthor.walk(True)] self.assertEquals(len(fullPropertyInfo), 8) def testValidate(self): anAuthor = _Author("Arthur") anAuthor.validate() anAuthor.name = "" self.assertRaises(ValueError, anAuthor.validate) def testComparison(self): author = _Author("me") other = _Author("you") self.assertNotEquals(author, other) self.assertNotEquals(hash(author), hash(other)) other.name = "me" # make them equal self.assertEquals(author, other) self.assertEquals(hash(author), hash(other)) # Empty domain objects self.assertEquals(domain.DomainObject(), domain.DomainObject()) self.assertEquals(hash(domain.DomainObject()), hash(domain.DomainObject())) # Compare two different domain objects self.assertNotEquals(author, author.mainAddress) self.assertNotEquals(hash(author), hash(author.mainAddress))
{ "repo_name": "DLR-SC/DataFinder", "path": "test/unittest/datafinder_test/core/configuration/properties/domain_test.py", "copies": "1", "size": "6804", "license": "bsd-3-clause", "hash": -7360320935092129000, "line_mean": 41.3375796178, "line_max": 127, "alpha_frac": 0.6578483245, "autogenerated": false, "ratio": 4.401034928848642, "config_test": true, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.014976302783557015, "num_lines": 157 }
""" Tests the repository path filter. """ import unittest from datafinder.gui.user.models.repository.filter.path_filter import PathFilter from datafinder_test.gui.user.mocks import BaseRepositoryMock, BaseItemMock __version__ = "$Revision-Id$" class PathFilterTest(unittest.TestCase): """ Tests of the repository path filter """ def setUp(self): """ Creates the repository and the filter. """ self._items = [BaseItemMock("/test/another"), BaseItemMock("/jepp/here")] self._repositoryModel = BaseRepositoryMock(self._items) self._pathFilter = PathFilter(self._repositoryModel) # Checking number of children of the root index self.assertEquals(self._repositoryModel.rowCount(), 2) self.assertEquals(self._pathFilter.rowCount(), 0) def testFiltering(self): """ Tests the different filter cases. """ # Restrict to the first item self._pathFilter.item = self._items[0] self.assertEquals(self._pathFilter.rowCount(), 1) index = self._pathFilter.indexFromPath("/test") self.assertEquals(self._pathFilter.nodeFromIndex(index).path, "/test") # Restrict to the second item self._pathFilter.item = self._items[1] self.assertEquals(self._pathFilter.rowCount(), 1) index = self._pathFilter.indexFromPath("/jepp") self.assertEquals(self._pathFilter.nodeFromIndex(index).path, "/jepp") # Restrict to a non-existing item self._pathFilter.item = BaseItemMock("/unknown") self.assertEquals(self._pathFilter.rowCount(), 0) # Restrict to "None" self._pathFilter.item = None self.assertEquals(self._pathFilter.rowCount(), 0)
{ "repo_name": "DLR-SC/DataFinder", "path": "test/unittest/datafinder_test/gui/user/model/repository/filter/path_filter_test.py", "copies": "1", "size": "3523", "license": "bsd-3-clause", "hash": -4308317416171051500, "line_mean": 38.4942528736, "line_max": 81, "alpha_frac": 0.6906045984, "autogenerated": false, "ratio": 4.144705882352941, "config_test": true, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.01641673558264434, "num_lines": 87 }
""" This module provides an annotation to make methods observable.. """ import logging __version__ = "$Revision-Id:$" _log = logging.getLogger("script") class Observable(object): """ Implements the observable annotation for bound methods, static methods and class methods. """ def __init__(self, method): """ Takes a method and makes it observable by another object. """ # pylint: disable=C0103 # C0103: __doc__ is a special method so it's name is fine. self.classObservable = None # Class-specific observable instance, None-> it is the class-spcific one self.callbacks = list() # List of observer functions / methods self.instance = None # Instance the method is bound to self.method = method # Method that is observed self.__doc__ = self.method.__doc__ # Documentation self.cls = None try: self.name = " " + method.__name__ # Name that is used to attach callbacks to the instances except AttributeError: self.name = None def __add__(self, callback): """ Registering a callback function which is called after method invocation. @param callback: Function that is supposed to be called on firing the event. @type callback: Function object which receives the following arguments: args: Arguments the observed method received. kwargs: Keyword arguments the observed method received. returnValue: The returned value of the observed method. error: Error which may be raised by the observed method. """ if not callback in self.callbacks: self.callbacks.append(callback) return self def __sub__(self, callback): """ Removes the callback function from the observed method. @param callback: Function that has been formerly registered. @raise ValueError: If the callback function has not been registered before. """ self.callbacks.remove(callback) return self def __call__(self, *args, **kwargs): """ Calls the observed method and handles callback notification. """ # pylint: disable=W0703, E0702 #W0703: Catching Exception is fine as this is a generic notification code and we re-raise #the exception. #E0702: It is ensured the error is not None before the error is re-raised. error = None returnValue = None # call the method and handle error try: if not hasattr(self.method, "__call__"): methodToCall = self.method.__get__(self.instance, self.cls) returnValue = methodToCall(*args, **kwargs) else: if self.instance is None: # Simulate standard error if the instance is None returnValue = self.method(*args, **kwargs) returnValue = self.method(self.instance, *args, **kwargs) except Exception, error_: error = error_ # call back if not self.classObservable is None: # Call all class-specific callbacks for callback in self.classObservable.callbacks: callback(args, kwargs, returnValue, error) for callback in self.callbacks: # Call the instance-specific callbacks callback(args, kwargs, returnValue, error) # Raise error if exists if not error is None: raise error return returnValue def __get__(self, instance, cls): """ Returns the wrapped observed method. """ observable = self #if instance is None the method is called from the class object self.instance = instance self.cls = cls if not instance is None and not self.name is None: try: observable = self.instance.__dict__[self.name] # Retrieve the cached observable from the instance properties except KeyError: # Create a new observable if it not exists observable = Observable(self.method) observable.classObservable = self observable.cls = cls observable.instance = instance self.instance.__dict__[self.name] = observable return observable
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/common/event_observer.py", "copies": "1", "size": "6280", "license": "bsd-3-clause", "hash": 7228231272687543000, "line_mean": 39.5894039735, "line_max": 124, "alpha_frac": 0.6272292994, "autogenerated": false, "ratio": 4.7467876039304615, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5874016903330461, "avg_score": null, "num_lines": null }
""" Constant definitions for connection handling. """ __version__ = "$Revision-Id$" # Constants for connection pooling MAX_POOL_NUMBER = 10 MAX_CONNECTION_NUMBER = 1 WIN32 = "win32" UTF8 = "UTF-8" LC_ALL = "LC_ALL" LINK_TARGET_PROPERTY_NAME = "datafinder:____LINK____" JSON_PROPERTY_NAME = "datafinder:json"
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/persistence/adapters/svn/constants.py", "copies": "1", "size": "1977", "license": "bsd-3-clause", "hash": -8430896743928244000, "line_mean": 35.6111111111, "line_max": 72, "alpha_frac": 0.756196257, "autogenerated": false, "ratio": 3.9226190476190474, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.017759625684382493, "num_lines": 54 }
""" Handles open and print actions of items. Currently it only works on Windows """ import os import logging import subprocess try: # pylint: disable=E0611,F0401 # E0611: "shell" exists in win32com but Pylint cannot detect it. # F0401: "win32com.shell" exists but Pylint cannot import. import pywintypes from win32com.shell import shell, shellcon from win32event import WaitForSingleObject, INFINITE _isWin32 = True except ImportError: _isWin32 = False from datafinder.core.error import ItemError from datafinder.gui.user.constants import LOGGER_ROOT from datafinder.gui.user.common.util import startNewQtThread __version__ = "$Revision-Id:$" class FileActionHandler(object): """ Handles open and print actions of items. Currently it only works on WIndows systems. """ _OPEN_COMMAND = "open" _PRINT_COMMAND = "print" _DF_DEFAULT_FILE_VIEWER_ENV = "DF_DEFAULT_FILE_VIEWER" _DF_DEFAULT_LINUX_VIEWER = "evince" _MAX_WORKER_THREADS = 30 _logger = logging.getLogger(LOGGER_ROOT) def __init__(self): """ Constructor. """ self._checkUntilClosedWorker = dict() def performOpen(self, item): """ Opens the file content of the associated item in a suitable external application. @param item: Item which is opened. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} """ self._performFileAction(item, self._OPEN_COMMAND) def performPrint(self, item): """ Prints the file content of the associated item. @param item: Item which is opened. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} """ self._performFileAction(item, self._PRINT_COMMAND) def _performFileAction(self, item, command): """ Performs the given command on the specific file. """ print _isWin32 if _isWin32: self._performFileActionWin32(item, command) else: if self._OPEN_COMMAND: # Run a default viewer defaultViewer = os.environ.get(self._DF_DEFAULT_FILE_VIEWER_ENV , self._DF_DEFAULT_LINUX_VIEWER) localContentPath, _ = self._getContent(item) try: subprocess.Popen((defaultViewer, localContentPath)) except OSError, error: raise ItemError("Cannot open file. Reason: '%s'" % str(error)) else: raise ItemError("Printing is not supported on this platform!") def _performFileActionWin32(self, item, command): """ Performs the given command on the specific file. """ # pylint: disable=E1101 # E1101: Pylint cannot resolve specific win32 modules. localContentPath, alreadyLocal = self._getContent(item) print localContentPath, alreadyLocal if not alreadyLocal and len(self._checkUntilClosedWorker) == self._MAX_WORKER_THREADS: errorMessage = "The maximum number (%i) of parallel opened editors " % self._MAX_WORKER_THREADS \ + "has been reached. Please close at least one external application." raise ItemError(errorMessage) fMask = 0 if not alreadyLocal: fMask = shellcon.SEE_MASK_NOCLOSEPROCESS try: result = shell.ShellExecuteEx(fMask, 0, command, localContentPath, "", "", 1) except pywintypes.error: return else: if not alreadyLocal: workerId = str(result["hProcess"]) worker = startNewQtThread(self._checkUntilClosed, self._createCheckUntilClosedCallback(workerId), result["hProcess"], command == self._OPEN_COMMAND, item, localContentPath) self._checkUntilClosedWorker[workerId] = worker @staticmethod def _checkUntilClosed(processHandle, writeBack, item, localContentPath): """ Waits until the opened application is closed, writes data back, and removes the temporary file. """ startModificationTime = os.path.getmtime(localContentPath) WaitForSingleObject(processHandle, INFINITE) finalModificationTime = os.path.getmtime(localContentPath) if writeBack and startModificationTime != finalModificationTime: if item.capabilities.canStoreData: fh = open(localContentPath, "rb") item.storeData(fh) os.remove(localContentPath) def _createCheckUntilClosedCallback(self, workerId): """ Creates a callback function performs the clean up actions. """ def _callback(): if workerId in self._checkUntilClosedWorker: try: worker = self._checkUntilClosedWorker[workerId] if not worker.error is None: self._logger.error(worker.error.message) finally: del self._checkUntilClosedWorker[workerId] return _callback @staticmethod def _getContent(item): """ Retrieves the file content of the associated item and returns its local path. """ dataUri = item.dataUri print item.dataUri if not item.isManaged and dataUri.startswith("file://"): # directly accessible localContentPath = dataUri[8:] temporaryFileObject = None else: # get temporary file localContentPath, temporaryFileObject = item.getTemporaryFileObject(False) temporaryFileObject.close() return localContentPath, temporaryFileObject is None
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/user/common/fileaction_handler.py", "copies": "1", "size": "7438", "license": "bsd-3-clause", "hash": 320158599997421200, "line_mean": 38.5638297872, "line_max": 116, "alpha_frac": 0.6524603388, "autogenerated": false, "ratio": 4.383028874484384, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.024227822893806653, "num_lines": 188 }
""" Implements adapter for manipulating a SVN file system. """ import logging import os import shutil from datafinder.persistence.error import PersistenceError from datafinder.persistence.adapters.svn.error import SubversionError from datafinder.persistence.adapters.svn import constants from datafinder.persistence.adapters.svn.util import util from datafinder.persistence.data.datastorer import NullDataStorer __version__ = "$Revision-Id$" _BLOCK_SIZE = 30000 _log = logging.getLogger() class DataSubversionAdapter(NullDataStorer): """ An adapter instance represents an item within the SVN file system. """ def __init__(self, identifier, connectionPool): """ Constructor. @param identifier: Logical identifier of the resource. @type identifier: C{unicode} @param connectionPool: Connection pool. @type connectionPool: L{Connection<datafinder.persistence.svn. connection_pool.SVNConnectionPool>} """ NullDataStorer.__init__(self, identifier) self._connectionPool = connectionPool @property def linkTarget(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ connection = self._connectionPool.acquire() try: return connection.getProperty( self.identifier, constants.LINK_TARGET_PROPERTY_NAME) except SubversionError: try: self._updateParentItem(connection) return connection.getProperty( self.identifier, constants.LINK_TARGET_PROPERTY_NAME) except SubversionError: return None finally: self._connectionPool.release(connection) def _updateParentItem(self, connection): parentId = util.determineParentPath(self.identifier) connection.update(parentId) @property def isLink(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ return not self.linkTarget is None @property def isLeaf(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ return self._determinItemKind(False) def _determinItemKind(self, checkCollectionKind=True): connection = self._connectionPool.acquire() if checkCollectionKind: checkMethod = connection.isCollection else: checkMethod = connection.isLeaf # Perform the check try: return checkMethod(self.identifier) except SubversionError: try: self._updateParentItem(connection) return checkMethod(self.identifier) except SubversionError, error: errorMessage = u"Cannot determine resource type of '%s'. Reason: '%s'" \ % (self.identifier, error) raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) @property def isCollection(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ return self._determinItemKind() @property def canAddChildren(self): """ @see L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ return self.isCollection def createLink(self, destination): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ self.createResource() connection = self._connectionPool.acquire() try: connection.update(self.identifier) connection.setProperty(self.identifier, constants.LINK_TARGET_PROPERTY_NAME, destination.identifier) except SubversionError, error: errorMessage = u"Cannot set property. Reason: '%s'" % error raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) def createResource(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ connection = self._connectionPool.acquire() path = connection.workingCopyPath + self.identifier try: self._updateParentItem(connection) if not os.path.exists(path): self._createLocalFile(path) else: if os.path.isdir(path): shutil.rmtree(path) self._createLocalFile(path) connection.add(self.identifier) connection.checkin(self.identifier) except OSError, error: errorMessage = os.strerror(error.errno) raise PersistenceError(errorMessage) except SubversionError, error: errorMessage = u"Cannot create resource '%s'. Reason: '%s'" % (self.identifier, error) raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) @staticmethod def _createLocalFile(path): try: fd = open(path, "wb") fd.close() except IOError, error: errorMessage = os.strerror(error.errno) raise PersistenceError(errorMessage) def createCollection(self, recursively=False): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ if recursively: parent = self._getParent() if not parent.exists() and parent.identifier != "/": parent.createCollection(True) connection = self._connectionPool.acquire() path = connection.workingCopyPath + self.identifier try: self._updateParentItem(connection) if not os.path.exists(path): self._createLocalDirectory(path) else: if not os.path.isdir(path): os.remove(path) self._createLocalDirectory(path) connection.add(self.identifier) connection.checkin(self.identifier) except OSError, error: errorMessage = os.strerror(error.errno) raise PersistenceError(errorMessage) except SubversionError, error: errorMessage = u"Cannot create collection '%s'. Reason: '%s'" \ % (self.identifier, error) raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) @staticmethod def _createLocalDirectory(path): os.mkdir(path) def _getParent(self): """ Helper which create the parent data storer. """ parentId = util.determineParentPath(self.identifier) return DataSubversionAdapter(parentId, self._connectionPool) def getChildren(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ connection = self._connectionPool.acquire() try: return connection.getChildren(self.identifier) except SubversionError, error: errorMessage = u"Cannot retrieve children of item '%s'. Reason: '%s'" \ % (self.identifier, error) raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) def writeData(self, dataStream): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ connection = self._connectionPool.acquire() try: connection.update(self.identifier) fd = open(connection.workingCopyPath + self.identifier, "wb") try: block = dataStream.read(_BLOCK_SIZE) while len(block) > 0: fd.write(block) block = dataStream.read(_BLOCK_SIZE) finally: fd.close() dataStream.close() connection.checkin(self.identifier) except SubversionError, error: errorMessage = u"Unable to write data to '%s'. " % self.identifier + \ u"Reason: %s" % error raise PersistenceError(errorMessage) except IOError, error: errorMessage = os.strerror(error.errno) raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) def readData(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ connection = self._connectionPool.acquire() try: connection.update(self.identifier) return open(connection.workingCopyPath + self.identifier, "rb") except IOError, error: errorMessage = os.strerror(error.errno) raise PersistenceError(errorMessage) except SubversionError, error: errorMessage = u"Unable to read data from '%s'. " % self.identifier + \ u"Reason: %s" % error raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) def delete(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ connection = self._connectionPool.acquire() try: connection.delete(self.identifier) except SubversionError, error: errorMessage = u"Unable to delete item '%s'. " % self.identifier \ + u"Reason: %s" % error raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) def move(self, destination): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ self.copy(destination) self.delete() def copy(self, destination): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ connection = self._connectionPool.acquire() try: connection.copy(self.identifier, destination.identifier) except SubversionError, error: errorMessage = u"Unable to copy item '%s' to '%s'. " \ % (self.identifier, destination.identifier) \ + u"Reason: %s" % error raise PersistenceError(errorMessage) finally: self._connectionPool.release(connection) def exists(self): """ @see: L{NullDataStorer<datafinder.persistence.data.datastorer.NullDataStorer>} """ connection = self._connectionPool.acquire() try: self._updateParentItem(connection) connection.info(self.identifier) return True except SubversionError: return False finally: self._connectionPool.release(connection)
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/persistence/adapters/svn/data/adapter.py", "copies": "1", "size": "12884", "license": "bsd-3-clause", "hash": -7471517959180663000, "line_mean": 37.6906906907, "line_max": 98, "alpha_frac": 0.6226327228, "autogenerated": false, "ratio": 4.606363961387201, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.015176835798231769, "num_lines": 333 }
""" Implements utility functionality for accessing a Subversion repositories. This implementation works with CPython and is based on C[pysvn}. """ import locale import logging import os import pysvn import sys import threading # pylint: disable=E0611 # E0611: pylint could not resolve ClientError. from pysvn import ClientError from datafinder.persistence.error import PersistenceError from datafinder.persistence.adapters.svn import constants from datafinder.persistence.adapters.svn.error import SubversionError from datafinder.persistence.adapters.svn.util.util import pepareSvnPath __version__ = "$Revision-Id$" _logger = logging.getLogger() class CPythonSubversionWrapper(object): """ Implements CPython specific utility class for accessing SVN repositories. """ def __init__(self, repositoryUri, workingCopyPath, username, password, sharedState): """ Initializes the pysvn client for repository access and performs the initial checkout if it does not already exist. """ self._username = username self._password = password self._workingCopyPath = workingCopyPath self._workingPathLength = len(workingCopyPath) self._sharedState = sharedState self._client = pysvn.Client() self._client.exception_style = 1 # errors have tuple args: (full msg, list((msg, error code))) self._loginTries = 0 self._client.callback_get_login = self._getLogin self._client.callback_get_log_message = lambda: (True, "") self._client.callback_ssl_server_trust_prompt = \ lambda trustData: (True, trustData["failures"], True) self._repositoryUri = repositoryUri def _getLogin(self, _, __, ___): """ Provides the login information for the pysvn client. """ if self._loginTries > 0: return (False, "", "", False) else: self._loginTries += 1 return (True, self._username, self._password, False) def initializeWorkingCopy(self): """ Checks the working copy out if it does not exist. """ try: if not os.path.exists(self._workingCopyPath): self._client.checkout(self._repositoryUri, self._workingCopyPath) except ClientError, error: raise PersistenceError(error) def isLeaf(self, path): """ Indicates whether the item is a file or not. """ # pylint: disable=E1101 # E1101: pylint could not resolve the node_kind attribute. return self._determineItemKind(path, pysvn.node_kind.file) def isCollection(self, path): """ Indicates whether the item is a directory or not. """ # pylint: disable=E1101 # E1101: pylint could not resolve the node_kind attribute. return self._determineItemKind(path, pysvn.node_kind.dir) def _determineItemKind(self, path, kind): """ Determines whether the item is of the given kind. """ # pylint: disable=E1101 # E1101: pylint could not resolve the node_kind attribute. entry = self._determineInfo(path) return entry.kind == kind def update(self, path): """ Updates the working copy. This method is synchronized among different connections. The update call also restores accidently deleted files (mode: infinity). """ # pylint: disable=E1101 # E1101: pylint could not resolve the depth attribute. self._sharedState.lock.acquire() try: try: self._client.cleanup(self.workingCopyPath) self._client.revert(self._workingCopyPath + path, True) self._client.update(self._workingCopyPath + path, depth=pysvn.depth.infinity ) except ClientError, error: raise SubversionError(error) finally: self._sharedState.lock.release() def checkin(self, path): """ Commits changes of the item identified with C{path}. It also ensures that existing conflicts are resolved. """ try: self._client.checkin(self._workingCopyPath + path, "") except ClientError, error: raise SubversionError(error) else: self._sharedState.removeFromCache(path) def add(self, path): """ Adds a new file/directory to the working copy. """ try: self._client.add(self._workingCopyPath + path, recurse=True) except ClientError, error: raise SubversionError(error) def delete(self, path): """ Removes a file or directory from the repository. It works directly on the server, i.e. no call to C{checkin} is required. The cached information of the item all removed as well. """ try: self._client.remove(self._getEncodedUri(path), force=True) except ClientError, error: raise SubversionError(error) else: self._sharedState.removeFromCache(path) def _getEncodedUri(self, path): """ Helper method - First the path is encoded to UTF-8 and then the special characters are quoted. It returns the full repository URI. It assumes that the repository URI is already in the correctly quoted and encoded format. """ return self._repositoryUri + pepareSvnPath(path) def copy(self, path, destinationPath): """ The copying process is directly performed on the SVN server. """ try: self._client.copy(self._getEncodedUri(path), self._getEncodedUri(destinationPath)) except ClientError, error: raise SubversionError(error) def setProperty(self, path, key, value): """ Sets the property of a file or directory. @param key: Name of the property. @type key: C{unicode} @param value: Value of the property. @type value: C{unicode} """ try: self._client.propset(key, value, self._workingCopyPath + path) self.checkin(path) except ClientError, error: raise SubversionError(error) def getProperty(self, path, name): """ Gets the property value of a file or directory. @param name: Name of the property. @type name: C{unicode} @rtype: C{unicode} """ # pylint: disable=E1101 # E1101: pylint could not resolve the Revision attribute. result = None fullWorkingPath = (self._workingCopyPath + path).encode(constants.UTF8) try: propertyValues = self._client.propget( name, fullWorkingPath, revision=pysvn.Revision(pysvn.opt_revision_kind.working), depth=pysvn.depth.empty) if fullWorkingPath in propertyValues: result = unicode(propertyValues[fullWorkingPath], constants.UTF8) except ClientError, error: raise SubversionError(error) else: return result def getChildren(self, path): """ Determines the direct children of the given directory. In prior an update is performed. The retrieved information are cached. This method is synchronized among different connections. """ self._sharedState.lock.acquire() try: try: self.update(path) children = list() entries = self._client.list(self._workingCopyPath + path, recurse=False) for entry in entries: entryPath = entry[0].path[self._workingPathLength:] formerEntry = self._sharedState.getFromCache(path) if formerEntry is None: newEntry = _Info(entry[0]) else: newEntry = _Info(entry[0]) newEntry.logMessage = formerEntry.logMessage # creation date and owner do not change self._sharedState.addToCache(entryPath, newEntry) children.append(entryPath) del children[0] # First item is always the queried path return children except ClientError, error: raise SubversionError(error) finally: self._sharedState.lock.release() def info(self, path): """ Returns a C{dict} holding the information about: - "lastChangedDate", "size", "owner", "creationDate". """ # pylint: disable=E1101 # E1101: pylint could not resolve the opt_revision_kind attribute. info = self._determineInfo(path) if info.logMessage is None: # determine creation date and owner try: info.logMessage = self._client.log( self._workingCopyPath + path, revision_start=pysvn.Revision(pysvn.opt_revision_kind.number, 1), revision_end=pysvn.Revision(pysvn.opt_revision_kind.head), limit=1)[0] except ClientError, error: raise SubversionError(error) result = dict() result["lastChangedDate"] = str(info.lastChangedDate) result["size"] = str(info.size) result["owner"] = info.owner result["creationDate"] = str(info.creationTime) return result def _determineInfo(self, path): """ Retrieves the entry information and puts it into the cache or uses the cached information. """ entry = self._sharedState.getFromCache(path) if entry is None: try: entry = self._client.list(self._workingCopyPath + path, recurse=False)[0][0] entry = _Info(entry) self._sharedState.addToCache(path, entry) return entry except ClientError, error: raise SubversionError(error) return entry @property def canBeAccessed(self): """ Checks whether the SVN repository can be accessed. """ try: self._client.log(self._repositoryUri) return True except ClientError, error: _logger.debug(error.args[0]) for _, errorCode in error.args[1]: if errorCode == 160006: # We have no commit in the repository, but its ok. return True return False @property def workingCopyPath(self): """ Returns local working copy path. """ return self._workingCopyPath class _Info(object): """ Represents the information of a single item. """ def __init__(self, entry): """ Uses a C{PysvnList} and pysvn log message dictionaries as basis and provides a common interface. """ self.lastChangedDate = entry.time self.size = entry.size self.kind = entry.kind self.logMessage = None @property def creationTime(self): """ Float time - the date of the first commit. """ if not self.logMessage is None : return self.logMessage["date"] @property def owner(self): """ Author of the first commit. """ if not self.logMessage is None: return self.logMessage["author"] class _SharedState(object): """ Holds the synchronization information. This includes a shared lock and a thread-safe cache for sharing item information. Items are identified by the their path relative to the repository working copy.""" # Doc strings add no value: pylint: disable=C0111 def __init__(self): self._lock = threading.RLock() self._cache = dict() self.lock = threading.RLock() def addToCache(self, path, info): self._lock.acquire() try: self._cache[path] = info finally: self._lock.release() def getFromCache(self, path): self._lock.acquire() try: if path in self._cache: return self._cache[path] finally: self._lock.release() def removeFromCache(self, path): self._lock.acquire() try: for key in self._cache.keys(): if key.startswith(path): del self._cache[key] finally: self._lock.release() # Used to synchronize repository-specific connections # which are working on ONE working copy _repositoryUriSharedStateMap = dict() def createCPythonWrapper(repositoryUri, workingCopyPath, username, password): """ Factory method for safe creation of SVN connections. Adds specific shared shared state to synchronize work of different connection instances. @note: It is expected that the calling client code ensures thread-safety. E.g., by using the default connection pool for connection creation. """ if repositoryUri in _repositoryUriSharedStateMap: sharedState = _repositoryUriSharedStateMap[repositoryUri] else: sharedState = _SharedState() _repositoryUriSharedStateMap[repositoryUri] = sharedState return CPythonSubversionWrapper(repositoryUri, workingCopyPath, username, password, sharedState) def _initializeLocale(): """ Initializes encoding information of C{locale} module. """ if sys.platform == constants.WIN32: locale.setlocale(locale.LC_ALL, "") else: if constants.LC_ALL in os.environ: try: locale.setlocale(locale.LC_ALL, os.environ[constants.LC_ALL]) return except locale.Error: # First try did not work, encoding must be set first then set locale. pass languageCode, encoding = locale.getdefaultlocale() if languageCode is None: languageCode = "en_US" # Set the encoding of the Python environment if no encoding is set. if encoding is None: encoding = constants.UTF8 if encoding.lower() == "utf": encoding = constants.UTF8 try: locale.setlocale(locale.LC_ALL, "%s.%s" % (languageCode, encoding)) except locale.Error: try: locale.setlocale(locale.LC_ALL, "en_US.UTF-8") except locale.Error: locale.setlocale(locale.LC_ALL, "C") _initializeLocale() # Just once executed when the module is imported
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/persistence/adapters/svn/util/cpython.py", "copies": "1", "size": "16521", "license": "bsd-3-clause", "hash": -4869766722680992000, "line_mean": 35.7951002227, "line_max": 108, "alpha_frac": 0.6102536166, "autogenerated": false, "ratio": 4.6083682008368205, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.01899111075215627, "num_lines": 449 }
""" Edit dialog to change authentification information such as url, username, password, ldap support """ from PyQt4 import QtGui from datafinder.gui.gen.user.authentification_edit_wizard_ui import Ui_editAuth from datafinder.gui.user.dialogs.authentification_dialog.auth_pref_dialog import AuthPrefDialogView __version__ = "$Revision-Id:$" class AuthEditDialogView(QtGui.QDialog, Ui_editAuth): """ This dialog provides an interface to change credentials that belong to a specified connection """ def __init__(self, parent=None, preferences=None, currentUri = None): """ Constructor. @param parent: Parent window of this L{QtGui.QDialog} @type parent: C{QtGui.QWidget} @param preferences: The preferences object. @type preferences: L{PreferencesHandler<datafinder.core.configuration.preferences.PreferencesHandler>} """ QtGui.QDialog.__init__(self, parent) Ui_editAuth.__init__(self) self.setupUi(self) self._preferences = preferences self.savePasswordFlag = False self._urlChangedSlot(currentUri) def _urlChangedSlot(self, newUri): """ Implementing changing of connection URI. """ self.currenturi = unicode(newUri) connection = self._preferences.getConnection(self.currenturi) if not connection is None: self.username = connection.username self.authentification = connection.password self.savePasswordFlag = not connection.password is None def _getUrl(self): """ Returns the entered url. @return: The url that was entered in the combobox. @rtype: C{string} """ return unicode(self.serverLineEdit.text()) def _setUrl(self, urls): """ Appends urls to the L{QtGui.QComboBox} widget. @param urls: A list of urls that has to be added. @type urls: C{list} """ self.serverLineEdit.setText(urls) def _getUsername(self): """ Returns the username that was entered by the user. @return: The username that was entered. @rtype: C{string} """ return unicode(self.usernameLineEdit.text()) def _setUsername(self, username): """ Set a string that in the username field. @param username: The username that has to be in the username field. @type username: C{string} """ self.usernameLineEdit.setText(username or "") def _getAuthentification(self): """ Returns the authentification information from the password/certificate location field. @return: Returns the authentification information in the password field. @rtype: C{string} """ return unicode(self.passwordLineEdit.text()) def _setAuthentification(self, authentification): """ Sets the password/credentials link in the credentials field. @param authentification: The credential information that has to be in the password/certificate location field. @type authentification: C{string} """ self.authLineEdit.setText(authentification or "") def _getAuthMechanism(self): """ Returns the authentification mechanism from the authentification mechanism field. @return: Returns the authentificationMechanism in the authentification mechanism field. @rtype: C{string} """ return unicode(self.authMechanismCombo.text()) def _setAuthMechanism (self, authMechanism): """ Sets the authentification mechanism from the authentification mechanism field. @param: Integer to the password field. @rtype: C{string} """ self.authMechanismCombo.setCurrentIndex(authMechanism) def _getComment(self): """ Returns the comment from the comment field. @return: Returns the comment in the comment field. @rtype: C{string} """ return unicode(self.commentPlainText.text()) def _setComment(self, comment): """ Sets the comment from the comment field. @param: Sets the comment in the comment field. @rtype: C{string} """ self.commentPlainText.setPlainText(comment) currenturi = property(_getUrl, _setUrl) username = property(_getUsername, _setUsername) authentification = property(_getAuthentification, _setAuthentification) authMechanism = property (_getAuthMechanism, _setAuthMechanism) comment = property (_getComment, _setComment ) def _preferencesActionSlot(self): """ Shows the preferences dialog for connection settings. """ preferencesDialog = AuthPrefDialogView(self) preferencesDialog.useLdap = self._preferences.useLdap preferencesDialog.ldapBaseDn = self._preferences.ldapBaseDn preferencesDialog.ldapServerUri = self._preferences.ldapServerUri if preferencesDialog.exec_() == QtGui.QDialog.Accepted: self._preferences.useLdap = preferencesDialog.useLdap self._preferences.ldapBaseDn = preferencesDialog.ldapBaseDn self._preferences.ldapServerUri = preferencesDialog.ldapServerUri
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/user/dialogs/authentification_dialog/auth_edit_dialog.py", "copies": "1", "size": "7236", "license": "bsd-3-clause", "hash": -2219658480908236800, "line_mean": 32.9565217391, "line_max": 118, "alpha_frac": 0.6578220011, "autogenerated": false, "ratio": 4.50560398505604, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.01406964676355335, "num_lines": 207 }
""" This module contains utility classes for the datafinder. """ from datetime import datetime from decimal import Decimal import functools import logging import sys import types from PyQt4 import QtCore from datafinder.core.configuration.properties.constants import SIZE_ID, CONTENT_SIZE_ID __version__ = "$Revision-Id:$" class _PyQtThread(QtCore.QThread): """ Helper class for creating a L{QtCore.QThread} object that acts like a python thread. """ def __init__(self, function, callbacks, *args, **kwargs): """ Constructor. @param function: Function that has to be called in a separate thread. @type function: C{function} @param callbacks: The functions that have to be called after the thread termination. @type callbacks: C{list} of C{function} @param *args: Additional parameters for the function. @type *args: C{list} @param **kwargs: Additional parameters for the function. @type **kwargs: C{dict} """ QtCore.QThread.__init__(self, None) self.result = None self.error = None self.__function = function self.__args = args[:] self.__kwargs = kwargs.copy() for callback in callbacks: if not callback is None: self.connect(self, QtCore.SIGNAL("finished()"), callback) def run(self): """ @see: L{run<PyQt4.QtCore.QThread.run>} """ # pylint: disable=E1101, W0703 # E1101: "pythoncom" has a "CoInitialize" member but Pylint cannot detect it. # W0703: Here it is fine to catch Exception as this is a generic thread implementation # and the error is later available to the client code. if sys.platform == "win32": import pythoncom pythoncom.CoInitialize() try: try: self.result = self.__function(*self.__args, **self.__kwargs) except Exception, error: self.error = error finally: if sys.platform == "win32": pythoncom.CoInitialize() def __del__(self): """ Cleans up the thread. """ self.deleteLater() def startNewQtThread(function, callback, *args, **kwargs): """ Starts a new qt thread instance with the given function. After the thread is finished the callback will be called. Result/error can be retrieved from the thread instance using the attributes C{result} / C{error}. @param function: The function that has to be executed in a separated thread. @type function: C{function} @param callback: The function that has to be called after thread has finished. @type callback: C{function} @param *args: Additional parameters for the function. @type *args: C{list} @param **kwargs: Additional parameters for the function. @type **kwargs: C{dict} @return: Returns the L{QtCore.QThread} instance that is working. @rtype: C{QtCore.QThread} """ if not hasattr(callback, "__iter__"): callback = [callback] qtThread = _PyQtThread(function, callback, *args, **kwargs) qtThread.start() return qtThread class StartInQtThread(object): """ Decorator class to ease threading. """ _workers = list() def __init__(self, callback=None): """ @param callback: callback function to call after the decorated function is finished """ self.callback = callback def __call__(self, function): """ Calls function in a new Qt thread. """ def _startInNewQtThread(*args, **kwargs): StartInQtThread._workers.append(startNewQtThread(function, self._callback, *args, **kwargs)) return _startInNewQtThread def _callback(self): """ Default callback. """ if not self.callback is None: self.callback() self._cleanup() @staticmethod def _cleanup(): """ Cleans up the internal static worker list and removes all finished threads. This internal list is needed to prevent threads from being garbage-collected. """ activeWorker = list() for worker in StartInQtThread._workers: if not worker.isFinished(): activeWorker.append(worker) else: del worker StartInQtThread._workers = activeWorker class BisectColumnHelper(object): """ Helper class that allow to insert items with the bisect module. """ def __init__(self, list_, column=0): """ Constructor. @param list_: The list that has to be wrapped by this helper class. @type list_: C{list} of C{list} objects. @param column: The index of the L{list} objects in the given list_, that has to be returned by the __getitem__ method. @type column: C{int} """ self.__list = list_ self.column = column def __getitem__(self, index): """ Returns the item of the internal 2 dimensional array at the postion index, column. A unicode object will transformed to lower characters. @param index: The index of the item that has to be returned. @type index: C{int} """ item = self.__list[index][self.column] if isinstance(item, unicode): item = item.lower() return item def __len__(self): """ Returns the length of the internal list object. @return: The length of the internal list. @rtype: C{int} """ return len(self.__list) _immediateConnectionType = "immediate" _deferredConnectionType = "deferred" def immediateConnectionDecorator(sender, signalSignature): """ Tags the function/method with specific connection information. The connection is directly established on scanning time. The sender references are determined as attributes of given sender containers. For that reason the attribute hierarchy of a sender is relative to a potential sender container. @param sender: Relative attribute hierarchy of the sender/senders. E.g. "myModel.myParent" / ["myModel.myParent", "myModel.myParent"]. @type sender: C{string} or C{list} @param signalSignature: The Qt signal signature. @type signalSignature: C{string} @return: The decorator function. @rtype: callable. """ def _wrapper(function): if not isinstance(function, types.FunctionType): #required for non-Python methods/functions function = functools.partial(function) function.sender = sender function.signalSignature = signalSignature function.connectionType = _immediateConnectionType return function return _wrapper def deferredConnectionDecorator(sender, signalSignature): """ Tags the function/method with specific connection information. The connection is not directly established on scanning time. This type of connection is established when calling C{QtConnectionDelegate.establishDeferredConnections} and the connections are removed when calling C{QtConnectionDelegate.removeDeferredConnections}. The sender references are determined as attributes of given sender containers. For that reason the attribute hierarchy of a sender is relative to a potential sender container. @param sender: Relative attribute hierarchy of the sender/senders. E.g. "myModel.myParent" / ["myModel.myParent", "myModel.myParent"]. @type sender: C{string} or C{list} @param signalSignature: The Qt signal signature. @type signalSignature: C{string} @return: The decorator function. @rtype: callable. """ def _wrapper(function): if not isinstance(function, types.FunctionType): #required for non-Python methods/functions function = functools.partial(function) function.sender = sender function.signalSignature = signalSignature function.connectionType = _deferredConnectionType return function return _wrapper class QtConnectionDelegate(object): """ This class can automatically connects a Qt sender objects (subclasses of C{QObect}) with a given Qt signal signature and a function/method which handles the signal (slot). In order to determine the connections which have to be established use the C{scan} method. This method checks all methods of the given object for tagged slot methods. For tagging slot methods the decorator function C{immediateConnectionDecorator} and C{deferredConnectionDecorator} are currently provided. """ def __init__(self, logger=None, deferredConnectionHook=None): """ Constructor. @param logger: An optional logger reference which is used for debug output. @type logger: C{logging.Logger} @param deferredConnectionHook: Function object which performs certain action on the specific sender object. Function gets the sender reference and a flag whether the sender is currently connected or not. @type deferredConnectionHook: Callable. """ self.__senderContainers = list() self.__immediateConnections = list() self.__deferredConnections = list() self.__unresolvedConnections = list() self.__logger = logger if self.__logger is None: self.__logger = logging.getLogger() self.__deferredConnectionHook = deferredConnectionHook def scan(self, obj, senderContainers): """ Scans the given object for tagged slot methods. The senders are searched in the attribute hierarchy of the given sender containers. @param obj: Object which is scanned for tagged slot methods. @type obj: C{object} @param senderContainers: List of containers which contain potential sender objects. @type senderContainers: C{list} of C{object} """ self.__senderContainers = senderContainers self.__clearConnections() for methodName in dir(obj): try: method = getattr(obj, methodName) except AttributeError: continue try: connectionType = method.connectionType qtSignal = QtCore.SIGNAL(method.signalSignature) senderNames = method.sender if isinstance(senderNames, types.StringType): senderNames = [senderNames] for senderName in senderNames: sender = self.__determineSender(connectionType, senderName, qtSignal, method) if sender is None: self.__logger.debug("Sender '%s' was not found." % method.sender) else: if connectionType == _immediateConnectionType: self.__establishConnection(sender, qtSignal, method) self.__immediateConnections.append((sender, qtSignal, method)) else: self.__deferredConnections.append((sender, qtSignal, method)) self.__logger.debug("Successfully parsed connection '%s %s %s %s %s'." \ % (connectionType, method.sender, method.signalSignature, methodName, sender)) except AttributeError: continue def __clearConnections(self): """ Disconnects all established connections and resets the internal state. """ for sender, qtSignal, slotMethod in self.__immediateConnections + self.__deferredConnections: self.__removeConnection(sender, qtSignal, slotMethod) self.__immediateConnections = list() self.__deferredConnections = list() self.__unresolvedConnections = list() def __determineSender(self, connectionType, senderName, qtSignal, slotMethod): """ Determines the sender reference. If a reference cannot be determined the the connection information will be added to C{self.__missingConnections}. """ sender = None attributeNames = senderName.split(".") senderContainers = self.__senderContainers for attributeName in attributeNames: found = False for senderContainer in senderContainers: if hasattr(senderContainer, attributeName): sender = getattr(senderContainer, attributeName) if sender is None: if not (connectionType, senderName, qtSignal, slotMethod) in self.__unresolvedConnections: self.__unresolvedConnections.append((connectionType, senderName, qtSignal, slotMethod)) self.__logger.debug("Adding '%s %s %s %s' to unresolved connections." \ % (connectionType, senderName, qtSignal, slotMethod)) found = True break if found: senderContainers = [sender] else: break return sender @staticmethod def __establishConnection(sender, qtSignal, slotMethod): """ Establishes a connection with the given parameters. """ try: success = QtCore.QObject.connect(sender, qtSignal, slotMethod) except TypeError: success = False return success @staticmethod def __removeConnection(sender, qtSignal, slotMethod): """ Removes a connection with the given parameters. """ try: success = QtCore.QObject.disconnect(sender, qtSignal, slotMethod) except TypeError: success = False return success def establishUnresolvedConnections(self): """ Connections whose sender reference was not found on scanning time are tried to be determined again. If the sender is found at this time the connection is established in accordance to its connection type. """ self.__logger.debug("Try to connect unresolved connections.") establishedMissingConnections = list() for connectionType, senderName, qtSignal, slotMethod in self.__unresolvedConnections: sender = self.__determineSender(connectionType, senderName, qtSignal, slotMethod) if not sender is None: establishedMissingConnections.append((connectionType, senderName, qtSignal, slotMethod)) self.__logger.debug("Resolved sender '%s'." % senderName) if connectionType == _immediateConnectionType: self.__establishConnection(sender, qtSignal, slotMethod) self.__immediateConnections.append([sender, qtSignal, slotMethod]) else: self.__deferredConnections.append([sender, qtSignal, slotMethod]) else: self.__logger.debug("Unable to resolve '%s'." % senderName) for establishedMissingConnection in establishedMissingConnections: self.__unresolvedConnections.remove(establishedMissingConnection) def establishDeferredConnections(self): """ Establishes all deferred connections. """ for sender, qtSignal, slotMethod in self.__deferredConnections: success = self.__establishConnection(sender, qtSignal, slotMethod) if not self.__deferredConnectionHook is None: self.__deferredConnectionHook(sender, success) def removeDeferredConnections(self): """ Removes/Disconnects all deferred connections. """ for sender, qtSignal, slotMethod in self.__deferredConnections: success = self.__removeConnection(sender, qtSignal, slotMethod) if not self.__deferredConnectionHook is None: self.__deferredConnectionHook(sender, not success) def extractPyObject(qVariant): """ Extracts the included python object from a QVariant @param qVariant: object to extract python object from @type qVariant: L{PyQt4.QtCore.QVariant} @return: the included python object """ try: objectType = qVariant.type() except AttributeError: return convertToPlainPythonObject(qVariant) if objectType == QtCore.QVariant.Double: casted = Decimal(str(qVariant.toDouble()[0])) # toDouble return a tuple (double,boolean) elif objectType == QtCore.QVariant.String: casted = qVariant.toString() casted = unicode(casted) elif objectType == QtCore.QVariant.Bool: casted = qVariant.toBool() elif objectType == QtCore.QVariant.DateTime: casted = qVariant.toDateTime() dt = casted.toPyDateTime() casted = datetime(dt.year, dt.month, dt.day, dt.hour, dt.minute, dt.second, dt.microsecond) elif objectType == QtCore.QVariant.List: casted = qVariant.toList() casted = [extractPyObject(x) for x in casted] elif objectType == QtCore.QVariant.LongLong: casted = Decimal(str(qVariant.toLongLong()[0])) # same as toDouble elif objectType == QtCore.QVariant.UserType: casted = qVariant.toPyObject() elif objectType == QtCore.QVariant.Int: casted = Decimal(str(qVariant.toInt()[0])) elif objectType == QtCore.QVariant.Date: casted = qVariant.toDate() elif qVariant.isNull(): casted = None else: raise TypeError("Unknown type. Unable to convert type: %s" % qVariant.typeName()) return convertToPlainPythonObject(casted) # lambda is fine: pylint: disable=W0108 _mappingDict = { QtCore.QString: lambda x: unicode(x), QtCore.QDateTime: lambda x: x.toPyDateTime(), QtCore.QDate: lambda x: x.toPyDate() } def convertToPlainPythonObject(qDataType): """ Converts a Qt object to a python object """ try: returnValue = _mappingDict[type(qDataType)](qDataType) except KeyError: returnValue = qDataType return returnValue def determineDisplayRepresentation(value, propertyIdentifier=None): """ Returns the display representation for the given Python value. @param value: Value that should be displayed. @type value: C{object} @param propertyIdentifier: Optional property identifier. Default: C{None} @type propertyIdentifier: C{unicode} @return: Representation of the value as human readable string. @rtype: C{unicode} """ displayRepresentation = repr(value) if isinstance(value, bool): displayRepresentation = "False" if value: displayRepresentation = "True" elif isinstance(value, datetime): displayRepresentation = value.strftime("%d.%m.%Y %H:%M:%S") elif isinstance(value, Decimal): decimalAsTuple = value.as_tuple() if propertyIdentifier in (SIZE_ID, CONTENT_SIZE_ID): displayRepresentation = str(long(value / 1024)) + " KB" elif decimalAsTuple[2] >= 0: displayRepresentation = str(long(value)) else: displayRepresentation = str(float(value)) elif isinstance(value, list): displayRepresentation = u"[" for item in value: displayRepresentation += determineDisplayRepresentation(item) + ", " if len(displayRepresentation) >= 2: displayRepresentation = displayRepresentation[:-2] + "]" else: displayRepresentation = displayRepresentation + "]" elif value is None: displayRepresentation = u"" elif isinstance(value, basestring): displayRepresentation = unicode(value) elif isinstance(value, dict): displayRepresentation = unicode(value) return displayRepresentation def determinePropertyDefinitionToolTip(propertyDefinition): """ Determines a tool tip text for the given property definition. @param propertyDefinition: Definition instance holding specific property parameter. @type propertyDefinition: L{PropertyDefinition<datafinder.core.configuration.properties.property_definition.PropertyDefinition>} @return: Tool tip text describing the property. @rtype: C{unicode} """ description = propertyDefinition.description toolTip = propertyDefinition.displayName type_ = propertyDefinition.type if not type_ is None: toolTip += ": " + type_ if not description is None: toolTip += "\n" + description return toolTip
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/user/common/util.py", "copies": "1", "size": "23404", "license": "bsd-3-clause", "hash": 1129343238161996500, "line_mean": 37.4671163575, "line_max": 132, "alpha_frac": 0.6188685695, "autogenerated": false, "ratio": 4.890096113664856, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.6008964683164856, "avg_score": null, "num_lines": null }
""" Handler for the generated preferences stuff. """ import base64 import codecs import logging from StringIO import StringIO from xml.parsers.expat import ExpatError from datafinder.core.configuration.gen import preferences from datafinder.core.error import ConfigurationError from datafinder.persistence.error import PersistenceError __version__ = "$Revision-Id:$" _DEFAULT_ENCODING = "UTF-8" preferences.ExternalEncoding = _DEFAULT_ENCODING class PreferencesHandler(object): """ Handles the local preferences information. """ _streamWriterClass = codecs.getwriter(_DEFAULT_ENCODING) _preferencesFileName = "preferences.xml" _log = logging.getLogger() def __init__(self, fileStorer): """ Constructor. @param fileStorer: Points to the parent directory of the preferences file. @type fileStorer: L{FileStorer<datafinder.persistence.factory.FileStorer>} @note: Call C{load} to initialize the handler. """ self._fileStorer = fileStorer.getChild(self._preferencesFileName) self._connections = None self._connectionOrder = list() self._preferences = None def _reset(self): """ Resets current configuration. """ self._connections = None self._connectionOrder = list() self._preferences = None def load(self): """ Loads the preferences. @note: When a problem occurs a new default preferences configuration is created. """ self._reset() try: if self._fileStorer.isLeaf: data = self._fileStorer.readData() content = data.read() data.close() try: self._preferences = preferences.parseString(unicode(content, _DEFAULT_ENCODING)) except (ValueError, ExpatError, UnicodeDecodeError, SyntaxError): self._log.error("Problem occurred during parsing preferences. Default preferences used.", exc_info=True) self._preferences = self._getDefaultPreferences() else: self._preferences = self._getDefaultPreferences() except PersistenceError: self._preferences = self._getDefaultPreferences() self._getConnections() @staticmethod def _getDefaultPreferences(): """ Creates the default preferences. """ return preferences.preferences(scriptUris=list(), searchQueries=list()) def store(self): """ Stores the preferences. @raise ConfigurationError: Indicating problems on storage. """ try: if not self._fileStorer.exists(): self._fileStorer.createResource() stream = self._streamWriterClass(StringIO()) self._preferences.connections = list() for connectionUri in self._connectionOrder: connection = self._connections[connectionUri] if connection.password is None: encryptedPassword = None else: encryptedPassword = base64.encodestring(connection.password) copiedConnection = preferences.connection(connection.url, connection.username, encryptedPassword, connection.useLdap, connection.ldapServerUri, connection.ldapBaseDn, connection.useLucene, connection.luceneIndexUri, connection.defaultDataStore, connection.defaultArchiveStore, connection.defaultOfflineStore) if not copiedConnection.url is None: self._preferences.addConnections(copiedConnection) self._preferences.__dict__.update(self.__dict__) try: self._preferences.export(stream, 0) except ExpatError: raise ConfigurationError("Cannot persist preferences configuration.") stream.seek(0) self._fileStorer.writeData(stream) except PersistenceError, error: raise ConfigurationError("Unable to store preferences file.\nReason: '%s'" % error.message) def getConnection(self, configurationUri): """ Returns the connection information for the given URI. @param configurationUri: URI of the configuration. @type configurationUri: C{unicode} @return: Object containing the configuration parameters. @rtype: C{object} """ result = None if not configurationUri is None: configurationUri = self._normalizeConfigurationUri(configurationUri) if configurationUri in self._connections: result = self._connections[configurationUri] return result def addScriptUri(self, scriptUri): """ Adds a script URI to the preferences. @param scriptUri: URI identifying the script extension. @type scriptUri: C{unicode} """ if not scriptUri in self._preferences.scriptUris: self._preferences.scriptUris.append(scriptUri) def removeScriptUri(self, scriptUri): """ Removes a script URI from the preferences. @param scriptPath: URI identifying the script extension. @type scriptPath: C{unicode} """ if scriptUri in self._preferences.scriptUris: self._preferences.scriptUris.remove(scriptUri) def clearScriptUris(self): """ Removes all existing script URIs from preferences. """ self._preferences.scriptUris = list() def addSearchQuery(self, name, query): """ Adds a search query to the preferences. @param name: Name of the search query. @type name: C{unicode} @param query: A search query string. @type query: C{unicode} """ if not name is None and not query is None: searchQuery = self._getSearchQuery(name) if searchQuery is None: searchQuery = preferences.searchQuery(name, query) self._preferences.searchQueries.append(searchQuery) else: searchQuery.query = query def _getSearchQuery(self, name): """ Returns the query under the given name or C{None} if it does not exist. """ for searchQuery in self._preferences.searchQueries: if searchQuery.name == name: return searchQuery return None def removeSearchQuery(self, name): """ Removes a search query from the preferences. @param name: Name of the search query. @type name: C{unicode} """ searchQuery = self._getSearchQuery(name) if not searchQuery is None: self._preferences.searchQueries.remove(searchQuery) def clearSearchQueries(self): """ Removes all existing search queries from preferences. """ self._preferences.searchQueries = list() def addConnection(self, configurationUri, username=None, password=None, useLdap=None, ldapServerUri=None, ldapBaseDn=None, useLucene=None, luceneIndexUri=None, defaultDataStore=None, defaultArchiveStore=None, defaultOfflineStore=None): """ Adds a connection. @param configurationUri: URI of the configuration. @type configurationUri: C{unicode} @param username: Username for authentication. @type username: C{unicode} @param password: Not encrypted password. @type password: C{unicode} """ if not configurationUri is None: configurationUri = self._normalizeConfigurationUri(configurationUri) if configurationUri in self._connectionOrder: connection = self.getConnection(configurationUri) self._connectionOrder.remove(configurationUri) else: connection = preferences.connection(configurationUri, username, password, useLdap, ldapServerUri, ldapBaseDn, useLucene, luceneIndexUri, defaultDataStore, defaultArchiveStore) connection.username = username connection.password = password connection.useLdap = useLdap connection.ldapServerUri = ldapServerUri connection.ldapBaseDn = ldapBaseDn connection.useLucene = useLucene connection.luceneIndexUri = luceneIndexUri connection.defaultDataStore = defaultDataStore connection.defaultArchiveStore = defaultArchiveStore connection.defaultOfflineStore = defaultOfflineStore self._connections[configurationUri] = connection self._connectionOrder.insert(0, configurationUri) @staticmethod def _normalizeConfigurationUri(configurationUri): """ Ensures that the path component of the URI is in the correct format, i.e. without trailing slash. """ if configurationUri.endswith("/"): configurationUri = configurationUri[:-1] return configurationUri def removeConnection(self, configurationUri): """ Removes a connection. @param configurationUri: URI of the configuration. @type configurationUri: C{unicode} """ if not configurationUri is None: configurationUri = self._normalizeConfigurationUri(configurationUri) if configurationUri in self._connections: del self._connections[configurationUri] if configurationUri in self._connectionOrder: self._connectionOrder.remove(configurationUri) def clearConnections(self): """ Clears all connections. """ self._connections.clear() self._connectionOrder = list() def _getConnections(self): """ Getter for the connections. """ if self._connections is None or self._connectionOrder is None: self._connections = dict() for connection in self._preferences.connections: if not connection.url is None: self._connectionOrder.append(connection.url) decryptedPassword = connection.password if not decryptedPassword is None: decryptedPassword = base64.decodestring(connection.password) copiedConnection = preferences.connection(connection.url, connection.username, decryptedPassword, connection.useLdap, connection.ldapServerUri, connection.ldapBaseDn, connection.useLucene, connection.luceneIndexUri, connection.defaultDataStore, connection.defaultArchiveStore, connection.defaultOfflineStore) self._connections[copiedConnection.url] = copiedConnection return self._connectionOrder[:] connectionUris = property(_getConnections) def __getattr__(self, name): """ Automatically redirects property calls to the generated class. """ return getattr(self._preferences, name)
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/core/configuration/preferences.py", "copies": "1", "size": "13945", "license": "bsd-3-clause", "hash": -7565749219310979000, "line_mean": 39.1356932153, "line_max": 130, "alpha_frac": 0.5958408032, "autogenerated": false, "ratio": 5.240511086057873, "config_test": true, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.02193890168635359, "num_lines": 339 }
""" Implements different script representation. """ import atexit import imp import sys import tarfile import tempfile import traceback from datafinder.common.logger import getDefaultLogger from datafinder.core.configuration.scripts import constants from datafinder.core.error import ConfigurationError from datafinder.persistence.error import PersistenceError from datafinder.persistence.factory import createFileStorer __version__ = "$Revision-Id:$" _COMMENT_CHARACTER = "#" _LIST_SEPARATOR = "," class Script(object): """ Represents a single script extension. """ _logger = getDefaultLogger() def __init__(self, fileStorer): """ Initialize a new script. @param fileStorer: Allowing access to the script data. @type fileStorer: L{FileStorer<datafinder.persistence.factory.FileStorer>} """ self._fileStorer = fileStorer self.uri = self._fileStorer.uri self.name = self._fileStorer.name self.location = None # Script options self.title = None self.description = None self.datatypes = list() self.dataformats = list() self.iconName = None self.version = None self.automatic = False self._parseScript() if self.iconName is None: self.iconName = "lightning_bolt" if self.title is None: self.title = fileStorer.name def _parseScript(self): """ Parse the script and extract the meta data. """ dataStream = self._fileStorer.readData() try: try: line = dataStream.readline() while line: line = line.strip() self._parse(line) line = dataStream.readline() finally: dataStream.close() except IOError: raise ConfigurationError("Cannot read script data.") def _parse(self, line): """ Evaluates the line and sets the corresponding script attribute. """ if line.startswith(_COMMENT_CHARACTER): if constants.TITLE_KEYWORD in line: self.title = line.split(constants.TITLE_KEYWORD)[1].strip() elif constants.DATATYPES_KEYWORD in line: datatypes = line.split(constants.DATATYPES_KEYWORD)[1].split(_LIST_SEPARATOR) for datatype in datatypes: datatype = datatype.strip() if len(datatype) > 0: self.datatypes.append(datatype) elif constants.DATAFORMATS_KEYWORD in line: dataformats = line.split(constants.DATAFORMATS_KEYWORD)[1].split(_LIST_SEPARATOR) for dataformat in dataformats: dataformat = dataformat.strip() if len(dataformat) > 0: self.dataformats.append(dataformat) elif constants.ICON_KEYWORD in line: self.iconName = line.split(constants.ICON_KEYWORD)[1].strip() elif constants.VERSION_KEYWORD in line: self.version = line.split(constants.VERSION_KEYWORD)[1].strip() elif constants.DESCRIPTION_KEYWORD in line: self.description = line.split(constants.DESCRIPTION_KEYWORD)[1].strip() elif constants.AUTOMATIC_EXECUTE_KEYWORD in line: self.automatic = True def execute(self): """ Execute the script. @param scriptOut: Object to write the script output to. @type scriptOut: Object with write() method. @raise ConfigurationError: Raised if execution of script caused an exception or script terminated with a negative return code. """ try: fileObject = self._fileStorer.readData() except PersistenceError, error: raise ConfigurationError("Cannot access script.\nReason: '%s'" % error.message) else: _loadModule(fileObject, self.name, self._logger) @property def isBound(self): """ Flag indicating whether the scripts does only work with certain data types or formats. """ return len(self.dataformats) > 0 or len(self.datatypes) > 0 class ScriptCollection(object): """ Class representing a script collection. """ _logger = getDefaultLogger() def __init__(self, fileStorer): """ Constructor. @param fileStorer: Allowing access to the script data. @type fileStorer: L{FileStorer<datafinder.persistence.factory.FileStorer>} """ self._fileStorer = fileStorer self.uri = self._fileStorer.uri self.name = self._fileStorer.name self._tmpdir = tempfile.mkdtemp() sys.path.append(self._tmpdir) self.title = self._fileStorer.name[:-4] sys.path.append(self._tmpdir) self._baseDirFileStorer = createFileStorer("file:///" + self._tmpdir + "/" + self.title) atexit.register(self._cleanup) self.scripts = list() self.hasPreferences = False self.location = None self._extract() self._parse() def _extract(self): """ Extract the script collection. """ dataStream = self._fileStorer.readData() tar = tarfile.open(fileobj=dataStream) for member in tar.getmembers(): tar.extract(member, self._tmpdir) tar.close() dataStream.close() def _parse(self): """ Parse all scripts. """ configFileStorer = self._baseDirFileStorer.getChild(constants.SCRIPT_DEFINITION_FILE_NAME) data = configFileStorer.readData() for line in data.readlines(): fileStorer = self._baseDirFileStorer.getChild(line.strip()) self.scripts.append(Script(fileStorer)) data.close() if self._baseDirFileStorer.getChild(constants.PREFERENCES_PAGE_MODULE_NAME).exists(): self.hasPreferences = True def _cleanup(self): """ Cleanup the temporary directory. """ if self._tmpdir in sys.path: sys.path.remove(self._tmpdir) try: fileStorer = createFileStorer("file:///" + self._tmpdir) if fileStorer.exists(): fileStorer.delete() except PersistenceError, error: self._logger.debug(error.message) def executePreferences(self): """ Execute the preferences page. """ if self.hasPreferences: try: fileObject = self._baseDirFileStorer.getChild(constants.PREFERENCES_PAGE_MODULE_NAME).readData() except PersistenceError, error: raise ConfigurationError("Cannot access script.\nReason: '%s'" % error.message) else: _loadModule(fileObject, constants.PREFERENCES_PAGE_MODULE_NAME, self._logger) def _loadModule(fileObject, moduleName, logger): """ Loads the content of the file object as Python module. It only works with real file objects. """ try: imp.load_module(moduleName, fileObject, fileObject.name, (".py", "r", imp.PY_SOURCE)) except Exception, error: for line in traceback.format_exception(sys.exc_info()[1], sys.exc_info()[0], sys.exc_info()[2]): logger.debug(line) raise ConfigurationError("Script '%s' terminated with error-code '%s'." % (moduleName, str(error))) finally: fileObject.close() def createScript(scriptFileStorer, location=constants.LOCAL_SCRIPT_LOCATION): """ Returns a parsed script for the given script file storer. @param scriptFileStorer: Allows access to the script file. @type scriptFileStorer: L{FileStorer<datafinder.persistence.factory.FileStorer>} @param location: The Location or source of the script. Default is the "local" location. @type location: C{unicode} @return: C{Script} or C{ScriptCollection} @raise ConfigurationError: Indicating problem during script parsing. """ script = None if scriptFileStorer.name.endswith(".py"): try: script = Script(scriptFileStorer) except (IOError, PersistenceError), error: raise ConfigurationError("Unable to parse script.\nReason: '%s'" % error.message) elif scriptFileStorer.name.endswith(".tar"): try: script = ScriptCollection(scriptFileStorer) except (IOError, PersistenceError), error: raise ConfigurationError("Unable to parse script collection.\nReason: '%s'" % error.message) else: raise ConfigurationError("'%s' is no valid script extension." % scriptFileStorer.name) script.location = location return script
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/core/configuration/scripts/script.py", "copies": "1", "size": "11020", "license": "bsd-3-clause", "hash": 1710166532194676000, "line_mean": 35.7397260274, "line_max": 112, "alpha_frac": 0.6078947368, "autogenerated": false, "ratio": 4.5219532211735745, "config_test": true, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.019755285922618618, "num_lines": 292 }
""" This is a basic icon to be shown on a canvas. """ from qt import QPixmap, QPoint, QPen, QColor from qtcanvas import QCanvasRectangle, QCanvasText __version__ = "$Revision-Id:$" class PrototypeIcon(QCanvasRectangle): """ Prototype-icon from wich other icons inherit. @param icnPxmp: a QPixmap representing the certain DataFinder-Type @type icnPxmp: L{QWidget<qt.Pixmap>} @param icnLbl: the label of this icon @type icnLbl: C{unicode} @param icnCnvs: the canvas on wich this icon is shown @type icnCnvs: L{QWidget<qt.QCanvas>} """ def __init__(self, icnPxmp, icnLbl, icnCnvs): """ Constructor.""" QCanvasRectangle.__init__(self, icnCnvs) self.isMarked = 0 self.partialRelations = [] self.iconType = 0 self.iconLabel = icnLbl self.iconLabelWidth = 0 self.iconLabelHeight = 0 self.iconPainterWidth = 0 self.iconPixmap = icnPxmp self.iconImage = None self.scaleMaskUnmarked = QPixmap.convertToImage(QPixmap.fromMimeSource("layer01.png")) self.scaleMaskMarked = QPixmap.convertToImage(QPixmap.fromMimeSource("layer02.png")) self.scaleMaskHighlight = QPixmap.convertToImage(QPixmap.fromMimeSource("layer03.png")) self.scaledMaskUnmarked = self.scaleMaskUnmarked self.scaledMaskMarked = self.scaleMaskMarked self.scaledMaskHighlight = self.scaleMaskHighlight self.setIconPixmap(icnPxmp) self.setIconLabel(self.iconLabel) def mark(self, passIt = True): """ Sets this icon as marked. If passIt is True, the icon will also mark all partial relations connected with this icon. """ self.isMarked = 2 if passIt: self.setZ(400) self.isMarked = 1 for eachItem in self.partialRelations: eachItem.mark() def unmark(self, passIt = True): """ Sets this icon as unmarked. If passIt is True, the icon will also unmark all partial relations connected with this icon. """ self.isMarked = 0 self.setZ(255) if passIt: for eachItem in self.partialRelations: eachItem.unmark() def getAnchorPoint(self): """ Actually just returns the QPoint at the mid of this icon. """ anchorPoint = QPoint(self.x() + self.iconPainterWidth / 2, self.y() + self.iconImage.height() / 2) return anchorPoint def getIconType(self): """ Returns the type of this icon. Type 0 is a PrototypeIcon Type 1 is a DataTypeIcon Type 2 is a RelationIcon Type 3 is a PartialRelationIcon """ return self.iconType def hit(self, p): """ Proofs if this icon is clicked. @return: boolean indicating whether icon is clicked (True) or not (False) @rtype: C{boolean} """ ix = p.x() - self.x() - (self.iconPainterWidth - self.iconImage.width()) / 2 iy = p.y() - self.y() if not self.iconImage.valid( ix , iy ): return False return True def setIconPixmap(self, newIcnPxmp): """ Sets or changes the icons pixmap. """ self.iconPixmap = newIcnPxmp self.iconImage = self.iconPixmap.convertToImage() self.setIconLabel(self.iconLabel) def setIconLabel(self, newIcnLbl): """ Sets a new icon label and aligns it at the center. @param newIcoTxt: the icons new name @type newIcoTxt: C{unicode} """ self.iconLabel = newIcnLbl iconLabelBuffer = QCanvasText(newIcnLbl, self.canvas()) self.iconLabelWidth = iconLabelBuffer.boundingRect().width() self.iconLabelHeight = iconLabelBuffer.boundingRect().height() iconLabelBuffer.setCanvas(None) del iconLabelBuffer self.setSize(self.iconImage.width() + 8, self.iconImage.height()+self.iconLabelHeight + 10) self.iconPainterWidth = self.iconImage.width() if self.iconLabelWidth > self.iconPainterWidth: self.setSize(self.iconLabelWidth + 8, self.iconPixmap.height()+self.iconLabelHeight + 10) self.iconPainterWidth = self.iconLabelWidth + 8 self.scaledMaskUnmarked = self.scaleMaskUnmarked.smoothScale(self.width(), self.height()) self.scaledMaskMarked = self.scaleMaskMarked.smoothScale(self.width(), self.height()) self.scaledMaskHighlight = self.scaleMaskHighlight.smoothScale(self.width(), self.height()) def updatePartialRelations(self): """ To update the coordinates of the connected partial relations call this function. """ for eachItem in self.partialRelations: eachItem.setCoords() def removePartialRelation(self, partialRelation): """ Removes the partialRelation from the icons partialRelations list. """ self.partialRelations.remove(partialRelation) def moveBy(self, dx, dy): """ To move this icon relative to its current position. At the same time all partial relations of this icon are updated. """ QCanvasRectangle.moveBy(self, dx, dy) self.updatePartialRelations() def drawShape(self, p): """ Draws the icon. """ p.setPen(QPen(QColor(100, 100, 100), 0)) markPixmap = QPixmap(self.scaledMaskUnmarked) if self.isMarked == 1: markPixmap = QPixmap(self.scaledMaskMarked) p.setPen(QPen(QColor(0, 0, 0), 0)) if self.isMarked == 2: markPixmap = QPixmap(self.scaledMaskHighlight) p.setPen(QPen(QColor(0, 0, 0), 0)) p.drawPixmap(self.x(), self.y(), markPixmap) p.drawPixmap(self.x() + (self.iconPainterWidth - self.iconPixmap.width()) / 2, self.y() + 4, self.iconPixmap) p.drawText(self.x() + (self.iconPainterWidth - self.iconLabelWidth) / 2, self.y() + self.iconPixmap.height() + self.iconLabelHeight + 4, self.iconLabel) def destroyIcon(self): """ When deleting the icon, this function also removes all connected partial relations from the canvas and deletes them. """ for eachItem in self.partialRelations: eachItem.setCanvas(None) del eachItem self.setCanvas(None) del self
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/datamodel_iconview/prototype_icon.py", "copies": "1", "size": "8560", "license": "bsd-3-clause", "hash": -8960587871634093000, "line_mean": 34.7381974249, "line_max": 117, "alpha_frac": 0.6203271028, "autogenerated": false, "ratio": 4.033930254476909, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5154257357276908, "avg_score": null, "num_lines": null }
""" Controls view displaying current content of a collection. """ from PyQt4 import QtCore, QtGui from datafinder.gui.user.common.controller import AbstractController from datafinder.gui.user.common.delegate import AbstractDelegate from datafinder.gui.user.common import util __version__ = "$Revision-Id:$" class StackedCollectionsController(AbstractController): """ Controls views displaying current content of a collection. """ def __init__(self, stackedWidget, tableView, listView, viewsListAction, viewsTableAction, viewsIconsAction, mainWindow, parentController): """ Constructor. """ AbstractController.__init__(self, stackedWidget, mainWindow, None, True, parentController) self._tableController = _TableController(tableView, mainWindow, self) self._listController = _ListController(listView, mainWindow, self) listView.setUniformItemSizes(True) self.connect(viewsTableAction, QtCore.SIGNAL("triggered()"), self._viewsTableClickedSlot) self.connect(viewsListAction, QtCore.SIGNAL("triggered()"), self._viewsListClickedSlot) self.connect(viewsIconsAction, QtCore.SIGNAL("triggered()"), self._viewsIconClickedSlot) self.connect(self.widget, QtCore.SIGNAL("modelUpdateSignal"), self._modelUpdateSlot) def _viewsTableClickedSlot(self): """ Displays the table view. """ self.setCurrentIndex(0) self._modelUpdateSlot(self.model) def _viewsListClickedSlot(self): """ Displays the list view. """ self.setCurrentIndex(1) self._listController.setViewMode(QtGui.QListView.ListMode) self._modelUpdateSlot(self.model) def _viewsIconClickedSlot(self): """ Displays the icon view. """ self.setCurrentIndex(1) self._listController.setViewMode(QtGui.QListView.IconMode) self._modelUpdateSlot(self.model) def _modelUpdateSlot(self, model): """ Slot is called when model data has changed. """ self._listController.setSelectionModel(self._tableController.selectionModel()) self._listController.itemActionController = self.parentController.itemActionController self._listController.model = model self._tableController.itemActionController = self.parentController.itemActionController self._tableController.model = model def focus(self): """ Sets focus to the current active view and selects the first item . """ self._tableController.focus() def setEnabled(self, flag): """ Enables all controlled widgets. """ self.widget.setEnabled(flag) self._listController.setEnabled(flag) self._tableController.setEnabled(flag) @property def selectedIndexes(self): """ Returns the selected indexes. """ return self._tableController.selectionModel().selectedRows() class _TableController(AbstractController): """ Controls the table view displaying the items. """ def __init__(self, tableView, mainWindow, parentController): """ Constructor. """ AbstractController.__init__(self, tableView, mainWindow, None, True, parentController) self.itemActionController = None self.model = None self.setFocusPolicy(QtCore.Qt.StrongFocus) self.setSortingEnabled(True) self.horizontalHeader().setSortIndicator(0, QtCore.Qt.AscendingOrder) self._delegates = [_CollectionDelegate(self)] def focus(self): """ Sets focus to the current active view and selects the first item . """ root = self.rootIndex() column = self.model.columnCount(root) - 1 item = QtGui.QItemSelection(self.model.index(0, 0, root), self.model.index(0, column, root)) self.selectionModel().clear() self.selectionModel().select(item, QtGui.QItemSelectionModel.Select) self.selectionModel().setCurrentIndex(self.model.index(0, 0, root), QtGui.QItemSelectionModel.Select) self.setFocus(QtCore.Qt.MouseFocusReason) class _ListController(AbstractController): """ Controls icon and list view displaying items. """ def __init__(self, listView, mainWindow, parentController): """ Constructor. """ AbstractController.__init__(self, listView, mainWindow, None, True, parentController) self.itemActionController = None self.model = None self._delegates = [_CollectionDelegate(self)] class _CollectionDelegate(AbstractDelegate): """ The Collection delegate manages a stacked collection view. """ def __init__(self, controller): """ Constructor. """ AbstractDelegate.__init__(self, controller) self._itemDelegate = _CollectionItemDelegate(self) self._controller.setItemDelegate(self._itemDelegate) self.__itemActionController = None self.ignoreOpenAction = False @property def _selectionModel(self): """ Getter for the selection model. """ return self._controller.widget.selectionModel() @property def _itemActionController(self): """ Getter for the ItemActionController. """ self.__itemActionController.configure(self._controller.widget, list()) return self.__itemActionController @util.immediateConnectionDecorator("widget", "modelUpdateSignal") def _modelSetSignalSlot(self, _): """ Reacts on changed model. """ self.__itemActionController = self._controller.itemActionController self._itemDelegate.actionController = self._itemActionController QtCore.QObject.connect(self._selectionModel, QtCore.SIGNAL("selectionChanged(QItemSelection, QItemSelection)"), self._selectionChangedSlot) # ensures that _selectionChangedSlot is correctly connected @util.immediateConnectionDecorator("model", "updateSignal") def _modelUpdateSignalSlot(self, index): """ Reacts on data updates of the model. """ self._controller.setRootIndex(self._controller.model.activeIndex) self._controller.selectionModel().clear() self._controller.selectionModel().select(index, QtGui.QItemSelectionModel.Select) self.__itemActionController.setItemActionEnabledState() @util.immediateConnectionDecorator("widget", "focusSignal") def _focusSignalSlot(self, isFocused): """ Slot is called when the widget is focused. """ if isFocused: self._itemActionController.setItemActionEnabledState() def _selectionChangedSlot(self, _, __): """ Slot is called when the selection has changed and updates available item actions. """ self._focusSignalSlot(self._controller.hasFocus()) self._controller.mainWindow.statusBar().clearMessage() selectedRows = len(self._selectionModel.selectedRows()) if selectedRows > 0: self._controller.mainWindow.statusBar().showMessage("%i items selected." % selectedRows) @util.immediateConnectionDecorator("widget", "doubleClicked(QModelIndex)") def _myWidgetDoubleClickedSlot(self, _): """ Slot is called when an item is double clicked in the list views. """ self._openActionClickedSlot() @util.immediateConnectionDecorator("widget", "returnPressed") def _myWidgetReturnPressedSlot(self, _): """ Reacts on enter key hits on a specific item. """ self._openActionClickedSlot() @util.deferredConnectionDecorator("selectAllAction", "triggered()") def _selectAllActionTriggeredSlot(self): """ Slot is called when all item in the current view has to be selected. """ self._itemActionController.selectAllAction() @util.deferredConnectionDecorator("reverseSelectionAction", "triggered()") def _reverseSelectionActionTriggeredSlot(self): """ Inverts the current selection. """ self._itemActionController.reverseSelectionAction() @util.immediateConnectionDecorator("widget", "customContextMenuRequested(QPoint)") def _customContextMenuRequestedSlot(self, _): """ Shows the context menu at a valid position. """ menu = self._itemActionController.createContextMenu(list()) menu.exec_(QtGui.QCursor.pos()) @util.deferredConnectionDecorator("copyAction", "triggered()") def _copyActionTriggeredSlot(self): """ Prepares a copy action. """ self._itemActionController.prepareCopyAction() @util.deferredConnectionDecorator("copyPropertiesAction", "triggered()") def _copyPropertiesActionSlot(self): """ Prepares copying of properties. """ self._itemActionController.prepareCopyPropertiesAction() @util.deferredConnectionDecorator("cutAction", "triggered()") def _cutActionTriggeredSlot(self): """ Prepares cut action. """ self._itemActionController.prepareCutAction() @util.deferredConnectionDecorator("pasteAction", "triggered()") def _pasteActionTriggeredSlot(self): """ Performs paste action. """ self._itemActionController.pasteAction() @util.deferredConnectionDecorator("deleteAction", "triggered()") def _deleteActionTriggeredSlot(self): """ Performs delete action. """ self._itemActionController.deleteAction() @util.deferredConnectionDecorator("renameAction", "triggered()") def _renameActionTriggeredSlot(self): """ Performs rename action. """ index = self._controller.selectionModel().currentIndex() if index.isValid(): self._controller.edit(index) @util.deferredConnectionDecorator("createCollectionAction", "triggered()") def _createCollectionActionClickedSlot(self): """ Creates a new collection. """ self._itemActionController.createCollection() @util.deferredConnectionDecorator("createLinkAction", "triggered()") def _createLinkActionClickedSlot(self): """ Creates a new link. """ self._itemActionController.createLink() @util.deferredConnectionDecorator("createLeafAction", "triggered()") def _createLeafAction(self): """ Creates a leaf. """ self._itemActionController.createLeaf() @util.deferredConnectionDecorator("importAction", "triggered()") def _importActionClickedSlot(self): """ Imports an item. """ self._itemActionController.importAction() @util.deferredConnectionDecorator("exportAction", "triggered()") def _exportActionClickedSlot(self): """ Exports an item. """ self._itemActionController.exportAction() @util.deferredConnectionDecorator("createArchiveAction", "triggered()") def _archiveActionClickedSlot(self): """ Archives an item. """ self._itemActionController.createArchive() @util.deferredConnectionDecorator("editPropertiesAction", "triggered()") def _propertiesActionClickedSlot(self): """ Shows properties. """ self._itemActionController.propertiesAction() @util.deferredConnectionDecorator("copyPropertiesAction", "triggered()") def _copyPropertiesActionClickedSlot(self): """ Initiates copying of properties. """ self._itemActionController.prepareCopyPropertiesAction() @util.deferredConnectionDecorator("openAction", "triggered()") def _openActionClickedSlot(self): """ Opens the selected item. """ if not self.ignoreOpenAction: self._itemActionController.openAction() @util.deferredConnectionDecorator("printAction", "triggered()") def _printActionClickedSlot(self): """ Prints the selected item. """ self._itemActionController.printAction() @util.deferredConnectionDecorator("searchAction", "triggered()") def _searchActionClickedSlot(self): """ Opens the search dialog. """ self._itemActionController.searchAction() @util.deferredConnectionDecorator("privilegeAction", "triggered()") def _privilegeActionClickedSlot(self): """ Opens the privilege dialog. """ self._itemActionController.privilegeAction() @util.deferredConnectionDecorator("commitArchiveAction", "triggered()") def _commitArchiveActionClickedSlot(self): """ Commits changes of selected archives. """ self._itemActionController.commitArchive() class _CollectionItemDelegate(QtGui.QItemDelegate): """ Controls the editing process of an item. """ def __init__(self, collectionDelegate=None): """ Constructor. """ QtGui.QItemDelegate.__init__(self) self._collectionDelegate = collectionDelegate self.actionController = None def setEditorData(self, editor, index): # R201 """ @see: L{setEditorData<PyQt4.QtGui.QItemDelegate.setEditorData>} """ data = index.model().data(index, QtCore.Qt.DisplayRole).toString() editor.setText(data) self._collectionDelegate.ignoreOpenAction = True def setModelData(self, editor, _, index): """ @see: L{setEditorData<PyQt4.QtGui.QItemDelegate.setEditorData>} """ try: if editor.isModified(): newName = unicode(editor.text()) self.actionController.renameAction(index, newName) finally: self._collectionDelegate.ignoreOpenAction = False
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/user/controller/repository/collection.py", "copies": "1", "size": "16049", "license": "bsd-3-clause", "hash": -5552522491253109000, "line_mean": 36.2119047619, "line_max": 118, "alpha_frac": 0.6495731821, "autogenerated": false, "ratio": 4.749630068067476, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.015204425376832992, "num_lines": 420 }
""" Dialog to configure connection preferences, currently only LDAP. """ from PyQt4 import QtCore, QtGui from datafinder.gui.gen.user.preferences_dialog_ui import Ui_preferencesDialog __version__ = "$Revision-Id:$" class PreferencesDialogView(QtGui.QDialog, Ui_preferencesDialog): """ Dialog to configure connection preferences, currently only LDAP. """ def __init__(self, parent=None): """ Constructor. @param parent: Parent window of this L{QtGui.QDialog} @type parent: C{QtGui.QWidget} """ QtGui.QDialog.__init__(self, parent) Ui_preferencesDialog.__init__(self) self.setupUi(self) self.connect(self.cancelButton, QtCore.SIGNAL("clicked()"), self.reject) self.connect(self.okButton, QtCore.SIGNAL("clicked()"), self.accept) self.connect(self.useLdapCheckBox, QtCore.SIGNAL("stateChanged(int)"), self.useLdapStateChanged) self.connect(self.useLuceneCheckBox, QtCore.SIGNAL("stateChanged(int)"), self.useLuceneStateChanged) def useLdapStateChanged(self, state): """ Enables and disables the line edits to edit the ldap properties. @param state: The new state @type state C{Qt::CheckState} """ if state == 2: self.serverUriLineEdit.setEnabled(True) self.baseDnLineEdit.setEnabled(True) else: self.serverUriLineEdit.setEnabled(False) self.baseDnLineEdit.setEnabled(False) def _getUseLdap(self): """ Returns if ldap should be used. @return: If ldap should be used. @rtype: C{boolean} """ if self.useLdapCheckBox.checkState() == 2: return True else: return False def _setUseLdap(self, use): """ If ldap should be used. @param urls: If ldap should be used. @type urls: C{boolean} """ if use: self.useLdapCheckBox.setCheckState(2) else: self.useLdapCheckBox.setCheckState(0) useLdap = property(_getUseLdap, _setUseLdap) def _getLdapServerUri(self): """ Returns the ldap server uri. @return: The ldap server uri. @rtype: C{String} """ return unicode(self.serverUriLineEdit.text()) def _setLdapServerUri(self, uri): """ Sets the ldap server uri. @param uri: The ldap server uri. @type uri: C{String} """ self.serverUriLineEdit.setText(uri or "") ldapServerUri = property(_getLdapServerUri, _setLdapServerUri) def _getLdapBaseDn(self): """ Returns the ldap basedn. @return: The ldap basedn. @rtype: C{String} """ return unicode(self.baseDnLineEdit.text()) def _setLdapBaseDn(self, basedn): """ Sets the ldap basedn. @param basedn: The ldap basedn. @type basedn: C{String} """ self.baseDnLineEdit.setText(basedn or "") ldapBaseDn = property(_getLdapBaseDn, _setLdapBaseDn) def useLuceneStateChanged(self, state): """ Enables and disables the line edits to edit the lucene properties. @param state: The new state @type state C{Qt::CheckState} """ if state == 2: self.indexUriLineEdit.setEnabled(True) else: self.indexUriLineEdit.setEnabled(False) def _getUseLucene(self): """ Returns if lucene should be used. @return: If lucene should be used. @rtype: C{boolean} """ if self.useLuceneCheckBox.checkState() == 2: return True else: return False def _setUseLucene(self, use): """ If lucene should be used. @param urls: If lucene should be used. @type urls: C{boolean} """ if use: self.useLuceneCheckBox.setCheckState(2) else: self.useLuceneCheckBox.setCheckState(0) useLucene = property(_getUseLucene, _setUseLucene) def _getLuceneIndexUri(self): """ Returns the lucene index uri. @return: The lucene index uri. @rtype: C{String} """ return unicode(self.indexUriLineEdit.text()) def _setLuceneIndexUri(self, uri): """ Sets the lucene index uri. @param uri: The lucene index uri. @type uri: C{String} """ self.indexUriLineEdit.setText(uri or "") luceneIndexUri = property(_getLuceneIndexUri, _setLuceneIndexUri)
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/user/dialogs/preferences_dialog.py", "copies": "1", "size": "6612", "license": "bsd-3-clause", "hash": -6302464879115255000, "line_mean": 29.0516431925, "line_max": 108, "alpha_frac": 0.6064730792, "autogenerated": false, "ratio": 4.091584158415841, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5198057237615841, "avg_score": null, "num_lines": null }
""" Implementation of commonly used search grammar. """ import time import unicodedata from pyparsing import White, alphas, nums, QuotedString, Word, operatorPrecedence, \ opAssoc, Combine, Keyword, Group, StringEnd, Regex, ParserElement __version__ = "$Revision-Id:$" EQUAL_OPERATOR = "=" LT_OPERATOR = "<" GT_OPERATOR = ">" LTE_OPERATOR = "<=" GTE_OPERATOR = ">=" LIKE_OPERATOR = "like" EXISTS_OPERATOR = "exists" CONTENT_CONTAINS_OPERATOR = "contains" IS_COLLECTION_OPERATOR = "isCollection" AND_OPERATOR = "AND" OR_OPERATOR = "OR" NOT_OPERATOR = "NOT" ParserElement.enablePackrat() # Improves the performance of pyparsing class SearchRestrictionParser(object): """ Defines the grammar for a simple search restriction expressions. The parsers of the different terms of these restriction expressions are provided by this class. """ def __init__(self): """ Constructor. """ self.__literalExpression = None self.__keywordExpression = None self.__propertyNameExpression = None self.__comparisonExpression = None self.__conditionExpression = None self.__conjunctionExpression = None self.__restrictionExpression = None self.__dateExpression = None self.__numberExpression = None self.__conjunctionTokens = None self.__comparisonTokens = None self.__andKeyword = None self.__orKeyword = None self.__notKeyword = None self.__quotedStringCharacters = ["\"", "'"] self.__initSearchRestrictionParser() def __initSearchRestrictionParser(self): """ Initializes and returns a parser for the search restrictions. """ unicodeUmlaut = unicodedata.lookup("LATIN CAPITAL LETTER A WITH DIAERESIS") + \ unicodedata.lookup("LATIN SMALL LETTER A WITH DIAERESIS") + \ unicodedata.lookup("LATIN CAPITAL LETTER O WITH DIAERESIS") + \ unicodedata.lookup("LATIN SMALL LETTER O WITH DIAERESIS") + \ unicodedata.lookup("LATIN CAPITAL LETTER U WITH DIAERESIS") + \ unicodedata.lookup("LATIN SMALL LETTER U WITH DIAERESIS") + \ unicodedata.lookup("LATIN SMALL LETTER SHARP S") # define property name firstPropertyNameCharacter = alphas + unicodeUmlaut + "_" propertyCharacter = firstPropertyNameCharacter + nums + ".-" self.__propertyNameExpression = Word(firstPropertyNameCharacter, propertyCharacter) # define literal day = Regex("(0[1-9]|[12][0-9]|3[01])") month = Regex("(0[1-9]|1[012])") year = Regex("((?:19|20)\d\d)") hour = Regex("([01][0-9]|2[0-3])") minute = Regex("([0-5][0-9])") second = minute self.__dateExpression = Combine(day + "." + month + "." + year + White() + hour + ":" + minute + ":" + second) self.__numberExpression = Regex("[-+]?(\d+(\.\d*)?|\.\d+)([eE][-+]?\d+)?") self.__literalExpression = QuotedString(self.__quotedStringCharacters[0]) for quotedStringCharacter in self.__quotedStringCharacters[1:]: self.__literalExpression |= QuotedString(quotedStringCharacter) self.__literalExpression.setParseAction(self.__handleLiteral) # define keywords notKeyword = Keyword(NOT_OPERATOR, caseless=True) andKeyword = Keyword(AND_OPERATOR, caseless=True) orKeyword = Keyword(OR_OPERATOR, caseless=True) gteKeyword = Keyword(GTE_OPERATOR) lteKeyword = Keyword(LTE_OPERATOR) equalKeyword = Keyword(EQUAL_OPERATOR) gtKeyword = Keyword(GT_OPERATOR) ltKeyword = Keyword(LT_OPERATOR) likeKeyword = Keyword(LIKE_OPERATOR, caseless=True) comparisonKeyword = gteKeyword | lteKeyword | equalKeyword | gtKeyword | ltKeyword | likeKeyword existsKeyword = Keyword(EXISTS_OPERATOR, caseless=True) contentContainsKeyword = Keyword(CONTENT_CONTAINS_OPERATOR, caseless=True) isCollectionKeyword = Keyword(IS_COLLECTION_OPERATOR, caseless=True) self.__keywordExpression = notKeyword | andKeyword | orKeyword | comparisonKeyword | existsKeyword | \ contentContainsKeyword | isCollectionKeyword | "(" | ")" # definition of condition terms comparisonCondition = Group(self.__propertyNameExpression + comparisonKeyword + self.__literalExpression) existsCondition = Group(existsKeyword + self.__propertyNameExpression) contentContainsCondition = Group(contentContainsKeyword + self.__literalExpression) isCollectionCondition = isCollectionKeyword self.__conditionExpression = comparisonCondition | existsCondition | contentContainsCondition | isCollectionCondition self.__conditionExpression.setParseAction(self.__handleConditionTerm) # definition of restriction expressions (operators to combine the condition terms) self.__restrictionExpression = operatorPrecedence( self.__conditionExpression, [ (notKeyword, 1, opAssoc.RIGHT), (andKeyword, 2, opAssoc.LEFT), (orKeyword, 2, opAssoc.LEFT) ] ) + StringEnd() # definition of comparison expression self.__comparisonExpression = comparisonKeyword self.__andKeyword = andKeyword self.__orKeyword = orKeyword self.__notKeyword = notKeyword # definition of conjunction expression self.__conjunctionExpression = andKeyword | orKeyword def registerPropertyParseAction(self, parseAction): """ Appends a parsing action when matching a property expression. """ self.__propertyNameExpression.setParseAction(parseAction) def registerLiteralParseAction(self, parseAction): """ Appends a parsing action when matching a literal. """ self.__literalExpression.setParseAction(parseAction) def registerConjunctionParseAction(self, parseAction): """ Appends a parsing action when matching a conjunction keyword. """ self.__andKeyword.setParseAction(parseAction) self.__orKeyword.setParseAction(parseAction) self.__notKeyword.setParseAction(parseAction) def registerComparisonParseAction(self, parseAction): """ Appends a parsing action when matching a comparison keyword. """ self.__comparisonExpression.setParseAction(parseAction) def __handleLiteral(self, _, __, tokenList): """" Evaluates the content of the quoted string. """ unquotedString = tokenList[0] result = list() for item in self.__dateExpression.scanString(unquotedString): result.append(item) if len(result) == 1: return time.strptime(str(result[0][0][0]), "%d.%m.%Y %H:%M:%S") else: for item in self.__numberExpression.scanString(unquotedString): result.append(item) if len(result) == 1: return eval(str(result[0][0][0])) def parseString(self, inputString): """ Parses the string and returns the result. @param inputString: String to parse. @type inputString: C{unicode} @raise ParseException: Signals an error parsing the given string. """ return self.__restrictionExpression.parseString(inputString) @staticmethod def __handleConditionTerm(_, __, tokens): """ Extracts operator, literal, property name from the parsed string and calls the given parse action function. """ operator = propertyName = literal = None tokenList = list(list(tokens)[0]) if len(tokenList) == 3: operator = tokenList[1] propertyName = tokenList[0] literal = tokenList[2] elif len(tokenList) == 2: operator = tokenList[0] if operator == EXISTS_OPERATOR: propertyName = tokenList[1] else: literal = tokenList[1] else: operator = tokens[0] return (propertyName, operator, literal) def matchKeyword(self, inputString): """ Returns all matches of keywords. Keywords in literals are ignored. @param inputString: String to parse. @type inputString: C{unicode} @return: List of matched expression tuples that consist of matched expression, start index, end index. @rtype: C{list} of C{tuple} of C{unicode}, C{int}, C{int} """ return self._matchWrapper(inputString, self.__keywordExpression) def matchPropertyName(self, inputString): """ Returns all matches of property names. Keywords and property names in literals are ignored. @param inputString: String to parse. @type inputString: C{unicode} @return: List of matched expression tuples that consist of matched expression, start index, end index. @rtype: C{list} of C{tuple} of C{unicode}, C{int}, C{int} """ return self._matchWrapper(inputString, self.__propertyNameExpression) def matchLiteral(self, inputString): """ Returns all matches of literals. @param inputString: String to parse. @type inputString: C{unicode} @return: List of matched expression tuples that consist of matched expression, start index, end index. @rtype: C{list} of C{tuple} of (C{unicode} or C{time.struct_time} or C{int} or C{float}, C{int}, C{int}) """ return self._matchWrapper(inputString, self.__literalExpression) def matchComparison(self, inputString): """ Returns all matches of comparison operators. @param inputString: String to parse. @type inputString: C{unicode} @return: List of matched expression tuples that consist of matched expression, start index, end index. @rtype: C{list} of C{tuple} of (C{unicode} or C{time.struct_time} or C{int} or C{float}, C{int}, C{int}) """ return self._matchWrapper(inputString, self.__comparisonExpression) def matchConjunction(self, inputString): """ Returns all matches of conjunction operators. @param inputString: String to parse. @type inputString: C{unicode} @return: List of matched expression tuples that consist of matched expression, start index, end index. @rtype: C{list} of C{tuple} of (C{unicode} or C{time.struct_time} or C{int} or C{float}, C{int}, C{int}) """ return self._matchWrapper(inputString, self.__conjunctionExpression) def matchConditionTerm(self, inputString): """ Returns all matches of condition terms. Condition terms in literals are ignored. @param inputString: String to parse. @type inputString: C{unicode} @return: List of matched expression tuples that consist of matched expression, start index, end index. @rtype: C{list} of C{tuple} of C{unicode}, C{int}, C{int} """ return self._matchWrapper(inputString, self.__conditionExpression) @property def comparisonTokens(self): """ Returns a list of strings representing the comparison operators. """ if self.__comparisonTokens is None: self.__comparisonTokens = self._walkKeywordTree(self.__comparisonExpression) return self.__comparisonTokens @property def conjunctionTokens(self): """ Returns a list of strings representing the conjunction keywords. """ if self.__conjunctionTokens is None: self.__conjunctionTokens = self._walkKeywordTree(self.__conjunctionExpression) return self.__conjunctionTokens @property def quotedStringCharacters(self): """ Returns a list of strings representing the quoted string characters. """ return self.__quotedStringCharacters def _walkKeywordTree(self, rootNode): """ Walks through a MatchFirst object and returns possible matches as a string list """ nextRoot = None try: nextRoot = rootNode.exprs[0] except AttributeError: return [rootNode.match] else: result = self._walkKeywordTree(nextRoot) result.append(rootNode.exprs[1].match) return result @staticmethod def _matchWrapper(inputString, expression): """ Calls scanString with given input, parse expression and returns the result. """ result = list() for expression, startIndex, endIndex in expression.scanString(inputString): expressionString = expression[0] result.append((expressionString, startIndex, endIndex)) return result
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/core/search_restriction.py", "copies": "1", "size": "15427", "license": "bsd-3-clause", "hash": -5329548059456086000, "line_mean": 39.0292553191, "line_max": 125, "alpha_frac": 0.6172295326, "autogenerated": false, "ratio": 4.745309135650569, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.025683752921608006, "num_lines": 376 }
""" Module that contains the leaf item type. """ from datafinder.core.configuration.properties.constants import DATA_FORMAT_ID, MIME_TYPE_ID from datafinder.core.error import ItemError from datafinder.core.item.base import ItemBase from datafinder.persistence.error import PersistenceError __version__ = "$Revision-Id:$" class ItemLeaf(ItemBase): """ Leaf type that can not contain any child elements. """ # Root cause is ItemBase: pylint: disable=R0904 def __init__(self, name=None, fileStorer=None): """ @see: L{ItemBase.__init__<datafinder.core.item.base.ItemBase.__init__>} """ ItemBase.__init__(self, name, fileStorer) self._isLeaf = True self._created = False self._dataFormat = None def create(self, properties): """ @see: L{ItemBase.create<datafinder.core.item.base.ItemBase.create>} """ ItemBase.create(self, properties) try: if not self.fileStorer.exists(): canStoreProperties = self.capabilities.canStoreProperties self.fileStorer.createResource() if canStoreProperties: self.updateProperties(properties) self.dataPersister.create() self._refreshProperties() except PersistenceError, error: raise ItemError("Unable to create leaf item.\nReason:'%s'" % error.message) else: self._created = True def refresh(self, itemStateOnly=False): """ L{ItemBase.refresh<datafinder.core.item.base.ItemBase.refresh>} Extends the refresh behavior so the data format can be refreshed as well. """ self._dataFormat = None ItemBase.refresh(self, itemStateOnly) @property def dataFormat(self): """ Getter for the data format attribute. """ if self._dataFormat is None: dataFormatName = None mimeType = None if DATA_FORMAT_ID in self.properties: dataFormatName = self.properties[DATA_FORMAT_ID].value if MIME_TYPE_ID in self.properties: mimeType = self.properties[MIME_TYPE_ID].value self._dataFormat = self.itemFactory.getDataFormat(dataFormatName, mimeType, self.name) return self._dataFormat
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/core/item/leaf.py", "copies": "1", "size": "4146", "license": "bsd-3-clause", "hash": -7031689418923992000, "line_mean": 37.4857142857, "line_max": 98, "alpha_frac": 0.6613603473, "autogenerated": false, "ratio": 4.2306122448979595, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.014823564510599001, "num_lines": 105 }
""" The class ContextMenu is the main popup menu for the IconView. The class CanvasView shows and andministrates icons. """ from qt import QPopupMenu, QAction, QKeySequence, QIconSet, SIGNAL, QPixmap from qtcanvas import QCanvasView, QCanvas from math import sin, cos, pi from datafinder.gui.admin import data_type_dialog from datafinder.gui.admin import relation_type_dialog from datafinder.gui.admin.datamodel_iconview.datatype_icon import DataTypeIcon from datafinder.gui.admin.datamodel_iconview.relation_icon import RelationIcon __version__ = "$Revision-Id:$" class ContextMenu(QPopupMenu): """ Implements the context menu in the icon view. """ # pylint: disable=R0901 # There too many parent classes as it inherits from QPopupMenu def __init__(self, theFrame, parent, context, widgetName = 0): QPopupMenu.__init__(self, parent, widgetName) self.myFrame = theFrame self.initContextMenu(context) def initContextMenu(self, context): """ Initiates the popup menu depending on the context and adds appropriate menu items. """ #ACTION TO ARRANGE THE ICONS IN A LINE arrangeIcons01Action = QAction("Lines", QKeySequence(), self, "arrangeIcons01Actions") arrangeIcons01Action.setIconSet(QIconSet()) self.connect(arrangeIcons01Action, SIGNAL("activated()"), self.parent().arrangeIconsInLines) #ACTION TO ARRANGE THE ICONS IN A CIRCLE arrangeIcons02Action = QAction("Circle", QKeySequence(), self, "arrangeIcons02Actions") arrangeIcons02Action.setIconSet(QIconSet()) self.connect(arrangeIcons02Action, SIGNAL("activated()"), self.parent().arrangeIconsInCircle) #SUBMENU TO CHOOSE THE WAY OF ARRANGEMENT #---------------------------------------- subMenu01 = QPopupMenu(self, "Arrange Icons") arrangeIcons01Action.addTo(subMenu01) arrangeIcons02Action.addTo(subMenu01) #ACTION TO UPDATE THE SCREEN updateCanvasViewAction = QAction("Update Screen", QKeySequence(), self, "updateCanvasViewAction") updateCanvasViewAction.setIconSet(QIconSet()) self.connect(updateCanvasViewAction, SIGNAL("activated()"), self.parent().updateCanvasView) #ACTION TO ADD A NEW DATATYPE newDataTypeAction = QAction("New Data Type...", QKeySequence(), self, "newDataTypeAction") newDataTypeAction.setIconSet(QIconSet(QPixmap.fromMimeSource("newDataType16.png"))) self.connect(newDataTypeAction, SIGNAL("activated()"), self.myFrame.addDataTypeSlot) #ACTION TO ADD A NEW RELATIONTYPE newRelationTypeAction = QAction("New Relation Type...", QKeySequence(), self, "newRelationTypeAction") newRelationTypeAction.setIconSet(QIconSet(QPixmap.fromMimeSource("newRelationType16.png"))) self.connect(newRelationTypeAction, SIGNAL("activated()"), self.myFrame.addRelationTypeSlot) #ACTION TO EDIT THE MARKED DATATYPE editDataTypeAction = QAction("Edit Data Type...", QKeySequence(), self, "editDataTypeAction") editDataTypeAction.setIconSet(QIconSet(QPixmap.fromMimeSource("edit16.png"))) #ACTION TO EDIT THE MARKED RELATIONTYPE editRelationTypeAction = QAction("Edit Relation Type...", QKeySequence(), self, "editRelationTypeAction") editRelationTypeAction.setIconSet(QIconSet(QPixmap.fromMimeSource("edit16.png"))) #ACTION TO REMOVE THE MARKED ICON FROM SCREEN removeIconAction = QAction("Remove Icon", QKeySequence(), self, "removeIconAction") removeIconAction.setIconSet(QIconSet(QPixmap.fromMimeSource("delete16.png"))) self.connect(removeIconAction, SIGNAL("activated()"), self.parent().removeIcon) #ACTION TO DELETE THE MARKED DATATYPEICON deleteDataTypeAction = QAction("Delete Data Type", QKeySequence(), self, "deleteDataTypeAction") deleteDataTypeAction.setIconSet(QIconSet(QPixmap.fromMimeSource("delete16.png"))) self.connect(deleteDataTypeAction, SIGNAL("activated()"), self.myFrame.deleteSelectedDataType) #ACTION TO DELETE THE MARKED RELATIONTYPE deleteRelationTypeAction = QAction("Delete Relation Type", QKeySequence(), self, "deleteRelationTypeAction") deleteRelationTypeAction.setIconSet(QIconSet(QPixmap.fromMimeSource("delete16.png"))) self.connect(deleteRelationTypeAction, SIGNAL("activated()"), self.myFrame.deleteSelectedRelationType) #CONTEXT-MENU IF NOTHING IS MARKED if context == 0: newDataTypeAction.addTo(self) newRelationTypeAction.addTo(self) self.insertSeparator() self.insertItem("Arrange Icons...", subMenu01) updateCanvasViewAction.addTo(self) else: #CONTEXT-MENU IF A DATATYPE IS MARKED if context.iconType == 1: dataTypeController = data_type_dialog.DataTypeController(self.myFrame, context.iconLabel, self.myFrame.repositoryConfiguration) self.connect(editDataTypeAction, SIGNAL("activated()"), dataTypeController.show) editDataTypeAction.addTo(self) deleteDataTypeAction.addTo(self) self.insertSeparator() newDataTypeAction.addTo(self) newRelationTypeAction.addTo(self) self.insertSeparator() removeIconAction.addTo(self) self.insertItem("Arrange Icons...", subMenu01) updateCanvasViewAction.addTo(self) #CONTEXT-MENU IF A RELATIONTYPE IS MARKED if context.iconType == 2: relationTypeController = relation_type_dialog.RelationTypeController(self.myFrame, context.iconLabel, self.myFrame.repositoryConfiguration) self.connect(editRelationTypeAction, SIGNAL("activated()"), relationTypeController.show) editRelationTypeAction.addTo(self) deleteRelationTypeAction.addTo(self) self.insertSeparator() newDataTypeAction.addTo(self) newRelationTypeAction.addTo(self) self.insertSeparator() removeIconAction.addTo(self) self.insertItem("Arrange Icons...", subMenu01) updateCanvasViewAction.addTo(self) class CanvasView(QCanvasView): """ Implements the icon view. """ def __init__(self, parent, theFrame, name, f): """ Initiates the IconView that provides a canvas. """ QCanvasView.__init__(self, None, parent, name, f) self.__markedStart = None canvas = QCanvas(parent, "canvas") canvas.resize(1600, 1200) canvas.setAdvancePeriod(30) self.setCanvas(canvas) self.theFrame = theFrame self.__marked = 0 self.__movingStart = 0 def contentsMousePressEvent(self, e): # QMouseEvent e """ If mouse is clicked this function determines the choosen icon and marks it. """ for eachItem in self.canvas().allItems(): eachItem.unmark() if e != None: point = self.inverseWorldMatrix().map(e.pos()) ilist = self.canvas().collisions(point) #QCanvasItemList ilist for eachItem in ilist: if eachItem.getIconType() <= 2: if not eachItem.hit(point): continue eachItem.mark() if eachItem.iconType == 1: self.theFrame.dataNavigator.setCurrentPage(0) item = self.theFrame.dataTypeBrowser.findItem(eachItem.iconLabel, 0) self.theFrame.dataTypeBrowser.setSelected(item, True) if eachItem.iconType == 2: self.theFrame.dataNavigator.setCurrentPage(1) #item = self.theFrame.relationTypeBrowser.findItem(eachItem..tabTitle, 0) item = self.theFrame.relationTypeBrowser.findItem(eachItem.iconLabel, 0) self.theFrame.relationTypeBrowser.setSelected(item, True) self.__marked = eachItem self.__markedStart = point self.canvas().setAllChanged() self.canvas().update() return self.__marked = 0 self.canvas().setAllChanged() self.canvas().update() def contentsMouseMoveEvent(self, e): """ If mouse is moved the marked icon is dragged relatively to mouse movement. """ # pylint: disable=E1103 # It is ensured that self.__marked is not an integer if self.__marked : point = self.inverseWorldMatrix().map(e.pos()) self.__marked.moveBy(point.x() - self.__markedStart.x(), point.y() - self.__markedStart.y()) self.__markedStart = point def contextMenuEvent(self, e): """ If mouse is right clicked this function creates a context menu. """ self.contentsMousePressEvent(e) contextMenu = ContextMenu(self.theFrame, self, self.__marked, "contextMenu") contextMenu.popup(e.globalPos()) def countAllIcons(self): """ To count all visible icons on the canvas. """ iconNumber = 0 iconNumber += self.countIconTypes(1) iconNumber += self.countIconTypes(2) return iconNumber def countIconTypes(self, iconType): """ To count visible icons with type iconType. """ iconTypeNumber = 0 for eachItem in self.canvas().allItems(): if eachItem.iconType == iconType: iconTypeNumber += 1 return iconTypeNumber def getMarkedIcon(self): """ Returns the marked icon. If no icon is marked this function returns 0. """ return self.__marked def getIcon(self, iconLabel): """ Returns the icon with name iconLabel. """ for eachItem in self.canvas().allItems(): if eachItem.iconLabel == iconLabel: return eachItem def getAllIcons(self): """ Returns a list of all icons on the canvas. """ allIcons = [] for eachItem in self.canvas().allItems(): if eachItem.iconType != 3: allIcons.append(eachItem) return allIcons def clear(self): """ Removes all items from the canvas. """ ilist = self.canvas().allItems() for eachItem in ilist: if eachItem: eachItem.setCanvas(None) del eachItem self.canvas().update() def updateCanvasView(self): """ Updates the canvas and reinitializes all relations. """ for eachItem in self.canvas().allItems(): if eachItem.iconType == 2: eachItem.reinitialize() self.canvas().setAllChanged() self.canvas().update() def markDataTypeIcon(self, iconLabel): """ Marks a DataTypeIcon. """ self.markIcon(iconLabel, 1) def markRelationIcon(self, iconLabel): """ Marks a RelationIcon. """ self.markIcon(iconLabel, 2) def markIcon(self, iconLabel, iconType = 1): """ Marks an icon with type iconType. """ # pylint: disable=E1103 # It is ensured that self.__marked is not an integer self.__marked = 0 for eachItem in self.canvas().allItems(): if eachItem.iconType == iconType and eachItem.iconLabel == iconLabel: self.__marked = eachItem eachItem.unmark() if self.__marked != 0: self.__marked.mark() self.canvas().setAllChanged() self.canvas().update() def addDataTypeIcon(self, iconLabel, iconSet): """ Adds a DataTypeIcon to the canvas. """ icon = iconSet.pixmap(QIconSet.Automatic, QIconSet.Active) i = DataTypeIcon(icon, iconLabel, self.canvas()) i.setZ(255) i.show() self.updateCanvasView() def addRelationIcon(self, relationType, iconLabel, iconSet): """ Adds a RelationTypeIcon to the canvas. """ icon = iconSet.pixmap(QIconSet.Automatic, QIconSet.Active) i = RelationIcon(relationType, icon, iconLabel, self.canvas()) i.setZ(255) i.show() def removeIcon(self): """ Removes the marked icon from the canvas. """ # pylint: disable=E1103 # It is ensured that self.__marked is not an integer if self.getMarkedIcon() != 0: self.getMarkedIcon().destroyIcon() self.contentsMousePressEvent(None) self.canvas().update() def arrangeIconsInLines(self): """ Arranges all visible icons in lines. First the DataTypeIcons are arranged, then the RelationIcons. """ xPosition = 40 yPosition = 40 for iconType in range(1, 3): for eachItem in self.canvas().allItems(): if eachItem.iconType == iconType: eachItem.move(xPosition, yPosition) eachItem.updatePartialRelations() xPosition = xPosition + eachItem.width() + 20 if xPosition > 950: xPosition = 40 yPosition = yPosition + eachItem.height() + 40 xPosition = 40 yPosition = yPosition + 80 self.canvas().update() def arrangeIconsInCircle(self): """ Arranges all visible icons in a circle. """ xPosition = 0 yPosition = 0 iconTypeNumber = [] iconTypeRadius = [0, 0] iconTypeFactor = [20, 25] iconTypePosition = 0 iconTypeNumber.append(self.countIconTypes(1)) iconTypeNumber.append(self.countIconTypes(2)) for iconType in range(1, 3): if iconTypeNumber[iconType - 1] != 0: iconTypeAngle = 360.0 / iconTypeNumber[iconType - 1] iconTypeTotalAngle = 180.0 iconTypeRadius[iconType - 1] = iconTypeNumber[iconType - 1] * 400 / iconTypeFactor[iconType - 1] iconTypePosition = iconTypeRadius[0] + 50 for eachItem in self.canvas().allItems(): if eachItem.iconType == iconType: xPosition = int(iconTypePosition + iconTypeRadius[iconType - 1] * sin(iconTypeTotalAngle * 2 * pi / 360)) yPosition = int(iconTypePosition + iconTypeRadius[iconType - 1] * cos(iconTypeTotalAngle * 2 * pi / 360)) eachItem.move(xPosition, yPosition) eachItem.updatePartialRelations() iconTypeTotalAngle += iconTypeAngle self.canvas().update()
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/datamodel_iconview/canvas_view.py", "copies": "1", "size": "17096", "license": "bsd-3-clause", "hash": 4605164411108368400, "line_mean": 38.1314553991, "line_max": 129, "alpha_frac": 0.6105521759, "autogenerated": false, "ratio": 4.327005821311061, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.0046702175089464015, "num_lines": 426 }
""" This is the default data persister which is intended to store data and access data on the same file system. """ import atexit import logging import os import random from tempfile import mkstemp import time from hashlib import sha1 from datafinder.core.error import ItemError from datafinder.core.configuration.properties.constants import CONTENT_IDENTIFIER_ID, \ ARCHIVE_ROOT_COLLECTION_ID, \ ARCHIVE_PART_COUNT_ID, \ ARCHIVE_PART_INDEX_ID from datafinder.core.item.property import Property from datafinder.persistence.common.configuration import BaseConfiguration from datafinder.persistence.error import PersistenceError from datafinder.persistence.factory import FileSystem __version__ = "$Revision-Id:$" _log = logging.getLogger(__name__) _BLOCK_SIZE = 30000 def _generateUniqueIdentifier(uri): """ Generates an unique name from the given URI. """ firstTime = time.time() time.sleep(random.random()) secondTime = time.time() return sha1(uri + str(firstTime + secondTime)).hexdigest() class NullDataPersister(object): """ Null-pattern-like implementation of a data persister. Objects of this class are associated with items that own no binary data, e.g. simple collections. """ def __init__(self, dataState, fileStorer=None): """ Constructor. @param dataState: Data state constant associated with the item. @type dataState: C{unicode} @param fileStorer: The file storer is used to access the data. @type fileStorer: L{FileStorer<datafinder.persistence.factory.FileStorer>} """ self._dataState = dataState self._fileStorer = fileStorer def create(self): """ Performs additional actions on item creation. """ pass def delete(self): """ Performs additional actions on item deletion. """ pass def copy(self, item): """ Performs additional actions on item copying. @param item: The already created target item of the copy. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} """ pass def move(self, item): """ Performs additional actions on item moving. @param item: The new item after moving. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} """ pass def retrieveData(self, index=0): """ Retrieves the data associated with the referenced item. @param index: Optional parameter identifying the "block" where the required is contained. Default: C{0} @type index: C{int\ @return: File-like object usable for reading data. @rtype: C{object} implementing the file protocol. """ pass def storeData(self, fileObj): """ Writes the data to the associated file resource. @param fileObj: File-like object used for reading data. @type fileObj: C{object} implementing the file protocol. """ pass @property def fileStorer(self): """ Returns the encapsulated file storer. """ return self._fileStorer @property def state(self): """ Returns the data state constant. """ return self._dataState class DefaultDataPersister(NullDataPersister): """ This is the default data persister which is intended to store data and access data on the same file system. """ def __init__(self, dataState, fileStorer): """ Constructor. """ NullDataPersister.__init__(self, dataState, fileStorer) def retrieveData(self, index=0): """ Data is directly retrieved from the associated file storer object. """ _log.debug(index) return self._fileStorer.readData() def storeData(self, fileObj): """ Data is directly written to the associated file storer object. """ self._fileStorer.writeData(fileObj) class FlatDataPersister(DefaultDataPersister): """ Implements the data behavior allowing access to external storage resource. """ def __init__(self, dataState, baseFileStorer, item, propertyRegistry): """ Constructor. @param dataState: Data state constant associated with the item. @type dataState: C{unicode} @param item: Item data persister is associated with. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} @param baseFileStorer: The file storer representing the root collection of the separated storage system. @type baseFileStorer: L{FileStorer<datafinder.persistence.factory.FileStorer>} @param propertyRegistry: Reference to the property definition registry. @type propertyRegistry: L{PropertyDefinitionRegistry<datafinder.core.configuration. properties.registry.PropertyDefinitionRegistry>} """ DefaultDataPersister.__init__(self, dataState, None) self._baseFileStorer = baseFileStorer self._item = item self._propertyRegistry = propertyRegistry if CONTENT_IDENTIFIER_ID in item.properties: uniqueName = item.properties[CONTENT_IDENTIFIER_ID].value self._fileStorer = self._baseFileStorer.getChild(uniqueName) def _prepareAction(self): """ Helper method performing common preparation steps. """ if self._fileStorer is None: uniqueName = _generateUniqueIdentifier(self._item.uri) self._fileStorer = self._baseFileStorer.getChild(uniqueName) def create(self): """ Initially creates the referenced file resource on the separated storage system. Additionally, sets the content identifier property in the item properties. This is required to identify the resource on the separated storage system. """ self._prepareAction() if self._fileStorer.exists(): raise ItemError("The unique identifier '%s' generated for item '%s' does already exist." \ % (self._fileStorer.name, self._item.path)) else: self._fileStorer.createResource() propertyDefinition = self._propertyRegistry.getPropertyDefinition(CONTENT_IDENTIFIER_ID) self._item.updateProperties([Property(propertyDefinition, self._fileStorer.name)]) if not CONTENT_IDENTIFIER_ID in self._item.properties: raise ItemError("Unable to set the unique identifier property " \ + "to '%s' for item '%s'." % (self._fileStorer.name, self._item.path)) def delete(self): """ Additionally performs deletion of the file resource on separated storage system. """ self._prepareAction() self._fileStorer.delete() def copy(self, item): """ Duplicates resource with the help of the data persister of the newly created target item. Updates the properties of the target item accordingly. """ self._prepareAction() uniqueName = _generateUniqueIdentifier(item.uri) targetFileStorer = self._baseFileStorer.getChild(uniqueName) self._fileStorer.copy(targetFileStorer) propertyDefinition = self._propertyRegistry.getPropertyDefinition(CONTENT_IDENTIFIER_ID) item.updateProperties([Property(propertyDefinition, uniqueName)]) item._dataPersister = None if not CONTENT_IDENTIFIER_ID in item.properties: raise ItemError("Unable to set the unique identifier property " \ + "to '%s' for item '%s'." % (uniqueName, item.path)) def retrieveData(self, index=0): """ Additionally ensure creation of the file storer instance. """ _log.debug(index) self._prepareAction() return DefaultDataPersister.retrieveData(self) def storeData(self, fileObj): """ Additionally ensure creation of the file storer instance. """ self._prepareAction() return DefaultDataPersister.storeData(self, fileObj) class HierarchicalDataPersister(DefaultDataPersister): """ Implements the data behavior allowing access to external storage resource. """ def __init__(self, dataState, fileStorer): """ Constructor. @param dataState: Data state constant associated with the item. @type dataState: C{unicode} @param fileStorer: The file storer representing the associated file resource. @type fileStorer: L{FileStorer<datafinder.persistence.factory.FileStorer>} """ DefaultDataPersister.__init__(self, dataState, fileStorer) def create(self): """ Creates the file resource on separated storage system under the path of the item. """ if not self._fileStorer.exists(): self._createParentCollection(self._fileStorer.parent) self._fileStorer.createResource() else: errorMessage = "The data persister '%s' does already exist." % (self._fileStorer.identifier) raise ItemError(errorMessage) def delete(self): """ Deletes on the file resource on separated storage system and cleans up created directories. """ self._fileStorer.delete() self._cleanupCollections() def _cleanupCollections(self): """ Removes empty collections. """ parent = self._fileStorer.parent while parent.name != "" and len(parent.getChildren()) == 0: parent.delete() parent = parent.parent def copy(self, item): """ Duplicates the file resource under the path of the given target item. """ destFileStorer = item.dataPersister.fileStorer self._createParentCollection(destFileStorer.parent) self._fileStorer.copy(destFileStorer) def move(self, item): """ Move the file resource to the path of the target item. """ destFileStorer = item.dataPersister.fileStorer self._createParentCollection(destFileStorer.parent) self._fileStorer.move(destFileStorer) self._cleanupCollections() @staticmethod def _createParentCollection(fileStorer): """ Helper function for creation of parent collection/directory structure. """ if not fileStorer.exists(): fileStorer.createCollection(True) class ArchiveDataPersister(DefaultDataPersister): """ This class implements a data persister that can retrieve and store data of archive root. """ def __init__(self, dataState, item, baseDataPersister): """ Constructor. @param dataState: Data state constant associated with the item. @type dataState: C{unicode} @param item: The item this persister is associated with. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} @param baseDataPersister: The data persister used to store data. @type baseDataPersister: L{DefaultDataPersister<datafinder.core.item.data_persister.persisters.DefaultDataPersister>} """ super(ArchiveDataPersister, self).__init__(dataState, None) self._item = item self._baseDataPersister = baseDataPersister self._count = int(item.properties[ARCHIVE_PART_COUNT_ID].value) @property def fileStorer(self): """ Returns the file storer object of the associated data persister. """ return self._baseDataPersister.fileStorer def create(self): """ @see: L{create<datafinder.core.item.data_persister.persisters.NullDataPersister.create>} """ self._baseDataPersister.create() def delete(self): """ @see: L{delete<datafinder.core.item.data_persister.persisters.NullDataPersister.delete>} """ if self._count > 0: for index in range(1, self._count): self._determineFileStorer(index).delete() self._baseDataPersister.delete() def _determineFileStorer(self, index=0): """ Returns the file storer associated with given index. """ fileStorer = self._baseDataPersister.fileStorer name = fileStorer.name if index > 0: name += "_" + str(index) return fileStorer.parent.getChild(name) def copy(self, item): """ @see: L{copy<datafinder.core.item.data_persister.persisters.NullDataPersister.copy>} """ self._baseDataPersister.copy(item) destBaseName = item.dataPersister.fileStorer.name destBaseFileStorer = item.dataPersister.fileStorer.parent for index in range(1, self._count): fileStorer = self._determineFileStorer(index) fileStorer.copy(destBaseFileStorer.getChild(destBaseName + "_" + str(index))) def move(self, item): """ @see: L{move<datafinder.core.item.data_persister.persisters.NullDataPersister.move>} """ if item.dataUri != self._item.dataUri: if not item.dataPersister.fileStorer.parent.exists(): item.dataPersister.fileStorer.parent.createCollection(True) destBaseName = item.dataPersister.fileStorer.name destBaseFileStorer = item.dataPersister.fileStorer.parent for index in range(1, self._count): fileStorer = self._determineFileStorer(index) fileStorer.move(destBaseFileStorer.getChild(destBaseName + "_" + str(index))) self._baseDataPersister.move(item) def retrieveData(self, index=0): """ @see: L{retrieveData<datafinder.core.item.data_persister.persisters.NullDataPersister.retrieveData>} """ _log.debug(index) return self._determineFileStorer(index).readData() def storeData(self, fileObj): """ @see: L{storeData<datafinder.core.item.data_persister.persisters.NullDataPersister.storeData>} """ fileStorer = self._determineFileStorer(self._count) property_ = self._item.properties[ARCHIVE_PART_COUNT_ID] property_.value = property_.value + 1 self._item._ignoreChecks = True try: self._item.updateProperties([property_]) self._count += 1 try: if not fileStorer.exists(): fileStorer.createResource() fileStorer.writeData(fileObj) except PersistenceError, error: self._count -= 1 property_.value = property_.value - 1 self._item.updateProperties([property_]) raise error finally: self._item._ignoreChecks = False class ArchiveMemberDataPersister(NullDataPersister): """ This class implements a data persister that can retrieve and store data of archive members. """ def __init__(self, dataState, item, rootItem, propertyRegistry): """ Constructor. @param dataState: Data state constant associated with the item. @type dataState: C{unicode} @param item: The item this persister is associated with. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} @param rootItem: The item that represents the stored archive (i.e. the ZIP file). @type rootItem: L{ItemBase<datafinder.core.item.base.ItemBase} @param propertyRegistry: Reference to the property definition registry. @type propertyRegistry: L{PropertyDefinitionRegistry<datafinder.core.configuration. properties.registry.PropertyDefinitionRegistry>} """ super(ArchiveMemberDataPersister, self).__init__(dataState, None) self._item = item self._propertyRegistry = propertyRegistry self._rootItem = rootItem self._fileSystem = None self._index = int(item.properties[ARCHIVE_PART_INDEX_ID].value) def _ensureReadableSystem(self): """ Make sure, self._archiveFileSystem contains a valid readable file system. If none is present, the corresponding ZIP file will be downloaded. """ if self._fileSystem is None: key = self._rootItem.path + str(self._index) if key in _temporaryFileMap: self._fileSystem = _temporaryFileMap[key][1] else: fd, path = mkstemp() fileHandle = os.fdopen(fd, "w+b") inStream = self._rootItem.dataPersister.retrieveData(self._index) try: block = inStream.read(_BLOCK_SIZE) while len(block) > 0: fileHandle.write(block) block = inStream.read(_BLOCK_SIZE) while len(block) > 0: fileHandle.write(block) block = inStream.read(_BLOCK_SIZE) fileHandle.close() except (OSError, IOError), error: reason = os.strerror(error.errno or 0) raise ItemError("Cannot retrieve archive.\nReason: '%s'" % reason) else: config = BaseConfiguration('arch:' + path) _log.debug("Downloaded %s to %s." % (self._rootItem.path, path)) self._fileSystem = FileSystem(config) _temporaryFileMap[key] = (path, self._fileSystem) def copy(self, item): """ @see: L{copy<datafinder.core.item.data_persister.persisters.NullDataPersister.copy>} """ self.move(item) def move(self, item): """ @see: L{move<datafinder.core.item.data_persister.persisters.NullDataPersister.move>} """ pathWithoutRootArchive = self._item.path[len(self._rootItem.path):] newArchiveRootPath = item.path[:item.path.rfind(pathWithoutRootArchive)] propDef = self._propertyRegistry.getPropertyDefinition(ARCHIVE_ROOT_COLLECTION_ID) archiveRootProperty = Property(propDef, newArchiveRootPath) item.updateProperties([archiveRootProperty]) def retrieveData(self, index=0): """ @see: L{retrieveData<datafinder.core.item.data_persister.persisters.NullDataPersister.retrieveData>} """ _log.debug(index) self._ensureReadableSystem() return self.fileStorer.readData() @property def fileStorer(self): """ Returns the encapsulated file storer. """ if self._fileSystem is None: self._ensureReadableSystem() if self._fileStorer is None: innerPath = self._item.path[len(self._rootItem.path):] self._fileStorer = self._fileSystem.createFileStorer(innerPath) return self._fileStorer _temporaryFileMap = dict() def _cleanupTemporaryFiles(): """ Cleans up the temporary created files on application exit. """ for filePath, fileSystem in _temporaryFileMap.values(): try: fileSystem.release() os.remove(filePath) except (OSError, PersistenceError): _log.error("Cannot clean up temporary file '%s'" % filePath) atexit.register(_cleanupTemporaryFiles)
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/core/item/data_persister/persisters.py", "copies": "1", "size": "22003", "license": "bsd-3-clause", "hash": 3848147038925267000, "line_mean": 37.7884267631, "line_max": 125, "alpha_frac": 0.6148706995, "autogenerated": false, "ratio": 4.453147136207246, "config_test": true, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5568017835707246, "avg_score": null, "num_lines": null }
""" Controller of the property view. """ from PyQt4 import QtCore from datafinder.gui.user.common.delegate import AbstractDelegate from datafinder.gui.user.common import util from datafinder.gui.user.common.controller import AbstractController __version__ = "$Revision-Id:$" class PropertiesController(AbstractController): """ Controls the property view. """ def __init__(self, mainWindow, parentController): """ Constructor. """ AbstractController.__init__(self, mainWindow.serverAttributeTableView, mainWindow, parentController=parentController) self.horizontalHeader().setSortIndicator(0, QtCore.Qt.AscendingOrder) self._delegates = [_PropertiesDelegate(self)] class _PropertiesDelegate(AbstractDelegate): """ This delegate is responsible for all user interaction with the view. """ def __init__(self, controller): """ Constructor. """ AbstractDelegate.__init__(self, controller) @util.immediateConnectionDecorator("widget", "modelUpdateSignal") def _setSortingEnabled(self): """ Enables the sorting behavior. """ self._controller.setSortingEnabled(True) @util.immediateConnectionDecorator(["serverTableSelectionModel", "serverTreeSelectionModel"], "currentChanged(QModelIndex, QModelIndex)") def _propertySelectionSlot(self, index, __): """ Slot is called when a item was selected in the tree/table or list view. @param index: The selected index. @type index: L{QModelIndex<PyQt4.QtCore.QModelIndex>} """ if index.isValid(): try: index = index.model().mapToSource(index) except AttributeError: index = index node = index.model().nodeFromIndex(index) self._controller.model.itemIndex = index self._mainWindow.serverPropertiesDockWidget.setWindowTitle("Properties of %s" % node.name) else: self._mainWindow.serverPropertiesDockWidget.setWindowTitle("Properties") @util.immediateConnectionDecorator("model", "modelReset()") def _modelResetSlot(self): """ Handles the reset signal of the property model. """ self._mainWindow.serverPropertiesDockWidget.setWindowTitle("Properties")
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/user/controller/repository/properties.py", "copies": "1", "size": "4173", "license": "bsd-3-clause", "hash": 7857777323599324000, "line_mean": 34.9292035398, "line_max": 125, "alpha_frac": 0.6812844476, "autogenerated": false, "ratio": 4.482277121374866, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.011134092055998383, "num_lines": 113 }
""" Login dialog (including a line for URL-input). """ from qt import PYSIGNAL, SLOT, SIGNAL from datafinder.gui.gen import FullLoginDialog __version__ = "$Revision-Id:$" class LoginDialog(FullLoginDialog.FullLoginDialogForm): """ Login-dialog providing url, username, and password. """ def __init__(self, preferences, parent=None, showurl=True): FullLoginDialog.FullLoginDialogForm.__init__(self, modal=True, parent=parent) self.connect(self.okPushButton, PYSIGNAL("quit"), SLOT("reject()")) # reset URL-combobox: self.davserverComboBox.clear() # Show or hide URL-combobox: self.showUrl(showurl) self._preferences = preferences self.connect(self.davserverComboBox, SIGNAL("textChanged(const QString&)"), self._uriChangedSlot) self.presetUrlList() def _uriChangedSlot(self, newUri): """ Handles the change of the selected URI. """ newUri = unicode(newUri) configuration = self._preferences.getConnection(newUri) if not configuration is None: self.presetUsername(configuration.username) self.presetPassword(configuration.password) def setAuthenticationRequired(self, authenticationRequired): """ Sets the user name and password line edit in accordance to required authentication. """ self.usernameLineEdit.setEnabled(authenticationRequired) self.passwordLineEdit.setEnabled(authenticationRequired) self.savePasswordCheckBox.setEnabled(authenticationRequired) def showUrl(self, show): """ Make URL-comboxbox visible/invisible. @param show: flag @type show: boolean """ self.davserverComboBox.setHidden(not(show)) self.davserverTextLabel.setHidden(not(show)) self.adjustSize() def presetUrl(self, url): """ Initialize URL-input-field. @param url: URL of (WebDAV-)server @type url: string """ self.davserverComboBox.clear() self.davserverComboBox.insertItem(url) self.usernameLineEdit.setFocus() def presetUrlList(self): """ Initialize URL-input-list/combobox. """ self.davserverComboBox.clear() for uri in self._preferences.connectionUris: if not uri is None: self.davserverComboBox.insertItem(uri) self.usernameLineEdit.setFocus() def presetUsername(self, user): """ Initialize username-input-field. @param user: username @type user: string """ self.usernameLineEdit.setText(user or "") self.passwordLineEdit.setFocus() def presetPassword(self, password): """ Initialize password-input-field. @param password: password of user @type password: string """ self.passwordLineEdit.setText(password or "") self.savePasswordCheckBox.setChecked(not password is None) self.passwordLineEdit.setFocus() def setSavePassword(self, booleanValue): """ Set "save-password?"-checkbox. @param booleanValue: flag @type booleanValue: boolean """ self.savePasswordCheckBox.setChecked(booleanValue) def getSavePassword(self): """ Check state of "save-password"-checkbox. @return: flag if password will be saved @rtype: boolean """ return self.savePasswordCheckBox.isChecked() def loginOkSlot(self): """ Slot for ok-button. A Qt-SIGNAL "updateWebdavServerView" is emitted (url, username, password as parameters). """ webdavUrl = unicode(self.davserverComboBox.currentText()).strip() webdavUser = unicode(self.usernameLineEdit.text()) webdavPassword = unicode(self.passwordLineEdit.text()) self.okPushButton.emit(PYSIGNAL("quit"), ()) self.okPushButton.emit(PYSIGNAL("updateWebdavServerView"), (webdavUrl, webdavUser, webdavPassword))
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/login_dialog.py", "copies": "1", "size": "5917", "license": "bsd-3-clause", "hash": -5888394971210118000, "line_mean": 31.6193181818, "line_max": 107, "alpha_frac": 0.6579347642, "autogenerated": false, "ratio": 4.382962962962963, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.0056464479474967084, "num_lines": 176 }
""" This module contains the properties model. """ from PyQt4 import QtCore, QtGui from datafinder.gui.user.common.util import \ extractPyObject, determineDisplayRepresentation, determinePropertyDefinitionToolTip from datafinder.core.configuration.properties import constants from datafinder.core.configuration.properties.domain import DomainObject from datafinder.core.configuration.properties.property_type import \ determinePropertyTypeConstant, PROPERTY_TYPE_NAMES from datafinder.core.error import PropertyError __version__ = "$Revision-Id:$" class PropertiesModel(QtCore.QAbstractTableModel): """ This model represents a set of properties. """ PROPERTY_STATE_CHANGED_SIGNAL = "propertyStateChanged" IS_CONSISTENT_SIGNAL = "isConsistentSignal" _SYSTEM = 1 _DATA = 2 _PROP = 4 _NEW = 8 _DELETED = 16 _EDITED = 32 _REQUIRED_NOT_SET = 64 _DOMAIN_PROPERTY = 128 # Used until there is a complete editor def __init__(self, repositoryModel, trackRepositoryUpdates=True): """ @param repositoryModel: The parent model which handles access to item of the data repository. @type repositoryModel: L{RepositoryModel<datafinder.gui.user.models.repository.RepositoryModel>} @param trackRepositoryUpdates: Optional flag determining whether the property model reacts on changes of the repository. Default: C{true} @type trackRepositoryUpdates: C{bool} """ QtCore.QAbstractTableModel.__init__(self) self._sortedColumn = 0 self._sortedOrder = QtCore.Qt.AscendingOrder self._headers = [self.tr("Name"), self.tr("Type"), self.tr("Value")] self._itemIndex = None self.isReadOnly = False self._isConsistent = False self.itemName = "" self._repositoryModel = repositoryModel self._properties = list(list()) if trackRepositoryUpdates: self.connect(self._repositoryModel, QtCore.SIGNAL("itemDataChanged"), self._handleUpdateSlot) self.connect(self._repositoryModel, QtCore.SIGNAL("modelReset()"), self.clear) def _handleUpdateSlot(self, index): """ Updates properties if the displayed item changed . """ try: if index.row() == self._itemIndex.row(): self.itemIndex = index self.reset() self._emitPropertyDataChanged() except AttributeError: pass # Nothing to do, index has already been handled. def _emitPropertyDataChanged(self): """ Emits the signal C{self.PROPERTY_STATE_CHANGED_SIGNAL}. """ self.emit(QtCore.SIGNAL(self.PROPERTY_STATE_CHANGED_SIGNAL)) def load(self, properties): """ Initializes the model with the given properties. @param properties: Properties represented by this model. @type properties: C{list} of L{Property<datafinder.core.item.property.Property>} """ self._properties = list(list()) propertyIds = list() for prop in properties: propDef = prop.propertyDefinition state = self._determinePropertyState(propDef.category) if not propDef.identifier in propertyIds and not state is None: propertyIds.append(propDef.identifier) value = prop.value if (not propDef.type in PROPERTY_TYPE_NAMES or isinstance(value, DomainObject)): state |= self._DOMAIN_PROPERTY displayPropertyTypeName = self._determinePropertyTypeName(propDef.type, value) self._properties.append([propDef.displayName, displayPropertyTypeName, value, propDef, propDef.restrictions, propDef.type, value, state]) self._checkConsistency() def _checkConsistency(self): """ Checks whether all properties are set correctly. """ self._isConsistent = True for prop in self._properties: try: propDef = prop[3] if not propDef is None: prop[3].validate(prop[2]) if prop[-1] & self._REQUIRED_NOT_SET: prop[-1] ^= self._REQUIRED_NOT_SET # Remove the "Not Set" flag except PropertyError: prop[-1] |= self._REQUIRED_NOT_SET self._isConsistent = False self.emit(QtCore.SIGNAL(self.IS_CONSISTENT_SIGNAL), self._isConsistent) @staticmethod def _determinePropertyState(category): """ Determines the internal state of the property. E.g. data model specific. """ if category in (constants.UNMANAGED_SYSTEM_PROPERTY_CATEGORY, constants.MANAGED_SYSTEM_PROPERTY_CATEGORY): state = PropertiesModel._SYSTEM elif category == constants.DATAMODEL_PROPERTY_CATEGORY: state = PropertiesModel._DATA elif category == constants.USER_PROPERTY_CATEGORY: state = PropertiesModel._PROP else: state = None return state @staticmethod def _determinePropertyTypeName(propertyType, value): """ Determines the display name of the property type. """ displayPropertyTypeName = propertyType if propertyType == constants.ANY_TYPE: if value is None: displayPropertyTypeName = constants.STRING_TYPE else: displayPropertyTypeName = determinePropertyTypeConstant(value) dotIndex = displayPropertyTypeName.rfind(".") if dotIndex > 0: startIndex = dotIndex + 1 if not startIndex >= len(displayPropertyTypeName): displayPropertyTypeName = displayPropertyTypeName[startIndex:] return displayPropertyTypeName def rowCount(self, _=QtCore.QModelIndex()): """ @see: L{rowCount<PyQt4.QtCore.QAbstractTableModel.rowCount>} """ return len(self._properties) def columnCount(self, _): """ @see: L{columnCount<PyQt4.QtCore.QAbstractTableModel.columnCount>} """ return len(self._headers) def headerData(self, section, orientation, role = QtCore.Qt.DisplayRole): """ @see: L{headerData<PyQt4.QtCore.QAbstractTableModel.headerData>} """ if orientation == QtCore.Qt.Horizontal: if role == QtCore.Qt.DisplayRole: return QtCore.QVariant(self._headers[section]) if role == QtCore.Qt.TextAlignmentRole: return QtCore.QVariant(int(QtCore.Qt.AlignLeft | QtCore.Qt.AlignVCenter)) return QtCore.QVariant() def data(self, index, role=QtCore.Qt.DisplayRole): """ @see: L{data<PyQt4.QtCore.QAbstractTableModel.data>} """ row = index.row() column = index.column() variant = QtCore.QVariant() if role == QtCore.Qt.DisplayRole: variant = self._getValueDisplayRepresentation(row, index) elif role == QtCore.Qt.BackgroundColorRole: state = self._properties[row][-1] attribute = QtGui.QColor(QtCore.Qt.white) if state & self._DELETED: attribute = QtGui.QColor(255, 100, 100) elif state & self._NEW: attribute = QtGui.QColor(100, 255, 100) elif state & self._REQUIRED_NOT_SET: attribute = QtGui.QColor(255, 255, 0) elif state & self._EDITED: attribute = QtGui.QColor(240, 240, 240) variant = QtCore.QVariant(attribute) elif role == QtCore.Qt.ToolTipRole: propertyEntry = self._properties[index.row()] if column == 0: if not propertyEntry[3] is None: variant = determinePropertyDefinitionToolTip(propertyEntry[3]) elif column == 2: variant = self._getValueDisplayRepresentation(row, index) return variant def _getValueDisplayRepresentation(self, row, index): value = self._properties[row][index.column()] if index.column() == 2: propDef = self._properties[row][3] propId = None if not propDef is None: propId = propDef.identifier variant = QtCore.QVariant(determineDisplayRepresentation(value, propId)) else: variant = QtCore.QVariant(value) return variant def setData(self, index, value, _=None): """ @see: L{setData<PyQt4.QtCore.QAbstractTableModel.setData>} """ row = index.row() column = index.column() value = extractPyObject(value) try: changed = cmp(self._properties[row][column], value) except TypeError: changed = True if changed: self._properties[row][column] = value if not self._properties[row][-1] & self._NEW: self._properties[row][-1] |= self._EDITED self._checkConsistency() if column == 1: self._properties[row][2] = None self._checkConsistency() if self._properties[row][0] is None: self.beginRemoveRows(QtCore.QModelIndex(), row, row) del self._properties[row] self.endRemoveRows() self._emitPropertyDataChanged() return False self.emit(QtCore.SIGNAL("dataChanged(QModelIndex, QModelIndex)"), index, index) self._emitPropertyDataChanged() return True def flags(self, index): """ @see: L{flags<PyQt4.QtCore.QAbstractTableModel.flags>} """ state = self._properties[index.row()][-1] flags = QtCore.Qt.ItemIsSelectable | QtCore.Qt.ItemIsEnabled if not self.isReadOnly: if state & self._NEW \ or (state & (self._DATA|self._PROP) and index.column() == 2) \ or (self._properties[index.row()][5] == constants.ANY_TYPE and state & (self._DATA|self._PROP) and index.column() == 1): flags |= QtCore.Qt.ItemIsEnabled if (not state & self._DELETED and not state & self._DOMAIN_PROPERTY): flags |= QtCore.Qt.ItemIsEditable return flags def sort(self, column, order=QtCore.Qt.AscendingOrder): """ @see: L{sort<PyQt4.QtCore.QAbstractTableModel.sort>} """ self._sortedColumn = column self._sortedOrder = order self.emit(QtCore.SIGNAL("layoutAboutToBeChanged()")) self._properties.sort(reverse = (order == QtCore.Qt.DescendingOrder), cmp=lambda x, y: cmp(determineDisplayRepresentation(x[column]).lower(), determineDisplayRepresentation(y[column]).lower())) self.emit(QtCore.SIGNAL("layoutChanged()")) def save(self): """ Saves property modifications of the given item. """ dirty = False for row in self._properties: state = row[-1] if state & (self._EDITED|self._NEW| self._DELETED): dirty = True if dirty: self._updateProperties(self._properties) def _updateProperties(self, properties): """ Converts the data saved in the model back to its internally used representation and stores it. """ addedEditedProperties = list() deletableProperties = list() for prop in properties: state = prop[-1] if state & self._DELETED: deletableProperties.append(prop[0]) elif state & self._NEW: newProperty = self._repositoryModel.repository.createProperty(prop[0], prop[2]) addedEditedProperties.append(newProperty) elif state & self._EDITED: newProperty = self._repositoryModel.repository.createPropertyFromDefinition(prop[3], prop[2]) addedEditedProperties.append(newProperty) if len(addedEditedProperties) > 0 or len(deletableProperties) > 0: if not self._itemIndex is None: self._repositoryModel.updateProperties(self._itemIndex, addedEditedProperties, deletableProperties) def clear(self): """ Clears the model internal data and resets the model. """ self._itemIndex = None self._properties = list() self.reset() def refresh(self): """ Reloads all data from the server and resets the data model. """ if not self._itemIndex is None: self._repositoryModel.refresh(self._itemIndex, True) self.itemIndex = self._itemIndex self.sort(self._sortedColumn, self._sortedOrder) self.reset() self._emitPropertyDataChanged() def add(self): """ Appends a "blank" property to the existing properties. @return: The index the new property. @rtype: L{QModelIndex<PyQt4.QtCore.QModelIndex>} """ row = self.rowCount() self.beginInsertRows(QtCore.QModelIndex(), row, row) self._properties.append([None, None, None, None, None, constants.ANY_TYPE, None, self._NEW]) self.endInsertRows() index = self.createIndex(row, 0, self._properties[row][0]) self.emit(QtCore.SIGNAL("dataChanged(QModelIndex, QModelIndex)"), index, index) self._emitPropertyDataChanged() return index def clearValue(self, index): """ Clears the value of the property, i.e. set it to C{None}. @param index: The index that has to be cleared. @type index: L{QModelIndex<PyQt4.QtCore.QModelIndex>} """ self.emit(QtCore.SIGNAL("layoutAboutToBeChanged()")) self._properties[index.row()][2] = None self._properties[index.row()][-1] |= self._EDITED self._checkConsistency() self.emit(QtCore.SIGNAL("layoutChanged()")) self.emit(QtCore.SIGNAL("dataChanged(QModelIndex, QModelIndex)"), index, index) self._emitPropertyDataChanged() def remove(self, index): """ iF the item is new it will be deleted instantly. Otherwise the property will be deleted after a save operation. @param index: The index that has to be removed. @type index: L{QModelIndex<PyQt4.QtCore.QModelIndex>} """ row = index.row() props = self._properties[row][-1] if not props & self._NEW | self._PROP: raise ValueError("Given index at %d, %d can not be deleted." % (row, index.column())) if props & self._NEW: self.beginRemoveRows(QtCore.QModelIndex(), row, row) del self._properties[row] self.endRemoveRows() else: self.emit(QtCore.SIGNAL("layoutAboutToBeChanged()")) self._properties[row][-1] |= self._DELETED self.emit(QtCore.SIGNAL("layoutChanged()")) self.emit(QtCore.SIGNAL("dataChanged(QModelIndex, QModelIndex)"), index, index) self._emitPropertyDataChanged() def revert(self, index=None): """ If the given index has the status deleted, this method removes the deleted status. @param index: The index that has to be reverted. @type index: L{QModelIndex<PyQt4.QtCore.QModelIndex>} """ if not index is None: row = index.row() self.emit(QtCore.SIGNAL("layoutAboutToBeChanged()")) if self._properties[row][-1] & self._DELETED: self._properties[row][-1] ^= self._DELETED elif self._properties[row][-1] & self._EDITED: originalValue = self._properties[row][6] originalType = self._determinePropertyTypeName(self._properties[row][5], originalValue) self._properties[row][1] = originalType self._properties[row][2] = originalValue self._properties[row][-1] ^= self._EDITED self._checkConsistency() self.emit(QtCore.SIGNAL("layoutChanged()")) self.emit(QtCore.SIGNAL("dataChanged(QModelIndex, QModelIndex)"), index, index) self._emitPropertyDataChanged() def _isPropertyNameUnique(self, propertyName): for item in self._properties: existingIdentifer = item[0] if not item[3] is None: existingIdentifer = item[3].identifier if existingIdentifer == propertyName: return False return True def isDeleteable(self, index): """ @param index: Index that has to be checked. @type index: L{QModelIndex<PyQt4.QtCore.QModelIndex>} @return: C{True} if the index can be deleted else C{False}. @rtype: C{bool} """ state = self._properties[index.row()][-1] return (bool(state & (self._NEW | self._PROP)) and not bool(state & self._DELETED)) def isRevertable(self, index): """ @param index: Index that has to be checked. @type index: L{QModelIndex<PyQt4.QtCore.QModelIndex>} @return: C{True} if the index can be reverted else c{False}. @rtype: C{bool} """ state = self._properties[index.row()][-1] return (bool(state & (self._DELETED | self._EDITED)) and not bool(state & self._NEW)) def canBeCleared(self, index): """ @param index: Index that has to be checked. @type index: L{QModelIndex<PyQt4.QtCore.QModelIndex>} @return: C{True} if the index can be cleared else C{False}. @rtype: C{bool} """ state = self._properties[index.row()][-1] return (not bool(state & self._SYSTEM) and not bool(state & self._DOMAIN_PROPERTY) and not self._properties[index.row()][2] is None) def getModelData(self, row, column): """ This function allows direct access the model data structure. """ return self._properties[row][column] @property def hasCustomMetadataSupport(self): """ Checks whether custom meta data can be set. """ return self._repositoryModel.hasCustomMetadataSupport @property def propertyNameValidationFunction(self): """ Detects the property name validator. """ def _wrapper(inputString): return self._repositoryModel.repository.configuration.propertyNameValidationFunction(inputString) \ and self._isPropertyNameUnique(inputString) return _wrapper @property def dirty(self): """ @return: C{True} if the data has changed else C{False}. @rtype: C{bool} """ for item in self._properties: if item[-1] & (self._EDITED | self._DELETED | self._NEW): return True return False @property def sortProperties(self): """ @return: The properties for the sorting, i.e. sorted column number and sort order. @rtype: C{tuple} """ return self._sortedColumn, self._sortedOrder @property def properties(self): """ @return: List of property instances contained in this model. @rtype: C{list} of L{Property<datafinder.core.item.property.Property>} """ properties = list() for prop in self._properties: if prop[-1] & self._NEW: newProperty = self._repositoryModel.repository.createProperty(prop[0], prop[2]) else: newProperty = self._repositoryModel.repository.createPropertyFromDefinition(prop[3], prop[2]) properties.append(newProperty) return properties @property def isConsistent(self): """ Checks whether all properties are set correctly. """ return self._isConsistent def _setItemIndex(self, index): """ Set the index from which the properties have to be loaded. In the most cases this is the current selected index in the view. @param itemIndex: The itemIndex from which the properties has to be loaded. @type itemIndex: L{QModelIndex<PyQt4.QtCore.QModelIndex>} """ self.reset() self._properties = list(list()) self.isReadOnly = True if index.isValid(): item = self._repositoryModel.nodeFromIndex(index) if item.isLink: item = item.linkTarget if not item is None: if not item.path is None: self._itemIndex = self._repositoryModel.indexFromPath(item.path) self.itemName = item.name self.isReadOnly = not item.capabilities.canStoreProperties properties = item.properties.values() self.load(properties) self.sort(self._sortedColumn, self._sortedOrder) itemIndex = property(fset=_setItemIndex)
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/user/models/properties.py", "copies": "1", "size": "23492", "license": "bsd-3-clause", "hash": -7401007111633544000, "line_mean": 38.9268292683, "line_max": 135, "alpha_frac": 0.5920313298, "autogenerated": false, "ratio": 4.502971056162545, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5595002385962545, "avg_score": null, "num_lines": null }
""" The class draws a partial relation (a line) from a DataTypeIcon to a RelationTypeIcon """ from qt import Qt, QBrush, QColor, QPointArray from qtcanvas import QCanvasPolygon __version__ = "$Revision-Id:$" class PartialRelationIcon(QCanvasPolygon): """ Represents a partial relation. """ def __init__(self, relCnvs, relIcn, colIcn, relType): """ initiates the partial relation and sets the connected relation and collection icon """ QCanvasPolygon.__init__(self, relCnvs) self.relationIcon = relIcn self.collectionIcon = colIcn self.relationType = relType self.iconLabel = "" self.iconType = 3 self.lineWidth = 1 self.relPoints = QPointArray(8) self.collectionIcon.partialRelations.append(self) self.unmark() def mark(self): """ to highlight the partial relation and connection relation and collection (if they're not marked yet) """ if self.relationType == 0: self.setBrush(QBrush(QColor(0, 0, 255), Qt.SolidPattern)) else: self.setBrush(QBrush(QColor(0, 180, 0), Qt.SolidPattern)) self.setZ(200) self.lineWidth = 2 if self.relationIcon.isMarked != 1: self.relationIcon.mark(False) if self.collectionIcon.isMarked != 1: self.collectionIcon.mark(False) self.setCoords() def unmark(self): """ to turn off the highlight of this partial relation and the connected collection and relation icon """ self.setZ(0) self.lineWidth = 1 if self.relationType == 0: self.setBrush(QBrush(QColor(200, 200, 255), Qt.SolidPattern)) else: self.setBrush(QBrush(QColor(200, 255, 200), Qt.SolidPattern)) self.relationIcon.unmark(False) self.collectionIcon.unmark(False) self.setCoords() def getIconType(self): """ return iconType """ return self.iconType def setCoords(self): """ to set the coordinates of the drawn polygon depending on the position of connected relation and collection icon """ relAnchorPoint = self.relationIcon.getAnchorPoint() colAnchorPoint = self.collectionIcon.getAnchorPoint() self.relPoints.setPoint(0, relAnchorPoint) if self.relationType == 0: self.relPoints.setPoint(1, relAnchorPoint.x(), (relAnchorPoint.y() + colAnchorPoint.y()) / 2) self.relPoints.setPoint(2, colAnchorPoint.x(), (relAnchorPoint.y() + colAnchorPoint.y()) / 2) else: self.relPoints.setPoint(1, (relAnchorPoint.x() + colAnchorPoint.x()) / 2, relAnchorPoint.y()) self.relPoints.setPoint(2, (relAnchorPoint.x() + colAnchorPoint.x()) / 2, colAnchorPoint.y()) self.relPoints.setPoint(3, self.collectionIcon.getAnchorPoint()) self.relPoints.setPoint(4, self.relPoints.point(3)[0] - self.lineWidth, self.relPoints.point(3)[1] - self.lineWidth) self.relPoints.setPoint(5, self.relPoints.point(2)[0] - self.lineWidth, self.relPoints.point(2)[1] - self.lineWidth) self.relPoints.setPoint(6, self.relPoints.point(1)[0] - self.lineWidth, self.relPoints.point(1)[1] - self.lineWidth) self.relPoints.setPoint(7, self.relPoints.point(0)[0] - self.lineWidth, self.relPoints.point(0)[1] - self.lineWidth) self.setPoints(self.relPoints) def destroyIcon(self): """ completely removes the partial relation from the canvas """ self.collectionIcon.removePartialRelation(self) self.setCanvas(None)
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/datamodel_iconview/partial_relation_icon.py", "copies": "1", "size": "5741", "license": "bsd-3-clause", "hash": -5267715409180089000, "line_mean": 36.0198675497, "line_max": 124, "alpha_frac": 0.6300296116, "autogenerated": false, "ratio": 4.000696864111498, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5130726475711498, "avg_score": null, "num_lines": null }
""" Module for the base item declaration. """ import logging from datafinder.core.configuration.properties.constants import UNMANAGED_SYSTEM_PROPERTY_CATEGORY, \ MANAGED_SYSTEM_PROPERTY_CATEGORY from datafinder.core.error import ItemError, PrivilegeError, PropertyError from datafinder.core.item.property import Property from datafinder.core.item.privileges.acl import AccessControlList from datafinder.core.item.privileges import privilege from datafinder.persistence.error import PersistenceError __version__ = "$Revision-Id:$" _logger = logging.getLogger() class ItemBase(object): """ Base class for all item implementations. """ def __init__(self, name=None, fileStorer=None): """ Constructor. @param name: Name of the item. @type name: C{unicode} @param fileStorer: File storer object representing the item. @type fileStorer: L{FileStorer<datafinder.persistence.factory.FileStorer>} @raise ItemError: If both C{name} and C{fileStorer} are not specified. """ if name is None and fileStorer is None: raise ItemError("Either name or a file storer has to be specified on initialization.") self.name = name self.path = None self._linkTarget = None self._fileStorer = fileStorer if not fileStorer is None: self.path = fileStorer.identifier self.name = fileStorer.name self._parent = None self._dataPersister = None self.itemFactory = None self._isRoot = False self._isCollection = False self._childrenPopulated = True self._children = list() self._isLeaf = False self._isLink = False self._created = False self._acl = None self._privileges = None self._properties = None self._ignoreChecks = False self._requiredPropertyDefinitions = None def refresh(self, itemStateOnly=False): """ Resets the state of the item so that its information is reloaded when accessed. @param itemStateOnly: If set it indicates that only the item state is refreshed but no structural information. Default is C{False} @type itemStateOnly: C{bool} """ if not itemStateOnly: self._parent = None self._dataPersister = None self._fileStorer = None self._acl = None self._properties = None self._privileges = None self._requiredPropertyDefinitions = None def create(self, properties): """ Interface for the creation of the concrete item. @param properties: Optional properties parameter for specifying meta data. @type properties: C{list} of L{Property<datafinder.core.item.properties.Property>} """ self._properties = dict() if self.itemFactory.hasCustomMetadataSupport: for prop in properties: if (self.isManaged or prop.propertyDefinition.category != MANAGED_SYSTEM_PROPERTY_CATEGORY): self._properties[prop.identifier] = prop missingProperties = self._completeProperties() if len(missingProperties) > 0: self._properties = None errorMessage = "The following required properties are missing.\n" \ "%s" % "\n".join(missingProperties) raise ItemError(errorMessage) if not self.parent.capabilities.canAddChildren: raise ItemError("No child item can be created below parent item '%s'" % self.parent.path) def _completeProperties(self, persistedProps=None): """ Checking whether the given properties are sufficient for item creation. """ missingProperties = list() reqPropDefs = self.requiredPropertyDefinitions.values() for reqPropDef in reqPropDefs: isAvailable = reqPropDef.identifier in self._properties if not isAvailable: prop = Property(reqPropDef, reqPropDef.defaultValue) self._properties[reqPropDef.identifier] = prop else: if not persistedProps is None: prop = Property.create( reqPropDef, persistedProps[reqPropDef.identifier]) self._properties[reqPropDef.identifier] = prop else: value = self._properties[reqPropDef.identifier].value prop = Property(reqPropDef, value) self._properties[reqPropDef.identifier] = prop if not isAvailable and reqPropDef.notNull: missingProperties.append(reqPropDef.displayName) return missingProperties def delete(self, ignoreStorageLocation=False): """ Deletes the item. """ if not ignoreStorageLocation: checker = self.itemFactory.createActionCheckTreeWalker() if not checker.canDelete(self): raise ItemError("The item '%s' cannot be deleted." % self.path) for affectedItem in checker.affectedItems: try: affectedItem.dataPersister.delete() except PersistenceError, error: raise ItemError("Unable to delete item '%s'.\nReason:'%s'" % (self.path, error.message)) self.dataPersister.delete() try: self.fileStorer.delete() except (AttributeError, PersistenceError), error: raise ItemError("Unable to delete item '%s'.\nReason:'%s'" % (self.path, error.message)) else: self.invalidate() def copy(self, item): """ Copy the this item to the given item. @param item: The target item that represents the copied item. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} """ checker = self.itemFactory.createActionCheckTreeWalker() if not checker.canCopy(self): raise ItemError("The item '%s' cannot be copied." % self.path) if not item.parent.capabilities.canAddChildren: raise ItemError("Cannot copy to target item.") try: self.fileStorer.copy(item.fileStorer) item._created = True self.dataPersister.copy(item) for affectedItem in checker.affectedItems: targetPath = item.path + affectedItem.path[len(self.path):] targetItem = self.itemFactory.create(targetPath) affectedItem.dataPersister.copy(targetItem) except (AttributeError, PersistenceError, ItemError), error: raise ItemError("Cannot copy item. Reason:'%s'" % error.message) else: item.refresh(True) def move(self, item): """ Moves this item to the given item location. @param item: The target item for this item. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} """ self._created = False checker = self.itemFactory.createActionCheckTreeWalker() if not checker.canMove(self): self._created = True raise ItemError("The item '%s' cannot be moved." % self.path) if not item.parent.capabilities.canAddChildren: self._created = True raise ItemError("Cannot move to target item.") try: self.fileStorer.move(item.fileStorer) item._created = True self.dataPersister.move(item) for affectedItem in checker.affectedItems: targetPath = item.path + affectedItem.path[len(self.path):] targetItem = self.itemFactory.create(targetPath) affectedItem.dataPersister.move(targetItem) except (AttributeError, PersistenceError, ItemError), error: self._created = True raise ItemError("Cannot move item. Reason:'%s'" % error.message) else: self.invalidate() item.refresh(True) def retrieveData(self): """ Receives the data associated with this item. @return: Readable file-like object. """ if not self.capabilities.canRetrieveData: raise ItemError("This item does not allow data retrieval.") else: try: return self.dataPersister.retrieveData() except PersistenceError, error: raise ItemError("Cannot read item data. Reason: '%s'" % error.message) def getTemporaryFileObject(self, deleteOnClose=True): """ Returns a named local temporary file object allowing access to the binary content. @param deleteOnClose: Automatically deletes the temporary file object when its closed. Default: C{True} @type deleteOnClose: C{bool} @return: Tuple consisting of local file path and opened temporary file object. @rtype: C{tuple} of C{unicode}, C{object} implementing file protocol """ if self.dataPersister.fileStorer is None or not self.capabilities.canRetrieveData: raise ItemError("This item does not allow data retrieval.") else: try: return self.dataPersister.fileStorer.getTemporaryFileObject(self.name, deleteOnClose) except PersistenceError, error: raise ItemError("Cannot retrieve temporary file object. Reason: '%s'" % error.message) def storeData(self, fileObj): """ Stores the data that has to be associated with this item. @param fileObj: File-like object that can be read from. """ if not self.capabilities.canStoreData: raise ItemError("This item does not allow data storage.") else: try: self.dataPersister.storeData(fileObj) except PersistenceError, error: raise ItemError("Cannot write item data. Reason: '%s'" % error.message) def getChildren(self): """ Returns the children for this item. @return: The children of this item. @rtype: C{list} """ return self._children def addChild(self, item): """ Adds a child item to this item. This method has to be implemented by subclasses. @param item: The item that has to be added to the item. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} """ pass def removeChild(self, item): """ Removes the given item from the child list. @param item: The child item that has to be removed. @type item: L{ItemBase<datafinder.core.item.base.ItemBase>} """ pass def hasChild(self, name, isCaseSensitive=False): """ Determines whether the item has a child with the given name. @param name: Name of the child. @type name: C{unicode} @param isCaseSensitive: Flag indicating whether the check is performed case sensitive. Default is C{False}. @type isCaseSensitive: C{bool} @return: Flag indicating existence. @rtype: C{bool} """ pass def invalidate(self): """ Invalidates the item. """ self.parent = None self.itemFactory.invalidate(self.path) self.path = None self._fileStorer = None @property def properties(self): """ Retrieves the properties and maps them to the correct representation. """ if self._properties is None: if self.isCreated: self._refreshProperties() else: return dict() return self._properties def _refreshProperties(self): """ Updates the item properties with current information of the persistence backend. """ self._properties = dict() if not privilege.READ_PRIVILEGE in self.privileges and not privilege.ALL_PRIVILEGE in self.privileges: _logger.warning("You are not allowed to retrieve properties!") else: try: persistedProps = self.fileStorer.retrieveMetadata() except PersistenceError, error: _logger.error(error.args) except AttributeError: self._properties = dict() else: self._properties = dict() for propId, value in persistedProps.iteritems(): propDef = self.itemFactory.getPropertyDefinition(propId) prop = Property.create(propDef, value) self._properties[propId] = prop self._completeProperties(persistedProps) def updateProperties(self, properties): """ Adds/Updates the given properties to the item. @param properties: Properties to add. @type properties: C{list} of L{Property<datafinder.core.item.property.Property>} """ if not self.capabilities.canStoreProperties: raise ItemError("You are not allowed to change properties!") propertiesToStore = dict() currentProperties = None if not self.properties is None: currentProperties = self.properties.copy() for prop in properties: if prop.propertyDefinition.category != UNMANAGED_SYSTEM_PROPERTY_CATEGORY: if self.isManaged or prop.propertyDefinition.category != MANAGED_SYSTEM_PROPERTY_CATEGORY: if prop.identifier in self.properties: self.properties[prop.identifier].value = prop.value else: propDef = self.itemFactory.getPropertyDefinition(prop.identifier) self.properties[prop.identifier] = Property(propDef, prop.value) try: propertiesToStore.update(**prop.toPersistenceFormat()) except PropertyError, error: _logger.error(error.args) try: self.fileStorer.updateMetadata(propertiesToStore) except (AttributeError, PersistenceError), error: _logger.error(error.args) self._properties = currentProperties def deleteProperties(self, propertyIdentifiers): """ Deletes the given properties from the item properties. @param propertyIdentifiers: List of property identifiers. @type propertyIdentifiers: C{list} of C{unicode} """ if not self.capabilities.canStoreProperties: raise ItemError("You are not allowed to delete properties!") try: self.fileStorer.deleteMetadata(propertyIdentifiers) except (AttributeError, PersistenceError), error: _logger.error(error.args) else: for propertyIdentifier in propertyIdentifiers: if propertyIdentifier in self.properties: del self.properties[propertyIdentifier] @property def acl(self): """ Retrieves the access control list. """ if self._acl is None: try: persistedAcl = self.fileStorer.retrieveAcl() except (AttributeError, PersistenceError), error: _logger.error(error.args) self._acl = AccessControlList() else: try: self._acl = AccessControlList.create(persistedAcl) except PrivilegeError, error: _logger.error(error.args) self._acl = AccessControlList() return self._acl def updateAcl(self, acl): """ Stores access control list. """ try: self.fileStorer.updateAcl(self._acl.toPersistenceFormat()) except (AttributeError, PersistenceError), error: _logger.error(error.args) else: self._acl = acl @property def fileStorer(self): """ Returns the file storer. """ if self._fileStorer is None and not self.path is None: self._fileStorer = self.itemFactory.createFileStorer(self.path) return self._fileStorer @property def dataType(self): """ Getter for the data type attribute. """ pass @property def dataFormat(self): """ Getter for the data format attribute. """ pass @property def dataPersister(self): """ Lazy instantiation of the data persister. """ if self._dataPersister is None: self._dataPersister = self.itemFactory.createDataPersister(self) return self._dataPersister @property def isRoot(self): """ Indicates whether it is the root item or not. """ return self._isRoot @property def isCollection(self): """ Indicates whether it is a collection or not. """ return self._isCollection @property def childrenPopulated(self): """ Indicates whether the children are already retrieved. """ return self._childrenPopulated @property def isLeaf(self): """ Indicates whether the item is a leaf or not. """ return self._isLeaf @property def isLink(self): """ Indicates whether the item is a link or not. """ return self._isLink @property def linkTarget(self): """ Returns the actual item this item points to. """ return self._linkTarget @property def linkTargetPath(self): """ Getter for the link target path. """ if not self.linkTarget is None: return self.linkTarget.path @property def state(self): """ Retrieve the data state associated with L{NullDataPersister<datafinder.core.item.data_persister.persisters.NullDataPersister>} of this item. @return: The data state. @rtype: C{unicode} @see L{datafinder.core.item.data_persister.constants} """ return self.dataPersister.state @property def privileges(self): """ Getter for the granted privileges on the specific item. """ if self._privileges is None: if self._created: self._privileges = list() if not self.fileStorer is None: try: privileges = self.fileStorer.retrievePrivileges() except PersistenceError: _logger.exception("Problems retrieving privileges.") return self._privileges for privilege_ in privileges: self._privileges.append(privilege.getPrivilege(privilege_)) else: return [privilege.ALL_PRIVILEGE] return self._privileges def _setParent(self, parent): """ Setter for the parent item. """ if not parent is None: if parent.isLeaf or parent.isLink: raise ItemError("Given parent is a leaf.") parent.addChild(self) oldPath = self.path if parent.path.endswith("/"): self.path = parent.path + self.name else: self.path = parent.path + "/" + self.name if oldPath != self.path: self._fileStorer = None self._dataPersister = None if not self._parent is None: if self._parent != parent: self._parent.removeChild(self) self._parent = parent def _getParent(self): """ Returns the parent of this item. """ if self._parent is None and not self.isRoot and not self.fileStorer is None: parentFileStorer = self.fileStorer.parent self._parent = self.itemFactory.create(parentFileStorer.identifier, fileStorer=parentFileStorer) return self._parent parent = property(_getParent, _setParent) @property def capabilities(self): """ Property holding the direct capabilities. """ return self.itemFactory.createItemCapabilityChecker(self) @property def dataUri(self): """ Returns the URI of the associated file object. """ if self.dataPersister.fileStorer is None: raise ItemError("This item does not allow data retrieval.") return self.dataPersister.fileStorer.uri @property def uri(self): """ Returns the URI of the item. """ return self.fileStorer.uri @property def isManaged(self): """ Flag indicating whether the item belongs to managed repository or not. """ return self.itemFactory.isManaged @property def isCreated(self): """ Flag indicating whether the item has been already created or not. """ return self._created @property def requiredPropertyDefinitions(self): """ Determines the required property definitions. """ if self._requiredPropertyDefinitions is None: reqPropDefs = self.itemFactory.getDefaultPropertyDefinitions(self) if not self.dataType is None: reqPropDefs += self.dataType.propertyDefinitions if not self.dataFormat is None: reqPropDefs += self.dataFormat.propertyDefinitions self._requiredPropertyDefinitions = dict() for propDef in reqPropDefs: self._requiredPropertyDefinitions[propDef.identifier] = propDef return self._requiredPropertyDefinitions @property def ignoreChecks(self): """ Returns whether sanity checks are ignored or not. """ return self._ignoreChecks
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/core/item/base.py", "copies": "1", "size": "24733", "license": "bsd-3-clause", "hash": 3746554523812909600, "line_mean": 36.0507692308, "line_max": 115, "alpha_frac": 0.5824202483, "autogenerated": false, "ratio": 4.838223787167449, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.01824528187694625, "num_lines": 650 }
""" Module provides functionality for common gui related tasks. """ import sys from thread import get_ident from threading import Lock, Condition from qt import QMimeSourceFactory, QCustomEvent, QObject, qApp, QEvent, \ QPixmap, QApplication, QLabel, \ QPoint, Qt, QFrame from datafinder.core.configuration import constants try: from datafinder.gui.gen import static_images # Everything is done on import time _haveImagesAsModule = not static_images is None # Alawys is "True", used to silent pylint except ImportError: _haveImagesAsModule = False __version__ = "$Revision-Id:$" _defaultLargeIconName = "dataType24.png" _defaultSmallIconName = "dataType16.png" def getPixmapForImageName(name, smallIcon=True): """ Returns the pixmap for the given name. If the pixmap can not be found a default icons will be returned. @param name: Name of the image. @type name: C{unicode} @param smallIcon: Flag indicating whether a small icon (16 pixels) or a large icon (24 pixels) is required. @type smallIcon: C{bool} @return: The Qt pixmap. @rtype: L{QPixmap<qt.QPixmap>} """ result = None if not name is None: if smallIcon: name += "16.png" else: name += "24.png" result = QPixmap.fromMimeSource(name) if result is None or result.isNull(): if smallIcon: result = QPixmap.fromMimeSource(_defaultSmallIconName) else: result = QPixmap.fromMimeSource(_defaultLargeIconName) return result def addQtImagePath(localPath): """ Adds path where Qt can look for images. @param localPath: Path on the local file system. @type localPath: C{unicode} """ QMimeSourceFactory.defaultFactory().addFilePath(localPath) def showSplash(splashImageName): """ Function which shows a nice splash screen. @param splashImageName: Name of the splash screen image. @type splashImageName: C{unicode} """ screen = QApplication.desktop().screenGeometry() if not _haveImagesAsModule: addQtImagePath(constants.LOCAL_INSTALLED_ICONS_DIRECTORY_PATH) dfPicture = QPixmap.fromMimeSource(splashImageName) dfSplash = QLabel(None, "splash", Qt.WDestructiveClose | Qt.WStyle_Customize | Qt.WStyle_NoBorder |\ Qt.WX11BypassWM | Qt.WStyle_StaysOnTop) dfSplash.setFrameStyle(QFrame.WinPanel | QFrame.Raised) dfSplash.setPixmap(dfPicture) dfSplash.setCaption("DataFinder") dfSplash.setAutoResize(1) dfSplash.move(QPoint(screen.center().x() - dfSplash.width() / 2, screen.center().y() - dfSplash.height() / 2)) dfSplash.show() dfSplash.repaint(0) QApplication.flush() return dfSplash class CallbackEventHandler(QObject): """ Allows the posting of Qt events from python threads. @note: initialise an instance of this class only from the Qt main thread. """ def __init__(self): """ Constructor. """ QObject.__init__(self) self.__mainThreadIdentifier = get_ident() def customEvent(self, event): """ @see L{customEvent<QObject.customEvent>}""" if isinstance(event, _MyCustomEvent): self._performCall(event.functionToCall, event.callback, event.arguments) def callFunctionInQtThread(self, functionToCall, blocking, *arguments): """ Calls the given function in the Qt thread. If this is used from the Qt main thread the given function is directly called. If C{blocking} is C{True} and the method is not called from the Qt main thread it will be ensured that the python thread is blocked until the function is executed. @param functionToCall: Pointer to the function that has to be executed. @param arguments: Arguments required for the function. @param blocking: Blocks the calling thread. @type blocking: C{boolean} """ if get_ident() == self.__mainThreadIdentifier: # call directly self._performCall(functionToCall, None, arguments) else: # post event in the main Qt thread event = _MyCustomEvent(functionToCall, arguments) if blocking: conditionVar = Condition(Lock()) conditionVar.acquire() def _callback(): conditionVar.acquire() conditionVar.notify() conditionVar.release() event.callback = _callback qApp.postEvent(self, event) conditionVar.wait() conditionVar.release() else: qApp.postEvent(self, event) @staticmethod def _performCall(functionToCall, callback, arguments): """ Performs the function call. W0142: Using */** magic is the only ways to perform these generic calls. """ # pylint: disable=W0142 if not functionToCall is None and not arguments is None: functionToCall(*arguments) if not callback is None: callback() class _MyCustomEvent(QCustomEvent): """ A custom event class. """ __eventIdentifier = QEvent.User # + 1000 def __init__(self, functionToCall, arguments): """ Constructor. """ QCustomEvent.__init__(self, 1000) self.functionToCall = functionToCall self.callback = None self.arguments = arguments def binaryStringToUnicodeStringDecoding(binaryString): """ Decodes the given binary string into an unicode string. The primarily use is for decoding file system paths. In order to perform the decoding the default file system encoding is used. If it fails on non-Windows operating systems, it will be tried to use the Windows encoding "cp437". This encoding is used when a a file name is written via a Samba share from a Windows client. If the given string is already an unicode string this string is returned and no conversion is tried. @param binaryString: String to decode. @type binaryString: C{string} @retrun: Unicode representation of the binary string. @rtype: C{unicode} """ fileSystemEncoding = sys.getfilesystemencoding() if fileSystemEncoding is None: fileSystemEncoding = "utf-8" if not isinstance(binaryString, unicode): try: unicodeString = binaryString.decode(fileSystemEncoding) except UnicodeDecodeError: if sys.platform != "win32": unicodeString = binaryString.decode("cp437") else: unicodeString = binaryString return unicodeString
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/common/utils.py", "copies": "1", "size": "8629", "license": "bsd-3-clause", "hash": 3372331077392304000, "line_mean": 34.256302521, "line_max": 111, "alpha_frac": 0.6554641326, "autogenerated": false, "ratio": 4.246555118110236, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.008592322243594066, "num_lines": 238 }
""" This module controls the tool bar view. """ from PyQt4 import QtCore, QtGui from datafinder.gui.user.common import util from datafinder.gui.user.common.delegate import AbstractDelegate from datafinder.gui.user.common.controller import AbstractController __version__ = "$Revision-Id:$" class ToolbarController(AbstractController): """ Controls the tool bar view including navigation in item history. """ def __init__(self, forwardAction, backwardAction, parentDirectoryAction, refreshAction, toolbarAction, widget, mainWindow, parentController): """ Constructor. """ AbstractController.__init__(self, widget, mainWindow, parentController=parentController) self._toolbarAction = toolbarAction self.forwardAction = forwardAction self.forwardMenu = QtGui.QMenu(widget) self.forwardAction.setData(QtCore.QVariant(1)) self.forwardAction.setMenu(self.forwardMenu) self.backwardAction = backwardAction self.backwardMenu = QtGui.QMenu(widget) self.backwardAction.setData(QtCore.QVariant(-1)) self.backwardAction.setMenu(self.backwardMenu) self.parentDirectoryAction = parentDirectoryAction self.refreshAction = refreshAction self._delegate = _ToolbarDelegate(self) self.setActivated(False) def setActivated(self, activated): """ Activates or deactivates of the tool bar. """ self.widget.setEnabled(activated) if activated: self.forwardAction.setEnabled(not activated) self.backwardAction.setEnabled(not activated) self.parentDirectoryAction.setEnabled(not activated) self.refreshAction.setEnabled(activated) else: self.forwardAction.setEnabled(activated) self.backwardAction.setEnabled(activated) self.parentDirectoryAction.setEnabled(activated) self.refreshAction.setEnabled(activated) def createHistoryMenu(self, pathlist, menu, iterator): """ Create a menu from the given list with L{QtCore.QModelIndex} objects. @param pathlist: List of history paths objects. @type pathlist: C{list} @param menu: Menu to which the given path list will added to. @type menu: C{QtGui.QMenu} @param iterator: The iterator that specifies if the menu will move relative forward or backward. @type iterator: C{int} """ menu.clear() for steps, path in enumerate(pathlist): action = QtGui.QAction(path, menu) action.setData(QtCore.QVariant((steps + 1) * iterator)) QtCore.QObject.connect(action, QtCore.SIGNAL("triggered()"), self._createJumpToPathActionSlot(action)) menu.addAction(action) if len(pathlist): menu.setDefaultAction(menu.actions()[0]) def _createJumpToPathActionSlot(self, action): """ Creates a slot which directly jumps to the associated path in the history. """ def _jumpToPathActionSlot(): steps, success = action.data().toInt() if success: self.model.relativeHistoryIndex = steps return _jumpToPathActionSlot class _ToolbarDelegate(AbstractDelegate): """ This delegate is responsible for user interactions with the L{ToolbarView}. """ def __init__(self, controller): """ Constructor. """ AbstractDelegate.__init__(self, controller) self._thread = None self._searchDialog = None @util.immediateConnectionDecorator("model", "updateSignal") def _modelUpdatedSlot(self, index): """ Slot is called if the model has changed. """ backwardList, forwardList = self._controller.model.history self._controller.createHistoryMenu(forwardList, self._controller.forwardMenu, 1) self._controller.createHistoryMenu(backwardList, self._controller.backwardMenu, -1) self._controller.forwardAction.setEnabled(len(forwardList) > 0) self._controller.backwardAction.setEnabled(len(backwardList) > 1) self._controller.parentDirectoryAction.setEnabled(index.isValid()) @util.immediateConnectionDecorator("backwardAction", "triggered()") def _historyBackwardClickedSlot(self): """ Slot is called if an action was triggered in one of the history menus. @param action: The action that was pressed in the history menu. @type action: C{QtGui.QMenu} """ steps, success = self._controller.backwardAction.data().toInt() if success: self._controller.model.relativeHistoryIndex = steps @util.immediateConnectionDecorator("forwardAction", "triggered()") def _historyForwardClickedSlot(self): """ Slot is called if an action was triggered in one of the history menus. @param action: The action that was pressed in the history menu. @type action: C{QtGui.QMenu} """ steps, success = self._controller.forwardAction.data().toInt() if success: self._controller.model.relativeHistoryIndex = steps @util.immediateConnectionDecorator("_toolbarAction", "triggered(bool)") def _showToolbar(self, showIt): """ Shows / hides the tool bar. """ self._controller.setVisible(showIt) @util.immediateConnectionDecorator("parentDirectoryAction", "triggered()") def _parentDirectoryActionTriggeredSlot(self): """ Change the path to the parent directory of the path. """ self._controller.model.activeIndex = self._controller.model.activeIndex.parent() @util.immediateConnectionDecorator("refreshAction", "triggered()") def _refreshActionTriggeredSlot(self): """ Refresh the View with the current model data. """ self._controller.model.refresh(self._controller.model.activeIndex)
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/user/controller/repository/toolbar.py", "copies": "1", "size": "7921", "license": "bsd-3-clause", "hash": -8841161470594874, "line_mean": 36.6390243902, "line_max": 114, "alpha_frac": 0.6653200353, "autogenerated": false, "ratio": 4.539255014326647, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5704575049626648, "avg_score": null, "num_lines": null }
"""" Module provides a logging handler for the DataFinder GUIs. """ import logging import Queue from datafinder.gui.admin.common import utils __version__ = "$Revision-Id:$" _guiLogFormat = "%(asctime)s: %(levelname)s: %(message)s" _guiDateFormat = "%H:%M:%S" _levelHtmlDirective = {logging.INFO: "<font color='black'>%s</font>", logging.WARNING: "<font color='orange'>%s</font>", logging.ERROR: "<font color='red'>%s</font>"} class GuiLoggerHandler(logging.Handler): """ Handler class used to display logging messages in a widget. The logging widget used for output has only to implement the method C{append} that takes a C{unicode} as input, the method C{scrollToBottom} and the method C{clear}. """ def __init__(self, logWidget, level=logging.INFO): """ Constuctor. @param logWidget: A qt widget with an C{append} interface. @type logWidget: L{QWidget<qt.QWidget>} @param level: Level constant. @see: L{logging<logging>} module. """ logging.Handler.__init__(self, level) formatter = logging.Formatter(_guiLogFormat, _guiDateFormat) self.setFormatter(formatter) self.__callbackHandler = utils.CallbackEventHandler() self.__logWidget = logWidget self.__logMessageQueue = Queue.Queue() def emit(self, record): """ @see: L{emit<logging.Handler.emit>} """ message = self.format(record) if self.level <= record.levelno: if record.levelno in _levelHtmlDirective: message = _levelHtmlDirective[record.levelno] % message self.__callbackHandler.callFunctionInQtThread(self.__logWidget.append, False, message) self.__callbackHandler.callFunctionInQtThread(self.__logWidget.scrollToBottom, False) def installGuiLoggingHandler(logger, logWidget, level=logging.INFO): """ Adds and configures a GuiLoggerHandler to the given logger. """ logWidget.clear() guiLoggerHandler = GuiLoggerHandler(logWidget, level) logger.addHandler(guiLoggerHandler)
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/common/logger_handler.py", "copies": "1", "size": "3878", "license": "bsd-3-clause", "hash": -3201271447668878000, "line_mean": 34.9333333333, "line_max": 98, "alpha_frac": 0.6835997937, "autogenerated": false, "ratio": 4.064989517819707, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5248589311519707, "avg_score": null, "num_lines": null }
""" Importing directory structure. """ from logging import getLogger from datafinder.core.configuration.properties.constants import DATATYPE_ID, DATASTORE_NAME_ID from datafinder.gui.user import script_api as gui_api from datafinder.script_api.error import ItemSupportError from datafinder.script_api.item import item_support from datafinder.script_api.repository import setWorkingRepository __version__ = "$LastChangedRevision: 59 $" _DATASTORE_DEFAULT_VALUE = "DataStore" # Data store in which files are imported _DATATYPE_DEFAULT_VALUE = "Directory" # Data type name of newly imported directories logger = getLogger() targetRepository = gui_api.managedRepositoryDescription() targetPath = gui_api.getScriptExecutionContext().itemPaths[0] sourceRepository = gui_api.unmanagedRepositoryDescription() setWorkingRepository(sourceRepository) sourcePath = gui_api.currentCollection() def _determinePropertiesCallback(itemDescription): """ Determines the properties for the given item. This callback is called for every imported item. Thus, you can implement a more specific property assignment. """ logger.info(itemDescription) properties = dict() if itemDescription.isLeaf: properties[DATASTORE_NAME_ID] = _DATASTORE_DEFAULT_VALUE else: if not DATATYPE_ID in properties: properties[DATATYPE_ID] = _DATATYPE_DEFAULT_VALUE return properties def _worker(): """ Performs the import. """ try: item_support.performImport(sourcePath, targetPath, targetRepository, dict(), True, True, _determinePropertiesCallback) except ItemSupportError, error: logger.error(error.message) def _workerCallback(): """ Unlocks target path when work is done. """ gui_api.unlock([targetPath], targetRepository) sourcePath = gui_api.getExistingCollection(sourceRepository, helpText="Please select the collection you want to import.") if not sourcePath is None: gui_api.lock([targetPath], targetRepository) gui_api.performWithProgressDialog(_worker, _workerCallback, "Import Directory", "Performing the directory import...")
{ "repo_name": "DLR-SC/DataFinder", "path": "contrib/script_examples/gui/directory_importer.py", "copies": "1", "size": "4036", "license": "bsd-3-clause", "hash": 520923501356189400, "line_mean": 35.7196261682, "line_max": 121, "alpha_frac": 0.7304261645, "autogenerated": false, "ratio": 4.143737166324435, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 0.5374163330824435, "avg_score": null, "num_lines": null }
""" Controller component of the create configuration dialog. """ import sys import threading from qt import QApplication, qApp from datafinder.common import logger from datafinder.core.error import ConfigurationError from datafinder.gui.admin.create_configuration_dialog.view import CreateConfigurationView from datafinder.gui.admin.create_configuration_dialog.model import CreateConfigurationModel __version__ = "$Revision-Id:$" class CreateConfigurationController(object): """ Controller component of the create configuration dialog. """ _logger = logger.getDefaultLogger() def __init__(self, repositoryManager): """ Constructor. """ self.__errorMessage = None self.__view = CreateConfigurationView(self) self.__model = CreateConfigurationModel(repositoryManager) self.__view.show() def createConfiguration(self, hostUri, username, password, configurationPath, dataPath): """ Delegates the call to the model. """ self.__errorMessage = None self.__view.createPushButton.setEnabled(False) thread = threading.Thread(target=self.__prepare, args=(hostUri, configurationPath, dataPath, username, password)) thread.start() while thread.isAlive(): qApp.processEvents() self.__view.createPushButton.setEnabled(True) if not self.__errorMessage is None: self._logger.error(self.__errorMessage) self.__view.showErrorMessage(self.__errorMessage) else: createConfiguration = True if self.__model.exists: createConfiguration = self.__view.showQuestion("The configuration path does already exist. Overwrite it?") self.__view.createPushButton.setEnabled(False) thread = threading.Thread(target=self.__performConfigurationCreation, args=(createConfiguration, )) thread.start() while thread.isAlive(): qApp.processEvents() if not self.__errorMessage is None: self._logger.error(self.__errorMessage) self.__view.showErrorMessage(self.__errorMessage) self.__view.createPushButton.setEnabled(True) def __prepare(self, hostUri, configurationPath, dataPath, username, password): """ Performs basic checks in thread. """ try: self.__model.prepareConfiguration(hostUri, configurationPath, dataPath, username, password) except ConfigurationError, error: self.__errorMessage = error.message def __performConfigurationCreation(self, overwrite): """ Performs the configuration creation and handles errors. """ try: self.__model.createConfiguration(overwrite) except ConfigurationError, error: self.__errorMessage = error.message def __getView(self): """ Returns the generated view class. """ return self.__view.view view = property(__getView) # simple self-test if __name__ == "__main__": application = QApplication(sys.argv) controller = CreateConfigurationController() application.setMainWidget(controller.view) application.exec_loop()
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/create_configuration_dialog/controller.py", "copies": "1", "size": "5061", "license": "bsd-3-clause", "hash": 4547268084933125600, "line_mean": 37.8503937008, "line_max": 122, "alpha_frac": 0.6757557795, "autogenerated": false, "ratio": 4.626142595978062, "config_test": true, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.017351318041377798, "num_lines": 127 }
""" Controller component of the data store configuration wizard. """ from qt import SIGNAL, QFileDialog from datafinder.common.logger import getDefaultLogger from datafinder.core.configuration import datastores from datafinder.core.error import ConfigurationError from datafinder.gui.admin.datastore_configuration_wizard.constants import authenticationOptionsPage, \ performanceOptionsPage, \ securityOptionsPage, \ standardOptionsPage, \ storageOptionsPage, \ wizardCaptionTemplate from datafinder.gui.admin.datastore_configuration_wizard import default from datafinder.gui.admin.datastore_configuration_wizard import ftp from datafinder.gui.admin.datastore_configuration_wizard import gridftp from datafinder.gui.admin.datastore_configuration_wizard import offline from datafinder.gui.admin.datastore_configuration_wizard import tsm from datafinder.gui.admin.datastore_configuration_wizard import view from datafinder.gui.admin.datastore_configuration_wizard import webdav from datafinder.gui.admin.datastore_configuration_wizard import s3 __version__ = "$Revision-Id:$" # default for all datastores _defaultForAllDataStores = "Default" # dictionary that contains the wizard page sequence for every datastore type _pageSequenceDictionary = { datastores.GRIDFTP_STORE: [standardOptionsPage, storageOptionsPage, securityOptionsPage, performanceOptionsPage], datastores.WEBDAV_STORE: [standardOptionsPage, storageOptionsPage, authenticationOptionsPage], datastores.FILE_STORE: [standardOptionsPage, storageOptionsPage, authenticationOptionsPage], datastores.FTP_STORE: [standardOptionsPage, storageOptionsPage, authenticationOptionsPage], datastores.OFFLINE_STORE: [standardOptionsPage, storageOptionsPage], datastores.DEFAULT_STORE: [standardOptionsPage], datastores.TSM_CONNECTOR_STORE: [standardOptionsPage, storageOptionsPage, authenticationOptionsPage], datastores.S3_STORE: [standardOptionsPage, authenticationOptionsPage], datastores.SUBVERSION_STORE: [standardOptionsPage, storageOptionsPage, authenticationOptionsPage], } class DataStoreConfigurationWizardController(object): """ Controls the DataStoreWizardView. Delegates the control of the specific from to the according subclass of AbstractoptionComntroller. """ _logger = getDefaultLogger() def __init__(self, parentFrame, dataStoreHandler, iconHandler, datastore=None): """ Constructor. """ self.parent = parentFrame self._dataStoreHandler = dataStoreHandler # create main view self.wizardView = view.DataStoreConfigurationWizardView(parentFrame) # init model if not datastore is None: self.datastore = datastore else: self.datastore = self._dataStoreHandler.createDataStore() # add control logic of the displayed forms self.lastPageTitle = standardOptionsPage self.currentFormHandler = default.base_option_controller.BaseOptionController(self.wizardView, self, standardOptionsPage, dataStoreHandler, iconHandler) self.formControllerDict = { standardOptionsPage: { _defaultForAllDataStores: self.currentFormHandler }, storageOptionsPage: { datastores.OFFLINE_STORE: offline.storage_option_controller.StorageOptionController(self.wizardView, self, storageOptionsPage), datastores.TSM_CONNECTOR_STORE: tsm.storage_option_controller.StorageOptionController(self.wizardView, self, storageOptionsPage), _defaultForAllDataStores: default.storage_option_controller.StorageOptionController(self.wizardView, self, storageOptionsPage) }, securityOptionsPage: { datastores.GRIDFTP_STORE: gridftp.security_option_controller.SecurityOptionController(self.wizardView, self, securityOptionsPage), }, authenticationOptionsPage: { datastores.FTP_STORE: ftp.authentication_option_controller.AuthenticationOptionController(self.wizardView, self, authenticationOptionsPage), datastores.WEBDAV_STORE: webdav.authentication_option_controller.AuthenticationOptionController(self.wizardView, self, authenticationOptionsPage), datastores.TSM_CONNECTOR_STORE: tsm.authentication_option_controller.AuthenticationOptionController(self.wizardView, self, authenticationOptionsPage), datastores.S3_STORE: s3.authentication_option_controller.AuthenticationOptionController(self.wizardView, self, authenticationOptionsPage), datastores.SUBVERSION_STORE: webdav.authentication_option_controller.AuthenticationOptionController(self.wizardView, self, authenticationOptionsPage), _defaultForAllDataStores: default.authentication_option_controller.AuthenticationOptionController(self.wizardView, self, authenticationOptionsPage) }, performanceOptionsPage: { datastores.GRIDFTP_STORE: gridftp.performance_option_controller.PerformanceOptionController(self.wizardView, self, performanceOptionsPage) } } # show wizard self.wizardView.setCaption(wizardCaptionTemplate % (self.datastore.storeType, self.datastore.name)) self.wizardView.show() self.wizardView.adjustSize() self.currentFormHandler.showModelPart() self.setPageSequence() # connect slots self.wizardView.connect(self.wizardView, SIGNAL("selected(const QString&)"), self._wizardPageChangedSlot) self.wizardView.connect(self.wizardView.finishButton(), SIGNAL("clicked()"), self._finishedSlot) def _finishedSlot(self): """ Method to overwrite standard behavior of the QWizard class if the button "finished" is used. This method validates the user input, saves the DataStore object and continues closes the wizard. """ self._dataStoreHandler.addDataStore(self.datastore) try: self._dataStoreHandler.store() except ConfigurationError, error: self._logger.error(error.message) else: self.parent.updateDataStores() def _wizardPageChangedSlot(self, currentTitleQString): """ Slot that saves the current form values and initializes the next form. """ actualPageTitle = unicode(currentTitleQString) if not actualPageTitle == self.lastPageTitle: self.lastPageTitle = actualPageTitle self.wizardView.transitionEnabled(True) pageType = unicode(currentTitleQString) try: self.currentFormHandler = self.formControllerDict[pageType][self.datastore.storeType] except KeyError: self.currentFormHandler = self.formControllerDict[pageType][_defaultForAllDataStores] self.currentFormHandler.showModelPart() def setPageSequence(self): """ Adapts the current wizard page sequence. """ pageSequenceList = _pageSequenceDictionary[self.datastore.storeType] self.wizardView.setPageSequence(pageSequenceList) self.wizardView.transitionEnabled(True) def getFileHandleFromDialog(self): """ Returns a file handle to the selected file. """ fileName = unicode(QFileDialog.getSaveFileName("", "All Files (*)", self.wizardView, "Save file dialog", "Choose a file name")) fileHandle = None if fileName: try: fileHandle = open (fileName, "rb") except IOError: fileHandle = None return fileHandle
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/datastore_configuration_wizard/controller.py", "copies": "1", "size": "10493", "license": "bsd-3-clause", "hash": -1302358348066373000, "line_mean": 46.3548387097, "line_max": 134, "alpha_frac": 0.6538644811, "autogenerated": false, "ratio": 4.851132686084142, "config_test": true, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.014142333872452003, "num_lines": 217 }
""" Defines an abstract controller component for the different option pages of the wizard. """ __version__ = "$Revision-Id:$" class AbstractOptionController(object): """ Abstract class that defines the interface of the form controller classes. """ def __init__(self, wizardView, wizardController, pageType): """ Constructor. @param wizardView: The wizard class. @type wizardView: instance of L{view.DataStoreConfigurationWizardView} @param wizardController: The main controller class. @type wizardController: instance of L{view.DataStoreConfigurationWizardController} @param pageType: category of the displayed options (e.g. storage, authentication, ...) @type pageType: C{string} """ self.wizardView = wizardView self.wizardController = wizardController self.errorDictionary = {} self.pageType = pageType self.wizardView.showCurrentErrorLabels(False, pageType) def showModelPart(self): """ Initializes the according form elements from the DataStore model. """ pass def setDatastoreProperty(self, myProperty, value, source=None): """ Validate and set the given property of the DataStore. """ try: setattr(self.wizardController.datastore, myProperty, value) if self.errorDictionary.has_key(myProperty): del self.errorDictionary[myProperty] self.wizardView.showErrorSource(source, False) except ValueError, valueError: self.errorDictionary[myProperty] = unicode(valueError) self.wizardView.showErrorSource(source, True) self.checkErrorMessageDisplaying() def checkErrorMessageDisplaying(self): """ Checks if it is necessary to display an error message. """ errorCount = len(self.errorDictionary) if errorCount == 0: self.wizardView.transitionEnabled(True) self.wizardView.showCurrentErrorLabels(False, self.pageType) else: self.wizardView.transitionEnabled(False) errorValues = self.errorDictionary.values() self.wizardView.showCurrentErrorLabels(True, self.pageType, errorValues[errorCount - 1])
{ "repo_name": "DLR-SC/DataFinder", "path": "src/datafinder/gui/admin/datastore_configuration_wizard/abstract_option_controller.py", "copies": "1", "size": "4251", "license": "bsd-3-clause", "hash": 7833481973472544000, "line_mean": 40.9393939394, "line_max": 94, "alpha_frac": 0.6593742649, "autogenerated": false, "ratio": 4.620652173913044, "config_test": false, "has_no_keywords": false, "few_assignments": false, "quality_score": 1, "avg_score": 0.019249859831682987, "num_lines": 99 }