[infer][checkers] filter out the experimental issues instead of using a whitelist

Summary: The issues that are not reported by default are all experimental issues from the biabduction analysis. In that case, it is easier to use a blacklist of errors to filter out so that the issues found by the checkers based on the AI framework can be reported by default without having to add them to the whitelist.

Reviewed By: jvillard

Differential Revision: D5051327

fbshipit-source-id: 2a93b11
master
Jeremy Dubreil 8 years ago committed by Facebook Github Bot
parent 06dfadecb7
commit 3b9aa9ad15

@ -306,25 +306,24 @@ let should_report (issue_kind: Exceptions.err_kind) issue_type error_desc eclass
};
issue_bucket_is_high
} else {
let issue_type_is_reportable = {
let reportable_issue_types =
let blacklisted_by_default =
Localise.[
Localise.from_string Config.default_failure_name,
context_leak,
double_lock,
empty_vector_access,
memory_leak,
quandary_taint_error,
resource_leak,
retain_cycle,
static_initialization_order_fiasco,
tainted_value_reaching_sensitive_function,
thread_safety_violation,
unsafe_guarded_by_access
analysis_stops,
divide_by_zero,
return_value_ignored,
array_out_of_bounds_l1,
array_out_of_bounds_l2,
array_out_of_bounds_l3,
null_test_after_dereference,
class_cast_exception,
uninitialized_value,
stack_variable_address_escape,
dangling_pointer_dereference,
unary_minus_applied_to_unsigned_expression,
condition_always_true,
condition_always_false
];
List.mem equal::Localise.equal reportable_issue_types issue_type
};
issue_type_is_reportable
not (List.mem equal::Localise.equal blacklisted_by_default issue_type)
}
}
}

@ -608,17 +608,9 @@ and checkers_repeated_calls =
CLOpt.mk_bool ~long:"checkers-repeated-calls" ~in_help:CLOpt.[Analyze, manual_generic]
"check for repeated calls"
and checkers, eradicate =
let checkers =
CLOpt.mk_bool ~deprecated:["checkers"] ~long:"checkers"
"Activate the checkers instead of the full analysis"
in
let eradicate =
CLOpt.mk_bool_group ~deprecated:["eradicate"] ~long:"eradicate"
"Activate the eradicate checker for Java annotations"
[checkers] []
in
(checkers, eradicate)
and checkers =
CLOpt.mk_bool ~long:"checkers" ~in_help:CLOpt.[Analyze, manual_generic]
"the checkers instead of the full analysis"
and clang_biniou_file =
CLOpt.mk_path_opt ~long:"clang-biniou-file"
@ -854,6 +846,10 @@ and enable_checks =
CLOpt.mk_string_list ~deprecated:["enable_checks"] ~long:"enable-checks" ~meta:"error name"
"Show reports coming from this type of errors"
and eradicate =
CLOpt.mk_bool ~long:"eradicate" ~in_help:CLOpt.[Analyze, manual_generic]
"the eradicate checker for Java annotations"
and eradicate_condition_redundant =
CLOpt.mk_bool ~long:"eradicate-condition-redundant"
"Condition redundant warnings"

Loading…
Cancel
Save