////////////////////////////////////////////////////////////////////////////////
//
// Input types
//
private bool DoesInputTypeContain(EXPR pSource, CType pDest,
TypeParameterType pParam)
{
// SPEC: If E is a method group or an anonymous function and T is a delegate
// SPEC: CType or expression tree CType then all the parameter types of T are
// SPEC: input types of E with CType T.
pDest = pDest.GetDelegateTypeOfPossibleExpression();
if (!pDest.isDelegateType())
{
return false; // No input types.
}
if (!pSource.isUNBOUNDLAMBDA() && !pSource.isMEMGRP())
{
return false; // No input types.
}
TypeArray pDelegateParameters =
pDest.AsAggregateType().GetDelegateParameters(GetSymbolLoader());
if (pDelegateParameters == null)
{
return false;
}
return TypeManager.ParametersContainTyVar(pDelegateParameters, pParam);
}