Ejemplo n.º 1
0
 public QualifiedMember(QualifiedType containingType, string name)
 {
     this.Name           = name;
     this.ContainingType = containingType;
 }
 internal static bool IsEither(this ITypeSymbol type, QualifiedType q1, QualifiedType q2, QualifiedType q3) => type == q1 || type == q2 || type == q3;
        internal static bool IsSameType(this ExpressionSyntax expression, QualifiedType metadataName, SemanticModel semanticModel, CancellationToken cancellationToken)
        {
            var type = semanticModel?.Compilation.GetTypeByMetadataName(metadataName.FullName);

            return(expression.IsSameType(type, semanticModel, cancellationToken));
        }
Ejemplo n.º 4
0
 private static bool NameEquals(string left, QualifiedType right)
 {
     return(left == right.Type ||
            (right.alias != null && left == right.alias));
 }
 internal static bool IsSameType(this ExpressionSyntax expression, QualifiedType metadataName, SyntaxNodeAnalysisContext context)
 {
     return(expression.IsSameType(metadataName, context.SemanticModel, context.CancellationToken));
 }