[driver] --merge should force merging in all cases

Summary: methinks

Reviewed By: ngorogiannis

Differential Revision: D19175684

fbshipit-source-id: 8f516c3bc
master
Jules Villard 5 years ago committed by Facebook Github Bot
parent 6d952eb3e2
commit 1c2aad9228

@ -398,13 +398,16 @@ let analyze_and_report ?suppress_console_report ~changed_files mode =
let should_analyze = should_analyze && Config.capture in let should_analyze = should_analyze && Config.capture in
let should_merge = let should_merge =
match mode with match mode with
| _ when Config.merge ->
(* [--merge] overrides other behaviors *)
true
| PythonCapture (BBuck, _) when Config.flavors && InferCommand.equal Run Config.command -> | PythonCapture (BBuck, _) when Config.flavors && InferCommand.equal Run Config.command ->
(* if doing capture + analysis of buck with flavors, we always need to merge targets before the analysis phase *) (* if doing capture + analysis of buck with flavors, we always need to merge targets before the analysis phase *)
true true
| Analyze | BuckGenruleMaster _ -> | Analyze | BuckGenruleMaster _ ->
RunState.get_merge_capture () RunState.get_merge_capture ()
| _ -> | _ ->
(* else rely on the command line value *) Config.merge false
in in
if should_merge then ( if should_merge then (
if Config.export_changed_functions then MergeCapture.merge_changed_functions () ; if Config.export_changed_functions then MergeCapture.merge_changed_functions () ;

Loading…
Cancel
Save