public override void TypeCheck() { foreach (var Statement in BlockStatements) { Statement.TypeCheck(); } }
public override void TypeCheck() { cond.TypeCheck(); if (!cond.type.Equal(new BoolType())) { Console.WriteLine("Invalid type for if statement condition\n"); throw new Exception("TypeCheck Error"); } whileThen.TypeCheck(); }
public override void TypeCheck() { methodBody.TypeCheck(); }