def split_call(lines, open_paren_line=<NUM_LIT:0>):
num_open = <NUM_LIT:0><EOL>num_closed = <NUM_LIT:0><EOL>for i, line in enumerate(lines):<EOL><INDENT>c = line.count('<STR_LIT:(>')<EOL>num_open += c<EOL>if not c and i==open_paren_line:<EOL><INDENT>raise Exception('<STR_LIT>' % (i, str(lines)))<EOL><DEDENT>num_closed += line.count('<STR_LIT:)>')<EOL>if num_open == num_closed:<EOL><INDENT>return (lines[:i+<NUM_LIT:1>], lines[i+<NUM_LIT:1>:])<EOL><DEDENT><DEDENT>print('<STR_LIT>'.join(lines))<EOL>raise Exception('<STR_LIT>' % (num_open, num_closed))<EOL>
Returns a 2-tuple where the first element is the list of lines from the
    first open paren in lines to the matching closed paren.  The second element
    is all remaining lines in a list.