def visit_lambda(self, lambda_, **kw):
func = lambda_.func
spec = inspect_getargspec(func)
if spec.varargs:
raise exc.CompileError('Lambdas with *args are not supported')
if spec.keywords:
raise exc.CompileError('Lambdas with **kwargs are not supported')
text = ', '.join(spec.args) + ' -> '
args = [literal_column(arg) for arg in spec.args]
text += self.process(func(*args), **kw)
return text
评论列表
文章目录