pub fn try_evaluate_const<'tcx>(
infcx: &InferCtxt<'tcx>,
ct: Const<'tcx>,
param_env: ParamEnv<'tcx>,
) -> Result<Const<'tcx>, EvaluateConstErr>
Expand description
Evaluates a type system constant making sure to not allow constants that depend on generic parameters or inference variables to succeed in evaluating.
You should not call this function unless you are implementing normalization itself. Prefer to use
normalize_erasing_regions
or the normalize
functions on ObligationCtxt
/FnCtxt
/InferCtxt
.