Lines Matching refs:lexer
200 m = re.match(r'\s*((lexer|parser|tree)\s+|)grammar\s+(\S+);', grammar, re.MULTILINE)
207 assert self.grammarType in ('lexer', 'parser', 'tree', 'combined'), self.grammarType
285 """Optionally build a subclass of generated lexer class"""
312 """Build lexer instance. Arguments are passed to lexer.__init__()."""
314 if self.grammarType == 'lexer':
318 self.lexerModule = self.__load_module(self.grammarName + 'Lexer')
319 cls = getattr(self.lexerModule, self.grammarName + 'Lexer')
323 lexer = cls(*args, **kwargs)
325 return lexer
366 m = re.match(r'\s*((lexer|parser|tree)\s+|)grammar\s+(\S+);', grammar, re.MULTILINE)
373 assert grammarType in ('lexer', 'parser', 'tree', 'combined'), grammarType
410 lexerMod = self.__load_module(grammarName + 'Lexer')
415 lexerCls = getattr(lexerMod, grammarName + 'Lexer')
422 if grammarType == 'lexer':