Microsoft.CSharp.RuntimeBinder.Semantics.MethodTypeInferrer.ExactConstructedInference C# (CSharp) Метод

ExactConstructedInference() приватный Метод

private ExactConstructedInference ( CType pSource, CType pDest ) : bool
pSource CType
pDest CType
Результат bool
        private bool ExactConstructedInference(CType pSource, CType pDest)
        {
            // SPEC:  Otherwise, if V is a constructed CType C<V1...Vk> and U is a constructed
            // SPEC:   CType C<U1...Uk> then an exact inference 
            // SPEC:   is made from each Ui to the corresponding Vi.

            if (!pSource.IsAggregateType() || !pDest.IsAggregateType())
            {
                return false;
            }
            AggregateType pConstructedSource = pSource.AsAggregateType();
            AggregateType pConstructedDest = pDest.AsAggregateType();
            if (pConstructedSource.GetOwningAggregate() != pConstructedDest.GetOwningAggregate())
            {
                return false;
            }
            ExactTypeArgumentInference(pConstructedSource, pConstructedDest);
            return true;
        }