예제 #1
0
 public override object VisitDoWhileStatement([NotNull] PigeonParser.DoWhileStatementContext context)
 {
     do
     {
         try
         {
             Visit(context.stmtBlock());
         }
         catch (BreakLoopException)
         {
             return(null);
         }
     }
     catch (ContinueLoopException)
     {
     }
     while ((bool)Visit(context.expr()))
     {
         ;
     }
     return(null);
 }
예제 #2
0
 public override void ExitDoWhileStatement([NotNull] PigeonParser.DoWhileStatementContext context)
 {
     CheckExprType(context.expr(), PigeonType.Bool);
 }