Skip to content

Commit 1acc3a9

Browse files
author
Lukas Markeffsky
committed
compiler: Fix bugs found by rustdoc::unescaped_backtick
1 parent 414d329 commit 1acc3a9

File tree

21 files changed

+24
-24
lines changed

21 files changed

+24
-24
lines changed

compiler/rustc_ast_lowering/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1574,7 +1574,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
15741574
hir::OwnerNode::Item(self.arena.alloc(opaque_ty_item))
15751575
}
15761576

1577-
/// Given a `parent_def_id`, a list of `lifetimes_in_bounds and a `remapping` hash to be
1577+
/// Given a `parent_def_id`, a list of `lifetimes_in_bounds` and a `remapping` hash to be
15781578
/// filled, this function creates new definitions for `Param` and `Fresh` lifetimes, inserts the
15791579
/// new definition, adds it to the remapping with the definition of the given lifetime and
15801580
/// returns a list of lifetimes to be lowered afterwards.

compiler/rustc_borrowck/src/diagnostics/region_errors.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,7 @@ impl<'a, 'tcx> MirBorrowckCtxt<'a, 'tcx> {
363363
/// fn foo<'a, 'b>(x: &'a u32) -> &'b u32 { x }
364364
/// ```
365365
///
366-
/// Here we would be invoked with `fr = 'a` and `outlived_fr = `'b`.
366+
/// Here we would be invoked with `fr = 'a` and `outlived_fr = 'b`.
367367
pub(crate) fn report_region_error(
368368
&mut self,
369369
fr: RegionVid,

compiler/rustc_borrowck/src/region_infer/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -794,7 +794,7 @@ impl<'tcx> RegionInferenceContext<'tcx> {
794794
/// from a universe it can't name; at present, the only way for
795795
/// this to be true is if `scc` outlives `'static`. This is
796796
/// actually stricter than necessary: ideally, we'd support bounds
797-
/// like `for<'a: 'b`>` that might then allow us to approximate
797+
/// like `for<'a: 'b>` that might then allow us to approximate
798798
/// `'a` with `'b` and not `'static`. But it will have to do for
799799
/// now.
800800
fn add_incompatible_universe(&mut self, scc: ConstraintSccIndex) {

compiler/rustc_borrowck/src/region_infer/values.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ pub(crate) struct RegionValues<N: Idx> {
234234
free_regions: SparseBitMatrix<N, RegionVid>,
235235

236236
/// Placeholders represent bound regions -- so something like `'a`
237-
/// in for<'a> fn(&'a u32)`.
237+
/// in `for<'a> fn(&'a u32)`.
238238
placeholders: SparseBitMatrix<N, PlaceholderIndex>,
239239
}
240240

compiler/rustc_hir_typeck/src/closure.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -372,8 +372,8 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
372372
/// ```
373373
///
374374
/// Here:
375-
/// - E would be `fn(&u32) -> &u32`.
376-
/// - S would be `fn(&u32) ->
375+
/// - E would be `fn(&u32) -> &u32`
376+
/// - S would be `fn(&u32) ->`
377377
/// - E' is `&'!0 u32 -> &'!0 u32`
378378
/// - S' is `&'?0 u32 -> ?T`
379379
///

compiler/rustc_incremental/src/assert_module_sources.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
//! the HIR doesn't change as a result of the annotations, which might
1919
//! perturb the reuse results.
2020
//!
21-
//! `#![rustc_expected_cgu_reuse(module="spike", cfg="rpass2", kind="post-lto")]
21+
//! `#![rustc_expected_cgu_reuse(module="spike", cfg="rpass2", kind="post-lto")]`
2222
//! allows for doing a more fine-grained check to see if pre- or post-lto data
2323
//! was re-used.
2424

compiler/rustc_index/src/bit_set.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1870,7 +1870,7 @@ impl<R: Idx, C: Idx> SparseBitMatrix<R, C> {
18701870
}
18711871
}
18721872

1873-
/// Subtracts `set from `row`. `set` can be either `BitSet` or
1873+
/// Subtracts `set` from `row`. `set` can be either `BitSet` or
18741874
/// `HybridBitSet`. Has no effect if `row` does not exist.
18751875
///
18761876
/// Returns true if the row was changed.

compiler/rustc_infer/src/infer/canonical/canonicalizer.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ impl<'tcx> InferCtxt<'tcx> {
5151

5252
/// Like [Self::canonicalize_query], but preserves distinct universes. For
5353
/// example, canonicalizing `&'?0: Trait<'?1>`, where `'?0` is in `U1` and
54-
/// `'?1` is in `U3` would be canonicalized to have ?0` in `U1` and `'?1`
54+
/// `'?1` is in `U3` would be canonicalized to have `?0` in `U1` and `'?1`
5555
/// in `U2`.
5656
///
5757
/// This is used for Chalk integration.

compiler/rustc_infer/src/infer/lexical_region_resolve/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ pub enum RegionResolutionError<'tcx> {
7070
/// `o` requires that `a <= b`, but this does not hold
7171
ConcreteFailure(SubregionOrigin<'tcx>, Region<'tcx>, Region<'tcx>),
7272

73-
/// `GenericBoundFailure(p, s, a)
73+
/// `GenericBoundFailure(p, s, a)`
7474
///
7575
/// The parameter/associated-type `p` must be known to outlive the lifetime
7676
/// `a` (but none of the known bounds are sufficient).

compiler/rustc_infer/src/infer/nll_relate/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ where
5555
///
5656
/// - Covariant means `a <: b`.
5757
/// - Contravariant means `b <: a`.
58-
/// - Invariant means `a == b.
58+
/// - Invariant means `a == b`.
5959
/// - Bivariant means that it doesn't matter.
6060
ambient_variance: ty::Variance,
6161

0 commit comments

Comments
 (0)