rustc_const_eval::const_eval::error

Function report

source
pub(super) fn report<'tcx, C, F, E>(
    tcx: TyCtxt<'tcx>,
    error: InterpError<'tcx>,
    span: Span,
    get_span_and_frames: C,
    mk: F,
) -> ErrorHandled
where C: FnOnce() -> (Span, Vec<FrameNote>), F: FnOnce(Span, Vec<FrameNote>) -> E, E: Diagnostic<'tcx>,
Expand description

Create a diagnostic for a const eval error.

This will use the mk function for creating the error which will get passed labels according to the InterpError and the span and a stacktrace of current execution according to get_span_and_frames.