Skip to content

Commit 69072f5

Browse files
committed
Remove unused fields in some structures
The dead_code lint was previously eroneously missing those. Since this lint bug has been fixed, the unused fields need to be removed.
1 parent f1ff461 commit 69072f5

File tree

3 files changed

+2
-15
lines changed

3 files changed

+2
-15
lines changed

compiler/rustc_borrowck/src/region_infer/mod.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2098,7 +2098,6 @@ impl<'tcx> RegionInferenceContext<'tcx> {
20982098
from_closure: constraint.from_closure,
20992099
cause: ObligationCause::new(constraint.span, CRATE_DEF_ID, cause_code.clone()),
21002100
variance_info: constraint.variance_info,
2101-
outlives_constraint: *constraint,
21022101
})
21032102
.collect();
21042103
debug!("categorized_path={:#?}", categorized_path);
@@ -2327,5 +2326,4 @@ pub struct BlameConstraint<'tcx> {
23272326
pub from_closure: bool,
23282327
pub cause: ObligationCause<'tcx>,
23292328
pub variance_info: ty::VarianceDiagInfo<'tcx>,
2330-
pub outlives_constraint: OutlivesConstraint<'tcx>,
23312329
}

compiler/rustc_codegen_llvm/src/context.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,7 @@ use rustc_session::config::{CrateType, DebugInfo, PAuthKey, PacRet};
2727
use rustc_session::Session;
2828
use rustc_span::source_map::Spanned;
2929
use rustc_span::Span;
30-
use rustc_target::abi::{
31-
call::FnAbi, HasDataLayout, PointeeInfo, Size, TargetDataLayout, VariantIdx,
32-
};
30+
use rustc_target::abi::{call::FnAbi, HasDataLayout, TargetDataLayout, VariantIdx};
3331
use rustc_target::spec::{HasTargetSpec, RelocModel, Target, TlsModel};
3432
use smallvec::SmallVec;
3533

@@ -82,7 +80,6 @@ pub struct CodegenCx<'ll, 'tcx> {
8280
/// Mapping of scalar types to llvm types.
8381
pub scalar_lltypes: RefCell<FxHashMap<Ty<'tcx>, &'ll Type>>,
8482

85-
pub pointee_infos: RefCell<FxHashMap<(Ty<'tcx>, Size), Option<PointeeInfo>>>,
8683
pub isize_ty: &'ll Type,
8784

8885
pub coverage_cx: Option<coverageinfo::CrateCoverageContext<'ll, 'tcx>>,
@@ -487,7 +484,6 @@ impl<'ll, 'tcx> CodegenCx<'ll, 'tcx> {
487484
compiler_used_statics: RefCell::new(Vec::new()),
488485
type_lowering: Default::default(),
489486
scalar_lltypes: Default::default(),
490-
pointee_infos: Default::default(),
491487
isize_ty,
492488
coverage_cx,
493489
dbg_cx,

library/test/src/console.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ pub struct ConsoleTestDiscoveryState {
4646
pub tests: usize,
4747
pub benchmarks: usize,
4848
pub ignored: usize,
49-
pub options: Options,
5049
}
5150

5251
impl ConsoleTestDiscoveryState {
@@ -56,13 +55,7 @@ impl ConsoleTestDiscoveryState {
5655
None => None,
5756
};
5857

59-
Ok(ConsoleTestDiscoveryState {
60-
log_out,
61-
tests: 0,
62-
benchmarks: 0,
63-
ignored: 0,
64-
options: opts.options,
65-
})
58+
Ok(ConsoleTestDiscoveryState { log_out, tests: 0, benchmarks: 0, ignored: 0 })
6659
}
6760

6861
pub fn write_log<F, S>(&mut self, msg: F) -> io::Result<()>

0 commit comments

Comments
 (0)