better check for avoiding double-wrapping

This commit is contained in:
adam j hartz 2016-03-02 16:45:43 -05:00
parent 9f9cd1894e
commit 340b70999c

View file

@ -185,15 +185,15 @@ class Execer(object):
if prev_indent == curr_indent:
raise original_error
maxcol = self._find_next_break(line, last_error_col)
if line.startswith('$['):
# if we have already wrapped this in subproc tokens
# and it still doesn't work, adding more won't help
# anything
raise original_error
sbpline = subproc_toks(line,
returnline=True,
maxcol=maxcol,
lexer=self.parser.lexer)
if line.startswith('$[$['):
# if we have already wrapped this in subproc tokens
# and it still doesn't work, adding more won't help
# anything
raise original_error
if sbpline is None:
# subprocess line had no valid tokens, likely because
# it only contained a comment.