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)
Compilation\CSharpCompilation.cs (5)
2380return ArrayTypeSymbol.CreateCSharpArray(this.Assembly, TypeWithAnnotations.Create(elementType, elementNullableAnnotation), rank);
2393return new PointerTypeSymbol(TypeWithAnnotations.Create(elementType, elementNullableAnnotation));
4092var returnTypeWithAnnotations = TypeWithAnnotations.Create(returnType.EnsureCSharpSymbolOrNull(nameof(returnType)), returnType.NullableAnnotation.ToInternalAnnotation());
4148typesBuilder.Add(TypeWithAnnotations.Create(elementType, annotation));
4216fields.Add(new AnonymousTypeField(name, location, TypeWithAnnotations.Create(type, nullableAnnotation), RefKind.None, ScopedKind.None));
FlowAnalysis\NullableWalker.cs (36)
129LValueType = TypeWithAnnotations.Create(type, annotation);
3097type = TypeWithAnnotations.Create(node.Type, type.NullableAnnotation);
3820var resultType = TypeWithAnnotations.Create(node.Type);
4529return GetOrCreatePlaceholderSlot(node, TypeWithAnnotations.Create(node.Type, NullableAnnotation.NotAnnotated));
4684: TypeWithAnnotations.Create(bestType);
4799var bestTypeWithObliviousAnnotation = TypeWithAnnotations.Create(bestType);
4811inferredType = TypeWithAnnotations.Create(bestType, BestTypeInferrer.GetNullableAnnotation(resultTypes));
4862result = TypeWithAnnotations.Create(type);
4889type = TypeWithAnnotations.Create(((NamedTypeSymbol)node.Type).OriginalDefinition.Construct(ImmutableArray.Create(type)));
5180targetTypeWithNullability = TypeWithAnnotations.Create(MakeNullableOf(targetTypeWithNullability));
5225TypeWithAnnotations.Create(expr.Type),
5629targetType = TypeWithAnnotations.Create(node.Type, NullableAnnotation.NotAnnotated);
5720TypeWithAnnotations.Create(rightType),
5758TypeWithAnnotations targetType = fromExplicitCast ? explicitType : TypeWithAnnotations.Create(boundConversion.Type);
5973var refResultTypeWithAnnotations = TypeWithAnnotations.Create(refResultType, lValueAnnotation);
5982SetResult(node, TypeWithState.Create(refResultType, rValueState), TypeWithAnnotations.Create(refResultType, lValueAnnotation));
6054resultTypeWithAnnotations = TypeWithAnnotations.Create(resultType);
7138completion(TypeWithAnnotations.Create(argument.Type));
7943return TypeWithAnnotations.Create(expr.GetTypeOrFunctionType(), GetNullableAnnotation(expr));
8330TypeWithAnnotations targetType = fromExplicitCast ? explicitType : TypeWithAnnotations.Create(node.Type);
9423TypeWithAnnotations.Create(conversion.BestUserDefinedConversionAnalysis!.FromType),
9494TypeWithAnnotations.Create(conversion.BestUserDefinedConversionAnalysis!.ToType),
9791var argTypeWithAnnotations = TypeWithAnnotations.Create(argType, NullableAnnotation.NotAnnotated);
9978var lvalueResult = TypeWithAnnotations.Create(node.Type, NullableAnnotation.NotAnnotated);
10990targetTypeWithAnnotations = TypeWithAnnotations.Create(collectionExpression.Type);
10997targetTypeWithAnnotations = TypeWithAnnotations.Create(ForEachLoopBinder.GetIEnumerableOfT(resultType, isAsync, compilation, ref discardedUseSiteInfo, out bool foundMultiple, needSupportForRefStructInterfaces: out _));
11048TypeWithAnnotations.Create(enumeratorInfoOpt.ElementType, NullableAnnotation.NotAnnotated).ToTypeWithState();
11256var type = TypeWithAnnotations.Create(node.Type);
11357var type = TypeWithAnnotations.Create(node.Type);
11365var type = TypeWithAnnotations.Create(node.Type);
11387var type = TypeWithAnnotations.Create(node.Type, node.NullableAnnotation);
11715var result = TypeWithAnnotations.Create(node.Type);
11735var result = TypeWithAnnotations.Create(node.Type, NullableAnnotation.Oblivious);
11841var result = TypeWithAnnotations.Create(node.Type, NullableAnnotation.Oblivious);
12012var result = TypeWithAnnotations.Create(node.Type, node.IsInferred ? NullableAnnotation.Annotated : node.NullableAnnotation);
12109var typeWithAnnotations = TypeWithAnnotations.Create(node.Type, node.NullableAnnotation);
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\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\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\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\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);