Add is_ck_translation_unit to context

Reviewed By: martinoluca

Differential Revision: D3693906

fbshipit-source-id: 2e1df34
master
Ryan Rhee 8 years ago committed by Facebook Github Bot 0
parent 66385dd5f4
commit 6e6a7a8e5a

@ -9,6 +9,15 @@
type context = { type context = {
in_synchronized_block: bool; in_synchronized_block: bool;
(*
* True if the translation unit contains an ObjC class impl that's a subclass
* of CKComponent or CKComponentController.
*)
is_ck_translation_unit: bool;
} }
let empty = { in_synchronized_block = false } let empty = {
in_synchronized_block = false;
is_ck_translation_unit = false;
}

@ -162,7 +162,7 @@ let run_frontend_checkers_on_stmt context cfg cg method_decl instr =
invoke_set_of_checkers call_checker context cfg cg decl_opt key while_stmt_checker_list; invoke_set_of_checkers call_checker context cfg cg decl_opt key while_stmt_checker_list;
context context
| ObjCAtSynchronizedStmt _ -> | ObjCAtSynchronizedStmt _ ->
{ (* context with *) CLintersContext.in_synchronized_block = true } { context with CLintersContext.in_synchronized_block = true }
| _ -> context | _ -> context
let run_frontend_checkers_on_decl context cfg cg dec = let run_frontend_checkers_on_decl context cfg cg dec =

Loading…
Cancel
Save