@@ -41,7 +41,7 @@ pub struct OpaqueTypeDecl<'tcx> {
41
41
/// ```
42
42
/// existential type Foo;
43
43
/// fn bar() -> Foo {
44
- /// ^^^ this is the span we are looking for!
44
+ /// ^^^ This is the span we are looking for!
45
45
/// ```
46
46
///
47
47
/// In cases where the fn returns `(impl Trait, impl Trait)` or
@@ -234,13 +234,13 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
234
234
///
235
235
/// # The Solution
236
236
///
237
- /// We generally prefer to make us our `<=` constraints, since
238
- /// they integrate best into the region solve . To do that, we find
239
- /// the "minimum" of all the arguments that appear in the substs:
240
- /// that is, some region which is less than all the others. In the
241
- /// case of `Foo1<'a>`, that would be `'a` (it's the only choice,
242
- /// after all). Then we apply that as a least bound to the
243
- /// variables (e.g., `'a <= '0`).
237
+ /// We generally prefer to make `<=` constraints, since they
238
+ /// integrate best into the region solver . To do that, we find the
239
+ /// "minimum" of all the arguments that appear in the substs: that
240
+ /// is, some region which is less than all the others. In the case
241
+ /// of `Foo1<'a>`, that would be `'a` (it's the only choice, after
242
+ /// all). Then we apply that as a least bound to the variables
243
+ /// (e.g., `'a <= '0`).
244
244
///
245
245
/// In some cases, there is no minimum. Consider this example:
246
246
///
@@ -316,7 +316,7 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
316
316
}
317
317
}
318
318
319
- /// See `constrain_opaque_types` for docs
319
+ /// See `constrain_opaque_types` for documentation.
320
320
pub fn constrain_opaque_type < FRR : FreeRegionRelations < ' tcx > > (
321
321
& self ,
322
322
def_id : DefId ,
@@ -417,7 +417,7 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
417
417
}
418
418
419
419
/// As a fallback, we sometimes generate an "in constraint". For
420
- /// case like `impl Foo<'a, 'b>`, where `'a` and `'b` cannot be
420
+ /// a case like `impl Foo<'a, 'b>`, where `'a` and `'b` cannot be
421
421
/// related, we would generate a constraint `'r in ['a, 'b,
422
422
/// 'static]` for each region `'r` that appears in the hidden type
423
423
/// (i.e., it must be equal to `'a`, `'b`, or `'static`).
0 commit comments