about summary refs log tree commit diff
path: root/src/librustc_trans/adt.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/librustc_trans/adt.rs')
-rw-r--r--src/librustc_trans/adt.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/librustc_trans/adt.rs b/src/librustc_trans/adt.rs
index 634dba3660e..314d929fe8c 100644
--- a/src/librustc_trans/adt.rs
+++ b/src/librustc_trans/adt.rs
@@ -71,7 +71,7 @@ pub fn finish_type_of<'a, 'tcx>(cx: &CrateContext<'a, 'tcx>,
     if let layout::Abi::Scalar(_) = l.abi {
         return;
     }
-    match *l {
+    match *l.layout {
         layout::NullablePointer { .. } |
         layout::General { .. } |
         layout::UntaggedUnion { .. } => { }
@@ -101,7 +101,7 @@ fn generic_type_of<'a, 'tcx>(cx: &CrateContext<'a, 'tcx>,
     if let layout::Abi::Scalar(value) = l.abi {
         return cx.llvm_type_of(value.to_ty(cx.tcx()));
     }
-    match *l {
+    match *l.layout {
         layout::Univariant(ref variant) => {
             match name {
                 None => {