anchor.diff:     * during recursive calls, the good_stack and good_ts grow "last dependency first" order.
      * returns the new stack, environment, and timestamps
      *)
  -  let rec iterate (depnames:list<string>) (st:stack_t) (env':env_t)
  -  (ts:m_timestamps) (good_stack:stack_t) (good_ts:m_timestamps) = //:(stack<'env, modul_t> * 'env * m_timestamps) =
  +  let rec iterate (depnames:list<string>) (st:deps_stack_t) (env':env_t)
  +                  (ts:m_timestamps) (good_stack:deps_stack_t) (good_ts:m_timestamps)
  +          : (env_t * (list<env_t> * m_timestamps)) =
       //invariant length good_stack = length good_ts, and same for stack and ts
   
       let match_dep (depnames:list<string>) (intf:option<string>) (impl:string) : (bool * list<string>) =
  
positive.code:  * if we find that the dependency at the head of ts does not match that at the head of the newly computed dependency,
   * or that the dependency is stale, we will typecheck that dependency, and everything that comes after that again
   * the stack and timestamps are passed in "last dependency first" order, so we will reverse them before checking
   * as with tc_deps, m is the dummy argument used for the stack entry
   * returns the new stack, environment, and timestamps
   *)
  let update_deps (filename:string) (m:modul_t) (stk:stack_t) (env:env_t) (ts:m_timestamps)
    : (stack_t * env_t * m_timestamps) =
    let is_stale (intf:option<string>) (impl:string) (intf_t:option<time>) (impl_t:time) :bool =
      let impl_mt = get_file_last_modification_time impl in
      (is_before impl_t impl_mt ||
  
negative.code: 
  // FIXME: Store repl_names in the stack, too
  type repl_state = { repl_line: int; repl_column: int; repl_fname: string;
                      repl_deps: (deps_stack_t * m_timestamps);
                      repl_curmod: modul_t; repl_env: env_t;
                      repl_stdin: stream_reader; repl_names: CTable.table }
  
  let repl_stack: ref<list<repl_state>> = Util.mk_ref []
  
  let repl_stack_empty () =
    match !repl_stack with
    | [] -> true
    | _ -> false
  
  let pop_repl env =
    match !repl_stack with
    | [] -> failwith "Too many pops"
    | st' :: stack ->
      pop env "#pop";
      repl_stack := stack;
      if repl_stack_empty () then cleanup st'.repl_env;
      st'
  
  let push_repl push_kind st =
    repl_stack := st :: !repl_stack;
    push (set_check_kind st.repl_env push_kind) ""
  
  let json_of_repl_state st =
    JsonAssoc
      [("loaded-dependencies",
        JsonList (List.map (fun (_, fstname, _, _) -> JsonStr fstname) (snd st.repl_deps)));
       ("options",
        JsonList (List.map json_of_fstar_option (current_fstar_options (fun _ -> true))))]
  
  