* @throws GoloCompilationException if an error exists in the source represented by the input parse tree.
*/
public final GoloModule check(ASTCompilationUnit compilationUnit) {
ParseTreeToGoloIrVisitor parseTreeToIR = new ParseTreeToGoloIrVisitor();
parseTreeToIR.setExceptionBuilder(exceptionBuilder);
GoloModule goloModule = parseTreeToIR.transform(compilationUnit);
ClosureCaptureGoloIrVisitor closureCaptureVisitor = new ClosureCaptureGoloIrVisitor();
closureCaptureVisitor.visitModule(goloModule);
LocalReferenceAssignmentAndVerificationVisitor localReferenceVisitor = new LocalReferenceAssignmentAndVerificationVisitor();
localReferenceVisitor.setExceptionBuilder(exceptionBuilder);
localReferenceVisitor.visitModule(goloModule);