pub fn report_overflow_error<T>(
        &self,
        obligation: &Obligation<'tcx, T>,
        suggest_increasing_limit: bool,
    ) -> !
        where T: fmt::Display + TypeFoldable<'tcx>
    {
        let predicate =
            self.resolve_vars_if_possible(&obligation.predicate);
        let mut err = struct_span_err!(
            self.tcx.sess,
            obligation.cause.span,
            E0275,
            "overflow evaluating the requirement `{}`",
            predicate
        );

        if suggest_increasing_limit {
            self.suggest_new_overflow_limit(&mut err);
        }

        self.note_obligation_cause_code(
            &mut err,
            &obligation.predicate,
            &obligation.cause.code,
            &mut vec![],
        );

        err.emit();
        self.tcx.sess.abort_if_errors();
        bug!();
    }
/// Reports that an overflow has occurred and halts compilation. We
/// halt compilation unconditionally because it is important that
/// overflows never be masked -- they basically represent computations
/// whose result could not be truly determined and thus we can't say
/// if the program type checks or not -- and they are unusual
/// occurrences in any case.
Reports that an overflow has occurred and halts compilation. We
halt compilation unconditionally because it is important that
overflows never be masked -- they basically represent computations
whose result could not be truly determined and thus we can't say
if the program type checks or not -- and they are unusual
occurrences in any case.
Reports that an overflow has occurred and halts compilation . We halt compilation unconditionally because it is important that overflows never be masked -- they basically represent computations whose result could not be truly determined and thus we can ' t say if the program type checks or not -- and they are unusual occurrences in any case .
pub fn report_overflow_error<T>(
        &self,
        obligation: &Obligation<'tcx, T>,
        suggest_increasing_limit: bool,
    ) -> !
        where T: fmt::Display + TypeFoldable<'tcx>
    {
        let predicate =
            self.resolve_vars_if_possible(&obligation.predicate);
        let mut err = struct_span_err!(
            self.tcx.sess,
            obligation.cause.span,
            E0275,
            "overflow evaluating the requirement `{}`",
            predicate
        );
        if suggest_increasing_limit {
            self.suggest_new_overflow_limit(&mut err);
        }
        self.note_obligation_cause_code(
            &mut err,
            &obligation.predicate,
            &obligation.cause.code,
            &mut vec![],
        );
        err.emit();
        self.tcx.sess.abort_if_errors();
        bug!();
    }
pub fn report_overflow_error < T > ( & self , obligation : & Obligation < ' tcx , T > , suggest_increasing_limit : bool , ) -> ! where T : fmt :: Display + TypeFoldable < ' tcx > { let predicate = self . resolve_vars_if_possible ( & obligation . predicate ) ; let mut err = struct_span_err ! ( self tcx sess obligation cause span E0275 " " predicate ) ; if suggest_increasing_limit { self . suggest_new_overflow_limit ( & mut err ) ; } self . note_obligation_cause_code ( & mut err , & obligation . predicate , & obligation . cause . code , & mut vec ! [ ] , ) ; err . emit ( ) ; self . tcx . sess . abort_if_errors ( ) ; bug ! ( ) ; }
Reports that an overflow has occurred and halts compilation.
Reports that an overflow has occurred and halts compilation .
&self
obligation
&Obligation<'tcx, T>
suggest_increasing_limit
bool