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

SCM Repository

[diderot] Diff of /branches/vis15/src/compiler/high-to-mid/high-to-mid.sml
ViewVC logotype

Diff of /branches/vis15/src/compiler/high-to-mid/high-to-mid.sml

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

revision 3739, Sat Apr 9 01:36:37 2016 UTC revision 3740, Sun Apr 10 17:09:42 2016 UTC
# Line 76  Line 76 
76     * multiplications.     * multiplications.
77     *)     *)
78      fun expandPower (env, y, [x, n]) = let      fun expandPower (env, y, [x, n]) = let
79            fun getConst x = (case SrcIR.Var.binding x            fun getConst x = (case SrcIR.Var.getDef x
80                   of SrcIR.VB_RHS(SrcIR.VAR x') => getConst x'                   of SrcIR.LIT(Literal.Int n) => SOME n
81                    | SrcIR.VB_RHS(SrcIR.LIT(Literal.Int n)) => SOME n                    | _ => NONE
                   | vb => NONE  
82                  (* end case *))                  (* end case *))
83            val x = Env.rename(env, x)            val x = Env.rename(env, x)
84            fun pow () = let            fun pow () = let

Legend:
Removed from v.3739  
changed lines
  Added in v.3740

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