mirror of
https://github.com/davidhalter/parso.git
synced 2026-10-25 22:17:21 +08:00
Fix working with async functions in the diff parser, fixes #56
This commit is contained in:
1 parent
0d37ff865c
commit
6c65aea47d
2 files changed
+19
No files matched your search
@@ -682,6 +682,8 @@ class _NodesTree(object):
|
||||
last = new_nodes[-1]
|
||||
if last.type == 'decorated':
|
||||
last = last.children[-1]
|
||||
if last.type in ('async_funcdef', 'async_stmt'):
|
||||
last = last.children[-1]
|
||||
last_line_offset_leaf = last.children[-2].get_last_leaf()
|
||||
assert last_line_offset_leaf == ':'
|
||||
else:
|
||||
|
||||
Reference in new issue
Block a user