fn unify_query_result_substitution_guess<R>(
        &self,
        cause: &ObligationCause<'tcx>,
        param_env: ty::ParamEnv<'tcx>,
        original_values: &SmallCanonicalVarValues<'tcx>,
        result_subst: &CanonicalVarValues<'tcx>,
        query_result: &Canonical<'tcx, QueryResult<'tcx, R>>,
    ) -> InferResult<'tcx, ()>
    where
        R: Debug + TypeFoldable<'tcx>,
    {
        // A closure that yields the result value for the given
        // canonical variable; this is taken from
        // `query_result.var_values` after applying the substitution
        // `result_subst`.
        let substituted_query_result = |index: CanonicalVar| -> Kind<'tcx> {
            query_result.substitute_projected(self.tcx, &result_subst, |v| &v.var_values[index])
        };

        // Unify the original value for each variable with the value
        // taken from `query_result` (after applying `result_subst`).
        Ok(self.unify_canonical_vars(cause, param_env, original_values, substituted_query_result)?)
    }
/// Given a "guess" at the values for the canonical variables in
/// the input, try to unify with the *actual* values found in the
/// query result.  Often, but not always, this is a no-op, because
/// we already found the mapping in the "guessing" step.
///
/// See also: `query_result_substitution_guess`
Given a "guess" at the values for the canonical variables in
the input, try to unify with the *actual* values found in the
query result.  Often, but not always, this is a no-op, because
we already found the mapping in the "guessing" step.


Given a " guess " at the values for the canonical variables in the input try to unify with the * actual * values found in the query result . Often but not always this is a no - op because we already found the mapping in the " guessing " step .
fn unify_query_result_substitution_guess<R>(
        &self,
        cause: &ObligationCause<'tcx>,
        param_env: ty::ParamEnv<'tcx>,
        original_values: &SmallCanonicalVarValues<'tcx>,
        result_subst: &CanonicalVarValues<'tcx>,
        query_result: &Canonical<'tcx, QueryResult<'tcx, R>>,
    ) -> InferResult<'tcx, ()>
    where
        R: Debug + TypeFoldable<'tcx>,
    {
        // A closure that yields the result value for the given
        // canonical variable; this is taken from
        // `query_result.var_values` after applying the substitution
        // `result_subst`.
        let substituted_query_result = |index: CanonicalVar| -> Kind<'tcx> {
            query_result.substitute_projected(self.tcx, &result_subst, |v| &v.var_values[index])
        };
        // Unify the original value for each variable with the value
        // taken from `query_result` (after applying `result_subst`).
        Ok(self.unify_canonical_vars(cause, param_env, original_values, substituted_query_result)?)
    }
fn unify_query_result_substitution_guess < R > ( & self , cause : & ObligationCause < ' tcx > , param_env : ty :: ParamEnv < ' tcx > , original_values : & SmallCanonicalVarValues < ' tcx > , result_subst : & CanonicalVarValues < ' tcx > , query_result : & Canonical < ' tcx , QueryResult < ' tcx , R > > , ) -> InferResult < ' tcx , ( ) > where R : Debug + TypeFoldable < ' tcx > , { // A closure that yields the result value for the given // canonical variable; this is taken from // `query_result.var_values` after applying the substitution // `result_subst`. let substituted_query_result = | index : CanonicalVar | -> Kind < ' tcx > { query_result . substitute_projected ( self . tcx , & result_subst , | v | & v . var_values [ index ] ) } ; // Unify the original value for each variable with the value // taken from `query_result` (after applying `result_subst`). Ok ( self . unify_canonical_vars ( cause , param_env , original_values , substituted_query_result ) ? ) }
Given a "guess" at the values for the canonical variables in
the input, try to unify with the *actual* values found in the
query result.
Given a " guess " at the values for the canonical variables in the input try to unify with the * actual * values found in the query result .
&self
cause
&ObligationCause<'tcx>
param_env
ty::ParamEnv<'tcx>
original_values
&SmallCanonicalVarValues<'tcx>
result_subst
&CanonicalVarValues<'tcx>
query_result
&Canonical<'tcx, QueryResult<'tcx, R>>