File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -444,12 +444,17 @@ let rec load_file state fn =
444444 (* TODO: stateful computations should take and return the state when possible *)
445445 state
446446 in
447+ let add_bad_file err fn =
448+ if ! DeadFlag. verbose then
449+ Printf. eprintf " %s\n %!" err;
450+ bad_files := fn :: ! bad_files
451+ in
447452 let process_interface fn =
448453 last_loc := Lexing. dummy_pos;
449454 if ! DeadFlag. verbose then Printf. eprintf " Scanning interface from %s\n %!" fn;
450455 init_and_continue state fn (fun state ->
451456 match state.file_infos.cmi_sign with
452- | None -> bad_files := fn :: ! bad_files
457+ | None -> add_bad_file " Missing cmi_sign " fn
453458 | Some cmi_sign ->
454459 read_interface fn cmi_sign state
455460 )
@@ -459,7 +464,7 @@ let rec load_file state fn =
459464 if ! DeadFlag. verbose then Printf. eprintf " Scanning implementation from %s\n %!" fn;
460465 init_and_continue state fn (fun state ->
461466 match state.file_infos.cmt_struct with
462- | None -> bad_files := fn :: ! bad_files
467+ | None -> add_bad_file " Missing cmt_struct " fn
463468 | Some structure ->
464469 regabs state;
465470 let prepare (loc1 , loc2 ) =
You can’t perform that action at this time.
0 commit comments