Fix issues with multi line for loops in the fast parser.

This commit is contained in:
Dave Halter
2015-02-17 14:57:00 +01:00
parent 4d9608ea6f
commit 7663703989
2 changed files with 34 additions and 16 deletions

View File

@@ -21,7 +21,7 @@ def test_add_to_end():
class Two(Abc):
def h(self):
self
""") # ^ here is the first completion
""") # ^ here is the first completion
b = " def g(self):\n" \
" self."
@@ -290,6 +290,17 @@ def test_for_on_one_line():
check_fp(src, 2)
def test_multi_line_for():
src = dedent("""\
for x in [1,
2]:
pass
pass
""")
check_fp(src, 1)
def test_wrong_indentation():
src = dedent("""\
def func():