about summary refs log tree commit diff
path: root/src/librustc_codegen_llvm
diff options
context:
space:
mode:
authorkennytm <kennytm@gmail.com>2018-10-18 10:47:21 +0800
committerkennytm <kennytm@gmail.com>2018-10-18 12:54:51 +0800
commit9ee49bbb88c2c7f4e06a14c95da2e0c0b843abd8 (patch)
treef1c4dfbee148aea412f0ed6d32cede9afa268172 /src/librustc_codegen_llvm
parent43ac030d7e6848bf06298153471567525618f955 (diff)
parentb1d3111ba2f4c7d318632c330b4356fec52b4055 (diff)
downloadrust-9ee49bbb88c2c7f4e06a14c95da2e0c0b843abd8.tar.gz
rust-9ee49bbb88c2c7f4e06a14c95da2e0c0b843abd8.zip
Rollup merge of #55016 - oli-obk:vtables💥_vtables_everywhere, r=RalfJung
Deduplicate some code and compile-time values around vtables

r? @RalfJung
Diffstat (limited to 'src/librustc_codegen_llvm')
-rw-r--r--src/librustc_codegen_llvm/meth.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/librustc_codegen_llvm/meth.rs b/src/librustc_codegen_llvm/meth.rs
index db06b87f44e..29c2e71960c 100644
--- a/src/librustc_codegen_llvm/meth.rs
+++ b/src/librustc_codegen_llvm/meth.rs
@@ -94,6 +94,10 @@ pub fn get_vtable(
     });
 
     let (size, align) = cx.size_and_align_of(ty);
+    // /////////////////////////////////////////////////////////////////////////////////////////////
+    // If you touch this code, be sure to also make the corresponding changes to
+    // `get_vtable` in rust_mir/interpret/traits.rs
+    // /////////////////////////////////////////////////////////////////////////////////////////////
     let components: Vec<_> = [
         callee::get_fn(cx, monomorphize::resolve_drop_in_place(cx.tcx, ty)),
         C_usize(cx, size.bytes()),