293 references to Create
Microsoft.CodeAnalysis.CSharp (293)
Binder\Binder.ValueChecks.cs (5)
3000=> TypeWithAnnotations.Create(_type, NullableAnnotation.NotAnnotated); 5476TypeWithAnnotations.Create(elementAccess.Expression.Type), 5485returnType: TypeWithAnnotations.Create(elementAccess.Type), 5516TypeWithAnnotations.Create(inlineArray.Type), 5525returnType: TypeWithAnnotations.Create(resultType),
Binder\Binder_AnonymousTypes.cs (1)
95TypeWithAnnotations.Create(fieldType),
Binder\Binder_Crefs.cs (1)
945parameterBuilder.Add(new SignatureOnlyParameterSymbol(TypeWithAnnotations.Create(type), ImmutableArray<CustomModifier>.Empty, isParamsArray: false, isParamsCollection: false, refKind: refKind));
Binder\Binder_Deconstruct.cs (4)
374return pending.SetInferredTypeWithAnnotations(TypeWithAnnotations.Create(type), this, diagnostics); 380return pending.SetInferredTypeWithAnnotations(TypeWithAnnotations.Create(type)); 518typesWithAnnotationsBuilder.Add(TypeWithAnnotations.Create(mergedType)); 569typesWithAnnotationsBuilder.Add(TypeWithAnnotations.Create(value.Type));
Binder\Binder_Expressions.cs (6)
368var type = new PointerTypeSymbol(TypeWithAnnotations.Create(boundStackAlloc.ElementType)); 941declTypeWithAnnotations = declTypeWithAnnotations.HasType ? declTypeWithAnnotations : TypeWithAnnotations.Create(CreateErrorType("var")); 1047var elementTypeWithAnnotations = TypeWithAnnotations.Create(boundArgument.Type); 4087var arrayType = ArrayTypeSymbol.CreateCSharpArray(Compilation.Assembly, TypeWithAnnotations.Create(bestType), rank); 4116type: GetStackAllocType(node, TypeWithAnnotations.Create(bestType), diagnostics, out bool hasErrors), 8305typeWithAnnotations: TypeWithAnnotations.Create(type));
Binder\Binder_Invocation.cs (2)
2068newArguments[i] = ((OutVariablePendingInference)argument).SetInferredTypeWithAnnotations(TypeWithAnnotations.Create(candidateType), null); 2079newArguments[i] = ((BoundDiscardExpression)argument).SetInferredTypeWithAnnotations(TypeWithAnnotations.Create(candidateType));
Binder\Binder_Operators.cs (1)
2553TypeSymbol pointerType = new PointerTypeSymbol(TypeWithAnnotations.Create(operandType));
Binder\Binder_Patterns.cs (2)
332declType: TypeWithAnnotations.Create(narrowedType, NullableAnnotation.NotAnnotated), 942return TypeWithAnnotations.Create(inputType.StrippedType(), NullableAnnotation.NotAnnotated);
Binder\Binder_Query.cs (1)
818new AnonymousTypeField(fieldName, fieldValue.Syntax.Location, TypeWithAnnotations.Create(TypeOrError(fieldValue)), RefKind.None, ScopedKind.None);
Binder\Binder_Statements.cs (5)
1023declTypeOpt = TypeWithAnnotations.Create(initializerType); 1028declTypeOpt = TypeWithAnnotations.Create(CreateErrorType("var")); 1043declTypeOpt = TypeWithAnnotations.Create(CreateErrorType("var")); 1365TypeSymbol pointerType = new PointerTypeSymbol(TypeWithAnnotations.Create(elementType)); 1470return op1.SetInferredTypeWithAnnotations(TypeWithAnnotations.Create(inferredType));
Binder\Binder_Symbols.cs (9)
341return TypeWithAnnotations.Create(new ExtendedErrorTypeSymbol(GetContainingNamespaceOrType(symbol.Symbol), symbol.Symbol, LookupResultKind.NotATypeOrNamespace, diagnosticInfo)); 459return TypeWithAnnotations.Create( 584return TypeWithAnnotations.Create(new ExtendedErrorTypeSymbol(left, LookupResultKind.NotATypeOrNamespace, diagnostics.Add(ErrorCode.ERR_ColColWithTypeAlias, node.Alias.Location, node.Alias.Identifier.Text))); 601return TypeWithAnnotations.Create(new PointerTypeSymbol(elementType)); 607return TypeWithAnnotations.Create(CreateErrorType()); 834return TypeWithAnnotations.Create(new ExtendedErrorTypeSymbol(qualifierOpt ?? this.Compilation.Assembly.GlobalNamespace, string.Empty, arity: 0, errorInfo: null)); 860return TypeWithAnnotations.Create(new ExtendedErrorTypeSymbol( 868return TypeWithAnnotations.Create(errorResult); 1363? TypeWithAnnotations.Create(UnboundArgumentErrorTypeSymbol.Instance)
Binder\ForEachLoopBinder.cs (7)
303declType = inferredType.HasType ? inferredType : TypeWithAnnotations.Create(CreateErrorType("var")); 370iterationVariableType = inferredType.HasType ? inferredType : TypeWithAnnotations.Create(CreateErrorType("var")); 680inferredType = TypeWithAnnotations.Create(DynamicTypeSymbol.Instance); 688inferredType = TypeWithAnnotations.Create(GetSpecialType(SpecialType.System_Char, diagnostics, collectionExpr.Syntax)); 1163builder.ElementTypeWithAnnotations = builder.CurrentPropertyGetter?.ReturnTypeWithAnnotations ?? TypeWithAnnotations.Create(GetSpecialType(SpecialType.System_Object, diagnostics, errorLocationSyntax)); 1285builder.ElementTypeWithAnnotations = TypeWithAnnotations.Create( 1293TypeWithAnnotations.Create(GetSpecialType(SpecialType.System_Char, diagnostics, syntax)) :
Binder\InMethodBinder.cs (1)
139return !elementType.IsDefault ? elementType : TypeWithAnnotations.Create(CreateErrorType());
Binder\Semantics\Conversions\Conversions.cs (1)
491var sourceAsPointer = new PointerTypeSymbol(TypeWithAnnotations.Create(sourceExpression.ElementType));
Binder\Semantics\OverloadResolution\MethodTypeInference.cs (4)
105return TypeWithAnnotations.Create(expr.GetTypeOrFunctionType()); 467_fixedResults[i] = (TypeWithAnnotations.Create(new ExtendedErrorTypeSymbol(_constructedContainingTypeOfMethod, _methodTypeParameters[i].Name, 0, null, false)), false); 2967best = TypeWithAnnotations.Create(resultType, best.NullableAnnotation); 3395var newBound = TypeWithAnnotations.Create(oldBound.Type, newAnnotation);
Binder\Semantics\OverloadResolution\OverloadResolution.cs (1)
4380paramsElementTypeOpt = TypeWithAnnotations.Create(ErrorTypeSymbol.EmptyParamsCollectionElementTypeSentinel);
Binder\Semantics\OverloadResolution\OverloadResolutionResult.cs (1)
1337TypeWithAnnotations.Create(argType),
Binder\WithLambdaParametersBinder.cs (1)
75return TypeWithAnnotations.Create(CreateErrorType());
BoundTree\BoundDiscardExpression.cs (1)
33return new DiscardSymbol(TypeWithAnnotations.Create(this.Type, this.TopLevelNullability.Annotation.ToInternalAnnotation()));
BoundTree\Constructors.cs (1)
560: this(syntax, aliasOpt, null, TypeWithAnnotations.Create(type), hasErrors)
BoundTree\OutDeconstructVarPendingInference.cs (1)
24return SetInferredTypeWithAnnotations(TypeWithAnnotations.Create(binder.CreateErrorType()), success: false);
BoundTree\UnboundLambda.cs (4)
278bestResultType = TypeWithAnnotations.Create(bestType); 290bestResultType = TypeWithAnnotations.Create(bestType); 380_builder.Add((node, TypeWithAnnotations.Create(type))); 965: TypeWithAnnotations.Create(LambdaSymbol.InferenceFailureReturnType);
BoundTree\VariablePendingInference.cs (1)
45type = TypeWithAnnotations.Create(binderOpt!.CreateErrorType("var"));
CodeGen\EmitArrayInitializer.cs (1)
649arrayType = arrayType.WithElementType(TypeWithAnnotations.Create(elementType.EnumUnderlyingTypeOrSelf()));
Compilation\CSharpCompilation.cs (5)
2380return ArrayTypeSymbol.CreateCSharpArray(this.Assembly, TypeWithAnnotations.Create(elementType, elementNullableAnnotation), rank); 2393return new PointerTypeSymbol(TypeWithAnnotations.Create(elementType, elementNullableAnnotation)); 4072var returnTypeWithAnnotations = TypeWithAnnotations.Create(returnType.EnsureCSharpSymbolOrNull(nameof(returnType)), returnType.NullableAnnotation.ToInternalAnnotation()); 4128typesBuilder.Add(TypeWithAnnotations.Create(elementType, annotation)); 4196fields.Add(new AnonymousTypeField(name, location, TypeWithAnnotations.Create(type, nullableAnnotation), RefKind.None, ScopedKind.None));
Compiler\MethodBodySynthesizer.cs (1)
434tmps[i] = new SynthesizedLocal(accessor, TypeWithAnnotations.Create(delegateType), SynthesizedLocalKind.LoweringTemp);
Emitter\Model\NamedTypeSymbolAdapter.cs (1)
495var type = TypeWithAnnotations.Create(@interface);
Emitter\Model\PEModuleBuilder.cs (2)
1579var byteArrayType = ArrayTypeSymbol.CreateSZArray(byteType.ContainingAssembly, TypeWithAnnotations.Create(byteType)); 1665var boolArray = ArrayTypeSymbol.CreateSZArray(booleanType.ContainingAssembly, TypeWithAnnotations.Create(booleanType));
Emitter\NoPia\EmbeddedType.cs (1)
137var type = TypeWithAnnotations.Create(@interface);
FlowAnalysis\NullableWalker.cs (36)
129LValueType = TypeWithAnnotations.Create(type, annotation); 3036type = TypeWithAnnotations.Create(node.Type, type.NullableAnnotation); 3759var resultType = TypeWithAnnotations.Create(node.Type); 4468return GetOrCreatePlaceholderSlot(node, TypeWithAnnotations.Create(node.Type, NullableAnnotation.NotAnnotated)); 4623: TypeWithAnnotations.Create(bestType); 4738var bestTypeWithObliviousAnnotation = TypeWithAnnotations.Create(bestType); 4750inferredType = TypeWithAnnotations.Create(bestType, BestTypeInferrer.GetNullableAnnotation(resultTypes)); 4801result = TypeWithAnnotations.Create(type); 4828type = TypeWithAnnotations.Create(((NamedTypeSymbol)node.Type).OriginalDefinition.Construct(ImmutableArray.Create(type))); 5119targetTypeWithNullability = TypeWithAnnotations.Create(MakeNullableOf(targetTypeWithNullability)); 5164TypeWithAnnotations.Create(expr.Type), 5568targetType = TypeWithAnnotations.Create(node.Type, NullableAnnotation.NotAnnotated); 5659TypeWithAnnotations.Create(rightType), 5697TypeWithAnnotations targetType = fromExplicitCast ? explicitType : TypeWithAnnotations.Create(boundConversion.Type); 5912var refResultTypeWithAnnotations = TypeWithAnnotations.Create(refResultType, lValueAnnotation); 5921SetResult(node, TypeWithState.Create(refResultType, rValueState), TypeWithAnnotations.Create(refResultType, lValueAnnotation)); 5993resultTypeWithAnnotations = TypeWithAnnotations.Create(resultType); 7077completion(TypeWithAnnotations.Create(argument.Type)); 7882return TypeWithAnnotations.Create(expr.GetTypeOrFunctionType(), GetNullableAnnotation(expr)); 8269TypeWithAnnotations targetType = fromExplicitCast ? explicitType : TypeWithAnnotations.Create(node.Type); 9362TypeWithAnnotations.Create(conversion.BestUserDefinedConversionAnalysis!.FromType), 9433TypeWithAnnotations.Create(conversion.BestUserDefinedConversionAnalysis!.ToType), 9730var argTypeWithAnnotations = TypeWithAnnotations.Create(argType, NullableAnnotation.NotAnnotated); 9917var lvalueResult = TypeWithAnnotations.Create(node.Type, NullableAnnotation.NotAnnotated); 10929targetTypeWithAnnotations = TypeWithAnnotations.Create(collectionExpression.Type); 10936targetTypeWithAnnotations = TypeWithAnnotations.Create(ForEachLoopBinder.GetIEnumerableOfT(resultType, isAsync, compilation, ref discardedUseSiteInfo, out bool foundMultiple, needSupportForRefStructInterfaces: out _)); 10987TypeWithAnnotations.Create(enumeratorInfoOpt.ElementType, NullableAnnotation.NotAnnotated).ToTypeWithState(); 11195var type = TypeWithAnnotations.Create(node.Type); 11296var type = TypeWithAnnotations.Create(node.Type); 11304var type = TypeWithAnnotations.Create(node.Type); 11326var type = TypeWithAnnotations.Create(node.Type, node.NullableAnnotation); 11654var result = TypeWithAnnotations.Create(node.Type); 11674var result = TypeWithAnnotations.Create(node.Type, NullableAnnotation.Oblivious); 11780var result = TypeWithAnnotations.Create(node.Type, NullableAnnotation.Oblivious); 11951var result = TypeWithAnnotations.Create(node.Type, node.IsInferred ? NullableAnnotation.Annotated : node.NullableAnnotation); 12048var typeWithAnnotations = TypeWithAnnotations.Create(node.Type, node.NullableAnnotation);
FlowAnalysis\NullableWalker_Patterns.cs (4)
476outputSlot = makeDagTempSlot(TypeWithAnnotations.Create(e.Type, NullableAnnotation.NotAnnotated), output); 688inferredType = TypeWithAnnotations.Create(inferredType.Type, existingType.NullableAnnotation.Join(inferredType.NullableAnnotation)); 839var type = TypeWithAnnotations.Create(t, NullableAnnotation.Annotated); 955var inferredTypeWithAnnotations = TypeWithAnnotations.Create(inferredType);
Lowering\AsyncRewriter\AsyncExceptionHandlerRewriter.cs (5)
187var pendingExceptionLocal = new SynthesizedLocal(_F.CurrentFunction, TypeWithAnnotations.Create(exceptionType), SynthesizedLocalKind.TryAwaitPendingException, tryStatementSyntax); 189var pendingBranchVar = new SynthesizedLocal(_F.CurrentFunction, TypeWithAnnotations.Create(_F.SpecialType(SpecialType.System_Int32)), SynthesizedLocalKind.TryAwaitPendingBranch, tryStatementSyntax); 1008this.returnValue = returnValue = new SynthesizedLocal(containingMethod, TypeWithAnnotations.Create(valueOpt.Type), SynthesizedLocalKind.AsyncMethodReturnValue, _syntaxOpt); 1044this.pendingCaughtException = new SynthesizedLocal(F.CurrentFunction, TypeWithAnnotations.Create(F.SpecialType(SpecialType.System_Object)), SynthesizedLocalKind.TryAwaitPendingCaughtException, tryStatementSyntax); 1045this.pendingCatch = new SynthesizedLocal(F.CurrentFunction, TypeWithAnnotations.Create(F.SpecialType(SpecialType.System_Int32)), SynthesizedLocalKind.TryAwaitPendingCatch, tryStatementSyntax);
Lowering\ClosureConversion\ClosureConversion.cs (1)
666LocalSymbol framePointer = new SynthesizedLocal(_topLevelMethod, TypeWithAnnotations.Create(frameType), SynthesizedLocalKind.LambdaDisplayClass, frame.ScopeSyntaxOpt);
Lowering\ClosureConversion\LambdaCapturedVariable.cs (1)
48return new LambdaCapturedVariable(frame, TypeWithAnnotations.Create(type), fieldName, IsThis(captured));
Lowering\Instrumentation\CodeCoverageInstrumenter.cs (2)
117_payloadType = ArrayTypeSymbol.CreateCSharpArray(methodBodyFactory.Compilation.Assembly, TypeWithAnnotations.Create(payloadElementType)); 253ArrayTypeSymbol.CreateCSharpArray(_methodBodyFactory.Compilation.Assembly, TypeWithAnnotations.Create(_payloadType));
Lowering\IteratorRewriter\IteratorFinallyMethodSymbol.cs (1)
147get { return TypeWithAnnotations.Create(ContainingAssembly.GetSpecialType(SpecialType.System_Void)); }
Lowering\LocalRewriter\LocalRewriter.PatternLocalRewriter.cs (1)
374var operandType = new PointerTypeSymbol(TypeWithAnnotations.Create(_factory.SpecialType(SpecialType.System_Void)));
Lowering\LocalRewriter\LocalRewriter_CollectionExpression.cs (3)
63return VisitArrayOrSpanCollectionExpression(node, collectionTypeKind, node.Type, TypeWithAnnotations.Create(elementType)); 576Construct(ImmutableArray.Create(TypeWithAnnotations.Create(inlineArrayType), elementType)); 605inlineArrayAsSpan = inlineArrayAsSpan.Construct(ImmutableArray.Create(TypeWithAnnotations.Create(inlineArrayType), elementType));
Lowering\LocalRewriter\LocalRewriter_Conversion.cs (1)
104var byteArray = ArrayTypeSymbol.CreateSZArray(_compilation.Assembly, TypeWithAnnotations.Create(byteType));
Lowering\LocalRewriter\LocalRewriter_DeconstructionAssignmentOperator.cs (1)
390var localSymbol = new SynthesizedLocal(_factory.CurrentFunction, TypeWithAnnotations.Create(outputPlaceholder.Type), SynthesizedLocalKind.LoweringTemp);
Lowering\MethodToClassRewriter.cs (1)
112newLocal = new TypeSubstitutedLocalSymbol(local, TypeWithAnnotations.Create(newType), CurrentMethod);
Lowering\StateMachineRewriter\StateMachineFieldSymbol.cs (1)
42this(stateMachineType, TypeWithAnnotations.Create(type), name, slotDebugInfo, slotIndex, isPublic)
Lowering\SyntheticBoundNodeFactory.cs (6)
181var result = new StateMachineFieldSymbol(CurrentType, TypeWithAnnotations.Create(type), name, isPublic, isThis); 595return new SynthesizedLocal(CurrentFunction, TypeWithAnnotations.Create(type), kind, syntax, isPinned, 615TypeWithAnnotations.Create(type), 626return SynthesizedParameterSymbol.Create(container, TypeWithAnnotations.Create(type), ordinal, RefKind.None, name); 1682TypeWithAnnotations.Create(type), 1721temp = new SynthesizedLocal(this.CurrentFunction, TypeWithAnnotations.Create(node.Type), SynthesizedLocalKind.LoweringTemp);
Symbols\AbstractTypeMap.cs (2)
125return TypeWithAnnotations.Create(result); 181return TypeWithAnnotations.Create(typeParameter);
Symbols\AbstractTypeParameterMap.cs (1)
36return TypeWithAnnotations.Create(typeParameter);
Symbols\AnonymousTypes\AnonymousTypeManager.Templates.cs (2)
236var original = TypeWithAnnotations.Create(genericFieldTypes[index].Type); 238var replacement = TypeWithAnnotations.Create(((ArrayTypeSymbol)lastParam.Type).WithElementType(original));
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.ConstructorSymbol.cs (1)
60get { return TypeWithAnnotations.Create(this.Manager.System_Void); }
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.DelegateTemplateSymbol.cs (5)
60new SynthesizedDelegateInvokeMethod.ParameterDescription(TypeWithAnnotations.Create(typeParams[i]), refKinds.IsNull ? RefKind.None : refKinds[i], ScopedKind.None, defaultValue: null, isParams: false, hasUnscopedRefAttribute: false)); 64var returnType = TypeWithAnnotations.Create(voidReturnTypeOpt ?? typeParams[parameterCount]); 130var type = TypeWithAnnotations.Create(typeParams[i]); 137type = TypeWithAnnotations.Create(ArrayTypeSymbol.CreateSZArray(containingType.ContainingAssembly, type)); 145var returnType = TypeWithAnnotations.Create(returnsVoid ? returnParameter.Type : typeParams[parameterCount]);
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.EqualsMethodSymbol.cs (2)
25SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(this.Manager.System_Object), 0, RefKind.None, "value")); 45get { return TypeWithAnnotations.Create(this.Manager.System_Boolean); }
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.GetHashCodeMethodSymbol.cs (1)
49get { return TypeWithAnnotations.Create(this.Manager.System_Int32); }
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.TemplateSymbol.cs (1)
63AnonymousTypePropertySymbol property = new AnonymousTypePropertySymbol(this, field, TypeWithAnnotations.Create(typeParameter), fieldIndex);
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousType.ToStringMethodSymbol.cs (1)
49get { return TypeWithAnnotations.Create(this.Manager.System_String, NullableAnnotation.NotAnnotated); }
Symbols\AssemblySymbol.cs (3)
767return ArrayTypeSymbol.CreateCSharpArray(this, TypeWithAnnotations.Create(symbol), rank); 777return new PointerTypeSymbol(TypeWithAnnotations.Create(symbol)); 880typeArgumentSymbols.Add(TypeWithAnnotations.Create(argSymbol));
Symbols\Compilation_WellKnownMembers.cs (1)
789var boolArray = ArrayTypeSymbol.CreateSZArray(booleanType.ContainingAssembly, TypeWithAnnotations.Create(booleanType));
Symbols\ErrorMethodSymbol.cs (1)
165get { return TypeWithAnnotations.Create(_returnType); }
Symbols\ErrorPropertySymbol.cs (1)
36_typeWithAnnotations = TypeWithAnnotations.Create(type);
Symbols\ErrorTypeSymbol.cs (1)
44return TypeWithAnnotations.Create(typeMap.SubstituteNamedType(this));
Symbols\FunctionPointers\FunctionPointerMethodSymbol.cs (1)
33returnType = TypeWithAnnotations.Create(typeBinder.CreateErrorType());
Symbols\Metadata\PE\PEEventSymbol.cs (2)
86_eventTypeWithAnnotations = TypeWithAnnotations.Create(new UnsupportedMetadataTypeSymbol(mrEx)); 101var type = TypeWithAnnotations.Create(typeSymbol);
Symbols\Metadata\PE\PEFieldSymbol.cs (3)
318var type = TypeWithAnnotations.Create(typeSymbol, customModifiers: customModifiersArray); 337type = TypeWithAnnotations.Create(new PointerTypeSymbol(TypeWithAnnotations.Create(fixedElementType)));
Symbols\Metadata\PE\PENamedTypeSymbol.cs (2)
521baseType = (NamedTypeSymbol)NullableTypeDecoder.TransformType(TypeWithAnnotations.Create(decodedType), _handle, moduleSymbol, accessSymbol: this, nullableContext: this).Type; 581typeSymbol = NullableTypeDecoder.TransformType(TypeWithAnnotations.Create(typeSymbol), interfaceImpl, moduleSymbol, accessSymbol: this, nullableContext: this).Type;
Symbols\Metadata\PE\PEParameterSymbol.cs (1)
390var typeWithModifiers = TypeWithAnnotations.Create(type, customModifiers: CSharpCustomModifier.Convert(customModifiers));
Symbols\Metadata\PE\PEPropertySymbol.cs (1)
303var propertyTypeWithAnnotations = TypeWithAnnotations.Create(originalPropertyType, customModifiers: typeCustomModifiers);
Symbols\Metadata\PE\SymbolFactory.cs (1)
170return TypeWithAnnotations.Create(type, NullableAnnotation.Oblivious, CSharpCustomModifier.Convert(customModifiers));
Symbols\Metadata\PE\TupleTypeDecoder.cs (3)
114return TypeWithAnnotations.Create(new UnsupportedMetadataTypeSymbol()); 121TypeWithAnnotations.Create(decoded, metadataType.NullableAnnotation, metadataType.CustomModifiers); 346TypeWithAnnotations.Create(decoded, typeWithAnnotations.NullableAnnotation, typeWithAnnotations.CustomModifiers);
Symbols\NullableAnnotationExtensions.cs (1)
104var flowState = TypeWithAnnotations.Create(type, annotation).ToTypeWithState().State;
Symbols\PlaceholderTypeArgumentSymbol.cs (1)
18private static readonly TypeWithAnnotations s_instance = TypeWithAnnotations.Create(new PlaceholderTypeArgumentSymbol());
Symbols\PublicModel\Symbol.cs (2)
25builder.Add(TypeWithAnnotations.Create(type, (typeArg?.NullableAnnotation.ToInternalAnnotation() ?? NullableAnnotation.NotAnnotated))); 49builder.Add(TypeWithAnnotations.Create(type, annotation));
Symbols\ReducedExtensionMethodSymbol.cs (1)
190builder.Add(TypeWithAnnotations.Create(ErrorTypeSymbol.UnknownResultType));
Symbols\Retargeting\RetargetingPropertySymbol.cs (1)
72type = TypeWithAnnotations.Create(asDynamic);
Symbols\Source\GlobalExpressionVariable.cs (1)
113type = TypeWithAnnotations.Create(binder.CreateErrorType("var"));
Symbols\Source\IndexedTypeParameterSymbol.cs (1)
113builder.Add(TypeWithAnnotations.Create(GetTypeParameter(i), NullableAnnotation.Ignored));
Symbols\Source\LambdaSymbol.cs (2)
62_returnType = !returnType.HasType ? TypeWithAnnotations.Create(ReturnTypeIsBeingInferred) : returnType; 373type = TypeWithAnnotations.Create(new ExtendedErrorTypeSymbol(compilation, name: string.Empty, arity: 0, errorInfo: null));
Symbols\Source\LocalFunctionOrSourceMemberMethodSymbol.cs (1)
33elementType = TypeWithAnnotations.Create(new ExtendedErrorTypeSymbol(DeclaringCompilation, name: "", arity: 0, errorInfo: null, unreported: false));
Symbols\Source\SourceConstructorSymbolBase.cs (1)
58_lazyReturnType = TypeWithAnnotations.Create(bodyBinder.GetSpecialType(SpecialType.System_Void, diagnostics, syntax));
Symbols\Source\SourceDelegateMethodSymbol.cs (5)
59var voidType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_Void, diagnostics, syntax)); 61var objectType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_Object, diagnostics, syntax)); 62var intPtrType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_IntPtr, diagnostics, syntax)); 84var iAsyncResultType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_IAsyncResult, diagnostics, syntax)); 85var asyncCallbackType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_AsyncCallback, diagnostics, syntax));
Symbols\Source\SourceDestructorSymbol.cs (1)
85_lazyReturnType = TypeWithAnnotations.Create(bodyBinder.GetSpecialType(SpecialType.System_Void, diagnostics, syntax));
Symbols\Source\SourceEnumConstantSymbol.cs (1)
62return TypeWithAnnotations.Create(this.ContainingType);
Symbols\Source\SourceEventAccessorSymbol.cs (3)
122_lazyReturnType = TypeWithAnnotations.Create(eventTokenType); 133_lazyReturnType = TypeWithAnnotations.Create(voidType); 144_lazyReturnType = TypeWithAnnotations.Create(voidType);
Symbols\Source\SourceLocalSymbol.cs (4)
371declType = TypeWithAnnotations.Create(typeBinder.CreateErrorType("var")); 564return TypeWithAnnotations.Create(initializerOpt?.Type); 698return TypeWithAnnotations.Create(_nodeBinder.CreateErrorType()); 813SetTypeWithAnnotations(TypeWithAnnotations.Create(_nodeBinder.CreateErrorType("var")));
Symbols\Source\SourceMemberContainerSymbol.cs (7)
4338TypeWithAnnotations.Create(this), 4387TypeWithAnnotations.Create(compilation.GetWellKnownType(WellKnownType.System_Text_StringBuilder)), 4653TypeWithAnnotations.Create(compilation.GetWellKnownType(WellKnownType.System_Type)), 4714TypeWithAnnotations.Create(this), 5286builder.AddValue(TypeWithAnnotations.Create(baseType)); 5290builder.AddValue(TypeWithAnnotations.Create(@interface)); 5350AddSynthesizedAttribute(ref attributes, moduleBuilder.SynthesizeNullableAttributeIfNecessary(this, nullableContextValue, TypeWithAnnotations.Create(baseType)));
Symbols\Source\SourceMemberFieldSymbol.cs (4)
473type = TypeWithAnnotations.Create(tokenTableType.Construct(ImmutableArray.Create(@event.TypeWithAnnotations))); 545type = TypeWithAnnotations.Create(initializerOpt.Type); 554type = TypeWithAnnotations.Create(binder.CreateErrorType("var")); 561type = TypeWithAnnotations.Create(new PointerTypeSymbol(type));
Symbols\Source\SourceNamedTypeSymbol_Bases.cs (1)
349return TypeWithAnnotations.Create(type).VisitType(
Symbols\Source\SourcePropertyAccessorSymbol.cs (1)
387var type = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_Void, diagnostics, this.GetSyntax()));
Symbols\Source\ThisParameterSymbol.cs (1)
141=> TypeWithAnnotations.Create(_containingType, NullableAnnotation.NotAnnotated);
Symbols\SymbolExtensions.cs (1)
530returnType = TypeWithAnnotations.Create((TypeSymbol)symbol);
Symbols\Synthesized\ReadOnlyListType\SynthesizedReadOnlyListConstructor.cs (1)
15SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(parameterType), ordinal: 0, RefKind.None, parameterName));
Symbols\Synthesized\ReadOnlyListType\SynthesizedReadOnlyListEnumeratorConstructor.cs (1)
15SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(parameterType), ordinal: 0, RefKind.None, "item"));
Symbols\Synthesized\Records\SynthesizedRecordBaseEquals.cs (2)
29return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 32TypeWithAnnotations.Create(ContainingType.BaseTypeNoUseSiteDiagnostics, NullableAnnotation.Annotated),
Symbols\Synthesized\Records\SynthesizedRecordDeconstruct.cs (1)
35return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Void, location, diagnostics)),
Symbols\Synthesized\Records\SynthesizedRecordEqualityContractProperty.cs (1)
82return (TypeWithAnnotations.Create(Binder.GetWellKnownType(DeclaringCompilation, WellKnownType.System_Type, diagnostics, Location), NullableAnnotation.NotAnnotated),
Symbols\Synthesized\Records\SynthesizedRecordEqualityOperatorBase.cs (3)
69return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 72TypeWithAnnotations.Create(ContainingType, annotation), 75TypeWithAnnotations.Create(ContainingType, annotation),
Symbols\Synthesized\Records\SynthesizedRecordEquals.cs (2)
37return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 40TypeWithAnnotations.Create(ContainingType, annotation),
Symbols\Synthesized\Records\SynthesizedRecordGetHashCode.cs (1)
34return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Int32, location, diagnostics)),
Symbols\Synthesized\Records\SynthesizedRecordObjEquals.cs (2)
32return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 35TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Object, location, diagnostics), annotation),
Symbols\Synthesized\Records\SynthesizedRecordPrintMembers.cs (2)
94return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 97TypeWithAnnotations.Create(Binder.GetWellKnownType(compilation, WellKnownType.System_Text_StringBuilder, diagnostics, location), annotation),
Symbols\Synthesized\Records\SynthesizedRecordToString.cs (1)
43return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_String, location, diagnostics), annotation),
Symbols\Synthesized\SynthesizedAccessorValueParameterSymbol.cs (1)
136return TypeWithAnnotations.Create(eventTokenType);
Symbols\Synthesized\SynthesizedDelegateSymbol.cs (2)
21SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(objectType), 0, RefKind.None, "object"), 22SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(intPtrType), 1, RefKind.None, "method"));
Symbols\Synthesized\SynthesizedEmbeddedNativeIntegerAttributeSymbol.cs (2)
32var boolArrayType = TypeWithAnnotations.Create( 35TypeWithAnnotations.Create(boolType)));
Symbols\Synthesized\SynthesizedEmbeddedNullableAttributeSymbol.cs (2)
34var annotatedByteType = TypeWithAnnotations.Create(systemByteType); 36var byteArrayType = TypeWithAnnotations.Create(
Symbols\Synthesized\SynthesizedEmbeddedNullableContextAttributeSymbol.cs (1)
41m => ImmutableArray.Create(SynthesizedParameterSymbol.Create(m, TypeWithAnnotations.Create(systemByteType), 0, RefKind.None)),
Symbols\Synthesized\SynthesizedEmbeddedNullablePublicOnlyAttributeSymbol.cs (1)
41m => ImmutableArray.Create(SynthesizedParameterSymbol.Create(m, TypeWithAnnotations.Create(systemBooleanType), 0, RefKind.None)),
Symbols\Synthesized\SynthesizedEmbeddedRefSafetyRulesAttributeSymbol.cs (1)
39m => ImmutableArray.Create(SynthesizedParameterSymbol.Create(m, TypeWithAnnotations.Create(int32Type), 0, RefKind.None)),
Symbols\Synthesized\SynthesizedEntryPointSymbol.cs (5)
44return new ScriptEntryPoint(containingType, TypeWithAnnotations.Create(systemVoid)); 392public override TypeWithAnnotations ReturnTypeWithAnnotations => TypeWithAnnotations.Create(_getAwaiterGetResultCall.Type); 484new SynthesizedLocal(this, TypeWithAnnotations.Create(_containingType), SynthesizedLocalKind.LoweringTemp), 541TypeWithAnnotations.Create(submissionArrayType), 0, RefKind.None, "submissionArray")); 576new SynthesizedLocal(this, TypeWithAnnotations.Create(_containingType), SynthesizedLocalKind.LoweringTemp),
Symbols\Synthesized\SynthesizedEnumValueFieldSymbol.cs (1)
35return TypeWithAnnotations.Create(((SourceNamedTypeSymbol)ContainingType).EnumUnderlyingType);
Symbols\Synthesized\SynthesizedFieldSymbol.cs (1)
33_type = TypeWithAnnotations.Create(type);
Symbols\Synthesized\SynthesizedGlobalMethodSymbol.cs (1)
211get { return TypeWithAnnotations.Create(_returnType); }
Symbols\Synthesized\SynthesizedHotReloadExceptionConstructorSymbol.cs (2)
19SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(stringType), ordinal: 0, RefKind.None), 20SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(intType), ordinal: 1, RefKind.None)
Symbols\Synthesized\SynthesizedInlineArrayAsReadOnlySpanMethod.cs (2)
17this.SetParameters(ImmutableArray.Create<ParameterSymbol>(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(TypeParameters[0]), 0, RefKind.In, "buffer"), 18SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(intType), 1, RefKind.None, "length")));
Symbols\Synthesized\SynthesizedInlineArrayAsSpanMethod.cs (2)
17this.SetParameters(ImmutableArray.Create<ParameterSymbol>(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(TypeParameters[0]), 0, RefKind.Ref, "buffer"), 18SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(intType), 1, RefKind.None, "length")));
Symbols\Synthesized\SynthesizedInlineArrayElementRefMethod.cs (2)
17this.SetParameters(ImmutableArray.Create<ParameterSymbol>(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(TypeParameters[0]), 0, RefKind.Ref, "buffer"), 18SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(intType), 1, RefKind.None, "index")));
Symbols\Synthesized\SynthesizedInlineArrayElementRefReadOnlyMethod.cs (2)
17this.SetParameters(ImmutableArray.Create<ParameterSymbol>(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(TypeParameters[0]), 0, RefKind.In, "buffer"), 18SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(intType), 1, RefKind.None, "index")));
Symbols\Synthesized\SynthesizedInlineArrayFirstElementRefMethod.cs (1)
17this.SetParameters(ImmutableArray.Create<ParameterSymbol>(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(TypeParameters[0]), 0, RefKind.Ref, "buffer")));
Symbols\Synthesized\SynthesizedInlineArrayFirstElementRefReadOnlyMethod.cs (1)
17this.SetParameters(ImmutableArray.Create<ParameterSymbol>(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(TypeParameters[0]), 0, RefKind.In, "buffer")));
Symbols\Synthesized\SynthesizedInstanceConstructor.cs (1)
156get { return TypeWithAnnotations.Create(ContainingAssembly.GetSpecialType(SpecialType.System_Void)); }
Symbols\Synthesized\SynthesizedInteractiveInitializerMethod.cs (1)
146get { return TypeWithAnnotations.Create(_returnType); }
Symbols\Synthesized\SynthesizedIntrinsicOperatorSymbol.cs (2)
228return TypeWithAnnotations.Create(_returnType); 468) : base(container, TypeWithAnnotations.Create(type), ordinal, RefKind.None, ScopedKind.None, name)
Symbols\Synthesized\SynthesizedLambdaCacheFieldSymbol.cs (1)
24_type = TypeWithAnnotations.Create(type);
Symbols\Synthesized\SynthesizedSimpleProgramEntryPointSymbol.cs (3)
57TypeWithAnnotations.Create( 59TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_String, NoLocation.Singleton, diagnostics)))), 0, RefKind.None, "args")); 159return TypeWithAnnotations.Create(_returnType);
Symbols\Synthesized\SynthesizedStaticConstructor.cs (1)
139return TypeWithAnnotations.Create(ContainingAssembly.GetSpecialType(SpecialType.System_Void));
Symbols\Synthesized\SynthesizedStringHashFunctionSymbol.cs (2)
21this.SetParameters(ImmutableArray.Create<ParameterSymbol>(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(paramType), 0, RefKind.None, "s"))); 31this.SetParameters(ImmutableArray.Create<ParameterSymbol>(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(paramType), 0, RefKind.None, "s")));
Symbols\Synthesized\SynthesizedThrowSwitchExpressionExceptionMethod.cs (1)
19this.SetParameters(ImmutableArray.Create(SynthesizedParameterSymbol.Create(this, TypeWithAnnotations.Create(paramType), 0, RefKind.None, "unmatchedValue")));
Symbols\Tuples\TupleTypeSymbol.cs (1)
244var chainedTypes = ImmutableArray.Create(elementTypes, (loop - 1) * (ValueTupleRestPosition - 1), ValueTupleRestPosition - 1).Add(TypeWithAnnotations.Create(currentSymbol));
Symbols\TypeMap.cs (1)
130result.Mapping.Add(tp, TypeWithAnnotations.Create(newTp));
Symbols\TypeSymbolExtensions.cs (1)
1957typeWithAnnotations = TypeWithAnnotations.Create(type, customModifiers: typeWithAnnotations.CustomModifiers);
Symbols\TypeUnification.cs (7)
30var substituted1 = SubstituteAllTypeParameters(substitution, TypeWithAnnotations.Create(t1)); 31var substituted2 = SubstituteAllTypeParameters(substitution, TypeWithAnnotations.Create(t2)); 59return CanUnifyHelper(TypeWithAnnotations.Create(t1), TypeWithAnnotations.Create(t2), ref substitution); 207AddSubstitution(ref substitution, tp1, TypeWithAnnotations.Create(t2.Type)); 215TypeWithAnnotations.Create(t2.Type, 234TypeWithAnnotations.Create(t1.Type,
Symbols\TypeWithAnnotations.cs (7)
82return Create(typeSymbol, nullableAnnotation: isAnnotated ? NullableAnnotation.Annotated : isNullableEnabled ? NullableAnnotation.NotAnnotated : NullableAnnotation.Oblivious); 115return Create(Type, NullableAnnotation.Annotated, CustomModifiers); 125return Create(Type, NullableAnnotation.NotAnnotated, CustomModifiers); 247return Create(type, nullableAnnotation, CustomModifiers); 465return Create(newTypeWithModifiers.Type, NullableAnnotation, newCustomModifiers); 1122return TypeWithAnnotations.Create(resolvedType, type.NullableAnnotation, customModifiers: customModifiers); 1132return TypeWithAnnotations.Create(typeSymbol, type.NullableAnnotation, customModifiers: customModifiers);
Symbols\TypeWithState.cs (2)
89var type = TypeWithAnnotations.Create(Type, NullableAnnotation.NotAnnotated); 95return TypeWithAnnotations.Create(this.Type, annotation);
Symbols\UnboundGenericType.cs (1)
55result.Add(TypeWithAnnotations.Create(new UnboundArgumentErrorTypeSymbol(name, errorInfo)));