[uninit] Do not crash if failed to compute post

Reviewed By: sblackshear, martinoluca

Differential Revision: D6099449

fbshipit-source-id: ce06294
master
Mehdi Bouaziz 7 years ago committed by Facebook Github Bot
parent ddda04c92b
commit 624cc5e536

@ -255,5 +255,8 @@ let checker {Callbacks.tenv; summary; proc_desc} : Specs.summary =
{RecordDomain.uninit_vars= _; RecordDomain.aliased_vars= _; RecordDomain.prepost= pre, post}
-> Summary.update_summary {pre; post} summary
| None
-> L.(die InternalError)
"Analyzer failed to compute post for %a" Typ.Procname.pp (Procdesc.get_proc_name proc_desc)
-> if Procdesc.Node.get_succs (Procdesc.get_start_node proc_desc) <> [] then (
L.internal_error "Uninit analyzer failed to compute post for %a" Typ.Procname.pp
(Procdesc.get_proc_name proc_desc) ;
summary )
else summary

Loading…
Cancel
Save