2 writes to InputType
Microsoft.CodeAnalysis.CSharp (2)
Generated\BoundNodes.xml.Generated.cs (2)
8119this.InputType = inputType; 8134this.InputType = inputType;
170 references to InputType
Microsoft.CodeAnalysis.CSharp (170)
Binder\Binder_Patterns.cs (1)
2378candidate = pat.InputType;
Binder\DecisionDagBuilder_CheckOrReachability.cs (37)
440var negated = new BoundNegatedPattern(pattern.Syntax, negated: pattern, pattern.InputType, narrowedType: pattern.InputType); 558var wrappedPattern = new BoundBinaryPattern(newPattern.Syntax, disjunction: false, current.Left, newPattern, current.InputType, newPattern.NarrowedType); 813stack.Push(new BoundBinaryPattern(operationSyntax, disjunction, left, right, left.InputType, narrowedType)); 828inputType = stack.Peek().InputType; 855return resultLeft.InputType; 1010var result = new BoundNegatedPattern(node.Syntax, node, node.InputType, narrowedType: node.InputType); 1051if (pattern.InputType.Equals(inputType, TypeCompareKind.AllIgnoreOptions)) 1065new BoundTypeExpression(recursivePattern.Syntax, aliasOpt: null, recursivePattern.InputType.StrippedType()), 1107new BoundTypeExpression(pattern.Syntax, aliasOpt: null, pattern.InputType), 1108isExplicitNotNullTest: false, unionMatchingMode: UnionMatchingMode.None, inputType, narrowedType: pattern.InputType).MakeCompilerGenerated(); 1122var result = new BoundDeclarationPattern(node.Syntax, node.DeclaredType, node.IsVar, unionMatchingMode: UnionMatchingMode.None, node.Variable, node.VariableAccess, node.InputType, node.NarrowedType) 1162initialCheck = new BoundTypePattern(node.Syntax, node.DeclaredType, node.IsExplicitNotNullTest, unionMatchingMode: UnionMatchingMode.None, node.InputType, node.NarrowedType, node.HasErrors); 1164else if (node.InputType.CanContainNull()) 1168new BoundLiteral(node.Syntax, constantValueOpt: ConstantValue.Null, type: node.InputType, hasErrors: false), 1169ConstantValue.Null, unionMatchingMode: UnionMatchingMode.None, node.InputType, node.InputType, hasErrors: false); 1170initialCheck = new BoundNegatedPattern(node.Syntax, nullCheck, node.InputType, narrowedType: node.InputType); 1176ImmutableArray<BoundPropertySubpattern>.Empty, isExplicitNotNullTest: false, unionMatchingMode: UnionMatchingMode.None, variable: null, variableAccess: null, node.InputType, node.InputType); 1185var discards = deconstruction.SelectAsArray(d => d.WithPattern(MakeDiscardPattern(d.Syntax, d.Pattern.InputType))); 1195newPattern = WithInputTypeCheckIfNeeded(newPattern, deconstruction[i].Pattern.InputType); 1202node.InputType, node.NarrowedType, node.HasErrors); 1230newPattern = WithInputTypeCheckIfNeeded(newPattern, property!.Pattern.InputType); 1237node.InputType, node.NarrowedType, node.HasErrors); 1298var discards = subpatterns.SelectAsArray(d => d.WithPattern(MakeDiscardPattern(d.Syntax, d.Pattern.InputType))); 1305ituplePattern.InputType, ituplePattern.NarrowedType); 1318newPattern = WithInputTypeCheckIfNeeded(newPattern, subpatterns[i].Pattern.InputType); 1322ituplePattern.GetItemMethod, newSubpatterns, ituplePattern.InputType, ituplePattern.NarrowedType); 1381newPattern = WithInputTypeCheckIfNeeded(newPattern, equivalentDefaultPatterns[i].InputType); 1387listPattern.InputType, listPattern.NarrowedType); 1408newPattern = WithInputTypeCheckIfNeeded(newPattern, slice.Pattern.InputType); 1411slice.ReceiverPlaceholder, slice.ArgumentPlaceholder, slice.InputType, slice.NarrowedType); 1418listPattern.InputType, listPattern.NarrowedType); 1467return MakeDiscardPattern(pattern.Syntax, pattern.InputType);
Binder\DecisionDagBuilder_ListPatterns.cs (4)
18Debug.Assert(inputType.IsErrorType() || list.HasErrors || list.InputType.IsErrorType() || 19inputType.Equals(list.InputType, TypeCompareKind.AllIgnoreOptions) && 68var sliceEvaluation = new BoundDagSliceEvaluation(slicePattern.Syntax, slicePattern.InputType, lengthTemp, startIndex: startIndex, endIndex: index, 83var indexEvaluation = new BoundDagIndexerEvaluation(subpattern.Syntax, subpattern.InputType, lengthTemp, index++,
Binder\DecisionDagBuilder.cs (6)
374(pattern.HasErrors || pattern.InputType.Equals(input.DagTemp.Type, TypeCompareKind.AllIgnoreOptions) || pattern.InputType.IsErrorType()) : 375(pattern.InputType.SpecialType == SpecialType.System_Object)); 939RoslynDebug.Assert(inputTempType.IsErrorType() || recursive.HasErrors || recursive.InputType.IsErrorType() || inputTempType.Equals(recursive.InputType, TypeCompareKind.AllIgnoreOptions)); 1148if (bin.InputType.Equals(bin.NarrowedType))
Binder\UnionMatchingRewriter.cs (33)
63Debug.Assert(exclusiveValuePattern.InputType.IsObjectType()); 67var member = new BoundPropertySubpatternMember(exclusiveValuePattern.Syntax, receiver: null, valueProperty, type: exclusiveValuePattern.InputType, hasErrors: valueProperty is null).MakeCompilerGenerated(); 84Debug.Assert(node.InputType.IsSubjectForUnionMatching); 89Debug.Assert(Binder.IsClassOrNullableValueTypeUnionNullPatternMatching((NamedTypeSymbol)node.InputType, node.ConstantValue)); 90Debug.Assert(node.NarrowedType.Equals(node.InputType, TypeCompareKind.AllIgnoreOptions)); 95(NamedTypeSymbol)node.InputType, 100left: node.Update(node.Value, node.ConstantValue, unionMatchingMode: UnionMatchingMode.None, node.InputType, node.InputType).MakeCompilerGenerated(), 102inputType: node.InputType, 103narrowedType: node.InputType) 108(NamedTypeSymbol)node.InputType, 121(NamedTypeSymbol)node.InputType, 124unionMatchingMode: UnionMatchingMode.None, node.Variable, node.VariableAccess, inputType: node.InputType, narrowedType: node.NarrowedType), 142TypeSymbol? inputType = node.InputType; 155(NamedTypeSymbol)node.InputType, 158inputType: node.InputType, narrowedType: node.NarrowedType), 174(NamedTypeSymbol)node.InputType, 176node.Update(node.DeclaredType, node.IsExplicitNotNullTest, unionMatchingMode: UnionMatchingMode.None, inputType: node.InputType, narrowedType: node.NarrowedType), 190(NamedTypeSymbol)node.InputType, 201return node.Update(negated, node.InputType, node.NarrowedType); 210TypeSymbol? inputType = node.InputType; 300Debug.Assert(node.NarrowedType.Equals(leastSpecific ?? node.InputType, TypeCompareKind.ConsiderEverything)); 303return node.Update(disjunction: true, preboundLeft, right, inputType: node.InputType, narrowedType: node.NarrowedType); 366inputType: left.InputType).MakeCompilerGenerated(); 389inputType: leftUnionPattern.InputType).MakeCompilerGenerated(); 434return new BoundBinaryPattern(node, disjunction: false, left, right, inputType: left.InputType, narrowedType: right.NarrowedType) { WasCompilerGenerated = makeCompilerGenerated }; 488toNegate = makeTypePattern(typePattern.DeclaredType, typePattern.InputType); 491toNegate = makeTypePattern(declarationPattern.DeclaredType, declarationPattern.InputType); 494toNegate = makeTypePattern(declaredType, recursivePattern.InputType); 502new BoundNegatedPattern(toNegate.Syntax, toNegate, toNegate.InputType, toNegate.InputType).MakeCompilerGenerated(), 530Debug.Assert(result.InputType.Equals(pattern.InputType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundBinaryPattern.cs (5)
13Debug.Assert(Left.InputType.Equals(InputType, TypeCompareKind.AllIgnoreOptions)); 19Debug.Assert(Right.InputType.Equals(InputType, TypeCompareKind.AllIgnoreOptions)); 25Debug.Assert(Right.InputType.Equals(Left.NarrowedType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundConstantPattern.cs (4)
18(ConstantValue == ConstantValue.Null && (InputType.IsNullableType() || !InputType.IsValueType) && NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions))); 22Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions) ||
BoundTree\BoundDiscardPattern.cs (1)
13Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundListPattern.cs (2)
16return Update(subpatterns, this.HasSlice, this.LengthAccess, this.IndexerAccess, this.ReceiverPlaceholder, this.ArgumentPlaceholder, this.Variable, this.VariableAccess, this.InputType, this.NarrowedType); 26Debug.Assert(NarrowedType.Equals(InputType.StrippedType(), TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundNegatedPattern.cs (3)
14Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions)); 15Debug.Assert(Negated.InputType.Equals(InputType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundPattern.cs (1)
36Debug.Assert(UnionMatchingMode == UnionMatchingMode.None || InputType is { IsSubjectForUnionMatching: true });
BoundTree\BoundPatternWithUnionMatching.cs (4)
15Debug.Assert(InputType.Equals(LeftOfPendingConjunction?.InputType ?? UnionMatchingInputType, TypeCompareKind.AllIgnoreOptions)); 16Debug.Assert(UnionMatchingInputType == (object)(LeftOfPendingConjunction?.NarrowedType ?? InputType)); 39Debug.Assert(ExclusiveInstancePattern.InputType == (object)UnionMatchingInputType);
BoundTree\BoundRecursivePattern.cs (1)
18Debug.Assert(NarrowedType.Equals(InputType.StrippedType(), TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundRelationalPattern.cs (1)
22Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions) ||
BoundTree\BoundSlicePattern.cs (2)
13return Update(pattern, this.IndexerAccess, this.ReceiverPlaceholder, this.ArgumentPlaceholder, this.InputType, this.NarrowedType); 21Debug.Assert(NarrowedType.Equals(InputType, TypeCompareKind.AllIgnoreOptions));
BoundTree\BoundTreeRewriter.cs (1)
375left = binary.Update(binary.Disjunction, left, right, VisitType(binary.InputType), VisitType(binary.NarrowedType));
BoundTree\NullabilityRewriter.cs (1)
159TypeSymbol inputType = GetUpdatedSymbol(currentBinary, currentBinary.InputType);
Compilation\CSharpSemanticModel.cs (2)
2040pattern.InputType, pattern.NarrowedType, nullability: default, convertedNullability: default, 2041Compilation.Conversions.ClassifyBuiltInConversion(pattern.InputType, pattern.NarrowedType, isChecked: false, ref discardedUseSiteInfo));
Generated\BoundNodes.xml.Generated.cs (47)
8171if (value != this.Value || constantValue != this.ConstantValue || unionMatchingMode != this.UnionMatchingMode || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8217if (!TypeSymbol.Equals(unionMatchingInputType, this.UnionMatchingInputType, TypeCompareKind.ConsiderEverything) || leftOfPendingConjunction != this.LeftOfPendingConjunction || exclusiveInstancePattern != this.ExclusiveInstancePattern || valueProperty != this.ValueProperty || exclusiveValuePattern != this.ExclusiveValuePattern || sharedRightOfPendingConjunction != this.SharedRightOfPendingConjunction || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8257if (!TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8312if (declaredType != this.DeclaredType || isVar != this.IsVar || unionMatchingMode != this.UnionMatchingMode || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(variable, this.Variable) || variableAccess != this.VariableAccess || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8355if (declaredType != this.DeclaredType || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(deconstructMethod, this.DeconstructMethod) || deconstruction != this.Deconstruction || properties != this.Properties || isExplicitNotNullTest != this.IsExplicitNotNullTest || unionMatchingMode != this.UnionMatchingMode || !Symbols.SymbolEqualityComparer.ConsiderEverything.Equals(variable, this.Variable) || variableAccess != this.VariableAccess || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8399if (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)) 8438if (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)) 8478if (!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)) 8624if (declaredType != this.DeclaredType || isExplicitNotNullTest != this.IsExplicitNotNullTest || unionMatchingMode != this.UnionMatchingMode || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8663if (disjunction != this.Disjunction || left != this.Left || right != this.Right || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8697if (negated != this.Negated || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 8738if (relation != this.Relation || value != this.Value || constantValue != this.ConstantValue || unionMatchingMode != this.UnionMatchingMode || !TypeSymbol.Equals(inputType, this.InputType, TypeCompareKind.ConsiderEverything) || !TypeSymbol.Equals(narrowedType, this.NarrowedType, TypeCompareKind.ConsiderEverything)) 12520TypeSymbol? inputType = this.VisitType(node.InputType); 12532TypeSymbol? inputType = this.VisitType(node.InputType); 12538TypeSymbol? inputType = this.VisitType(node.InputType); 12547TypeSymbol? inputType = this.VisitType(node.InputType); 12559TypeSymbol? inputType = this.VisitType(node.InputType); 12572TypeSymbol? inputType = this.VisitType(node.InputType); 12582TypeSymbol? inputType = this.VisitType(node.InputType); 12591TypeSymbol? inputType = this.VisitType(node.InputType); 12617TypeSymbol? inputType = this.VisitType(node.InputType); 12625TypeSymbol? inputType = this.VisitType(node.InputType); 12632TypeSymbol? inputType = this.VisitType(node.InputType); 12639TypeSymbol? inputType = this.VisitType(node.InputType); 15214TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15223TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15235TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15243TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15254TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15266TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15279TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15292TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15314TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15322TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 15330TypeSymbol inputType = GetUpdatedSymbol(node, node.InputType); 17467new TreeDumperNode("inputType", node.InputType, null), 17480new TreeDumperNode("inputType", node.InputType, null), 17487new TreeDumperNode("inputType", node.InputType, null), 17499new TreeDumperNode("inputType", node.InputType, null), 17514new TreeDumperNode("inputType", node.InputType, null), 17529new TreeDumperNode("inputType", node.InputType, null), 17540new TreeDumperNode("inputType", node.InputType, null), 17550new TreeDumperNode("inputType", node.InputType, null), 17583new TreeDumperNode("inputType", node.InputType, null), 17593new TreeDumperNode("inputType", node.InputType, null), 17601new TreeDumperNode("inputType", node.InputType, null), 17612new TreeDumperNode("inputType", node.InputType, null),
Operations\CSharpOperationFactory.cs (14)
2586TypeSymbol inputType = boundConstantPattern.InputType; 2597TypeSymbol inputType = boundRelationalPattern.InputType; 2610ITypeSymbol inputType = boundDeclarationPattern.InputType.GetPublicSymbol(); 2621ITypeSymbol matchedType = (boundRecursivePattern.DeclaredType?.Type ?? boundRecursivePattern.InputType.StrippedType()).GetPublicSymbol(); 2634boundRecursivePattern.InputType.GetPublicSymbol(), 2648boundITuplePattern.InputType.StrippedType().GetPublicSymbol(), 2653boundITuplePattern.InputType.GetPublicSymbol(), 2664inputType: boundTypePattern.InputType.GetPublicSymbol(), 2677inputType: boundNode.InputType.GetPublicSymbol(), 2691inputType: boundNode.InputType.GetPublicSymbol(), 2702boundNegatedPattern.InputType.GetPublicSymbol(), 2742boundBinaryPattern.InputType.GetPublicSymbol(), 2825cp.InputType.IsValidV6SwitchGoverningType()) 2911inputType: boundNode.InputType.GetPublicSymbol(),