コード例 #1
0
ファイル: Main.cs プロジェクト: michalMilewski-8/MTKompilator
 public WhileNode(Node _condition, Node _block, int _line)
 {
     linenumber = _line;
     condition  = _condition;
     block      = _block as BlockNode;
     if (block is null)
     {
         Console.WriteLine($"line {linenumber} error: syntax error");
         errors++;
     }
     else
     {
         block.SetRefForWhile(this);
         continueJump = $"{block.blockId}_cont";
         breakJump    = $"{block.blockId}_break";
     }
 }