fn compute_region_bound<'tcx>(
    this: &AstConv<'tcx>,
    rscope: &RegionScope,
    span: Span,
    region_bounds: &[&ast::Lifetime],
    principal_trait_ref: Option<ty::PolyTraitRef<'tcx>>, // None for closures
    builtin_bounds: ty::BuiltinBounds)
    -> ty::Region
{
    match compute_opt_region_bound(this.tcx(), span, region_bounds,
                                   principal_trait_ref, builtin_bounds) {
        Some(r) => r,
        None => {
            match rscope.default_region_bound(span) {
                Some(r) => { r }
                None => {
                    this.tcx().sess.span_err(
                        span,
                        &format!("explicit lifetime bound required")[]);
                    ty::ReStatic
                }
            }
        }
    }
}
/// A version of `compute_opt_region_bound` for use where some region bound is required
/// (existential types, basically). Reports an error if no region bound can be derived and we are
/// in an `rscope` that does not provide a default.
A version of `compute_opt_region_bound` for use where some region bound is required
(existential types, basically). Reports an error if no region bound can be derived and we are
in an `rscope` that does not provide a default.
A version of ` compute_opt_region_bound ` for use where some region bound is required ( existential types basically ) . Reports an error if no region bound can be derived and we are in an ` rscope ` that does not provide a default .
fn compute_region_bound<'tcx>(
    this: &AstConv<'tcx>,
    rscope: &RegionScope,
    span: Span,
    region_bounds: &[&ast::Lifetime],
    principal_trait_ref: Option<ty::PolyTraitRef<'tcx>>, // None for closures
    builtin_bounds: ty::BuiltinBounds)
    -> ty::Region
{
    match compute_opt_region_bound(this.tcx(), span, region_bounds,
                                   principal_trait_ref, builtin_bounds) {
        Some(r) => r,
        None => {
            match rscope.default_region_bound(span) {
                Some(r) => { r }
                None => {
                    this.tcx().sess.span_err(
                        span,
                        &format!("explicit lifetime bound required")[]);
                    ty::ReStatic
                }
            }
        }
    }
}
fn compute_region_bound < ' tcx > ( this : & AstConv < ' tcx > , rscope : & RegionScope , span : Span , region_bounds : & [ & ast :: Lifetime ] , principal_trait_ref : Option < ty :: PolyTraitRef < ' tcx > > , // None for closures builtin_bounds : ty :: BuiltinBounds ) -> ty :: Region { match compute_opt_region_bound ( this . tcx ( ) , span , region_bounds , principal_trait_ref , builtin_bounds ) { Some ( r ) => r , None => { match rscope . default_region_bound ( span ) { Some ( r ) => { r } None => { this . tcx ( ) . sess . span_err ( span , & format ! ( " " ) [ ] ) ; ty :: ReStatic } } } } }
A version of `compute_opt_region_bound` for use where some region bound is required
(existential types, basically).
A version of ` compute_opt_region_bound ` for use where some region bound is required ( existential types basically ) .
this
&AstConv<'tcx>
rscope
&RegionScope
span
Span
region_bounds
&[&ast::Lifetime]
principal_trait_ref
Option<ty::PolyTraitRef<'tcx>>
builtin_bounds
ty::BuiltinBounds
this
&AstConv<'tcx>
rscope
&RegionScope
span
Span
region_bounds
&[&ast::Lifetime]
principal_trait_ref
Option<ty::PolyTraitRef<'tcx>>
builtin_bounds
ty::BuiltinBounds