structure TypeCheck = struct local structure E = Ein structure P = Printer structure TE= TypeEin structure PE= PhaseEin structure F=ExamplesF structure N = NormalizeEin in fun tester(e,phase,expect)= let val b= PE.checkPhase(e,phase) in if(b=expect) then( if(b=true) then (let val p=print(P.printerE e) val a1=TE.checker(e,phase) val x= TE.printTy(a1) val n=N.normalize(e) val a2=TE.checker(n,phase) in (print "==>";print(P.printerE n);TE.printTy(a1))end ) else print "") else (print(P.printerE e);print "\n Failed") end (* val r1=List.map tester [(F.probe1,1,true),(F.probe1,2,false),(F.probe2,1,true),(F.probe3,2,false),(F.probe4,1,true),(F.probe5,2,false),(F.probe6,1,true),(F.probe7,2,false),(F.probe8,1,true),(F.probe8,2,false)] val r1=List.map tester [(F.sum1,1,true),(F.sum2,1,true),(F.sum3,1,true),(F.sum4,1,true),(F.sum5,1,true),(F.sum6,1,true),(F.sum7,1,true),(F.sum8,1,true),(F.sum9,1,true)] val r1=List.map tester [(F.sumapply1,1,true),(F.sumapply2,1,true),(F.sumapply3,1,true),(F.sumapply4,1,true),(F.sumapply5,1,true),(F.sumapply6,1,true),(F.sumapply7,1,true)] *) end; (* local *) end (* local *)
Click to toggle
does not end with </html> tag
does not end with </body> tag
The output has ended thus: (F.sumapply5,1,true),(F.sumapply6,1,true),(F.sumapply7,1,true)] *) end; (* local *) end (* local *)