anchor.diff:    let ast, _ = Driver.parse_file filename in
     collect_module ast;
     (* Util.print2 "Deps for %s: %s\n" filename (String.concat " " (!deps)); *)
  -  !deps
  +  !deps, !mo_roots
   
   let print_graph graph =
     Util.print_endline "A DOT-format graph has been dumped in the current directory as dep.graph";
  
positive.code:     | None ->
          raise (Errors.Error (Util.format1 "module not found in search path: %s\n" alias, range_of_lid lid))
    in
    let record_lid lid =
      (* Thanks to the new `?.` and `.(` syntaxes, `lid` is no longer a
         module name itself, so only its namespace part is to be
         recorded as a module dependency.  *)
      let try_key key =
        begin match smap_try_find working_map key with
        | Some pair ->
            List.iter (fun f -> add_dep (lowercase_module_name f)) (list_of_pair pair)
        | None ->
            if List.length lid.ns > 0 && Options.debug_any () then
              FStar.Errors.warn (range_of_lid lid)
                (BU.format1 "Unbound module reference %s" (string_of_lid lid false))
        end
      in
      // Option.Some x
      try_key (lowercase_join_longident lid false);
      ()
    in
  
  
    let auto_open = hard_coded_dependencies filename in
    List.iter record_open_module_or_namespace auto_open;
  
negative.code:   (verify_mode: verify_mode)
    (is_user_provided_filename: bool)
    (original_map: map)
    (filename: string):
     list<string> //direct dependences of filename
   * list<string> //additional "roots" that should be scanned
                  //i.e. implementations of interfaces in the first list
  =
    let deps = BU.mk_ref [] in
    let mo_roots = BU.mk_ref [] in
    let add_file l d =
      if not (List.existsML (fun d' -> d' = d) !l) then
        l := d :: !l
    in
    let add_dep = add_file deps in
    let add_root = add_file mo_roots in
    let working_map = smap_copy original_map in
  
    let add_dependence_edge lid =
      let key = lowercase_join_longident lid true in
      let found = smap_try_find working_map key in
      match smap_try_find working_map key with
      | Some (Some intf,  None) ->
        add_dep (lowercase_module_name intf);
        None
  
      | Some (Some intf,  Some impl) ->
        add_dep (lowercase_module_name intf);
        add_root (lowercase_module_name impl);
        None
  
      | Some (None, Some impl) ->
        add_dep (lowercase_module_name impl);
        None
  
      | Some (None, None)
      | None ->
        Some key
    in
  
    let record_open_module let_open lid =
      match add_dependence_edge lid with
      | None -> true
      | Some key ->
        let r = enter_namespace original_map working_map key in
        begin if not r then //NS: this means that lid is a namespace?
          if let_open then
            raise (Errors.Error ("let-open only supported for modules, not namespaces", (range_of_lid lid)))
          else
  