def split_double_braces(input):
 double_open_brace_re = re.compile('(.*?[\\[\\{\\(,])(\\s*)([\\[\\{\\(])')
 double_close_brace_re = re.compile('(.*?[\\]\\}\\)],?)(\\s*)([\\]\\}\\)])')
 masked_input = mask_quotes(input)
 masked_input = mask_comments(masked_input)
 (output, mask_output) = do_split(input, masked_input, double_open_brace_re)
 (output, mask_output) = do_split(output, mask_output, double_close_brace_re)
 return output

def split_double_braces ( input ) : double_open_brace_re = re . compile ( '(.*?[\\[\\{\\(,])(\\s*)([\\[\\{\\(])' ) double_close_brace_re = re . compile ( '(.*?[\\]\\}\\)],?)(\\s*)([\\]\\}\\)])' ) masked_input = mask_quotes ( input ) masked_input = mask_comments ( masked_input ) ( output , mask_output ) = do_split ( input , masked_input , double_open_brace_re ) ( output , mask_output ) = do_split ( output , mask_output , double_close_brace_re ) return output
masks out the quotes and comments .