|
|
@ -211,7 +211,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s
|
|
|
|
let procdesc = context.CContext.procdesc in
|
|
|
|
let procdesc = context.CContext.procdesc in
|
|
|
|
let pvar, typ = mk_temp_sil_var_for_expr context.CContext.tenv procdesc var_name expr_info in
|
|
|
|
let pvar, typ = mk_temp_sil_var_for_expr context.CContext.tenv procdesc var_name expr_info in
|
|
|
|
let var_data =
|
|
|
|
let var_data =
|
|
|
|
ProcAttributes.{name= Pvar.get_name pvar; typ; attributes= []; is_constexpr= false}
|
|
|
|
ProcAttributes.{name= Pvar.get_name pvar; typ; modify_in_block= false; is_constexpr= false}
|
|
|
|
in
|
|
|
|
in
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
(Exp.Lvar pvar, typ)
|
|
|
|
(Exp.Lvar pvar, typ)
|
|
|
@ -248,7 +248,10 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s
|
|
|
|
let procdesc = trans_state.context.CContext.procdesc in
|
|
|
|
let procdesc = trans_state.context.CContext.procdesc in
|
|
|
|
let pvar = mk_temp_sil_var procdesc "__temp_return_" in
|
|
|
|
let pvar = mk_temp_sil_var procdesc "__temp_return_" in
|
|
|
|
let var_data : ProcAttributes.var_data =
|
|
|
|
let var_data : ProcAttributes.var_data =
|
|
|
|
{name= Pvar.get_name pvar; typ= return_type; attributes= []; is_constexpr= false}
|
|
|
|
{ name= Pvar.get_name pvar
|
|
|
|
|
|
|
|
; typ= return_type
|
|
|
|
|
|
|
|
; modify_in_block= false
|
|
|
|
|
|
|
|
; is_constexpr= false }
|
|
|
|
in
|
|
|
|
in
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
Exp.Lvar pvar
|
|
|
|
Exp.Lvar pvar
|
|
|
@ -1138,7 +1141,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s
|
|
|
|
let pvar = Pvar.mk_tmp "__temp_construct_" (Procdesc.get_proc_name procdesc) in
|
|
|
|
let pvar = Pvar.mk_tmp "__temp_construct_" (Procdesc.get_proc_name procdesc) in
|
|
|
|
let class_type = CType_decl.get_type_from_expr_info ei context.CContext.tenv in
|
|
|
|
let class_type = CType_decl.get_type_from_expr_info ei context.CContext.tenv in
|
|
|
|
let var_data : ProcAttributes.var_data =
|
|
|
|
let var_data : ProcAttributes.var_data =
|
|
|
|
{name= Pvar.get_name pvar; typ= class_type; attributes= []; is_constexpr= false}
|
|
|
|
{name= Pvar.get_name pvar; typ= class_type; modify_in_block= false; is_constexpr= false}
|
|
|
|
in
|
|
|
|
in
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
(Exp.Lvar pvar, class_type)
|
|
|
|
(Exp.Lvar pvar, class_type)
|
|
|
@ -1545,7 +1548,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s
|
|
|
|
let pvar = mk_temp_sil_var procdesc "SIL_temp_conditional___" in
|
|
|
|
let pvar = mk_temp_sil_var procdesc "SIL_temp_conditional___" in
|
|
|
|
let var_data =
|
|
|
|
let var_data =
|
|
|
|
ProcAttributes.
|
|
|
|
ProcAttributes.
|
|
|
|
{name= Pvar.get_name pvar; typ= var_typ; attributes= []; is_constexpr= false}
|
|
|
|
{name= Pvar.get_name pvar; typ= var_typ; modify_in_block= false; is_constexpr= false}
|
|
|
|
in
|
|
|
|
in
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
let continuation' = mk_cond_continuation trans_state.continuation in
|
|
|
|
let continuation' = mk_cond_continuation trans_state.continuation in
|
|
|
@ -2909,7 +2912,7 @@ module CTrans_funct (F : CModule_type.CFrontend) : CModule_type.CTranslation = s
|
|
|
|
let res_trans = init_expr_trans trans_state var_exp_typ stmt_info (Some temp_exp) in
|
|
|
|
let res_trans = init_expr_trans trans_state var_exp_typ stmt_info (Some temp_exp) in
|
|
|
|
let _, typ = res_trans.return in
|
|
|
|
let _, typ = res_trans.return in
|
|
|
|
let var_data =
|
|
|
|
let var_data =
|
|
|
|
ProcAttributes.{name= Pvar.get_name pvar; typ; attributes= []; is_constexpr= false}
|
|
|
|
ProcAttributes.{name= Pvar.get_name pvar; typ; modify_in_block= false; is_constexpr= false}
|
|
|
|
in
|
|
|
|
in
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
Procdesc.append_locals procdesc [var_data] ;
|
|
|
|
res_trans
|
|
|
|
res_trans
|
|
|
|