anchor.diff:    let rec discover_one (file_name:file_name) =
       if deps_try_find dep_graph file_name = None then
       begin
  -      let deps, mo_roots, needs_interface_inlining =
  +      let parsing_data, (deps, mo_roots, needs_interface_inlining) =
           match BU.smap_try_find !collect_one_cache file_name with
  -        | Some cached -> cached
  +        | Some cached -> Mk_pd [], cached
           | None ->
  -          let r, additional_roots = collect_one file_system_map file_name get_parsing_data_from_cache in
  -          r.direct_deps, additional_roots, r.has_inline_for_extraction in
  +          let parsing_data, deps, needs_interface_inlining, additional_roots = collect_one file_system_map file_name get_parsing_data_from_cache in
  +          parsing_data, (deps, additional_roots, needs_interface_inlining) in
         if needs_interface_inlining
         then add_interface_for_inlining file_name;
  -      BU.smap_add parse_results file_name ({
  -        direct_deps = deps;
  -        has_inline_for_extraction = needs_interface_inlining });
  +      BU.smap_add parse_results file_name parsing_data;
         let deps =
             let module_name = lowercase_module_name file_name in
             if is_implementation file_name
  
positive.code:  * AR: Parsing data for a file (also cached in the checked files)
   *     It is exactly same as what collect_one function below returns
   *)
  type parsing_data = {
    direct_deps              : list<dependence>;  //direct dependences of the file
                                                  //we no longer stote the additional roots, i.e. implementations of interfaces in the first list
                                                  //in the cache, see #1657
    has_inline_for_extraction: bool;              //if it is an interface that contains an `inline_for_extraction`
  }
  let empty_parsing_data = {
    direct_deps = [];
    has_inline_for_extraction = false
  }
  
  type deps = {
      dep_graph:dependence_graph;                 //dependences of the entire project, not just those reachable from the command line
  
negative.code:     then [ UseImplementation mname ]
      else [] in
  
    let print_dependence_list deps =
      List.fold_left (fun s d -> s ^ "::" ^ dep_to_string d) "" deps in
  
    let data_from_cache = filename |> get_parsing_data_from_cache in
    if data_from_cache |> is_some then begin
      if Options.debug_any ()
      then
        BU.print1 "Reading parsing data for %s from its checked file\n" filename;
        data_from_cache |> must |> read_parsing_data_from_cache;
        BU.print1 "Dependences as read from the cache:%s\n" (print_dependence_list (record.get_deps ()));
        BU.print1 "Parsing data as read from the cache:%s\n" (str_of_parsing_data (data_from_cache |> must));
        data_from_cache |> must,
        record.get_deps (),
        record.get_inline_for_extraction (),
        mo_roots
    end
    else
        let num_of_toplevelmods = BU.mk_ref 0 in
  
        let auto_open = hard_coded_dependencies filename in
        List.iter record.record_open_module_or_namespace auto_open;
  
        let rec collect_module = function
          | Module (lid, decls)
          | Interface (lid, decls, _) ->
              check_module_declaration_against_filename lid filename;
              record.begin_module lid;
              collect_decls decls
  
        and collect_decls decls =
          List.iter (fun x -> collect_decl x.d;
                              List.iter collect_term x.attrs;
                              if List.contains Inline_for_extraction x.quals
                              then record.set_interface_inlining ()
                              ) decls
  
        and collect_decl d =
          match d with
          | Include lid
          | Open lid ->
              record.record_open false lid
          | Friend lid ->
              record.add_dep_on_module (lowercase_join_longident lid true |> Ident.lid_of_str) true
          | ModuleAbbrev (ident, lid) ->
              ignore (record.record_module_alias ident lid)
          | TopLevelLet (_, patterms) ->
              List.iter (fun (pat, t) -> collect_pattern pat; collect_term t) patterms
          | Main t
  