Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/charisee_dev/src/compiler/ein/printer.sml
ViewVC logotype

Diff of /branches/charisee_dev/src/compiler/ein/printer.sml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2522, Mon Jan 13 18:42:09 2014 UTC revision 2525, Tue Jan 21 19:14:22 2014 UTC
# Line 33  Line 33 
33      | E.Delta(ix) =>  handleBeta ix      | E.Delta(ix) =>  handleBeta ix
34      | E.Value(ix)=> String.concat["_",Int.toString(ix),"_"]      | E.Value(ix)=> String.concat["_",Int.toString(ix),"_"]
35      | E.Epsilon(ix, jx, kx) => String.concat["E_",Int.toString(ix), Int.toString(jx), Int.toString(kx)]      | E.Epsilon(ix, jx, kx) => String.concat["E_",Int.toString(ix), Int.toString(jx), Int.toString(kx)]
36      | E.Sum (sumindex,e1)=>String.concat[" Σ_",String.concatWith ","(List.map handleSumRange sumindex)," (", printbody e1,")"]      | E.Sum (sumindex,e1)=>String.concat[" Σ_",String.concatWith ","(List.map handleSumRange sumindex)," &S", printbody e1,"&E"]
37      | E.Neg e1 => String.concat["-", printbody e1]      | E.Neg e1 => String.concat["-NEG-", printbody e1]
38      | E.Add el => String.concat["(",String.concatWith "+" (List.map printbody el),")"]      | E.Add el => String.concat["(",String.concatWith "+" (List.map printbody el),")"]
39      | E.Sub(e1, e2) => String.concat ["(",printbody(e1),"- ",printbody(e2), ")"]      | E.Sub(e1, e2) => String.concat ["(",printbody(e1),"- ",printbody(e2), ")"]
40      | E.Prod el => String.concat["{{",String.concatWith "* " (List.map printbody el),"}}"]      | E.Prod el => String.concat["{{",String.concatWith "* " (List.map printbody el),"}}"]
# Line 54  Line 54 
54          fun Index (dim::i, count) = String.concat["(", Int.toString count,          fun Index (dim::i, count) = String.concat["(", Int.toString count,
55                  " DIM:", Int.toString dim, ")", Index(i,count+1)]                  " DIM:", Int.toString dim, ")", Index(i,count+1)]
56              | Index (_, count) = ""              | Index (_, count) = ""
57          fun Param(E.TEN t::param, i)=String.concat[Int.toString(i), ":TEN", Int.toString t," ",Param(param, i+1)]          fun Param(E.TEN(t,shape)::param, i)=let
58                    val shape'=List.map(fn e1=>Int.toString(e1)) shape
59                    in String.concat[Int.toString(i), ":TEN", Int.toString t," ", String.concatWith"," shape'," --",Param(param, i+1)]
60                    end
61              | Param(E.FLD(d)::param, i)= String.concat[Int.toString(i), ":FLD-", Int.toString d," ",Param(param, i+1)]              | Param(E.FLD(d)::param, i)= String.concat[Int.toString(i), ":FLD-", Int.toString d," ",Param(param, i+1)]
62                 | Param(E.IMG(d)::param, i)= String.concat[Int.toString(i), ":IMG-", Int.toString d," ",Param(param, i+1)]                 | Param(E.IMG(d)::param, i)= String.concat[Int.toString(i), ":IMG-", Int.toString d," ",Param(param, i+1)]
63                 | Param(E.KRN::param, i)= String.concat[Int.toString(i), ":KRN ",Param(param, i+1)]                 | Param(E.KRN::param, i)= String.concat[Int.toString(i), ":KRN ",Param(param, i+1)]

Legend:
Removed from v.2522  
changed lines
  Added in v.2525

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0