def split_unquoted_newlines(stmt):
 text = text_type(stmt)
 lines = SPLIT_REGEX.split(text)
 outputlines = ['']
 for line in lines:
  if (not line):
   continue
  elif LINE_MATCH.match(line):
   outputlines.append('')
  else:
   outputlines[(-1)] += line
 return outputlines

def split_unquoted_newlines ( stmt ) : text = text_type ( stmt ) lines = SPLIT_REGEX . split ( text ) outputlines = [ '' ] for line in lines : if ( not line ) : continue elif LINE_MATCH . match ( line ) : outputlines . append ( '' ) else : outputlines [ ( - 1 ) ] += line return outputlines
split a string on all unquoted newlines .