From 7b8455174a541f7ff402cf5c98872137ade1eda6 Mon Sep 17 00:00:00 2001 From: Dave Halter Date: Fri, 26 May 2017 14:06:40 -0400 Subject: [PATCH] Remove more unused code. --- parso/python/diff.py | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/parso/python/diff.py b/parso/python/diff.py index b2e83fc..1bbfe34 100644 --- a/parso/python/diff.py +++ b/parso/python/diff.py @@ -255,8 +255,7 @@ class DiffParser(object): last_until_line = 0 while until_line > self._nodes_stack.parsed_until_line: node = self._try_parse_part(until_line) - nodes = self._get_children_nodes(node) - #self._insert_nodes(nodes) + nodes = node.children self._nodes_stack.add_parsed_nodes(nodes) logging.debug( @@ -271,16 +270,6 @@ class DiffParser(object): assert last_until_line != self._nodes_stack.parsed_until_line, last_until_line last_until_line = self._nodes_stack.parsed_until_line - def _get_children_nodes(self, node): - nodes = node.children - first_element = nodes[0] - # TODO this looks very strange... - if first_element.type == 'error_leaf' and \ - first_element.original_type == 'indent': - assert False, str(nodes) - - return nodes - def _try_parse_part(self, until_line): """ Sets up a normal parser that uses a spezialized tokenizer to only parse