Skip to content

Commit e6b630c

Browse files
apply suggestions from oli-obk
Co-authored-by: Oli Scherer <[email protected]>
1 parent c9bf88c commit e6b630c

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

compiler/rustc_borrowck/src/region_infer/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1364,7 +1364,7 @@ impl<'tcx> RegionInferenceContext<'tcx> {
13641364

13651365
let result = self.scc_values.contains_points(sup_region_scc, sub_region_scc);
13661366
debug!(
1367-
"eval_outlives: returning {} because of comparison between points in sup/sub",
1367+
"returning {} because of comparison between points in sup/sub",
13681368
result
13691369
);
13701370
result

compiler/rustc_infer/src/infer/outlives/obligations.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ where
318318
self.delegate.push_verify(origin, generic, region, verify_bound);
319319
}
320320

321-
#[tracing::instrument(level = "Debug", skip(self))]
321+
#[tracing::instrument(level = "debug", skip(self))]
322322
fn projection_must_outlive(
323323
&mut self,
324324
origin: infer::SubregionOrigin<'tcx>,
@@ -361,7 +361,7 @@ where
361361
// }` in the trait definition.
362362
approx_env_bounds.retain(|bound_outlives| {
363363
// OK to skip binder because we only manipulate and compare against other
364-
// values from the same inder. e.g. if we have (e.g.) `for<'a> <T as Trait<'a>>::Item: 'a`
364+
// values from the same binder. e.g. if we have (e.g.) `for<'a> <T as Trait<'a>>::Item: 'a`
365365
// in `bound`, the `'a` will be a `^1` (bound, debruijn index == innermost) region.
366366
// If the declaration is `trait Trait<'b> { type Item: 'b; }`, then `projection_declared_bounds_from_trait`
367367
// will be invoked with `['b => ^1]` and so we will get `^1` returned.

compiler/rustc_infer/src/infer/outlives/test_type_match.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ use crate::infer::region_constraints::VerifyIfEq;
3434
/// like are used. This is a particular challenge since this function is invoked
3535
/// very late in inference and hence cannot make use of the normal inference
3636
/// machinery.
37-
#[tracing::instrument(level = "Debug", skip(tcx, param_env))]
37+
#[tracing::instrument(level = "debug", skip(tcx, param_env))]
3838
pub fn extract_verify_if_eq<'tcx>(
3939
tcx: TyCtxt<'tcx>,
4040
param_env: ty::ParamEnv<'tcx>,
@@ -63,7 +63,7 @@ pub fn extract_verify_if_eq<'tcx>(
6363
}
6464

6565
/// True if a (potentially higher-ranked) outlives
66-
#[tracing::instrument(level = "Debug", skip(tcx, param_env))]
66+
#[tracing::instrument(level = "debug", skip(tcx, param_env))]
6767
pub(super) fn can_match_erased_ty<'tcx>(
6868
tcx: TyCtxt<'tcx>,
6969
param_env: ty::ParamEnv<'tcx>,
@@ -102,7 +102,7 @@ impl<'tcx> Match<'tcx> {
102102

103103
/// Binds the pattern variable `br` to `value`; returns an `Err` if the pattern
104104
/// is already bound to a different value.
105-
#[tracing::instrument(level = "Debug", skip(self))]
105+
#[tracing::instrument(level = "debug", skip(self))]
106106
fn bind(
107107
&mut self,
108108
br: ty::BoundRegion,
@@ -167,7 +167,7 @@ impl<'tcx> TypeRelation<'tcx> for Match<'tcx> {
167167
#[instrument(skip(self), level = "debug")]
168168
fn tys(&mut self, pattern: Ty<'tcx>, value: Ty<'tcx>) -> RelateResult<'tcx, Ty<'tcx>> {
169169
if pattern == value {
170-
return Ok(pattern);
170+
Ok(pattern)
171171
} else {
172172
relate::super_relate_tys(self, pattern, value)
173173
}
@@ -181,7 +181,7 @@ impl<'tcx> TypeRelation<'tcx> for Match<'tcx> {
181181
) -> RelateResult<'tcx, ty::Const<'tcx>> {
182182
debug!("{}.consts({:?}, {:?})", self.tag(), pattern, value);
183183
if pattern == value {
184-
return Ok(pattern);
184+
Ok(pattern)
185185
} else {
186186
relate::super_relate_consts(self, pattern, value)
187187
}

0 commit comments

Comments
 (0)