[threadsafe] fix the code for recognizing constructors

Reviewed By: sblackshear

Differential Revision: D4030221

fbshipit-source-id: 5433686
master
Peter O'Hearn 8 years ago committed by Facebook Github Bot
parent 5fe40bae12
commit 69f7ed5f6d

@ -110,7 +110,8 @@ module ResultsTableType = Map.Make (struct
end)
let should_analyze_proc (_,_,proc_name,proc_desc) =
(Procname.is_constructor proc_name) || (Cfg.Procdesc.get_access proc_desc <> PredSymb.Private)
not (Procname.is_constructor proc_name) &&
Cfg.Procdesc.get_access proc_desc <> PredSymb.Private
(* creates a map from proc_envs to postconditions *)
let make_results_table file_env =

@ -26,6 +26,10 @@ public class ThreadSafeExample{
Integer f;
public ThreadSafeExample() {
f = 86;
}
public void tsOK() {
synchronized (this) {
f = 42;

Loading…
Cancel
Save