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/src/compiler/Elaborator/types/typecheck.sml
ViewVC logotype

Diff of /sml/branches/primop-branch/src/compiler/Elaborator/types/typecheck.sml

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

revision 1372, Mon Sep 15 22:16:26 2003 UTC revision 1373, Mon Sep 15 22:16:26 2003 UTC
# Line 13  Line 13 
13    
14  (* functorized to factor out dependencies on FLINT... *)  (* functorized to factor out dependencies on FLINT... *)
15  functor TypecheckFn (val ii_ispure : II.ii -> bool  functor TypecheckFn (val ii_ispure : II.ii -> bool
16                       val ii2ty : II.ii -> Types.ty option) : TYPECHECK =               (* PRIMOP: val ii2ty : II.ii -> Types.ty option *)) : TYPECHECK =
17  struct  struct
18    
19  local open Array List Types VarCon BasicTypes TypesUtil Unify Absyn  local open Array List Types VarCon BasicTypes TypesUtil Unify Absyn
# Line 403  Line 403 
403          end          end
404  in  in
405       case exp       case exp
406        of VARexp(r as ref(VALvar{typ, info, ...}), _) =>        of VARexp(r as ref(VALvar{typ, ...}), _) =>
407              let val (ty, insts) = instantiatePoly(!typ)
408               in (VARexp(r, insts), ty)
409              end
410    (* PRIMOP:
411           (case ii2ty info of           (case ii2ty info of
412                SOME st =>                SOME st =>
413                let val (sty, insts) = instantiatePoly(st)                let val (sty, insts) = instantiatePoly(st)
# Line 416  Line 420 
420                let val (ty, insts) = instantiatePoly(!typ)                let val (ty, insts) = instantiatePoly(!typ)
421                in (VARexp(r, insts), ty)                in (VARexp(r, insts), ty)
422                end)                end)
423    *)
424         | VARexp(refvar as ref(OVLDvar _),_) =>         | VARexp(refvar as ref(OVLDvar _),_) =>
425              (exp,pushOverloaded(refvar, err region))              (exp,pushOverloaded(refvar, err region))
426         | VARexp(r as ref ERRORvar, _) => (exp, WILDCARDty)         | VARexp(r as ref ERRORvar, _) => (exp, WILDCARDty)

Legend:
Removed from v.1372  
changed lines
  Added in v.1373

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