From 3d9f6f564008b930afff9ba6b32d08bc267ebb3b Mon Sep 17 00:00:00 2001 From: Timotej Lazar Date: Mon, 11 May 2015 10:58:22 +0200 Subject: Disable parser generation The parser is currently unused. --- prolog/util.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/prolog/util.py b/prolog/util.py index 3130ea5..7e8adb2 100644 --- a/prolog/util.py +++ b/prolog/util.py @@ -38,7 +38,6 @@ class Token(namedtuple('Token', ['type', 'val', 'pos', 'rule', 'part', 'stop'])) self.stop if stop is None else stop) from .lexer import lexer, operators -from .parser import parser # Return a list of tokens in [text]. def tokenize(text): @@ -143,11 +142,6 @@ def compose(tokens): prev = t return code.strip() -# Parse [text] into an AST. -def parse(text): - tree = parser.parse(text) - return tree - # Rename variables in [tokens] to A0, A1, A2,… in order of appearance. def rename_vars(tokens, names=None): if names is None: -- cgit v1.2.1