[ownership] Do not report on temporary variables.

Reviewed By: mbouaziz, ngorogiannis

Differential Revision: D8874806

fbshipit-source-id: a977f4224
master
Daiva Naudziuniene 6 years ago committed by Facebook Github Bot
parent b215cdbff4
commit 4d1abb0eeb

@ -109,6 +109,7 @@ module Domain = struct
let report_use_after_lifetime (var, _) ~use_loc ~invalidated_loc summary =
if Var.appears_in_source_code var then
let message =
F.asprintf "Variable %a is used at line %a after its lifetime ended at %a" Var.pp var
Location.pp use_loc Location.pp invalidated_loc

Loading…
Cancel
Save