Skip to content

Commit

Permalink
Rollup merge of rust-lang#84987 - lcnr:nits, r=Mark-Simulacrum
Browse files Browse the repository at this point in the history
small nits
  • Loading branch information
Dylan-DPC authored May 6, 2021
2 parents 37ac8c0 + b981141 commit 10e2891
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 8 deletions.
3 changes: 0 additions & 3 deletions compiler/rustc_infer/src/infer/error_reporting/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2398,9 +2398,6 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
self.tcx.associated_item(def_id).ident
),
infer::EarlyBoundRegion(_, name) => format!(" for lifetime parameter `{}`", name),
infer::BoundRegionInCoherence(name) => {
format!(" for lifetime parameter `{}` in coherence check", name)
}
infer::UpvarRegion(ref upvar_id, _) => {
let var_name = self.tcx.hir().name(upvar_id.var_path.hir_id);
format!(" for capture of `{}` by closure", var_name)
Expand Down
3 changes: 0 additions & 3 deletions compiler/rustc_infer/src/infer/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -453,8 +453,6 @@ pub enum RegionVariableOrigin {

UpvarRegion(ty::UpvarId, Span),

BoundRegionInCoherence(Symbol),

/// This origin is used for the inference variables that we create
/// during NLL region processing.
Nll(NllRegionVariableOrigin),
Expand Down Expand Up @@ -1749,7 +1747,6 @@ impl RegionVariableOrigin {
| EarlyBoundRegion(a, ..)
| LateBoundRegion(a, ..)
| UpvarRegion(_, a) => a,
BoundRegionInCoherence(_) => rustc_span::DUMMY_SP,
Nll(..) => bug!("NLL variable used with `span`"),
}
}
Expand Down
2 changes: 0 additions & 2 deletions compiler/rustc_trait_selection/src/traits/select/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1044,8 +1044,6 @@ impl<'cx, 'tcx> SelectionContext<'cx, 'tcx> {
}

/// Returns `true` if the global caches can be used.
/// Do note that if the type itself is not in the
/// global tcx, the local caches will be used.
fn can_use_global_caches(&self, param_env: ty::ParamEnv<'tcx>) -> bool {
// If there are any inference variables in the `ParamEnv`, then we
// always use a cache local to this particular scope. Otherwise, we
Expand Down

0 comments on commit 10e2891

Please sign in to comment.