CVS: sml-dist/src/compiler/ElabData/modules moduleutil.sig, 1.2.20.2, 1.2.20.3 moduleutil.sml, 1.2.20.2, 1.2.20.3
George Kuan <[email protected]> Fri, 07 Jul 2006 13:36:20 -0700
| Newsgroups | gmane.comp.lang.sml.smlnj.commits |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/smlnj/sml-dist/src/compiler/ElabData/modules
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv22575/modules
Modified Files:
Tag: primop-branch-2
moduleutil.sig moduleutil.sml
Log Message:
elabdata builds now -- everything updated to new primopid representation scheme
Index: moduleutil.sig
===================================================================
RCS file: /cvsroot/smlnj/sml-dist/src/compiler/ElabData/modules/moduleutil.sig,v
retrieving revision 1.2.20.2
retrieving revision 1.2.20.3
diff -C2 -d -r1.2.20.2 -r1.2.20.3
*** moduleutil.sig 6 Jul 2006 22:28:24 -0000 1.2.20.2
--- moduleutil.sig 7 Jul 2006 20:36:18 -0000 1.2.20.3
***************
*** 69,73 ****
(*** extract inl_info from a list of bindings *)
! val extractInfo : Bindings.binding -> PrimOpId.primId
val getSigSymbols: Modules.Signature -> Symbol.symbol list
--- 69,73 ----
(*** extract inl_info from a list of bindings *)
! val strPrimElemInBinds : Bindings.binding list -> PrimOpId.strPrimElem
val getSigSymbols: Modules.Signature -> Symbol.symbol list
Index: moduleutil.sml
===================================================================
RCS file: /cvsroot/smlnj/sml-dist/src/compiler/ElabData/modules/moduleutil.sml,v
retrieving revision 1.2.20.2
retrieving revision 1.2.20.3
diff -C2 -d -r1.2.20.2 -r1.2.20.3
*** moduleutil.sml 6 Jul 2006 22:28:24 -0000 1.2.20.2
--- moduleutil.sml 7 Jul 2006 20:36:18 -0000 1.2.20.3
***************
*** 21,24 ****
--- 21,25 ----
structure MI = ModuleId
structure SE = StaticEnv
+ structure POI = PrimOpId
open Modules
in
***************
*** 79,83 ****
of STRent entity =>
(STR{sign = sign, rlzn = entity, access = A.selAcc(dacc,slot),
! prim = PrimOpId.selStrPrimId (dinfo, slot)},
entVar)
| _ => bug "getStr: bad entity")
--- 80,84 ----
of STRent entity =>
(STR{sign = sign, rlzn = entity, access = A.selAcc(dacc,slot),
! prim = POI.selStrPrimId (dinfo, slot)},
entVar)
| _ => bug "getStr: bad entity")
***************
*** 91,95 ****
of FCTent entity =>
(FCT{sign = sign, rlzn = entity, access = A.selAcc(dacc,slot),
! prim = PrimOpId.selStrPrimId (dinfo, slot)},
entVar)
| _ => bug "getFct: bad entity")
--- 92,96 ----
of FCTent entity =>
(FCT{sign = sign, rlzn = entity, access = A.selAcc(dacc,slot),
! prim = POI.selStrPrimId (dinfo, slot)},
entVar)
| _ => bug "getFct: bad entity")
***************
*** 115,119 ****
rlzn = EE.lookStrEnt(entities,entVar),
access = A.selAcc(access, slot),
! prim = PrimOpId.selStrPrimId (prim, slot)})
| _ => NONE)
elements
--- 116,120 ----
rlzn = EE.lookStrEnt(entities,entVar),
access = A.selAcc(access, slot),
! prim = POI.selStrPrimId (prim, slot)})
| _ => NONE)
elements
***************
*** 175,179 ****
| strDefToStr(VARstrDef(sign,entPath), entEnv) =
STR{sign=sign,rlzn=EE.lookStrEP(entEnv,entPath),
! access=A.nullAcc, info=StrE []}
(*
--- 176,180 ----
| strDefToStr(VARstrDef(sign,entPath), entEnv) =
STR{sign=sign,rlzn=EE.lookStrEP(entEnv,entPath),
! access=A.nullAcc, prim=POI.StrE []}
(*
***************
*** 183,189 ****
*)
datatype strInfo = SIGINFO of EP.entPath (* reverse order! *)
! | STRINFO of strEntity * A.access * InlInfo.inl_info
! val bogusInfo = STRINFO (bogusStrEntity, A.nullAcc, II.nullInfo)
fun getStrElem (sym, sign as SIG {elements,...}, sInfo) =
--- 184,190 ----
*)
datatype strInfo = SIGINFO of EP.entPath (* reverse order! *)
! | STRINFO of strEntity * A.access * POI.strPrimElem
! val bogusInfo = STRINFO (bogusStrEntity, A.nullAcc, POI.StrE [])
fun getStrElem (sym, sign as SIG {elements,...}, sInfo) =
***************
*** 195,199 ****
| STRINFO ({entities,...}, dacc, dinfo) =>
STRINFO(EE.lookStrEnt(entities,entVar),
! A.selAcc(dacc,slot), II.selStrInfo (dinfo, slot))
in (subsig, newInfo)
end)
--- 196,200 ----
| STRINFO ({entities,...}, dacc, dinfo) =>
STRINFO(EE.lookStrEnt(entities,entVar),
! A.selAcc(dacc,slot), POI.selStrPrimId (dinfo, slot))
in (subsig, newInfo)
end)
***************
*** 208,212 ****
FCT{sign=subfsig, rlzn=EE.lookFctEnt(entities,entVar),
access=A.selAcc(dacc, slot),
! info=II.selStrInfo (dinfo, slot)}
| _ => bug "mkFctVar - bad spec")
--- 209,213 ----
FCT{sign=subfsig, rlzn=EE.lookFctEnt(entities,entVar),
access=A.selAcc(dacc, slot),
! prim=POI.selStrPrimId (dinfo, slot)}
| _ => bug "mkFctVar - bad spec")
***************
*** 232,236 ****
VALspec{spec,slot} =>
V.VAL(V.VALvar{access = A.selAcc(dacc,slot),
! info = II.selStrInfo (dinfo, slot),
path = sp,
typ = ref(transType entities spec)})
--- 233,237 ----
VALspec{spec,slot} =>
V.VAL(V.VALvar{access = A.selAcc(dacc,slot),
! prim = POI.selValPrimFromStrPrim (dinfo, slot),
path = sp,
typ = ref(transType entities spec)})
***************
*** 258,262 ****
of STRINFO(newrlzn, newacc, newinfo) =>
STR{sign=newsig, rlzn=newrlzn, access=newacc,
! info=newinfo}
| SIGINFO ep => STRSIG{sign=newsig, entPath=rev ep})
end
--- 259,263 ----
of STRINFO(newrlzn, newacc, newinfo) =>
STR{sign=newsig, rlzn=newrlzn, access=newacc,
! prim=newinfo}
| SIGINFO ep => STRSIG{sign=newsig, entPath=rev ep})
end
***************
*** 272,276 ****
of STRINFO (newrlzn, newacc, newinfo) =>
CONSTstrDef(STR{sign=newsig, rlzn=newrlzn,
! access=newacc, info=newinfo})
| SIGINFO ep => VARstrDef(newsig, rev ep))
end
--- 273,277 ----
of STRINFO (newrlzn, newacc, newinfo) =>
CONSTstrDef(STR{sign=newsig, rlzn=newrlzn,
! access=newacc, prim=newinfo})
| SIGINFO ep => VARstrDef(newsig, rev ep))
end
***************
*** 287,292 ****
in case str
! of STR { sign, rlzn, access, info } =>
! loop(spath, sign, STRINFO(rlzn, access, info))
| STRSIG{sign, entPath} =>
loop(spath, sign, SIGINFO (rev entPath))
--- 288,293 ----
in case str
! of STR { sign, rlzn, access, prim } =>
! loop(spath, sign, STRINFO(rlzn, access, prim))
| STRSIG{sign, entPath} =>
loop(spath, sign, SIGINFO (rev entPath))
***************
*** 410,414 ****
fun getBinding (sym, str as STR st) =
(case st of
! {sign as SIG _, rlzn, access=dacc, info=dinfo} =>
let val sinfo = STRINFO(rlzn, dacc, dinfo)
val entities = #entities rlzn
--- 411,415 ----
fun getBinding (sym, str as STR st) =
(case st of
! {sign as SIG _, rlzn, access=dacc, prim=dinfo} =>
let val sinfo = STRINFO(rlzn, dacc, dinfo)
val entities = #entities rlzn
***************
*** 455,459 ****
SigMatch
*)
! fun strPrimElemInBinds [] = StrE []
| strPrimElemInBinds (bind::rest) =
let
--- 456,460 ----
SigMatch
*)
! fun strPrimElemInBinds [] = POI.StrE []
| strPrimElemInBinds (bind::rest) =
let
***************
*** 462,475 ****
of B.STRbind (M.STR { prim, ... }) => prim
| B.FCTbind (M.FCT { prim, ... }) => prim
! | B.VALbind (V.VALvar {info, ...}) => PrimE info
! | B.CONbind _ => PrimE NonPrim
! | B.TYCbind _ =>
bug "unexpected binding in strPrimElemInBinds")
in
(case (strPrimElemInBinds rest) of
! (StrE restPrims) =>
! StrE (strPrims :: restPrims)
! | PrimE id => StrE (PrimE id))
! end
(* extract all signature names from a structure --
--- 463,476 ----
of B.STRbind (M.STR { prim, ... }) => prim
| B.FCTbind (M.FCT { prim, ... }) => prim
! | B.VALbind (V.VALvar {prim, ...}) => POI.PrimE prim
! | B.CONbind _ => POI.PrimE POI.NonPrim
! | _ =>
bug "unexpected binding in strPrimElemInBinds")
in
(case (strPrimElemInBinds rest) of
! (POI.StrE restPrims) =>
! POI.StrE (strPrims :: restPrims)
! | POI.PrimE id => POI.StrE ([POI.PrimE id]))
! end (* let *)
(* extract all signature names from a structure --
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