def parse_if(self):
from .parser import (
parse_body,
)
if self.stmt.orelse:
add_on = [parse_body(self.stmt.orelse, self.context)]
else:
add_on = []
return LLLnode.from_list(['if', Expr.parse_value_expr(self.stmt.test, self.context), parse_body(self.stmt.body, self.context)] + add_on, typ=None, pos=getpos(self.stmt))
评论列表
文章目录