Fix bug in error detection code, where a zero-length string was causing a traceback
Fixes #5064
This commit is contained in:
parent
30948ae0dc
commit
1f80aa768a
1 changed files with 1 additions and 1 deletions
|
@ -403,7 +403,7 @@ Or:
|
||||||
match = True
|
match = True
|
||||||
elif middle.startswith('"') and not middle.endswith('"'):
|
elif middle.startswith('"') and not middle.endswith('"'):
|
||||||
match = True
|
match = True
|
||||||
if middle[0] in [ '"', "'" ] and middle[-1] in [ '"', "'" ] and probline.count("'") > 2 or probline.count("'") > 2:
|
if len(middle) > 0 and middle[0] in [ '"', "'" ] and middle[-1] in [ '"', "'" ] and probline.count("'") > 2 or probline.count("'") > 2:
|
||||||
unbalanced = True
|
unbalanced = True
|
||||||
if match:
|
if match:
|
||||||
msg = msg + """
|
msg = msg + """
|
||||||
|
|
Loading…
Reference in a new issue