Remove redundant secondary declaration of glue.
This commit is contained in:
parent
7e43a31f08
commit
381ba1d0ba
@ -1781,20 +1781,8 @@ fn get_static_tydesc(&@block_ctxt cx,
|
||||
fn declare_tydesc(&@local_ctxt cx, &ast::span sp, &ty::t t,
|
||||
vec[uint] ty_params) -> @tydesc_info {
|
||||
log "+++ declare_tydesc " + ty::ty_to_str(cx.ccx.tcx, t);
|
||||
auto take_glue = declare_generic_glue(cx, t, T_glue_fn(cx.ccx.tn),
|
||||
"take");
|
||||
auto drop_glue = declare_generic_glue(cx, t, T_glue_fn(cx.ccx.tn),
|
||||
"drop");
|
||||
auto free_glue = declare_generic_glue(cx, t, T_glue_fn(cx.ccx.tn),
|
||||
"free");
|
||||
auto cmp_glue = declare_generic_glue(cx, t, T_cmp_glue_fn(cx.ccx.tn),
|
||||
"cmp");
|
||||
auto ccx = cx.ccx;
|
||||
|
||||
// Don't inline free glue; it's cold.
|
||||
llvm::LLVMAddFunctionAttr(free_glue, lib::llvm::LLVMNoInlineAttribute as
|
||||
lib::llvm::llvm::Attribute);
|
||||
|
||||
auto llsize;
|
||||
auto llalign;
|
||||
if (!ty::type_has_dynamic_size(ccx.tcx, t)) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user