mirror of
https://github.com/Sei-Lisa/LSL-PyOptimizer
synced 2024-11-21 14:18:57 -07:00
Minor pickiness
Even if the last char is a backslash, if we're inside a double quoted string, report unterminated string on EOF.
This commit is contained in:
parent
054539adf9
commit
40cd88e9f7
1 changed files with 3 additions and 3 deletions
|
@ -99,7 +99,7 @@ def parseArgs(s):
|
|||
State = Space
|
||||
args.append(arg)
|
||||
arg = ''
|
||||
# else remain in state Space
|
||||
# else remain in the 'Space' state
|
||||
elif c == '\n':
|
||||
break
|
||||
else:
|
||||
|
@ -129,9 +129,9 @@ def parseArgs(s):
|
|||
else:
|
||||
arg += c
|
||||
|
||||
if State in (SQuote, DQuote):
|
||||
if State in (SQuote, DQuote, DQBackslash):
|
||||
raise EArgError(u"Unterminated string in .run file")
|
||||
if State in (SBackslash, NBackslash, DQBackslash):
|
||||
if State in (SBackslash, NBackslash):
|
||||
raise EArgError(u"Backslash before EOF in .run file")
|
||||
|
||||
if State == Normal:
|
||||
|
|
Loading…
Reference in a new issue