diff --git a/infer/src/IR/Typ.ml b/infer/src/IR/Typ.ml index f4a794a6b..931153575 100644 --- a/infer/src/IR/Typ.ml +++ b/infer/src/IR/Typ.ml @@ -638,6 +638,13 @@ module Procname = struct | C _ | Block _ | Linters_dummy_method -> t + let objc_cpp_replace_method_name t (new_method_name: string) = + match t with + | ObjC_Cpp osig + -> ObjC_Cpp {osig with method_name= new_method_name} + | C _ | Block _ | Linters_dummy_method | Java _ + -> t + (** Get the class name of a Objective-C/C++ procedure name. *) let objc_cpp_get_class_name objc_cpp = Name.name objc_cpp.class_name diff --git a/infer/src/IR/Typ.mli b/infer/src/IR/Typ.mli index e7f5a3a03..a2a18d5ad 100644 --- a/infer/src/IR/Typ.mli +++ b/infer/src/IR/Typ.mli @@ -377,6 +377,8 @@ module Procname : sig val objc_cpp_get_class_type_name : objc_cpp -> Name.t + val objc_cpp_replace_method_name : t -> string -> t + val objc_method_kind_of_bool : bool -> objc_cpp_method_kind (** Create ObjC method type from a bool is_instance. *) diff --git a/infer/src/base/Config.ml b/infer/src/base/Config.ml index b907adb4c..bf49c3c1f 100644 --- a/infer/src/base/Config.ml +++ b/infer/src/base/Config.ml @@ -114,6 +114,8 @@ let captured_dir_name = "captured" let clang_initializer_prefix = "__infer_globals_initializer_" +let clang_inner_destructor_prefix = "__infer_inner_destructor_" + let classnames_dir_name = "classnames" (** Experimental: if true do some specialized analysis of concurrent constructs. *) diff --git a/infer/src/base/Config.mli b/infer/src/base/Config.mli index be1eb74c3..1d54715d5 100644 --- a/infer/src/base/Config.mli +++ b/infer/src/base/Config.mli @@ -101,6 +101,8 @@ val captured_dir_name : string val clang_initializer_prefix : string +val clang_inner_destructor_prefix : string + val classnames_dir_name : string val classpath : string option diff --git a/infer/src/clang/cAst_utils.ml b/infer/src/clang/cAst_utils.ml index b94223563..74cb82ee2 100644 --- a/infer/src/clang/cAst_utils.ml +++ b/infer/src/clang/cAst_utils.ml @@ -477,3 +477,12 @@ let get_cxx_base_classes decl = -> cxx_record_info.xrdi_bases | _ -> [] + +let get_cxx_virtual_base_classes decl = + let open Clang_ast_t in + match decl with + | CXXRecordDecl (_, _, _, _, _, _, _, cxx_record_info) + | ClassTemplateSpecializationDecl (_, _, _, _, _, _, _, cxx_record_info, _, _) + -> cxx_record_info.xrdi_transitive_vbases + | _ + -> [] diff --git a/infer/src/clang/cAst_utils.mli b/infer/src/clang/cAst_utils.mli index 25002d1e6..6430bf66f 100644 --- a/infer/src/clang/cAst_utils.mli +++ b/infer/src/clang/cAst_utils.mli @@ -147,3 +147,5 @@ val type_of_decl : Clang_ast_t.decl -> Clang_ast_t.type_ptr option val get_record_fields : Clang_ast_t.decl -> Clang_ast_t.decl list val get_cxx_base_classes : Clang_ast_t.decl -> Clang_ast_t.type_ptr list + +val get_cxx_virtual_base_classes : Clang_ast_t.decl -> Clang_ast_t.type_ptr list diff --git a/infer/src/clang/cFrontend_decl.ml b/infer/src/clang/cFrontend_decl.ml index 1f0139918..8857e6062 100644 --- a/infer/src/clang/cFrontend_decl.ml +++ b/infer/src/clang/cFrontend_decl.ml @@ -17,8 +17,8 @@ module CFrontend_decl_funct (T : CModule_type.CTranslation) : CModule_type.CFron let model_exists procname = Specs.summary_exists_in_models procname && not Config.models_mode (* Translates the method/function's body into nodes of the cfg. *) - let add_method trans_unit_ctx tenv cg cfg class_decl_opt procname body has_return_param - is_objc_method outer_context_opt extra_instrs = + let add_method ?(is_destructor_wrapper= false) trans_unit_ctx tenv cg cfg class_decl_opt procname + body has_return_param is_objc_method outer_context_opt extra_instrs = L.(debug Capture Verbose) "@\n@\n>>---------- ADDING METHOD: '%a' ---------<<@\n@\n" Typ.Procname.pp procname ; let handle_frontend_failure ~print fmt = @@ -41,7 +41,9 @@ module CFrontend_decl_funct (T : CModule_type.CTranslation) : CModule_type.CFron L.(debug Capture Verbose) "@\n@\n>>---------- Start translating body of function: '%s' ---------<<@\n@." (Typ.Procname.to_string procname) ; - let meth_body_nodes = T.instructions_trans context body extra_instrs exit_node in + let meth_body_nodes = + T.instructions_trans context body extra_instrs exit_node ~is_destructor_wrapper + in let proc_attributes = Procdesc.get_attributes procdesc in Procdesc.Node.add_locals_ret_declaration start_node proc_attributes (Procdesc.get_locals procdesc) ; @@ -90,8 +92,8 @@ module CFrontend_decl_funct (T : CModule_type.CTranslation) : CModule_type.CFron | None -> () - let process_method_decl ?(set_objc_accessor_attr= false) trans_unit_ctx tenv cg cfg curr_class - meth_decl ~is_objc = + let process_method_decl ?(set_objc_accessor_attr= false) ?(is_destructor= false) trans_unit_ctx + tenv cg cfg curr_class meth_decl ~is_objc = let ms, body_opt, extra_instrs = CMethod_trans.method_signature_of_decl trans_unit_ctx tenv meth_decl None in @@ -101,11 +103,32 @@ module CFrontend_decl_funct (T : CModule_type.CTranslation) : CModule_type.CFron | Some body -> let procname = CMethod_signature.ms_get_name ms in let return_param_typ_opt = CMethod_signature.ms_get_return_param_typ ms in - if CMethod_trans.create_local_procdesc ~set_objc_accessor_attr trans_unit_ctx cfg tenv ms + let ms', procname' = + if is_destructor then ( + (* For a destructor we create two procedures: a destructor wrapper and an inner destructor *) + (* A destructor wrapper is called from the outside, i.e. for destructing local variables and fields *) + (* The destructor wrapper calls the inner destructor which has the actual body *) + if CMethod_trans.create_local_procdesc ~set_objc_accessor_attr trans_unit_ctx cfg tenv + ms [body] [] is_objc_inst_method + then + add_method trans_unit_ctx tenv cg cfg curr_class procname body return_param_typ_opt + is_objc None extra_instrs ~is_destructor_wrapper:true ; + let new_method_name = + Config.clang_inner_destructor_prefix ^ Typ.Procname.get_method procname + in + let ms' = + CMethod_signature.replace_name_ms ms + (Typ.Procname.objc_cpp_replace_method_name procname new_method_name) + in + let procname' = CMethod_signature.ms_get_name ms' in + (ms', procname') ) + else (ms, procname) + in + if CMethod_trans.create_local_procdesc ~set_objc_accessor_attr trans_unit_ctx cfg tenv ms' [body] [] is_objc_inst_method then - add_method trans_unit_ctx tenv cg cfg curr_class procname body return_param_typ_opt - is_objc None extra_instrs + add_method trans_unit_ctx tenv cg cfg curr_class procname' body return_param_typ_opt + is_objc None extra_instrs ~is_destructor_wrapper:false | None -> if set_objc_accessor_attr then ignore @@ -133,8 +156,11 @@ module CFrontend_decl_funct (T : CModule_type.CTranslation) : CModule_type.CFron let process_one_method_decl trans_unit_ctx tenv cg cfg curr_class dec = let open Clang_ast_t in match dec with - | CXXMethodDecl _ | CXXConstructorDecl _ | CXXConversionDecl _ | CXXDestructorDecl _ + | CXXMethodDecl _ | CXXConstructorDecl _ | CXXConversionDecl _ + -> process_method_decl trans_unit_ctx tenv cg cfg curr_class dec ~is_objc:false + | CXXDestructorDecl _ -> process_method_decl trans_unit_ctx tenv cg cfg curr_class dec ~is_objc:false + ~is_destructor:true | ObjCMethodDecl _ -> process_method_decl trans_unit_ctx tenv cg cfg curr_class dec ~is_objc:true | ObjCPropertyImplDecl (_, obj_c_property_impl_decl_info) diff --git a/infer/src/clang/cModule_type.ml b/infer/src/clang/cModule_type.ml index 5fb350273..46634b788 100644 --- a/infer/src/clang/cModule_type.ml +++ b/infer/src/clang/cModule_type.ml @@ -20,7 +20,8 @@ module type CTranslation = sig (** Translates instructions: (statements and expressions) from the ast into sil *) val instructions_trans : - CContext.t -> Clang_ast_t.stmt -> instr_type list -> Procdesc.Node.t -> Procdesc.Node.t list + CContext.t -> Clang_ast_t.stmt -> instr_type list -> Procdesc.Node.t + -> is_destructor_wrapper:bool -> Procdesc.Node.t list (** It receives the context, a list of statements from clang ast, list of custom statments to be added before clang statements and the exit node and it returns a list of cfg nodes that represent the translation of the stmts into sil. *) diff --git a/infer/src/clang/cTrans.ml b/infer/src/clang/cTrans.ml index ba28a8c57..e3b10cd68 100644 --- a/infer/src/clang/cTrans.ml +++ b/infer/src/clang/cTrans.ml @@ -604,7 +604,8 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s let instrs = pre_trans_result.instrs @ deref_instrs in {pre_trans_result with instrs; exps= [(exp, field_typ)]} - let method_deref_trans trans_state pre_trans_result decl_ref stmt_info decl_kind = + let method_deref_trans ?(is_inner_destructor= false) trans_state pre_trans_result decl_ref + stmt_info decl_kind = let open CContext in let context = trans_state.context in let sil_loc = CLocation.get_sil_location stmt_info context in @@ -667,8 +668,27 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s Typ.Name.Cpp.from_qual_name Typ.NoTemplate (CAst_utils.get_class_name_from_member name_info) in - CMethod_trans.create_procdesc_with_pointer context decl_ptr (Some class_typename) - method_name + if is_inner_destructor then + match ms_opt with + | Some ms + -> let procname = CMethod_signature.ms_get_name ms in + let new_method_name = + Config.clang_inner_destructor_prefix ^ Typ.Procname.get_method procname + in + let ms' = + CMethod_signature.replace_name_ms ms + (Typ.Procname.objc_cpp_replace_method_name procname new_method_name) + in + ignore + (CMethod_trans.create_local_procdesc context.translation_unit_context context.cfg + context.tenv ms' [] [] false) ; + CMethod_signature.ms_get_name ms' + | None + -> CMethod_trans.create_procdesc_with_pointer context decl_ptr (Some class_typename) + method_name + else + CMethod_trans.create_procdesc_with_pointer context decl_ptr (Some class_typename) + method_name in let method_exp = (Exp.Const (Const.Cfun pname), method_typ) in { pre_trans_result with @@ -676,7 +696,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s ; exps= [method_exp] @ extra_exps ; instrs= pre_trans_result.instrs @ extra_instrs } - let destructor_deref_trans trans_state pvar_trans_result class_type_ptr si = + let destructor_deref_trans trans_state pvar_trans_result class_type_ptr si ~is_inner_destructor = let open Clang_ast_t in let destruct_decl_ref_opt = match CAst_utils.get_decl_from_typ_ptr class_type_ptr with @@ -696,7 +716,8 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s empty_res_trans | Some CXXDestructorDecl (_, _, _, {fdi_body= Some _}, _) (* Translate only those destructors that have bodies *) - -> method_deref_trans trans_state pvar_trans_result decl_ref si `CXXDestructor + -> method_deref_trans ~is_inner_destructor trans_state pvar_trans_result decl_ref si + `CXXDestructor | _ -> empty_res_trans ) | None @@ -1160,7 +1181,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s in {res_trans with exps= extra_res_trans.exps} - and cxx_destructor_call_trans trans_state si this_res_trans class_type_ptr = + and cxx_destructor_call_trans trans_state si this_res_trans class_type_ptr ~is_inner_destructor = (* cxx_method_construct_call_trans claims a priority with the same `si`. New pointer is generated to avoid premature node creation *) let si' = {si with Clang_ast_t.si_pointer= CAst_utils.get_fresh_pointer ()} in @@ -1172,7 +1193,9 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s let this_res_trans' = {this_res_trans with exps= [(this_exp, CType.add_pointer_to_typ this_typ)]} in - let res_trans_callee = destructor_deref_trans trans_state this_res_trans' class_type_ptr si' in + let res_trans_callee = + destructor_deref_trans trans_state this_res_trans' class_type_ptr si' ~is_inner_destructor + in let is_cpp_call_virtual = res_trans_callee.is_cpp_call_virtual in if res_trans_callee.exps <> [] then cxx_method_construct_call_trans trans_state_pri res_trans_callee [] si' (Typ.mk Tvoid) @@ -1300,30 +1323,79 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s in instruction trans_state transformed_stmt + and compute_this_for_destructor_calls trans_state stmt_info class_ptr = + let context = trans_state.context in + let sil_loc = CLocation.get_sil_location stmt_info context in + let class_qual_type = CAst_utils.qual_type_of_decl_ptr class_ptr in + let this_res_trans = + this_expr_trans trans_state sil_loc + (Ast_expressions.create_pointer_qual_type class_qual_type) + in + let obj_sil, class_typ = + extract_exp_from_list this_res_trans.exps + "WARNING: There should be one expression for 'this' in constructor. @\n" + in + let this_qual_type = match class_typ.desc with Typ.Tptr (t, _) -> t | _ -> class_typ in + (obj_sil, this_qual_type, this_res_trans) + + and inject_base_class_destructor_calls trans_state stmt_info bases obj_sil this_qual_type = + List.rev_map bases ~f:(fun base -> + let this_res_trans_destruct = {empty_res_trans with exps= [(obj_sil, this_qual_type)]} in + cxx_destructor_call_trans trans_state stmt_info this_res_trans_destruct base + ~is_inner_destructor:true ) + + and add_this_instrs_if_result_empty res_trans this_res_trans = + let all_res_trans = List.filter ~f:(fun res -> res <> empty_res_trans) res_trans in + let all_res_trans = + if all_res_trans <> [] then {empty_res_trans with instrs= this_res_trans.instrs} + :: all_res_trans + else all_res_trans + in + all_res_trans + + and cxx_inject_virtual_base_class_destructors trans_state stmt_info = + let context = trans_state.context in + if not (CGeneral_utils.is_cpp_translation context.translation_unit_context) then + empty_res_trans + else + (* get virtual base classes of the current class *) + let class_ptr = CContext.get_curr_class_decl_ptr context.CContext.curr_class in + let decl = Option.value_exn (CAst_utils.get_decl class_ptr) in + let typ_pointer_opt = CAst_utils.type_of_decl decl in + let bases = CAst_utils.get_cxx_virtual_base_classes decl in + let bases = match typ_pointer_opt with Some p -> bases @ [p] | None -> bases in + let _, sloc2 = stmt_info.Clang_ast_t.si_source_range in + let stmt_info_loc = {stmt_info with Clang_ast_t.si_source_range= (sloc2, sloc2)} in + (* compute `this` once that is used for all destructor calls of virtual base class *) + let obj_sil, this_qual_type, this_res_trans = + compute_this_for_destructor_calls trans_state stmt_info_loc class_ptr + in + let trans_state_pri = PriorityNode.try_claim_priority_node trans_state stmt_info_loc in + let bases_res_trans = + inject_base_class_destructor_calls trans_state_pri stmt_info_loc bases obj_sil + this_qual_type + in + let all_res_trans = add_this_instrs_if_result_empty bases_res_trans this_res_trans in + let sil_loc = CLocation.get_sil_location stmt_info_loc context in + PriorityNode.compute_results_to_parent trans_state_pri sil_loc "Destruction" stmt_info_loc + all_res_trans + and cxx_inject_field_destructors_in_destructor_body trans_state stmt_info = let context = trans_state.context in if not (CGeneral_utils.is_cpp_translation context.translation_unit_context) then empty_res_trans else - (* get fields of the current class *) + (* get fields and base classes of the current class *) let class_ptr = CContext.get_curr_class_decl_ptr context.CContext.curr_class in let decl = Option.value_exn (CAst_utils.get_decl class_ptr) in let fields = CAst_utils.get_record_fields decl in let bases = CAst_utils.get_cxx_base_classes decl in - (* compute `this` once that is used for all fields *) - let class_qual_type = CAst_utils.qual_type_of_decl_ptr class_ptr in let _, sloc2 = stmt_info.Clang_ast_t.si_source_range in let stmt_info_loc = {stmt_info with Clang_ast_t.si_source_range= (sloc2, sloc2)} in - let sil_loc = CLocation.get_sil_location stmt_info_loc context in - let this_res_trans = - this_expr_trans trans_state sil_loc - (Ast_expressions.create_pointer_qual_type class_qual_type) - in - let obj_sil, class_typ = - extract_exp_from_list this_res_trans.exps - "WARNING: There should be one expression for 'this' in constructor. @\n" + (* compute `this` once that is used for all destructors of fields and base classes *) + let obj_sil, this_qual_type, this_res_trans = + compute_this_for_destructor_calls trans_state stmt_info_loc class_ptr in - let this_qual_type = match class_typ.desc with Typ.Tptr (t, _) -> t | _ -> class_typ in (* ReturnStmt claims a priority with the same `stmt_info`. New pointer is generated to avoid premature node creation *) let stmt_info' = @@ -1347,25 +1419,18 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s {empty_res_trans with exps= [(field_exp, field_typ)]} in cxx_destructor_call_trans trans_state_pri stmt_info_loc this_res_trans_destruct - qual_type.Clang_ast_t.qt_type_ptr + qual_type.Clang_ast_t.qt_type_ptr ~is_inner_destructor:false | _ -> assert false ) in let bases_res_trans = - List.rev_map bases ~f:(fun base -> - let this_res_trans_destruct = - {empty_res_trans with exps= [(obj_sil, this_qual_type)]} - in - cxx_destructor_call_trans trans_state_pri stmt_info_loc this_res_trans_destruct base ) - in - let all_res_trans = - List.filter ~f:(fun res -> res <> empty_res_trans) (all_res_trans @ bases_res_trans) + inject_base_class_destructor_calls trans_state_pri stmt_info_loc bases obj_sil + this_qual_type in let all_res_trans = - if all_res_trans <> [] then {empty_res_trans with instrs= this_res_trans.instrs} - :: all_res_trans - else all_res_trans + add_this_instrs_if_result_empty (all_res_trans @ bases_res_trans) this_res_trans in + let sil_loc = CLocation.get_sil_location stmt_info context in PriorityNode.compute_results_to_parent trans_state_pri sil_loc "Destruction" stmt_info' all_res_trans @@ -1396,7 +1461,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s let typ = CType_decl.qual_type_to_sil_type context.CContext.tenv qual_type in let this_res_trans_destruct = {empty_res_trans with exps= [(exp, typ)]} in cxx_destructor_call_trans trans_state_pri stmt_info_loc this_res_trans_destruct - qual_type.Clang_ast_t.qt_type_ptr + qual_type.Clang_ast_t.qt_type_ptr ~is_inner_destructor:false | _ -> assert false) vars_to_destroy @@ -2752,7 +2817,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s let this_res_trans_destruct = {empty_res_trans with exps= result_trans_param.exps} in let destruct_res_trans = cxx_destructor_call_trans trans_state_pri destruct_stmt_info this_res_trans_destruct - deleted_type.Clang_ast_t.qt_type_ptr + deleted_type.Clang_ast_t.qt_type_ptr ~is_inner_destructor:false in [result_trans_param; destruct_res_trans; call_res_trans] (* --- END OF DEAD CODE --- *) else [result_trans_param; call_res_trans] @@ -3403,7 +3468,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s let res_trans_stmt = instruction trans_state stmt in fst (CTrans_utils.extract_exp_from_list res_trans_stmt.exps warning) - let instructions_trans context body extra_instrs exit_node = + let instructions_trans context body extra_instrs exit_node ~is_destructor_wrapper = let trans_state = { context ; succ_nodes= [exit_node] @@ -3416,9 +3481,15 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s let procname = Procdesc.get_proc_name context.CContext.procdesc in let is_destructor = Typ.Procname.is_destructor procname in let stmt_info, _ = Clang_ast_proj.get_stmt_tuple body in - let destructor_res = - if is_destructor then cxx_inject_field_destructors_in_destructor_body trans_state stmt_info - else empty_res_trans + let destructor_res, body = + if is_destructor_wrapper then + let stmt_info' = {stmt_info with si_pointer= CAst_utils.get_fresh_pointer ()} in + ( cxx_inject_virtual_base_class_destructors trans_state stmt_info' + (* destructor wrapper only have calls to virtual base class destructors in its body *) + , Clang_ast_t.CompoundStmt (stmt_info', []) ) + else if is_destructor then + (cxx_inject_field_destructors_in_destructor_body trans_state stmt_info, body) + else (empty_res_trans, body) in (* Injecting destructor call nodes of fields at the end of the body *) let succ_nodes = diff --git a/infer/tests/build_systems/codetoanalyze/clang_translation/src/main.cpp.dot b/infer/tests/build_systems/codetoanalyze/clang_translation/src/main.cpp.dot index cfb0abf4c..8995044ae 100644 --- a/infer/tests/build_systems/codetoanalyze/clang_translation/src/main.cpp.dot +++ b/infer/tests/build_systems/codetoanalyze/clang_translation/src/main.cpp.dot @@ -207,21 +207,32 @@ digraph iCFG { "shared_ptr#shared_ptr#std#{_ZNSt3__110shared_ptrIiEC1Ev|constexpr}.a83df2e127dfd835cd19672b6db04408_4" -> "shared_ptr#shared_ptr#std#{_ZNSt3__110shared_ptrIiEC1Ev|constexpr}.a83df2e127dfd835cd19672b6db04408_3" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_1" [label="1: Start std::shared_ptr___infer_inner_destructor_~shared_ptr\nFormals: this:int**\nLocals: \n DECLARE_LOCALS(&return); [line 182]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_1" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_2" [label="2: Exit std::shared_ptr___infer_inner_destructor_~shared_ptr \n " color=yellow style=filled] + + +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::std__shared_ptr___infer_inner_destructor_~std__shared_ptr(n$0:int**) [line 182]\n " shape="box"] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_2" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" [label="4: Call _fun_std::shared_ptr_reset \n n$2=*&this:int** [line 182]\n _=*n$2:int* [line 182]\n _fun_std::shared_ptr_reset(n$2:int**,null:int*) [line 182]\n " shape="box"] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" ; "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" [label="1: Start std::shared_ptr_~shared_ptr\nFormals: this:int**\nLocals: \n DECLARE_LOCALS(&return); [line 182]\n " color=yellow style=filled] - "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" ; + "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" ; "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_2" [label="2: Exit std::shared_ptr_~shared_ptr \n " color=yellow style=filled] -"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::std__shared_ptr_~std__shared_ptr(n$0:int**) [line 182]\n " shape="box"] +"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::shared_ptr___infer_inner_destructor_~shared_ptr(n$0:int**) [line 182]\n " shape="box"] "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_2" ; -"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" [label="4: Call _fun_std::shared_ptr_reset \n n$2=*&this:int** [line 182]\n _=*n$2:int* [line 182]\n _fun_std::shared_ptr_reset(n$2:int**,null:int*) [line 182]\n " shape="box"] - - - "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" ; "reset#shared_ptr#std#(_ZNSt3__110shared_ptrIiE5resetIivEEvPT_).a1205b56a9f5cca1b1c1504f3db46c6e_1" [label="1: Start std::shared_ptr_reset\nFormals: this:int** p:int*\nLocals: \n DECLARE_LOCALS(&return); [line 234]\n " color=yellow style=filled] diff --git a/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_default_root.cpp.dot b/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_default_root.cpp.dot index cfb0abf4c..8995044ae 100644 --- a/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_default_root.cpp.dot +++ b/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_default_root.cpp.dot @@ -207,21 +207,32 @@ digraph iCFG { "shared_ptr#shared_ptr#std#{_ZNSt3__110shared_ptrIiEC1Ev|constexpr}.a83df2e127dfd835cd19672b6db04408_4" -> "shared_ptr#shared_ptr#std#{_ZNSt3__110shared_ptrIiEC1Ev|constexpr}.a83df2e127dfd835cd19672b6db04408_3" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_1" [label="1: Start std::shared_ptr___infer_inner_destructor_~shared_ptr\nFormals: this:int**\nLocals: \n DECLARE_LOCALS(&return); [line 182]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_1" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_2" [label="2: Exit std::shared_ptr___infer_inner_destructor_~shared_ptr \n " color=yellow style=filled] + + +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::std__shared_ptr___infer_inner_destructor_~std__shared_ptr(n$0:int**) [line 182]\n " shape="box"] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_2" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" [label="4: Call _fun_std::shared_ptr_reset \n n$2=*&this:int** [line 182]\n _=*n$2:int* [line 182]\n _fun_std::shared_ptr_reset(n$2:int**,null:int*) [line 182]\n " shape="box"] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" ; "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" [label="1: Start std::shared_ptr_~shared_ptr\nFormals: this:int**\nLocals: \n DECLARE_LOCALS(&return); [line 182]\n " color=yellow style=filled] - "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" ; + "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" ; "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_2" [label="2: Exit std::shared_ptr_~shared_ptr \n " color=yellow style=filled] -"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::std__shared_ptr_~std__shared_ptr(n$0:int**) [line 182]\n " shape="box"] +"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::shared_ptr___infer_inner_destructor_~shared_ptr(n$0:int**) [line 182]\n " shape="box"] "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_2" ; -"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" [label="4: Call _fun_std::shared_ptr_reset \n n$2=*&this:int** [line 182]\n _=*n$2:int* [line 182]\n _fun_std::shared_ptr_reset(n$2:int**,null:int*) [line 182]\n " shape="box"] - - - "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" ; "reset#shared_ptr#std#(_ZNSt3__110shared_ptrIiE5resetIivEEvPT_).a1205b56a9f5cca1b1c1504f3db46c6e_1" [label="1: Start std::shared_ptr_reset\nFormals: this:int** p:int*\nLocals: \n DECLARE_LOCALS(&return); [line 234]\n " color=yellow style=filled] diff --git a/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_default_symlink.cpp.dot b/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_default_symlink.cpp.dot index cfb0abf4c..8995044ae 100644 --- a/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_default_symlink.cpp.dot +++ b/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_default_symlink.cpp.dot @@ -207,21 +207,32 @@ digraph iCFG { "shared_ptr#shared_ptr#std#{_ZNSt3__110shared_ptrIiEC1Ev|constexpr}.a83df2e127dfd835cd19672b6db04408_4" -> "shared_ptr#shared_ptr#std#{_ZNSt3__110shared_ptrIiEC1Ev|constexpr}.a83df2e127dfd835cd19672b6db04408_3" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_1" [label="1: Start std::shared_ptr___infer_inner_destructor_~shared_ptr\nFormals: this:int**\nLocals: \n DECLARE_LOCALS(&return); [line 182]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_1" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_2" [label="2: Exit std::shared_ptr___infer_inner_destructor_~shared_ptr \n " color=yellow style=filled] + + +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::std__shared_ptr___infer_inner_destructor_~std__shared_ptr(n$0:int**) [line 182]\n " shape="box"] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_2" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" [label="4: Call _fun_std::shared_ptr_reset \n n$2=*&this:int** [line 182]\n _=*n$2:int* [line 182]\n _fun_std::shared_ptr_reset(n$2:int**,null:int*) [line 182]\n " shape="box"] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" ; "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" [label="1: Start std::shared_ptr_~shared_ptr\nFormals: this:int**\nLocals: \n DECLARE_LOCALS(&return); [line 182]\n " color=yellow style=filled] - "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" ; + "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" ; "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_2" [label="2: Exit std::shared_ptr_~shared_ptr \n " color=yellow style=filled] -"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::std__shared_ptr_~std__shared_ptr(n$0:int**) [line 182]\n " shape="box"] +"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::shared_ptr___infer_inner_destructor_~shared_ptr(n$0:int**) [line 182]\n " shape="box"] "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_2" ; -"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" [label="4: Call _fun_std::shared_ptr_reset \n n$2=*&this:int** [line 182]\n _=*n$2:int* [line 182]\n _fun_std::shared_ptr_reset(n$2:int**,null:int*) [line 182]\n " shape="box"] - - - "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" ; "reset#shared_ptr#std#(_ZNSt3__110shared_ptrIiE5resetIivEEvPT_).a1205b56a9f5cca1b1c1504f3db46c6e_1" [label="1: Start std::shared_ptr_reset\nFormals: this:int** p:int*\nLocals: \n DECLARE_LOCALS(&return); [line 234]\n " color=yellow style=filled] diff --git a/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_symlink.cpp.dot b/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_symlink.cpp.dot index cfb0abf4c..8995044ae 100644 --- a/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_symlink.cpp.dot +++ b/infer/tests/build_systems/codetoanalyze/clang_translation/src/main_symlink.cpp.dot @@ -207,21 +207,32 @@ digraph iCFG { "shared_ptr#shared_ptr#std#{_ZNSt3__110shared_ptrIiEC1Ev|constexpr}.a83df2e127dfd835cd19672b6db04408_4" -> "shared_ptr#shared_ptr#std#{_ZNSt3__110shared_ptrIiEC1Ev|constexpr}.a83df2e127dfd835cd19672b6db04408_3" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_1" [label="1: Start std::shared_ptr___infer_inner_destructor_~shared_ptr\nFormals: this:int**\nLocals: \n DECLARE_LOCALS(&return); [line 182]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_1" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_2" [label="2: Exit std::shared_ptr___infer_inner_destructor_~shared_ptr \n " color=yellow style=filled] + + +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::std__shared_ptr___infer_inner_destructor_~std__shared_ptr(n$0:int**) [line 182]\n " shape="box"] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_2" ; +"__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" [label="4: Call _fun_std::shared_ptr_reset \n n$2=*&this:int** [line 182]\n _=*n$2:int* [line 182]\n _fun_std::shared_ptr_reset(n$2:int**,null:int*) [line 182]\n " shape="box"] + + + "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_4" -> "__infer_inner_destructor_~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).e1de29ff17d1dd4b1e883acc49f18c8d_3" ; "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" [label="1: Start std::shared_ptr_~shared_ptr\nFormals: this:int**\nLocals: \n DECLARE_LOCALS(&return); [line 182]\n " color=yellow style=filled] - "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" ; + "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_1" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" ; "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_2" [label="2: Exit std::shared_ptr_~shared_ptr \n " color=yellow style=filled] -"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::std__shared_ptr_~std__shared_ptr(n$0:int**) [line 182]\n " shape="box"] +"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" [label="3: Destruction \n n$0=*&this:int** [line 182]\n _=*n$0:int* [line 182]\n _fun_std::shared_ptr___infer_inner_destructor_~shared_ptr(n$0:int**) [line 182]\n " shape="box"] "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_2" ; -"~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" [label="4: Call _fun_std::shared_ptr_reset \n n$2=*&this:int** [line 182]\n _=*n$2:int* [line 182]\n _fun_std::shared_ptr_reset(n$2:int**,null:int*) [line 182]\n " shape="box"] - - - "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_4" -> "~shared_ptr#shared_ptr#std#(_ZNSt3__110shared_ptrIiED0Ev).64f04c4b2ed4a174cbcd135fb2e0998b_3" ; "reset#shared_ptr#std#(_ZNSt3__110shared_ptrIiE5resetIivEEvPT_).a1205b56a9f5cca1b1c1504f3db46c6e_1" [label="1: Start std::shared_ptr_reset\nFormals: this:int** p:int*\nLocals: \n DECLARE_LOCALS(&return); [line 234]\n " color=yellow style=filled] diff --git a/infer/tests/codetoanalyze/cpp/errors/issues.exp b/infer/tests/codetoanalyze/cpp/errors/issues.exp index 12ac9d85b..e98372871 100644 --- a/infer/tests/codetoanalyze/cpp/errors/issues.exp +++ b/infer/tests/codetoanalyze/cpp/errors/issues.exp @@ -217,7 +217,7 @@ codetoanalyze/cpp/errors/types/typeid_expr.cpp, person_typeid_name, 4, MEMORY_LE codetoanalyze/cpp/errors/types/typeid_expr.cpp, person_typeid_name, 8, DIVIDE_BY_ZERO, [start of procedure person_typeid_name(),start of procedure Person,return from a call to Person_Person,Condition is false] codetoanalyze/cpp/errors/types/typeid_expr.cpp, template_type_id_person, 2, MEMORY_LEAK, [start of procedure template_type_id_person(),start of procedure Person,return from a call to Person_Person,Skipping template_typeid(): function or method not found] codetoanalyze/cpp/errors/types/typeid_expr.cpp, template_type_id_person, 5, DIVIDE_BY_ZERO, [start of procedure template_type_id_person(),start of procedure Person,return from a call to Person_Person,Condition is false] -codetoanalyze/cpp/errors/types/typeid_expr.cpp, template_typeid, 2, MEMORY_LEAK, [start of procedure template_typeid(),start of procedure Person,return from a call to Person_Person,start of procedure Person,return from a call to Person_Person,start of procedure ~Person,return from a call to Person_~Person] +codetoanalyze/cpp/errors/types/typeid_expr.cpp, template_typeid, 2, MEMORY_LEAK, [start of procedure template_typeid(),start of procedure Person,return from a call to Person_Person,start of procedure Person,return from a call to Person_Person,start of procedure ~Person,start of procedure __infer_inner_destructor_~Person,return from a call to Person___infer_inner_destructor_~Person,return from a call to Person_~Person] codetoanalyze/cpp/errors/vector/access_field_later.cpp, getIntPtr, 2, EMPTY_VECTOR_ACCESS, [start of procedure getIntPtr()] codetoanalyze/cpp/errors/vector/access_field_later.cpp, getWithCopy, 2, EMPTY_VECTOR_ACCESS, [start of procedure getWithCopy()] codetoanalyze/cpp/errors/vector/access_field_later.cpp, getWithCopyPtr, 2, EMPTY_VECTOR_ACCESS, [start of procedure getWithCopyPtr()] diff --git a/infer/tests/codetoanalyze/cpp/frontend/destructors/break_scope.cpp.dot b/infer/tests/codetoanalyze/cpp/frontend/destructors/break_scope.cpp.dot index cd2fc45d0..52b63405c 100644 --- a/infer/tests/codetoanalyze/cpp/frontend/destructors/break_scope.cpp.dot +++ b/infer/tests/codetoanalyze/cpp/frontend/destructors/break_scope.cpp.dot @@ -479,13 +479,24 @@ digraph iCFG { "X#X#break_scope#{_ZN11break_scope1XC1Ev|constexpr}.c40e3536eb37af840612f198a520182a_2" [label="2: Exit break_scope::X_X \n " color=yellow style=filled] +"__infer_inner_destructor_~X#X#break_scope#(_ZN11break_scope1XD0Ev).ef09409bcd4ddc481e7220bbe1a3263d_1" [label="1: Start break_scope::X___infer_inner_destructor_~X\nFormals: this:break_scope::X*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~X#X#break_scope#(_ZN11break_scope1XD0Ev).ef09409bcd4ddc481e7220bbe1a3263d_1" -> "__infer_inner_destructor_~X#X#break_scope#(_ZN11break_scope1XD0Ev).ef09409bcd4ddc481e7220bbe1a3263d_2" ; +"__infer_inner_destructor_~X#X#break_scope#(_ZN11break_scope1XD0Ev).ef09409bcd4ddc481e7220bbe1a3263d_2" [label="2: Exit break_scope::X___infer_inner_destructor_~X \n " color=yellow style=filled] + + "~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_1" [label="1: Start break_scope::X_~X\nFormals: this:break_scope::X*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] - "~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_1" -> "~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_2" ; + "~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_1" -> "~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_3" ; "~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_2" [label="2: Exit break_scope::X_~X \n " color=yellow style=filled] +"~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_3" [label="3: Destruction \n n$0=*&this:break_scope::X* [line 12]\n _=*n$0:break_scope::X [line 12]\n _fun_break_scope::X___infer_inner_destructor_~X(n$0:break_scope::X*) [line 12]\n " shape="box"] + + + "~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_3" -> "~X#X#break_scope#(_ZN11break_scope1XD0Ev).c4abbf50a9425a7490a5d9414ad324ac_2" ; "X#X#break_scope#{_ZN11break_scope1XC1ERKS0_|constexpr}.ac741cc117694680a0db71143e20b138_1" [label="1: Start break_scope::X_X\nFormals: this:break_scope::X* __param_0:break_scope::X const &\nLocals: \n DECLARE_LOCALS(&return); [line 11]\n " color=yellow style=filled] @@ -611,13 +622,24 @@ digraph iCFG { "vec#vec#break_scope#{_ZN11break_scope3vecC1Ev}.cb47feb1d11066b4d5321ee0edf92827_3" -> "vec#vec#break_scope#{_ZN11break_scope3vecC1Ev}.cb47feb1d11066b4d5321ee0edf92827_2" ; +"__infer_inner_destructor_~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).607b2f31918f9f66761e59a18277e9f1_1" [label="1: Start break_scope::vec___infer_inner_destructor_~vec\nFormals: this:break_scope::vec*\nLocals: \n DECLARE_LOCALS(&return); [line 34]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).607b2f31918f9f66761e59a18277e9f1_1" -> "__infer_inner_destructor_~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).607b2f31918f9f66761e59a18277e9f1_2" ; +"__infer_inner_destructor_~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).607b2f31918f9f66761e59a18277e9f1_2" [label="2: Exit break_scope::vec___infer_inner_destructor_~vec \n " color=yellow style=filled] + + "~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_1" [label="1: Start break_scope::vec_~vec\nFormals: this:break_scope::vec*\nLocals: \n DECLARE_LOCALS(&return); [line 34]\n " color=yellow style=filled] - "~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_1" -> "~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_2" ; + "~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_1" -> "~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_3" ; "~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_2" [label="2: Exit break_scope::vec_~vec \n " color=yellow style=filled] +"~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_3" [label="3: Destruction \n n$0=*&this:break_scope::vec* [line 34]\n _=*n$0:break_scope::vec [line 34]\n _fun_break_scope::vec___infer_inner_destructor_~vec(n$0:break_scope::vec*) [line 34]\n " shape="box"] + + + "~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_3" -> "~vec#vec#break_scope#(_ZN11break_scope3vecD0Ev).053725d75c82d883e2b287c914d73376_2" ; "begin#vec#break_scope#(_ZN11break_scope3vec5beginEv).74725bafe1f90b7d151b8912e60afd42_1" [label="1: Start break_scope::vec_begin\nFormals: this:break_scope::vec* __return_param:break_scope::iterator*\nLocals: 0$?%__sil_tmpSIL_materialize_temp__n$1:break_scope::iterator \n DECLARE_LOCALS(&return,&0$?%__sil_tmpSIL_materialize_temp__n$1); [line 36]\n " color=yellow style=filled] diff --git a/infer/tests/codetoanalyze/cpp/frontend/destructors/call_on_delete.cpp.dot b/infer/tests/codetoanalyze/cpp/frontend/destructors/call_on_delete.cpp.dot index cbdd93a9f..e79058785 100644 --- a/infer/tests/codetoanalyze/cpp/frontend/destructors/call_on_delete.cpp.dot +++ b/infer/tests/codetoanalyze/cpp/frontend/destructors/call_on_delete.cpp.dot @@ -22,11 +22,22 @@ digraph iCFG { "deleteX#_Z7deleteXP1X.ddffb30c0ee6370177b08414b2c6d138_3" -> "deleteX#_Z7deleteXP1X.ddffb30c0ee6370177b08414b2c6d138_2" ; +"__infer_inner_destructor_~X#X#(_ZN1XD0Ev).a1bdd64497fedf372add1f9d013cfbad_1" [label="1: Start X___infer_inner_destructor_~X\nFormals: this:X*\nLocals: \n DECLARE_LOCALS(&return); [line 11]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~X#X#(_ZN1XD0Ev).a1bdd64497fedf372add1f9d013cfbad_1" -> "__infer_inner_destructor_~X#X#(_ZN1XD0Ev).a1bdd64497fedf372add1f9d013cfbad_2" ; +"__infer_inner_destructor_~X#X#(_ZN1XD0Ev).a1bdd64497fedf372add1f9d013cfbad_2" [label="2: Exit X___infer_inner_destructor_~X \n " color=yellow style=filled] + + "~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_1" [label="1: Start X_~X\nFormals: this:X*\nLocals: \n DECLARE_LOCALS(&return); [line 11]\n " color=yellow style=filled] - "~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_1" -> "~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_2" ; + "~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_1" -> "~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_3" ; "~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_2" [label="2: Exit X_~X \n " color=yellow style=filled] +"~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_3" [label="3: Destruction \n n$0=*&this:X* [line 11]\n _=*n$0:X [line 11]\n _fun_X___infer_inner_destructor_~X(n$0:X*) [line 11]\n " shape="box"] + + + "~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_3" -> "~X#X#(_ZN1XD0Ev).570f4e582c393d8fb931d72cddd28836_2" ; } diff --git a/infer/tests/codetoanalyze/cpp/frontend/destructors/continue_scope.cpp.dot b/infer/tests/codetoanalyze/cpp/frontend/destructors/continue_scope.cpp.dot index f4014c66b..e1c3b8bf9 100644 --- a/infer/tests/codetoanalyze/cpp/frontend/destructors/continue_scope.cpp.dot +++ b/infer/tests/codetoanalyze/cpp/frontend/destructors/continue_scope.cpp.dot @@ -402,13 +402,24 @@ digraph iCFG { "X#X#continue_scope#{_ZN14continue_scope1XC1Ev|constexpr}.309ed1a5aaa9a7f91a1b2c965b22fb65_2" [label="2: Exit continue_scope::X_X \n " color=yellow style=filled] +"__infer_inner_destructor_~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).6e2c8e3d1d5c09b82f94d5cf6f8b46ca_1" [label="1: Start continue_scope::X___infer_inner_destructor_~X\nFormals: this:continue_scope::X*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).6e2c8e3d1d5c09b82f94d5cf6f8b46ca_1" -> "__infer_inner_destructor_~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).6e2c8e3d1d5c09b82f94d5cf6f8b46ca_2" ; +"__infer_inner_destructor_~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).6e2c8e3d1d5c09b82f94d5cf6f8b46ca_2" [label="2: Exit continue_scope::X___infer_inner_destructor_~X \n " color=yellow style=filled] + + "~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_1" [label="1: Start continue_scope::X_~X\nFormals: this:continue_scope::X*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] - "~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_1" -> "~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_2" ; + "~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_1" -> "~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_3" ; "~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_2" [label="2: Exit continue_scope::X_~X \n " color=yellow style=filled] +"~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_3" [label="3: Destruction \n n$0=*&this:continue_scope::X* [line 12]\n _=*n$0:continue_scope::X [line 12]\n _fun_continue_scope::X___infer_inner_destructor_~X(n$0:continue_scope::X*) [line 12]\n " shape="box"] + + + "~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_3" -> "~X#X#continue_scope#(_ZN14continue_scope1XD0Ev).4072450acbc3373059f5ebe403a65b9b_2" ; "X#X#continue_scope#{_ZN14continue_scope1XC1ERKS0_|constexpr}.e9ad42d27c2e4394802f687830879658_1" [label="1: Start continue_scope::X_X\nFormals: this:continue_scope::X* __param_0:continue_scope::X const &\nLocals: \n DECLARE_LOCALS(&return); [line 11]\n " color=yellow style=filled] @@ -534,13 +545,24 @@ digraph iCFG { "vec#vec#continue_scope#{_ZN14continue_scope3vecC1Ev}.02564fa4cf1e87af7244f8fd35b7d277_3" -> "vec#vec#continue_scope#{_ZN14continue_scope3vecC1Ev}.02564fa4cf1e87af7244f8fd35b7d277_2" ; +"__infer_inner_destructor_~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).ca8dc8da9da26cefea028f77edaba5ec_1" [label="1: Start continue_scope::vec___infer_inner_destructor_~vec\nFormals: this:continue_scope::vec*\nLocals: \n DECLARE_LOCALS(&return); [line 34]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).ca8dc8da9da26cefea028f77edaba5ec_1" -> "__infer_inner_destructor_~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).ca8dc8da9da26cefea028f77edaba5ec_2" ; +"__infer_inner_destructor_~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).ca8dc8da9da26cefea028f77edaba5ec_2" [label="2: Exit continue_scope::vec___infer_inner_destructor_~vec \n " color=yellow style=filled] + + "~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_1" [label="1: Start continue_scope::vec_~vec\nFormals: this:continue_scope::vec*\nLocals: \n DECLARE_LOCALS(&return); [line 34]\n " color=yellow style=filled] - "~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_1" -> "~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_2" ; + "~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_1" -> "~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_3" ; "~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_2" [label="2: Exit continue_scope::vec_~vec \n " color=yellow style=filled] +"~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_3" [label="3: Destruction \n n$0=*&this:continue_scope::vec* [line 34]\n _=*n$0:continue_scope::vec [line 34]\n _fun_continue_scope::vec___infer_inner_destructor_~vec(n$0:continue_scope::vec*) [line 34]\n " shape="box"] + + + "~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_3" -> "~vec#vec#continue_scope#(_ZN14continue_scope3vecD0Ev).0f31d591628d81f66a8e6d7551b6574f_2" ; "begin#vec#continue_scope#(_ZN14continue_scope3vec5beginEv).4167375ef226120932c1b2e1ed1e96fb_1" [label="1: Start continue_scope::vec_begin\nFormals: this:continue_scope::vec* __return_param:continue_scope::iterator*\nLocals: 0$?%__sil_tmpSIL_materialize_temp__n$1:continue_scope::iterator \n DECLARE_LOCALS(&return,&0$?%__sil_tmpSIL_materialize_temp__n$1); [line 36]\n " color=yellow style=filled] diff --git a/infer/tests/codetoanalyze/cpp/frontend/destructors/destructor_bases.cpp b/infer/tests/codetoanalyze/cpp/frontend/destructors/destructor_bases.cpp index 739d67104..8a691d78a 100644 --- a/infer/tests/codetoanalyze/cpp/frontend/destructors/destructor_bases.cpp +++ b/infer/tests/codetoanalyze/cpp/frontend/destructors/destructor_bases.cpp @@ -7,12 +7,17 @@ * of patent rights can be found in the PATENTS file in the same directory. */ -struct A { +struct T { + T(){}; + ~T(){}; +}; + +struct A : virtual T { A(){}; ~A(){}; }; -struct B : A { +struct B : virtual A { B(){}; ~B(){}; }; @@ -32,3 +37,8 @@ struct E : B, C, D { E(){}; ~E(){}; }; + +struct F : B, virtual C, D { + F(){}; + ~F(){}; +}; diff --git a/infer/tests/codetoanalyze/cpp/frontend/destructors/destructor_bases.cpp.dot b/infer/tests/codetoanalyze/cpp/frontend/destructors/destructor_bases.cpp.dot index b80225896..6022d2ad3 100644 --- a/infer/tests/codetoanalyze/cpp/frontend/destructors/destructor_bases.cpp.dot +++ b/infer/tests/codetoanalyze/cpp/frontend/destructors/destructor_bases.cpp.dot @@ -1,121 +1,266 @@ /* @generated */ digraph iCFG { -"A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_1" [label="1: Start A_A\nFormals: this:A*\nLocals: \n DECLARE_LOCALS(&return); [line 11]\n " color=yellow style=filled] +"A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_1" [label="1: Start A_A\nFormals: this:A*\nLocals: \n DECLARE_LOCALS(&return); [line 16]\n " color=yellow style=filled] - "A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_1" -> "A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_2" ; + "A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_1" -> "A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_3" ; "A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_2" [label="2: Exit A_A \n " color=yellow style=filled] -"~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_1" [label="1: Start A_~A\nFormals: this:A*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] +"A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_3" [label="3: Constructor Init \n n$0=*&this:A* [line 16]\n _fun_T_T(n$0:A*) [line 16]\n " shape="box"] - "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_1" -> "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_2" ; + "A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_3" -> "A#A#{_ZN1AC1Ev}.2d3ff9efa1bcbece3182f08e3514d828_2" ; +"__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_1" [label="1: Start A___infer_inner_destructor_~A\nFormals: this:A*\nLocals: \n DECLARE_LOCALS(&return); [line 17]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_1" -> "__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_2" ; +"__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_2" [label="2: Exit A___infer_inner_destructor_~A \n " color=yellow style=filled] + + +"~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_1" [label="1: Start A_~A\nFormals: this:A*\nLocals: \n DECLARE_LOCALS(&return); [line 17]\n " color=yellow style=filled] + + + "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_1" -> "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_3" ; "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_2" [label="2: Exit A_~A \n " color=yellow style=filled] -"B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_1" [label="1: Start B_B\nFormals: this:B*\nLocals: \n DECLARE_LOCALS(&return); [line 16]\n " color=yellow style=filled] +"~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_3" [label="3: Destruction \n n$0=*&this:A* [line 17]\n _=*n$0:A [line 17]\n _fun_A___infer_inner_destructor_~A(n$0:A*) [line 17]\n _=*n$0:A [line 17]\n _fun_T___infer_inner_destructor_~T(n$0:A*) [line 17]\n " shape="box"] + + + "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_3" -> "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_2" ; +"B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_1" [label="1: Start B_B\nFormals: this:B*\nLocals: \n DECLARE_LOCALS(&return); [line 21]\n " color=yellow style=filled] - "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_1" -> "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_3" ; + "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_1" -> "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_4" ; "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_2" [label="2: Exit B_B \n " color=yellow style=filled] -"B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_3" [label="3: Constructor Init \n n$0=*&this:B* [line 16]\n _fun_A_A(n$0:B*) [line 16]\n " shape="box"] +"B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_3" [label="3: Constructor Init \n n$0=*&this:B* [line 21]\n _fun_A_A(n$0:B*) [line 21]\n " shape="box"] "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_3" -> "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_2" ; -"~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_1" [label="1: Start B_~B\nFormals: this:B*\nLocals: \n DECLARE_LOCALS(&return); [line 17]\n " color=yellow style=filled] +"B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_4" [label="4: Constructor Init \n n$1=*&this:B* [line 21]\n _fun_T_T(n$1:B*) [line 21]\n " shape="box"] + + + "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_4" -> "B#B#{_ZN1BC1Ev}.7d36f8f9e357133df32509b5d80a4f1d_3" ; +"__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_1" [label="1: Start B___infer_inner_destructor_~B\nFormals: this:B*\nLocals: \n DECLARE_LOCALS(&return); [line 22]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_1" -> "__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_2" ; +"__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_2" [label="2: Exit B___infer_inner_destructor_~B \n " color=yellow style=filled] + + +"~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_1" [label="1: Start B_~B\nFormals: this:B*\nLocals: \n DECLARE_LOCALS(&return); [line 22]\n " color=yellow style=filled] "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_1" -> "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_3" ; "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_2" [label="2: Exit B_~B \n " color=yellow style=filled] -"~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_3" [label="3: Destruction \n n$0=*&this:B* [line 17]\n _=*n$0:B [line 17]\n _fun_A_~A(n$0:B*) [line 17]\n " shape="box"] +"~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_3" [label="3: Destruction \n n$0=*&this:B* [line 22]\n _=*n$0:B [line 22]\n _fun_B___infer_inner_destructor_~B(n$0:B*) [line 22]\n _=*n$0:B [line 22]\n _fun_A___infer_inner_destructor_~A(n$0:B*) [line 22]\n _=*n$0:B [line 22]\n _fun_T___infer_inner_destructor_~T(n$0:B*) [line 22]\n " shape="box"] "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_3" -> "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_2" ; -"C#C#{_ZN1CC1Ev}.3e03405a28565a3b8cdc219c868b91d4_1" [label="1: Start C_C\nFormals: this:C*\nLocals: \n DECLARE_LOCALS(&return); [line 21]\n " color=yellow style=filled] +"C#C#{_ZN1CC1Ev}.3e03405a28565a3b8cdc219c868b91d4_1" [label="1: Start C_C\nFormals: this:C*\nLocals: \n DECLARE_LOCALS(&return); [line 26]\n " color=yellow style=filled] "C#C#{_ZN1CC1Ev}.3e03405a28565a3b8cdc219c868b91d4_1" -> "C#C#{_ZN1CC1Ev}.3e03405a28565a3b8cdc219c868b91d4_2" ; "C#C#{_ZN1CC1Ev}.3e03405a28565a3b8cdc219c868b91d4_2" [label="2: Exit C_C \n " color=yellow style=filled] -"~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_1" [label="1: Start C_~C\nFormals: this:C*\nLocals: \n DECLARE_LOCALS(&return); [line 22]\n " color=yellow style=filled] +"__infer_inner_destructor_~C#C#(_ZN1CD0Ev).383a303e5889d004732e2e54cf423aff_1" [label="1: Start C___infer_inner_destructor_~C\nFormals: this:C*\nLocals: \n DECLARE_LOCALS(&return); [line 27]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~C#C#(_ZN1CD0Ev).383a303e5889d004732e2e54cf423aff_1" -> "__infer_inner_destructor_~C#C#(_ZN1CD0Ev).383a303e5889d004732e2e54cf423aff_2" ; +"__infer_inner_destructor_~C#C#(_ZN1CD0Ev).383a303e5889d004732e2e54cf423aff_2" [label="2: Exit C___infer_inner_destructor_~C \n " color=yellow style=filled] + + +"~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_1" [label="1: Start C_~C\nFormals: this:C*\nLocals: \n DECLARE_LOCALS(&return); [line 27]\n " color=yellow style=filled] - "~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_1" -> "~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_2" ; + "~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_1" -> "~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_3" ; "~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_2" [label="2: Exit C_~C \n " color=yellow style=filled] -"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_1" [label="1: Start D_D\nFormals: this:D*\nLocals: \n DECLARE_LOCALS(&return); [line 27]\n " color=yellow style=filled] +"~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_3" [label="3: Destruction \n n$0=*&this:C* [line 27]\n _=*n$0:C [line 27]\n _fun_C___infer_inner_destructor_~C(n$0:C*) [line 27]\n " shape="box"] + + + "~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_3" -> "~C#C#(_ZN1CD0Ev).5004cab30e9be2ae0ac437333f531054_2" ; +"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_1" [label="1: Start D_D\nFormals: this:D*\nLocals: \n DECLARE_LOCALS(&return); [line 32]\n " color=yellow style=filled] - "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_1" -> "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_5" ; + "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_1" -> "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_6" ; "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_2" [label="2: Exit D_D \n " color=yellow style=filled] -"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_3" [label="3: Constructor Init \n n$0=*&this:D* [line 27]\n _fun_B_B(n$0.b:B*) [line 27]\n " shape="box"] +"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_3" [label="3: Constructor Init \n n$0=*&this:D* [line 32]\n _fun_B_B(n$0.b:B*) [line 32]\n " shape="box"] "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_3" -> "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_2" ; -"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_4" [label="4: Constructor Init \n n$1=*&this:D* [line 27]\n _fun_C_C(n$1:D*) [line 27]\n " shape="box"] +"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_4" [label="4: Constructor Init \n n$1=*&this:D* [line 32]\n _fun_C_C(n$1:D*) [line 32]\n " shape="box"] "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_4" -> "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_3" ; -"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_5" [label="5: Constructor Init \n n$2=*&this:D* [line 27]\n _fun_A_A(n$2:D*) [line 27]\n " shape="box"] +"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_5" [label="5: Constructor Init \n n$2=*&this:D* [line 32]\n _fun_A_A(n$2:D*) [line 32]\n " shape="box"] "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_5" -> "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_4" ; -"~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_1" [label="1: Start D_~D\nFormals: this:D*\nLocals: a:A \n DECLARE_LOCALS(&return,&a); [line 28]\n " color=yellow style=filled] +"D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_6" [label="6: Constructor Init \n n$3=*&this:D* [line 32]\n _fun_T_T(n$3:D*) [line 32]\n " shape="box"] - "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_1" -> "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_5" ; + "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_6" -> "D#D#{_ZN1DC1Ev}.1fb38ad288cb592a49d11e238b53d161_5" ; +"~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_1" [label="1: Start D_~D\nFormals: this:D*\nLocals: \n DECLARE_LOCALS(&return); [line 33]\n " color=yellow style=filled] + + + "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_1" -> "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_3" ; "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_2" [label="2: Exit D_~D \n " color=yellow style=filled] -"~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_3" [label="3: Destruction \n n$0=*&this:D* [line 28]\n _=*n$0.b:B [line 28]\n _fun_B_~B(n$0.b:B*) [line 28]\n _=*n$0:D [line 28]\n _fun_C_~C(n$0:D*) [line 28]\n _=*n$0:D [line 28]\n _fun_A_~A(n$0:D*) [line 28]\n " shape="box"] +"~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_3" [label="3: Destruction \n n$0=*&this:D* [line 33]\n _=*n$0:D [line 33]\n _fun_D___infer_inner_destructor_~D(n$0:D*) [line 33]\n _=*n$0:D [line 33]\n _fun_T___infer_inner_destructor_~T(n$0:D*) [line 33]\n " shape="box"] "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_3" -> "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_2" ; -"~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_4" [label="4: Destruction \n _=*&a:A [line 28]\n _fun_A_~A(&a:A*) [line 28]\n " shape="box"] +"__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_1" [label="1: Start D___infer_inner_destructor_~D\nFormals: this:D*\nLocals: a:A \n DECLARE_LOCALS(&return,&a); [line 33]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_1" -> "__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_5" ; +"__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_2" [label="2: Exit D___infer_inner_destructor_~D \n " color=yellow style=filled] + + +"__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_3" [label="3: Destruction \n n$0=*&this:D* [line 33]\n _=*n$0.b:B [line 33]\n _fun_B_~B(n$0.b:B*) [line 33]\n _=*n$0:D [line 33]\n _fun_C___infer_inner_destructor_~C(n$0:D*) [line 33]\n _=*n$0:D [line 33]\n _fun_A___infer_inner_destructor_~A(n$0:D*) [line 33]\n " shape="box"] + + + "__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_3" -> "__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_2" ; +"__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_4" [label="4: Destruction \n _=*&a:A [line 33]\n _fun_A_~A(&a:A*) [line 33]\n " shape="box"] - "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_4" -> "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_3" ; -"~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_5" [label="5: DeclStmt \n _fun_A_A(&a:A*) [line 28]\n " shape="box"] + "__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_4" -> "__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_3" ; +"__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_5" [label="5: DeclStmt \n _fun_A_A(&a:A*) [line 33]\n " shape="box"] - "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_5" -> "~D#D#(_ZN1DD0Ev).927ae640f732cd5172d9f1a635578398_4" ; -"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_1" [label="1: Start E_E\nFormals: this:E*\nLocals: \n DECLARE_LOCALS(&return); [line 32]\n " color=yellow style=filled] + "__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_5" -> "__infer_inner_destructor_~D#D#(_ZN1DD0Ev).fbd3458798cca31644b33a96a04d3fe2_4" ; +"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_1" [label="1: Start E_E\nFormals: this:E*\nLocals: \n DECLARE_LOCALS(&return); [line 37]\n " color=yellow style=filled] - "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_1" -> "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_5" ; + "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_1" -> "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_7" ; "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_2" [label="2: Exit E_E \n " color=yellow style=filled] -"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_3" [label="3: Constructor Init \n n$0=*&this:E* [line 32]\n _fun_D_D(n$0:E*) [line 32]\n " shape="box"] +"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_3" [label="3: Constructor Init \n n$0=*&this:E* [line 37]\n _fun_D_D(n$0:E*) [line 37]\n " shape="box"] "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_3" -> "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_2" ; -"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_4" [label="4: Constructor Init \n n$1=*&this:E* [line 32]\n _fun_C_C(n$1:E*) [line 32]\n " shape="box"] +"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_4" [label="4: Constructor Init \n n$1=*&this:E* [line 37]\n _fun_C_C(n$1:E*) [line 37]\n " shape="box"] "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_4" -> "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_3" ; -"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_5" [label="5: Constructor Init \n n$2=*&this:E* [line 32]\n _fun_B_B(n$2:E*) [line 32]\n " shape="box"] +"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_5" [label="5: Constructor Init \n n$2=*&this:E* [line 37]\n _fun_B_B(n$2:E*) [line 37]\n " shape="box"] "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_5" -> "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_4" ; -"~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_1" [label="1: Start E_~E\nFormals: this:E*\nLocals: \n DECLARE_LOCALS(&return); [line 33]\n " color=yellow style=filled] +"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_6" [label="6: Constructor Init \n n$3=*&this:E* [line 37]\n _fun_A_A(n$3:E*) [line 37]\n " shape="box"] + + + "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_6" -> "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_5" ; +"E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_7" [label="7: Constructor Init \n n$4=*&this:E* [line 37]\n _fun_T_T(n$4:E*) [line 37]\n " shape="box"] + + + "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_7" -> "E#E#{_ZN1EC1Ev}.8eb6f0809ed40dd2a68db058b9bc4ade_6" ; +"__infer_inner_destructor_~E#E#(_ZN1ED0Ev).1cd2fde06f46ea9404c8354ab5ffff71_1" [label="1: Start E___infer_inner_destructor_~E\nFormals: this:E*\nLocals: \n DECLARE_LOCALS(&return); [line 38]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~E#E#(_ZN1ED0Ev).1cd2fde06f46ea9404c8354ab5ffff71_1" -> "__infer_inner_destructor_~E#E#(_ZN1ED0Ev).1cd2fde06f46ea9404c8354ab5ffff71_3" ; +"__infer_inner_destructor_~E#E#(_ZN1ED0Ev).1cd2fde06f46ea9404c8354ab5ffff71_2" [label="2: Exit E___infer_inner_destructor_~E \n " color=yellow style=filled] + + +"__infer_inner_destructor_~E#E#(_ZN1ED0Ev).1cd2fde06f46ea9404c8354ab5ffff71_3" [label="3: Destruction \n n$0=*&this:E* [line 38]\n _=*n$0:E [line 38]\n _fun_D___infer_inner_destructor_~D(n$0:E*) [line 38]\n _=*n$0:E [line 38]\n _fun_C___infer_inner_destructor_~C(n$0:E*) [line 38]\n _=*n$0:E [line 38]\n _fun_B___infer_inner_destructor_~B(n$0:E*) [line 38]\n " shape="box"] + + + "__infer_inner_destructor_~E#E#(_ZN1ED0Ev).1cd2fde06f46ea9404c8354ab5ffff71_3" -> "__infer_inner_destructor_~E#E#(_ZN1ED0Ev).1cd2fde06f46ea9404c8354ab5ffff71_2" ; +"~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_1" [label="1: Start E_~E\nFormals: this:E*\nLocals: \n DECLARE_LOCALS(&return); [line 38]\n " color=yellow style=filled] "~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_1" -> "~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_3" ; "~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_2" [label="2: Exit E_~E \n " color=yellow style=filled] -"~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_3" [label="3: Destruction \n n$0=*&this:E* [line 33]\n _=*n$0:E [line 33]\n _fun_D_~D(n$0:E*) [line 33]\n _=*n$0:E [line 33]\n _fun_C_~C(n$0:E*) [line 33]\n _=*n$0:E [line 33]\n _fun_B_~B(n$0:E*) [line 33]\n " shape="box"] +"~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_3" [label="3: Destruction \n n$0=*&this:E* [line 38]\n _=*n$0:E [line 38]\n _fun_E___infer_inner_destructor_~E(n$0:E*) [line 38]\n _=*n$0:E [line 38]\n _fun_A___infer_inner_destructor_~A(n$0:E*) [line 38]\n _=*n$0:E [line 38]\n _fun_T___infer_inner_destructor_~T(n$0:E*) [line 38]\n " shape="box"] "~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_3" -> "~E#E#(_ZN1ED0Ev).44fb1076af1709dabd7a40484ef7ca13_2" ; +"F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_1" [label="1: Start F_F\nFormals: this:F*\nLocals: \n DECLARE_LOCALS(&return); [line 42]\n " color=yellow style=filled] + + + "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_1" -> "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_7" ; +"F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_2" [label="2: Exit F_F \n " color=yellow style=filled] + + +"F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_3" [label="3: Constructor Init \n n$0=*&this:F* [line 42]\n _fun_D_D(n$0:F*) [line 42]\n " shape="box"] + + + "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_3" -> "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_2" ; +"F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_4" [label="4: Constructor Init \n n$1=*&this:F* [line 42]\n _fun_B_B(n$1:F*) [line 42]\n " shape="box"] + + + "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_4" -> "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_3" ; +"F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_5" [label="5: Constructor Init \n n$2=*&this:F* [line 42]\n _fun_C_C(n$2:F*) [line 42]\n " shape="box"] + + + "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_5" -> "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_4" ; +"F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_6" [label="6: Constructor Init \n n$3=*&this:F* [line 42]\n _fun_A_A(n$3:F*) [line 42]\n " shape="box"] + + + "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_6" -> "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_5" ; +"F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_7" [label="7: Constructor Init \n n$4=*&this:F* [line 42]\n _fun_T_T(n$4:F*) [line 42]\n " shape="box"] + + + "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_7" -> "F#F#{_ZN1FC1Ev}.02883af06694002d810188a2463493b7_6" ; +"__infer_inner_destructor_~F#F#(_ZN1FD0Ev).5a82575ee7db3a505ae3cb2a1a80ad66_1" [label="1: Start F___infer_inner_destructor_~F\nFormals: this:F*\nLocals: \n DECLARE_LOCALS(&return); [line 43]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~F#F#(_ZN1FD0Ev).5a82575ee7db3a505ae3cb2a1a80ad66_1" -> "__infer_inner_destructor_~F#F#(_ZN1FD0Ev).5a82575ee7db3a505ae3cb2a1a80ad66_3" ; +"__infer_inner_destructor_~F#F#(_ZN1FD0Ev).5a82575ee7db3a505ae3cb2a1a80ad66_2" [label="2: Exit F___infer_inner_destructor_~F \n " color=yellow style=filled] + + +"__infer_inner_destructor_~F#F#(_ZN1FD0Ev).5a82575ee7db3a505ae3cb2a1a80ad66_3" [label="3: Destruction \n n$0=*&this:F* [line 43]\n _=*n$0:F [line 43]\n _fun_D___infer_inner_destructor_~D(n$0:F*) [line 43]\n _=*n$0:F [line 43]\n _fun_B___infer_inner_destructor_~B(n$0:F*) [line 43]\n " shape="box"] + + + "__infer_inner_destructor_~F#F#(_ZN1FD0Ev).5a82575ee7db3a505ae3cb2a1a80ad66_3" -> "__infer_inner_destructor_~F#F#(_ZN1FD0Ev).5a82575ee7db3a505ae3cb2a1a80ad66_2" ; +"~F#F#(_ZN1FD0Ev).c4e45094cdc89c1a6c4112ae45286ef9_1" [label="1: Start F_~F\nFormals: this:F*\nLocals: \n DECLARE_LOCALS(&return); [line 43]\n " color=yellow style=filled] + + + "~F#F#(_ZN1FD0Ev).c4e45094cdc89c1a6c4112ae45286ef9_1" -> "~F#F#(_ZN1FD0Ev).c4e45094cdc89c1a6c4112ae45286ef9_3" ; +"~F#F#(_ZN1FD0Ev).c4e45094cdc89c1a6c4112ae45286ef9_2" [label="2: Exit F_~F \n " color=yellow style=filled] + + +"~F#F#(_ZN1FD0Ev).c4e45094cdc89c1a6c4112ae45286ef9_3" [label="3: Destruction \n n$0=*&this:F* [line 43]\n _=*n$0:F [line 43]\n _fun_F___infer_inner_destructor_~F(n$0:F*) [line 43]\n _=*n$0:F [line 43]\n _fun_C___infer_inner_destructor_~C(n$0:F*) [line 43]\n _=*n$0:F [line 43]\n _fun_A___infer_inner_destructor_~A(n$0:F*) [line 43]\n _=*n$0:F [line 43]\n _fun_T___infer_inner_destructor_~T(n$0:F*) [line 43]\n " shape="box"] + + + "~F#F#(_ZN1FD0Ev).c4e45094cdc89c1a6c4112ae45286ef9_3" -> "~F#F#(_ZN1FD0Ev).c4e45094cdc89c1a6c4112ae45286ef9_2" ; +"T#T#{_ZN1TC1Ev}.e96b2e7fa5f7843a391c757eaa263383_1" [label="1: Start T_T\nFormals: this:T*\nLocals: \n DECLARE_LOCALS(&return); [line 11]\n " color=yellow style=filled] + + + "T#T#{_ZN1TC1Ev}.e96b2e7fa5f7843a391c757eaa263383_1" -> "T#T#{_ZN1TC1Ev}.e96b2e7fa5f7843a391c757eaa263383_2" ; +"T#T#{_ZN1TC1Ev}.e96b2e7fa5f7843a391c757eaa263383_2" [label="2: Exit T_T \n " color=yellow style=filled] + + +"__infer_inner_destructor_~T#T#(_ZN1TD0Ev).389742d463c8e82b53ba61267847ccd1_1" [label="1: Start T___infer_inner_destructor_~T\nFormals: this:T*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~T#T#(_ZN1TD0Ev).389742d463c8e82b53ba61267847ccd1_1" -> "__infer_inner_destructor_~T#T#(_ZN1TD0Ev).389742d463c8e82b53ba61267847ccd1_2" ; +"__infer_inner_destructor_~T#T#(_ZN1TD0Ev).389742d463c8e82b53ba61267847ccd1_2" [label="2: Exit T___infer_inner_destructor_~T \n " color=yellow style=filled] + + +"~T#T#(_ZN1TD0Ev).64090d9695f68bd8a9808c8833d7a0d1_1" [label="1: Start T_~T\nFormals: this:T*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] + + + "~T#T#(_ZN1TD0Ev).64090d9695f68bd8a9808c8833d7a0d1_1" -> "~T#T#(_ZN1TD0Ev).64090d9695f68bd8a9808c8833d7a0d1_3" ; +"~T#T#(_ZN1TD0Ev).64090d9695f68bd8a9808c8833d7a0d1_2" [label="2: Exit T_~T \n " color=yellow style=filled] + + +"~T#T#(_ZN1TD0Ev).64090d9695f68bd8a9808c8833d7a0d1_3" [label="3: Destruction \n n$0=*&this:T* [line 12]\n _=*n$0:T [line 12]\n _fun_T___infer_inner_destructor_~T(n$0:T*) [line 12]\n " shape="box"] + + + "~T#T#(_ZN1TD0Ev).64090d9695f68bd8a9808c8833d7a0d1_3" -> "~T#T#(_ZN1TD0Ev).64090d9695f68bd8a9808c8833d7a0d1_2" ; } diff --git a/infer/tests/codetoanalyze/cpp/frontend/destructors/scope.cpp.dot b/infer/tests/codetoanalyze/cpp/frontend/destructors/scope.cpp.dot index d1b1c58d8..1812ed5f9 100644 --- a/infer/tests/codetoanalyze/cpp/frontend/destructors/scope.cpp.dot +++ b/infer/tests/codetoanalyze/cpp/frontend/destructors/scope.cpp.dot @@ -181,6 +181,17 @@ digraph iCFG { "S#S#destructor_scope#{_ZN16destructor_scope1SC1Ev|constexpr}.8a90c7de74a36914310ae757d91d91ff_3" -> "S#S#destructor_scope#{_ZN16destructor_scope1SC1Ev|constexpr}.8a90c7de74a36914310ae757d91d91ff_2" ; +"__infer_inner_destructor_~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).c9c88a7d09356d579c04681847b139d2_1" [label="1: Start destructor_scope::S___infer_inner_destructor_~S\nFormals: this:destructor_scope::S*\nLocals: \n DECLARE_LOCALS(&return); [line 21]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).c9c88a7d09356d579c04681847b139d2_1" -> "__infer_inner_destructor_~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).c9c88a7d09356d579c04681847b139d2_3" ; +"__infer_inner_destructor_~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).c9c88a7d09356d579c04681847b139d2_2" [label="2: Exit destructor_scope::S___infer_inner_destructor_~S \n " color=yellow style=filled] + + +"__infer_inner_destructor_~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).c9c88a7d09356d579c04681847b139d2_3" [label="3: Destruction \n n$0=*&this:destructor_scope::S* [line 21]\n _=*n$0.x1:destructor_scope::X [line 21]\n _fun_destructor_scope::X_~X(n$0.x1:destructor_scope::X*) [line 21]\n " shape="box"] + + + "__infer_inner_destructor_~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).c9c88a7d09356d579c04681847b139d2_3" -> "__infer_inner_destructor_~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).c9c88a7d09356d579c04681847b139d2_2" ; "~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).e029a1be84e1c759d19e67b6cee10d7f_1" [label="1: Start destructor_scope::S_~S\nFormals: this:destructor_scope::S*\nLocals: \n DECLARE_LOCALS(&return); [line 21]\n " color=yellow style=filled] @@ -188,50 +199,61 @@ digraph iCFG { "~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).e029a1be84e1c759d19e67b6cee10d7f_2" [label="2: Exit destructor_scope::S_~S \n " color=yellow style=filled] -"~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).e029a1be84e1c759d19e67b6cee10d7f_3" [label="3: Destruction \n n$0=*&this:destructor_scope::S* [line 21]\n _=*n$0.x1:destructor_scope::X [line 21]\n _fun_destructor_scope::X_~X(n$0.x1:destructor_scope::X*) [line 21]\n " shape="box"] +"~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).e029a1be84e1c759d19e67b6cee10d7f_3" [label="3: Destruction \n n$0=*&this:destructor_scope::S* [line 21]\n _=*n$0:destructor_scope::S [line 21]\n _fun_destructor_scope::S___infer_inner_destructor_~S(n$0:destructor_scope::S*) [line 21]\n " shape="box"] "~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).e029a1be84e1c759d19e67b6cee10d7f_3" -> "~S#S#destructor_scope#(_ZN16destructor_scope1SD0Ev).e029a1be84e1c759d19e67b6cee10d7f_2" ; -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_1" [label="1: Start destructor_scope::W_~W\nFormals: this:destructor_scope::W*\nLocals: y:destructor_scope::Y x:destructor_scope::X \n DECLARE_LOCALS(&return,&y,&x); [line 31]\n " color=yellow style=filled] +"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_1" [label="1: Start destructor_scope::W_~W\nFormals: this:destructor_scope::W*\nLocals: \n DECLARE_LOCALS(&return); [line 31]\n " color=yellow style=filled] - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_1" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_10" ; + "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_1" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_3" ; "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_2" [label="2: Exit destructor_scope::W_~W \n " color=yellow style=filled] -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_3" [label="3: Destruction \n n$0=*&this:destructor_scope::W* [line 36]\n _=*n$0.s:destructor_scope::S [line 36]\n _fun_destructor_scope::S_~S(n$0.s:destructor_scope::S*) [line 36]\n _=*n$0.y:destructor_scope::Y [line 36]\n _fun_destructor_scope::Y_~Y(n$0.y:destructor_scope::Y*) [line 36]\n _=*n$0.x:destructor_scope::X [line 36]\n _fun_destructor_scope::X_~X(n$0.x:destructor_scope::X*) [line 36]\n " shape="box"] +"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_3" [label="3: Destruction \n n$0=*&this:destructor_scope::W* [line 36]\n _=*n$0:destructor_scope::W [line 36]\n _fun_destructor_scope::W___infer_inner_destructor_~W(n$0:destructor_scope::W*) [line 36]\n " shape="box"] "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_3" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_2" ; -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_4" [label="4: Destruction \n _=*&y:destructor_scope::Y [line 36]\n _fun_destructor_scope::Y_~Y(&y:destructor_scope::Y*) [line 36]\n _=*&x:destructor_scope::X [line 36]\n _fun_destructor_scope::X_~X(&x:destructor_scope::X*) [line 36]\n " shape="box"] +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_1" [label="1: Start destructor_scope::W___infer_inner_destructor_~W\nFormals: this:destructor_scope::W*\nLocals: y:destructor_scope::Y x:destructor_scope::X \n DECLARE_LOCALS(&return,&y,&x); [line 31]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_1" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_10" ; +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_2" [label="2: Exit destructor_scope::W___infer_inner_destructor_~W \n " color=yellow style=filled] + + +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_3" [label="3: Destruction \n n$0=*&this:destructor_scope::W* [line 36]\n _=*n$0.s:destructor_scope::S [line 36]\n _fun_destructor_scope::S_~S(n$0.s:destructor_scope::S*) [line 36]\n _=*n$0.y:destructor_scope::Y [line 36]\n _fun_destructor_scope::Y_~Y(n$0.y:destructor_scope::Y*) [line 36]\n _=*n$0.x:destructor_scope::X [line 36]\n _fun_destructor_scope::X_~X(n$0.x:destructor_scope::X*) [line 36]\n " shape="box"] + + + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_3" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_2" ; +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_4" [label="4: Destruction \n _=*&y:destructor_scope::Y [line 36]\n _fun_destructor_scope::Y_~Y(&y:destructor_scope::Y*) [line 36]\n _=*&x:destructor_scope::X [line 36]\n _fun_destructor_scope::X_~X(&x:destructor_scope::X*) [line 36]\n " shape="box"] - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_4" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_3" ; -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_5" [label="5: DeclStmt \n _fun_destructor_scope::Y_Y(&y:destructor_scope::Y*) [line 35]\n " shape="box"] + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_4" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_3" ; +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_5" [label="5: DeclStmt \n _fun_destructor_scope::Y_Y(&y:destructor_scope::Y*) [line 35]\n " shape="box"] - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_5" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_4" ; -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_6" [label="6: + \n " ] + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_5" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_4" ; +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_6" [label="6: + \n " ] - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_6" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_5" ; -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_7" [label="7: Prune (true branch) \n n$6=*&this:destructor_scope::W* [line 33]\n n$7=*n$6.b:_Bool [line 33]\n PRUNE((n$7 != 0), true); [line 33]\n " shape="invhouse"] + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_6" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_5" ; +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_7" [label="7: Prune (true branch) \n n$6=*&this:destructor_scope::W* [line 33]\n n$7=*n$6.b:_Bool [line 33]\n PRUNE((n$7 != 0), true); [line 33]\n " shape="invhouse"] - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_7" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_9" ; -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_8" [label="8: Prune (false branch) \n n$6=*&this:destructor_scope::W* [line 33]\n n$7=*n$6.b:_Bool [line 33]\n PRUNE((n$7 == 0), false); [line 33]\n " shape="invhouse"] + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_7" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_9" ; +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_8" [label="8: Prune (false branch) \n n$6=*&this:destructor_scope::W* [line 33]\n n$7=*n$6.b:_Bool [line 33]\n PRUNE((n$7 == 0), false); [line 33]\n " shape="invhouse"] - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_8" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_6" ; -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_9" [label="9: Return Stmt \n _=*&x:destructor_scope::X [line 34]\n _fun_destructor_scope::X_~X(&x:destructor_scope::X*) [line 34]\n n$9=*&this:destructor_scope::W* [line 34]\n _=*n$9.s:destructor_scope::S [line 34]\n _fun_destructor_scope::S_~S(n$9.s:destructor_scope::S*) [line 34]\n _=*n$9.y:destructor_scope::Y [line 34]\n _fun_destructor_scope::Y_~Y(n$9.y:destructor_scope::Y*) [line 34]\n _=*n$9.x:destructor_scope::X [line 34]\n _fun_destructor_scope::X_~X(n$9.x:destructor_scope::X*) [line 34]\n " shape="box"] + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_8" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_6" ; +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_9" [label="9: Return Stmt \n _=*&x:destructor_scope::X [line 34]\n _fun_destructor_scope::X_~X(&x:destructor_scope::X*) [line 34]\n n$9=*&this:destructor_scope::W* [line 34]\n _=*n$9.s:destructor_scope::S [line 34]\n _fun_destructor_scope::S_~S(n$9.s:destructor_scope::S*) [line 34]\n _=*n$9.y:destructor_scope::Y [line 34]\n _fun_destructor_scope::Y_~Y(n$9.y:destructor_scope::Y*) [line 34]\n _=*n$9.x:destructor_scope::X [line 34]\n _fun_destructor_scope::X_~X(n$9.x:destructor_scope::X*) [line 34]\n " shape="box"] - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_9" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_2" ; -"~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_10" [label="10: DeclStmt \n _fun_destructor_scope::X_X(&x:destructor_scope::X*) [line 32]\n " shape="box"] + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_9" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_2" ; +"__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_10" [label="10: DeclStmt \n _fun_destructor_scope::X_X(&x:destructor_scope::X*) [line 32]\n " shape="box"] - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_10" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_7" ; - "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_10" -> "~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).9885401ab9f4b0bdd64fdcd63dd6accc_8" ; + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_10" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_7" ; + "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_10" -> "__infer_inner_destructor_~W#W#destructor_scope#(_ZN16destructor_scope1WD0Ev).37a82ed518652a47d87bdadb9b9382b3_8" ; "X#X#destructor_scope#{_ZN16destructor_scope1XC1Ev|constexpr}.2fe4286cdaf024592bc7b4ad8b4a565f_1" [label="1: Start destructor_scope::X_X\nFormals: this:destructor_scope::X*\nLocals: \n DECLARE_LOCALS(&return); [line 11]\n " color=yellow style=filled] @@ -239,13 +261,24 @@ digraph iCFG { "X#X#destructor_scope#{_ZN16destructor_scope1XC1Ev|constexpr}.2fe4286cdaf024592bc7b4ad8b4a565f_2" [label="2: Exit destructor_scope::X_X \n " color=yellow style=filled] +"__infer_inner_destructor_~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).e34b7d35c667e9a0c249014ae7750d5b_1" [label="1: Start destructor_scope::X___infer_inner_destructor_~X\nFormals: this:destructor_scope::X*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).e34b7d35c667e9a0c249014ae7750d5b_1" -> "__infer_inner_destructor_~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).e34b7d35c667e9a0c249014ae7750d5b_2" ; +"__infer_inner_destructor_~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).e34b7d35c667e9a0c249014ae7750d5b_2" [label="2: Exit destructor_scope::X___infer_inner_destructor_~X \n " color=yellow style=filled] + + "~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_1" [label="1: Start destructor_scope::X_~X\nFormals: this:destructor_scope::X*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] - "~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_1" -> "~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_2" ; + "~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_1" -> "~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_3" ; "~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_2" [label="2: Exit destructor_scope::X_~X \n " color=yellow style=filled] +"~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_3" [label="3: Destruction \n n$0=*&this:destructor_scope::X* [line 12]\n _=*n$0:destructor_scope::X [line 12]\n _fun_destructor_scope::X___infer_inner_destructor_~X(n$0:destructor_scope::X*) [line 12]\n " shape="box"] + + + "~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_3" -> "~X#X#destructor_scope#(_ZN16destructor_scope1XD0Ev).f18f0761b16fe36438c4eae7e576b682_2" ; "X#X#destructor_scope#{_ZN16destructor_scope1XC1ERKS0_|constexpr}.2414d8fbaa297d1fce05355d53896b6b_1" [label="1: Start destructor_scope::X_X\nFormals: this:destructor_scope::X* __param_0:destructor_scope::X const &\nLocals: \n DECLARE_LOCALS(&return); [line 11]\n " color=yellow style=filled] @@ -260,13 +293,24 @@ digraph iCFG { "Y#Y#destructor_scope#{_ZN16destructor_scope1YC1Ev|constexpr}.bbec2666e178558d30786fd357bae394_2" [label="2: Exit destructor_scope::Y_Y \n " color=yellow style=filled] +"__infer_inner_destructor_~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).71e5f497c4eb72b48471526acc7e1690_1" [label="1: Start destructor_scope::Y___infer_inner_destructor_~Y\nFormals: this:destructor_scope::Y*\nLocals: \n DECLARE_LOCALS(&return); [line 16]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).71e5f497c4eb72b48471526acc7e1690_1" -> "__infer_inner_destructor_~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).71e5f497c4eb72b48471526acc7e1690_2" ; +"__infer_inner_destructor_~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).71e5f497c4eb72b48471526acc7e1690_2" [label="2: Exit destructor_scope::Y___infer_inner_destructor_~Y \n " color=yellow style=filled] + + "~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_1" [label="1: Start destructor_scope::Y_~Y\nFormals: this:destructor_scope::Y*\nLocals: \n DECLARE_LOCALS(&return); [line 16]\n " color=yellow style=filled] - "~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_1" -> "~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_2" ; + "~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_1" -> "~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_3" ; "~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_2" [label="2: Exit destructor_scope::Y_~Y \n " color=yellow style=filled] +"~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_3" [label="3: Destruction \n n$0=*&this:destructor_scope::Y* [line 16]\n _=*n$0:destructor_scope::Y [line 16]\n _fun_destructor_scope::Y___infer_inner_destructor_~Y(n$0:destructor_scope::Y*) [line 16]\n " shape="box"] + + + "~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_3" -> "~Y#Y#destructor_scope#(_ZN16destructor_scope1YD0Ev).c1e3be6c11bac066871bac643c1a7d33_2" ; "Z#Z#destructor_scope#{_ZN16destructor_scope1ZC1Ev|constexpr}.58846154fa4db51b4cb4a6dc634794d7_1" [label="1: Start destructor_scope::Z_Z\nFormals: this:destructor_scope::Z*\nLocals: \n DECLARE_LOCALS(&return); [line 19]\n " color=yellow style=filled] diff --git a/infer/tests/codetoanalyze/cpp/frontend/destructors/simple_decl.cpp.dot b/infer/tests/codetoanalyze/cpp/frontend/destructors/simple_decl.cpp.dot index 8045434ee..bbc16081f 100644 --- a/infer/tests/codetoanalyze/cpp/frontend/destructors/simple_decl.cpp.dot +++ b/infer/tests/codetoanalyze/cpp/frontend/destructors/simple_decl.cpp.dot @@ -1,5 +1,16 @@ /* @generated */ digraph iCFG { +"__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_1" [label="1: Start A___infer_inner_destructor_~A\nFormals: this:A*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_1" -> "__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_3" ; +"__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_2" [label="2: Exit A___infer_inner_destructor_~A \n " color=yellow style=filled] + + +"__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_3" [label="3: BinaryOperatorStmt: Assign \n n$1=*&this:A* [line 12]\n *n$1.f:int=0 [line 12]\n " shape="box"] + + + "__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_3" -> "__infer_inner_destructor_~A#A#(_ZN1AD0Ev).d7916f7ac2ccc90a14007799f4bf9d5a_2" ; "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_1" [label="1: Start A_~A\nFormals: this:A*\nLocals: \n DECLARE_LOCALS(&return); [line 12]\n " color=yellow style=filled] @@ -7,10 +18,21 @@ digraph iCFG { "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_2" [label="2: Exit A_~A \n " color=yellow style=filled] -"~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_3" [label="3: BinaryOperatorStmt: Assign \n n$1=*&this:A* [line 12]\n *n$1.f:int=0 [line 12]\n " shape="box"] +"~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_3" [label="3: Destruction \n n$0=*&this:A* [line 12]\n _=*n$0:A [line 12]\n _fun_A___infer_inner_destructor_~A(n$0:A*) [line 12]\n " shape="box"] "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_3" -> "~A#A#(_ZN1AD0Ev).56ee06aef571dbbd330acc7aac738fb2_2" ; +"__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_1" [label="1: Start B___infer_inner_destructor_~B\nFormals: this:B*\nLocals: \n DECLARE_LOCALS(&return); [line 20]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_1" -> "__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_3" ; +"__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_2" [label="2: Exit B___infer_inner_destructor_~B \n " color=yellow style=filled] + + +"__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_3" [label="3: BinaryOperatorStmt: Assign \n n$1=*&this:B* [line 20]\n *n$1.f:int=1 [line 20]\n " shape="box"] + + + "__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_3" -> "__infer_inner_destructor_~B#B#(_ZN1BD0Ev).7405d4358f39a25c16cc2f7f705f5618_2" ; "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_1" [label="1: Start B_~B\nFormals: this:B*\nLocals: \n DECLARE_LOCALS(&return); [line 20]\n " color=yellow style=filled] @@ -18,7 +40,7 @@ digraph iCFG { "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_2" [label="2: Exit B_~B \n " color=yellow style=filled] -"~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_3" [label="3: BinaryOperatorStmt: Assign \n n$1=*&this:B* [line 20]\n *n$1.f:int=1 [line 20]\n " shape="box"] +"~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_3" [label="3: Destruction \n n$0=*&this:B* [line 20]\n _=*n$0:B [line 20]\n _fun_B___infer_inner_destructor_~B(n$0:B*) [line 20]\n " shape="box"] "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_3" -> "~B#B#(_ZN1BD0Ev).cd4fb9d54ed1b3496d9539c455e8ee1d_2" ; diff --git a/infer/tests/codetoanalyze/cpp/shared/methods/virtual_methods.cpp.dot b/infer/tests/codetoanalyze/cpp/shared/methods/virtual_methods.cpp.dot index 78e45e4bc..f871bad82 100644 --- a/infer/tests/codetoanalyze/cpp/shared/methods/virtual_methods.cpp.dot +++ b/infer/tests/codetoanalyze/cpp/shared/methods/virtual_methods.cpp.dot @@ -192,11 +192,22 @@ digraph iCFG { "Triangle#Triangle#{_ZN8TriangleC1Ev}.aa76cc2cdb1a882a316a78e630da4121_3" -> "Triangle#Triangle#{_ZN8TriangleC1Ev}.aa76cc2cdb1a882a316a78e630da4121_2" ; +"__infer_inner_destructor_~Triangle#Triangle#(_ZN7PolygonD0Ev).abcb70e3d6c186e1ac7b4a0bc961e227_1" [label="1: Start Triangle___infer_inner_destructor_~Triangle\nFormals: this:Triangle*\nLocals: \n DECLARE_LOCALS(&return); [line 31]\n " color=yellow style=filled] + + + "__infer_inner_destructor_~Triangle#Triangle#(_ZN7PolygonD0Ev).abcb70e3d6c186e1ac7b4a0bc961e227_1" -> "__infer_inner_destructor_~Triangle#Triangle#(_ZN7PolygonD0Ev).abcb70e3d6c186e1ac7b4a0bc961e227_2" ; +"__infer_inner_destructor_~Triangle#Triangle#(_ZN7PolygonD0Ev).abcb70e3d6c186e1ac7b4a0bc961e227_2" [label="2: Exit Triangle___infer_inner_destructor_~Triangle \n " color=yellow style=filled] + + "~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_1" [label="1: Start Triangle_~Triangle\nFormals: this:Triangle*\nLocals: \n DECLARE_LOCALS(&return); [line 31]\n " color=yellow style=filled] - "~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_1" -> "~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_2" ; + "~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_1" -> "~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_3" ; "~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_2" [label="2: Exit Triangle_~Triangle \n " color=yellow style=filled] +"~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_3" [label="3: Destruction \n n$0=*&this:Triangle* [line 31]\n _=*n$0:Triangle [line 31]\n _fun_Triangle___infer_inner_destructor_~Triangle(n$0:Triangle*) virtual [line 31]\n " shape="box"] + + + "~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_3" -> "~Triangle#Triangle#(_ZN7PolygonD0Ev).a5b74549c8daf4ed9f14d2f3048b49ad_2" ; }