protected override void RunTest(Program program, string outputFile) { FileUnitTester fut = null; try { fut = new FileUnitTester(outputFile); var factory = program.TypeFactory; var store = program.TypeStore; var aen = new ExpressionNormalizer(program.Platform.PointerType); var eqb = new EquivalenceClassBuilder(factory, store, eventListener); var tyco = new TypeCollector(factory, store, program, eventListener); aen.Transform(program); eqb.Build(program); tyco.CollectTypes(); if (buildEquivalenceClasses) { store.BuildEquivalenceClassDataTypes(factory); new TypeVariableReplacer(store).ReplaceTypeVariables(); } } catch (Exception ex) { fut.TextWriter.WriteLine(ex.Message); fut.TextWriter.WriteLine(ex.StackTrace); throw; } finally { DumpProgAndStore(program, fut.TextWriter); fut.AssertFilesEqual(); fut.Dispose(); } }
protected override void RunTest(Program program, string outputFile) { FileUnitTester fut = null; try { fut = new FileUnitTester(outputFile); var factory = program.TypeFactory; var store = program.TypeStore; var aen = new ExpressionNormalizer(program.Platform.PointerType); var eqb = new EquivalenceClassBuilder(factory, store); var tyco = new TypeCollector(factory, store, program); aen.Transform(program); eqb.Build(program); tyco.CollectTypes(); } catch(Exception ex) { fut.TextWriter.WriteLine(ex.Message); fut.TextWriter.WriteLine(ex.StackTrace); throw; } finally { DumpProgAndStore(program, fut); fut.Dispose(); } }