Binder\Binder_Patterns.cs (6)
1040return new BoundDeclarationPattern(node, boundDeclType, isVar: false, isUnionMatching: hasUnionMatching, variableSymbol, variableAccess, inputType: inputType, narrowedType: boundDeclType.Type, hasErrors);
1268narrowedType: boundDeclType?.Type ?? inputType.StrippedType(), hasErrors);
1924hasErrors |= CheckValidPatternType(typeSyntax, inputType, patternType.Type, diagnostics: diagnostics, ref useSiteInfo, out _) ||
1925(unionType is not null && CheckValidPatternTypeForUnionCases(typeSyntax, unionType, patternType.Type, diagnostics: diagnostics, ref useSiteInfo));
1953bool isExplicitNotNullTest = patternType.Type.SpecialType == SpecialType.System_Object;
1958return new BoundTypePattern(node, patternType, isExplicitNotNullTest, isUnionMatching: hasUnionMatching, inputType: inputType, patternType.Type, hasErrors);
Generated\BoundNodes.xml.Generated.cs (4)
1102if (!Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(aliasOpt, this.AliasOpt) || boundContainingTypeOpt != this.BoundContainingTypeOpt || boundDimensionsOpt != this.BoundDimensionsOpt || typeWithAnnotations != this.TypeWithAnnotations || !TypeSymbol.Equals(type, this.Type, TypeCompareKind.ConsiderEverything))
11233TypeSymbol? type = this.VisitType(node.Type);
12982updatedNode = node.Update(node.AliasOpt, boundContainingTypeOpt, boundDimensionsOpt, node.TypeWithAnnotations, node.Type);
15655new TreeDumperNode("type", node.Type, null),