CVS: sml-dist/src/compiler/Elaborator/modules sigmatch.sml, 1.6.8.7, 1.6.8.8
David MacQueen <[email protected]> Mon, 10 Jul 2006 15:27:15 -0700
| Newsgroups | gmane.comp.lang.sml.smlnj.commits |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/smlnj/sml-dist/src/compiler/Elaborator/modules
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv7775/src/compiler/Elaborator/modules
Modified Files:
Tag: primop-branch-2
sigmatch.sml
Log Message:
further changes to primops, starting on translate.sml
Index: sigmatch.sml
===================================================================
RCS file: /cvsroot/smlnj/sml-dist/src/compiler/Elaborator/modules/sigmatch.sml,v
retrieving revision 1.6.8.7
retrieving revision 1.6.8.8
diff -C2 -d -r1.6.8.7 -r1.6.8.8
*** sigmatch.sml 7 Jul 2006 21:06:09 -0000 1.6.8.7
--- sigmatch.sml 10 Jul 2006 22:27:13 -0000 1.6.8.8
***************
*** 198,201 ****
--- 198,204 ----
val res = (Unify.unifyTy(actinst, specinst); true) handle _ => false
+ (* dbm: shouldn't this unifyTy always succeed, because when called
+ in packElems, the structure will already have been matched against
+ the signature (according to the comment before packStr) *)
val instbtvs = map TU.tyvarType insttys0
***************
*** 204,208 ****
in (insttys, instbtvs, specinst, res)
end
! *)
(* dbm: obsolete!
--- 207,211 ----
in (insttys, instbtvs, specinst, res)
end
! **)
(* dbm: obsolete!
***************
*** 1295,1305 ****
val dacc = DA.selAcc(rootAcc, s)
val dinfo = PrimOpId.selStrPrimId(rootInfo, s)
val (instys, btvs, resinst, eqflag) =
! absEqvTy(restyp, srctyp, dinfo)
!
val spath = SP.SPATH[sym]
val srcvar = VALvar{path=spath, typ=ref srctyp,
access=dacc, prim=dinfo}
val (decs', nv) =
if eqflag then (decs, srcvar)
--- 1298,1314 ----
val dacc = DA.selAcc(rootAcc, s)
val dinfo = PrimOpId.selStrPrimId(rootInfo, s)
+ (* dbm: assume that eqflag will always be true because of prior successful
+ * sigmatch, therefore this does nothing ---
val (instys, btvs, resinst, eqflag) =
! absEqvTy(restyp, srctyp, dinfo)
! *)
val spath = SP.SPATH[sym]
val srcvar = VALvar{path=spath, typ=ref srctyp,
access=dacc, prim=dinfo}
+ (* does nothing -- just use decs and srcvar below
+ val (decs', nv) = (decs, srcvar)
+ *)
+ (* dbm: was:
val (decs', nv) =
if eqflag then (decs, srcvar)
***************
*** 1319,1326 ****
in ((A.VALdec [vb])::decs, resvar)
end)
!
! val bindings' = (B.VALbind nv)::bindings
! in packElems(elems, entEnv, decs', bindings')
end)
--- 1328,1335 ----
in ((A.VALdec [vb])::decs, resvar)
end)
+ *)
! val bindings' = (B.VALbind srcvar)::bindings
! in packElems(elems, entEnv, decs, bindings')
end)
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642