Remove code that does nothing

master
Andrzej Kotulski 9 years ago
parent 9b8cd7d582
commit 98cb3c84ac

@ -91,16 +91,6 @@ let rec translate_one_declaration tenv cg cfg namespace dec =
| dec ->
Printing.log_stats "\nWARNING: found Declaration %s skipped\n" (Ast_utils.string_of_decl dec)
(** Preprocess declarations to create method signatures of function declarations. *)
let preprocess_one_declaration tenv cg cfg dec =
let info = Clang_ast_proj.get_decl_tuple dec in
CLocation.update_curr_file info;
match dec with
| FunctionDecl(di, name_info, qt, fdecl_info) ->
let name = name_info.Clang_ast_t.ni_name in
ignore (CMethod_declImpl.create_function_signature di fdecl_info name qt false None)
| _ -> ()
(* Translates a file by translating the ast into a cfg. *)
let compute_icfg tenv source_file ast =
match ast with
@ -109,7 +99,6 @@ let compute_icfg tenv source_file ast =
Printing.log_out "\n Start creating icfg\n";
let cg = Cg.create () in
let cfg = Cfg.Node.create_cfg () in
list_iter (preprocess_one_declaration tenv cg cfg) decl_list;
list_iter (translate_one_declaration tenv cg cfg None) decl_list;
Printing.log_out "\n Finished creating icfg\n";
(cg, cfg)

@ -23,9 +23,6 @@ module type CMethod_decl = sig
val function_decl : Sil.tenv -> Cfg.cfg -> Cg.t -> string option -> bool -> Clang_ast_t.decl_info ->
string -> Clang_ast_t.qual_type -> Clang_ast_t.function_decl_info -> (Mangled.t * Sil.typ * bool) list -> Procname.t option -> CContext.curr_class -> unit
val create_function_signature : Clang_ast_t.decl_info -> Clang_ast_t.function_decl_info -> string ->
Clang_ast_t.qual_type -> bool -> Procname.t option -> Clang_ast_t.stmt option * CMethod_signature.method_signature
val process_getter_setter : CContext.t -> Procname.t -> bool
end

@ -16,9 +16,6 @@ module CMethod_decl_funct(T: CModule_type.CTranslation) : sig
val function_decl : Sil.tenv -> Cfg.cfg -> Cg.t -> string option -> bool -> Clang_ast_t.decl_info ->
string -> Clang_ast_t.qual_type -> Clang_ast_t.function_decl_info -> (Mangled.t * Sil.typ * bool) list -> Procname.t option -> CContext.curr_class -> unit
val create_function_signature : Clang_ast_t.decl_info -> Clang_ast_t.function_decl_info -> string ->
Clang_ast_t.qual_type -> bool -> Procname.t option -> Clang_ast_t.stmt option * CMethod_signature.method_signature
val process_getter_setter : CContext.t -> Procname.t -> bool
end
@ -30,8 +27,5 @@ module type CMethod_decl = sig
val function_decl : Sil.tenv -> Cfg.cfg -> Cg.t -> string option -> bool -> Clang_ast_t.decl_info ->
string -> Clang_ast_t.qual_type -> Clang_ast_t.function_decl_info -> (Mangled.t * Sil.typ * bool) list -> Procname.t option -> CContext.curr_class -> unit
val create_function_signature : Clang_ast_t.decl_info -> Clang_ast_t.function_decl_info -> string ->
Clang_ast_t.qual_type -> bool -> Procname.t option -> Clang_ast_t.stmt option * CMethod_signature.method_signature
val process_getter_setter : CContext.t -> Procname.t -> bool
end

Loading…
Cancel
Save