Module ClangFrontend.CAst_utils
val dummy_source_range : unit -> ATDGenerated.Clang_ast_t.source_range
val dummy_stmt_info : unit -> ATDGenerated.Clang_ast_t.stmt_info
val get_fresh_pointer : unit -> ATDGenerated.Clang_ast_t.pointer
val get_decl : ATDGenerated.Clang_ast_t.pointer -> ATDGenerated.Clang_ast_t.decl option
val get_decl_opt : ATDGenerated.Clang_ast_t.pointer option -> ATDGenerated.Clang_ast_t.decl option
val get_stmt : ATDGenerated.Clang_ast_t.pointer -> ATDGenerated.Clang_ast_t.source_range -> ATDGenerated.Clang_ast_t.stmt option
val get_stmt_exn : ATDGenerated.Clang_ast_t.pointer -> ATDGenerated.Clang_ast_t.source_range -> ATDGenerated.Clang_ast_t.stmt
val get_stmt_opt : ATDGenerated.Clang_ast_t.pointer option -> ATDGenerated.Clang_ast_t.source_range -> ATDGenerated.Clang_ast_t.stmt option
val get_decl_opt_with_decl_ref : ATDGenerated.Clang_ast_t.decl_ref -> ATDGenerated.Clang_ast_t.decl option
val get_decl_opt_with_decl_ref_opt : ATDGenerated.Clang_ast_t.decl_ref option -> ATDGenerated.Clang_ast_t.decl option
val get_property_of_ivar : ATDGenerated.Clang_ast_t.pointer -> ATDGenerated.Clang_ast_t.decl option
val update_sil_types_map : ATDGenerated.Clang_ast_t.type_ptr -> IR.Typ.desc -> unit
val update_enum_map_exn : ATDGenerated.Clang_ast_t.pointer -> IR.Exp.t -> unit
val add_enum_constant : ATDGenerated.Clang_ast_t.pointer -> ATDGenerated.Clang_ast_t.pointer option -> unit
val get_enum_constant_exp_exn : ATDGenerated.Clang_ast_t.pointer -> ATDGenerated.Clang_ast_t.pointer option * IR.Exp.t option
val get_qualified_name : ?linters_mode:bool -> ATDGenerated.Clang_ast_t.named_decl_info -> IR.QualifiedCppName.t
returns sanitized, fully qualified name given name info
val get_unqualified_name : ATDGenerated.Clang_ast_t.named_decl_info -> string
returns sanitized unqualified name given name info
val get_class_name_from_member : ATDGenerated.Clang_ast_t.named_decl_info -> IR.QualifiedCppName.t
returns qualified class name given member name info
val get_type : ATDGenerated.Clang_ast_t.type_ptr -> ATDGenerated.Clang_ast_t.c_type option
looks up clang pointer to type and returns c_type. It requires type_ptr to be `TPtr.
val get_desugared_type : ATDGenerated.Clang_ast_t.type_ptr -> ATDGenerated.Clang_ast_t.c_type option
looks up clang pointer to type and resolves any sugar around it. See get_type for more info and restrictions
val get_decl_from_typ_ptr : ATDGenerated.Clang_ast_t.type_ptr -> ATDGenerated.Clang_ast_t.decl option
returns declaration of the type for certain types (RecordType, ObjCInterfaceType and None for others
val name_of_typedef_type_info : ATDGenerated.Clang_ast_t.typedef_type_info -> IR.QualifiedCppName.t
val name_opt_of_typedef_qual_type : ATDGenerated.Clang_ast_t.qual_type -> IR.QualifiedCppName.t option
type qual_type_to_sil_type
= IR.Tenv.t -> ATDGenerated.Clang_ast_t.qual_type -> IR.Typ.t
type procname_from_decl
= ?tenv:IR.Tenv.t -> ?block_return_type:ATDGenerated.Clang_ast_t.qual_type -> ?outer_proc:IR.Procname.t -> ATDGenerated.Clang_ast_t.decl -> IR.Procname.t
val qual_type_of_decl_ptr : ATDGenerated.Clang_ast_t.pointer -> ATDGenerated.Clang_ast_t.qual_type
val add_type_from_decl_ref_opt : qual_type_to_sil_type -> IR.Tenv.t -> ATDGenerated.Clang_ast_t.decl_ref option -> bool -> unit
val add_type_from_decl_ref_list : qual_type_to_sil_type -> IR.Tenv.t -> ATDGenerated.Clang_ast_t.decl_ref list -> unit
val get_function_decl_with_body : ATDGenerated.Clang_ast_t.pointer -> ATDGenerated.Clang_ast_t.decl option
val get_info_from_decl_ref : ATDGenerated.Clang_ast_t.decl_ref -> ATDGenerated.Clang_ast_t.named_decl_info * ATDGenerated.Clang_ast_t.pointer * ATDGenerated.Clang_ast_t.qual_type
val exists_eventually_st : ('a -> ATDGenerated.Clang_ast_t.stmt -> bool) -> 'a -> ATDGenerated.Clang_ast_t.stmt -> bool
val is_syntactically_global_var : ATDGenerated.Clang_ast_t.decl -> bool
true if a declaration is a global variable
val is_static_local_var : ATDGenerated.Clang_ast_t.decl -> bool
true if a declaration is a static local variable
val is_constexpr_var : ATDGenerated.Clang_ast_t.decl -> bool
true if a declaration is a constexpr variable
val generate_key_stmt : ATDGenerated.Clang_ast_t.stmt -> string
Generates a key for a statement based on its sub-statements and the statement tag.
val generate_key_decl : ATDGenerated.Clang_ast_t.decl -> string
Generates a key for a declaration based on its name and the declaration tag.
val get_super_if : ATDGenerated.Clang_ast_t.decl option -> ATDGenerated.Clang_ast_t.decl option
Given an objc impl or interface decl, returns the objc interface decl of the superclass, if any.
val get_impl_decl_info : ATDGenerated.Clang_ast_t.decl -> ATDGenerated.Clang_ast_t.obj_c_implementation_decl_info option
val get_super_ObjCImplementationDecl : ATDGenerated.Clang_ast_t.obj_c_implementation_decl_info -> ATDGenerated.Clang_ast_t.decl option
Given an objc impl decl info, return its super class implementation decl
val is_objc_if_descendant : ?blacklist:string list -> ATDGenerated.Clang_ast_t.decl option -> string list -> bool
Recursively go up the inheritance hierarchy of a given ObjCInterfaceDecl. Returns true if the passed in decl is an objc interface decl that's an eventual descendant of one of the classes passed in. Ancestors param is a list of strings that represent the class names. Will short-circuit on NSObject and NSProxy since those are known to be common base classes. The list of classes to short-circuit on can be overridden via specifying the named `blacklist` argument.
val qual_type_to_objc_interface : ATDGenerated.Clang_ast_t.qual_type -> ATDGenerated.Clang_ast_t.decl option
val is_objc_factory_method : class_decl:ATDGenerated.Clang_ast_t.decl option -> method_decl:ATDGenerated.Clang_ast_t.decl option -> bool
A class method that returns an instance of the class is a factory method.
val sil_annot_of_type : ATDGenerated.Clang_ast_t.qual_type -> IR.Annot.Item.t
val type_of_decl : ATDGenerated.Clang_ast_t.decl -> ATDGenerated.Clang_ast_t.type_ptr option
val get_record_fields : ATDGenerated.Clang_ast_t.decl -> ATDGenerated.Clang_ast_t.decl list
val get_cxx_base_classes : ATDGenerated.Clang_ast_t.decl -> ATDGenerated.Clang_ast_t.type_ptr list
val get_cxx_virtual_base_classes : ATDGenerated.Clang_ast_t.decl -> ATDGenerated.Clang_ast_t.type_ptr list
val is_std_vector : ATDGenerated.Clang_ast_t.qual_type -> bool
val is_no_escape_block_arg : ATDGenerated.Clang_ast_t.decl -> bool
val has_block_attribute : ATDGenerated.Clang_ast_t.decl -> bool
val is_implicit_decl : ATDGenerated.Clang_ast_t.decl -> bool
val get_superclass_curr_class_objc_from_decl : ATDGenerated.Clang_ast_t.decl -> ATDGenerated.Clang_ast_t.decl_ref option
val get_method_body_opt : ATDGenerated.Clang_ast_t.decl -> ATDGenerated.Clang_ast_t.stmt option