def __call__(self, *args): env = Environment(self.env) arg_spec = self.args if type(arg_spec) == Symbol: env[arg_spec.string] = scm_list(*args) else: env.update({b[0].string: b[1] for b in zip(arg_spec, args)}) return [pysch.eval(f, env) for f in self.forms][-1]
def eval(str): form = pysch.read(str) return pysch.eval(form, env)
def eval(str): return pysch.eval(pysch.read(str), env)