Fix #enddef detection in wmlindent.
This commit is contained in:
parent
5c2aa1cd25
commit
10bc9e8733
1 changed files with 2 additions and 1 deletions
|
@ -159,7 +159,8 @@ def reindent(name, infp, outfp):
|
|||
saved_indent = indent
|
||||
indent = wmltools.baseindent
|
||||
inmacro = True
|
||||
elif transformed.endswith("#enddef"):
|
||||
# Be sure to ignore the newlines
|
||||
elif transformed.rstrip().endswith("#enddef"):
|
||||
indent = saved_indent
|
||||
inmacro = False
|
||||
elif not inmacro and transformed[0] in ('[', ']'):
|
||||
|
|
Loading…
Add table
Reference in a new issue