Shrink vtable symbol names a bit

This commit is contained in:
bjorn3 2020-03-13 11:19:31 +01:00
parent 4d226e8f17
commit 98a073cf26

View File

@ -135,7 +135,14 @@ fn build_vtable<'tcx>(
let data_id = fx
.module
.declare_data(
&format!("vtable.{:?}.for.{:?}", trait_ref, layout.ty),
&format!(
"__vtable.{}.for.{:?}",
trait_ref
.as_ref()
.map(|trait_ref| format!("{:?}", trait_ref.skip_binder()).into())
.unwrap_or(std::borrow::Cow::Borrowed("???")),
layout.ty
),
Linkage::Local,
false,
false,