private void EmitBlock(BasicBlock block, bool voidReturn, CCodeBuilder code)
 {
     code.AppendLine($"bb{block.Number}:");
     code.BeginBlock();
     foreach (var statement in block.Statements)
     {
         EmitStatement(statement, voidReturn, code);
     }
     code.EndBlock();
 }
Esempio n. 2
0
        private void EmitBlock(Block block, bool isConstructor, CCodeBuilder code)
        {
            code.AppendLine($"bb{block.Number}:");
            code.BeginBlock();
            foreach (var instruction in block.Instructions)
            {
                EmitInstruction(instruction, code);
            }

            EmitInstruction(block.Terminator, isConstructor, code);
            code.EndBlock();
        }