]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_trans/trans/mir/analyze.rs
address nits from dotdash
[rust.git] / src / librustc_trans / trans / mir / analyze.rs
index acf6e53468ef552b666be874a319a8eefac16892..f5fa897bca63122c0b768a6b39819c408f12061e 100644 (file)
@@ -30,7 +30,7 @@ pub fn lvalue_temps<'bcx,'tcx>(bcx: Block<'bcx,'tcx>,
         if
             ty.is_scalar() ||
             ty.is_unique() ||
-            ty.is_region_ptr() ||
+            (ty.is_region_ptr() && !common::type_is_fat_ptr(bcx.tcx(), ty)) ||
             ty.is_simd()
         {
             // These sorts of types are immediates that we can store
@@ -42,7 +42,7 @@ pub fn lvalue_temps<'bcx,'tcx>(bcx: Block<'bcx,'tcx>,
             // for newtypes, but we currently force some types
             // (e.g. structs) into an alloca unconditionally, just so
             // that we don't have to deal with having two pathways
-            // (gep vs getvalue etc).
+            // (gep vs extractvalue etc).
             analyzer.mark_as_lvalue(index);
         }
     }