Lines Matching refs:sexp
37 def check_sexp(sexp): argument
44 if isinstance(sexp, list):
45 for s in sexp:
47 elif not isinstance(sexp, (STRING_TYPE, bytes)):
48 raise Exception('Not a sexp: {0!r}'.format(sexp))
50 def parse_sexp(sexp): argument
57 for match in sexp_token_regexp.finditer(sexp):
64 sexp = stack.pop()
65 stack[-1].append(sexp)
74 def sexp_to_string(sexp): argument
78 if isinstance(sexp, STRING_TYPE):
79 return sexp
80 if isinstance(sexp, bytes):
81 return sexp.encode('utf-8')
82 assert isinstance(sexp, list)
84 for s in sexp:
95 def sort_decls(sexp): argument
101 assert isinstance(sexp, list)
104 for s in sexp: