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/trunk/src/cm/smlfile/smlinfo.sml
ViewVC logotype

Diff of /sml/trunk/src/cm/smlfile/smlinfo.sml

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

revision 273, Wed May 12 08:38:51 1999 UTC revision 274, Fri May 14 05:23:02 1999 UTC
# Line 2  Line 2 
2    
3      type info      type info
4    
5        type policy = Policy.policy
6    
7      type fileoffset = AbsPath.t * int      type fileoffset = AbsPath.t * int
8      type stableinfo = { skeleton: Skeleton.decl, binary: fileoffset }      type stableinfo = { skeleton: Skeleton.decl, binary: fileoffset }
9    
10      val new : { sourcepath: AbsPath.t,      val new : policy ->
11            { sourcepath: AbsPath.t,
12                  group: AbsPath.t,                  group: AbsPath.t,
13                  history: string list,                  history: string list,
14                  share: bool option,                  share: bool option,
# Line 18  Line 21 
21    
22  structure SmlInfo :> SMLINFO = struct  structure SmlInfo :> SMLINFO = struct
23    
24        type source = GenericVC.Source.inputSource
25        type parsetree = GenericVC.Ast.dec
26    
27        type policy = Policy.policy
28    
29      type info = Dummy.t      type info = Dummy.t
30    (*
31            INFO {
32                  sourcepath: AbsPath.t,
33                  lastseen: TStamp.t ref,
34                  parsetree: { tree: parsetree, source: source } option ref,
35                  skelpath: AbsPath.t,
36                  skeleton: Skeleton.decl option ref,
37                  (* to be extended *)
38                 }
39    *)
40    
41      type fileoffset = AbsPath.t * int      type fileoffset = AbsPath.t * int
42      type stableinfo = { skeleton: Skeleton.decl, binary: fileoffset }      type stableinfo = { skeleton: Skeleton.decl, binary: fileoffset }
43    
44      fun new { sourcepath, group, history, share, stableinfo } = Dummy.v  (*
45        fun new policy { sourcepath, group, history, share, stableinfo = NONE } =
46            INFO {
47                  sourcepath = sourcepath,
48                  lastseen = ref TStamp.NOTSTAMP,
49                  parsetree = ref NONE,
50                  skelpath = Policy.mkSkelPath policy sourcepath,
51                  skeleton = ref NONE
52                 }
53    *)
54        fun new policy arg = Dummy.v
55    
56    (*
57        fun outdated (INFO { sourcepath, lastseen = ref ts, ... }) = let
58            val nts = AbsPath.modtime sourcepath
59        in
60            (TStamp.earlier (ts, nts), nts)
61        end
62    *)
63    
64    (*
65        fun getParseTree (i as INFO { sourcepath, parsetree, lastseen, ... }) = let
66            val (outd, nts) = outdated i
67            fun parse () =
68        in
69            if outd then parse ()
70            else case !parsetree of
71                NONE => parse ()
72              | SOME pt => pt
73        end
74    *)
75    
76      fun exports i = Dummy.f ()      fun exports i = (ignore Dummy.v; SymbolSet.empty)
77      fun describe i = Dummy.f ()      fun describe i = Dummy.f ()
78  end  end

Legend:
Removed from v.273  
changed lines
  Added in v.274

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