Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/vis15/src/compiler/typechecker/typechecker.sml
ViewVC logotype

Diff of /branches/vis15/src/compiler/typechecker/typechecker.sml

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

revision 3994, Sat Jun 18 18:41:33 2016 UTC revision 3995, Sat Jun 18 20:00:19 2016 UTC
# Line 17  Line 17 
17      structure E = Env      structure E = Env
18    
19      fun check errStrm (PT.Program{span, tree}) = let      fun check errStrm (PT.Program{span, tree}) = let
20            val {globals, strand, init, create, update} = tree            val {globals, globInit, strand, init, create, update} = tree
21            val cxt = (errStrm, span)            val cxt = (errStrm, span)
22            val env = E.new()            val env = E.new()
23            val {const_dcls, input_dcls, other_dcls, env} =            val {const_dcls, input_dcls, other_dcls, env} =
24                  CheckGlobals.check (env, cxt, globals)                  CheckGlobals.check (env, cxt, globals)
25              val globInit' = Option.map (fn stm => CheckStmt.check (env, cxt, stm)) globInit
26              val (strand', env) = CheckStrand.check (env, cxt, strand)
27              val create' = CheckCreate.check (env, cxt, create)
28            val init' = (case init            val init' = (case init
29                   of SOME stm => (                   of SOME stm => (
30                        E.recordProp (env, Properties.GlobalInit);                        E.recordProp (env, Properties.GlobalInit);
31                        SOME(CheckStmt.check(E.initScope env, cxt, stm)))                        SOME(CheckStmt.check(E.initScope env, cxt, stm)))
32                    | NONE => NONE                    | NONE => NONE
33                  (* end case *))                  (* end case *))
           val (strand', env) = CheckStrand.check (env, cxt, strand)  
           val create' = CheckCreate.check (env, cxt, create)  
34            val update' = (case update            val update' = (case update
35                   of SOME stm => (                   of SOME stm => (
36                        E.recordProp(env, Properties.GlobalUpdate);                        E.recordProp(env, Properties.GlobalUpdate);
# Line 41  Line 42 
42                    const_dcls = const_dcls,                    const_dcls = const_dcls,
43                    input_dcls = input_dcls,                    input_dcls = input_dcls,
44                    globals = other_dcls,                    globals = other_dcls,
45                      globInit = globInit',
46                    strand = strand',                    strand = strand',
                   init = init',  
47                    create = create',                    create = create',
48                      init = init',
49                    update = update'                    update = update'
50                  }                  }
51            in            in

Legend:
Removed from v.3994  
changed lines
  Added in v.3995

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