/// minimum values.
///
/// For example:
- ///
- /// fn foo<'a, 'b>(..) where 'a: 'b
- ///
+ /// ```
+ /// fn foo<'a, 'b>( /* ... */ ) where 'a: 'b { /* ... */ }
+ /// ```
/// would initialize two variables like so:
- ///
- /// R0 = { CFG, R0 } // 'a
- /// R1 = { CFG, R0, R1 } // 'b
- ///
+ /// ```ignore (illustrative)
+ /// R0 = { CFG, R0 } // 'a
+ /// R1 = { CFG, R0, R1 } // 'b
+ /// ```
/// Here, R0 represents `'a`, and it contains (a) the entire CFG
/// and (b) any universally quantified regions that it outlives,
/// which in this case is just itself. R1 (`'b`) in contrast also
/// whether any of the constraints were too strong. In particular,
/// we want to check for a case where a universally quantified
/// region exceeded its bounds. Consider:
- ///
- /// fn foo<'a, 'b>(x: &'a u32) -> &'b u32 { x }
- ///
+ /// ```compile_fail,E0312
+ /// fn foo<'a, 'b>(x: &'a u32) -> &'b u32 { x }
+ /// ```
/// In this case, returning `x` requires `&'a u32 <: &'b u32`
/// and hence we establish (transitively) a constraint that
/// `'a: 'b`. The `propagate_constraints` code above will
/// <https://smallcultfollowing.com/babysteps/blog/2019/01/17/polonius-and-region-errors/>
///
/// In the canonical example
- ///
- /// fn foo<'a, 'b>(x: &'a u32) -> &'b u32 { x }
- ///
+ /// ```compile_fail,E0312
+ /// fn foo<'a, 'b>(x: &'a u32) -> &'b u32 { x }
+ /// ```
/// returning `x` requires `&'a u32 <: &'b u32` and hence we establish (transitively) a
/// constraint that `'a: 'b`. It is an error that we have no evidence that this
/// constraint holds.