2 writes to NarrowedType
Microsoft.CodeAnalysis.CSharp (2)
Generated\BoundNodes.xml.Generated.cs (2)
7998this.NarrowedType = narrowedType; 8009this.NarrowedType = narrowedType;
86 references to NarrowedType
Microsoft.CodeAnalysis.CSharp (86)
Binder\Binder_Patterns.cs (4)
1856var right = binder.BindPattern(node.Right, preboundLeft.NarrowedType, permitDesignations, hasErrors, diagnostics); 1858narrowedTypeCandidates.Add(right.NarrowedType); 1859return new BoundBinaryPattern(node, disjunction: isDisjunction, preboundLeft, right, inputType: inputType, narrowedType: right.NarrowedType, hasErrors); 1872candidates.Add(pat.NarrowedType);
Binder\DecisionDagBuilder.cs (3)
679if (bin.InputType.Equals(bin.NarrowedType)) 688output = @this.MakeConvertToType(input: input, syntax: bin.Syntax, type: bin.NarrowedType, isExplicitTest: false, tests: builder); 697Debug.Assert(bin.HasErrors || output.Type.Equals(bin.NarrowedType, TypeCompareKind.AllIgnoreOptions));
Binder\DecisionDagBuilder_ListPatterns.cs (2)
17input.Type.StrippedType().Equals(list.NarrowedType, TypeCompareKind.ConsiderEverything) && 24output = input = MakeConvertToType(input, list.Syntax, list.NarrowedType, isExplicitTest: false, tests);
BoundTree\BoundBinaryPattern.cs (3)
23Debug.Assert(Right.InputType.Equals(Left.NarrowedType, TypeCompareKind.AllIgnoreOptions)); 24Debug.Assert(NarrowedType.Equals(Right.NarrowedType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundConstantPattern.cs (2)
13Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions) || 14NarrowedType.Equals(Value.Type, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundDeclarationPattern.cs (2)
14NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions) : 15NarrowedType.Equals(DeclaredType.Type, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundDiscardPattern.cs (1)
13Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundITuplePattern.cs (2)
14Debug.Assert(NarrowedType.IsCompilerServicesTopLevelType() && NarrowedType.Name == "ITuple");
BoundTree\BoundListPattern.cs (1)
17Debug.Assert(NarrowedType.Equals(InputType.StrippedType(), TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundNegatedPattern.cs (1)
13Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundRecursivePattern.cs (2)
15NarrowedType.Equals(InputType.StrippedType(), TypeCompareKind.AllIgnoreOptions) : 16NarrowedType.Equals(DeclaredType.Type, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundRelationalPattern.cs (2)
13Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions) || 14NarrowedType.Equals(Value.Type, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundSlicePattern.cs (1)
15Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundTreeRewriter.cs (1)
233left = binary.Update(binary.Disjunction, left, right, VisitType(binary.InputType), VisitType(binary.NarrowedType));
BoundTree\BoundTypePattern.cs (1)
13Debug.Assert(NarrowedType.Equals(DeclaredType.Type, TypeCompareKind.AllIgnoreOptions));
Compilation\CSharpSemanticModel.cs (2)
2026pattern.InputType, pattern.NarrowedType, nullability: default, convertedNullability: default, 2027Compilation.Conversions.ClassifyBuiltInConversion(pattern.InputType, pattern.NarrowedType, isChecked: false, ref discardedUseSiteInfo));
Generated\BoundNodes.xml.Generated.cs (44)
8043if (value != this.Value || constantValue != this.ConstantValue || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8083if (!TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8136if (declaredType != this.DeclaredType || isVar != this.IsVar || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(variable, this.Variable) || variableAccess != this.VariableAccess || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8177if (declaredType != this.DeclaredType || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(deconstructMethod, this.DeconstructMethod) || deconstruction != this.Deconstruction || properties != this.Properties || isExplicitNotNullTest != this.IsExplicitNotNullTest || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(variable, this.Variable) || variableAccess != this.VariableAccess || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8221if (subpatterns != this.Subpatterns || hasSlice != this.HasSlice || lengthAccess != this.LengthAccess || indexerAccess != this.IndexerAccess || receiverPlaceholder != this.ReceiverPlaceholder || argumentPlaceholder != this.ArgumentPlaceholder || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(variable, this.Variable) || variableAccess != this.VariableAccess || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8260if (pattern != this.Pattern || indexerAccess != this.IndexerAccess || receiverPlaceholder != this.ReceiverPlaceholder || argumentPlaceholder != this.ArgumentPlaceholder || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8300if (!Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(getLengthMethod, this.GetLengthMethod) || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(getItemMethod, this.GetItemMethod) || subpatterns != this.Subpatterns || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8440if (declaredType != this.DeclaredType || isExplicitNotNullTest != this.IsExplicitNotNullTest || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8479if (disjunction != this.Disjunction || left != this.Left || right != this.Right || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8513if (negated != this.Negated || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8552if (relation != this.Relation || value != this.Value || constantValue != this.ConstantValue || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 12094TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12100TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12108TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12118TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12130TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12140TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12147TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12171TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12179TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12186TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 12193TypeSymbol? narrowedType = this.VisitType(node.NarrowedType); 14750TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14758TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14766TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14777TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14789TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14802TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14815TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14837TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14845TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14854TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 14862TypeSymbol narrowedType = GetUpdatedSymbol(node, node.NarrowedType); 16949new TreeDumperNode("narrowedType", node.NarrowedType, null), 16956new TreeDumperNode("narrowedType", node.NarrowedType, null), 16967new TreeDumperNode("narrowedType", node.NarrowedType, null), 16981new TreeDumperNode("narrowedType", node.NarrowedType, null), 16996new TreeDumperNode("narrowedType", node.NarrowedType, null), 17007new TreeDumperNode("narrowedType", node.NarrowedType, null), 17017new TreeDumperNode("narrowedType", node.NarrowedType, null), 17049new TreeDumperNode("narrowedType", node.NarrowedType, null), 17059new TreeDumperNode("narrowedType", node.NarrowedType, null), 17067new TreeDumperNode("narrowedType", node.NarrowedType, null), 17077new TreeDumperNode("narrowedType", node.NarrowedType, null),
Operations\CSharpOperationFactory.cs (12)
2521TypeSymbol narrowedType = boundConstantPattern.NarrowedType; 2532TypeSymbol narrowedType = boundRelationalPattern.NarrowedType; 2545ITypeSymbol narrowedType = boundDeclarationPattern.NarrowedType.GetPublicSymbol(); 2569boundRecursivePattern.NarrowedType.GetPublicSymbol(), 2588boundITuplePattern.NarrowedType.GetPublicSymbol(), 2597matchedType: boundTypePattern.NarrowedType.GetPublicSymbol(), 2599narrowedType: boundTypePattern.NarrowedType.GetPublicSymbol(), 2612narrowedType: boundNode.NarrowedType.GetPublicSymbol(), 2626narrowedType: boundNode.NarrowedType.GetPublicSymbol(), 2637boundNegatedPattern.NarrowedType.GetPublicSymbol(), 2677boundBinaryPattern.NarrowedType.GetPublicSymbol(), 2846narrowedType: boundNode.NarrowedType.GetPublicSymbol(),