예제 #1
0
 def visitExp9(self, ctx: MCParser.Exp9Context):
     if ctx.exp():
         return self.visit(ctx.exp())
     return self.visit(ctx.operand())
예제 #2
0
 def visitExp9(self, ctx: MCParser.Exp9Context):
     return self.visit(ctx.operand()) if ctx.operand() else self.visit(
         ctx.subexp())
예제 #3
0
 def visitExp9(self, ctx: MCParser.Exp9Context):
     #exp9: '(' exp')' | operand;
     if ctx.operand():
         return self.visit(ctx.operand())
     else:
         return self.visit(ctx.exp())
예제 #4
0
 def visitExp9(self, ctx: MCParser.Exp9Context):
     return self.visit(ctx.exp()) if ctx.getChildCount() == 3 \
         else self.visit(ctx.operand())