diff --git a/infer/src/backend/Differential.ml b/infer/src/backend/Differential.ml index 80c9bcaec..86e654c36 100644 --- a/infer/src/backend/Differential.ml +++ b/infer/src/backend/Differential.ml @@ -145,19 +145,19 @@ let issue_of_cost cost_info ~delta ~prev_cost ~curr_cost = | `Increased -> Format.fprintf fmt "increased" in - let pp_raw_cost fmt cost_polynomial = + let pp_extra_msg fmt cost_polynomial = if Config.developer_mode then - Format.fprintf fmt " Cost is %a (degree is %a)" CostDomain.BasicCost.pp cost_polynomial + Format.fprintf fmt "Cost is %a (degree is %a)" CostDomain.BasicCost.pp cost_polynomial CostDomain.BasicCost.pp_degree cost_polynomial - else () + else Format.fprintf fmt "Please make sure this is an expected change." in - Format.asprintf "Complexity of this function has %a from %a to %a.%a" + Format.asprintf "Complexity of this function has %a from %a to %a. %a" (MarkupFormatter.wrap_bold pp_delta) delta (MarkupFormatter.wrap_monospaced CostDomain.BasicCost.pp_degree_hum) prev_cost (MarkupFormatter.wrap_monospaced CostDomain.BasicCost.pp_degree_hum) - curr_cost pp_raw_cost curr_cost + curr_cost pp_extra_msg curr_cost in let line = cost_info.Jsonbug_t.loc.lnum in let column = cost_info.Jsonbug_t.loc.cnum in