diff options
| author | Saleem Jaffer <ssaleem1992@gmail.com> | 2019-05-04 18:06:40 +0530 |
|---|---|---|
| committer | Saleem Jaffer <ssaleem1992@gmail.com> | 2019-05-04 18:06:40 +0530 |
| commit | 80d5478649b5c26846afb1a923c24f8103b887cf (patch) | |
| tree | 4540fbb7f8c7572dc74de877a11726dc6949de4e /src/librustc_codegen_llvm | |
| parent | 94a48924da05d2c3c147ce7739d497fdcf33ca01 (diff) | |
removing param_env from pointee_info_at
Diffstat (limited to 'src/librustc_codegen_llvm')
| -rw-r--r-- | src/librustc_codegen_llvm/abi.rs | 4 | ||||
| -rw-r--r-- | src/librustc_codegen_llvm/context.rs | 6 | ||||
| -rw-r--r-- | src/librustc_codegen_llvm/type_of.rs | 2 |
3 files changed, 7 insertions, 5 deletions
diff --git a/src/librustc_codegen_llvm/abi.rs b/src/librustc_codegen_llvm/abi.rs index 1be07367914..70d184240fc 100644 --- a/src/librustc_codegen_llvm/abi.rs +++ b/src/librustc_codegen_llvm/abi.rs @@ -12,7 +12,7 @@ use rustc_target::abi::call::ArgType; use rustc_codegen_ssa::traits::*; use rustc_target::abi::{HasDataLayout, LayoutOf, Size, TyLayout, Abi as LayoutAbi}; -use rustc::ty::{self, Ty, Instance, ParamEnv}; +use rustc::ty::{self, Ty, Instance}; use rustc::ty::layout::{self, PointerKind}; use libc::c_uint; @@ -478,7 +478,7 @@ impl<'tcx> FnTypeExt<'tcx> for FnType<'tcx, Ty<'tcx>> { } } - if let Some(pointee) = layout.pointee_info_at(cx, offset, ParamEnv::reveal_all()) { + if let Some(pointee) = layout.pointee_info_at(cx, offset) { if let Some(kind) = pointee.safe { attrs.pointee_size = pointee.size; attrs.pointee_align = Some(pointee.align); diff --git a/src/librustc_codegen_llvm/context.rs b/src/librustc_codegen_llvm/context.rs index a225a11e94d..7bf8f705ea8 100644 --- a/src/librustc_codegen_llvm/context.rs +++ b/src/librustc_codegen_llvm/context.rs @@ -15,7 +15,9 @@ use rustc_data_structures::small_c_str::SmallCStr; use rustc::mir::mono::Stats; use rustc::session::config::{self, DebugInfo}; use rustc::session::Session; -use rustc::ty::layout::{LayoutError, LayoutOf, PointeeInfo, Size, TyLayout, VariantIdx, HasParamEnv}; +use rustc::ty::layout::{ + LayoutError, LayoutOf, PointeeInfo, Size, TyLayout, VariantIdx, HasParamEnv +}; use rustc::ty::{self, Ty, TyCtxt}; use rustc::util::nodemap::FxHashMap; use rustc_target::spec::{HasTargetSpec, Target}; @@ -864,6 +866,6 @@ impl LayoutOf for CodegenCx<'ll, 'tcx> { impl<'tcx, 'll> HasParamEnv<'tcx> for CodegenCx<'ll, 'tcx> { fn param_env(&self) -> ty::ParamEnv<'tcx> { - panic!("asd") + ty::ParamEnv::reveal_all() } } diff --git a/src/librustc_codegen_llvm/type_of.rs b/src/librustc_codegen_llvm/type_of.rs index 3f717754e32..ff25ed92566 100644 --- a/src/librustc_codegen_llvm/type_of.rs +++ b/src/librustc_codegen_llvm/type_of.rs @@ -383,7 +383,7 @@ impl<'tcx> LayoutLlvmExt<'tcx> for TyLayout<'tcx> { return pointee; } - let result = Ty::pointee_info_at(*self, cx, offset, ty::ParamEnv::reveal_all()); + let result = Ty::pointee_info_at(*self, cx, offset); cx.pointee_infos.borrow_mut().insert((self.ty, offset), result); result |
