CalculateArgumentScore() public static method

public static CalculateArgumentScore ( Type paramType, Type argType ) : int
paramType System.Type
argType System.Type
return int
Esempio n. 1
0
        private bool CalculateCandidateArgumentScore(CandidateMethod candidateMethod, int argumentIndex, Type paramType)
        {
            int score = CandidateMethod.CalculateArgumentScore(paramType, _arguments[argumentIndex]);

            if (score < 0)
            {
                return(false);
            }

            candidateMethod.ArgumentScores[argumentIndex] = score;
            return(true);
        }
Esempio n. 2
0
 private void EmitLoadValue()
 {
     EmitArgArrayElement(0);
     EmitCoercion(_argumentType, _field.FieldType, CandidateMethod.CalculateArgumentScore(_field.FieldType, _argumentType));
 }