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

SCM Repository

[diderot] Diff of /trunk/src/compiler/simplify/simplify.sml
ViewVC logotype

Diff of /trunk/src/compiler/simplify/simplify.sml

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

revision 398, Thu Oct 14 20:08:18 2010 UTC revision 399, Thu Oct 14 20:08:35 2010 UTC
# Line 143  Line 143 
143                  in                  in
144                    (stms, S.E_Cons xs)                    (stms, S.E_Cons xs)
145                  end                  end
146              | AST.E_Slice(e, indices) => let (* tensor slicing *)              | AST.E_Slice(e, indices, ty) => let (* tensor slicing *)
147                  val (stms, x) = simplifyExpToVar (e, stms)                  val (stms, x) = simplifyExpToVar (e, stms)
148                    fun f ([], ys, stms) = (stms, List.rev ys)
149                      | f (NONE::es, ys, stms) = f (es, NONE::ys, stms)
150                      | f (SOME e::es, ys, stms) = let
151                          val (stms, y) = simplifyExpToVar (e, stms)
152                  in                  in
153                    raise Fail "FIXME"                          f (es, SOME y::ys, stms)
154                          end
155                    val (stms, indices) = f (indices, [], stms)
156                    in
157                      (stms, S.E_Slice(x, indices, ty))
158                  end                  end
159              | AST.E_Cond(e1, e2, e3) => let              | AST.E_Cond(e1, e2, e3) => let
160                (* a conditional expression gets turned into an if-then-else statememt *)                (* a conditional expression gets turned into an if-then-else statememt *)

Legend:
Removed from v.398  
changed lines
  Added in v.399

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