Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Diff of /sml/branches/primop-branch-2/src/compiler/FLINT/trans/translate.sml
ViewVC logotype

Diff of /sml/branches/primop-branch-2/src/compiler/FLINT/trans/translate.sml

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

revision 733, Fri Nov 17 05:13:45 2000 UTC revision 772, Thu Jan 4 15:36:41 2001 UTC
# Line 736  Line 736 
736        mkAccInfo(access, info, fn () => toLty d (!typ), getNameOp path)        mkAccInfo(access, info, fn () => toLty d (!typ), getNameOp path)
737    | mkVar _ = bug "unexpected vars in mkVar"    | mkVar _ = bug "unexpected vars in mkVar"
738    
739  fun mkVE (v as V.VALvar {info=II.INL_PRIM(p, SOME typ), ...}, ts, d) =  fun mkVE (v as V.VALvar {info=II.INL_PRIM(p, typ), ...}, ts, d) =
740        (case (p, ts)        (case (p, ts)
741          of (PO.POLYEQL, [t]) => eqGen(typ, t, toTcLt d)          of (PO.POLYEQL, [t]) => eqGen(typ, t, toTcLt d)
742           | (PO.POLYNEQ, [t]) => composeNOT(eqGen(typ, t, toTcLt d), toLty d t)           | (PO.POLYNEQ, [t]) => composeNOT(eqGen(typ, t, toTcLt d), toLty d t)
# Line 747  Line 747 
747                   in GENOP (dict, p, toLty d typ, map (toTyc d) ts)                   in GENOP (dict, p, toLty d typ, map (toTyc d) ts)
748                  end                  end
749           | _ => transPrim(p, (toLty d typ), map (toTyc d) ts))           | _ => transPrim(p, (toLty d typ), map (toTyc d) ts))
   
   | mkVE (v as V.VALvar {info=II.INL_PRIM(p, NONE), typ, ...}, ts, d) =  
       (case ts of [] => transPrim(p, (toLty d (!typ)), [])  
                 | [x] =>  
                    (* a temporary hack to resolve the boot/built-in.sml file *)  
                    (let val lt = toLty d (!typ)  
                         val nt = toLty d x  
                      in if LT.lt_eqv(LT.ltc_top, lt)  
                         then transPrim(p, nt, [])  
                         else bug "unexpected primop in mkVE"  
                     end)  
                 | _ => bug "unexpected poly primops in mkVE")  
   
750    | mkVE (v, [], d) = mkVar(v, d)    | mkVE (v, [], d) = mkVar(v, d)
751    | mkVE (v, ts, d) = TAPP(mkVar(v, d), map (toTyc d) ts)    | mkVE (v, ts, d) = TAPP(mkVar(v, d), map (toTyc d) ts)
752    

Legend:
Removed from v.733  
changed lines
  Added in v.772

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