8865 references to SpecialType
Microsoft.CodeAnalysis (1635)
CodeGen\PermissionSetAttribute.cs (1)
86member => member.Kind == SymbolKind.Property && ((IPropertySymbol)member).Type.SpecialType == SpecialType.System_String));
CommandLine\SarifV2ErrorLogger.cs (1)
77string? justification = suppressionInfo?.Attribute?.DecodeNamedArgument<string>("Justification", SpecialType.System_String);
Compilation\Compilation.cs (4)
949public INamedTypeSymbol GetSpecialType(SpecialType specialType) 964private protected abstract INamedTypeSymbolInternal CommonGetSpecialType(SpecialType specialType); 3651internal void MakeTypeMissing(SpecialType type) 3671internal bool IsTypeMissing(SpecialType type)
Compilation\Expression.cs (13)
13case SpecialType.System_Int32: 15case SpecialType.System_Int64: 17case SpecialType.System_UInt32: 19case SpecialType.System_UInt64: 21case SpecialType.System_UInt16: 23case SpecialType.System_Int16: 25case SpecialType.System_SByte: 27case SpecialType.System_Byte: 29case SpecialType.System_Char: 31case SpecialType.System_Boolean: 33case SpecialType.System_Single: 35case SpecialType.System_Double: 37case SpecialType.System_Object:
ConstantValue.cs (41)
42internal abstract SpecialType SpecialType { get; } 349public static ConstantValue Create(object value, SpecialType st) 356public static ConstantValue CreateSizeOf(SpecialType st) 395public static ConstantValue Default(SpecialType st) 432internal static ConstantValueTypeDiscriminator GetDiscriminator(SpecialType st) 436case SpecialType.System_SByte: return ConstantValueTypeDiscriminator.SByte; 437case SpecialType.System_Byte: return ConstantValueTypeDiscriminator.Byte; 438case SpecialType.System_Int16: return ConstantValueTypeDiscriminator.Int16; 439case SpecialType.System_UInt16: return ConstantValueTypeDiscriminator.UInt16; 440case SpecialType.System_Int32: return ConstantValueTypeDiscriminator.Int32; 441case SpecialType.System_UInt32: return ConstantValueTypeDiscriminator.UInt32; 442case SpecialType.System_Int64: return ConstantValueTypeDiscriminator.Int64; 443case SpecialType.System_UInt64: return ConstantValueTypeDiscriminator.UInt64; 444case SpecialType.System_IntPtr: return ConstantValueTypeDiscriminator.NInt; 445case SpecialType.System_UIntPtr: return ConstantValueTypeDiscriminator.NUInt; 446case SpecialType.System_Char: return ConstantValueTypeDiscriminator.Char; 447case SpecialType.System_Boolean: return ConstantValueTypeDiscriminator.Boolean; 448case SpecialType.System_Single: return ConstantValueTypeDiscriminator.Single; 449case SpecialType.System_Double: return ConstantValueTypeDiscriminator.Double; 450case SpecialType.System_Decimal: return ConstantValueTypeDiscriminator.Decimal; 451case SpecialType.System_DateTime: return ConstantValueTypeDiscriminator.DateTime; 452case SpecialType.System_String: return ConstantValueTypeDiscriminator.String; 484private static SpecialType GetSpecialType(ConstantValueTypeDiscriminator discriminator) 488case ConstantValueTypeDiscriminator.SByte: return SpecialType.System_SByte; 489case ConstantValueTypeDiscriminator.Byte: return SpecialType.System_Byte; 490case ConstantValueTypeDiscriminator.Int16: return SpecialType.System_Int16; 491case ConstantValueTypeDiscriminator.UInt16: return SpecialType.System_UInt16; 492case ConstantValueTypeDiscriminator.Int32: return SpecialType.System_Int32; 493case ConstantValueTypeDiscriminator.UInt32: return SpecialType.System_UInt32; 494case ConstantValueTypeDiscriminator.Int64: return SpecialType.System_Int64; 495case ConstantValueTypeDiscriminator.UInt64: return SpecialType.System_UInt64; 496case ConstantValueTypeDiscriminator.NInt: return SpecialType.System_IntPtr; 497case ConstantValueTypeDiscriminator.NUInt: return SpecialType.System_UIntPtr; 498case ConstantValueTypeDiscriminator.Char: return SpecialType.System_Char; 499case ConstantValueTypeDiscriminator.Boolean: return SpecialType.System_Boolean; 500case ConstantValueTypeDiscriminator.Single: return SpecialType.System_Single; 501case ConstantValueTypeDiscriminator.Double: return SpecialType.System_Double; 502case ConstantValueTypeDiscriminator.Decimal: return SpecialType.System_Decimal; 503case ConstantValueTypeDiscriminator.DateTime: return SpecialType.System_DateTime; 504case ConstantValueTypeDiscriminator.String: return SpecialType.System_String; 505default: return SpecialType.None;
ConstantValueSpecialized.cs (11)
42internal override SpecialType SpecialType 44get { return SpecialType.None; } 83internal override SpecialType SpecialType 85get { return SpecialType.None; } 167internal override SpecialType SpecialType 169get { return SpecialType.System_String; } 246internal override SpecialType SpecialType 248get { return SpecialType.System_Decimal; } 287internal override SpecialType SpecialType 289get { return SpecialType.System_DateTime; } 330internal override SpecialType SpecialType
DiagnosticAnalyzer\SuppressMessageAttributeState.cs (3)
397info.Scope = attribute.DecodeNamedArgument<string>("Scope", SpecialType.System_String); 398info.Target = attribute.DecodeNamedArgument<string>("Target", SpecialType.System_String); 399info.MessageId = attribute.DecodeNamedArgument<string>("MessageId", SpecialType.System_String);
Emit\CommonPEModuleBuilder.cs (8)
590internal abstract Cci.INamedTypeReference GetSpecialType(SpecialType specialType, TSyntaxNode syntaxNodeOpt, DiagnosticBag diagnostics); 1035this.GetSpecialType(SpecialType.System_Object, syntaxNodeOpt, diagnostics), 1036this.GetSpecialType(SpecialType.System_ValueType, syntaxNodeOpt, diagnostics), 1037this.GetSpecialType(SpecialType.System_Byte, syntaxNodeOpt, diagnostics), 1038this.GetSpecialType(SpecialType.System_Int16, syntaxNodeOpt, diagnostics), 1039this.GetSpecialType(SpecialType.System_Int32, syntaxNodeOpt, diagnostics), 1040this.GetSpecialType(SpecialType.System_Int64, syntaxNodeOpt, diagnostics), 1074return GetSpecialType((SpecialType)platformType, (TSyntaxNode)context.SyntaxNode, context.Diagnostics);
InternalUtilities\EnumUtilties.cs (9)
19internal static ulong ConvertEnumUnderlyingTypeToUInt64(object value, SpecialType specialType) 28case SpecialType.System_SByte: 30case SpecialType.System_Int16: 32case SpecialType.System_Int32: 34case SpecialType.System_Int64: 36case SpecialType.System_Byte: 38case SpecialType.System_UInt16: 40case SpecialType.System_UInt32: 42case SpecialType.System_UInt64:
MemberDescriptor.cs (2)
53return DeclaringTypeId <= (int)SpecialType.Count 54? ((SpecialType)DeclaringTypeId).GetMetadataName()!
MetadataReader\MetadataDecoder.cs (5)
1010if (type.SpecialType == SpecialType.System_Decimal) 1014else if (type.SpecialType == SpecialType.System_DateTime) 1033var specialType = typeCode.ToSpecialType(); 1341type = GetSpecialType(SpecialType.System_Object); 1434type = GetSpecialType(SpecialType.System_Object);
MetadataReader\MetadataTypeCodeExtensions.cs (53)
14internal static SpecialType ToSpecialType(this SignatureTypeCode typeCode) 19return SpecialType.System_TypedReference; 22return SpecialType.System_Void; 25return SpecialType.System_Boolean; 28return SpecialType.System_SByte; 31return SpecialType.System_Byte; 34return SpecialType.System_Int16; 37return SpecialType.System_UInt16; 40return SpecialType.System_Int32; 43return SpecialType.System_UInt32; 46return SpecialType.System_Int64; 49return SpecialType.System_UInt64; 52return SpecialType.System_Single; 55return SpecialType.System_Double; 58return SpecialType.System_Char; 61return SpecialType.System_String; 64return SpecialType.System_IntPtr; 67return SpecialType.System_UIntPtr; 70return SpecialType.System_Object; 77internal static bool HasShortFormSignatureEncoding(this SpecialType type) 105case SpecialType.System_String: 106case SpecialType.System_Object: 107case SpecialType.System_Void: 108case SpecialType.System_Boolean: 109case SpecialType.System_Char: 110case SpecialType.System_Byte: 111case SpecialType.System_SByte: 112case SpecialType.System_Int16: 113case SpecialType.System_UInt16: 114case SpecialType.System_Int32: 115case SpecialType.System_UInt32: 116case SpecialType.System_Int64: 117case SpecialType.System_UInt64: 118case SpecialType.System_IntPtr: 119case SpecialType.System_UIntPtr: 120case SpecialType.System_TypedReference: 121case SpecialType.System_Single: 122case SpecialType.System_Double: 129internal static SerializationTypeCode ToSerializationType(this SpecialType specialType) 133case SpecialType.System_Boolean: 136case SpecialType.System_SByte: 139case SpecialType.System_Byte: 142case SpecialType.System_Int16: 145case SpecialType.System_Int32: 148case SpecialType.System_Int64: 151case SpecialType.System_UInt16: 154case SpecialType.System_UInt32: 157case SpecialType.System_UInt64: 160case SpecialType.System_Single: 163case SpecialType.System_Double: 166case SpecialType.System_Char: 169case SpecialType.System_String: 172case SpecialType.System_Object:
MetadataReader\SymbolFactory.cs (1)
44internal abstract TypeSymbol GetSpecialType(ModuleSymbol moduleSymbol, SpecialType specialType);
MetadataReader\TypeNameDecoder.cs (1)
85protected TypeSymbol GetSpecialType(SpecialType specialType)
Operations\ControlFlowGraphBuilder.cs (21)
2394INamedTypeSymbol booleanType = _compilation.GetSpecialType(SpecialType.System_Boolean); 2452INamedTypeSymbol booleanType = _compilation.GetSpecialType(SpecialType.System_Boolean); 2553INamedTypeSymbol booleanType = _compilation.GetSpecialType(SpecialType.System_Boolean); 3112if (operation.Target?.Type?.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T && 3292return MakeIsNullOperation(operand, _compilation.GetSpecialType(SpecialType.System_Boolean)); 3945: _compilation.GetSpecialType(SpecialType.System_IDisposable); 4165return new AwaitOperation(invocation, semanticModel: null, value.Syntax, _compilation.GetSpecialType(SpecialType.System_Void), isImplicit: true); 4182Debug.Assert(iDisposable.SpecialType == SpecialType.System_IDisposable || 4192ITypeSymbol objectType = _compilation.GetSpecialType(SpecialType.System_Object); 4458: _compilation.GetSpecialType(SpecialType.System_IDisposable); 4525return new AwaitOperation(moveNext, semanticModel: null, operation.Syntax, _compilation.GetSpecialType(SpecialType.System_Boolean), isImplicit: true); 4532return MakeInvalidOperation(_compilation.GetSpecialType(SpecialType.System_Boolean), enumeratorRef); 4645ITypeSymbol booleanType = _compilation.GetSpecialType(SpecialType.System_Boolean); 5065_compilation.GetSpecialType(SpecialType.System_Boolean), 5146var shiftConst = new LiteralOperation(semanticModel: null, operand.Syntax, _compilation.GetSpecialType(SpecialType.System_Int32), 5248_compilation.GetSpecialType(SpecialType.System_Boolean), 5369INamedTypeSymbol booleanType = _compilation.GetSpecialType(SpecialType.System_Boolean); 5735ITypeSymbol booleanType = _compilation.GetSpecialType(SpecialType.System_Boolean); 6587Debug.Assert(outParameterArgument is { Parameter: { RefKind: RefKind.Out, Type.SpecialType: SpecialType.System_Boolean } }); 7474INamedTypeSymbol booleanType = _compilation.GetSpecialType(SpecialType.System_Boolean); 7529? MakeInvalidOperation(operation.Syntax, type: _compilation.GetSpecialType(SpecialType.System_Object), ImmutableArray<IOperation>.Empty)
PEWriter\Types.cs (6)
18SystemObject = CodeAnalysis.SpecialType.System_Object, 19SystemDecimal = CodeAnalysis.SpecialType.System_Decimal, 20SystemTypedReference = CodeAnalysis.SpecialType.System_TypedReference, 22SystemInt32 = CodeAnalysis.SpecialType.System_Int32, 23SystemVoid = CodeAnalysis.SpecialType.System_Void, 24SystemString = CodeAnalysis.SpecialType.System_String,
SpecialMembers.cs (394)
21(byte)SpecialType.System_String, // DeclaringTypeId 24(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 25(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 29(byte)SpecialType.System_String, // DeclaringTypeId 32(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 33(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 34(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 38(byte)SpecialType.System_String, // DeclaringTypeId 41(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 42(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 43(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 44(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 48(byte)SpecialType.System_String, // DeclaringTypeId 51(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 52(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 53(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 54(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 55(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 59(byte)SpecialType.System_String, // DeclaringTypeId 62(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 63(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 67(byte)SpecialType.System_String, // DeclaringTypeId 70(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 71(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 75(byte)SpecialType.System_String, // DeclaringTypeId 78(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 79(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 80(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 84(byte)SpecialType.System_String, // DeclaringTypeId 87(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 88(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 89(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 90(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 94(byte)SpecialType.System_String, // DeclaringTypeId 97(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 98(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 102(byte)SpecialType.System_String, // DeclaringTypeId 105(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 106(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 107(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 111(byte)SpecialType.System_String, // DeclaringTypeId 114(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 115(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 116(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 120(byte)SpecialType.System_String, // DeclaringTypeId 123(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 127(byte)SpecialType.System_String, // DeclaringTypeId 130(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 131(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 135(byte)SpecialType.System_String, // DeclaringTypeId 138(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 139(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 140(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 144(byte)SpecialType.System_String, // DeclaringTypeId 147(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 148(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 149(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 153(byte)SpecialType.System_Double, // DeclaringTypeId 156(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 157(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 161(byte)SpecialType.System_Single, // DeclaringTypeId 164(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 165(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 169(byte)SpecialType.System_Delegate, // DeclaringTypeId 172(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 173(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 174(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 178(byte)SpecialType.System_Delegate, // DeclaringTypeId 181(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 182(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 183(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 187(byte)SpecialType.System_Delegate, // DeclaringTypeId 190(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 191(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 192(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 196(byte)SpecialType.System_Delegate, // DeclaringTypeId 199(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 200(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 201(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 205(byte)SpecialType.System_Decimal, // DeclaringTypeId 207(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, // Field Signature 211(byte)SpecialType.System_Decimal, // DeclaringTypeId 213(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, // Field Signature 217(byte)SpecialType.System_Decimal, // DeclaringTypeId 219(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, // Field Signature 223(byte)SpecialType.System_Decimal, // DeclaringTypeId 226(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 227(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 231(byte)SpecialType.System_Decimal, // DeclaringTypeId 234(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 235(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 239(byte)SpecialType.System_Decimal, // DeclaringTypeId 242(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 243(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 247(byte)SpecialType.System_Decimal, // DeclaringTypeId 250(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 251(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, 255(byte)SpecialType.System_Decimal, // DeclaringTypeId 258(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 259(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 263(byte)SpecialType.System_Decimal, // DeclaringTypeId 266(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 267(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 271(byte)SpecialType.System_Decimal, // DeclaringTypeId 274(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 275(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 276(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 277(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 278(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 279(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 283(byte)SpecialType.System_Decimal, // DeclaringTypeId 286(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 287(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 288(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 292(byte)SpecialType.System_Decimal, // DeclaringTypeId 295(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 296(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 297(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 301(byte)SpecialType.System_Decimal, // DeclaringTypeId 304(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 305(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 306(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 310(byte)SpecialType.System_Decimal, // DeclaringTypeId 313(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 314(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 315(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 319(byte)SpecialType.System_Decimal, // DeclaringTypeId 322(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 323(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 324(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 328(byte)SpecialType.System_Decimal, // DeclaringTypeId 331(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 332(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 336(byte)SpecialType.System_Decimal, // DeclaringTypeId 339(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 340(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 344(byte)SpecialType.System_Decimal, // DeclaringTypeId 347(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 348(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 352(byte)SpecialType.System_Decimal, // DeclaringTypeId 355(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 356(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 360(byte)SpecialType.System_Decimal, // DeclaringTypeId 363(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 364(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 365(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 369(byte)SpecialType.System_Decimal, // DeclaringTypeId 372(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 373(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 374(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 378(byte)SpecialType.System_Decimal, // DeclaringTypeId 381(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 382(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 383(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 387(byte)SpecialType.System_Decimal, // DeclaringTypeId 390(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 391(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 392(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 396(byte)SpecialType.System_Decimal, // DeclaringTypeId 399(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 400(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 401(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 405(byte)SpecialType.System_Decimal, // DeclaringTypeId 408(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 409(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 410(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 414(byte)SpecialType.System_Decimal, // DeclaringTypeId 417(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 418(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 419(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 423(byte)SpecialType.System_Decimal, // DeclaringTypeId 426(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 427(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 428(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 432(byte)SpecialType.System_Decimal, // DeclaringTypeId 435(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 436(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 437(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 441(byte)SpecialType.System_Decimal, // DeclaringTypeId 444(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 445(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 446(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 450(byte)SpecialType.System_Decimal, // DeclaringTypeId 453(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 454(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 455(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 459(byte)SpecialType.System_Decimal, // DeclaringTypeId 462(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 463(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 464(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 468(byte)SpecialType.System_Decimal, // DeclaringTypeId 471(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 472(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 473(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 477(byte)SpecialType.System_Decimal, // DeclaringTypeId 480(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 481(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 485(byte)SpecialType.System_Decimal, // DeclaringTypeId 488(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 489(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 493(byte)SpecialType.System_Decimal, // DeclaringTypeId 496(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 497(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, 501(byte)SpecialType.System_Decimal, // DeclaringTypeId 504(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 505(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 509(byte)SpecialType.System_Decimal, // DeclaringTypeId 512(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 513(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 517(byte)SpecialType.System_Decimal, // DeclaringTypeId 520(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 521(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_SByte, 525(byte)SpecialType.System_Decimal, // DeclaringTypeId 528(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 529(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, 533(byte)SpecialType.System_Decimal, // DeclaringTypeId 536(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 537(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 541(byte)SpecialType.System_Decimal, // DeclaringTypeId 544(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 545(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, 549(byte)SpecialType.System_Decimal, // DeclaringTypeId 552(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 553(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 557(byte)SpecialType.System_Decimal, // DeclaringTypeId 560(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, 561(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 565(byte)SpecialType.System_Decimal, // DeclaringTypeId 568(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_SByte, 569(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 573(byte)SpecialType.System_Decimal, // DeclaringTypeId 576(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, 577(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 581(byte)SpecialType.System_Decimal, // DeclaringTypeId 584(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 585(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 589(byte)SpecialType.System_Decimal, // DeclaringTypeId 592(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 593(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 597(byte)SpecialType.System_Decimal, // DeclaringTypeId 600(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 601(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 605(byte)SpecialType.System_Decimal, // DeclaringTypeId 608(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, 609(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 613(byte)SpecialType.System_Decimal, // DeclaringTypeId 616(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 617(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 621(byte)SpecialType.System_Decimal, // DeclaringTypeId 624(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 625(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 629(byte)SpecialType.System_Decimal, // DeclaringTypeId 632(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 633(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 637(byte)SpecialType.System_Decimal, // DeclaringTypeId 640(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 641(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 645(byte)SpecialType.System_Decimal, // DeclaringTypeId 648(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 649(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 653(byte)SpecialType.System_DateTime, // DeclaringTypeId 655(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, // Field Signature 659(byte)SpecialType.System_DateTime, // DeclaringTypeId 662(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 663(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 667(byte)SpecialType.System_DateTime, // DeclaringTypeId 670(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 671(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 672(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 676(byte)SpecialType.System_DateTime, // DeclaringTypeId 679(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 680(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 681(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 685(byte)SpecialType.System_DateTime, // DeclaringTypeId 688(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 689(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 690(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 694(byte)SpecialType.System_DateTime, // DeclaringTypeId 697(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 698(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 699(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 703(byte)SpecialType.System_DateTime, // DeclaringTypeId 706(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 707(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 708(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 712(byte)SpecialType.System_DateTime, // DeclaringTypeId 715(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 716(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 717(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 721(byte)SpecialType.System_DateTime, // DeclaringTypeId 724(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 725(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 726(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 730(byte)SpecialType.System_Collections_IEnumerable, // DeclaringTypeId 733(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_IEnumerator, 737(byte)SpecialType.System_Collections_IEnumerator, // DeclaringTypeId 740(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 744(byte)SpecialType.System_Collections_IEnumerator, // DeclaringTypeId 747(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 751(byte)SpecialType.System_Collections_IEnumerator, // DeclaringTypeId 754(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 758(byte)SpecialType.System_Collections_IEnumerator, // DeclaringTypeId 761(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 765(byte)SpecialType.System_Collections_Generic_IEnumerable_T, // DeclaringTypeId 769(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerator_T, 775(byte)SpecialType.System_Collections_Generic_IEnumerator_T, // DeclaringTypeId 782(byte)SpecialType.System_Collections_Generic_IEnumerator_T, // DeclaringTypeId 789(byte)SpecialType.System_IDisposable, // DeclaringTypeId 792(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 796(byte)SpecialType.System_Array, // DeclaringTypeId 799(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 803(byte)SpecialType.System_Array, // DeclaringTypeId 806(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 810(byte)SpecialType.System_Array, // DeclaringTypeId 813(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 814(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 818(byte)SpecialType.System_Array, // DeclaringTypeId 821(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 822(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 826(byte)SpecialType.System_Object, // DeclaringTypeId 829(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 833(byte)SpecialType.System_Object, // DeclaringTypeId 836(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 837(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 841(byte)SpecialType.System_Object, // DeclaringTypeId 844(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 845(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 846(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 850(byte)SpecialType.System_Object, // DeclaringTypeId 853(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 857(byte)SpecialType.System_Object, // DeclaringTypeId 860(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 861(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 862(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 866(byte)SpecialType.System_IntPtr, // DeclaringTypeId 869(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 870(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_IntPtr, 874(byte)SpecialType.System_IntPtr, // DeclaringTypeId 877(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 878(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_IntPtr, 882(byte)SpecialType.System_IntPtr, // DeclaringTypeId 885(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 886(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_IntPtr, 890(byte)SpecialType.System_IntPtr, // DeclaringTypeId 893(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_IntPtr, 894(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 898(byte)SpecialType.System_IntPtr, // DeclaringTypeId 901(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_IntPtr, 902(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 906(byte)SpecialType.System_IntPtr, // DeclaringTypeId 909(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_IntPtr, 910(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 914(byte)SpecialType.System_UIntPtr, // DeclaringTypeId 917(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 918(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UIntPtr, 922(byte)SpecialType.System_UIntPtr, // DeclaringTypeId 925(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 926(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UIntPtr, 930(byte)SpecialType.System_UIntPtr, // DeclaringTypeId 933(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, 934(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UIntPtr, 938(byte)SpecialType.System_UIntPtr, // DeclaringTypeId 941(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UIntPtr, 942(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 946(byte)SpecialType.System_UIntPtr, // DeclaringTypeId 949(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UIntPtr, 950(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 954(byte)SpecialType.System_UIntPtr, // DeclaringTypeId 957(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UIntPtr, 958(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, 962(byte)SpecialType.System_Nullable_T, // DeclaringTypeId 969(byte)SpecialType.System_Nullable_T, // DeclaringTypeId 976(byte)SpecialType.System_Nullable_T, // DeclaringTypeId 979(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 983(byte)SpecialType.System_Nullable_T, // DeclaringTypeId 986(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 991(byte)SpecialType.System_Nullable_T, // DeclaringTypeId 994(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Nullable_T, 999(byte)SpecialType.System_Nullable_T, // DeclaringTypeId 1003(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Nullable_T, 1007(byte)SpecialType.System_Runtime_CompilerServices_RuntimeFeature, // DeclaringTypeId 1009(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Field Signature 1013(byte)SpecialType.System_Runtime_CompilerServices_RuntimeFeature, // DeclaringTypeId 1015(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Field Signature 1019(byte)SpecialType.System_Runtime_CompilerServices_RuntimeFeature, // DeclaringTypeId 1021(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Field Signature 1025(byte)SpecialType.System_Runtime_CompilerServices_RuntimeFeature, // DeclaringTypeId 1027(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Field Signature 1031(byte)SpecialType.System_Runtime_CompilerServices_RuntimeFeature, // DeclaringTypeId 1033(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Field Signature 1037(byte)SpecialType.System_Runtime_CompilerServices_RuntimeFeature, // DeclaringTypeId 1039(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Field Signature 1043(byte)SpecialType.System_Runtime_CompilerServices_PreserveBaseOverridesAttribute, // DeclaringTypeId 1046(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type
SpecialTypeExtensions.cs (142)
15public static bool IsClrInteger(this SpecialType specialType) 19case SpecialType.System_Boolean: 20case SpecialType.System_Char: 21case SpecialType.System_Byte: 22case SpecialType.System_SByte: 23case SpecialType.System_Int16: 24case SpecialType.System_UInt16: 25case SpecialType.System_Int32: 26case SpecialType.System_UInt32: 27case SpecialType.System_Int64: 28case SpecialType.System_UInt64: 29case SpecialType.System_IntPtr: 30case SpecialType.System_UIntPtr: 40public static bool IsBlittable(this SpecialType specialType) 44case SpecialType.System_Boolean: 45case SpecialType.System_Char: 46case SpecialType.System_Byte: 47case SpecialType.System_SByte: 48case SpecialType.System_Int16: 49case SpecialType.System_UInt16: 50case SpecialType.System_Int32: 51case SpecialType.System_UInt32: 52case SpecialType.System_Int64: 53case SpecialType.System_UInt64: 54case SpecialType.System_Single: 55case SpecialType.System_Double: 62public static bool IsValueType(this SpecialType specialType) 66case SpecialType.System_Void: 67case SpecialType.System_Boolean: 68case SpecialType.System_Char: 69case SpecialType.System_Byte: 70case SpecialType.System_SByte: 71case SpecialType.System_Int16: 72case SpecialType.System_UInt16: 73case SpecialType.System_Int32: 74case SpecialType.System_UInt32: 75case SpecialType.System_Int64: 76case SpecialType.System_UInt64: 77case SpecialType.System_Single: 78case SpecialType.System_Double: 79case SpecialType.System_Decimal: 80case SpecialType.System_IntPtr: 81case SpecialType.System_UIntPtr: 82case SpecialType.System_Nullable_T: 83case SpecialType.System_DateTime: 84case SpecialType.System_TypedReference: 85case SpecialType.System_ArgIterator: 86case SpecialType.System_RuntimeArgumentHandle: 87case SpecialType.System_RuntimeFieldHandle: 88case SpecialType.System_RuntimeMethodHandle: 89case SpecialType.System_RuntimeTypeHandle: 96public static int SizeInBytes(this SpecialType specialType) 100case SpecialType.System_SByte: 102case SpecialType.System_Byte: 104case SpecialType.System_Int16: 106case SpecialType.System_UInt16: 108case SpecialType.System_Int32: 110case SpecialType.System_UInt32: 112case SpecialType.System_Int64: 114case SpecialType.System_UInt64: 116case SpecialType.System_Char: 118case SpecialType.System_Single: 120case SpecialType.System_Double: 122case SpecialType.System_Boolean: 125case SpecialType.System_Decimal: 139public static bool IsPrimitiveRecursiveStruct(this SpecialType specialType) 143case SpecialType.System_Boolean: 144case SpecialType.System_Byte: 145case SpecialType.System_Char: 146case SpecialType.System_Double: 147case SpecialType.System_Int16: 148case SpecialType.System_Int32: 149case SpecialType.System_Int64: 150case SpecialType.System_UInt16: 151case SpecialType.System_UInt32: 152case SpecialType.System_UInt64: 153case SpecialType.System_IntPtr: 154case SpecialType.System_UIntPtr: 155case SpecialType.System_SByte: 156case SpecialType.System_Single: 163public static bool IsValidEnumUnderlyingType(this SpecialType specialType) 167case SpecialType.System_Byte: 168case SpecialType.System_SByte: 169case SpecialType.System_Int16: 170case SpecialType.System_UInt16: 171case SpecialType.System_Int32: 172case SpecialType.System_UInt32: 173case SpecialType.System_Int64: 174case SpecialType.System_UInt64: 181public static bool IsNumericType(this SpecialType specialType) 185case SpecialType.System_Byte: 186case SpecialType.System_SByte: 187case SpecialType.System_Int16: 188case SpecialType.System_UInt16: 189case SpecialType.System_Int32: 190case SpecialType.System_UInt32: 191case SpecialType.System_Int64: 192case SpecialType.System_UInt64: 193case SpecialType.System_Single: 194case SpecialType.System_Double: 195case SpecialType.System_Decimal: 205public static bool IsIntegralType(this SpecialType specialType) 209case SpecialType.System_Byte: 210case SpecialType.System_SByte: 211case SpecialType.System_Int16: 212case SpecialType.System_UInt16: 213case SpecialType.System_Int32: 214case SpecialType.System_UInt32: 215case SpecialType.System_Int64: 216case SpecialType.System_UInt64: 223public static bool IsUnsignedIntegralType(this SpecialType specialType) 227case SpecialType.System_Byte: 228case SpecialType.System_UInt16: 229case SpecialType.System_UInt32: 230case SpecialType.System_UInt64: 237public static bool IsSignedIntegralType(this SpecialType specialType) 241case SpecialType.System_SByte: 242case SpecialType.System_Int16: 243case SpecialType.System_Int32: 244case SpecialType.System_Int64: 256public static int VBForToShiftBits(this SpecialType specialType) 260case SpecialType.System_SByte: 262case SpecialType.System_Int16: 264case SpecialType.System_Int32: 266case SpecialType.System_Int64: 273public static SpecialType FromRuntimeTypeOfLiteralValue(object value) 282return SpecialType.System_Int32; 287return SpecialType.System_String; 292return SpecialType.System_Boolean; 297return SpecialType.System_Char; 302return SpecialType.System_Int64; 307return SpecialType.System_Double; 312return SpecialType.System_UInt32; 317return SpecialType.System_UInt64; 322return SpecialType.System_Single; 327return SpecialType.System_Decimal; 332return SpecialType.System_Int16; 337return SpecialType.System_UInt16; 342return SpecialType.System_DateTime; 347return SpecialType.System_Byte; 352return SpecialType.System_SByte; 355return SpecialType.None;
SpecialTypes.cs (46)
74private static readonly Dictionary<string, SpecialType> s_nameToTypeIdMap; 77private static readonly SpecialType[] s_typeCodeToTypeIdMap; 81s_nameToTypeIdMap = new Dictionary<string, SpecialType>((int)SpecialType.Count); 90s_nameToTypeIdMap.Add(name, (SpecialType)i); 93s_typeIdToTypeCodeMap = new Microsoft.Cci.PrimitiveTypeCode[(int)SpecialType.Count + 1]; 100s_typeIdToTypeCodeMap[(int)SpecialType.System_Boolean] = Microsoft.Cci.PrimitiveTypeCode.Boolean; 101s_typeIdToTypeCodeMap[(int)SpecialType.System_Char] = Microsoft.Cci.PrimitiveTypeCode.Char; 102s_typeIdToTypeCodeMap[(int)SpecialType.System_Void] = Microsoft.Cci.PrimitiveTypeCode.Void; 103s_typeIdToTypeCodeMap[(int)SpecialType.System_String] = Microsoft.Cci.PrimitiveTypeCode.String; 104s_typeIdToTypeCodeMap[(int)SpecialType.System_Int64] = Microsoft.Cci.PrimitiveTypeCode.Int64; 105s_typeIdToTypeCodeMap[(int)SpecialType.System_Int32] = Microsoft.Cci.PrimitiveTypeCode.Int32; 106s_typeIdToTypeCodeMap[(int)SpecialType.System_Int16] = Microsoft.Cci.PrimitiveTypeCode.Int16; 107s_typeIdToTypeCodeMap[(int)SpecialType.System_SByte] = Microsoft.Cci.PrimitiveTypeCode.Int8; 108s_typeIdToTypeCodeMap[(int)SpecialType.System_UInt64] = Microsoft.Cci.PrimitiveTypeCode.UInt64; 109s_typeIdToTypeCodeMap[(int)SpecialType.System_UInt32] = Microsoft.Cci.PrimitiveTypeCode.UInt32; 110s_typeIdToTypeCodeMap[(int)SpecialType.System_UInt16] = Microsoft.Cci.PrimitiveTypeCode.UInt16; 111s_typeIdToTypeCodeMap[(int)SpecialType.System_Byte] = Microsoft.Cci.PrimitiveTypeCode.UInt8; 112s_typeIdToTypeCodeMap[(int)SpecialType.System_Single] = Microsoft.Cci.PrimitiveTypeCode.Float32; 113s_typeIdToTypeCodeMap[(int)SpecialType.System_Double] = Microsoft.Cci.PrimitiveTypeCode.Float64; 114s_typeIdToTypeCodeMap[(int)SpecialType.System_IntPtr] = Microsoft.Cci.PrimitiveTypeCode.IntPtr; 115s_typeIdToTypeCodeMap[(int)SpecialType.System_UIntPtr] = Microsoft.Cci.PrimitiveTypeCode.UIntPtr; 117s_typeCodeToTypeIdMap = new SpecialType[(int)Microsoft.Cci.PrimitiveTypeCode.Invalid + 1]; 121s_typeCodeToTypeIdMap[i] = SpecialType.None; 124s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Boolean] = SpecialType.System_Boolean; 125s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Char] = SpecialType.System_Char; 126s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Void] = SpecialType.System_Void; 127s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.String] = SpecialType.System_String; 128s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Int64] = SpecialType.System_Int64; 129s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Int32] = SpecialType.System_Int32; 130s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Int16] = SpecialType.System_Int16; 131s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Int8] = SpecialType.System_SByte; 132s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.UInt64] = SpecialType.System_UInt64; 133s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.UInt32] = SpecialType.System_UInt32; 134s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.UInt16] = SpecialType.System_UInt16; 135s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.UInt8] = SpecialType.System_Byte; 136s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Float32] = SpecialType.System_Single; 137s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.Float64] = SpecialType.System_Double; 138s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.IntPtr] = SpecialType.System_IntPtr; 139s_typeCodeToTypeIdMap[(int)Microsoft.Cci.PrimitiveTypeCode.UIntPtr] = SpecialType.System_UIntPtr; 145public static string? GetMetadataName(this SpecialType id) 150public static SpecialType GetTypeFromMetadataName(string metadataName) 152SpecialType id; 159return SpecialType.None; 162public static SpecialType GetTypeFromMetadataName(Microsoft.Cci.PrimitiveTypeCode typeCode) 167public static Microsoft.Cci.PrimitiveTypeCode GetTypeCode(SpecialType typeId)
SymbolDisplay\AbstractSymbolDisplayVisitor.cs (5)
80protected abstract void AddLiteralValue(SpecialType type, object value); 81protected abstract void AddExplicitlyCastedLiteralValue(INamedTypeSymbol namedType, SpecialType type, object value); 190var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType; 267var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType; 286var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType;
Symbols\Attributes\CommonAttributeData.cs (31)
142internal T? GetConstructorArgument<T>(int i, SpecialType specialType) 160internal T? DecodeNamedArgument<T>(string name, SpecialType specialType, T? defaultValue = default) 165private static T? DecodeNamedArgument<T>(ImmutableArray<KeyValuePair<string, TypedConstant>> namedArguments, string name, SpecialType specialType, T? defaultValue = default) 203Debug.Assert(parameters[0].Type.SpecialType == SpecialType.System_Byte); 204Debug.Assert(parameters[1].Type.SpecialType == SpecialType.System_Byte); 208byte scale = args[0].DecodeValue<byte>(SpecialType.System_Byte); 209bool isNegative = args[1].DecodeValue<byte>(SpecialType.System_Byte) != 0; 211if (parameters[2].Type.SpecialType == SpecialType.System_Int32) 213Debug.Assert(parameters[2].Type.SpecialType == SpecialType.System_Int32); 214Debug.Assert(parameters[3].Type.SpecialType == SpecialType.System_Int32); 215Debug.Assert(parameters[4].Type.SpecialType == SpecialType.System_Int32); 217high = args[2].DecodeValue<int>(SpecialType.System_Int32); 218mid = args[3].DecodeValue<int>(SpecialType.System_Int32); 219low = args[4].DecodeValue<int>(SpecialType.System_Int32); 223Debug.Assert(parameters[2].Type.SpecialType == SpecialType.System_UInt32); 224Debug.Assert(parameters[3].Type.SpecialType == SpecialType.System_UInt32); 225Debug.Assert(parameters[4].Type.SpecialType == SpecialType.System_UInt32); 227high = unchecked((int)args[2].DecodeValue<uint>(SpecialType.System_UInt32)); 228mid = unchecked((int)args[3].DecodeValue<uint>(SpecialType.System_UInt32)); 229low = unchecked((int)args[4].DecodeValue<uint>(SpecialType.System_UInt32)); 237long value = this.CommonConstructorArguments[0].DecodeValue<long>(SpecialType.System_Int64); 371if (attribute.AttributeConstructor.Parameters[0].Type.SpecialType == SpecialType.System_Int16) 373options = (MethodImplOptions)attribute.CommonConstructorArguments[0].DecodeValue<short>(SpecialType.System_Int16); 377options = attribute.CommonConstructorArguments[0].DecodeValue<MethodImplOptions>(SpecialType.System_Enum); 398var value = (MethodImplAttributes)namedArg.Value.DecodeValue<int>(SpecialType.System_Enum); 435LayoutKind kind = attribute.CommonConstructorArguments[0].DecodeValue<LayoutKind>(SpecialType.System_Enum); 455charSet = namedArg.Value.DecodeValue<CharSet>(SpecialType.System_Enum); 476alignment = namedArg.Value.DecodeValue<int>(SpecialType.System_Int32); 488size = namedArg.Value.DecodeValue<int>(Microsoft.CodeAnalysis.SpecialType.System_Int32); 538bool allowMultiple = DecodeNamedArgument(namedArgs, "AllowMultiple", SpecialType.System_Boolean, false); 539bool inherited = DecodeNamedArgument(namedArgs, "Inherited", SpecialType.System_Boolean, true);
Symbols\Attributes\MarshalAsAttributeDecoder.cs (13)
102if (attribute.AttributeConstructor.Parameters[0].Type.SpecialType == SpecialType.System_Int16) 104unmanagedType = (UnmanagedType)attribute.CommonConstructorArguments[0].DecodeValue<short>(SpecialType.System_Int16); 108unmanagedType = attribute.CommonConstructorArguments[0].DecodeValue<UnmanagedType>(SpecialType.System_Enum); 131typeName = namedArg.Value.DecodeValue<string>(SpecialType.System_String); 142typeSymbol = namedArg.Value.DecodeValue<ITypeSymbolInternal>(SpecialType.None); 147cookie = namedArg.Value.DecodeValue<string>(SpecialType.System_String); 187parameterIndex = namedArg.Value.DecodeValue<int>(SpecialType.System_Int32); 223elementType = namedArg.Value.DecodeValue<UnmanagedType>(SpecialType.System_Enum); 237elementCount = namedArg.Value.DecodeValue<int>(SpecialType.System_Int32); 252parameterIndex = namedArg.Value.DecodeValue<short>(SpecialType.System_Int16); 300elementTypeVariant = namedArg.Value.DecodeValue<Cci.VarEnum>(SpecialType.System_Enum); 310elementTypeSymbol = namedArg.Value.DecodeValue<ITypeSymbolInternal>(SpecialType.None); 368elementCount = namedArg.Value.DecodeValue<int>(SpecialType.System_Int32);
Symbols\ITypeSymbol.cs (5)
93/// Returns <see cref="Microsoft.CodeAnalysis.SpecialType.None"/> if the type is not special. 95SpecialType SpecialType { get; } 201return typeOpt?.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T; 217return type?.SpecialType == SpecialType.System_Boolean; 222return type?.SpecialType == SpecialType.System_Object;
Symbols\ITypeSymbolInternal.cs (2)
18/// Returns <see cref="Microsoft.CodeAnalysis.SpecialType.None"/> if the type is not special. 20SpecialType SpecialType { get; }
Symbols\TypedConstant.cs (17)
127internal T? DecodeValue<T>(SpecialType specialType) 133internal bool TryDecodeValue<T>(SpecialType specialType, [MaybeNullWhen(false)] out T value) 141if (_type!.SpecialType == specialType || (_type.TypeKind == TypeKind.Enum && specialType == SpecialType.System_Enum)) 162case SpecialType.System_Boolean: 163case SpecialType.System_SByte: 164case SpecialType.System_Int16: 165case SpecialType.System_Int32: 166case SpecialType.System_Int64: 167case SpecialType.System_Byte: 168case SpecialType.System_UInt16: 169case SpecialType.System_UInt32: 170case SpecialType.System_UInt64: 171case SpecialType.System_Single: 172case SpecialType.System_Double: 173case SpecialType.System_Char: 174case SpecialType.System_String: 175case SpecialType.System_Object:
WellKnownMembers.cs (798)
21(byte)SpecialType.System_Object, // DeclaringTypeId 24(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 31(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return Type 32(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 39(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return Type 40(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 41(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 48(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 62(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 63(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 70(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 71(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 78(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 79(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 86(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 87(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 94(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 95(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, 102(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 103(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 110(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 111(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 118(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_SByte, // Return Type 119(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 126(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_SByte, // Return Type 127(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 134(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_SByte, // Return Type 135(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 142(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, // Return Type 143(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 150(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, // Return Type 151(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 158(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, // Return Type 159(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 166(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Return Type 167(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 174(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Return Type 175(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 182(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Return Type 183(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 190(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, // Return Type 191(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 198(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, // Return Type 199(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 206(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, // Return Type 207(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 214(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 215(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 222(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 223(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 230(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 231(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 238(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, // Return Type 239(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 246(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, // Return Type 247(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 254(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, // Return Type 255(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 262(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, // Return Type 263(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 270(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, // Return Type 271(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 278(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, // Return Type 279(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 286(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // Return Type 287(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 294(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // Return Type 295(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 302(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // Return Type 303(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 310(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Return Type 311(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 318(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return Type 319(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 326(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 327(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 334(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 341(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 342(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 364(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Field Signature 371(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 380(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 381(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 388(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 389(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 413(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, // Return Type 415(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 419(byte)SpecialType.System_Delegate, // DeclaringTypeId 422(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, // Return Type 424(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 429(byte)SpecialType.System_Delegate, // DeclaringTypeId 432(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, // Return Type 434(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 436(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 466(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 474(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 483(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 492(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 507(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 515(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 522(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 529(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 536(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 543(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 544(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 551(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 558(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 559(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 566(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 573(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 580(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 587(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 595(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 602(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 634(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 635(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 642(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 643(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 650(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 658(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 666(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 668(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 675(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 676(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 677(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 684(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 685(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 686(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Delegate, 693(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 702(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 703(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 710(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 711(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 718(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 719(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 726(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 727(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 734(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 742(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 743(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, 758(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 765(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 766(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 767(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 774(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 775(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 782(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 783(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 790(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 791(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 798(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 835(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 843(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 860(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 871(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 883(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 884(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 891(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 892(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 893(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 894(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 895(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 896(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 903(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 904(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 905(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 906(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 907(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 908(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 915(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 922(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 929(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 930(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 937(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 938(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 945(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 952(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 959(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 966(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 968(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 975(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 982(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 983(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1018(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1019(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1026(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 1027(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Array, 1035(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 1051(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 1066(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 1073(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 1086(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 1094(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1101(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1116(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1117(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1118(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1119(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1136(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 1137(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1144(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 1145(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1146(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1153(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 1154(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1168(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 1180(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1203(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1214(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1217(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1230(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1243(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1254(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1256(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1261(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1272(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1284(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1295(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1298(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1312(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Collections_Generic_IEnumerable_T, 1323(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1330(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, // Return Type 1331(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1338(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1339(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1346(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_SByte, // Return Type 1347(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1354(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, // Return Type 1355(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1362(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Return Type 1363(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1370(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, // Return Type 1371(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1378(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 1379(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1386(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, // Return Type 1387(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1394(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, // Return Type 1395(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1402(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // Return Type 1403(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1410(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Return Type 1411(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1418(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return Type 1419(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1426(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, // Return Type 1427(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1434(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, // Return Type 1435(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1442(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, // Return Type 1443(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1450(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 1451(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1458(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1459(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1466(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1467(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 1474(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1475(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 1482(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1483(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, 1490(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1491(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, 1498(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1499(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, 1506(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1507(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, 1514(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1515(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 1522(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1523(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, 1530(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1531(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, 1538(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1539(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 1546(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 1547(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1554(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1555(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1562(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_SByte, // Return Type 1563(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1570(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, // Return Type 1571(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1578(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Return Type 1579(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1586(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, // Return Type 1587(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1594(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 1595(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1602(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, // Return Type 1603(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1610(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int64, // Return Type 1611(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1618(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // Return Type 1619(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1626(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Return Type 1627(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1634(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return Type 1635(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1642(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, // Return Type 1643(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1650(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_DateTime, // Return Type 1651(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1658(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, // Return Type 1659(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1666(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 1667(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1675(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1682(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1683(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1691(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1692(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1699(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1700(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1707(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1708(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1715(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1716(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1717(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1724(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1725(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1726(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1733(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1734(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1735(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1742(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1743(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1744(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1751(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1752(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1753(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1760(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1761(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1762(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1769(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1770(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1771(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1778(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1779(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1780(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1787(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1788(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1789(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1796(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1797(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1798(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1805(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1806(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1807(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1814(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1815(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1816(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1823(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1824(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1825(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1832(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1833(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1834(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1835(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1842(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1843(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1844(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1845(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1852(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1853(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1854(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1855(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1862(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1863(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1864(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1865(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1872(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1873(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1874(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1875(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1882(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1883(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1884(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1885(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1892(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1893(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1894(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1895(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1902(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1903(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1904(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1905(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1912(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1913(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1914(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1915(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1922(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1923(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1924(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1925(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1932(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1933(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1934(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1935(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1942(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 1943(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1944(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1945(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1952(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 1953(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1954(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1955(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1962(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 1963(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1964(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1965(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1972(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1973(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1975(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1976(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1977(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1979(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1980(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 1987(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 1988(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1990(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1991(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 1992(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 1994(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 2001(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2002(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2004(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2005(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2006(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2014(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2015(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2017(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2018(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2019(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2021(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 2022(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 2029(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 2030(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2031(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2032(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2039(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2040(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2041(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2042(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2049(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2050(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2051(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2052(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2053(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 2054(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 2061(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2068(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2074(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Field Signature 2081(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2082(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2083(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2084(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2085(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2092(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2099(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2106(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Array, // Return Type 2107(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Array, 2108(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Array, 2115(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 2116(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2117(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2125(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 2126(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2127(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2136(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2143(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2151(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2153(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2160(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2167(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2174(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 2175(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2176(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2177(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2178(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2179(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2180(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2187(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 2188(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2189(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2190(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2197(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2198(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2205(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 2206(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2207(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2209(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2216(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 2217(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2224(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 2225(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2232(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 2233(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2240(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 2241(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2248(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 2249(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2256(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 2257(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2264(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 2265(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2272(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 2273(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2280(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 2281(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2282(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2284(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2291(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2298(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2313(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2321(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2328(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2330(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.GenericMethodParameter, (byte)SpecialType.System_Object, 2337(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2339(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.GenericMethodParameter, (byte)SpecialType.System_Object, 2346(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2354(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2369(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2377(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2384(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2386(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.GenericMethodParameter, (byte)SpecialType.System_Object, 2393(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2395(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.GenericMethodParameter, (byte)SpecialType.System_Object, 2402(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2410(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2432(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2440(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2448(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2450(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.GenericMethodParameter, (byte)SpecialType.System_Object, 2457(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2459(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.GenericMethodParameter, (byte)SpecialType.System_Object, 2466(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2474(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2492(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2500(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2508(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 2509(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 2516(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 2517(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2524(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 2525(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 2532(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 2533(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2540(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 2541(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2548(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, // Return Type 2549(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2556(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2558(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2565(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2567(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2575(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2582(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2590(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 2597(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2827(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2835(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2844(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2854(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2865(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2877(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2890(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2904(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2920(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 2921(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2925(byte)SpecialType.System_String, // DeclaringTypeId 2928(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 2930(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 2931(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 2938(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 2940(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2941(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2942(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 2943(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2950(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 2952(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2953(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2954(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 2955(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 2963(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Method id 2971(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Method id 2972(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Lambda id 2980(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Method id 2981(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // State machine instance id 2989(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Method id 2990(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Lambda id 2991(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // State machine instance id 2998(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3005(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // Return Type 3012(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3013(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Value 3014(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3021(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3022(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, // Value 3023(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3030(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3031(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, // Value 3032(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3039(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3040(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, // Value 3041(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3048(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3049(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // Value 3050(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3057(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3058(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Value 3059(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3066(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3067(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Value 3068(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3075(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3076(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, // Value 3077(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3084(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3085(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Value 3086(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3093(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3094(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Value 3095(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3102(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3103(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Value 3104(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3111(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3112(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Value address 3113(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Size 3114(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3121(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3122(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Source parameter index 3123(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Target local index 3130(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3131(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean,// Value 3132(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3139(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3140(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, // Value 3141(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3148(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3149(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt16, // Value 3150(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3157(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3158(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt32, // Value 3159(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3166(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3167(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_UInt64, // Value 3168(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3175(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3176(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Value 3177(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3184(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3185(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Value 3186(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3193(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3194(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Decimal, // Value 3195(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3202(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3203(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Value 3204(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3211(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3212(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Value 3213(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3220(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3221(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Value 3222(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Local index 3229(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3230(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Value address 3231(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Size 3232(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Parameter index 3239(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3240(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Source parameter index 3241(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Target parameter index 3248(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3249(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Source local index 3250(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Target local index 3257(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3258(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 3265(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3266(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 3273(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3274(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Byte, 3282(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3283(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 3290(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3297(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3304(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3311(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3312(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 3313(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 3320(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3321(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3322(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3329(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3338(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3345(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 3352(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3353(byte)SignatureTypeCode.Pointer, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3354(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3361(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3369(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3371(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3372(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3380(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3387(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 3394(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3401(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Return type 3402(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Number As System.Single 3409(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return type 3410(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Number As System.Double 3417(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Return type 3418(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Single, // Number As System.Single 3425(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return type 3426(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Number As System.Double 3433(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return Type 3434(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 3441(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return Type 3442(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 3449(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, // Return Type 3450(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Double, 3457(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3458(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3459(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 3466(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3467(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3474(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3520(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3550(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 3565(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument: short 3573(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument: short 3580(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3584(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 3585(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Argument 3586(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument 3594(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3601(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3609(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3617(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, 3625(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument: short 3633(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument: short 3640(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3644(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 3645(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Argument 3646(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument 3654(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3655(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument: short 3663(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument: short 3670(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3674(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 3675(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Argument 3676(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument 3684(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3689(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument 3696(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3704(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3706(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int16, // Argument 3720(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3727(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3729(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.GenericMethodParameter, (byte)SpecialType.System_Object, 3736(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3738(byte)SignatureTypeCode.ByReference, (byte)SignatureTypeCode.GenericMethodParameter, (byte)SpecialType.System_Object, 3745(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3753(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, // Return Type 3754(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3761(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, // Return Type 3768(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3775(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3776(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 3783(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3790(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3791(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 3798(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, // Return Type 3822(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type, 3829(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3830(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Argument 3837(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3844(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3845(byte)SignatureTypeCode.SZArray, (byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 3853(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 3861(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 3869(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Object, 3876(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3883(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, // Return Type 3890(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3897(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3904(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3911(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3912(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Int32, 3919(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 3934(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Boolean, 3952(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Char, 3953(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 3960(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3961(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_String, 3968(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type 3975(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, 3982(byte)SignatureTypeCode.TypeHandle, (byte)SpecialType.System_Void, // Return Type
WellKnownTypes.cs (2)
18Unknown = SpecialType.None, 20First = SpecialType.Count + 1,
Microsoft.CodeAnalysis.CodeStyle (303)
AbstractForEachCastDiagnosticAnalyzer.cs (1)
141=> collectionElementType.SpecialType != SpecialType.System_Object ||
AbstractPopulateSwitchDiagnosticAnalyzer.cs (1)
97if (type is not { SpecialType: SpecialType.System_Boolean })
AbstractRemoveRedundantEqualityDiagnosticAnalyzer.cs (2)
60if (rightOperand.Type.SpecialType != SpecialType.System_Boolean || 61leftOperand.Type.SpecialType != SpecialType.System_Boolean)
AbstractRemoveUnnecessaryPragmaSuppressionsDiagnosticAnalyzer.cs (2)
827attribute.AttributeConstructor?.Parameters is [_, { Name: "checkId", Type.SpecialType: SpecialType.System_String }, ..] && 836attribute.AttributeConstructor.Parameters[0].Type.SpecialType == SpecialType.System_String &&
AbstractRemoveUnusedMembersDiagnosticAnalyzer.cs (2)
590attribute.ConstructorArguments is [{ Kind: TypedConstantKind.Primitive, Type.SpecialType: SpecialType.System_String, Value: string value }]) 728(IsSpecialMethodWithMatchingProperty("ShouldSerialize") && methodSymbol.ReturnType.SpecialType == SpecialType.System_Boolean ||
AbstractRemoveUnusedParametersAndValuesDiagnosticAnalyzer.SymbolStartAnalyzer.BlockAnalyzer.cs (1)
144value.Type.SpecialType == SpecialType.System_Void)
AbstractRemoveUnusedParametersAndValuesDiagnosticAnalyzer.SymbolStartAnalyzer.cs (2)
241method.Parameters is [{ Type.SpecialType: SpecialType.System_Object }, var secondParam] && 280methodSymbol.Parameters[0].Type.SpecialType == SpecialType.System_String &&
AbstractSimplifyConditionalDiagnosticAnalyzer.cs (2)
154typeInfo.Type?.SpecialType == SpecialType.System_Boolean && 155typeInfo.ConvertedType?.SpecialType == SpecialType.System_Boolean;
AbstractSimplifyInterpolationHelpers.cs (1)
127return method.ContainingType.SpecialType == SpecialType.System_Object
AbstractSpeculationAnalyzer.cs (6)
707&& symbol.ContainingType.SpecialType == SpecialType.System_Object 983if (newReceiverType.SpecialType != SpecialType.None) 990return newSymbolContainingType.SpecialType is SpecialType.System_Array or 991SpecialType.System_Delegate or 992SpecialType.System_Enum or 993SpecialType.System_String;
AbstractUseIsNullForReferenceEqualsDiagnosticAnalyzer.cs (1)
34var objectType = context.Compilation.GetSpecialType(SpecialType.System_Object);
AbstractUseNullPropagationDiagnosticAnalyzer.cs (4)
86var objectType = context.Compilation.GetSpecialType(SpecialType.System_Object); 154if (type is not INamedTypeSymbol namedType || namedType.ConstructedFrom.SpecialType != SpecialType.System_Nullable_T) 182var whenPartIsNullable = whenPartType?.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T; 360if (typeSymbol?.SpecialType == SpecialType.System_Object)
AbstractUseNullPropagationDiagnosticAnalyzer_IfStatement.cs (1)
89var whenPartIsNullable = semanticModel.GetTypeInfo(whenPartMatch).Type?.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T;
AbstractValidateFormatStringDiagnosticAnalyzer.cs (1)
303if (containingType.SpecialType != SpecialType.System_String)
EnumUtilties.cs (9)
19internal static ulong ConvertEnumUnderlyingTypeToUInt64(object value, SpecialType specialType) 28case SpecialType.System_SByte: 30case SpecialType.System_Int16: 32case SpecialType.System_Int32: 34case SpecialType.System_Int64: 36case SpecialType.System_Byte: 38case SpecialType.System_UInt16: 40case SpecialType.System_UInt32: 42case SpecialType.System_UInt64:
HashCodeAnalyzer.cs (1)
38var objectType = compilation.GetSpecialType(SpecialType.System_Object);
IMethodSymbolExtensions.cs (2)
44method.Parameters is [{ Type.SpecialType: SpecialType.System_Object }, var secondParam] && 105methodSymbol.ReturnType.SpecialType == SpecialType.System_Int32 ||
INamedTypeSymbolExtensions.cs (1)
615ContainingType.SpecialType: SpecialType.System_Object,
IntegerUtilities.cs (7)
60public static long Convert(long v, SpecialType type) 63SpecialType.System_SByte => unchecked((sbyte)v), 64SpecialType.System_Byte => unchecked((byte)v), 65SpecialType.System_Int16 => unchecked((short)v), 66SpecialType.System_UInt16 => unchecked((ushort)v), 67SpecialType.System_Int32 => unchecked((int)v), 68SpecialType.System_UInt32 => unchecked((uint)v),
ISemanticFactsExtensions.cs (2)
119=> type?.SpecialType is SpecialType.System_Single or SpecialType.System_Double;
ISymbolExtensions.cs (4)
448.Select(p => (p.Type ?? compilation.GetSpecialType(SpecialType.System_Object)).WithNullableAnnotation(p.NullableAnnotation)); 453types = types.Concat((method.ReturnType ?? compilation.GetSpecialType(SpecialType.System_Object)).WithNullableAnnotation(method.ReturnNullableAnnotation)); 619if (!returnType.GetMembers().OfType<IPropertySymbol>().Any(p => p.Name == WellKnownMemberNames.IsCompleted && p.Type.SpecialType == SpecialType.System_Boolean && p.GetMethod != null)) 669ReturnType.SpecialType: SpecialType.System_Boolean,
ITypeSymbolExtensions.cs (55)
57=> symbol?.SpecialType == SpecialType.System_Void; 60=> symbol?.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T; 270case SpecialType.System_Array or SpecialType.System_ValueType: 273case SpecialType.System_Delegate: 274case SpecialType.System_MulticastDelegate: 275case SpecialType.System_Enum: 288case SpecialType.System_Byte: 289case SpecialType.System_SByte: 290case SpecialType.System_Int16: 291case SpecialType.System_UInt16: 292case SpecialType.System_Int32: 293case SpecialType.System_UInt32: 294case SpecialType.System_Int64: 295case SpecialType.System_UInt64: 296case SpecialType.System_Single: 297case SpecialType.System_Double: 298case SpecialType.System_Decimal: 299case SpecialType.System_IntPtr when type.IsNativeIntegerType: 300case SpecialType.System_UIntPtr when type.IsNativeIntegerType: 376case SpecialType.System_Object: 377case SpecialType.System_Void: 378case SpecialType.System_Boolean: 379case SpecialType.System_SByte: 380case SpecialType.System_Byte: 381case SpecialType.System_Decimal: 382case SpecialType.System_Single: 383case SpecialType.System_Double: 384case SpecialType.System_Int16: 385case SpecialType.System_Int32: 386case SpecialType.System_Int64: 387case SpecialType.System_Char: 388case SpecialType.System_String: 389case SpecialType.System_UInt16: 390case SpecialType.System_UInt32: 391case SpecialType.System_UInt64: 392case SpecialType.System_IntPtr when symbol.IsNativeIntegerType: 393case SpecialType.System_UIntPtr when symbol.IsNativeIntegerType: 404typeSymbol.AllInterfaces.Any(static i => i.SpecialType == SpecialType.System_Collections_IEnumerable) && 646case SpecialType.System_Boolean: 647case SpecialType.System_Char: 648case SpecialType.System_SByte: 649case SpecialType.System_Byte: 650case SpecialType.System_Int16: 651case SpecialType.System_UInt16: 652case SpecialType.System_Int32: 653case SpecialType.System_UInt32: 654case SpecialType.System_Int64: 655case SpecialType.System_UInt64: 656case SpecialType.System_Decimal: 657case SpecialType.System_Single: 658case SpecialType.System_Double: 661case SpecialType.System_IntPtr: 662case SpecialType.System_UIntPtr: 665case SpecialType.System_DateTime:
J\s\src\Compilers\Core\Portable\SpecialTypeExtensions.cs\SpecialTypeExtensions.cs (142)
15public static bool IsClrInteger(this SpecialType specialType) 19case SpecialType.System_Boolean: 20case SpecialType.System_Char: 21case SpecialType.System_Byte: 22case SpecialType.System_SByte: 23case SpecialType.System_Int16: 24case SpecialType.System_UInt16: 25case SpecialType.System_Int32: 26case SpecialType.System_UInt32: 27case SpecialType.System_Int64: 28case SpecialType.System_UInt64: 29case SpecialType.System_IntPtr: 30case SpecialType.System_UIntPtr: 40public static bool IsBlittable(this SpecialType specialType) 44case SpecialType.System_Boolean: 45case SpecialType.System_Char: 46case SpecialType.System_Byte: 47case SpecialType.System_SByte: 48case SpecialType.System_Int16: 49case SpecialType.System_UInt16: 50case SpecialType.System_Int32: 51case SpecialType.System_UInt32: 52case SpecialType.System_Int64: 53case SpecialType.System_UInt64: 54case SpecialType.System_Single: 55case SpecialType.System_Double: 62public static bool IsValueType(this SpecialType specialType) 66case SpecialType.System_Void: 67case SpecialType.System_Boolean: 68case SpecialType.System_Char: 69case SpecialType.System_Byte: 70case SpecialType.System_SByte: 71case SpecialType.System_Int16: 72case SpecialType.System_UInt16: 73case SpecialType.System_Int32: 74case SpecialType.System_UInt32: 75case SpecialType.System_Int64: 76case SpecialType.System_UInt64: 77case SpecialType.System_Single: 78case SpecialType.System_Double: 79case SpecialType.System_Decimal: 80case SpecialType.System_IntPtr: 81case SpecialType.System_UIntPtr: 82case SpecialType.System_Nullable_T: 83case SpecialType.System_DateTime: 84case SpecialType.System_TypedReference: 85case SpecialType.System_ArgIterator: 86case SpecialType.System_RuntimeArgumentHandle: 87case SpecialType.System_RuntimeFieldHandle: 88case SpecialType.System_RuntimeMethodHandle: 89case SpecialType.System_RuntimeTypeHandle: 96public static int SizeInBytes(this SpecialType specialType) 100case SpecialType.System_SByte: 102case SpecialType.System_Byte: 104case SpecialType.System_Int16: 106case SpecialType.System_UInt16: 108case SpecialType.System_Int32: 110case SpecialType.System_UInt32: 112case SpecialType.System_Int64: 114case SpecialType.System_UInt64: 116case SpecialType.System_Char: 118case SpecialType.System_Single: 120case SpecialType.System_Double: 122case SpecialType.System_Boolean: 125case SpecialType.System_Decimal: 139public static bool IsPrimitiveRecursiveStruct(this SpecialType specialType) 143case SpecialType.System_Boolean: 144case SpecialType.System_Byte: 145case SpecialType.System_Char: 146case SpecialType.System_Double: 147case SpecialType.System_Int16: 148case SpecialType.System_Int32: 149case SpecialType.System_Int64: 150case SpecialType.System_UInt16: 151case SpecialType.System_UInt32: 152case SpecialType.System_UInt64: 153case SpecialType.System_IntPtr: 154case SpecialType.System_UIntPtr: 155case SpecialType.System_SByte: 156case SpecialType.System_Single: 163public static bool IsValidEnumUnderlyingType(this SpecialType specialType) 167case SpecialType.System_Byte: 168case SpecialType.System_SByte: 169case SpecialType.System_Int16: 170case SpecialType.System_UInt16: 171case SpecialType.System_Int32: 172case SpecialType.System_UInt32: 173case SpecialType.System_Int64: 174case SpecialType.System_UInt64: 181public static bool IsNumericType(this SpecialType specialType) 185case SpecialType.System_Byte: 186case SpecialType.System_SByte: 187case SpecialType.System_Int16: 188case SpecialType.System_UInt16: 189case SpecialType.System_Int32: 190case SpecialType.System_UInt32: 191case SpecialType.System_Int64: 192case SpecialType.System_UInt64: 193case SpecialType.System_Single: 194case SpecialType.System_Double: 195case SpecialType.System_Decimal: 205public static bool IsIntegralType(this SpecialType specialType) 209case SpecialType.System_Byte: 210case SpecialType.System_SByte: 211case SpecialType.System_Int16: 212case SpecialType.System_UInt16: 213case SpecialType.System_Int32: 214case SpecialType.System_UInt32: 215case SpecialType.System_Int64: 216case SpecialType.System_UInt64: 223public static bool IsUnsignedIntegralType(this SpecialType specialType) 227case SpecialType.System_Byte: 228case SpecialType.System_UInt16: 229case SpecialType.System_UInt32: 230case SpecialType.System_UInt64: 237public static bool IsSignedIntegralType(this SpecialType specialType) 241case SpecialType.System_SByte: 242case SpecialType.System_Int16: 243case SpecialType.System_Int32: 244case SpecialType.System_Int64: 256public static int VBForToShiftBits(this SpecialType specialType) 260case SpecialType.System_SByte: 262case SpecialType.System_Int16: 264case SpecialType.System_Int32: 266case SpecialType.System_Int64: 273public static SpecialType FromRuntimeTypeOfLiteralValue(object value) 282return SpecialType.System_Int32; 287return SpecialType.System_String; 292return SpecialType.System_Boolean; 297return SpecialType.System_Char; 302return SpecialType.System_Int64; 307return SpecialType.System_Double; 312return SpecialType.System_UInt32; 317return SpecialType.System_UInt64; 322return SpecialType.System_Single; 327return SpecialType.System_Decimal; 332return SpecialType.System_Int16; 337return SpecialType.System_UInt16; 342return SpecialType.System_DateTime; 347return SpecialType.System_Byte; 352return SpecialType.System_SByte; 355return SpecialType.None;
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SpecialTypeExtensions.cs\SpecialTypeExtensions.cs (20)
11public static PredefinedType ToPredefinedType(this SpecialType specialType) 14SpecialType.System_Object => PredefinedType.Object, 15SpecialType.System_Void => PredefinedType.Void, 16SpecialType.System_Boolean => PredefinedType.Boolean, 17SpecialType.System_Char => PredefinedType.Char, 18SpecialType.System_SByte => PredefinedType.SByte, 19SpecialType.System_Byte => PredefinedType.Byte, 20SpecialType.System_Int16 => PredefinedType.Int16, 21SpecialType.System_UInt16 => PredefinedType.UInt16, 22SpecialType.System_Int32 => PredefinedType.Int32, 23SpecialType.System_UInt32 => PredefinedType.UInt32, 24SpecialType.System_Int64 => PredefinedType.Int64, 25SpecialType.System_UInt64 => PredefinedType.UInt64, 26SpecialType.System_Decimal => PredefinedType.Decimal, 27SpecialType.System_Single => PredefinedType.Single, 28SpecialType.System_Double => PredefinedType.Double, 29SpecialType.System_String => PredefinedType.String, 30SpecialType.System_DateTime => PredefinedType.DateTime, 31SpecialType.System_IntPtr => PredefinedType.IntPtr, 32SpecialType.System_UIntPtr => PredefinedType.UIntPtr,
PopulateSwitchStatementHelpers.cs (1)
139if (member is not IFieldSymbol fieldSymbol || fieldSymbol.Type.SpecialType != SpecialType.None)
PredefinedTypeExtensions.cs (21)
11public static SpecialType ToSpecialType(this PredefinedType predefinedType) 14PredefinedType.Object => SpecialType.System_Object, 15PredefinedType.Void => SpecialType.System_Void, 16PredefinedType.Boolean => SpecialType.System_Boolean, 17PredefinedType.Char => SpecialType.System_Char, 18PredefinedType.SByte => SpecialType.System_SByte, 19PredefinedType.Byte => SpecialType.System_Byte, 20PredefinedType.Int16 => SpecialType.System_Int16, 21PredefinedType.UInt16 => SpecialType.System_UInt16, 22PredefinedType.Int32 => SpecialType.System_Int32, 23PredefinedType.UInt32 => SpecialType.System_UInt32, 24PredefinedType.Int64 => SpecialType.System_Int64, 25PredefinedType.UInt64 => SpecialType.System_UInt64, 26PredefinedType.Decimal => SpecialType.System_Decimal, 27PredefinedType.Single => SpecialType.System_Single, 28PredefinedType.Double => SpecialType.System_Double, 29PredefinedType.String => SpecialType.System_String, 30PredefinedType.DateTime => SpecialType.System_DateTime, 31PredefinedType.IntPtr => SpecialType.System_IntPtr, 32PredefinedType.UIntPtr => SpecialType.System_UIntPtr, 33_ => SpecialType.None,
SemanticModelExtensions.cs (2)
173type.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T || 190if (type.SpecialType == SpecialType.System_String)
SpecialTypeAnnotation.cs (8)
14private static readonly ConcurrentDictionary<SpecialType, string> s_fromSpecialTypes = new(); 15private static readonly ConcurrentDictionary<string, SpecialType> s_toSpecialTypes = new(); 17public static SyntaxAnnotation Create(SpecialType specialType) 20public static SpecialType GetSpecialType(SyntaxAnnotation annotation) 23private static string CreateFromSpecialTypes(SpecialType arg) 26private static SpecialType CreateToSpecialTypes(string arg) 27=> (SpecialType)Enum.Parse(typeof(SpecialType), arg);
SymbolEquivalenceComparer.cs (1)
180=> symbol.IsKind(SymbolKind.NamedType, out ITypeSymbol? typeSymbol) && typeSymbol.SpecialType == SpecialType.System_Object;
Microsoft.CodeAnalysis.CodeStyle.Fixes (51)
AbstractFlagsEnumGenerator.cs (5)
15protected abstract SyntaxNode CreateExplicitlyCastedLiteralValue(SyntaxGenerator generator, INamedTypeSymbol enumType, SpecialType underlyingSpecialType, object constantValue); 81var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType; 141SyntaxGenerator generator, IFieldSymbol field, INamedTypeSymbol enumType, SpecialType underlyingSpecialType) 175var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType; 191var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType;
AbstractTypeInferenceService.AbstractTypeInferrer.cs (2)
83protected IEnumerable<TypeInferenceInfo> CreateResult(SpecialType type, NullableAnnotation nullableAnnotation = NullableAnnotation.None) 127symbol.ContainingType?.SpecialType == SpecialType.System_Enum;
AbstractTypeInferenceService.cs (1)
48? ImmutableArray.Create<ITypeSymbol>(semanticModel.Compilation.GetSpecialType(SpecialType.System_Boolean))
CodeGenerationAbstractNamedTypeSymbol.cs (1)
34SpecialType specialType,
CodeGenerationArrayTypeSymbol.cs (1)
13: base(null, null, default, Accessibility.NotApplicable, default, string.Empty, SpecialType.None, nullableAnnotation)
CodeGenerationHelpers.cs (12)
84public static bool IsSpecialType([NotNullWhen(true)] ITypeSymbol? type, SpecialType specialType) 137SpecialType.System_SByte => value is sbyte, 138SpecialType.System_Byte => value is byte, 139SpecialType.System_Int16 => value is short, 140SpecialType.System_UInt16 => value is ushort, 141SpecialType.System_Int32 => value is int, 142SpecialType.System_UInt32 => value is uint, 143SpecialType.System_Int64 => value is long, 144SpecialType.System_UInt64 => value is ulong, 145SpecialType.System_Decimal => value is decimal, 146SpecialType.System_Single => value is float, 147SpecialType.System_Double => value is double,
CodeGenerationMethodSymbol.cs (1)
80=> this.ReturnType == null || this.ReturnType.SpecialType == SpecialType.System_Void;
CodeGenerationNamedTypeSymbol.cs (1)
39SpecialType specialType,
CodeGenerationPointerTypeSymbol.cs (1)
14: base(null, null, default, Accessibility.NotApplicable, default, string.Empty, SpecialType.None, NullableAnnotation.None)
CodeGenerationSymbolFactory.cs (5)
424SpecialType specialType = SpecialType.None, 443SpecialType specialType = SpecialType.None, 495specialType: SpecialType.None,
CodeGenerationTypeParameterSymbol.cs (1)
35: base(containingType?.ContainingAssembly, containingType, attributes, Accessibility.NotApplicable, default, name, SpecialType.None, nullableAnnotation)
CodeGenerationTypeSymbol.cs (2)
19public SpecialType SpecialType { get; protected set; } 28SpecialType specialType,
SimplificationHelpers.cs (2)
78var specialType = SpecialTypeAnnotation.GetSpecialType(annotation2); 79if (specialType != SpecialType.None)
SyntaxGeneratorExtensions.cs (1)
77_ => compilation.GetSpecialType(SpecialType.System_Object),
SyntaxGeneratorExtensions_CreateGetHashCodeMethod.cs (4)
136? factory.SimpleLocalDeclarationStatement(generatorInternal, compilation.GetSpecialType(SpecialType.System_Int32), HashCodeName, CreateLiteralExpression(factory, initHash)) 137: factory.LocalDeclarationStatement(compilation.GetSpecialType(SpecialType.System_Int64), HashCodeName, CreateLiteralExpression(factory, initHash))); 166compilation.GetSpecialType(SpecialType.System_Int32), 210method.ReturnType.SpecialType == SpecialType.System_Int32 &&
SyntaxGeneratorExtensions_Negate.cs (11)
61SpecialType? patternValueType, 279SpecialType? patternValueType) 281if (patternValueType is SpecialType specialType && specialType.IsNumericType()) 421if (containingType?.SpecialType == SpecialType.System_Array || 422containingType?.SpecialType == SpecialType.System_String) 432case SpecialType.System_Byte: 433case SpecialType.System_UInt16: 434case SpecialType.System_UInt32: 435case SpecialType.System_UInt64: 471SpecialType? patternValueType) 478if (patternValueType == SpecialType.System_Boolean)
Microsoft.CodeAnalysis.CSharp (1999)
Binder\Binder.ValueChecks.cs (3)
556if ((expr.ConstantValueOpt != null) || (expr.Type.GetSpecialTypeSafe() == SpecialType.System_Void)) 2921if (expr.Type?.GetSpecialTypeSafe() == SpecialType.System_Void) 3165if (expr.Type?.GetSpecialTypeSafe() == SpecialType.System_Void)
Binder\Binder_Attributes.cs (2)
988if (type.SpecialType == SpecialType.System_Object || 990((ArrayTypeSymbol)type).ElementType.SpecialType == SpecialType.System_Object)
Binder\Binder_Await.cs (1)
393if (isCompletedProperty.Type.SpecialType != SpecialType.System_Boolean)
Binder\Binder_Constraints.cs (11)
269GetSpecialType(SpecialType.System_ValueType, diagnostics, typeSyntax); 480case SpecialType.System_Enum: 481case SpecialType.System_Delegate: 482case SpecialType.System_MulticastDelegate: 491else if (type.SpecialType != SpecialType.System_Enum) 524case SpecialType.System_Enum: 528case SpecialType.System_Delegate: 529case SpecialType.System_MulticastDelegate: 533case SpecialType.System_Object: 534case SpecialType.System_ValueType: 535case SpecialType.System_Array:
Binder\Binder_Conversions.cs (218)
667destination.SpecialType == SpecialType.System_Object; 804SpecialType.System_Decimal => WellKnownMember.System_Runtime_CompilerServices_DecimalConstantAttribute__ctor, 805SpecialType.System_DateTime => WellKnownMember.System_Runtime_CompilerServices_DateTimeConstantAttribute__ctor, 1595case SpecialType.System_Single: 1597case SpecialType.System_Double: 1641SpecialType destinationType; 1646Debug.Assert(underlyingType.SpecialType != SpecialType.None); 1668else if (destinationType == SpecialType.System_Decimal) 1693else if (destinationType == SpecialType.System_IntPtr || destinationType == SpecialType.System_UIntPtr) 1705private static object DoUncheckedConversion(SpecialType destinationType, ConstantValue value) 1740case SpecialType.System_Byte: return (byte)byteValue; 1741case SpecialType.System_Char: return (char)byteValue; 1742case SpecialType.System_UInt16: return (ushort)byteValue; 1743case SpecialType.System_UInt32: return (uint)byteValue; 1744case SpecialType.System_UInt64: return (ulong)byteValue; 1745case SpecialType.System_SByte: return (sbyte)byteValue; 1746case SpecialType.System_Int16: return (short)byteValue; 1747case SpecialType.System_Int32: return (int)byteValue; 1748case SpecialType.System_Int64: return (long)byteValue; 1749case SpecialType.System_IntPtr: return (int)byteValue; 1750case SpecialType.System_UIntPtr: return (uint)byteValue; 1751case SpecialType.System_Single: 1752case SpecialType.System_Double: return (double)byteValue; 1753case SpecialType.System_Decimal: return (decimal)byteValue; 1760case SpecialType.System_Byte: return (byte)charValue; 1761case SpecialType.System_Char: return (char)charValue; 1762case SpecialType.System_UInt16: return (ushort)charValue; 1763case SpecialType.System_UInt32: return (uint)charValue; 1764case SpecialType.System_UInt64: return (ulong)charValue; 1765case SpecialType.System_SByte: return (sbyte)charValue; 1766case SpecialType.System_Int16: return (short)charValue; 1767case SpecialType.System_Int32: return (int)charValue; 1768case SpecialType.System_Int64: return (long)charValue; 1769case SpecialType.System_IntPtr: return (int)charValue; 1770case SpecialType.System_UIntPtr: return (uint)charValue; 1771case SpecialType.System_Single: 1772case SpecialType.System_Double: return (double)charValue; 1773case SpecialType.System_Decimal: return (decimal)charValue; 1780case SpecialType.System_Byte: return (byte)uint16Value; 1781case SpecialType.System_Char: return (char)uint16Value; 1782case SpecialType.System_UInt16: return (ushort)uint16Value; 1783case SpecialType.System_UInt32: return (uint)uint16Value; 1784case SpecialType.System_UInt64: return (ulong)uint16Value; 1785case SpecialType.System_SByte: return (sbyte)uint16Value; 1786case SpecialType.System_Int16: return (short)uint16Value; 1787case SpecialType.System_Int32: return (int)uint16Value; 1788case SpecialType.System_Int64: return (long)uint16Value; 1789case SpecialType.System_IntPtr: return (int)uint16Value; 1790case SpecialType.System_UIntPtr: return (uint)uint16Value; 1791case SpecialType.System_Single: 1792case SpecialType.System_Double: return (double)uint16Value; 1793case SpecialType.System_Decimal: return (decimal)uint16Value; 1800case SpecialType.System_Byte: return (byte)uint32Value; 1801case SpecialType.System_Char: return (char)uint32Value; 1802case SpecialType.System_UInt16: return (ushort)uint32Value; 1803case SpecialType.System_UInt32: return (uint)uint32Value; 1804case SpecialType.System_UInt64: return (ulong)uint32Value; 1805case SpecialType.System_SByte: return (sbyte)uint32Value; 1806case SpecialType.System_Int16: return (short)uint32Value; 1807case SpecialType.System_Int32: return (int)uint32Value; 1808case SpecialType.System_Int64: return (long)uint32Value; 1809case SpecialType.System_IntPtr: return (int)uint32Value; 1810case SpecialType.System_UIntPtr: return (uint)uint32Value; 1811case SpecialType.System_Single: return (double)(float)uint32Value; 1812case SpecialType.System_Double: return (double)uint32Value; 1813case SpecialType.System_Decimal: return (decimal)uint32Value; 1820case SpecialType.System_Byte: return (byte)uint64Value; 1821case SpecialType.System_Char: return (char)uint64Value; 1822case SpecialType.System_UInt16: return (ushort)uint64Value; 1823case SpecialType.System_UInt32: return (uint)uint64Value; 1824case SpecialType.System_UInt64: return (ulong)uint64Value; 1825case SpecialType.System_SByte: return (sbyte)uint64Value; 1826case SpecialType.System_Int16: return (short)uint64Value; 1827case SpecialType.System_Int32: return (int)uint64Value; 1828case SpecialType.System_Int64: return (long)uint64Value; 1829case SpecialType.System_IntPtr: return (int)uint64Value; 1830case SpecialType.System_UIntPtr: return (uint)uint64Value; 1831case SpecialType.System_Single: return (double)(float)uint64Value; 1832case SpecialType.System_Double: return (double)uint64Value; 1833case SpecialType.System_Decimal: return (decimal)uint64Value; 1840case SpecialType.System_Byte: return (byte)nuintValue; 1841case SpecialType.System_Char: return (char)nuintValue; 1842case SpecialType.System_UInt16: return (ushort)nuintValue; 1843case SpecialType.System_UInt32: return (uint)nuintValue; 1844case SpecialType.System_UInt64: return (ulong)nuintValue; 1845case SpecialType.System_SByte: return (sbyte)nuintValue; 1846case SpecialType.System_Int16: return (short)nuintValue; 1847case SpecialType.System_Int32: return (int)nuintValue; 1848case SpecialType.System_Int64: return (long)nuintValue; 1849case SpecialType.System_IntPtr: return (int)nuintValue; 1850case SpecialType.System_Single: return (double)(float)nuintValue; 1851case SpecialType.System_Double: return (double)nuintValue; 1852case SpecialType.System_Decimal: return (decimal)nuintValue; 1859case SpecialType.System_Byte: return (byte)sbyteValue; 1860case SpecialType.System_Char: return (char)sbyteValue; 1861case SpecialType.System_UInt16: return (ushort)sbyteValue; 1862case SpecialType.System_UInt32: return (uint)sbyteValue; 1863case SpecialType.System_UInt64: return (ulong)sbyteValue; 1864case SpecialType.System_SByte: return (sbyte)sbyteValue; 1865case SpecialType.System_Int16: return (short)sbyteValue; 1866case SpecialType.System_Int32: return (int)sbyteValue; 1867case SpecialType.System_Int64: return (long)sbyteValue; 1868case SpecialType.System_IntPtr: return (int)sbyteValue; 1869case SpecialType.System_UIntPtr: return (uint)sbyteValue; 1870case SpecialType.System_Single: 1871case SpecialType.System_Double: return (double)sbyteValue; 1872case SpecialType.System_Decimal: return (decimal)sbyteValue; 1879case SpecialType.System_Byte: return (byte)int16Value; 1880case SpecialType.System_Char: return (char)int16Value; 1881case SpecialType.System_UInt16: return (ushort)int16Value; 1882case SpecialType.System_UInt32: return (uint)int16Value; 1883case SpecialType.System_UInt64: return (ulong)int16Value; 1884case SpecialType.System_SByte: return (sbyte)int16Value; 1885case SpecialType.System_Int16: return (short)int16Value; 1886case SpecialType.System_Int32: return (int)int16Value; 1887case SpecialType.System_Int64: return (long)int16Value; 1888case SpecialType.System_IntPtr: return (int)int16Value; 1889case SpecialType.System_UIntPtr: return (uint)int16Value; 1890case SpecialType.System_Single: 1891case SpecialType.System_Double: return (double)int16Value; 1892case SpecialType.System_Decimal: return (decimal)int16Value; 1899case SpecialType.System_Byte: return (byte)int32Value; 1900case SpecialType.System_Char: return (char)int32Value; 1901case SpecialType.System_UInt16: return (ushort)int32Value; 1902case SpecialType.System_UInt32: return (uint)int32Value; 1903case SpecialType.System_UInt64: return (ulong)int32Value; 1904case SpecialType.System_SByte: return (sbyte)int32Value; 1905case SpecialType.System_Int16: return (short)int32Value; 1906case SpecialType.System_Int32: return (int)int32Value; 1907case SpecialType.System_Int64: return (long)int32Value; 1908case SpecialType.System_IntPtr: return (int)int32Value; 1909case SpecialType.System_UIntPtr: return (uint)int32Value; 1910case SpecialType.System_Single: return (double)(float)int32Value; 1911case SpecialType.System_Double: return (double)int32Value; 1912case SpecialType.System_Decimal: return (decimal)int32Value; 1919case SpecialType.System_Byte: return (byte)int64Value; 1920case SpecialType.System_Char: return (char)int64Value; 1921case SpecialType.System_UInt16: return (ushort)int64Value; 1922case SpecialType.System_UInt32: return (uint)int64Value; 1923case SpecialType.System_UInt64: return (ulong)int64Value; 1924case SpecialType.System_SByte: return (sbyte)int64Value; 1925case SpecialType.System_Int16: return (short)int64Value; 1926case SpecialType.System_Int32: return (int)int64Value; 1927case SpecialType.System_Int64: return (long)int64Value; 1928case SpecialType.System_IntPtr: return (int)int64Value; 1929case SpecialType.System_UIntPtr: return (uint)int64Value; 1930case SpecialType.System_Single: return (double)(float)int64Value; 1931case SpecialType.System_Double: return (double)int64Value; 1932case SpecialType.System_Decimal: return (decimal)int64Value; 1939case SpecialType.System_Byte: return (byte)nintValue; 1940case SpecialType.System_Char: return (char)nintValue; 1941case SpecialType.System_UInt16: return (ushort)nintValue; 1942case SpecialType.System_UInt32: return (uint)nintValue; 1943case SpecialType.System_UInt64: return (ulong)nintValue; 1944case SpecialType.System_SByte: return (sbyte)nintValue; 1945case SpecialType.System_Int16: return (short)nintValue; 1946case SpecialType.System_Int32: return (int)nintValue; 1947case SpecialType.System_Int64: return (long)nintValue; 1948case SpecialType.System_IntPtr: return (int)nintValue; 1949case SpecialType.System_UIntPtr: return (uint)nintValue; 1950case SpecialType.System_Single: return (double)(float)nintValue; 1951case SpecialType.System_Double: return (double)nintValue; 1952case SpecialType.System_Decimal: return (decimal)nintValue; 1963case SpecialType.System_Byte: return (byte)doubleValue; 1964case SpecialType.System_Char: return (char)doubleValue; 1965case SpecialType.System_UInt16: return (ushort)doubleValue; 1966case SpecialType.System_UInt32: return (uint)doubleValue; 1967case SpecialType.System_UInt64: return (ulong)doubleValue; 1968case SpecialType.System_SByte: return (sbyte)doubleValue; 1969case SpecialType.System_Int16: return (short)doubleValue; 1970case SpecialType.System_Int32: return (int)doubleValue; 1971case SpecialType.System_Int64: return (long)doubleValue; 1972case SpecialType.System_IntPtr: return (int)doubleValue; 1973case SpecialType.System_UIntPtr: return (uint)doubleValue; 1974case SpecialType.System_Single: return (double)(float)doubleValue; 1975case SpecialType.System_Double: return (double)doubleValue; 1976case SpecialType.System_Decimal: return (value.Discriminator == ConstantValueTypeDiscriminator.Single) ? (decimal)(float)doubleValue : (decimal)doubleValue; 1983case SpecialType.System_Byte: return (byte)decimalValue; 1984case SpecialType.System_Char: return (char)decimalValue; 1985case SpecialType.System_UInt16: return (ushort)decimalValue; 1986case SpecialType.System_UInt32: return (uint)decimalValue; 1987case SpecialType.System_UInt64: return (ulong)decimalValue; 1988case SpecialType.System_SByte: return (sbyte)decimalValue; 1989case SpecialType.System_Int16: return (short)decimalValue; 1990case SpecialType.System_Int32: return (int)decimalValue; 1991case SpecialType.System_Int64: return (long)decimalValue; 1992case SpecialType.System_IntPtr: return (int)decimalValue; 1993case SpecialType.System_UIntPtr: return (uint)decimalValue; 1994case SpecialType.System_Single: return (double)(float)decimalValue; 1995case SpecialType.System_Double: return (double)decimalValue; 1996case SpecialType.System_Decimal: return (decimal)decimalValue; 2008public static bool CheckConstantBounds(SpecialType destinationType, ConstantValue value, out bool maySucceedAtRuntime) 2026private static bool CheckConstantBounds(SpecialType destinationType, double value, out bool maySucceedAtRuntime) 2034case SpecialType.System_Byte: return (byte.MinValue - 1D) < value && value < (byte.MaxValue + 1D); 2035case SpecialType.System_Char: return (char.MinValue - 1D) < value && value < (char.MaxValue + 1D); 2036case SpecialType.System_UInt16: return (ushort.MinValue - 1D) < value && value < (ushort.MaxValue + 1D); 2037case SpecialType.System_UInt32: return (uint.MinValue - 1D) < value && value < (uint.MaxValue + 1D); 2038case SpecialType.System_UInt64: return (ulong.MinValue - 1D) < value && value < (ulong.MaxValue + 1D); 2039case SpecialType.System_SByte: return (sbyte.MinValue - 1D) < value && value < (sbyte.MaxValue + 1D); 2040case SpecialType.System_Int16: return (short.MinValue - 1D) < value && value < (short.MaxValue + 1D); 2041case SpecialType.System_Int32: return (int.MinValue - 1D) < value && value < (int.MaxValue + 1D); 2043case SpecialType.System_Int64: return (long.MinValue - 1D) <= value && value < (long.MaxValue + 1D); 2044case SpecialType.System_Decimal: return ((double)decimal.MinValue - 1D) < value && value < ((double)decimal.MaxValue + 1D); 2045case SpecialType.System_IntPtr: 2048case SpecialType.System_UIntPtr: 2056private static bool CheckConstantBounds(SpecialType destinationType, decimal value, out bool maySucceedAtRuntime) 2064case SpecialType.System_Byte: return (byte.MinValue - 1M) < value && value < (byte.MaxValue + 1M); 2065case SpecialType.System_Char: return (char.MinValue - 1M) < value && value < (char.MaxValue + 1M); 2066case SpecialType.System_UInt16: return (ushort.MinValue - 1M) < value && value < (ushort.MaxValue + 1M); 2067case SpecialType.System_UInt32: return (uint.MinValue - 1M) < value && value < (uint.MaxValue + 1M); 2068case SpecialType.System_UInt64: return (ulong.MinValue - 1M) < value && value < (ulong.MaxValue + 1M); 2069case SpecialType.System_SByte: return (sbyte.MinValue - 1M) < value && value < (sbyte.MaxValue + 1M); 2070case SpecialType.System_Int16: return (short.MinValue - 1M) < value && value < (short.MaxValue + 1M); 2071case SpecialType.System_Int32: return (int.MinValue - 1M) < value && value < (int.MaxValue + 1M); 2072case SpecialType.System_Int64: return (long.MinValue - 1M) < value && value < (long.MaxValue + 1M); 2073case SpecialType.System_IntPtr: 2076case SpecialType.System_UIntPtr:
Binder\Binder_Crefs.cs (2)
373builder.Add(this.GetSpecialType(memberName == "nint" ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr, diagnostics, syntax).AsNativeInteger());
Binder\Binder_Deconstruct.cs (2)
126var voidType = GetSpecialType(SpecialType.System_Void, diagnostics, node); 693if (deconstructMethod.ReturnType.GetSpecialTypeSafe() != SpecialType.System_Void)
Binder\Binder_Expressions.cs (66)
1001if (boundArgument.Type?.SpecialType == SpecialType.System_Void) 1184TypeSymbol typedReferenceType = this.Compilation.GetSpecialType(SpecialType.System_TypedReference); 1208TypeSymbol typedReferenceType = GetSpecialType(SpecialType.System_TypedReference, diagnostics, node); 1232TypeSymbol typedReferenceType = this.Compilation.GetSpecialType(SpecialType.System_TypedReference); 1274TypeSymbol runtimeArgumentHandleType = GetSpecialType(SpecialType.System_RuntimeArgumentHandle, diagnostics, node); 1399this.GetSpecialType(SpecialType.System_Int32, diagnostics, node), hasErrors); 2349GetSpecialType(SpecialType.System_Boolean, diagnostics, node); 2352TypeSymbol intType = GetSpecialType(SpecialType.System_Int32, diagnostics, node); 2359NamedTypeSymbol nullableType = GetSpecialType(SpecialType.System_Nullable_T, diagnostics, node); 2437GetSpecialType(SpecialType.System_Boolean, diagnostics, node); 2439NamedTypeSymbol nullableType = GetSpecialType(SpecialType.System_Nullable_T, diagnostics, node); 2466NamedTypeSymbol nullableType = GetSpecialType(SpecialType.System_Nullable_T, diagnostics, operand); 3664this.Compilation.CreateArrayTypeSymbol(GetSpecialType(SpecialType.System_Object, diagnostics, node)), 3765GetSpecialType(SpecialType.System_Int32, diagnostics, nonNullSyntax)) 3846count = GenerateConversionForAssignment(GetSpecialType(SpecialType.System_Int32, diagnostics, node), count, diagnostics); 3990GetSpecialType(SpecialType.System_Int32, diagnostics, node)) 4011if (constantValue == null || constantValue.IsBad || expression.Type.SpecialType != SpecialType.System_Int32) 4034var type = expression.Type.SpecialType; 4035if (type == SpecialType.System_Int32) 4040if (type == SpecialType.System_Int64) 4047Debug.Assert(type == SpecialType.System_UInt32 || type == SpecialType.System_UInt64); 4152containingType.SpecialType == SpecialType.System_Object || 4155if ((object)initializerType == null || containingType.SpecialType == SpecialType.System_Object) //e.g. when defining System.Object in source 4375if (baseType.SpecialType == SpecialType.System_Object) 4377if (resultMember is null || resultMember.ContainingType.SpecialType != SpecialType.System_Object) 5373TypeSymbol collectionsIEnumerableType = this.GetSpecialType(SpecialType.System_Collections_IEnumerable, diagnostics, node); 5513type: GetSpecialType(SpecialType.System_Void, diagnostics, elementInitializer), 6189var specialType = type.SpecialType; 6198case SpecialType.System_SByte: 6199case SpecialType.System_Int16: 6200case SpecialType.System_Int32: 6201case SpecialType.System_Int64: 6202case SpecialType.System_Byte: 6203case SpecialType.System_UInt16: 6204case SpecialType.System_UInt32: 6205case SpecialType.System_UInt64: 6206case SpecialType.System_Single: 6207case SpecialType.System_Double: 6208case SpecialType.System_Decimal: 6209case SpecialType.System_Boolean: 6210case SpecialType.System_Char: 6251var specialType = SpecialTypeExtensions.FromRuntimeTypeOfLiteralValue(value); 6255specialType != SpecialType.None && 6256specialType != SpecialType.System_Byte && 6257specialType != SpecialType.System_SByte && 6258specialType != SpecialType.System_Int16 && 6259specialType != SpecialType.System_UInt16); 6286var type = GetWellKnownType(WellKnownType.System_ReadOnlySpan_T, diagnostics, node).Construct(GetSpecialType(SpecialType.System_Byte, diagnostics, node)); 8032var int32 = GetSpecialType(SpecialType.System_Int32, diagnostics, node); 8067TryImplicitConversionToArrayIndex(index, SpecialType.System_Int32, node, diagnostics) ?? 8068TryImplicitConversionToArrayIndex(index, SpecialType.System_UInt32, node, diagnostics) ?? 8069TryImplicitConversionToArrayIndex(index, SpecialType.System_Int64, node, diagnostics) ?? 8070TryImplicitConversionToArrayIndex(index, SpecialType.System_UInt64, node, diagnostics); 8104NamedTypeSymbol int32 = GetSpecialType(SpecialType.System_Int32, diagnostics, node); 8138private BoundExpression TryImplicitConversionToArrayIndex(BoundExpression expr, SpecialType specialType, SyntaxNode node, BindingDiagnosticBag diagnostics) 8675original.Parameters[0] is { Type.SpecialType: SpecialType.System_Int32, RefKind: RefKind.None }) 8677var intPlaceholder = new BoundImplicitIndexerValuePlaceholder(syntax, Compilation.GetSpecialType(SpecialType.System_Int32)) { WasCompilerGenerated = true }; 8693else if (receiver.Type.SpecialType == SpecialType.System_String) 8732original.Parameters[0] is { Type.SpecialType: SpecialType.System_Int32, RefKind: RefKind.None } && 8733original.Parameters[1] is { Type.SpecialType: SpecialType.System_Int32, RefKind: RefKind.None }) 8752var startArgumentPlaceholder = new BoundImplicitIndexerValuePlaceholder(syntax, Compilation.GetSpecialType(SpecialType.System_Int32)) { WasCompilerGenerated = true }; 8753var lengthArgumentPlaceholder = new BoundImplicitIndexerValuePlaceholder(syntax, Compilation.GetSpecialType(SpecialType.System_Int32)) { WasCompilerGenerated = true }; 8831getMethod.ReturnType.SpecialType == SpecialType.System_Int32 && 9412accessType = GetSpecialType(SpecialType.System_Void, diagnostics, node); 9420accessType = GetSpecialType(SpecialType.System_Nullable_T, diagnostics, node).Construct(accessType);
Binder\Binder_InterpolatedString.cs (15)
41var stringType = GetSpecialType(SpecialType.System_String, diagnostics, node); 55var intType = GetSpecialType(SpecialType.System_Int32, diagnostics, node); 167var constantValue = ConstantValue.Create(text, SpecialType.System_String); 243Debug.Assert(unconvertedInterpolatedString.Parts.All(static part => part.Type is null or { SpecialType: SpecialType.System_String })); 298=> parts.All(p => p is BoundLiteral or BoundStringInsert { Value.Type.SpecialType: SpecialType.System_String, Alignment: null, Format: null }); 371var @string = GetSpecialType(SpecialType.System_String, diagnostics, rootSyntax); 528TypeSymbol objectType = GetSpecialType(SpecialType.System_Object, diagnostics, syntax); 565var intType = GetSpecialType(SpecialType.System_Int32, diagnostics, syntax); 576var boolType = GetSpecialType(SpecialType.System_Boolean, diagnostics, syntax); 685var objectType = GetSpecialType(SpecialType.System_Object, diagnostics, unconvertedInterpolatedString.Syntax); 719Debug.Assert(part is BoundLiteral { Type: { SpecialType: SpecialType.System_String } }); 817bool methodReturnsBool = returnType.SpecialType == SpecialType.System_Boolean; 818if (!methodReturnsBool && returnType.SpecialType != SpecialType.System_Void) 830var expected = builderPatternExpectsBool == true ? Compilation.GetSpecialType(SpecialType.System_Boolean) : Compilation.GetSpecialType(SpecialType.System_Void);
Binder\Binder_Invocation.cs (12)
196TypeSymbol objType = GetSpecialType(SpecialType.System_Object, diagnostics, node); 1167Debug.Assert(parameterType.IsDynamic() || parameterType.SpecialType == SpecialType.System_Object); 1377defaultValue = new BoundLiteral(syntax, ConstantValue.Create(line), Compilation.GetSpecialType(SpecialType.System_Int32)) { WasCompilerGenerated = true }; 1382defaultValue = new BoundLiteral(syntax, ConstantValue.Create(path), Compilation.GetSpecialType(SpecialType.System_String)) { WasCompilerGenerated = true }; 1387defaultValue = new BoundLiteral(syntax, ConstantValue.Create(memberName), Compilation.GetSpecialType(SpecialType.System_String)) { WasCompilerGenerated = true }; 1391&& Conversions.ClassifyBuiltInConversion(Compilation.GetSpecialType(SpecialType.System_String), parameterType, isChecked: false, ref discardedUseSiteInfo).Exists 1396defaultValue = new BoundLiteral(syntax, ConstantValue.Create(argument.Syntax.ToString()), Compilation.GetSpecialType(SpecialType.System_String)) { WasCompilerGenerated = true }; 1401if (parameterType.IsDynamic() || parameterType.SpecialType == SpecialType.System_Object) 1421if (InAttributeArgument && parameterType.SpecialType == SpecialType.System_Object) 1432if (!conversion.IsValid && defaultConstantValue is { SpecialType: SpecialType.System_Decimal or SpecialType.System_DateTime }) 1911return new BoundNameOfOperator(node, boundArgument, ConstantValue.Create(name), Compilation.GetSpecialType(SpecialType.System_String));
Binder\Binder_Lookup.cs (10)
970var iFaceSpecial = iFaceOriginal.SpecialType; 973return iFaceSpecial == SpecialType.System_Collections_Generic_IEnumerable_T || 974iFaceSpecial == SpecialType.System_Collections_Generic_IList_T || 975iFaceSpecial == SpecialType.System_Collections_Generic_ICollection_T || 977iFaceSpecial == SpecialType.System_Collections_Generic_IReadOnlyList_T || 978iFaceSpecial == SpecialType.System_Collections_Generic_IReadOnlyCollection_T || 980iFaceSpecial == SpecialType.System_Collections_IEnumerable || 1161this.LookupMembersInClass(tmp, this.Compilation.GetSpecialType(SpecialType.System_Object), name, arity, basesBeingResolved, options, originalBinder, type, diagnose, ref useSiteInfo); 1254hiddenContainer.SpecialType != SpecialType.System_Object) 2029this.AddMemberLookupSymbolsInfoInClass(result, Compilation.GetSpecialType(SpecialType.System_Object), options, originalBinder, accessThroughType);
Binder\Binder_Operators.cs (42)
289type = this.GetSpecialType(SpecialType.System_Void, diagnostics, node); //we know the return type would have been void 322type = this.GetSpecialType(SpecialType.System_Void, diagnostics, node); 542return new BoundLiteral(node, ConstantValue.Create(kind == BinaryOperatorKind.Equal), GetSpecialType(SpecialType.System_Boolean, diagnostics, node)); 557Debug.Assert(right.Type.SpecialType == SpecialType.System_String); 707GetSpecialType(SpecialType.System_Boolean, diagnostics, node)); 852namedType.TypeArgumentsWithAnnotationsNoUseSiteDiagnostics.Single().Type.SpecialType is SpecialType.System_Byte; 905if ((object)left.Type != null && left.Type.SpecialType == SpecialType.System_Boolean && 906(object)right.Type != null && right.Type.SpecialType == SpecialType.System_Boolean) 956bool bothBool = signature.LeftType.SpecialType == SpecialType.System_Boolean && 957signature.RightType.SpecialType == SpecialType.System_Boolean; 1035var booleanType = Compilation.GetSpecialType(SpecialType.System_Boolean); 1269return GetSpecialType(SpecialType.System_Boolean, diagnostics, node); 1420(operand.Type.SpecialType == SpecialType.System_UInt64 || isNuint(operand.Type))) 1451return type.SpecialType == SpecialType.System_UIntPtr 1654internal static SpecialType GetEnumPromotedType(SpecialType underlyingType) 1658case SpecialType.System_Byte: 1659case SpecialType.System_SByte: 1660case SpecialType.System_Int16: 1661case SpecialType.System_UInt16: 1662return SpecialType.System_Int32; 1664case SpecialType.System_Int32: 1665case SpecialType.System_UInt32: 1666case SpecialType.System_Int64: 1667case SpecialType.System_UInt64: 1704SpecialType operandSpecialType = GetEnumPromotedType(underlyingType.SpecialType); 1730Debug.Assert(resultTypeSymbol.SpecialType == SpecialType.System_Boolean); 1739if (resultTypeSymbol.SpecialType != SpecialType.System_Boolean && constantValue != null && !constantValue.IsBad) 1799SpecialType resultType = resultTypeSymbol.SpecialType; 2776var upconvertSpecialType = GetEnumPromotedType(underlyingType.SpecialType); 2825SpecialType resultType = resultTypeSymbol.SpecialType; 3061return new BoundLiteral(node, ConstantValue.Create((int)-2147483648), GetSpecialType(SpecialType.System_Int32, diagnostics, node)); 3076return new BoundLiteral(node, ConstantValue.Create(-9223372036854775808), GetSpecialType(SpecialType.System_Int64, diagnostics, node)); 3176var resultType = (TypeSymbol)GetSpecialType(SpecialType.System_Boolean, diagnostics, node); 3273GetSpecialType(SpecialType.System_Object, diagnostics, node).Name // a pretty way of getting the string "Object" 3282operandType = GetSpecialType(SpecialType.System_Object, diagnostics, node); 3465if (operandType.IsValueType && targetType.IsClassType() && targetType.SpecialType != SpecialType.System_Enum || 3466targetType.IsValueType && operandType.IsClassType() && operandType.SpecialType != SpecialType.System_Enum) 3722type: GetSpecialType(SpecialType.System_Object, diagnostics, node)); 3740operandType = GetSpecialType(SpecialType.System_Object, diagnostics, node); 3747targetType = GetSpecialType(SpecialType.System_Object, diagnostics, node); 3972var objectType = GetSpecialType(SpecialType.System_Object, diagnostics, node);
Binder\Binder_Patterns.cs (26)
41node, expression, pattern, GetSpecialType(SpecialType.System_Boolean, diagnostics, node), 428if (convertedType.SpecialType == SpecialType.System_String && inputType.IsSpanOrReadOnlySpanChar()) 448bool isExplicitNotNullTest = boundType.Type.SpecialType == SpecialType.System_Object; 643if (expression.Type?.SpecialType == SpecialType.System_String && inputType.IsSpanOrReadOnlySpanChar()) 815expressionType = conversions.CorLibrary.GetSpecialType(SpecialType.System_Object); 1105var objectType = Compilation.GetSpecialType(SpecialType.System_Object); 1132var objectType = Compilation.GetSpecialType(SpecialType.System_Object); 1251if (declType != (object)Compilation.GetSpecialType(SpecialType.System_Object) && 1481if (memberType.SpecialType == SpecialType.System_Int32 && 1610bool isExplicitNotNullTest = patternType.Type.SpecialType == SpecialType.System_Object; 1687SpecialType.System_Single => BinaryOperatorKind.Float, 1688SpecialType.System_Double => BinaryOperatorKind.Double, 1689SpecialType.System_Char => BinaryOperatorKind.Char, 1690SpecialType.System_SByte => BinaryOperatorKind.Int, // operands are converted to int 1691SpecialType.System_Byte => BinaryOperatorKind.Int, // operands are converted to int 1692SpecialType.System_UInt16 => BinaryOperatorKind.Int, // operands are converted to int 1693SpecialType.System_Int16 => BinaryOperatorKind.Int, // operands are converted to int 1694SpecialType.System_Int32 => BinaryOperatorKind.Int, 1695SpecialType.System_UInt32 => BinaryOperatorKind.UInt, 1696SpecialType.System_Int64 => BinaryOperatorKind.Long, 1697SpecialType.System_UInt64 => BinaryOperatorKind.ULong, 1698SpecialType.System_Decimal => BinaryOperatorKind.Decimal, 1699SpecialType.System_String => BinaryOperatorKind.String, 1700SpecialType.System_Boolean => BinaryOperatorKind.Bool, 1701SpecialType.System_IntPtr when type.IsNativeIntegerType => BinaryOperatorKind.NInt, 1702SpecialType.System_UIntPtr when type.IsNativeIntegerType => BinaryOperatorKind.NUInt,
Binder\Binder_QueryErrors.cs (2)
89var ienumerable_t = Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T); 127var ienumerable = Compilation.GetSpecialType(SpecialType.System_Collections_IEnumerable);
Binder\Binder_Statements.cs (11)
1287if (initializerType.SpecialType == SpecialType.System_String && 1288((object)fixedPatternMethod == null || fixedPatternMethod.ContainingType.SpecialType != SpecialType.System_String)) 1291elementType = this.GetSpecialType(SpecialType.System_Char, diagnostics, initializerSyntax); 1524type = this.GetSpecialType(SpecialType.System_Void, diagnostics, node); 2208if (sourceType.SpecialType == SpecialType.System_Double && syntax.Kind() == SyntaxKind.NumericLiteralExpression && 2209(targetType.SpecialType == SpecialType.System_Single || targetType.SpecialType == SpecialType.System_Decimal)) 2211Error(diagnostics, ErrorCode.ERR_LiteralDoubleCast, syntax, (targetType.SpecialType == SpecialType.System_Single) ? "F" : "M", targetType); 2539var boolean = GetSpecialType(SpecialType.System_Boolean, diagnostics, node); 3414else if (expression.Type?.SpecialType == SpecialType.System_Void) 3727if (baseType.SpecialType == SpecialType.System_Object)
Binder\Binder_Symbols.cs (9)
991var specialType = 992node.IsNint ? SpecialType.System_IntPtr : 993node.IsNuint ? SpecialType.System_UIntPtr : SpecialType.None; 995if (specialType == SpecialType.None) 1058this.GetSpecialType(SpecialType.System_Boolean, diagnostics, node); 1632internal NamedTypeSymbol GetSpecialType(SpecialType typeId, BindingDiagnosticBag diagnostics, SyntaxNode node) 1637internal static NamedTypeSymbol GetSpecialType(CSharpCompilation compilation, SpecialType typeId, SyntaxNode node, BindingDiagnosticBag diagnostics) 1645internal static NamedTypeSymbol GetSpecialType(CSharpCompilation compilation, SpecialType typeId, Location location, BindingDiagnosticBag diagnostics)
Binder\Binder_TupleOperators.cs (3)
33TypeSymbol resultType = GetSpecialType(SpecialType.System_Boolean, diagnostics, node); 131TypeSymbol boolean = GetSpecialType(SpecialType.System_Boolean, diagnostics, node); 420NamedTypeSymbol nullableT = GetSpecialType(SpecialType.System_Nullable_T, diagnostics, syntax);
Binder\DecisionDagBuilder.cs (56)
323var objectType = this._compilation.GetSpecialType(SpecialType.System_Object); 325RoslynDebug.Assert(getLengthProperty.Type.SpecialType == SpecialType.System_Int32); 339var lengthTemp = new BoundDagTemp(syntax, this._compilation.GetSpecialType(SpecialType.System_Int32), lengthEvaluation); 461if (input.Type.IsDynamic() ? type.SpecialType == SpecialType.System_Object : conversion.IsImplicit) 1515case (SpecialType.System_SByte, SpecialType.System_Byte): 1516case (SpecialType.System_Byte, SpecialType.System_SByte): 1517case (SpecialType.System_Int16, SpecialType.System_UInt16): 1518case (SpecialType.System_UInt16, SpecialType.System_Int16): 1519case (SpecialType.System_Int32, SpecialType.System_UInt32): 1520case (SpecialType.System_UInt32, SpecialType.System_Int32): 1521case (SpecialType.System_Int64, SpecialType.System_UInt64): 1522case (SpecialType.System_UInt64, SpecialType.System_Int64): 1523case (SpecialType.System_IntPtr, SpecialType.System_UIntPtr): 1524case (SpecialType.System_UIntPtr, SpecialType.System_IntPtr): 1529case (SpecialType.System_Int32, SpecialType.System_IntPtr): 1530case (SpecialType.System_Int32, SpecialType.System_UIntPtr): 1531case (SpecialType.System_UInt32, SpecialType.System_IntPtr): 1532case (SpecialType.System_UInt32, SpecialType.System_UIntPtr): 1533case (SpecialType.System_IntPtr, SpecialType.System_Int32): 1534case (SpecialType.System_IntPtr, SpecialType.System_UInt32): 1535case (SpecialType.System_UIntPtr, SpecialType.System_Int32): 1536case (SpecialType.System_UIntPtr, SpecialType.System_UInt32): 1541case (SpecialType.System_Int64, SpecialType.System_IntPtr): 1542case (SpecialType.System_Int64, SpecialType.System_UIntPtr): 1543case (SpecialType.System_UInt64, SpecialType.System_IntPtr): 1544case (SpecialType.System_UInt64, SpecialType.System_UIntPtr): 1545case (SpecialType.System_IntPtr, SpecialType.System_Int64): 1546case (SpecialType.System_IntPtr, SpecialType.System_UInt64): 1547case (SpecialType.System_UIntPtr, SpecialType.System_Int64): 1548case (SpecialType.System_UIntPtr, SpecialType.System_UInt64):
Binder\DecisionDagBuilder_ListPatterns.cs (1)
43var lengthTemp = new BoundDagTemp(syntax, _compilation.GetSpecialType(SpecialType.System_Int32), lengthEvaluation);
Binder\ForEachLoopBinder.cs (22)
243if (!hasErrors && awaitInfo.GetResult?.ReturnType.SpecialType != SpecialType.System_Boolean) 572(collectionConversionClassification.Kind == ConversionKind.ExplicitReference && collectionExpr.Type.SpecialType == SpecialType.System_String)); 629else if (collectionExpr.Type.SpecialType == SpecialType.System_String && builder.CollectionType.SpecialType == SpecialType.System_Collections_IEnumerable) 635inferredType = TypeWithAnnotations.Create(GetSpecialType(SpecialType.System_Char, diagnostics, collectionExpr.Syntax)); 826if (!isAsync && collectionExprType.SpecialType == SpecialType.System_String) 888this.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T)); 920Debug.Assert(collectionType.OriginalDefinition.SpecialType == SpecialType.System_Collections_Generic_IEnumerable_T); 983Debug.Assert(collectionType.SpecialType == SpecialType.System_Collections_IEnumerable); 988builder.ElementTypeWithAnnotations = builder.CurrentPropertyGetter?.ReturnTypeWithAnnotations ?? TypeWithAnnotations.Create(GetSpecialType(SpecialType.System_Object, diagnostics, errorLocationSyntax)); 991builder.GetEnumeratorInfo.Method.ReturnType.SpecialType == SpecialType.System_Collections_IEnumerator); 1063isAsync ? this.Compilation.GetWellKnownType(WellKnownType.System_IAsyncDisposable) : this.Compilation.GetSpecialType(SpecialType.System_IDisposable), 1076builder.CollectionType = GetSpecialType(SpecialType.System_Collections_IEnumerable, diagnostics, _syntax); 1083GetSpecialType(SpecialType.System_Object, diagnostics, _syntax)); 1087builder.ElementTypeWithAnnotations = collectionExprType.SpecialType == SpecialType.System_String ? 1088TypeWithAnnotations.Create(GetSpecialType(SpecialType.System_Char, diagnostics, _syntax)) : 1100TypeSymbol.Equals(builder.GetEnumeratorInfo.Method.ReturnType, this.Compilation.GetSpecialType(SpecialType.System_Collections_IEnumerator), TypeCompareKind.ConsiderEverything2)); 1498return moveNextMethodCandidate.OriginalDefinition.ReturnType.SpecialType != SpecialType.System_Boolean; 1516case SpecialType.System_Collections_IEnumerable: 1517case SpecialType.System_Collections_Generic_IEnumerable_T: 1557var implementedNonGeneric = this.Compilation.GetSpecialType(SpecialType.System_Collections_IEnumerable); 1630return type.SpecialType == SpecialType.System_Collections_Generic_IEnumerable_T;
Binder\InContainerBinder.cs (1)
94return TypeWithAnnotations.Create(this.Compilation.GetSpecialType(SpecialType.System_Object));
Binder\InMethodBinder.cs (5)
153case SpecialType.System_Collections_IEnumerable: 154case SpecialType.System_Collections_IEnumerator: 155var objectType = compilation.GetSpecialType(SpecialType.System_Object); 162case SpecialType.System_Collections_Generic_IEnumerable_T: 163case SpecialType.System_Collections_Generic_IEnumerator_T:
Binder\PatternExplainer.cs (28)
674if (underlyingType.SpecialType == SpecialType.System_IntPtr) 682else if (underlyingType.SpecialType == SpecialType.System_UIntPtr) 700SpecialType.System_Int32 => true, 701SpecialType.System_Int64 => true, 702SpecialType.System_UInt32 => true, 703SpecialType.System_UInt64 => true, 704SpecialType.System_String => true, 705SpecialType.System_Decimal => true, 706SpecialType.System_Single => true, 707SpecialType.System_Double => true, 708SpecialType.System_Boolean => true, 709SpecialType.System_Char => true, 721case SpecialType.System_Boolean: 722case SpecialType.System_Byte: 723case SpecialType.System_SByte: 724case SpecialType.System_UInt16: 725case SpecialType.System_Int16: 726case SpecialType.System_Int32: 727case SpecialType.System_UInt32: 728case SpecialType.System_UInt64: 729case SpecialType.System_Int64: 730case SpecialType.System_IntPtr when type.IsNativeIntegerType: 731case SpecialType.System_UIntPtr when type.IsNativeIntegerType: 732case SpecialType.System_Decimal: 733case SpecialType.System_Char: 734case SpecialType.System_String: 737case SpecialType.System_Single: 746case SpecialType.System_Double:
Binder\Semantics\Conversions\Conversions.cs (3)
80SpecialType.System_Decimal => WellKnownMember.System_Runtime_CompilerServices_DecimalConstantAttribute__ctor, 81SpecialType.System_DateTime => WellKnownMember.System_Runtime_CompilerServices_DateTimeConstantAttribute__ctor, 320TypeWithAnnotations.Create(compilation.GetSpecialType(SpecialType.System_Object), customModifiers: parameter.TypeWithAnnotations.CustomModifiers), parameter.RefCustomModifiers, parameter.IsParams, parameter.RefKind);
Binder\Semantics\Conversions\ConversionsBase.cs (85)
241var sourceIsVoid = source?.SpecialType == SpecialType.System_Void; 242var destIsVoid = destination.SpecialType == SpecialType.System_Void; 1202if (nt.OriginalDefinition.GetSpecialTypeSafe() == SpecialType.System_Nullable_T && 1229if (nt.OriginalDefinition.GetSpecialTypeSafe() == SpecialType.System_Nullable_T) 1260if (nt.OriginalDefinition.GetSpecialTypeSafe() == SpecialType.System_Nullable_T) 1288var specialSource = source.Type.GetSpecialTypeSafe(); 1290if (specialSource == SpecialType.System_Int32) 1296case SpecialType.System_Byte: 1298case SpecialType.System_SByte: 1300case SpecialType.System_Int16: 1302case SpecialType.System_IntPtr when destination.IsNativeIntegerType: 1304case SpecialType.System_UInt32: 1305case SpecialType.System_UIntPtr when destination.IsNativeIntegerType: 1307case SpecialType.System_UInt64: 1309case SpecialType.System_UInt16: 1315else if (specialSource == SpecialType.System_Int64 && destination.GetSpecialTypeSafe() == SpecialType.System_UInt64 && (constantValue.IsBad || 0 <= constantValue.Int64Value)) 1543var multicastDelegateType = corLibrary.GetSpecialType(SpecialType.System_MulticastDelegate); 1616TypeSymbol expectedAttributeType = corLibrary.GetSpecialType(SpecialType.System_Int32); 1643TypeSymbol expectedAttributeType = corLibrary.GetSpecialType(SpecialType.System_String); 1954case SpecialType.System_Char: 1955case SpecialType.System_SByte: 1956case SpecialType.System_Byte: 1957case SpecialType.System_Int16: 1958case SpecialType.System_UInt16: 1959case SpecialType.System_Int32: 1960case SpecialType.System_UInt32: 1961case SpecialType.System_Int64: 1962case SpecialType.System_UInt64: 1963case SpecialType.System_Single: 1964case SpecialType.System_Double: 1965case SpecialType.System_Decimal: 1966case SpecialType.System_IntPtr when type.IsNativeIntegerType: 1967case SpecialType.System_UIntPtr when type.IsNativeIntegerType: 2039case SpecialType.System_SByte: 2040case SpecialType.System_Byte: 2041case SpecialType.System_Int16: 2042case SpecialType.System_UInt16: 2043case SpecialType.System_Char: 2044case SpecialType.System_Int32: 2045case SpecialType.System_UInt32: 2046case SpecialType.System_Int64: 2047case SpecialType.System_UInt64: 2048case SpecialType.System_Double: 2049case SpecialType.System_Single: 2050case SpecialType.System_Decimal: 2057(type.SpecialType == SpecialType.System_IntPtr || type.SpecialType == SpecialType.System_UIntPtr) && !type.IsNativeIntegerType; 2426if (destination.SpecialType == SpecialType.System_Collections_IEnumerable) 2496if (destination.SpecialType == SpecialType.System_Object || destination.Kind == SymbolKind.DynamicType) 2590if (destination.GetSpecialTypeSafe() == SpecialType.System_Array) 2595if (IsBaseInterface(destination, this.corLibrary.GetDeclaredSpecialType(SpecialType.System_Array), ref useSiteInfo)) 2628var specialDestination = destination.GetSpecialTypeSafe(); 2630if (specialDestination == SpecialType.System_MulticastDelegate || 2631specialDestination == SpecialType.System_Delegate || 2632IsBaseInterface(destination, this.corLibrary.GetDeclaredSpecialType(SpecialType.System_MulticastDelegate), ref useSiteInfo)) 2661if (destination.SpecialType == SpecialType.System_MulticastDelegate) 2671var derivedType = this.corLibrary.GetDeclaredSpecialType(SpecialType.System_MulticastDelegate); 3144return source.IsPointerOrFunctionPointer() && destination is PointerTypeSymbol { PointedAtType: { SpecialType: SpecialType.System_Void } }; 3235if (source.SpecialType == SpecialType.System_Object) 3403if (source.SpecialType == SpecialType.System_Delegate || source.SpecialType == SpecialType.System_MulticastDelegate) 3408if (HasImplicitConversionToInterface(this.corLibrary.GetDeclaredSpecialType(SpecialType.System_Delegate), source, ref useSiteInfo)) 3510if (source.SpecialType == SpecialType.System_Array) 3515foreach (var iface in this.corLibrary.GetDeclaredSpecialType(SpecialType.System_Array).AllInterfacesWithDefinitionUseSiteDiagnostics(ref useSiteInfo)) 3544var specialDefinition = ((TypeSymbol)source.OriginalDefinition).SpecialType; 3546if (specialDefinition == SpecialType.System_Collections_Generic_IList_T || 3547specialDefinition == SpecialType.System_Collections_Generic_ICollection_T || 3548specialDefinition == SpecialType.System_Collections_Generic_IEnumerable_T || 3549specialDefinition == SpecialType.System_Collections_Generic_IReadOnlyList_T || 3550specialDefinition == SpecialType.System_Collections_Generic_IReadOnlyCollection_T) 3593var specialTypeSource = source.SpecialType; 3595if (specialTypeSource == SpecialType.System_Object || specialTypeSource == SpecialType.System_ValueType) 3614if (source.SpecialType == SpecialType.System_Enum && destination.IsEnumType()) 3687case SpecialType.System_SByte: 3688case SpecialType.System_Byte: 3689case SpecialType.System_Int16: 3690case SpecialType.System_UInt16: 3691case SpecialType.System_Int32: 3692case SpecialType.System_UInt32: 3693case SpecialType.System_Int64: 3694case SpecialType.System_UInt64: 3696case SpecialType.System_IntPtr: 3697case SpecialType.System_UIntPtr:
Binder\Semantics\Conversions\UserDefinedImplicitConversions.cs (1)
872var nullable = this.corLibrary.GetDeclaredSpecialType(SpecialType.System_Nullable_T);
Binder\Semantics\Operators\BinaryOperatorEasyOut.cs (3)
354if (left.Type.SpecialType == SpecialType.System_Int32 || 355left.Type.SpecialType == SpecialType.System_Boolean || 356left.Type.SpecialType == SpecialType.System_String)
Binder\Semantics\Operators\BinaryOperatorOverloadResolution.cs (27)
312operators.Add(new BinaryOperatorSignature(kind | BinaryOperatorKind.Delegate, delegateType, delegateType, Compilation.GetSpecialType(SpecialType.System_Boolean))); 380TypeSymbol systemDelegateType = _binder.Compilation.GetSpecialType(SpecialType.System_Delegate); 476Debug.Assert(underlying.SpecialType != SpecialType.None); 478var nullable = Compilation.GetSpecialType(SpecialType.System_Nullable_T); 528var boolean = Compilation.GetSpecialType(SpecialType.System_Boolean); 552operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerAndIntAddition, pointerType, Compilation.GetSpecialType(SpecialType.System_Int32), pointerType)); 553operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerAndUIntAddition, pointerType, Compilation.GetSpecialType(SpecialType.System_UInt32), pointerType)); 554operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerAndLongAddition, pointerType, Compilation.GetSpecialType(SpecialType.System_Int64), pointerType)); 555operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerAndULongAddition, pointerType, Compilation.GetSpecialType(SpecialType.System_UInt64), pointerType)); 556operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.IntAndPointerAddition, Compilation.GetSpecialType(SpecialType.System_Int32), pointerType, pointerType)); 557operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.UIntAndPointerAddition, Compilation.GetSpecialType(SpecialType.System_UInt32), pointerType, pointerType)); 558operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.LongAndPointerAddition, Compilation.GetSpecialType(SpecialType.System_Int64), pointerType, pointerType)); 559operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.ULongAndPointerAddition, Compilation.GetSpecialType(SpecialType.System_UInt64), pointerType, pointerType)); 562operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerAndIntSubtraction, pointerType, Compilation.GetSpecialType(SpecialType.System_Int32), pointerType)); 563operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerAndUIntSubtraction, pointerType, Compilation.GetSpecialType(SpecialType.System_UInt32), pointerType)); 564operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerAndLongSubtraction, pointerType, Compilation.GetSpecialType(SpecialType.System_Int64), pointerType)); 565operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerAndULongSubtraction, pointerType, Compilation.GetSpecialType(SpecialType.System_UInt64), pointerType)); 566operators.Add(new BinaryOperatorSignature(BinaryOperatorKind.PointerSubtraction, pointerType, pointerType, Compilation.GetSpecialType(SpecialType.System_Int64))); 583var voidPointerType = new PointerTypeSymbol(TypeWithAnnotations.Create(Compilation.GetSpecialType(SpecialType.System_Void))); 584operators.Add(new BinaryOperatorSignature(kind | BinaryOperatorKind.Pointer, voidPointerType, voidPointerType, Compilation.GetSpecialType(SpecialType.System_Boolean))); 750((object)left.Type == null || (!left.Type.IsDelegateType() && left.Type.SpecialType != SpecialType.System_String && left.Type.SpecialType != SpecialType.System_Delegate)) && 751((object)right.Type == null || (!right.Type.IsDelegateType() && right.Type.SpecialType != SpecialType.System_String && right.Type.SpecialType != SpecialType.System_Delegate)); 762var @object = Compilation.GetSpecialType(SpecialType.System_Object); 763operators.Add(new BinaryOperatorSignature(kind | BinaryOperatorKind.Object, @object, @object, Compilation.GetSpecialType(SpecialType.System_Boolean))); 1023return result.SpecialType == SpecialType.System_Boolean ?
Binder\Semantics\Operators\OperatorFacts.cs (23)
34case SpecialType.System_Array: 35case SpecialType.System_Boolean: 36case SpecialType.System_Byte: 37case SpecialType.System_Char: 38case SpecialType.System_Decimal: 39case SpecialType.System_Delegate: 40case SpecialType.System_Double: 41case SpecialType.System_Enum: 42case SpecialType.System_Int16: 43case SpecialType.System_Int32: 44case SpecialType.System_Int64: 45case SpecialType.System_IntPtr when type.IsNativeIntegerType: 46case SpecialType.System_UIntPtr when type.IsNativeIntegerType: 47case SpecialType.System_MulticastDelegate: 48case SpecialType.System_Object: 49case SpecialType.System_SByte: 50case SpecialType.System_Single: 51case SpecialType.System_String: 52case SpecialType.System_UInt16: 53case SpecialType.System_UInt32: 54case SpecialType.System_UInt64: 55case SpecialType.System_ValueType: 56case SpecialType.System_Void:
Binder\Semantics\Operators\OperatorKindExtensions.cs (10)
147public static BinaryOperatorKind WithType(this BinaryOperatorKind kind, SpecialType type) 152case SpecialType.System_Int32: 154case SpecialType.System_UInt32: 156case SpecialType.System_Int64: 158case SpecialType.System_UInt64: 165public static UnaryOperatorKind WithType(this UnaryOperatorKind kind, SpecialType type) 170case SpecialType.System_Int32: 172case SpecialType.System_UInt32: 174case SpecialType.System_Int64: 176case SpecialType.System_UInt64:
Binder\Semantics\Operators\UnaryOperatorOverloadResolution.cs (1)
20return Compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(type);
Binder\Semantics\OverloadResolution\MethodTypeInference.cs (2)
1302if (!returnType.HasType || returnType.SpecialType == SpecialType.System_Void) 1357if (!sourceReturnType.HasType || sourceReturnType.SpecialType == SpecialType.System_Void)
Binder\Semantics\OverloadResolution\OverloadResolution.cs (15)
1306if (type.SpecialType == SpecialType.System_Object && currentType.SpecialType != SpecialType.System_Object) 1368if (type.IsClassType() && type.GetSpecialTypeSafe() != SpecialType.System_Object) 2317t1.IsDynamic() && t2.SpecialType == SpecialType.System_Object || 2318t2.IsDynamic() && t1.SpecialType == SpecialType.System_Object); 3040case SpecialType.System_SByte: 3041case SpecialType.System_Int16: 3042case SpecialType.System_Int32: 3043case SpecialType.System_Int64: 3044case SpecialType.System_IntPtr when type.IsNativeIntegerType: 3061case SpecialType.System_Byte: 3062case SpecialType.System_UInt16: 3063case SpecialType.System_UInt32: 3064case SpecialType.System_UInt64: 3065case SpecialType.System_UIntPtr when type.IsNativeIntegerType:
Binder\SwitchBinder.cs (1)
397if (switchGoverningType.SpecialType == SpecialType.System_Boolean)
Binder\UsingStatementBinder.cs (1)
294: originalBinder.Compilation.GetSpecialType(SpecialType.System_IDisposable);
BoundTree\UnboundLambda.cs (3)
723returnType = TypeWithAnnotations.Create(Binder.Compilation.GetSpecialType(SpecialType.System_Void)); 924? TypeWithAnnotations.Create(this.Binder.Compilation.GetSpecialType(SpecialType.System_Void)) 1172? this.Binder.Compilation.GetSpecialType(SpecialType.System_Void)
CodeGen\EmitArrayInitializer.cs (15)
441SpecialType specialElementType = SpecialType.None; 696private static bool IsTypeAllowedInBlobWrapper(SpecialType type) => type is 700SpecialType.System_SByte or SpecialType.System_Byte or SpecialType.System_Boolean or 706SpecialType.System_Int16 or SpecialType.System_UInt16 or SpecialType.System_Char or 709SpecialType.System_Int32 or SpecialType.System_UInt32 or SpecialType.System_Single or 712SpecialType.System_Int64 or SpecialType.System_UInt64 or SpecialType.System_Double;
CodeGen\EmitConversion.cs (4)
384if (parameters[0].Type.SpecialType != SpecialType.System_Object) continue; 385var p1t = parameters[1].Type.SpecialType; 386if (p1t == SpecialType.System_IntPtr || p1t == SpecialType.System_UIntPtr)
CodeGen\EmitExpression.cs (34)
52(expression.Type.SpecialType != SpecialType.System_Decimal && 1099Debug.Assert(!field.IsConst || field.ContainingType.SpecialType == SpecialType.System_Decimal, 1296case SpecialType.System_Byte: 1298case SpecialType.System_Int16: 1300case SpecialType.System_Int32: 1302case SpecialType.System_Int64: 1304case SpecialType.System_Char: 1306case SpecialType.System_Boolean: 1308case SpecialType.System_SByte: 1310case SpecialType.System_UInt16: 1312case SpecialType.System_UInt32: 1314case SpecialType.System_UInt64: 1316case SpecialType.System_IntPtr: 1318case SpecialType.System_UIntPtr: 1320case SpecialType.System_Single: 1322case SpecialType.System_Double: 1324case SpecialType.System_RuntimeTypeHandle: 1326case SpecialType.System_RuntimeFieldHandle: 1328case SpecialType.System_RuntimeMethodHandle: 1330case SpecialType.System_RuntimeArgumentHandle: 2095return containingType.SpecialType != SpecialType.None; 2124Debug.Assert(expression.Type.SpecialType == SpecialType.System_Int32 || 2125expression.Type.SpecialType == SpecialType.System_Int64 || 2126expression.Type.SpecialType == SpecialType.System_UIntPtr); 2386if (rightType.IsReferenceType || (right.ConstantValueOpt != null && rightType.SpecialType != SpecialType.System_Decimal)) 3214if (!type.IsTypeParameter() && type.SpecialType != SpecialType.System_Decimal) 3224if (type.IsPointerOrFunctionPointer() || type.SpecialType == SpecialType.System_UIntPtr) 3230else if (type.SpecialType == SpecialType.System_IntPtr) 3244Debug.Assert(expression.Type.SpecialType == SpecialType.System_Decimal || 3308Debug.Assert(node.Type.SpecialType == SpecialType.System_Int32); 3325Debug.Assert(node.Type.SpecialType == SpecialType.System_Int32); 3339Debug.Assert(node.Type.SpecialType == SpecialType.System_Int32); 3362Debug.Assert(node.Type.SpecialType == SpecialType.System_Int32); 3409Debug.Assert(node.Type.SpecialType == SpecialType.System_Int32);
CodeGen\EmitOperators.cs (21)
305Debug.Assert(binOp.Left.Type.SpecialType == SpecialType.System_Boolean); 306Debug.Assert(binOp.Right.Type.SpecialType == SpecialType.System_Boolean); 314Debug.Assert(binOp.Left.Type.SpecialType == SpecialType.System_Boolean); 315Debug.Assert(binOp.Right.Type.SpecialType == SpecialType.System_Boolean); 331Debug.Assert(binOp.Left.Type.SpecialType == SpecialType.System_Boolean); 332Debug.Assert(binOp.Right.Type.SpecialType == SpecialType.System_Boolean); 337Debug.Assert(binOp.Left.Type.SpecialType == SpecialType.System_Boolean); 338Debug.Assert(binOp.Right.Type.SpecialType == SpecialType.System_Boolean); 343Debug.Assert(binOp.Left.Type.SpecialType == SpecialType.System_Boolean); 344Debug.Assert(binOp.Right.Type.SpecialType == SpecialType.System_Boolean); 482Debug.Assert(condition.Type.SpecialType == SpecialType.System_Boolean); 606SpecialType type = enumType.GetEnumUnderlyingType().SpecialType; 609case SpecialType.System_Byte: 612case SpecialType.System_SByte: 615case SpecialType.System_Int16: 618case SpecialType.System_UInt16: 691private static bool IsUnsigned(SpecialType type) 695case SpecialType.System_Byte: 696case SpecialType.System_UInt16: 697case SpecialType.System_UInt32: 698case SpecialType.System_UInt64:
CodeGen\EmitStatement.cs (8)
1025_module.GetSpecialType(SpecialType.System_Object, catchBlock.Syntax, _diagnostics.DiagnosticBag); 1283expression.Type.SpecialType == SpecialType.System_String || expression.Type.IsSpanOrReadOnlySpanChar()); 1286if (expression.Type.SpecialType == SpecialType.System_String || expression.Type.IsSpanOrReadOnlySpanChar()) 1368var int32Type = Binder.GetSpecialType(_module.Compilation, SpecialType.System_Int32, syntaxNode, _diagnostics); 1393var charType = Binder.GetSpecialType(_module.Compilation, SpecialType.System_Char, syntaxNode, _diagnostics); 1495var UInt32Type = Binder.GetSpecialType(_module.Compilation, SpecialType.System_UInt32, syntaxNode, _diagnostics); 1516var sequenceEqualsCharMethod = sequenceEqualsTMethod.Construct(Binder.GetSpecialType(_module.Compilation, SpecialType.System_Char, syntaxNode, _diagnostics)); 1776? _module.GetSpecialType(SpecialType.System_IntPtr, syntaxNode, _diagnostics.DiagnosticBag)
Compilation\BuiltInOperators.cs (57)
264case UnaryOperatorKind.SByte: opType = _compilation.GetSpecialType(SpecialType.System_SByte); break; 265case UnaryOperatorKind.Byte: opType = _compilation.GetSpecialType(SpecialType.System_Byte); break; 266case UnaryOperatorKind.Short: opType = _compilation.GetSpecialType(SpecialType.System_Int16); break; 267case UnaryOperatorKind.UShort: opType = _compilation.GetSpecialType(SpecialType.System_UInt16); break; 268case UnaryOperatorKind.Int: opType = _compilation.GetSpecialType(SpecialType.System_Int32); break; 269case UnaryOperatorKind.UInt: opType = _compilation.GetSpecialType(SpecialType.System_UInt32); break; 270case UnaryOperatorKind.Long: opType = _compilation.GetSpecialType(SpecialType.System_Int64); break; 271case UnaryOperatorKind.ULong: opType = _compilation.GetSpecialType(SpecialType.System_UInt64); break; 274case UnaryOperatorKind.Char: opType = _compilation.GetSpecialType(SpecialType.System_Char); break; 275case UnaryOperatorKind.Float: opType = _compilation.GetSpecialType(SpecialType.System_Single); break; 276case UnaryOperatorKind.Double: opType = _compilation.GetSpecialType(SpecialType.System_Double); break; 277case UnaryOperatorKind.Decimal: opType = _compilation.GetSpecialType(SpecialType.System_Decimal); break; 278case UnaryOperatorKind.Bool: opType = _compilation.GetSpecialType(SpecialType.System_Boolean); break; 284opType = _compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(opType); 693Debug.Assert(((NamedTypeSymbol)readonlySpanOfByte).TypeArgumentsWithAnnotationsNoUseSiteDiagnostics.Single().Type.SpecialType is SpecialType.System_Byte); 723TypeSymbol rightType = _compilation.GetSpecialType(SpecialType.System_Int32); 726rightType = _compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(rightType); 736return new BinaryOperatorSignature(kind, left, left, _compilation.GetSpecialType(SpecialType.System_Boolean)); 751case BinaryOperatorKind.Int: return _compilation.GetSpecialType(SpecialType.System_Int32); 752case BinaryOperatorKind.UInt: return _compilation.GetSpecialType(SpecialType.System_UInt32); 753case BinaryOperatorKind.Long: return _compilation.GetSpecialType(SpecialType.System_Int64); 754case BinaryOperatorKind.ULong: return _compilation.GetSpecialType(SpecialType.System_UInt64); 757case BinaryOperatorKind.Float: return _compilation.GetSpecialType(SpecialType.System_Single); 758case BinaryOperatorKind.Double: return _compilation.GetSpecialType(SpecialType.System_Double); 759case BinaryOperatorKind.Decimal: return _compilation.GetSpecialType(SpecialType.System_Decimal); 760case BinaryOperatorKind.Bool: return _compilation.GetSpecialType(SpecialType.System_Boolean); 763return _compilation.GetSpecialType(SpecialType.System_Object); 766return _compilation.GetSpecialType(SpecialType.System_String); 783case BinaryOperatorKind.Int: return _compilation.GetSpecialType(SpecialType.System_Int32); 784case BinaryOperatorKind.UInt: return _compilation.GetSpecialType(SpecialType.System_UInt32); 785case BinaryOperatorKind.Long: return _compilation.GetSpecialType(SpecialType.System_Int64); 786case BinaryOperatorKind.ULong: return _compilation.GetSpecialType(SpecialType.System_UInt64); 789case BinaryOperatorKind.Float: return _compilation.GetSpecialType(SpecialType.System_Single); 790case BinaryOperatorKind.Double: return _compilation.GetSpecialType(SpecialType.System_Double); 791case BinaryOperatorKind.Decimal: return _compilation.GetSpecialType(SpecialType.System_Decimal); 792case BinaryOperatorKind.Bool: return _compilation.GetSpecialType(SpecialType.System_Boolean); 795return _compilation.GetSpecialType(SpecialType.System_String); 798return _compilation.GetSpecialType(SpecialType.System_Object); 815case BinaryOperatorKind.Int: return _compilation.GetSpecialType(SpecialType.System_Int32); 816case BinaryOperatorKind.UInt: return _compilation.GetSpecialType(SpecialType.System_UInt32); 817case BinaryOperatorKind.Long: return _compilation.GetSpecialType(SpecialType.System_Int64); 818case BinaryOperatorKind.ULong: return _compilation.GetSpecialType(SpecialType.System_UInt64); 821case BinaryOperatorKind.Float: return _compilation.GetSpecialType(SpecialType.System_Single); 822case BinaryOperatorKind.Double: return _compilation.GetSpecialType(SpecialType.System_Double); 823case BinaryOperatorKind.Decimal: return _compilation.GetSpecialType(SpecialType.System_Decimal); 824case BinaryOperatorKind.Bool: return _compilation.GetSpecialType(SpecialType.System_Boolean); 825case BinaryOperatorKind.Object: return _compilation.GetSpecialType(SpecialType.System_Object); 829return _compilation.GetSpecialType(SpecialType.System_String); 840var nullable = _compilation.GetSpecialType(SpecialType.System_Nullable_T); 844case BinaryOperatorKind.Int: return nullable.Construct(_compilation.GetSpecialType(SpecialType.System_Int32)); 845case BinaryOperatorKind.UInt: return nullable.Construct(_compilation.GetSpecialType(SpecialType.System_UInt32)); 846case BinaryOperatorKind.Long: return nullable.Construct(_compilation.GetSpecialType(SpecialType.System_Int64)); 847case BinaryOperatorKind.ULong: return nullable.Construct(_compilation.GetSpecialType(SpecialType.System_UInt64)); 850case BinaryOperatorKind.Float: return nullable.Construct(_compilation.GetSpecialType(SpecialType.System_Single)); 851case BinaryOperatorKind.Double: return nullable.Construct(_compilation.GetSpecialType(SpecialType.System_Double)); 852case BinaryOperatorKind.Decimal: return nullable.Construct(_compilation.GetSpecialType(SpecialType.System_Decimal)); 853case BinaryOperatorKind.Bool: return nullable.Construct(_compilation.GetSpecialType(SpecialType.System_Boolean));
Compilation\CSharpCompilation.cs (35)
788return info.ConvertedType?.SpecialType != SpecialType.System_Void; 1546internal new NamedTypeSymbol GetSpecialType(SpecialType specialType) 1548if (specialType <= SpecialType.None || specialType > SpecialType.Count) 1623SpecialType.None, 1994if (method.ReturnType.IsVoidType() || method.ReturnType.SpecialType == SpecialType.System_Int32) 2019(result!.Type!.IsVoidType() || result.Type!.SpecialType == SpecialType.System_Int32); 2038if (returnType.SpecialType != SpecialType.System_Int32 && !returnType.IsVoidType()) 2075return (array.IsSZArray && array.ElementType.SpecialType == SpecialType.System_String, returnsTaskOrTaskOfInt); 3695private protected override INamedTypeSymbolInternal CommonGetSpecialType(SpecialType specialType) 3819return GetSpecialType(signed ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr).AsNativeInteger(); 3951if (csharpReturnType.SpecialType != SpecialType.None && 3952csharpLeftType.SpecialType != SpecialType.None && 3953csharpRightType.SpecialType != SpecialType.None) 3974csharpReturnType.SpecialType is SpecialType.System_Boolean) 3977(SpecialType.System_Object, SpecialType.System_Object) or 3978(SpecialType.System_Delegate, SpecialType.System_Delegate)) 3991csharpReturnType.SpecialType == SpecialType.System_Boolean) 4019csharpReturnType.SpecialType is SpecialType.System_Boolean && 4074csharpReturnType.SpecialType is SpecialType.System_Boolean && 4075csharpLeftType is PointerTypeSymbol { PointedAtType.SpecialType: SpecialType.System_Void } && 4076csharpRightType is PointerTypeSymbol { PointedAtType.SpecialType: SpecialType.System_Void }) 4111csharpReturnType.SpecialType is SpecialType.System_Int64 && 4130=> type.SpecialType is SpecialType.System_Int32 or SpecialType.System_UInt32 or SpecialType.System_Int64 or SpecialType.System_UInt64; 4133=> IsReadOnlySpanType(type) && ((NamedTypeSymbol)type).TypeArgumentsWithAnnotationsNoUseSiteDiagnostics[0].SpecialType == SpecialType.System_Byte; 4176if (csharpReturnType.SpecialType != SpecialType.None && csharpOperandType.SpecialType != SpecialType.None) 4367internal bool CanEmitBoolean() => CanEmitSpecialType(SpecialType.System_Boolean); 4369internal bool CanEmitSpecialType(SpecialType type)
Compilation\CSharpSemanticModel.cs (2)
3849binaryOperator.Type.SpecialType == SpecialType.System_Boolean) 3852var objectType = binaryOperator.Type.ContainingAssembly.GetSpecialType(SpecialType.System_Object);
Compiler\AnonymousTypeMethodBodySynthesizer.cs (1)
38Debug.Assert(ContainingType.BaseTypeNoUseSiteDiagnostics.SpecialType == SpecialType.System_Object);
Compiler\ClsComplianceChecker.cs (7)
525System.Diagnostics.Debug.Assert((object)baseType != null || symbol.SpecialType == SpecialType.System_Object, "Only object has no base."); 1012case SpecialType.System_TypedReference: 1013case SpecialType.System_UIntPtr: 1017case SpecialType.System_SByte: // sic 1018case SpecialType.System_UInt16: 1019case SpecialType.System_UInt32: 1020case SpecialType.System_UInt64:
Compiler\MethodBodySynthesizer.cs (5)
37Debug.Assert((object)constructor.ContainingType.BaseTypeNoUseSiteDiagnostics == null || constructor.ContainingType.BaseTypeNoUseSiteDiagnostics.SpecialType == SpecialType.System_Object); 38var objectType = constructor.ContainingAssembly.GetSpecialType(SpecialType.System_Object); 93var intType = compilation.GetSpecialType(SpecialType.System_Int32); 94var objectType = compilation.GetSpecialType(SpecialType.System_Object); 349TypeSymbol boolType = compilation.GetSpecialType(SpecialType.System_Boolean);
Compiler\MethodBodySynthesizer.Lowered.cs (9)
55LocalSymbol i = F.SynthesizedLocal(F.SpecialType(SpecialType.System_Int32)); 56LocalSymbol hashCode = F.SynthesizedLocal(F.SpecialType(SpecialType.System_UInt32)); 85F.Binary(BinaryOperatorKind.ObjectNotEqual, F.SpecialType(SpecialType.System_Boolean), 112F.Binary(BinaryOperatorKind.LessThan, F.SpecialType(SpecialType.System_Boolean), 151.Construct(F.SpecialType(SpecialType.System_Char)); 153LocalSymbol i = F.SynthesizedLocal(F.SpecialType(SpecialType.System_Int32)); 154LocalSymbol hashCode = F.SynthesizedLocal(F.SpecialType(SpecialType.System_UInt32)); 201F.Binary(BinaryOperatorKind.LessThan, F.SpecialType(SpecialType.System_Boolean), 361Debug.Assert(system_Int32.SpecialType == SpecialType.System_Int32);
Emitter\EditAndContinue\CSharpSymbolMatcher.cs (2)
40_symbols = new MatchSymbols(anonymousTypeMap, anonymousDelegates, anonymousDelegatesWithIndexedNames, sourceAssembly, otherAssembly, otherSynthesizedMembers, otherDeletedMembers, new DeepTranslator(otherAssembly.GetSpecialType(SpecialType.System_Object))); 486return _otherAssembly.GetSpecialType(SpecialType.System_Object);
Emitter\EditAndContinue\PEDeltaAssemblyBuilder.cs (1)
95_deepTranslator = new CSharpSymbolMatcher.DeepTranslator(sourceAssembly.GetSpecialType(SpecialType.System_Object));
Emitter\Model\NamedTypeSymbolAdapter.cs (3)
291baseType = AdaptedNamedTypeSymbol.ContainingAssembly.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_Object); 355else if (method.MethodKind == MethodKind.Destructor && AdaptedNamedTypeSymbol.SpecialType != SpecialType.System_Object) 362TypeSymbol objectType = AdaptedNamedTypeSymbol.DeclaringCompilation.GetSpecialType(CodeAnalysis.SpecialType.System_Object);
Emitter\Model\ParameterSymbolAdapter.cs (3)
83if (constant.SpecialType != SpecialType.None) 241this.ExplicitDefaultConstantValue.SpecialType != SpecialType.System_Decimal && 242this.ExplicitDefaultConstantValue.SpecialType != SpecialType.System_DateTime;
Emitter\Model\PEAssemblyBuilder.cs (6)
446GetSpecialType(SpecialType.System_Byte, diagnostics)); 454GetSpecialType(SpecialType.System_Byte, diagnostics)); 462GetSpecialType(SpecialType.System_Boolean, diagnostics)); 470GetSpecialType(SpecialType.System_Boolean, diagnostics)); 485GetSpecialType(SpecialType.System_Int32, diagnostics)); 555private NamedTypeSymbol GetSpecialType(SpecialType type, BindingDiagnosticBag diagnostics)
Emitter\Model\PEModuleBuilder.cs (17)
795private NamedTypeSymbol GetUntranslatedSpecialType(SpecialType specialType, SyntaxNode syntaxNodeOpt, DiagnosticBag diagnostics) 812internal sealed override Cci.INamedTypeReference GetSpecialType(SpecialType specialType, SyntaxNode syntaxNodeOpt, DiagnosticBag diagnostics) 835return namedType.SpecialType == (SpecialType)platformType; 1065if ((object)declaredBase != null && declaredBase.SpecialType == SpecialType.System_ValueType) 1499return GetSpecialType(SpecialType.System_Object, syntaxNodeOpt, diagnostics); 1544return new SynthesizedPrivateImplementationDetailsStaticConstructor(SourceModule, details, GetUntranslatedSpecialType(SpecialType.System_Void, syntaxOpt, diagnostics)).GetCciAdapter(); 1613NamedTypeSymbol byteType = Compilation.GetSpecialType(SpecialType.System_Byte); 1634NamedTypeSymbol byteType = Compilation.GetSpecialType(SpecialType.System_Byte); 1657ImmutableArray.Create(new TypedConstant(Compilation.GetSpecialType(SpecialType.System_Byte), TypedConstantKind.Primitive, value))); 1697NamedTypeSymbol booleanType = Compilation.GetSpecialType(SpecialType.System_Boolean); 1839TypeSymbol returnType = factory.SpecialType(SpecialType.System_Void); 1840TypeSymbol argumentType = factory.SpecialType(SpecialType.System_Object); 1841TypeSymbol paramNameType = factory.SpecialType(SpecialType.System_String); 1869TypeSymbol returnType = factory.SpecialType(SpecialType.System_Void); 1870TypeSymbol unmatchedValueType = factory.SpecialType(SpecialType.System_Object); 1890TypeSymbol returnType = factory.SpecialType(SpecialType.System_Void); 1915TypeSymbol returnType = factory.SpecialType(SpecialType.System_Void);
Emitter\Model\SynthesizedPrivateImplementationDetailsStaticConstructor.cs (1)
55factory.Array(payloadArrayType.ElementType, factory.Binary(BinaryOperatorKind.Addition, factory.SpecialType(SpecialType.System_Int32), factory.MaximumMethodDefIndex(), factory.Literal(1))));
Emitter\Model\TypeParameterSymbolAdapter.cs (4)
240SpecialType.System_ValueType, 258case SpecialType.System_Object: 261case SpecialType.System_ValueType: 278var typeRef = moduleBeingBuilt.GetSpecialType(SpecialType.System_ValueType,
Emitter\NoPia\EmbeddedTypesManager.cs (3)
59var typeSymbol = ModuleBeingBuilt.Compilation.GetSpecialType(SpecialType.System_String); 148ImmutableArray.Create(new TypedConstant(ctor.Parameters[0].Type, TypedConstantKind.Type, ctor.ContainingAssembly.GetSpecialType(SpecialType.System_Object))), 243if (namedType.SpecialType != SpecialType.None || namedType.IsErrorType() || !namedType.ContainingAssembly.IsLinked)
FlowAnalysis\AbstractFlowPass.cs (15)
637else if ((object)node.Type == null || node.Type.SpecialType != SpecialType.System_Boolean) 1373case SpecialType.System_Boolean: 1374case SpecialType.System_Char: 1375case SpecialType.System_SByte: 1376case SpecialType.System_Byte: 1377case SpecialType.System_Int16: 1378case SpecialType.System_UInt16: 1379case SpecialType.System_Int32: 1380case SpecialType.System_UInt32: 1381case SpecialType.System_Int64: 1382case SpecialType.System_UInt64: 1383case SpecialType.System_Decimal: 1384case SpecialType.System_Single: 1385case SpecialType.System_Double: 1386case SpecialType.System_DateTime:
FlowAnalysis\DefiniteAssignment.cs (3)
365if (methodThisParameter.Type.SpecialType != SpecialType.None) 875type.SpecialType != SpecialType.System_String && 876type is not ArrayTypeSymbol { IsSZArray: true, ElementType.SpecialType: SpecialType.System_Byte })
FlowAnalysis\EmptyStructTypeCache.cs (1)
134return nts.IsStructType() && nts.SpecialType == SpecialType.None && !nts.KnownCircularStruct;
FlowAnalysis\NullableWalker.cs (16)
2818returnType.Type.SpecialType == SpecialType.System_Boolean) 4030if (type.SpecialType != SpecialType.None) 4099if (property.Type.SpecialType != SpecialType.System_Void) 4625Debug.Assert(binary.Type.SpecialType == SpecialType.System_Boolean); 4731Debug.Assert(binary.Type.SpecialType == SpecialType.System_Boolean); 5724|| method.ReturnType.SpecialType != SpecialType.System_Boolean 6401if (method.ReturnType.SpecialType == SpecialType.System_Boolean 7655Debug.Assert(containingType.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T); 8647return compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(ImmutableArray.Create(underlying)); 9927if ((object)getMethod != null && getMethod.ContainingType.SpecialType == SpecialType.System_Nullable_T) 10019(conversion.Kind == ConversionKind.ExplicitReference && resultType.SpecialType == SpecialType.System_String)) 10027if (node.Expression.Type!.SpecialType == SpecialType.System_Collections_IEnumerable) 10083else if (resultType.SpecialType == SpecialType.System_String) 10606Debug.Assert(node.Type.SpecialType == SpecialType.System_Boolean); 10609if (typeExpr.Type?.SpecialType == SpecialType.System_Object) 10658Debug.Assert(node.Type.SpecialType == SpecialType.System_RuntimeArgumentHandle);
Lowering\AsyncRewriter\AsyncExceptionHandlerRewriter.cs (6)
174var exceptionType = _F.SpecialType(SpecialType.System_Object); 177var pendingBranchVar = new SynthesizedLocal(_F.CurrentFunction, TypeWithAnnotations.Create(_F.SpecialType(SpecialType.System_Int32)), SynthesizedLocalKind.TryAwaitPendingBranch, tryStatementSyntax); 394LocalSymbol obj = _F.SynthesizedLocal(_F.SpecialType(SpecialType.System_Object)); 523var catchType = node.ExceptionTypeOpt ?? _F.SpecialType(SpecialType.System_Object); 1009this.pendingCaughtException = new SynthesizedLocal(F.CurrentFunction, TypeWithAnnotations.Create(F.SpecialType(SpecialType.System_Object)), SynthesizedLocalKind.TryAwaitPendingCaughtException, tryStatementSyntax); 1010this.pendingCatch = new SynthesizedLocal(F.CurrentFunction, TypeWithAnnotations.Create(F.SpecialType(SpecialType.System_Int32)), SynthesizedLocalKind.TryAwaitPendingCatch, tryStatementSyntax);
Lowering\AsyncRewriter\AsyncMethodBuilderMemberCollection.cs (4)
136resultType: F.SpecialType(SpecialType.System_Void), 169resultType: F.SpecialType(SpecialType.System_Void), 241resultType: F.SpecialType(SpecialType.System_Void), 259resultType = F.SpecialType(SpecialType.System_Object);
Lowering\AsyncRewriter\AsyncMethodToStateMachineRewriter.cs (2)
447resultType: F.SpecialType(SpecialType.System_Boolean)).ToExpression(); 458? F.SpecialType(SpecialType.System_Object)
Lowering\AsyncRewriter\AsyncRewriter.AsyncIteratorRewriter.cs (5)
126NamedTypeSymbol boolType = F.SpecialType(SpecialType.System_Boolean); 336var versionSymbol = F.SynthesizedLocal(F.SpecialType(SpecialType.System_Int16)); 497.Construct(F.SpecialType(SpecialType.System_Boolean)); 522.Construct(F.SpecialType(SpecialType.System_Boolean)); 548.Construct(F.SpecialType(SpecialType.System_Boolean));
Lowering\AsyncRewriter\AsyncRewriter.cs (2)
141stateField = F.StateMachineField(F.SpecialType(SpecialType.System_Int32), GeneratedNames.MakeStateMachineStateFieldName(), isPublic: true); 147instanceIdField = F.StateMachineField(F.SpecialType(SpecialType.System_UInt64), GeneratedNames.MakeStateMachineStateIdFieldName(), isPublic: true);
Lowering\AsyncRewriter\AsyncStateMachine.cs (1)
49interfaces.Add(compilation.GetWellKnownType(WellKnownType.System_Threading_Tasks_Sources_IValueTaskSource_T).Construct(compilation.GetSpecialType(SpecialType.System_Boolean)));
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (8)
105_int32Type = _bound.SpecialType(SpecialType.System_Int32); 106_objectType = _bound.SpecialType(SpecialType.System_Object); 107_nullableType = _bound.SpecialType(SpecialType.System_Nullable_T); 108_IEnumerableType = _bound.SpecialType(SpecialType.System_Collections_Generic_IEnumerable_T); 371var operand = _bound.Null(_bound.SpecialType(SpecialType.System_Object)); 511if (underlying.SpecialType == SpecialType.System_Boolean) 516var possiblePromote = Binder.GetEnumPromotedType(underlying.SpecialType); 697unquoted = _bound.StaticCall(_bound.SpecialType(SpecialType.System_Delegate), "CreateDelegate", _bound.Typeof(delegateType), receiver, _bound.MethodInfo(method));
Lowering\DiagnosticsPass_ExpressionTrees.cs (1)
92node.Indices[0].Type!.SpecialType == SpecialType.None)
Lowering\DiagnosticsPass_Warnings.cs (4)
330if (node.Left.Type.SpecialType == SpecialType.System_Object && !IsExplicitCast(node.Left) && !(node.Left.ConstantValueOpt != null && node.Left.ConstantValueOpt.IsNull) && ConvertedHasEqual(node.OperatorKind, node.Right, out t)) 335else if (node.Right.Type.SpecialType == SpecialType.System_Object && !IsExplicitCast(node.Right) && !(node.Right.ConstantValueOpt != null && node.Right.ConstantValueOpt.IsNull) && ConvertedHasEqual(node.OperatorKind, node.Left, out t)) 630SpecialType fromSpecialType = from.SpecialType; 631SpecialType toSpecialType = to.SpecialType;
Lowering\Extensions.cs (1)
132if (expr.Type.IsNullableType() && expr.Type.GetNullableUnderlyingType().SpecialType != SpecialType.System_Boolean)
Lowering\Instrumentation\CodeCoverageInstrumenter.cs (3)
116TypeSymbol payloadElementType = methodBodyFactory.SpecialType(SpecialType.System_Boolean); 219methodBodyFactory.SpecialType(SpecialType.System_Int32), fileIndices.ToImmutable()); 292_methodBodyFactory.SpecialType(SpecialType.System_Boolean),
Lowering\Instrumentation\LocalStateTracingInstrumenter.cs (17)
215SpecialType.System_Boolean 217SpecialType.System_SByte or SpecialType.System_Byte 219SpecialType.System_Int16 or SpecialType.System_UInt16 or SpecialType.System_Char 221SpecialType.System_Int32 or SpecialType.System_UInt32 223SpecialType.System_Int64 or SpecialType.System_UInt64 225SpecialType.System_Single 227SpecialType.System_Double 229SpecialType.System_Decimal 231SpecialType.System_String 464if (parameter.Type.SpecialType == SpecialType.System_String && targetType.SpecialType != SpecialType.System_String) 567if (invocation.Type.SpecialType != SpecialType.System_Void)
Lowering\IteratorRewriter\IteratorConstructor.cs (1)
26var intType = container.DeclaringCompilation.GetSpecialType(SpecialType.System_Int32);
Lowering\IteratorRewriter\IteratorFinallyMethodSymbol.cs (1)
147get { return TypeWithAnnotations.Create(ContainingAssembly.GetSpecialType(SpecialType.System_Void)); }
Lowering\IteratorRewriter\IteratorRewriter.cs (15)
70case SpecialType.System_Collections_IEnumerable: 71case SpecialType.System_Collections_Generic_IEnumerable_T: 75case SpecialType.System_Collections_IEnumerator: 76case SpecialType.System_Collections_Generic_IEnumerator_T: 102EnsureSpecialType(SpecialType.System_Int32, bag); 103EnsureSpecialType(SpecialType.System_IDisposable, bag); 107EnsureSpecialType(SpecialType.System_Collections_IEnumerator, bag); 113EnsureSpecialType(SpecialType.System_Collections_Generic_IEnumerator_T, bag); 119EnsureSpecialType(SpecialType.System_Collections_IEnumerable, bag); 121EnsureSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T, bag); 146private void EnsureSpecialType(SpecialType type, BindingDiagnosticBag bag) 177stateField = F.StateMachineField(F.SpecialType(SpecialType.System_Int32), GeneratedNames.MakeStateMachineStateFieldName()); 182instanceIdField = F.StateMachineField(F.SpecialType(SpecialType.System_UInt64), GeneratedNames.MakeStateMachineStateIdFieldName()); 218var IEnumeratorOfElementType = F.SpecialType(SpecialType.System_Collections_Generic_IEnumerator_T).Construct(ImmutableArray.Create(_elementType)); 258var IEnumerableOfElementType = F.SpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(_elementType.Type);
Lowering\IteratorRewriter\IteratorStateMachine.cs (6)
34interfaces.Add(ContainingAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(ElementType.Type)); 35interfaces.Add(ContainingAssembly.GetSpecialType(SpecialType.System_Collections_IEnumerable)); 38interfaces.Add(ContainingAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerator_T).Construct(ElementType.Type)); 39interfaces.Add(ContainingAssembly.GetSpecialType(SpecialType.System_IDisposable)); 40interfaces.Add(ContainingAssembly.GetSpecialType(SpecialType.System_Collections_IEnumerator)); 61internal override NamedTypeSymbol BaseTypeNoUseSiteDiagnostics => ContainingAssembly.GetSpecialType(SpecialType.System_Object);
Lowering\LocalRewriter\LocalRewriter.cs (2)
559SpecialType type = (SpecialType)descriptor.DeclaringTypeId;
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (15)
539if (t1.Input.Type.SpecialType is SpecialType.System_Double or SpecialType.System_Single) 753bool isStringInput = input.Type.SpecialType == SpecialType.System_String; 790case SpecialType.System_IntPtr: 792input = _factory.Convert(_factory.SpecialType(SpecialType.System_Int64), input); 796case SpecialType.System_UIntPtr: 798input = _factory.Convert(_factory.SpecialType(SpecialType.System_UInt64), input); 815SpecialType.System_Single => BinaryOperatorKind.FloatLessThanOrEqual, 816SpecialType.System_Double => BinaryOperatorKind.DoubleLessThanOrEqual, 817SpecialType.System_Decimal => BinaryOperatorKind.DecimalLessThanOrEqual, 948TypeSymbol returnType = _factory.SpecialType(SpecialType.System_UInt32); 951StringPatternInput.String => _factory.SpecialType(SpecialType.System_String), 953.Construct(_factory.SpecialType(SpecialType.System_Char)), 955.Construct(_factory.SpecialType(SpecialType.System_Char)), 1066_whenNodeIdentifierLocal ??= _factory.SynthesizedLocal(_factory.SpecialType(SpecialType.System_Int32));
Lowering\LocalRewriter\LocalRewriter.PatternLocalRewriter.cs (15)
203inputType = _factory.SpecialType(SpecialType.System_Object); 243Debug.Assert(e.Property.GetMethod.Parameters[0].Type.SpecialType == SpecialType.System_Int32); 373TypeSymbol objectType = _factory.SpecialType(SpecialType.System_Object); 374var operandType = new PointerTypeSymbol(TypeWithAnnotations.Create(_factory.SpecialType(SpecialType.System_Void))); 380_factory.SpecialType(SpecialType.System_Boolean), 403if (input.Type.SpecialType == SpecialType.System_Double && double.IsNaN(value.DoubleValue) || 404input.Type.SpecialType == SpecialType.System_Single && float.IsNaN(value.SingleValue)) 412if (operatorKind.OperandTypes() == BinaryOperatorKind.Int && comparisonType.SpecialType != SpecialType.System_Int32) 417SpecialType.System_Byte => true, 418SpecialType.System_SByte => true, 419SpecialType.System_Int16 => true, 420SpecialType.System_UInt16 => true, 423comparisonType = _factory.SpecialType(SpecialType.System_Int32); 428return this._localRewriter.MakeBinaryOperator(_factory.Syntax, operatorKind, input, literal, _factory.SpecialType(SpecialType.System_Boolean), method: null, constrainedToTypeOpt: null); 439.Construct(_factory.SpecialType(SpecialType.System_Char));
Lowering\LocalRewriter\LocalRewriter_BinaryOperator.cs (45)
115Debug.Assert(node.Type.SpecialType == SpecialType.System_String, "Non-string binary addition should have been handled by VisitConversion or VisitArguments"); 590return arrLength.Update(arrLength.Expression, _factory.SpecialType(SpecialType.System_UIntPtr)); 644var boolean = _compilation.GetSpecialType(SpecialType.System_Boolean); 799TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 891return MakeLiteral(syntax, ConstantValue.Create(value), _compilation.GetSpecialType(SpecialType.System_Boolean)); 1001TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 1152TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 1376TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 1561NamedTypeSymbol nullableType = _compilation.GetSpecialType(SpecialType.System_Nullable_T); 1562TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 1754TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 1862Debug.Assert(returnType.SpecialType == SpecialType.System_Boolean); 1952BoundExpression result = method.ReturnType.SpecialType == SpecialType.System_Delegate ? 1960Debug.Assert(loweredLeft.Type is { SpecialType: SpecialType.System_Decimal }); 1961Debug.Assert(loweredRight.Type is { SpecialType: SpecialType.System_Decimal }); 2003TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 2017TypeSymbol objectType = _compilation.GetSpecialType(SpecialType.System_Object); 2059Debug.Assert(rightType.SpecialType == SpecialType.System_Int32); 2126Debug.Assert(leftType.SpecialType is SpecialType.System_IntPtr or SpecialType.System_UIntPtr); 2131Debug.Assert(rightType.SpecialType == SpecialType.System_Int32); 2225Debug.Assert(sizeOfExpression.Type is { SpecialType: SpecialType.System_Int32 }); 2236var numericSpecialType = numericOperand.Type.SpecialType; 2249SpecialType destinationType = numericSpecialType; 2252case SpecialType.System_Int32: 2263destinationType = SpecialType.System_IntPtr; 2267case SpecialType.System_UInt32: 2274destinationType = SpecialType.System_UIntPtr; 2278case SpecialType.System_Int64: 2279destinationType = SpecialType.System_IntPtr; 2281case SpecialType.System_UInt64: 2282destinationType = SpecialType.System_UIntPtr; 2299case SpecialType.System_Int32: 2301TypeSymbol nativeIntType = _factory.SpecialType(SpecialType.System_IntPtr); 2313case SpecialType.System_UInt32: 2315TypeSymbol longType = _factory.SpecialType(SpecialType.System_Int64); 2316TypeSymbol nativeIntType = _factory.SpecialType(SpecialType.System_IntPtr); 2326case SpecialType.System_Int64: 2328TypeSymbol longType = _factory.SpecialType(SpecialType.System_Int64); 2329TypeSymbol nativeIntType = _factory.SpecialType(SpecialType.System_IntPtr); 2338case SpecialType.System_UInt64: 2340TypeSymbol ulongType = _factory.SpecialType(SpecialType.System_UInt64); 2341TypeSymbol nativeUIntType = _factory.SpecialType(SpecialType.System_UIntPtr); 2374Debug.Assert(returnType.SpecialType == SpecialType.System_Int64); 2386_factory.SpecialType(SpecialType.System_IntPtr),
Lowering\LocalRewriter\LocalRewriter_Call.cs (1)
1320TypeSymbol int32Type = compilation.GetSpecialType(SpecialType.System_Int32);
Lowering\LocalRewriter\LocalRewriter_ConditionalAccess.cs (1)
145var objectType = _compilation.GetSpecialType(SpecialType.System_Object);
Lowering\LocalRewriter\LocalRewriter_Conversion.cs (114)
90Debug.Assert(byteType.SpecialType == SpecialType.System_Byte); 138Debug.Assert(byteArray.ElementType.SpecialType == SpecialType.System_Byte); 221if (type.SpecialType != SpecialType.System_Double && type.SpecialType != SpecialType.System_Single) 425if (rewrittenType.SpecialType == SpecialType.System_Decimal || rewrittenOperand.Type.SpecialType == SpecialType.System_Decimal) 488if (rewrittenType.SpecialType == SpecialType.System_Decimal) 495else if (rewrittenOperand.Type.SpecialType == SpecialType.System_Decimal) 620SpecialType GetUnderlyingSpecialType(TypeSymbol type) => 623bool IsInRange(SpecialType type, SpecialType low, SpecialType high) => 626SpecialType sourceST = GetUnderlyingSpecialType(source); 627SpecialType targetST = GetUnderlyingSpecialType(target); 632IsInRange(sourceST, SpecialType.System_Char, SpecialType.System_Double) && 633IsInRange(targetST, SpecialType.System_Char, SpecialType.System_UInt64); 679rewrittenOperand.Type.SpecialType != SpecialType.System_Decimal && 680rewrittenOperand.Type.SpecialType != SpecialType.System_DateTime) 964if (!TypeSymbol.Equals(typeFrom, typeTo, TypeCompareKind.ConsiderEverything2) && (typeFrom.SpecialType == SpecialType.System_Decimal || typeTo.SpecialType == SpecialType.System_Decimal)) 1390SpecialType t0Type = t0.IsEnumType() ? t0.GetEnumUnderlyingType()!.SpecialType : t0.SpecialType; 1391SpecialType s0Type = s0.IsEnumType() ? s0.GetEnumUnderlyingType()!.SpecialType : s0.SpecialType; 1393if (t0Type == SpecialType.System_IntPtr) 1402case SpecialType.System_Byte: 1403case SpecialType.System_SByte: 1404case SpecialType.System_Int16: 1405case SpecialType.System_UInt16: 1406case SpecialType.System_Char: 1407case SpecialType.System_Int32: 1409case SpecialType.System_UInt32: 1410case SpecialType.System_UInt64: 1411case SpecialType.System_Int64: 1412case SpecialType.System_Single: 1413case SpecialType.System_Double: 1414case SpecialType.System_Decimal: 1418else if (t0Type == SpecialType.System_UIntPtr) 1427case SpecialType.System_Byte: 1428case SpecialType.System_UInt16: 1429case SpecialType.System_Char: 1430case SpecialType.System_UInt32: 1432case SpecialType.System_SByte: 1433case SpecialType.System_Int16: 1434case SpecialType.System_Int32: 1435case SpecialType.System_UInt64: 1436case SpecialType.System_Int64: 1437case SpecialType.System_Single: 1438case SpecialType.System_Double: 1439case SpecialType.System_Decimal: 1443else if (s0Type == SpecialType.System_IntPtr) 1452case SpecialType.System_Byte: 1453case SpecialType.System_SByte: 1454case SpecialType.System_Int16: 1455case SpecialType.System_UInt16: 1456case SpecialType.System_Char: 1457case SpecialType.System_UInt32: 1458case SpecialType.System_Int32: 1460case SpecialType.System_UInt64: 1461case SpecialType.System_Int64: 1462case SpecialType.System_Single: 1463case SpecialType.System_Double: 1464case SpecialType.System_Decimal: 1468else if (s0Type == SpecialType.System_UIntPtr) 1477case SpecialType.System_SByte: 1478case SpecialType.System_Int16: 1479case SpecialType.System_Int32: 1480case SpecialType.System_Byte: 1481case SpecialType.System_UInt16: 1482case SpecialType.System_Char: 1483case SpecialType.System_UInt32: 1485case SpecialType.System_UInt64: 1486case SpecialType.System_Int64: 1487case SpecialType.System_Single: 1488case SpecialType.System_Double: 1489case SpecialType.System_Decimal: 1500if (typeFrom.SpecialType == SpecialType.System_Decimal) 1505case SpecialType.System_Char: return SpecialMember.System_Decimal__op_Explicit_ToChar; 1506case SpecialType.System_SByte: return SpecialMember.System_Decimal__op_Explicit_ToSByte; 1507case SpecialType.System_Byte: return SpecialMember.System_Decimal__op_Explicit_ToByte; 1508case SpecialType.System_Int16: return SpecialMember.System_Decimal__op_Explicit_ToInt16; 1509case SpecialType.System_UInt16: return SpecialMember.System_Decimal__op_Explicit_ToUInt16; 1510case SpecialType.System_Int32: return SpecialMember.System_Decimal__op_Explicit_ToInt32; 1511case SpecialType.System_UInt32: return SpecialMember.System_Decimal__op_Explicit_ToUInt32; 1512case SpecialType.System_Int64: return SpecialMember.System_Decimal__op_Explicit_ToInt64; 1513case SpecialType.System_UInt64: return SpecialMember.System_Decimal__op_Explicit_ToUInt64; 1514case SpecialType.System_Single: return SpecialMember.System_Decimal__op_Explicit_ToSingle; 1515case SpecialType.System_Double: return SpecialMember.System_Decimal__op_Explicit_ToDouble; 1525case SpecialType.System_Char: return SpecialMember.System_Decimal__op_Implicit_FromChar; 1526case SpecialType.System_SByte: return SpecialMember.System_Decimal__op_Implicit_FromSByte; 1527case SpecialType.System_Byte: return SpecialMember.System_Decimal__op_Implicit_FromByte; 1528case SpecialType.System_Int16: return SpecialMember.System_Decimal__op_Implicit_FromInt16; 1529case SpecialType.System_UInt16: return SpecialMember.System_Decimal__op_Implicit_FromUInt16; 1530case SpecialType.System_Int32: return SpecialMember.System_Decimal__op_Implicit_FromInt32; 1531case SpecialType.System_UInt32: return SpecialMember.System_Decimal__op_Implicit_FromUInt32; 1532case SpecialType.System_Int64: return SpecialMember.System_Decimal__op_Implicit_FromInt64; 1533case SpecialType.System_UInt64: return SpecialMember.System_Decimal__op_Implicit_FromUInt64; 1534case SpecialType.System_Single: return SpecialMember.System_Decimal__op_Explicit_FromSingle; 1535case SpecialType.System_Double: return SpecialMember.System_Decimal__op_Explicit_FromDouble; 1544Debug.Assert(fromType.SpecialType == SpecialType.System_Decimal || toType.SpecialType == SpecialType.System_Decimal); 1546if (fromType.SpecialType == SpecialType.System_Decimal) 1550case SpecialType.System_IntPtr: 1551case SpecialType.System_UIntPtr: 1552operand = RewriteDecimalConversionCore(syntax, operand, fromType, get64BitType(_compilation, signed: toType.SpecialType == SpecialType.System_IntPtr), isImplicit, constantValueOpt); 1560case SpecialType.System_IntPtr: 1561case SpecialType.System_UIntPtr: 1562operand = MakeConversionNode(operand, get64BitType(_compilation, signed: fromType.SpecialType == SpecialType.System_IntPtr), @checked); 1570static TypeSymbol get64BitType(CSharpCompilation compilation, bool signed) => compilation.GetSpecialType(signed ? SpecialType.System_Int64 : SpecialType.System_UInt64); 1650if (fromType.SpecialType == SpecialType.System_Decimal || toType.SpecialType == SpecialType.System_Decimal) 1665if (fromType.SpecialType == SpecialType.System_Decimal) 1678else if (toType.SpecialType == SpecialType.System_Decimal)
Lowering\LocalRewriter\LocalRewriter_FixedStatement.cs (3)
209else if (fixedCollectionInitializer.Expression.Type is { SpecialType: SpecialType.System_String }) 517BoundExpression lengthCheck = factory.Binary(BinaryOperatorKind.IntNotEqual, factory.SpecialType(SpecialType.System_Boolean), lengthCall, factory.Literal(0)); 520BoundExpression condition = factory.Binary(BinaryOperatorKind.LogicalBoolAnd, factory.SpecialType(SpecialType.System_Boolean), notNullCheck, lengthCheck);
Lowering\LocalRewriter\LocalRewriter_ForEachStatement.cs (12)
67if (origDefinition.SpecialType == SpecialType.System_String) 328Debug.Assert(enumeratorType.OriginalDefinition.SpecialType != SpecialType.System_Nullable_T); 337var objectType = _factory.SpecialType(SpecialType.System_Object); 395type: _compilation.GetSpecialType(SpecialType.System_Boolean)), 529TypeSymbol intType = _compilation.GetSpecialType(SpecialType.System_Int32); 530TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 555MakeLiteral(forEachSyntax, ConstantValue.Default(SpecialType.System_Int32), intType)); 708TypeSymbol intType = _compilation.GetSpecialType(SpecialType.System_Int32); 709TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 734MakeLiteral(forEachSyntax, ConstantValue.Default(SpecialType.System_Int32), intType)); 835TypeSymbol intType = _compilation.GetSpecialType(SpecialType.System_Int32); 836TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean);
Lowering\LocalRewriter\LocalRewriter_Index.cs (1)
17NamedTypeSymbol booleanType = _compilation.GetSpecialType(SpecialType.System_Boolean);
Lowering\LocalRewriter\LocalRewriter_IndexerAccess.cs (7)
330Debug.Assert(integerArgument.Type!.SpecialType == SpecialType.System_Int32); 402Debug.Assert(loweredExpr.Type!.SpecialType == SpecialType.System_Int32); 413Debug.Assert(loweredExpr.Type!.SpecialType == SpecialType.System_Int32); 461Debug.Assert(hatExpression.Operand is { Type: { SpecialType: SpecialType.System_Int32 } }); 465else if (unloweredExpr is BoundConversion { Operand: { Type: { SpecialType: SpecialType.System_Int32 } } operand }) 474arguments[0] is { Type.SpecialType: SpecialType.System_Int32, ConstantValueOpt.Value: int _ and >= 0 } index && 475arguments[1] is { Type.SpecialType: SpecialType.System_Boolean, ConstantValueOpt.Value: bool fromEnd })
Lowering\LocalRewriter\LocalRewriter_IsPatternOperator.cs (2)
119Debug.Assert(node.Type is { SpecialType: SpecialType.System_Boolean }); 178Debug.Assert(test.Type.SpecialType == SpecialType.System_Boolean);
Lowering\LocalRewriter\LocalRewriter_Literal.cs (15)
30Debug.Assert(type is { SpecialType: SpecialType.System_Decimal }); 38Debug.Assert(type is { SpecialType: SpecialType.System_DateTime }); 73curMethod.ContainingType.SpecialType != SpecialType.System_Decimal) && 100arguments.Add(new BoundLiteral(syntax, ConstantValue.Create((int)value), _compilation.GetSpecialType(SpecialType.System_Int32))); 106arguments.Add(new BoundLiteral(syntax, ConstantValue.Create((uint)value), _compilation.GetSpecialType(SpecialType.System_UInt32))); 112arguments.Add(new BoundLiteral(syntax, ConstantValue.Create((long)value), _compilation.GetSpecialType(SpecialType.System_Int64))); 118arguments.Add(new BoundLiteral(syntax, ConstantValue.Create((ulong)value), _compilation.GetSpecialType(SpecialType.System_UInt64))); 124arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(low), _compilation.GetSpecialType(SpecialType.System_Int32))); 125arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(mid), _compilation.GetSpecialType(SpecialType.System_Int32))); 126arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(high), _compilation.GetSpecialType(SpecialType.System_Int32))); 127arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(isNegative), _compilation.GetSpecialType(SpecialType.System_Boolean))); 128arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(scale), _compilation.GetSpecialType(SpecialType.System_Byte))); 133Debug.Assert(ctor.ContainingType.SpecialType == SpecialType.System_Decimal); 148arguments.Add(new BoundLiteral(syntax, ConstantValue.Create(constantValue.DateTimeValue.Ticks), _compilation.GetSpecialType(SpecialType.System_Int64))); 152Debug.Assert(ctor.ContainingType.SpecialType == SpecialType.System_DateTime);
Lowering\LocalRewriter\LocalRewriter_LockStatement.cs (3)
33argumentType = _compilation.GetSpecialType(SpecialType.System_Object); 44argumentType = _compilation.GetSpecialType(SpecialType.System_Object); 96TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean);
Lowering\LocalRewriter\LocalRewriter_NullCoalescingOperator.cs (2)
117if (whenNullOpt.IsDefaultValue() && whenNullOpt.Type.SpecialType != SpecialType.System_Decimal) 192if (method.IsStatic && method.ContainingType.SpecialType == SpecialType.System_String)
Lowering\LocalRewriter\LocalRewriter_PointerElementAccess.cs (4)
50case SpecialType.System_Int32: 53case SpecialType.System_UInt32: 56case SpecialType.System_Int64: 59case SpecialType.System_UInt64:
Lowering\LocalRewriter\LocalRewriter_Range.cs (1)
143TypeSymbol boolType = _compilation.GetSpecialType(SpecialType.System_Boolean);
Lowering\LocalRewriter\LocalRewriter_StackAlloc.cs (2)
109TypeSymbol uintType = _factory.SpecialType(SpecialType.System_UInt32); 110TypeSymbol uintPtrType = _factory.SpecialType(SpecialType.System_UIntPtr);
Lowering\LocalRewriter\LocalRewriter_StringConcat.cs (5)
161if (method.IsStatic && method.ContainingType.SpecialType == SpecialType.System_String) 344var array = _factory.ArrayOrEmpty(_factory.SpecialType(SpecialType.System_String), loweredArgs); 390if (cv.SpecialType == SpecialType.System_Char) 432if (structToStringMethod != null && (expr.Type.SpecialType != SpecialType.None && !isFieldOfMarshalByRef(expr, _compilation))) 494type: _compilation.GetSpecialType(SpecialType.System_String));
Lowering\LocalRewriter\LocalRewriter_StringInterpolation.cs (6)
102Debug.Assert(localType.SpecialType == SpecialType.System_Boolean); 119Debug.Assert(call.Type.SpecialType == SpecialType.System_Boolean == usesBoolReturns); 146var boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 196fillin.Value.Type?.SpecialType != SpecialType.System_String || 279Debug.Assert(node.Type is { SpecialType: SpecialType.System_String }); // if target-converted, we should not get here. 329Debug.Assert(result.Type.SpecialType == SpecialType.System_String || result.Type.IsErrorType());
Lowering\LocalRewriter\LocalRewriter_SwitchExpression.cs (1)
126var objectType = _factory.SpecialType(SpecialType.System_Object);
Lowering\LocalRewriter\LocalRewriter_TupleBinaryOperator.cs (1)
583Debug.Assert(boolOperator.ReturnType.SpecialType == SpecialType.System_Boolean);
Lowering\LocalRewriter\LocalRewriter_UnaryOperator.cs (35)
84Debug.Assert((kind == UnaryOperatorKind.DynamicTrue || kind == UnaryOperatorKind.DynamicFalse) && type.SpecialType == SpecialType.System_Boolean 129var upconvertSpecialType = Binder.GetEnumPromotedType(underlyingType.SpecialType); 636type = _compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(type); 725Debug.Assert(constantOne.SpecialType != SpecialType.None); 726Debug.Assert(binaryOperandType.SpecialType != SpecialType.None); 737binaryOperandType = _compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(binaryOperandType); 756Debug.Assert(boundOne.Type is { SpecialType: SpecialType.System_Int32 }); 770if (unaryOperandType.SpecialType == SpecialType.System_Decimal) 774else if (unaryOperandType.IsNullableType() && unaryOperandType.GetNullableUnderlyingType().SpecialType == SpecialType.System_Decimal) 809Debug.Assert(operand.Type is { SpecialType: SpecialType.System_Decimal }); 816Debug.Assert(operand.Type is { } && operand.Type.IsNullableType() && operand.Type.GetNullableUnderlyingType().SpecialType == SpecialType.System_Decimal); 892SpecialType specialType; 897specialType = SpecialType.System_Int32; 900specialType = SpecialType.System_SByte; 903specialType = SpecialType.System_Int16; 906specialType = SpecialType.System_Byte; 909specialType = SpecialType.System_UInt16; 912specialType = SpecialType.System_Char; 915specialType = SpecialType.System_UInt32; 918specialType = SpecialType.System_Int64; 921specialType = SpecialType.System_UInt64; 924specialType = SpecialType.System_IntPtr; 927specialType = SpecialType.System_UIntPtr; 930specialType = SpecialType.System_Single; 933specialType = SpecialType.System_Double; 936specialType = SpecialType.System_Decimal; 949type = _compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(type); 1016case SpecialType.System_SByte: 1017case SpecialType.System_Int16: 1018case SpecialType.System_Int32: 1021case SpecialType.System_Byte: 1022case SpecialType.System_UInt16: 1023case SpecialType.System_UInt32: 1026case SpecialType.System_Int64: 1029case SpecialType.System_UInt64:
Lowering\LocalRewriter\LocalRewriter_UsingStatement.cs (2)
162_compilation.GetSpecialType(SpecialType.System_IDisposable) : 238_compilation.GetSpecialType(SpecialType.System_IDisposable) :
Lowering\LocalRewriter\LoweredDynamicOperationFactory.cs (4)
216resultType = _factory.SpecialType(SpecialType.System_Void); 309resultType = _factory.SpecialType(SpecialType.System_Void); 503var resultType = _factory.SpecialType(SpecialType.System_Boolean); 909var systemObjectType = _factory.SpecialType(SpecialType.System_Object);
Lowering\SpillSequenceSpiller.cs (6)
1197_F.Convert(_F.SpecialType(SpecialType.System_Object), receiver), 1198_F.Null(_F.SpecialType(SpecialType.System_Object))); 1215_F.Convert(_F.SpecialType(SpecialType.System_Object), _F.Default(receiver.Type)), 1216_F.Null(_F.SpecialType(SpecialType.System_Object))); 1224_F.Convert(_F.SpecialType(SpecialType.System_Object), _F.Local(clone)), 1225_F.Null(_F.SpecialType(SpecialType.System_Object))))
Lowering\StateMachineRewriter\MethodToStateMachineRewriter.cs (3)
125this.cachedState = F.SynthesizedLocal(F.SpecialType(SpecialType.System_Int32), syntax: F.Syntax, kind: SynthesizedLocalKind.StateMachineCachedState); 441if (type.SpecialType == SpecialType.System_TypedReference) return true; 442if (type.SpecialType != SpecialType.None) return false; // int, etc
Lowering\StateMachineRewriter\ResumableStateMachineStateAllocator.cs (1)
86f.SpecialType(SpecialType.System_Boolean),
Lowering\StateMachineRewriter\StateMachineRewriter.cs (1)
108initialThreadIdField = F.StateMachineField(F.SpecialType(SpecialType.System_Int32), GeneratedNames.MakeIteratorCurrentThreadIdFieldName());
Lowering\SyntheticBoundNodeFactory.cs (38)
335public NamedTypeSymbol SpecialType(SpecialType st) 613return new BoundIsOperator(this.Syntax, operand, Type(type), c.Kind, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean)) { WasCompilerGenerated = true }; 618Debug.Assert(left.Type?.SpecialType == CodeAnalysis.SpecialType.System_Boolean); 619Debug.Assert(right.Type?.SpecialType == CodeAnalysis.SpecialType.System_Boolean); 620return Binary(BinaryOperatorKind.LogicalBoolAnd, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right); 625Debug.Assert(left.Type?.SpecialType == CodeAnalysis.SpecialType.System_Boolean); 626Debug.Assert(right.Type?.SpecialType == CodeAnalysis.SpecialType.System_Boolean); 627return Binary(BinaryOperatorKind.LogicalBoolOr, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right); 632return Binary(BinaryOperatorKind.IntEqual, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right); 637return Binary(BinaryOperatorKind.ObjectEqual, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right); 642return Binary(BinaryOperatorKind.ObjectNotEqual, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right); 647return Binary(BinaryOperatorKind.IntNotEqual, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right); 652return Binary(BinaryOperatorKind.IntLessThan, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right); 657return Binary(BinaryOperatorKind.IntGreaterThanOrEqual, SpecialType(CodeAnalysis.SpecialType.System_Boolean), left, right); 662return Binary(BinaryOperatorKind.IntSubtraction, SpecialType(CodeAnalysis.SpecialType.System_Int32), left, right); 667return Binary(BinaryOperatorKind.IntMultiplication, SpecialType(CodeAnalysis.SpecialType.System_Int32), left, right); 672return new BoundLiteral(Syntax, ConstantValue.Create(value), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Byte)) { WasCompilerGenerated = true }; 677return new BoundLiteral(Syntax, ConstantValue.Create(value), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) { WasCompilerGenerated = true }; 685return new BoundLiteral(Syntax, ConstantValue.Create(value), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_UInt32)) { WasCompilerGenerated = true }; 721case { SpecialType: CodeAnalysis.SpecialType.System_Double }: 724case { SpecialType: CodeAnalysis.SpecialType.System_Single }: 1002Debug.Assert(ex.Type is { SpecialType: CodeAnalysis.SpecialType.System_Int32 }); 1064return new BoundLiteral(Syntax, ConstantValue.Create(value), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean)) { WasCompilerGenerated = true }; 1076return new BoundLiteral(Syntax, stringConst, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_String)) { WasCompilerGenerated = true }; 1087return new BoundLiteral(Syntax, charConst, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Char)) { WasCompilerGenerated = true }; 1098return new BoundArrayLength(Syntax, array, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)); 1213return new BoundSizeOfOperator(Syntax, Type(type), Binder.GetConstantSizeOf(type), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) { WasCompilerGenerated = true }; 1231SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 1241SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 1251SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 1259SpecialType(Microsoft.CodeAnalysis.SpecialType.System_UInt64)) 1274return new BoundModuleVersionIdString(Syntax, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_String)) { WasCompilerGenerated = true }; 1286SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 1298SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 1498Debug.Assert(expression is { Type: { SpecialType: CodeAnalysis.SpecialType.System_Boolean } }); 1631TypeSymbol boolType = Compilation.GetSpecialType(CodeAnalysis.SpecialType.System_Boolean); 1645TypeSymbol objectType = SpecialType(CodeAnalysis.SpecialType.System_Object); 1694Debug.Assert(returnType.SpecialType == CodeAnalysis.SpecialType.System_Boolean);
Operations\CSharpOperationFactory.cs (2)
1792: compilation.GetSpecialType(SpecialType.System_IDisposable); 1967TypeWithAnnotations.Create(((CSharpCompilation)_semanticModel.Compilation).GetSpecialType(SpecialType.System_Boolean)),
Parser\Lexer.cs (29)
94internal SpecialType ValueKind; 358case SpecialType.System_Int32: 361case SpecialType.System_UInt32: 364case SpecialType.System_Int64: 367case SpecialType.System_UInt64: 370case SpecialType.System_Single: 373case SpecialType.System_Double: 376case SpecialType.System_Decimal: 1063info.ValueKind = SpecialType.None; 1177info.ValueKind = SpecialType.System_Single; 1182info.ValueKind = SpecialType.System_Double; 1187info.ValueKind = SpecialType.System_Decimal; 1191info.ValueKind = SpecialType.System_Double; 1197info.ValueKind = SpecialType.System_Single; 1202info.ValueKind = SpecialType.System_Double; 1207info.ValueKind = SpecialType.System_Decimal; 1251case SpecialType.System_Single: 1254case SpecialType.System_Double: 1257case SpecialType.System_Decimal: 1283info.ValueKind = SpecialType.System_Int32; 1288info.ValueKind = SpecialType.System_UInt32; 1296info.ValueKind = SpecialType.System_Int64; 1301info.ValueKind = SpecialType.System_UInt64; 1313info.ValueKind = SpecialType.System_UInt32; 1318info.ValueKind = SpecialType.System_UInt64; 1328info.ValueKind = SpecialType.System_Int64; 1333info.ValueKind = SpecialType.System_UInt64; 1345info.ValueKind = SpecialType.System_UInt64; 2990info.ValueKind = SpecialType.System_Int32;
SymbolDisplay\SymbolDisplayVisitor.Types.cs (18)
633case SpecialType.System_Void: 635case SpecialType.System_SByte: 637case SpecialType.System_Int16: 639case SpecialType.System_Int32: 641case SpecialType.System_Int64: 643case SpecialType.System_IntPtr when symbol.IsNativeIntegerType: 645case SpecialType.System_UIntPtr when symbol.IsNativeIntegerType: 647case SpecialType.System_Byte: 649case SpecialType.System_UInt16: 651case SpecialType.System_UInt32: 653case SpecialType.System_UInt64: 655case SpecialType.System_Single: 657case SpecialType.System_Double: 659case SpecialType.System_Decimal: 661case SpecialType.System_Char: 663case SpecialType.System_Boolean: 665case SpecialType.System_String: 667case SpecialType.System_Object:
SymbolDisplay\SymbolDisplayVisitor_Constants.cs (5)
36protected override void AddExplicitlyCastedLiteralValue(INamedTypeSymbol namedType, SpecialType type, object value) 44protected override void AddLiteralValue(SpecialType type, object value) 53case SpecialType.System_Boolean: 57case SpecialType.System_String: 58case SpecialType.System_Char:
Symbols\AbstractTypeMap.cs (1)
390dynamicEraser = new DynamicTypeEraser(owner.ContainingAssembly.CorLibrary.GetSpecialType(SpecialType.System_Object));
Symbols\AnonymousTypes\AnonymousTypeManager.SymbolCollection.cs (7)
111get { return Compilation.GetSpecialType(SpecialType.System_Object); } 116get { return Compilation.GetSpecialType(SpecialType.System_Void); } 121get { return Compilation.GetSpecialType(SpecialType.System_Boolean); } 126get { return Compilation.GetSpecialType(SpecialType.System_String); } 131get { return Compilation.GetSpecialType(SpecialType.System_Int32); } 136get { return Compilation.GetSpecialType(SpecialType.System_IntPtr); } 141get { return Compilation.GetSpecialType(SpecialType.System_MulticastDelegate); }
Symbols\AnonymousTypes\AnonymousTypeManager.Templates.cs (4)
177Compilation.GetSpecialType(SpecialType.System_IntPtr), 178returnsVoid ? Compilation.GetSpecialType(SpecialType.System_Void) : null, 468Compilation.GetSpecialType(SpecialType.System_IntPtr), 469returnsVoid ? Compilation.GetSpecialType(SpecialType.System_Void) : null,
Symbols\ArrayTypeSymbol.cs (4)
71return CreateMDArray(elementType, rank, sizes, lowerBounds, declaringAssembly.GetSpecialType(SpecialType.System_Array)); 93return CreateSZArray(elementType, declaringAssembly.GetSpecialType(SpecialType.System_Array), GetSZArrayInterfaces(elementType, declaringAssembly)); 111var iListOfT = declaringAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IList_T); 117var iReadOnlyListOfT = declaringAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IReadOnlyList_T);
Symbols\AssemblySymbol.cs (7)
383internal abstract NamedTypeSymbol GetDeclaredSpecialType(SpecialType type); 472Debug.Assert((SpecialType)SpecialMembers.GetDescriptor(feature).DeclaringTypeId == SpecialType.System_Runtime_CompilerServices_RuntimeFeature); 473return GetSpecialType(SpecialType.System_Runtime_CompilerServices_RuntimeFeature) is { TypeKind: TypeKind.Class, IsStatic: true } && 496GetSpecialType(SpecialType.System_Runtime_CompilerServices_PreserveBaseOverridesAttribute) is { TypeKind: TypeKind.Class }; 567internal NamedTypeSymbol GetSpecialType(SpecialType type) 588return GetSpecialType(SpecialType.System_Object);
Symbols\Attributes\AttributeData.cs (12)
283string? memberName = value.DecodeValue<string>(SpecialType.System_String); 295var memberName = member.DecodeValue<string>(SpecialType.System_String); 331var sense = arguments.Attribute.CommonConstructorArguments[0].DecodeValue<bool>(SpecialType.System_Boolean); 334var memberName = value.DecodeValue<string>(SpecialType.System_String); 346var memberName = member.DecodeValue<string>(SpecialType.System_String); 581if (property.TypeWithAnnotations.HasType && property.Type.SpecialType == SpecialType.System_String && 600ctorArgument.DecodeValue<ClassInterfaceType>(SpecialType.System_Enum) : 601(ClassInterfaceType)ctorArgument.DecodeValue<short>(SpecialType.System_Int16); 626ctorArgument.DecodeValue<ComInterfaceType>(SpecialType.System_Enum) : 627(ComInterfaceType)ctorArgument.DecodeValue<short>(SpecialType.System_Int16); 670if (member is PropertySymbol { Type: { SpecialType: SpecialType.System_String } }) 834return arguments.Length == 1 && arguments[0].TryDecodeValue(SpecialType.System_String, out string? value) ? value : null;
Symbols\Attributes\SourceAttributeData.cs (15)
249SpecialType specType = parameterType.SpecialType; 292if (specType != SpecialType.System_Boolean) 300if (specType != SpecialType.System_Char) 308if (specType != SpecialType.System_SByte) 316if (specType != SpecialType.System_Byte) 324if (specType != SpecialType.System_Int16) 332if (specType != SpecialType.System_UInt16) 340if (specType != SpecialType.System_Int32) 348if (specType != SpecialType.System_UInt32) 356if (specType != SpecialType.System_Int64) 364if (specType != SpecialType.System_UInt64) 372if (specType != SpecialType.System_Single) 380if (specType != SpecialType.System_Double) 388if (specType != SpecialType.System_String) 396if (specType != SpecialType.System_Object)
Symbols\BaseTypeAnalysis.cs (20)
255case SpecialType.System_Void: 256case SpecialType.System_Boolean: 257case SpecialType.System_Char: 258case SpecialType.System_SByte: 259case SpecialType.System_Byte: 260case SpecialType.System_Int16: 261case SpecialType.System_UInt16: 262case SpecialType.System_Int32: 263case SpecialType.System_UInt32: 264case SpecialType.System_Int64: 265case SpecialType.System_UInt64: 266case SpecialType.System_Decimal: 267case SpecialType.System_Single: 268case SpecialType.System_Double: 269case SpecialType.System_IntPtr: 270case SpecialType.System_UIntPtr: 271case SpecialType.System_ArgIterator: 272case SpecialType.System_RuntimeArgumentHandle: 274case SpecialType.System_TypedReference: 276case SpecialType.None:
Symbols\Compilation_WellKnownMembers.cs (10)
96NamedTypeSymbol type = descriptor.DeclaringTypeId <= (int)SpecialType.Count 97? this.GetSpecialType((SpecialType)descriptor.DeclaringTypeId) 458var systemByte = GetSpecialType(SpecialType.System_Byte); 461var systemUnit32 = GetSpecialType(SpecialType.System_UInt32); 477var ticks = new TypedConstant(GetSpecialType(SpecialType.System_Int64), TypedConstantKind.Primitive, value.Ticks); 758NamedTypeSymbol booleanType = GetSpecialType(SpecialType.System_Boolean); 772var stringType = GetSpecialType(SpecialType.System_String); 786var boolType = GetSpecialType(SpecialType.System_Boolean); 1023case SpecialType.System_IntPtr: 1024case SpecialType.System_UIntPtr:
Symbols\ConstantValueUtils.cs (1)
113typeSymbol.SpecialType != SpecialType.System_String)
Symbols\ConstraintsHelper.cs (10)
114NamedTypeSymbol effectiveBaseClass = corLibrary.GetSpecialType(typeParameter.HasValueTypeConstraint ? SpecialType.System_ValueType : SpecialType.System_Object); 229constraintEffectiveBase = corLibrary.GetSpecialType(SpecialType.System_ValueType); 235constraintEffectiveBase = corLibrary.GetSpecialType(SpecialType.System_Enum); 241constraintEffectiveBase = corLibrary.GetSpecialType(SpecialType.System_Array); 293Debug.Assert((effectiveBaseClass.SpecialType == SpecialType.System_Object) || (deducedBaseType.SpecialType != SpecialType.System_Object)); 297if ((constraintTypes.Length == 0) && (deducedBaseType.SpecialType == SpecialType.System_Object)) 299Debug.Assert(effectiveBaseClass.SpecialType == SpecialType.System_Object); 1541if (type.SpecialType == SpecialType.System_Object)
Symbols\DynamicTypeSymbol.cs (2)
192return (int)Microsoft.CodeAnalysis.SpecialType.System_Object; 210return (object?)other != null && other.SpecialType == Microsoft.CodeAnalysis.SpecialType.System_Object;
Symbols\FieldSymbol.cs (1)
142get { return this.IsConst && (this.Type.SpecialType != SpecialType.System_Decimal); }
Symbols\MemberSignatureComparer.cs (2)
679if (constraintType.SpecialType == SpecialType.System_Object) 692if ((constraintType.SpecialType == SpecialType.System_ValueType) &&
Symbols\Metadata\PE\DynamicTypeDecoder.cs (3)
145PeekFlag() && (type.SpecialType != SpecialType.System_Object && !type.IsDynamic())) 155if (type.SpecialType == SpecialType.System_Object) 176: _containingAssembly.GetSpecialType(SpecialType.System_Object);
Symbols\Metadata\PE\MetadataDecoder.cs (5)
177return new MissingMetadataTypeSymbol.TopLevel(new MissingModuleSymbolWithName(moduleSymbol.ContainingAssembly, moduleName), ref emittedName, SpecialType.None); 422SpecialType baseSpecialType = (candidate.BaseTypeNoUseSiteDiagnostics?.SpecialType ?? SpecialType.None); 423if (baseSpecialType == SpecialType.None || baseSpecialType != (baseType?.SpecialType ?? SpecialType.None))
Symbols\Metadata\PE\NativeIntegerTypeDecoder.cs (3)
19if (containingType?.SpecialType == SpecialType.System_Runtime_CompilerServices_RuntimeFeature 115case SpecialType.System_IntPtr: 116case SpecialType.System_UIntPtr:
Symbols\Metadata\PE\PEFieldSymbol.cs (3)
327_packedFlags.SetIsVolatile(customModifiersArray.Any(static m => !m.IsOptional && ((CSharpCustomModifier)m).ModifierSymbol.SpecialType == SpecialType.System_Runtime_CompilerServices_IsVolatile)); 493if (this.Type.SpecialType == SpecialType.System_Decimal) 600return this.Type.SpecialType == SpecialType.System_Decimal &&
Symbols\Metadata\PE\PEMethodSymbol.cs (1)
1274(method.ContainingType.SpecialType == SpecialType.System_Object &&
Symbols\Metadata\PE\PEModuleSymbol.cs (1)
492if (keepLookingForDeclaredCorTypes && type.SpecialType != SpecialType.None)
Symbols\Metadata\PE\PENamedTypeSymbol.cs (18)
36private readonly SpecialType _corTypeId; 347_corTypeId = SpecialType.None; 356public override SpecialType SpecialType 1763SpecialType baseCorTypeId = @base.SpecialType; 1767case SpecialType.System_Enum: 1772case SpecialType.System_MulticastDelegate: 1777case SpecialType.System_ValueType: 1779if (this.SpecialType != SpecialType.System_Enum) 1895if (this.SpecialType == Microsoft.CodeAnalysis.SpecialType.None) 1902isOrdinaryStruct = (this.SpecialType == Microsoft.CodeAnalysis.SpecialType.System_Nullable_T); 1949var isOrdinaryEmbeddableStruct = (this.TypeKind == TypeKind.Struct) && (this.SpecialType == Microsoft.CodeAnalysis.SpecialType.None) && this.ContainingAssembly.IsLinked; 2091else if (TypeKind == TypeKind.Class && SpecialType != SpecialType.System_Enum) 2094if (@base?.SpecialType == SpecialType.None && @base.ContainingAssembly?.IsMissing == true) 2102case SpecialType.System_Enum: 2103case SpecialType.System_MulticastDelegate: 2104case SpecialType.System_ValueType: 2493Debug.Assert(this.SpecialType == SpecialType.System_IntPtr || this.SpecialType == SpecialType.System_UIntPtr);
Symbols\Metadata\PE\PETypeParameterSymbol.cs (4)
273else if (typeSymbol.SpecialType == SpecialType.System_ValueType) 291if (typeSymbol.SpecialType == SpecialType.System_ValueType && ((_flags & GenericParameterAttributes.NotNullableValueTypeConstraint) != 0)) 545Debug.Assert(type.HasType && type.SpecialType == SpecialType.System_Object); 701return this.ContainingAssembly.GetSpecialType(SpecialType.System_Object);
Symbols\Metadata\PE\SymbolFactory.cs (1)
29internal override TypeSymbol GetSpecialType(PEModuleSymbol moduleSymbol, SpecialType specialType)
Symbols\MetadataOrSourceAssemblySymbol.cs (9)
43internal sealed override NamedTypeSymbol GetDeclaredSpecialType(SpecialType type) 80SpecialType typeId = corType.SpecialType; 81Debug.Assert(typeId != SpecialType.None); 89new NamedTypeSymbol[(int)SpecialType.Count + 1], null); 101Debug.Assert(_cachedSpecialTypes > 0 && _cachedSpecialTypes <= (int)SpecialType.Count); 113return ReferenceEquals(this.CorLibrary, this) && _cachedSpecialTypes < (int)SpecialType.Count; 144SpecialType.System_IntPtr => 0, 145SpecialType.System_UIntPtr => 1, 203NamedTypeSymbol type = GetDeclaredSpecialType((SpecialType)descriptor.DeclaringTypeId);
Symbols\MethodSymbol.cs (3)
1230new TypedConstant(declaringCompilation.GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, PEModule.RequiredMembersMarker), // message 1231new TypedConstant(declaringCompilation.GetSpecialType(SpecialType.System_Boolean), TypedConstantKind.Primitive, true)) // error 1236ImmutableArray.Create(new TypedConstant(declaringCompilation.GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, nameof(CompilerFeatureRequiredFeatures.RequiredMembers)))
Symbols\MethodSymbolExtensions.cs (1)
61else if (method.ContainingType.SpecialType == SpecialType.System_Object)
Symbols\MissingAssemblySymbol.cs (1)
178internal override NamedTypeSymbol GetDeclaredSpecialType(SpecialType type)
Symbols\MissingCorLibrarySymbol.cs (2)
43internal override NamedTypeSymbol GetDeclaredSpecialType(SpecialType type) 55new NamedTypeSymbol[(int)SpecialType.Count + 1], null);
Symbols\MissingMetadataTypeSymbol.cs (15)
162public TopLevel(ModuleSymbol module, ref MetadataTypeName fullName, SpecialType specialType, DiagnosticInfo? errorInfo = null) 195RoslynDebug.Assert(typeId == -1 || typeId == (int)SpecialType.None || arity == 0 || mangleName); 289SpecialType typeId = SpecialType.None; 307public override SpecialType SpecialType 312return (typeId >= (int)WellKnownType.First) ? SpecialType.None : (SpecialType)_lazyTypeId; 322var errorInfo = this.TypeId != (int)SpecialType.None ? 334if (this.SpecialType == Microsoft.CodeAnalysis.SpecialType.System_Object) 336return (int)Microsoft.CodeAnalysis.SpecialType.System_Object; 346Debug.Assert(this.SpecialType == SpecialType.System_IntPtr || this.SpecialType == SpecialType.System_UIntPtr); 376this.SpecialType == Microsoft.CodeAnalysis.SpecialType.System_Object) 436public override SpecialType SpecialType 440return SpecialType.None; // do not have nested types among CORE types yet.
Symbols\NamedTypeSymbol.cs (3)
785if (this.SpecialType == SpecialType.System_Object) 787return (int)SpecialType.System_Object; 807if (this.SpecialType == SpecialType.System_Object)
Symbols\NativeIntegerTypeSymbol.cs (6)
33Debug.Assert(underlyingType.SpecialType == SpecialType.System_IntPtr || underlyingType.SpecialType == SpecialType.System_UIntPtr); 50public override SpecialType SpecialType => _underlyingType.SpecialType; 281private readonly SpecialType _specialType; 288Debug.Assert(_specialType == SpecialType.System_IntPtr || _specialType == SpecialType.System_UIntPtr);
Symbols\PublicModel\TypeSymbol.cs (1)
169SpecialType ITypeSymbol.SpecialType => UnderlyingTypeSymbol.SpecialType;
Symbols\Retargeting\RetargetingAssemblySymbol.cs (1)
212internal override NamedTypeSymbol GetDeclaredSpecialType(SpecialType type)
Symbols\Retargeting\RetargetingSymbolTranslator.cs (1)
212return result.SpecialType == SpecialType.None ? result : result.AsNativeInteger();
Symbols\Source\FieldSymbolWithAttributesAndModifiers.cs (2)
188int offset = attribute.CommonConstructorArguments[0].DecodeValue<int>(SpecialType.System_Int32); 274if (this.Type.SpecialType == SpecialType.System_Decimal)
Symbols\Source\ImplicitNamedTypeSymbol.cs (2)
57=> IsScriptClass ? null : this.DeclaringCompilation.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_Object); 63diagnostics.ReportUseSite(this.DeclaringCompilation.GetSpecialType(SpecialType.System_Object), Locations[0]);
Symbols\Source\ParameterHelpers.cs (2)
752conversion.IsIdentity && parameterType.SpecialType == SpecialType.System_Object && defaultExpression.Type.IsDynamic()) 767defaultExpression.Type.SpecialType == SpecialType.System_String ||
Symbols\Source\SourceAssemblySymbol.cs (20)
1821var boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 1884var obj = GetSpecialType(SpecialType.System_Object); 1953var int32Type = _compilation.GetSpecialType(SpecialType.System_Int32); 1973var boolType = _compilation.GetSpecialType(SpecialType.System_Boolean); 2007var stringType = _compilation.GetSpecialType(SpecialType.System_String); 2017var stringType = _compilation.GetSpecialType(SpecialType.System_String); 2507wrapNonExceptionThrows = namedArg.Value.DecodeValue<bool>(SpecialType.System_Boolean); 2556int arg = attribute.GetConstructorArgument<int>(i, SpecialType.System_Int32); 2739case SpecialType.System_Boolean: 2741case SpecialType.System_Byte: 2742case SpecialType.System_Decimal: 2743case SpecialType.System_Double: 2744case SpecialType.System_Int16: 2745case SpecialType.System_Int32: 2746case SpecialType.System_Int64: 2747case SpecialType.System_SByte: 2748case SpecialType.System_Single: 2749case SpecialType.System_UInt16: 2750case SpecialType.System_UInt32: 2751case SpecialType.System_UInt64:
Symbols\Source\SourceComplexParameterSymbol.cs (9)
676if (constructorArguments[0].TryDecodeValue(SpecialType.System_String, out string? parameterName)) 875return arguments.Length == 1 && arguments[0].TryDecodeValue(SpecialType.System_Boolean, out bool value) ? 962SpecialType specialType = arg.Kind == TypedConstantKind.Enum ? 1062TypeSymbol intType = compilation.GetSpecialType(SpecialType.System_Int32); 1090TypeSymbol stringType = compilation.GetSpecialType(SpecialType.System_String); 1123TypeSymbol stringType = compilation.GetSpecialType(SpecialType.System_String); 1164TypeSymbol stringType = compilation.GetSpecialType(SpecialType.System_String); 1325if (constant.TypeInternal is not { SpecialType: SpecialType.System_String }) 1331var name = constant.DecodeValue<string>(SpecialType.System_String);
Symbols\Source\SourceConstructorSymbolBase.cs (1)
60_lazyReturnType = TypeWithAnnotations.Create(bodyBinder.GetSpecialType(SpecialType.System_Void, diagnostics, syntax));
Symbols\Source\SourceDelegateMethodSymbol.cs (7)
56var voidType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_Void, diagnostics, syntax)); 58var objectType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_Object, diagnostics, syntax)); 59var intPtrType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_IntPtr, diagnostics, syntax)); 76if (binder.Compilation.GetSpecialType(SpecialType.System_IAsyncResult).TypeKind != TypeKind.Error && 77binder.Compilation.GetSpecialType(SpecialType.System_AsyncCallback).TypeKind != TypeKind.Error && 81var iAsyncResultType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_IAsyncResult, diagnostics, syntax)); 82var asyncCallbackType = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_AsyncCallback, diagnostics, syntax));
Symbols\Source\SourceDestructorSymbol.cs (1)
73_lazyReturnType = TypeWithAnnotations.Create(bodyBinder.GetSpecialType(SpecialType.System_Void, diagnostics, syntax));
Symbols\Source\SourceEnumConstantSymbol.cs (1)
153var constantType = this.ContainingType.EnumUnderlyingType.SpecialType;
Symbols\Source\SourceEventAccessorSymbol.cs (2)
131TypeSymbol voidType = compilation.GetSpecialType(SpecialType.System_Void); 145TypeSymbol voidType = compilation.GetSpecialType(SpecialType.System_Void);
Symbols\Source\SourceFieldSymbol.cs (1)
88CSharpCustomModifier.CreateRequired(this.ContainingAssembly.GetSpecialType(SpecialType.System_Runtime_CompilerServices_IsVolatile)));
Symbols\Source\SourceFixedFieldSymbol.cs (3)
46var intType = compilation.GetSpecialType(SpecialType.System_Int32); 89TypeSymbol intType = binder.GetSpecialType(SpecialType.System_Int32, diagnostics, sizeExpression); 237=> ContainingAssembly.GetSpecialType(SpecialType.System_ValueType);
Symbols\Source\SourceMemberContainerSymbol.cs (18)
76public SpecialType SpecialType 78get { return (SpecialType)((_flags >> SpecialTypeOffset) & SpecialTypeMask); } 106Debug.Assert(EnumUtilities.ContainsAllValues<SpecialType>(SpecialTypeMask)); 111public Flags(SpecialType specialType, TypeKind typeKind) 241var specialType = access == (int)DeclarationModifiers.Public 243: SpecialType.None; 256private SpecialType MakeSpecialType() 270return SpecialType.None; 754public override SpecialType SpecialType 2556if (method.IsOverride && method.GetConstructedLeastOverriddenMethod(this, requireSameReturnType: false).ContainingType.SpecialType == Microsoft.CodeAnalysis.SpecialType.System_Object) 4035TypeWithAnnotations.Create(compilation.GetSpecialType(SpecialType.System_Void)), 4052if (deconstruct.ReturnType.SpecialType != SpecialType.System_Void && !deconstruct.ReturnType.IsErrorType()) 4082TypeWithAnnotations.Create(compilation.GetSpecialType(SpecialType.System_Void)), 4129returnType: TypeWithAnnotations.Create(compilation.GetSpecialType(SpecialType.System_Boolean)), 4184returnType: TypeWithAnnotations.Create(compilation.GetSpecialType(SpecialType.System_String)), 4358TypeWithAnnotations.Create(compilation.GetSpecialType(SpecialType.System_Int32)), 4456TypeWithAnnotations.Create(compilation.GetSpecialType(SpecialType.System_Boolean)), 4476if (thisEquals.ReturnType.SpecialType != SpecialType.System_Boolean && !thisEquals.ReturnType.IsErrorType())
Symbols\Source\SourceMemberFieldSymbol.cs (2)
112&& this.Type.SpecialType == SpecialType.System_Decimal) 136if (IsConst && Type.SpecialType == SpecialType.System_Decimal &&
Symbols\Source\SourceMethodSymbolWithAttributes.cs (10)
336string? name = attributeData.GetConstructorArgument<string>(0, SpecialType.System_String); 695string name = attribute.GetConstructorArgument<string>(0, SpecialType.System_String); 789string? moduleName = attribute.GetConstructorArgument<string>(0, SpecialType.System_String); 832charSet = namedArg.Value.DecodeValue<CharSet>(SpecialType.System_Enum); 837setLastError = namedArg.Value.DecodeValue<bool>(SpecialType.System_Boolean); 842exactSpelling = namedArg.Value.DecodeValue<bool>(SpecialType.System_Boolean); 846preserveSig = namedArg.Value.DecodeValue<bool>(SpecialType.System_Boolean); 851callingConvention = namedArg.Value.DecodeValue<CallingConvention>(SpecialType.System_Enum); 855bestFitMapping = namedArg.Value.DecodeValue<bool>(SpecialType.System_Boolean); 859throwOnUnmappable = namedArg.Value.DecodeValue<bool>(SpecialType.System_Boolean);
Symbols\Source\SourceModuleSymbol.cs (3)
515CharSet charSet = attribute.GetConstructorArgument<CharSet>(0, SpecialType.System_Enum); 592var version = ImmutableArray.Create(new TypedConstant(compilation.GetSpecialType(SpecialType.System_Int32), TypedConstantKind.Primitive, 11)); 599new TypedConstant(compilation.GetSpecialType(SpecialType.System_Boolean), TypedConstantKind.Primitive, _assemblySymbol.InternalsAreVisible));
Symbols\Source\SourceNamedTypeSymbol.cs (10)
941string? name = attributeData.GetConstructorArgument<string>(0, SpecialType.System_String); 1016Debug.Assert(this.SpecialType == SpecialType.System_Object || this.DeclaringCompilation.IsAttributeType(this)); 1298string name = attribute.GetConstructorArgument<string>(0, SpecialType.System_String); 1488if ((object)baseType != null && baseType.SpecialType != SpecialType.System_Object) 1580new TypedConstant(compilation.GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, PEModule.ByRefLikeMarker), // message 1581new TypedConstant(compilation.GetSpecialType(SpecialType.System_Boolean), TypedConstantKind.Primitive, true)), // error=true 1586ImmutableArray.Create(new TypedConstant(compilation.GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, nameof(CompilerFeatureRequiredFeatures.RefStructs))), 1599var defaultMemberNameConstant = new TypedConstant(compilation.GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, defaultMemberName); 1644Debug.Assert(this.SpecialType == SpecialType.System_IntPtr || this.SpecialType == SpecialType.System_UIntPtr);
Symbols\Source\SourceNamedTypeSymbol_Bases.cs (19)
472SpecialType baseSpecialType = baseType.SpecialType; 476if (this.SpecialType == SpecialType.System_Enum && baseSpecialType == SpecialType.System_ValueType || 477this.SpecialType == SpecialType.System_MulticastDelegate && baseSpecialType == SpecialType.System_Delegate) 481else if (baseSpecialType == SpecialType.System_Array && this.ContainingAssembly.CorLibrary == this.ContainingAssembly) 527if (this.IsStatic && localBase.SpecialType != SpecialType.System_Object) 622if (this.SpecialType == SpecialType.System_Object && ((object)localBase != null || localInterfaces.Count != 0)) 643private static bool IsRestrictedBaseType(SpecialType specialType) 647case SpecialType.System_Array: 648case SpecialType.System_Enum: 649case SpecialType.System_Delegate: 650case SpecialType.System_MulticastDelegate: 651case SpecialType.System_ValueType: 717declaredBase = compilation.GetSpecialType(SpecialType.System_Enum); 730if (this.SpecialType == SpecialType.System_Object) 735declaredBase = compilation.GetSpecialType(SpecialType.System_Object); 739declaredBase = compilation.GetSpecialType(SpecialType.System_ValueType); 746declaredBase = compilation.GetSpecialType(SpecialType.System_MulticastDelegate);
Symbols\Source\SourceNamedTypeSymbol_Enum.cs (2)
69type = compilation.GetSpecialType(SpecialType.System_Int32); 76NamedTypeSymbol defaultUnderlyingType = compilation.GetSpecialType(SpecialType.System_Int32);
Symbols\Source\SourceNamespaceSymbol.cs (1)
466if ((object)type != null && type.SpecialType != SpecialType.None)
Symbols\Source\SourceOrdinaryMethodSymbol.cs (3)
153if (returnType.SpecialType == SpecialType.System_TypedReference && 154(this.ContainingType.SpecialType == SpecialType.System_TypedReference || this.ContainingType.SpecialType == SpecialType.System_ArgIterator))
Symbols\Source\SourceParameterSymbolBase.cs (1)
83defaultValue.SpecialType == SpecialType.System_Decimal &&
Symbols\Source\SourcePropertyAccessorSymbol.cs (1)
388var type = TypeWithAnnotations.Create(binder.GetSpecialType(SpecialType.System_Void, diagnostics, this.GetSyntax()));
Symbols\Source\SourcePropertySymbolBase.cs (2)
1194string? indexerName = attributeData.CommonConstructorArguments[0].DecodeValue<string>(SpecialType.System_String); 1414string indexerName = attribute.CommonConstructorArguments[0].DecodeValue<string>(SpecialType.System_String);
Symbols\Source\SourceTypeParameterSymbol.cs (1)
342return this.ContainingAssembly.GetSpecialType(SpecialType.System_Object);
Symbols\Source\SourceUserDefinedOperatorSymbolBase.cs (3)
473if ((ContainingType.SpecialType == SpecialType.System_Nullable_T) 614if (this.ReturnType.SpecialType != SpecialType.System_Boolean) 724else if (this.GetParameterType(1).StrippedType().SpecialType != SpecialType.System_Int32)
Symbols\SpecialTypeExtensions.cs (29)
11public static bool CanBeConst(this SpecialType specialType) 15case SpecialType.System_Boolean: 16case SpecialType.System_Char: 17case SpecialType.System_SByte: 18case SpecialType.System_Int16: 19case SpecialType.System_Int32: 20case SpecialType.System_Int64: 21case SpecialType.System_Byte: 22case SpecialType.System_UInt16: 23case SpecialType.System_UInt32: 24case SpecialType.System_UInt64: 25case SpecialType.System_Single: 26case SpecialType.System_Double: 27case SpecialType.System_Decimal: 28case SpecialType.System_String: 35public static bool IsValidVolatileFieldType(this SpecialType specialType) 39case SpecialType.System_Byte: 40case SpecialType.System_SByte: 41case SpecialType.System_Int16: 42case SpecialType.System_UInt16: 43case SpecialType.System_Int32: 44case SpecialType.System_UInt32: 45case SpecialType.System_Char: 46case SpecialType.System_Single: 47case SpecialType.System_Boolean: 48case SpecialType.System_IntPtr: 49case SpecialType.System_UIntPtr: 56public static int FixedBufferElementSizeInBytes(this SpecialType specialType) 60return specialType == SpecialType.System_Decimal ? 0 : specialType.SizeInBytes();
Symbols\Symbol.cs (1)
1147modifierType.SpecialType == SpecialType.System_Runtime_CompilerServices_IsVolatile)
Symbols\Synthesized\Records\SynthesizedRecordBaseEquals.cs (2)
36return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 77F.Convert(F.SpecialType(SpecialType.System_Object), F.Parameter(parameter)));
Symbols\Synthesized\Records\SynthesizedRecordDeconstruct.cs (1)
42return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Void, location, diagnostics)),
Symbols\Synthesized\Records\SynthesizedRecordEqualityOperator.cs (2)
46candidate.ReturnType.SpecialType == SpecialType.System_Boolean && !candidate.IsStatic && 72BoundExpression recordEquals = F.LogicalAnd(F.ObjectNotEqual(left, F.Null(F.SpecialType(SpecialType.System_Object))),
Symbols\Synthesized\Records\SynthesizedRecordEqualityOperatorBase.cs (1)
69return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)),
Symbols\Synthesized\Records\SynthesizedRecordEquals.cs (3)
41return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 100retExpr = F.ObjectNotEqual(other, F.Null(F.SpecialType(SpecialType.System_Object))); 114baseEquals.ReturnType.SpecialType != SpecialType.System_Boolean)
Symbols\Synthesized\Records\SynthesizedRecordGetHashCode.cs (2)
34return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Int32, location, diagnostics)), 83if (overridden is null || overridden.ReturnType.SpecialType != SpecialType.System_Int32)
Symbols\Synthesized\Records\SynthesizedRecordObjEquals.cs (3)
32return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 35TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Object, location, diagnostics), annotation), 49if (_typedRecordEquals.ReturnType.SpecialType != SpecialType.System_Boolean)
Symbols\Synthesized\Records\SynthesizedRecordPrintMembers.cs (3)
93return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_Boolean, location, diagnostics)), 159basePrintMethod.ReturnType.SpecialType != SpecialType.System_Boolean) 222F.Convert(F.SpecialType(SpecialType.System_Object), value))));
Symbols\Synthesized\Records\SynthesizedRecordToString.cs (1)
44return (ReturnType: TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_String, location, diagnostics), annotation),
Symbols\Synthesized\SynthesizedContainer.cs (2)
156internal override NamedTypeSymbol BaseTypeNoUseSiteDiagnostics => ContainingAssembly.GetSpecialType(this.TypeKind == TypeKind.Struct ? SpecialType.System_ValueType : SpecialType.System_Object);
Symbols\Synthesized\SynthesizedEntryPointSymbol.cs (3)
33var systemObject = Binder.GetSpecialType(compilation, SpecialType.System_Object, DummySyntax(), diagnostics); 43var systemVoid = Binder.GetSpecialType(compilation, SpecialType.System_Void, DummySyntax(), diagnostics); 365ReturnType.SpecialType == SpecialType.System_Int32);
Symbols\Synthesized\SynthesizedFieldSymbolBase.cs (1)
75compilation.CanEmitSpecialType(SpecialType.System_String))
Symbols\Synthesized\SynthesizedInstanceConstructor.cs (1)
156get { return TypeWithAnnotations.Create(ContainingAssembly.GetSpecialType(SpecialType.System_Void)); }
Symbols\Synthesized\SynthesizedInteractiveInitializerMethod.cs (1)
274? compilation.GetSpecialType(SpecialType.System_Object)
Symbols\Synthesized\SynthesizedParameterSymbol.cs (3)
168compilation.CanEmitSpecialType(SpecialType.System_String)) 201SpecialType.System_Decimal => compilation.SynthesizeDecimalConstantAttribute(defaultValue.DecimalValue), 202SpecialType.System_DateTime => compilation.SynthesizeDateTimeConstantAttribute(defaultValue.DateTimeValue),
Symbols\Synthesized\SynthesizedSimpleProgramEntryPointSymbol.cs (4)
44_returnType = Binder.GetSpecialType(compilation, SpecialType.System_Void, NoLocation.Singleton, diagnostics); 48Construct(Binder.GetSpecialType(compilation, SpecialType.System_Int32, NoLocation.Singleton, diagnostics)); 51_returnType = Binder.GetSpecialType(compilation, SpecialType.System_Int32, NoLocation.Singleton, diagnostics); 67TypeWithAnnotations.Create(Binder.GetSpecialType(compilation, SpecialType.System_String, NoLocation.Singleton, diagnostics)))), 0, RefKind.None, "args"));
Symbols\Synthesized\SynthesizedStaticConstructor.cs (1)
139return TypeWithAnnotations.Create(ContainingAssembly.GetSpecialType(SpecialType.System_Void));
Symbols\Synthesized\SynthesizedSubmissionConstructor.cs (1)
24var submissionArrayType = compilation.CreateArrayTypeSymbol(compilation.GetSpecialType(SpecialType.System_Object));
Symbols\Synthesized\SynthesizedThrowIfNullMethod.cs (1)
44F.Binary(BinaryOperatorKind.ObjectEqual, F.SpecialType(SpecialType.System_Boolean),
Symbols\Synthesized\SynthesizedThrowSwitchExpressionExceptionMethod.cs (1)
33Debug.Assert(unmatchedValue.Type.SpecialType == SpecialType.System_Object);
Symbols\TypedConstantExtensions.cs (4)
30if (constant.Kind == TypedConstantKind.Type || constant.TypeInternal!.SpecialType == SpecialType.System_Object) 52SpecialType splType = ((INamedTypeSymbol)constant.Type!).EnumUnderlyingType!.SpecialType; 67private static string DisplayUnsignedEnumConstant(TypedConstant constant, SpecialType specialType, ulong constantToDecode, string typeName) 146private static string DisplaySignedEnumConstant(TypedConstant constant, SpecialType specialType, long constantToDecode, string typeName)
Symbols\TypeParameterSymbol.cs (3)
421case SpecialType.System_Object: 422case SpecialType.System_ValueType: 423case SpecialType.System_Enum:
Symbols\TypeSymbol.cs (5)
493public virtual SpecialType SpecialType 497return SpecialType.None; 557|| (SpecialType is SpecialType.System_IntPtr or SpecialType.System_UIntPtr && this.ContainingAssembly.RuntimeSupportsNumericIntPtr); 2455SpecialType ITypeSymbolInternal.SpecialType => this.SpecialType;
Symbols\TypeSymbolExtensions.cs (95)
99return type.SpecialType == SpecialType.System_Void; 133return type.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T; 175return type.SpecialType == SpecialType.System_Object; 180return type.SpecialType == SpecialType.System_String; 185return type.SpecialType == SpecialType.System_Char; 208return (underlyingType is object) && (underlyingType.SpecialType != SpecialType.None); 466SpecialType st = t.SpecialType; 468if (st == SpecialType.System_Collections_Generic_IList_T || 469st == SpecialType.System_Collections_Generic_ICollection_T || 470st == SpecialType.System_Collections_Generic_IEnumerable_T || 471st == SpecialType.System_Collections_Generic_IReadOnlyList_T || 472st == SpecialType.System_Collections_Generic_IReadOnlyCollection_T) 582case SpecialType.System_SByte: 583case SpecialType.System_Byte: 584case SpecialType.System_Int16: 585case SpecialType.System_UInt16: 586case SpecialType.System_Int32: 587case SpecialType.System_UInt32: 588case SpecialType.System_Int64: 589case SpecialType.System_UInt64: 590case SpecialType.System_IntPtr when type.IsNativeIntegerType: 591case SpecialType.System_UIntPtr when type.IsNativeIntegerType: 592case SpecialType.System_Char: 593case SpecialType.System_Boolean: 594case SpecialType.System_Single: 595case SpecialType.System_Double: 596case SpecialType.System_Decimal: 604public static SpecialType GetSpecialTypeSafe(this TypeSymbol? type) 606return type is object ? type.SpecialType : SpecialType.None; 1257case SpecialType.System_SByte: 1258case SpecialType.System_Byte: 1259case SpecialType.System_Int16: 1260case SpecialType.System_UInt16: 1261case SpecialType.System_Int32: 1262case SpecialType.System_UInt32: 1263case SpecialType.System_Int64: 1264case SpecialType.System_UInt64: 1265case SpecialType.System_Char: 1266case SpecialType.System_String: 1269case SpecialType.System_Boolean: 1285&& arguments[0].SpecialType == SpecialType.System_Char; 1296&& arguments[0].SpecialType == SpecialType.System_Char; 1307&& arguments[0].SpecialType == SpecialType.System_Char; 1324case SpecialType.System_TypedReference: 1325case SpecialType.System_ArgIterator: 1326case SpecialType.System_RuntimeArgumentHandle: 1339case SpecialType.System_Boolean: 1340case SpecialType.System_Char: 1341case SpecialType.System_SByte: 1342case SpecialType.System_Int16: 1343case SpecialType.System_Int32: 1344case SpecialType.System_Int64: 1345case SpecialType.System_Byte: 1346case SpecialType.System_UInt16: 1347case SpecialType.System_UInt32: 1348case SpecialType.System_UInt64: 1349case SpecialType.System_IntPtr when type.IsNativeIntegerType: 1350case SpecialType.System_UIntPtr when type.IsNativeIntegerType: 1351case SpecialType.System_Single: 1352case SpecialType.System_Double: 1355case SpecialType.System_Decimal: 1558if (type.SpecialType == SpecialType.System_Object) 2112case SpecialType.System_Object: return 0; 2113case SpecialType.System_String: return 1; 2114case SpecialType.System_Boolean: return 2; 2115case SpecialType.System_Char: return 3; 2116case SpecialType.System_SByte: return 4; 2117case SpecialType.System_Int16: return 5; 2118case SpecialType.System_Int32: return 6; 2119case SpecialType.System_Int64: return 7; 2120case SpecialType.System_Byte: return 8; 2121case SpecialType.System_UInt16: return 9; 2122case SpecialType.System_UInt32: return 10; 2123case SpecialType.System_UInt64: return 11; 2124case SpecialType.System_IntPtr when type.IsNativeIntegerType: return 12; 2125case SpecialType.System_UIntPtr when type.IsNativeIntegerType: return 13; 2126case SpecialType.System_Single: return 14; 2127case SpecialType.System_Double: return 15; 2128case SpecialType.System_Decimal: return 16; 2130case SpecialType.None: 2137case SpecialType.System_Boolean: return 17; 2138case SpecialType.System_Char: return 18; 2139case SpecialType.System_SByte: return 19; 2140case SpecialType.System_Int16: return 20; 2141case SpecialType.System_Int32: return 21; 2142case SpecialType.System_Int64: return 22; 2143case SpecialType.System_Byte: return 23; 2144case SpecialType.System_UInt16: return 24; 2145case SpecialType.System_UInt32: return 25; 2146case SpecialType.System_UInt64: return 26; 2147case SpecialType.System_IntPtr when underlyingType.IsNativeIntegerType: return 27; 2148case SpecialType.System_UIntPtr when underlyingType.IsNativeIntegerType: return 28; 2149case SpecialType.System_Single: return 29; 2150case SpecialType.System_Double: return 30; 2151case SpecialType.System_Decimal: return 31;
Symbols\TypeWithAnnotations.cs (8)
215=> Create(compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(ImmutableArray.Create(typeSymbol))); 263public SpecialType SpecialType => _extensions.GetSpecialType(DefaultType); 840internal abstract SpecialType GetSpecialType(TypeSymbol typeSymbol); 870internal override SpecialType GetSpecialType(TypeSymbol typeSymbol) => typeSymbol.SpecialType; 958internal override SpecialType GetSpecialType(TypeSymbol typeSymbol) 960var specialType = _underlying.SpecialType; 961return specialType.IsValueType() ? SpecialType.None : specialType; 1068_compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(ImmutableArray.Create(_underlying)) :
Syntax\SyntaxKindExtensions.cs (17)
11internal static SpecialType GetSpecialType(this SyntaxKind kind) 16return SpecialType.System_Void; 18return SpecialType.System_Boolean; 20return SpecialType.System_Byte; 22return SpecialType.System_SByte; 24return SpecialType.System_Int16; 26return SpecialType.System_UInt16; 28return SpecialType.System_Int32; 30return SpecialType.System_UInt32; 32return SpecialType.System_Int64; 34return SpecialType.System_UInt64; 36return SpecialType.System_Double; 38return SpecialType.System_Single; 40return SpecialType.System_Decimal; 42return SpecialType.System_String; 44return SpecialType.System_Char; 46return SpecialType.System_Object;
Utilities\TypeSymbolExtensions.cs (3)
210if (type.SpecialType == SpecialType.System_Object) 270return compilation.Assembly.GetSpecialType(SpecialType.System_Object); 274return compilation.Assembly.GetSpecialType(SpecialType.System_ValueType);
Utilities\ValueSetFactory.cs (17)
32public static IValueSetFactory? ForSpecialType(SpecialType specialType, bool isNative = false) 36SpecialType.System_Byte => ForByte, 37SpecialType.System_SByte => ForSByte, 38SpecialType.System_Char => ForChar, 39SpecialType.System_Int16 => ForShort, 40SpecialType.System_UInt16 => ForUShort, 41SpecialType.System_Int32 => ForInt, 42SpecialType.System_UInt32 => ForUInt, 43SpecialType.System_Int64 => ForLong, 44SpecialType.System_UInt64 => ForULong, 45SpecialType.System_Boolean => ForBool, 46SpecialType.System_Single => ForFloat, 47SpecialType.System_Double => ForDouble, 48SpecialType.System_String => ForString, 49SpecialType.System_Decimal => ForDecimal, 50SpecialType.System_IntPtr when isNative => ForNint, 51SpecialType.System_UIntPtr when isNative => ForNuint,
Microsoft.CodeAnalysis.CSharp.CodeStyle (37)
CastSimplifier.cs (9)
92Parent.Parent: IConversionOperation { Type.SpecialType: SpecialType.System_Object } conversionOperation 470if (castNode.IsParentKind(SyntaxKind.Interpolation) && originalConversionOperation.Type?.SpecialType is SpecialType.System_Object) 579if (current.ContainingType.SpecialType == SpecialType.System_Object) 675=> type.IsSignedIntegralType() || type?.SpecialType is SpecialType.System_IntPtr; 769if (binaryOperation.LeftOperand.Type?.SpecialType == SpecialType.System_Object && 776else if (binaryOperation.RightOperand.Type?.SpecialType == SpecialType.System_Object && 959=> type?.SpecialType is SpecialType.System_Double or SpecialType.System_Single; 1217rewrittenType.SpecialType == SpecialType.System_Enum;
ConvertProgramAnalysis_TopLevelStatements.cs (1)
94if (containingType.BaseType?.SpecialType != SpecialType.System_Object)
CSharpAsAndNullCheckDiagnosticAnalyzer.cs (1)
86if (castType?.SpecialType == SpecialType.System_Object)
CSharpMakeStructMemberReadOnlyAnalyzer.cs (2)
253if (methodReference.ContainingType.SpecialType is SpecialType.System_Object or SpecialType.System_ValueType)
CSharpRemoveUnnecessaryLambdaExpressionDiagnosticAnalyzer.cs (1)
127if (lambdaTypeInfo.ConvertedType == null || lambdaTypeInfo.ConvertedType.SpecialType is SpecialType.System_Object)
CSharpUseCompoundCoalesceAssignmentDiagnosticAnalyzer.cs (2)
197if (symbol is null || !symbol.IsUserDefinedOperator() || symbol.ContainingType.SpecialType == SpecialType.System_String) 215symbol.ContainingType?.SpecialType == SpecialType.System_Object)
CSharpUseIndexOperatorDiagnosticAnalyzer.cs (1)
84var arrayType = compilation.GetSpecialType(SpecialType.System_Array);
CSharpUseIsNullCheckForCastAndEqualityOperatorDiagnosticAnalyzer.cs (1)
77if (semanticModel.GetTypeInfo(castExpression.Type).Type?.SpecialType == SpecialType.System_Object)
CSharpUseRangeOperatorDiagnosticAnalyzer.InfoCache.cs (1)
64var stringType = compilation.GetSpecialType(SpecialType.System_String);
Helpers.cs (4)
30p.Type.SpecialType == SpecialType.System_Int32) 77method.OriginalDefinition.Parameters[0].Type.SpecialType == SpecialType.System_Int32; 115=> parameter.Type.SpecialType == SpecialType.System_Int32 && 119=> parameter.Type.SpecialType == SpecialType.System_Int32 &&
ITypeSymbolExtensions.cs (13)
13case SpecialType.System_Boolean: 14case SpecialType.System_Char: 15case SpecialType.System_SByte: 16case SpecialType.System_Int16: 17case SpecialType.System_Int32: 18case SpecialType.System_Int64: 19case SpecialType.System_Byte: 20case SpecialType.System_UInt16: 21case SpecialType.System_UInt32: 22case SpecialType.System_UInt64: 23case SpecialType.System_Single: 24case SpecialType.System_Double: 27case SpecialType.System_Decimal:
UseUtf8StringLiteralDiagnosticAnalyzer.cs (1)
78if (arrayCreationOperation.Type is not IArrayTypeSymbol { ElementType.SpecialType: SpecialType.System_Byte })
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (59)
ConvertToRecordHelpers.cs (4)
29methodSymbol.ReturnType.SpecialType == SpecialType.System_Boolean && 37methodSymbol.Parameters.First().Type.SpecialType == SpecialType.System_Object && 516else if (parameter.Type.SpecialType == SpecialType.System_Object) 1107var objectType = compilation.GetSpecialType(SpecialType.System_Object);
CSharpFixIncorrectConstraintCodeFixProvider.cs (2)
95isEnumConstraint ? SpecialType.System_Enum : SpecialType.System_Delegate));
CSharpFixReturnTypeCodeFixProvider.cs (1)
107if (previousReturnType.SpecialType is SpecialType.System_Void ||
CSharpFlagsEnumGenerator.cs (1)
22SpecialType underlyingSpecialType,
CSharpReplaceDefaultLiteralCodeFixProvider.cs (2)
101else if (type.SpecialType is SpecialType.System_IntPtr or SpecialType.System_UIntPtr)
CSharpTypeInferenceService.TypeInferrer.cs (35)
581return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 842return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 972return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 982return CreateResult(SpecialType.System_Boolean); 1037if (parentTypes.Any(static parentType => parentType.InferredType.SpecialType == SpecialType.System_String || parentType.InferredType.TypeKind == TypeKind.Delegate)) 1039return parentTypes.Where(parentType => parentType.InferredType.SpecialType == SpecialType.System_String || parentType.InferredType.TypeKind == TypeKind.Delegate); 1070return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 1077return CreateResult(SpecialType.System_Boolean); 1118return CreateResult(SpecialType.System_Boolean); 1141return CreateResult(SpecialType.System_Object, NullableAnnotation.Annotated); 1155else if (symbol.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T) 1162return compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(symbol); 1183return CreateResult(SpecialType.System_Boolean); 1219return CreateResult(SpecialType.System_Boolean); 1260return CreateResult(SpecialType.System_Void); 1277? this.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 1280enumerableType ??= this.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T); 1288.Construct(Compilation.GetSpecialType(SpecialType.System_Object))); 1307return CreateResult(SpecialType.System_Boolean); 1318return CreateResult(SpecialType.System_Boolean); 1631return CreateResult(SpecialType.System_Object); 1936return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 1954return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 1961return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 1970return CreateResult(SpecialType.System_Boolean); 2019return types.Select(t => t.InferredType.SpecialType == SpecialType.System_Void ? new TypeInferenceInfo(task) : new TypeInferenceInfo(taskOfT.Construct(t.InferredType))); 2057return this.Compilation.GetSpecialType(SpecialType.System_Void); 2189return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 2222return CreateResult(SpecialType.System_IDisposable); 2246return CreateResult(SpecialType.System_IDisposable); 2250return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 2253if (laterUsageInference is not [] and not [{ InferredType.SpecialType: SpecialType.System_Object }]) 2282if (inferredDescendantTypes is not [] and not [{ InferredType.SpecialType: SpecialType.System_Object }]) 2434return SpecializedCollections.SingletonEnumerable(new TypeInferenceInfo(Compilation.GetSpecialType(SpecialType.System_Boolean))); 2445return CreateResult(SpecialType.System_Boolean);
ExpressionGenerator.cs (6)
125var isNotSingle = !IsSpecialType(type, SpecialType.System_Single); 136if (value is double && !IsSpecialType(type, SpecialType.System_Double)) 141if (value is uint && !IsSpecialType(type, SpecialType.System_UInt32)) 146if (value is long && !IsSpecialType(type, SpecialType.System_Int64)) 151if (value is ulong && !IsSpecialType(type, SpecialType.System_UInt64)) 160var isNotDecimal = !IsSpecialType(type, SpecialType.System_Decimal);
ExpressionSyntaxExtensions.cs (1)
114targetType = semanticModel.Compilation.GetSpecialType(SpecialType.System_Object);
InternalExtensions.cs (1)
36if (typeInfo.Type != null && typeInfo.Type.SpecialType == SpecialType.System_Void)
ITypeParameterSymbolExtensions.cs (1)
64if (type.SpecialType != SpecialType.System_Object)
ITypeSymbolExtensions.TypeSyntaxGeneratorVisitor.cs (2)
117syntax = SyntaxFactory.IdentifierName(symbol.SpecialType == SpecialType.System_IntPtr ? "nint" : "nuint"); 221if (symbol.SpecialType == SpecialType.System_Void)
NamedTypeGenerator.cs (2)
245var baseList = namedType.EnumUnderlyingType != null && namedType.EnumUnderlyingType.SpecialType != SpecialType.System_Int32 324if (namedType.TypeKind == TypeKind.Class && namedType.BaseType != null && namedType.BaseType.SpecialType != Microsoft.CodeAnalysis.SpecialType.System_Object)
UseUtf8StringLiteralCodeFixProvider.cs (1)
70namedType.TypeArguments[0].SpecialType == SpecialType.System_Byte;
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (26)
CodeGeneration\SyntaxGeneratorTests.cs (2)
92Assert.Equal(SpecialType.System_String, typeInfo.Type.SpecialType); 93Assert.Equal(SpecialType.System_String, typeInfo.ConvertedType.SpecialType);
EditAndContinue\TopLevelEditingTests.cs (24)
5423SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("S.C.F2").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Byte))?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("S.C")) 5427semanticEdits: new[] { SemanticEdit(SemanticEditKind.Insert, c => c.GetMembers("S.C.F2").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Int32))?.ISymbol) }) 6738SemanticEdit(SemanticEditKind.Insert, c => c.GetMembers("S.F").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Byte))?.ISymbol) 6744SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("S.F").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Int32))?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("S")) 7852SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.Main").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Boolean))?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 7853SemanticEdit(SemanticEditKind.Insert, c => c.GetMembers("C.Main").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Int32))?.ISymbol) 7889SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.Main").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Boolean))?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 7890SemanticEdit(SemanticEditKind.Insert, c => c.GetMembers("C.Main").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Int32))?.ISymbol) 9771SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C..ctor").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Boolean))?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 9772SemanticEdit(SemanticEditKind.Insert, c => c.GetMembers("C..ctor").FirstOrDefault(m => m.GetParameterTypes().Any(t => t.SpecialType == SpecialType.System_Int32))?.ISymbol) 13737SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.add_E").FirstOrDefault(m => m.GetParameterTypes()[0].Type.GetMemberTypeArgumentsNoUseSiteDiagnostics()[0].SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 13738SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.remove_E").FirstOrDefault(m => m.GetParameterTypes()[0].Type.GetMemberTypeArgumentsNoUseSiteDiagnostics()[0].SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 13759SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.add_E").FirstOrDefault(m => m.GetParameterTypes()[0].Type.GetMemberTypeArgumentsNoUseSiteDiagnostics()[0].GetMemberTypeArgumentsNoUseSiteDiagnostics()[1].SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 13760SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.remove_E").FirstOrDefault(m => m.GetParameterTypes()[0].Type.GetMemberTypeArgumentsNoUseSiteDiagnostics()[0].GetMemberTypeArgumentsNoUseSiteDiagnostics()[1].SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 13844SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.add_E").FirstOrDefault(m => m.GetParameterTypes()[0].Type.SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 13845SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.remove_E").FirstOrDefault(m => m.GetParameterTypes()[0].Type.SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 14433SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.set_P").FirstOrDefault(p => p.GetParameters()[0].Type.SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 14455SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.set_P").FirstOrDefault(p => p.GetParameters()[0].Type.SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 15697SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.set_Item").FirstOrDefault(p => p.GetParameters()[1].Type.SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 15790SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.get_Item").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 15791SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.set_Item").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Int32)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 15792SemanticEdit(SemanticEditKind.Insert, c => c.GetMembers("C.this[]").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_String)?.ISymbol), 16958SemanticEdit(SemanticEditKind.Delete, c => c.GetMembers("C.M").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_String)?.ISymbol, deletedSymbolContainerProvider: c => c.GetMember("C")), 16959SemanticEdit(SemanticEditKind.Insert, c => c.GetMembers("C.M").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Int32)?.ISymbol)
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (200)
CodeGen\CodeGenAsyncLocalsTests.cs (1)
971Assert.Equal(1, spillFieldsByType.Single(x => TypeSymbol.Equals(x.Key, comp.GetSpecialType(SpecialType.System_Int32), TypeCompareKind.ConsiderEverything2)).Count());
CodeGen\CodeGenAsyncTests.cs (2)
922Assert.Equal(SpecialType.System_Int64, hoistedField.Type.SpecialType); 981Assert.Equal(SpecialType.System_Int64, hoistedField.Type.SpecialType);
CodeGen\CodeGenAwaitUsingTests.cs (3)
595comp.MakeTypeMissing(SpecialType.System_IDisposable); 2421comp.MakeTypeMissing(SpecialType.System_IDisposable); 2444comp.MakeTypeMissing(SpecialType.System_IDisposable);
CodeGen\CodeGenDeconstructTests.cs (3)
7236Assert.Equal(SpecialType.System_Int32, symbolInfo.Symbol.GetTypeOrReturnType().SpecialType); 7511Assert.Equal(SpecialType.System_Int32, xSymbolInfo.Symbol.GetTypeOrReturnType().SpecialType); 7518Assert.Equal(SpecialType.System_Boolean, zSymbolInfo.Symbol.GetTypeOrReturnType().SpecialType);
CodeGen\CodeGenDynamicTests.cs (2)
594Assert.Equal(SpecialType.System_Object, container.BaseType().SpecialType); 830Assert.Equal(SpecialType.System_MulticastDelegate, d.BaseType().SpecialType);
CodeGen\CodeGenForEachTests.cs (1)
1389compilation.MakeTypeMissing(SpecialType.System_IDisposable);
CodeGen\CodeGenFunctionPointersTests.cs (27)
102(RefKind.None, IsSpecialType(SpecialType.System_Int32)), 103(RefKind.None, IsSpecialType(SpecialType.System_String))); 146(RefKind.Ref, IsArrayType(IsSpecialType(SpecialType.System_Int32))), 148(RefKind.Ref, IsSpecialType(SpecialType.System_String))); 170(RefKind.Ref, IsArrayType(IsSpecialType(SpecialType.System_Int32))), 172(RefKind.Out, IsSpecialType(SpecialType.System_String))); 200(RefKind.None, IsSpecialType(SpecialType.System_Int32))) 229(RefKind.RefReadOnly, IsSpecialType(SpecialType.System_Boolean)), 230(RefKind.In, IsSpecialType(SpecialType.System_String)), 231(RefKind.In, IsSpecialType(SpecialType.System_Int32))); 565(RefKind.RefReadOnly, IsSpecialType(SpecialType.System_Int32))); 569(RefKind.RefReadOnly, IsSpecialType(SpecialType.System_Int32))); 574(RefKind.Out, IsSpecialType(SpecialType.System_Int32))); 579(RefKind.In, IsSpecialType(SpecialType.System_Int32))); 584(RefKind.Out, IsSpecialType(SpecialType.System_Int32))); 589(RefKind.In, IsSpecialType(SpecialType.System_Int32))); 652(RefKind.RefReadOnly, IsSpecialType(SpecialType.System_String))))); 657(RefKind.None, IsSpecialType(SpecialType.System_Int32)))), 690(RefKind.RefReadOnly, IsSpecialType(SpecialType.System_Boolean)), 691(RefKind.In, IsSpecialType(SpecialType.System_Int32))); 746(RefKind.Ref, IsSpecialType(SpecialType.System_Boolean)), 747(RefKind.Ref, IsSpecialType(SpecialType.System_Int32))); 791(RefKind.None, IsSpecialType(SpecialType.System_String)))); 794(RefKind.None, IsSpecialType(SpecialType.System_Int32)))); 870Assert.Equal(SpecialType.System_Object, returnTypeWithAnnotations.CustomModifiers[0].Modifier.SpecialType); 7656var @string = comp1.GetSpecialType(SpecialType.System_String); 7741var @string = comp2.GetSpecialType(SpecialType.System_String);
CodeGen\CodeGenTupleTest.cs (99)
498t => Assert.Equal(SpecialType.System_Int32, t.SpecialType)); 512t => Assert.Equal(SpecialType.System_Int32, t.SpecialType)); 524t => Assert.Equal(SpecialType.System_Int32, t.SpecialType)); 536t => Assert.Equal(SpecialType.System_Int32, t.SpecialType)); 699t => Assert.Equal(SpecialType.System_Int32, t.SpecialType)); 715t => Assert.Equal(SpecialType.System_Int32, t.SpecialType)); 1015Assert.Equal(SpecialType.System_Int32, t.SpecialType)); 5784TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 5821TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 5822TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 5848TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 5865TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 5866TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 5900var intType = comp.GetSpecialType(SpecialType.System_Int32); 5901var stringType = comp.GetSpecialType(SpecialType.System_String); 5942TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 5943TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 5963TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 5964TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 5982TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 5983TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6001TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6019TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6020TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6045TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6046TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6071TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6072TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6096TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6097TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6121TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6122TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6147TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6148TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6181TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6205ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6265NamedTypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6287NamedTypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6334TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6359TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6360TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6378var intType = comp.GetSpecialType(SpecialType.System_Int32); 6379var stringType = comp.GetSpecialType(SpecialType.System_String); 6407TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6408TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6423TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6424TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6439TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6454TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6455TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6474TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6475TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6494TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6495TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6515TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6516TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 6538TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6555TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 6579INamedTypeSymbol intType = comp.GetSpecialType(SpecialType.System_String).GetPublicSymbol(); 6597var intType = comp.GetSpecialType(SpecialType.System_Int32); 6598var stringType = comp.GetSpecialType(SpecialType.System_String); 6929NamedTypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 18849TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 18850TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 18867ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 18868ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 18887ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 18888ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 18910TypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 18911TypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 18912TypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 18927ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 18928ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 18929ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 18953ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 18954ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 18955ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 18978ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 18979ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 18980ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 19003ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 19004ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 19005ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 19029ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 19030ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 19031ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 19071ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 19072ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 19073ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 19110ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 19111ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 19112ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 19149ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 19150ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 19151ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 19188ITypeSymbol intType = comp.GetSpecialType(SpecialType.System_Int32); 19189ITypeSymbol stringType = comp.GetSpecialType(SpecialType.System_String); 19190ITypeSymbol objectType = comp.GetSpecialType(SpecialType.System_Object); 29026var @object = comp.GetSpecialType(SpecialType.System_Object);
CodeGen\DestructorTests.cs (2)
601Assert.Equal(SpecialType.System_Int32, intType.SpecialType); 834Assert.Equal(SpecialType.System_Void, destructor.ReturnType.SpecialType);
CodeGen\IndexAndRangeTests.cs (1)
1002Assert.Equal(SpecialType.System_Int32, property.Parameters[0].Type.SpecialType);
Emit\CompilationEmitTests.cs (1)
5044comp.GetSpecialType(SpecialType.System_Int32);
Emit\EditAndContinue\EditAndContinueTests.cs (18)
3613Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.get_P").FirstOrDefault(m => m.GetTypeOrReturnType().SpecialType == SpecialType.System_String)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 3614Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.set_P").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_String)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 3615Edit(SemanticEditKind.Insert, symbolProvider: c => c.GetMembers("C.P").FirstOrDefault(m => m.GetTypeOrReturnType().SpecialType == SpecialType.System_Int32)?.ISymbol), 3708Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.get_P").FirstOrDefault(m => m.GetTypeOrReturnType().SpecialType == SpecialType.System_Int32)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 3709Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.set_P").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Int32)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 3710Edit(SemanticEditKind.Insert, symbolProvider: c => c.GetMembers("C.P").FirstOrDefault(m => m.GetTypeOrReturnType().SpecialType == SpecialType.System_String)?.ISymbol), 4080Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.get_Item").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Int32)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 4081Edit(SemanticEditKind.Insert, symbolProvider: c => c.GetMembers("C.this[]").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_String)?.ISymbol), 4147Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.get_Item").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_String)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 4148Edit(SemanticEditKind.Insert, symbolProvider: c => c.GetMembers("C.this[]").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Int32)?.ISymbol), 15613Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.M").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Int32)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 15614Edit(SemanticEditKind.Insert, symbolProvider: c => c.GetMembers("C.M").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Boolean)?.ISymbol), 15668Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.M").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Boolean)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 15669Edit(SemanticEditKind.Insert, symbolProvider: c => c.GetMembers("C.M").FirstOrDefault(m => m.GetParameterTypes()[0].SpecialType == SpecialType.System_Int32)?.ISymbol), 15740Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.M").FirstOrDefault(m => m.GetTypeOrReturnType().SpecialType == SpecialType.System_String)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 15741Edit(SemanticEditKind.Insert, symbolProvider: c => c.GetMembers("C.M").FirstOrDefault(m => m.GetTypeOrReturnType().SpecialType == SpecialType.System_Int32)?.ISymbol), 15798Edit(SemanticEditKind.Delete, symbolProvider: c => c.GetMembers("C.M").FirstOrDefault(m => m.GetTypeOrReturnType().SpecialType == SpecialType.System_Int32)?.ISymbol, newSymbolProvider: c=>c.GetMember("C")), 15799Edit(SemanticEditKind.Insert, symbolProvider: c => c.GetMembers("C.M").FirstOrDefault(m => m.GetTypeOrReturnType().SpecialType == SpecialType.System_String)?.ISymbol),
Emit\EmitMetadataTests.cs (35)
449Assert.Same(module.GetCorLibType(SpecialType.System_Array), parameter1Type); 450Assert.Same(module.GetCorLibType(SpecialType.System_Boolean), m2.Parameters.Single().Type); 451Assert.Same(module.GetCorLibType(SpecialType.System_Char), m3.Parameters.Single().Type); 455Assert.Same(module.GetCorLibType(SpecialType.System_Void), m4.ReturnType); 456Assert.Same(module.GetCorLibType(SpecialType.System_SByte), method4ParamTypes[0]); 457Assert.Same(module.GetCorLibType(SpecialType.System_Single), method4ParamTypes[1]); 458Assert.Same(module.GetCorLibType(SpecialType.System_Double), method4ParamTypes[2]); 459Assert.Same(module.GetCorLibType(SpecialType.System_Int16), method4ParamTypes[3]); 460Assert.Same(module.GetCorLibType(SpecialType.System_Int32), method4ParamTypes[4]); 461Assert.Same(module.GetCorLibType(SpecialType.System_Int64), method4ParamTypes[5]); 462Assert.Same(module.GetCorLibType(SpecialType.System_IntPtr), method4ParamTypes[6]); 463Assert.Same(module.GetCorLibType(SpecialType.System_String), method4ParamTypes[7]); 464Assert.Same(module.GetCorLibType(SpecialType.System_Byte), method4ParamTypes[8]); 465Assert.Same(module.GetCorLibType(SpecialType.System_UInt16), method4ParamTypes[9]); 466Assert.Same(module.GetCorLibType(SpecialType.System_UInt32), method4ParamTypes[10]); 467Assert.Same(module.GetCorLibType(SpecialType.System_UInt64), method4ParamTypes[11]); 468Assert.Same(module.GetCorLibType(SpecialType.System_UIntPtr), method4ParamTypes[12]); 666CheckConstantField(type, "I", Accessibility.Private, SpecialType.System_Int32, -1); 668CheckConstantField(type, "J", Accessibility.Internal, SpecialType.System_Int32, -1); 669CheckConstantField(type, "O", Accessibility.ProtectedOrInternal, SpecialType.System_Object, null); 670CheckConstantField(type, "S", Accessibility.Public, SpecialType.System_String, "string"); 676private void CheckConstantField(NamedTypeSymbol type, string name, Accessibility declaredAccessibility, SpecialType fieldType, object value) 950Assert.Equal(SpecialType.System_Int32, pBack.Type.SpecialType); 956Assert.Equal(SpecialType.System_String, qBack.Type.SpecialType); 962Assert.Equal(SpecialType.System_Decimal, rBack.Type.SpecialType); 968Assert.Equal(SpecialType.System_Char, sBack.Type.SpecialType); 1021Assert.Equal(SpecialType.System_Int32, p.Type.SpecialType); 1027Assert.Equal(SpecialType.System_String, qBack.Type.SpecialType); 1033Assert.Equal(SpecialType.System_Decimal, rBack.Type.SpecialType); 1039Assert.Equal(SpecialType.System_Char, sBack.Type.SpecialType); 1280Assert.Equal(SpecialType.System_String, p.Type.SpecialType); 1331CheckEnumType(type, Accessibility.Internal, SpecialType.System_Int32); 1355CheckEnumType(type, Accessibility.Internal, SpecialType.System_Int16); 1389private void CheckEnumType(NamedTypeSymbol type, Accessibility declaredAccessibility, SpecialType underlyingType) 1391Assert.Equal(SpecialType.System_Enum, type.BaseType().SpecialType);
Emit\NoPiaEmbedTypes.cs (4)
1198Assert.Equal(SpecialType.System_ValueType, test2.BaseType().SpecialType); 1266Assert.Equal(SpecialType.System_Int32, test9.EnumUnderlyingType.SpecialType); 1339Assert.Equal(SpecialType.System_MulticastDelegate, test11.BaseType().SpecialType); 1480Assert.Equal(SpecialType.System_Void, paramInfo[0].Type.SpecialType);
PDB\PDBTests.cs (1)
621var stInt = c1.GetSpecialType(SpecialType.System_Int32);
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (18)
Attributes\AttributeTests.cs (1)
5219NamedTypeSymbol classYOfInt = classY.ConstructIfGeneric(ImmutableArray.Create(TypeWithAnnotations.Create(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32))));
Attributes\AttributeTests_Synthesized.cs (2)
648var c1OfInt = comp.GetTypeByMetadataName("C1`1").Construct(comp.GetSpecialType(SpecialType.System_Int32)); 1970new TypedConstant(comp.GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, "unused"))));
Attributes\AttributeTests_Tuples.cs (2)
354Assert.Equal(SpecialType.System_Object, sender.Type.SpecialType); 647Assert.True(constant.Type.SpecialType == SpecialType.System_String);
Emit\NumericIntPtrTests.cs (6)
1566return type.SpecialType == (signed ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr); 10322Assert.Same(nintType, comp.GetSpecialType(SpecialType.System_IntPtr)); 10335Assert.Same(nuintType, comp.GetSpecialType(SpecialType.System_UIntPtr)); 10345Assert.Equal(SpecialType.System_IntPtr, type.SpecialType); 10354Assert.Equal(SpecialType.System_UIntPtr, type.SpecialType);
Semantics\PatternMatchingTests.cs (2)
11366Assert.Equal(SpecialType.System_String, typeInfo.Type.SpecialType); 11367Assert.Equal(SpecialType.System_String, typeInfo.ConvertedType.SpecialType);
Semantics\PatternMatchingTests2.cs (3)
2032Assert.Equal(SpecialType.System_Boolean, typeInfo.Type.SpecialType); 2073Assert.Equal(SpecialType.System_Boolean, typeInfo.Type.SpecialType); 3288comp.MakeTypeMissing(SpecialType.System_Int32);
Semantics\PatternSwitchTests.cs (2)
3286Assert.Equal(SpecialType.System_Boolean, type.Type.SpecialType); 3287Assert.Equal(SpecialType.System_Boolean, type.ConvertedType.SpecialType);
Microsoft.CodeAnalysis.CSharp.ExpressionEvaluator.ExpressionCompiler (15)
Binders\PlaceholderLocalBinder.cs (1)
86var local = new ObjectAddressLocalSymbol(_containingMethod, name, this.Compilation.GetSpecialType(SpecialType.System_Object), address);
CompilationContext.cs (6)
201var objectType = Compilation.GetSpecialType(SpecialType.System_Object); 240var objectType = Compilation.GetSpecialType(SpecialType.System_Object); 307var objectType = Compilation.GetSpecialType(SpecialType.System_Object); 717binder.Compilation.GetSpecialType(SpecialType.System_Object)); 724else if (expressionType.SpecialType == SpecialType.System_Void) 731else if (expressionType.SpecialType == SpecialType.System_Boolean)
Rewriters\LocalDeclarationRewriter.cs (3)
107var stringType = compilation.GetSpecialType(SpecialType.System_String); 140TypeWithAnnotations.Create(compilation.GetSpecialType(SpecialType.System_Byte))); 150var intType = compilation.GetSpecialType(SpecialType.System_Int32);
Symbols\EEMethodSymbol.cs (3)
316get { return this.ReturnType.SpecialType == SpecialType.System_Void; } 734return compilation.GetSpecialType(SpecialType.System_Void); 744return compilation.GetSpecialType(SpecialType.System_Void);
Symbols\ObjectAddressLocalSymbol.cs (1)
21Debug.Assert(type.SpecialType == SpecialType.System_Object);
Symbols\PlaceholderLocalSymbol.cs (1)
160var intPtrType = compilation.GetSpecialType(SpecialType.System_IntPtr);
Microsoft.CodeAnalysis.CSharp.ExpressionEvaluator.ExpressionCompiler.UnitTests (10)
ExpressionCompilerTests.cs (4)
1402Assert.Equal(SpecialType.System_Object, method.ReturnType.SpecialType); 1668Assert.Equal(SpecialType.System_Void, method.ReturnType.SpecialType); 1714Assert.Equal(SpecialType.System_Object, method.ReturnType.SpecialType); 4712Assert.Equal(SpecialType.System_Int32, ((MethodSymbol)methodData.Method).ReturnType.SpecialType);
LocalsTests.cs (2)
2769Assert.Equal(SpecialType.System_Int32, ((MethodSymbol)testData.GetMethodData(typeName + ".<>m0").Method).ReturnType.SpecialType); 2778Assert.Equal(SpecialType.System_Int32, ((MethodSymbol)methodData.Method).ReturnType.SpecialType);
ManagedAddressOfTests.cs (1)
308Assert.Equal(SpecialType.System_String, ((PointerTypeSymbol)returnType).PointedAtType.SpecialType);
PseudoVariableTests.cs (2)
1121Assert.Equal(SpecialType.System_Int32, ((PointerTypeSymbol)((MethodSymbol)methodData.Method).ReturnType).PointedAtType.SpecialType); 1161Assert.Equal(SpecialType.System_Char, ((PointerTypeSymbol)((MethodSymbol)methodData.Method).ReturnType).PointedAtType.SpecialType);
UsingDebugInfoTests.cs (1)
850Assert.Equal(SpecialType.System_Int32, ((NamedTypeSymbol)typeSymbol).SpecialType);
Microsoft.CodeAnalysis.CSharp.Features (97)
CodeRefactorings\UseRecursivePatterns\UseRecursivePatternsCodeRefactoringProvider.cs (1)
465ContainingType: not { SpecialType: SpecialType.System_Nullable_T }
Completion\CompletionProviders\DeclarationName\DeclarationNameRecommender.cs (3)
96if (type.SpecialType == SpecialType.System_Void) 145t => t.OriginalDefinition.SpecialType == SpecialType.System_Collections_Generic_IEnumerable_T || 169originalDefinition.SpecialType == SpecialType.System_Nullable_T)
Completion\CompletionProviders\EnumAndCompletionListTagCompletionProvider.cs (1)
114if (type.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T)
Completion\CompletionProviders\ObjectCreationCompletionProvider.cs (1)
131if (namedTypeSymbol?.SpecialType == SpecialType.System_Object)
Completion\KeywordRecommenders\AbstractSpecialTypePreselectingKeywordRecommender.cs (1)
24protected abstract SpecialType SpecialType { get; }
Completion\KeywordRecommenders\BoolKeywordRecommender.cs (2)
54protected override SpecialType SpecialType => SpecialType.System_Boolean;
Completion\KeywordRecommenders\ByteKeywordRecommender.cs (2)
55protected override SpecialType SpecialType => SpecialType.System_Byte;
Completion\KeywordRecommenders\CharKeywordRecommender.cs (2)
54protected override SpecialType SpecialType => SpecialType.System_Char;
Completion\KeywordRecommenders\DecimalKeywordRecommender.cs (2)
54protected override SpecialType SpecialType => SpecialType.System_Decimal;
Completion\KeywordRecommenders\DoubleKeywordRecommender.cs (2)
54protected override SpecialType SpecialType => SpecialType.System_Double;
Completion\KeywordRecommenders\FloatKeywordRecommender.cs (2)
54protected override SpecialType SpecialType => SpecialType.System_Single;
Completion\KeywordRecommenders\IntKeywordRecommender.cs (2)
55protected override SpecialType SpecialType => SpecialType.System_Int32;
Completion\KeywordRecommenders\LongKeywordRecommender.cs (2)
55protected override SpecialType SpecialType => SpecialType.System_Int64;
Completion\KeywordRecommenders\ObjectKeywordRecommender.cs (2)
53protected override SpecialType SpecialType => SpecialType.System_Object;
Completion\KeywordRecommenders\SByteKeywordRecommender.cs (2)
55protected override SpecialType SpecialType => SpecialType.System_SByte;
Completion\KeywordRecommenders\ShortKeywordRecommender.cs (2)
55protected override SpecialType SpecialType => SpecialType.System_Int16;
Completion\KeywordRecommenders\StringKeywordRecommender.cs (2)
23protected override SpecialType SpecialType => SpecialType.System_String;
Completion\KeywordRecommenders\UIntKeywordRecommender.cs (2)
55protected override SpecialType SpecialType => SpecialType.System_UInt32;
Completion\KeywordRecommenders\ULongKeywordRecommender.cs (2)
55protected override SpecialType SpecialType => SpecialType.System_UInt64;
Completion\KeywordRecommenders\UShortKeywordRecommender.cs (2)
62protected override SpecialType SpecialType => SpecialType.System_UInt16;
Completion\Providers\DefaultArgumentProvider.cs (13)
39SpecialType.System_Boolean => "false", 40SpecialType.System_Char => @"'\\0'", 41SpecialType.System_Byte => "(byte)0", 42SpecialType.System_SByte => "(sbyte)0", 43SpecialType.System_Int16 => "(short)0", 44SpecialType.System_UInt16 => "(ushort)0", 45SpecialType.System_Int32 => "0", 46SpecialType.System_UInt32 => "0U", 47SpecialType.System_Int64 => "0L", 48SpecialType.System_UInt64 => "0UL", 49SpecialType.System_Decimal => "0.0m", 50SpecialType.System_Single => "0.0f", 51SpecialType.System_Double => "0.0",
ConvertForEachToFor\CSharpConvertForEachToForCodeRefactoringProvider.cs (2)
69model.Compilation.GetSpecialType(SpecialType.System_Object); 89model.Compilation.GetSpecialType(SpecialType.System_Int32).GenerateTypeSyntax(),
ConvertLinq\CSharpConvertLinqQueryToForEachProvider.cs (5)
310methodSymbol.ReturnType?.SpecialType == SpecialType.System_Int32 && 375=> typeSymbol.SpecialType == SpecialType.System_Int32; 562if (returnTypeInfo.Type.OriginalDefinition?.SpecialType == SpecialType.System_Collections_Generic_IEnumerable_T) 568if (returnTypeInfo.ConvertedType.OriginalDefinition?.SpecialType == SpecialType.System_Collections_Generic_IEnumerable_T) 755if (methodSymbol.ReturnType.OriginalDefinition?.SpecialType != SpecialType.System_Collections_Generic_IEnumerable_T)
ConvertProgramAnalysis_TopLevelStatements.cs (1)
94if (containingType.BaseType?.SpecialType != SpecialType.System_Object)
ConvertToRecordHelpers.cs (4)
29methodSymbol.ReturnType.SpecialType == SpecialType.System_Boolean && 37methodSymbol.Parameters.First().Type.SpecialType == SpecialType.System_Object && 516else if (parameter.Type.SpecialType == SpecialType.System_Object) 1107var objectType = compilation.GetSpecialType(SpecialType.System_Object);
CSharpAsAndNullCheckDiagnosticAnalyzer.cs (1)
86if (castType?.SpecialType == SpecialType.System_Object)
CSharpFixIncorrectConstraintCodeFixProvider.cs (2)
95isEnumConstraint ? SpecialType.System_Enum : SpecialType.System_Delegate));
CSharpFixReturnTypeCodeFixProvider.cs (1)
107if (previousReturnType.SpecialType is SpecialType.System_Void ||
CSharpMakeStructMemberReadOnlyAnalyzer.cs (2)
253if (methodReference.ContainingType.SpecialType is SpecialType.System_Object or SpecialType.System_ValueType)
CSharpRemoveUnnecessaryLambdaExpressionDiagnosticAnalyzer.cs (1)
127if (lambdaTypeInfo.ConvertedType == null || lambdaTypeInfo.ConvertedType.SpecialType is SpecialType.System_Object)
CSharpReplaceDefaultLiteralCodeFixProvider.cs (2)
101else if (type.SpecialType is SpecialType.System_IntPtr or SpecialType.System_UIntPtr)
CSharpUseCompoundCoalesceAssignmentDiagnosticAnalyzer.cs (2)
197if (symbol is null || !symbol.IsUserDefinedOperator() || symbol.ContainingType.SpecialType == SpecialType.System_String) 215symbol.ContainingType?.SpecialType == SpecialType.System_Object)
CSharpUseIndexOperatorDiagnosticAnalyzer.cs (1)
84var arrayType = compilation.GetSpecialType(SpecialType.System_Array);
CSharpUseIsNullCheckForCastAndEqualityOperatorDiagnosticAnalyzer.cs (1)
77if (semanticModel.GetTypeInfo(castExpression.Type).Type?.SpecialType == SpecialType.System_Object)
CSharpUseRangeOperatorDiagnosticAnalyzer.InfoCache.cs (1)
64var stringType = compilation.GetSpecialType(SpecialType.System_String);
ExtractMethod\CSharpMethodExtractor.Analyzer.cs (1)
101return info.Type == null || info.Type.SpecialType == Microsoft.CodeAnalysis.SpecialType.System_Object
ExtractMethod\CSharpMethodExtractor.cs (1)
177if (type.SpecialType == SpecialType.System_Void)
ExtractMethod\CSharpMethodExtractor.CSharpCodeGenerator.cs (1)
637} && parameters[0].Type.SpecialType == SpecialType.System_Boolean))
ExtractMethod\CSharpSelectionResult.ExpressionResult.cs (1)
122if (info.Type?.SpecialType == SpecialType.System_String &&
ExtractMethod\Extensions.cs (1)
264=> type == null || type.SpecialType == SpecialType.System_Object;
GenerateMember\GenerateParameterizedMember\CSharpGenerateDeconstructMethodService.cs (1)
59type: semanticModel.GetTypeInfo(((ConstantPatternSyntax)positionalPattern.Subpatterns[i].Pattern).Expression, cancellationToken).Type ?? semanticModel.Compilation.GetSpecialType(SpecialType.System_Object),
IntroduceVariable\CSharpIntroduceLocalForExpressionCodeRefactoringProvider.cs (1)
144var isIntrinsic = tupleType.TupleElements.All(f => f.Type?.SpecialType != SpecialType.None);
J\s\src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\Helpers.cs\Helpers.cs (4)
30p.Type.SpecialType == SpecialType.System_Int32) 77method.OriginalDefinition.Parameters[0].Type.SpecialType == SpecialType.System_Int32; 115=> parameter.Type.SpecialType == SpecialType.System_Int32 && 119=> parameter.Type.SpecialType == SpecialType.System_Int32 &&
ReverseForStatement\CSharpReverseForStatementCodeRefactoringProvider.cs (4)
95SpecialType.System_Byte => IsUnsignedBoundary(startValue, endValue, byte.MaxValue), 96SpecialType.System_UInt16 => IsUnsignedBoundary(startValue, endValue, ushort.MaxValue), 97SpecialType.System_UInt32 => IsUnsignedBoundary(startValue, endValue, uint.MaxValue), 98SpecialType.System_UInt64 => IsUnsignedBoundary(startValue, endValue, ulong.MaxValue),
SignatureHelp\ElementAccessExpressionSignatureHelpProvider.cs (1)
65if (namedType.ConstructedFrom.SpecialType == SpecialType.System_Nullable_T &&
Snippets\AbstractCSharpAutoPropertySnippetProvider.cs (1)
66type: compilation.GetSpecialType(SpecialType.System_Int32).GenerateTypeSyntax(allowVar: false),
Snippets\CSharpForEachLoopSnippetProvider.cs (2)
44namedSymbol => namedSymbol.SpecialType is SpecialType.System_Collections_Generic_IEnumerable_T or SpecialType.System_Collections_IEnumerable) &&
UseUtf8StringLiteralCodeFixProvider.cs (1)
70namedType.TypeArguments[0].SpecialType == SpecialType.System_Byte;
UseUtf8StringLiteralDiagnosticAnalyzer.cs (1)
78if (arrayCreationOperation.Type is not IArrayTypeSymbol { ElementType.SpecialType: SpecialType.System_Byte })
Microsoft.CodeAnalysis.CSharp.IOperation.UnitTests (3)
IOperation\FunctionPointerOperations.cs (2)
210Assert.Equal(SpecialType.System_String, signature.Parameters[0].Type.SpecialType); 211Assert.Equal(SpecialType.System_Void, signature.ReturnType.SpecialType);
IOperation\IOperationTests_ICompoundAssignmentOperation.cs (1)
86var inSymbol = implicitSymbols.Where(sym => sym.ReturnType.SpecialType == SpecialType.System_Int32).Single();
Microsoft.CodeAnalysis.CSharp.Scripting (16)
Hosting\ObjectFormatter\CSharpTypeNameFormatter.cs (16)
27protected override string GetPrimitiveTypeName(SpecialType type) 31case SpecialType.System_Boolean: return "bool"; 32case SpecialType.System_Byte: return "byte"; 33case SpecialType.System_Char: return "char"; 34case SpecialType.System_Decimal: return "decimal"; 35case SpecialType.System_Double: return "double"; 36case SpecialType.System_Int16: return "short"; 37case SpecialType.System_Int32: return "int"; 38case SpecialType.System_Int64: return "long"; 39case SpecialType.System_SByte: return "sbyte"; 40case SpecialType.System_Single: return "float"; 41case SpecialType.System_String: return "string"; 42case SpecialType.System_UInt16: return "ushort"; 43case SpecialType.System_UInt32: return "uint"; 44case SpecialType.System_UInt64: return "ulong"; 45case SpecialType.System_Object: return "object";
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (349)
Semantics\ConditionalOperatorTests.cs (1)
1276Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(conditionalExpr.Condition).Type!.SpecialType);
Semantics\DeconstructionTests.cs (10)
5991Assert.Equal(SpecialType.System_Void, type.Type.SpecialType); 5992Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType); 6034Assert.Equal(SpecialType.System_Void, type.Type.SpecialType); 6035Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType); 6074Assert.Equal(SpecialType.System_Void, type.Type.SpecialType); 6075Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType); 6116Assert.Equal(SpecialType.System_Int32, type.Type.SpecialType); 6117Assert.Equal(SpecialType.System_Int32, type.ConvertedType.SpecialType); 6156Assert.Equal(SpecialType.System_Void, type.Type.SpecialType); 6157Assert.Equal(SpecialType.System_Void, type.ConvertedType.SpecialType);
Semantics\DelegateTypeTests.cs (14)
752Assert.Equal(SpecialType.System_Delegate, typeInfo.ConvertedType!.SpecialType); 898Assert.Equal(SpecialType.System_Delegate, typeInfo.ConvertedType!.SpecialType); 1222Assert.Equal(SpecialType.System_Delegate, typeInfo.ConvertedType!.SpecialType); 1317Assert.Equal(SpecialType.System_Delegate, typeInfo.ConvertedType!.SpecialType); 1412Assert.Equal(SpecialType.System_Delegate, typeInfo.ConvertedType!.SpecialType); 1830Assert.Equal(SpecialType.System_Delegate, typeInfo.ConvertedType!.SpecialType); 5316Assert.Equal(SpecialType.System_Delegate, typeInfo.ConvertedType!.SpecialType); 5339Assert.Equal(SpecialType.System_Delegate, typeInfo.ConvertedType!.SpecialType); 11043var expectedBaseType = ((CSharpCompilation)model.Compilation).GetSpecialType(SpecialType.System_MulticastDelegate); 11443verifyConversions(model, expr, comp.GetSpecialType(SpecialType.System_MulticastDelegate).GetPublicSymbol(), ConversionKind.FunctionType, ConversionKind.FunctionType); 11445verifyConversions(model, expr, getFunctionType(funcOfT.Construct(comp.GetSpecialType(SpecialType.System_Int32))), ConversionKind.FunctionType, ConversionKind.FunctionType); 11446verifyConversions(model, expr, getFunctionType(funcOfT.Construct(comp.GetSpecialType(SpecialType.System_Object))), ConversionKind.NoConversion, ConversionKind.NoConversion); 12253var objectType = comp.GetSpecialType(SpecialType.System_Object); 12254var stringType = comp.GetSpecialType(SpecialType.System_String);
Semantics\DynamicTests.cs (5)
49var dynamicToObject = c.Conversions.ClassifyConversionFromType(DynamicTypeSymbol.Instance, c.GetSpecialType(SpecialType.System_Object), ref useSiteDiagnostics); 50var objectToDynamic = c.Conversions.ClassifyConversionFromType(c.GetSpecialType(SpecialType.System_Object), DynamicTypeSymbol.Instance, ref useSiteDiagnostics); 1931var eraser = new DynamicTypeEraser(compilation.GetSpecialType(SpecialType.System_Object)); 1961Assert.Equal(SpecialType.System_Object, ebc.SpecialType); 3847var typeObject = comp.GetSpecialType(SpecialType.System_Object);
Semantics\ExpressionBodiedMemberTests.cs (9)
75Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 76Assert.Equal(SpecialType.System_Int32, semanticInfo.ConvertedType.SpecialType); 139Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 178Assert.Equal(SpecialType.System_String, semanticInfo.Type.SpecialType); 179Assert.Equal(SpecialType.System_Object, semanticInfo.ConvertedType.SpecialType); 226Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 227Assert.Equal(SpecialType.System_Int32, semanticInfo.ConvertedType.SpecialType); 315Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 316Assert.Equal(SpecialType.System_Int32, semanticInfo.ConvertedType.SpecialType);
Semantics\ForEachTests.cs (38)
1207Assert.Equal(SpecialType.System_Int32, info.ElementTypeWithAnnotations.SpecialType); 1219Assert.Equal(SpecialType.System_Collections_IEnumerable, boundNode.Expression.Type.SpecialType); 1244Assert.Equal(SpecialType.System_String, info.CollectionType.SpecialType); 1245Assert.Equal(SpecialType.System_Char, info.ElementTypeWithAnnotations.SpecialType); 1257Assert.Equal(SpecialType.System_String, boundNode.Expression.Type.SpecialType); 1258Assert.Equal(SpecialType.System_String, ((BoundConversion)boundNode.Expression).Operand.Type.SpecialType); 1289Assert.Equal(SpecialType.System_Int32, info.ElementTypeWithAnnotations.SpecialType); 1333Assert.Equal(SpecialType.System_Int32, info.ElementTypeWithAnnotations.SpecialType); 1366Assert.Equal(SpecialType.System_Object, info.ElementTypeWithAnnotations.SpecialType); 1406Assert.Equal(SpecialType.System_Int32, info.ElementTypeWithAnnotations.SpecialType); 1448Assert.Equal(SpecialType.System_Object, info.ElementTypeWithAnnotations.SpecialType); 1460Assert.Equal(SpecialType.System_Collections_IEnumerable, boundNode.Expression.Type.SpecialType); 1487Assert.Equal(SpecialType.System_Object, info.ElementTypeWithAnnotations.SpecialType); 1499Assert.Equal(SpecialType.System_Collections_IEnumerable, boundNode.Expression.Type.SpecialType); 1520Assert.Equal(SpecialType.System_Int32, info.ElementTypeWithAnnotations.SpecialType); 1531Assert.Equal(SpecialType.System_Int32, boundNode.IterationVariables.Single().Type.SpecialType); 1550Assert.Equal(SpecialType.System_String, info.CollectionType.SpecialType); 1551Assert.Equal(SpecialType.System_Char, info.ElementTypeWithAnnotations.SpecialType); 1562Assert.Equal(SpecialType.System_Char, boundNode.IterationVariables.Single().Type.SpecialType); 1591Assert.Equal(SpecialType.System_Int32, boundNode.IterationVariables.Single().Type.SpecialType); 1615Assert.Equal(SpecialType.System_Object, boundNode.IterationVariables.Single().Type.SpecialType); 1667Assert.Equal(SpecialType.System_Collections_IEnumerable, info.CollectionType.SpecialType); 1668Assert.Equal(SpecialType.System_Object, info.ElementTypeWithAnnotations.SpecialType); 1680Assert.Equal(SpecialType.System_Collections_IEnumerable, boundNode.Expression.Type.SpecialType); 1700Assert.Equal(SpecialType.System_Collections_IEnumerable, info.CollectionType.SpecialType); 1713Assert.Equal(SpecialType.System_Collections_IEnumerable, boundNode.Expression.Type.SpecialType); 1742Assert.Equal(SpecialType.System_Object, info.ElementTypeWithAnnotations.SpecialType); 1826Assert.Equal(SpecialType.System_Object, info.ElementTypeWithAnnotations.SpecialType); 1873Assert.Equal(SpecialType.System_Int32, info.ElementTypeWithAnnotations.SpecialType); 2139Assert.Equal(SpecialType.System_Object, loopInfo.CurrentProperty.Type.SpecialType); 2143Assert.Equal(SpecialType.System_Char, typeInfo.Type.SpecialType); 2188Assert.Equal(SpecialType.System_String, loopInfo0.ElementType.SpecialType); 2197Assert.Equal(SpecialType.System_Object, loopInfo1.ElementType.SpecialType); // No longer string. 2889Assert.Equal(SpecialType.System_String, localSymbolType.SpecialType); 3116Assert.Equal(SpecialType.System_String, info.CollectionType.SpecialType); 3117Assert.Equal(SpecialType.System_Char, info.ElementTypeWithAnnotations.SpecialType); 3128Assert.Equal(SpecialType.System_Char, boundNode.IterationVariables.Single().Type.SpecialType); 3235Assert.Equal(SpecialType.System_Int32, info.ElementTypeWithAnnotations.SpecialType);
Semantics\FunctionPointerTests.cs (5)
189Assert.True(typeInfo.ConvertedType is IPointerTypeSymbol { PointedAtType: { SpecialType: SpecialType.System_Void } }); 1597Assert.Equal(SpecialType.System_String, methodSymbol.TypeArguments[0].SpecialType); 1599Assert.Equal(SpecialType.System_String, functionPointer.Signature.Parameters[0].Type.SpecialType); 1757Assert.Equal(SpecialType.System_String, methodSymbol.TypeArguments[0].SpecialType); 1759Assert.Equal(SpecialType.System_String, functionPointer.Signature.ReturnType.SpecialType);
Semantics\GenericConstraintsTests.cs (12)
456Assert.Equal(SpecialType.System_Enum, typeParameter.ConstraintTypes().Single().SpecialType); 475Assert.Equal(SpecialType.System_Enum, typeParameter.ConstraintTypes().Single().SpecialType); 494Assert.Equal(SpecialType.System_Enum, typeParameter.ConstraintTypes().Single().SpecialType); 513Assert.Equal(SpecialType.System_Enum, typeParameter.ConstraintTypes().Single().SpecialType); 980Assert.Equal(SpecialType.System_Delegate, typeParameter.ConstraintTypes().Single().SpecialType); 1015Assert.Equal(SpecialType.System_Delegate, typeParameter.ConstraintTypes().Single().SpecialType); 1032Assert.Equal(SpecialType.System_Delegate, typeParameter.ConstraintTypes().Single().SpecialType); 1465Assert.Equal(SpecialType.System_MulticastDelegate, typeParameter.ConstraintTypes().Single().SpecialType); 1500Assert.Equal(SpecialType.System_MulticastDelegate, typeParameter.ConstraintTypes().Single().SpecialType); 1517Assert.Equal(SpecialType.System_MulticastDelegate, typeParameter.ConstraintTypes().Single().SpecialType); 3175Assert.Equal(SpecialType.System_Int32, inferredMethod.TypeArguments.Single().SpecialType); 3230Assert.Equal(SpecialType.System_Int32, inferredMethod.TypeArguments.Single().SpecialType);
Semantics\ImplicitlyTypedLocalsTests.cs (1)
46Assert.Equal(SpecialType.System_Int32, fieldA.Type.SpecialType);
Semantics\InteractiveSemanticModelTests.cs (3)
126Assert.Equal(SpecialType.System_Int32, bindInfo.Type.SpecialType); 141Assert.Equal(SpecialType.System_Int32, bindInfo.Type.SpecialType); 268Assert.Equal(SpecialType.System_Char, semanticInfo.Type.SpecialType);
Semantics\InteractiveUsingTests.cs (5)
26Assert.Equal(SpecialType.System_String, GetSpeculativeType(sub, "String").SpecialType); 35Assert.Equal(SpecialType.System_Int32, GetSpeculativeType(sub, "I").SpecialType); 187Assert.Equal(SpecialType.System_Int32, GetSpeculativeType(sub1, "A").SpecialType); 190Assert.Equal(SpecialType.System_Int16, GetSpeculativeType(sub2, "A").SpecialType); 196Assert.Equal(SpecialType.System_Int64, GetSpeculativeType(sub4, "A").SpecialType);
Semantics\InterpolationTests.cs (6)
4402comp.MakeTypeMissing(SpecialType.System_Boolean); 4428comp.MakeTypeMissing(SpecialType.System_Void); 4580Assert.Equal(SpecialType.System_String, semanticInfo.Type.SpecialType); 4801Assert.Equal(SpecialType.System_Object, semanticInfo.ConvertedType.SpecialType); 4807Assert.Equal(SpecialType.System_String, semanticInfo.Type.SpecialType); 4808Assert.Equal(SpecialType.System_String, semanticInfo.ConvertedType.SpecialType);
Semantics\LocalFunctionTests.cs (7)
458Assert.Equal(SpecialType.System_Int32, argType0.SpecialType); 464Assert.Equal(SpecialType.System_String, argType1.SpecialType); 620Assert.Equal(SpecialType.System_String, model.GetTypeInfo(arg1.Expression).Type.SpecialType); 624Assert.Equal(SpecialType.System_String, model.GetTypeInfo(arg2.Expression).Type.SpecialType); 628Assert.Equal(SpecialType.System_String, model.GetTypeInfo(arg3.Expression).Type.SpecialType); 673Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(arg.Expression).Type.SpecialType); 727Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(arg.Expression).Type.SpecialType);
Semantics\LockTests.cs (3)
48Assert.Equal(SpecialType.System_Object, localSymbol.Type.SpecialType); 666var symbol = compilation.GetSpecialType(SpecialType.System_String); 687var symbol = compilation.GetSpecialType(SpecialType.System_String);
Semantics\LookupTests.cs (1)
2009var m = ms.Where(mm => mm.Parameters[0].Type.SpecialType == SpecialType.System_Int32).Single();
Semantics\MethodTypeInferenceTests.cs (2)
1049Assert.Equal(SpecialType.System_Char, method.TypeArguments.Single().SpecialType); 1079Assert.Equal(SpecialType.System_Char, method.TypeArguments.Single().SpecialType);
Semantics\NativeIntegerTests.cs (36)
222Assert.Equal(signed ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr, type.SpecialType); 237Assert.Equal(signed ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr, type.SpecialType); 545var specialType = signed ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr; 724private static void VerifyErrorType(NamedTypeSymbol type, SpecialType specialType, bool isNativeInt) 732private static void VerifyErrorType(INamedTypeSymbol type, SpecialType specialType, bool isNativeInt) 742var specialType = signed ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr; 744VerifyErrorType(underlyingType, SpecialType.None, isNativeInt: false); 756var specialType = signed ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr; 758VerifyErrorType(underlyingType, SpecialType.None, isNativeInt: false); 1539verifyInterfaces(comp, (NamedTypeSymbol)comp.GetMember<MethodSymbol>("I.F1").ReturnType, SpecialType.System_IntPtr, includesIEquatable); 1540verifyInterfaces(comp, (NamedTypeSymbol)comp.GetMember<MethodSymbol>("I.F2").ReturnType, SpecialType.System_UIntPtr, includesIEquatable); 1543static void verifyInterfaces(CSharpCompilation comp, NamedTypeSymbol type, SpecialType specialType, bool includesIEquatable) 1660VerifyErrorType(comp.CreateNativeIntegerTypeSymbol(signed: true), SpecialType.System_IntPtr, isNativeInt: true); 1661VerifyErrorType(comp.CreateNativeIntegerTypeSymbol(signed: false), SpecialType.System_UIntPtr, isNativeInt: true); 1662VerifyErrorType(((Compilation)comp).CreateNativeIntegerTypeSymbol(signed: true), SpecialType.System_IntPtr, isNativeInt: true); 1663VerifyErrorType(((Compilation)comp).CreateNativeIntegerTypeSymbol(signed: false), SpecialType.System_UIntPtr, isNativeInt: true); 3638Assert.Equal(SpecialType.None, underlyingType.SpecialType); 3643Assert.Equal(SpecialType.None, underlyingType0.SpecialType); 3645Assert.Equal(SpecialType.System_UIntPtr, underlyingType1.SpecialType); 3685Assert.Equal(SpecialType.System_Int16, underlyingType0.SpecialType); 3687Assert.Equal(SpecialType.System_Object, underlyingType1.SpecialType); 3719Assert.Equal(SpecialType.System_Int16, underlyingType0.SpecialType); 3721Assert.Equal(SpecialType.System_UIntPtr, underlyingType1.SpecialType); 3753Assert.Equal(SpecialType.System_Int16, underlyingType0.SpecialType); 3755Assert.Equal(SpecialType.System_UIntPtr, underlyingType1.SpecialType); 4124Assert.Equal(SpecialType.None, type.SpecialType); 4816type.SpecialType == (signed ? SpecialType.System_IntPtr : SpecialType.System_UIntPtr);
Semantics\NullableConversionTests.cs (2)
812var nullableIntType = compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(compilation.GetSpecialType(SpecialType.System_Int32));
Semantics\NullableReferenceTypesTests.cs (1)
112149var modifiers = ImmutableArray.Create(CSharpCustomModifier.CreateOptional(comp.GetSpecialType(SpecialType.System_Object)));
Semantics\NullCoalesceAssignmentTests.cs (3)
160var int32 = comp.GetSpecialType(SpecialType.System_Int32); 186Assert.Equal(SpecialType.System_Int32, semanticModel.GetTypeInfo(defaultLiteral).Type.SpecialType); 187Assert.Equal(SpecialType.System_Int32, semanticModel.GetTypeInfo(defaultLiteral).ConvertedType.SpecialType);
Semantics\ObjectAndCollectionInitializerTests.cs (3)
4009Assert.Equal(SpecialType.System_Int32, typeInfo.Type.SpecialType); 4010Assert.Equal(SpecialType.System_Int32, typeInfo.ConvertedType.SpecialType); 4081Assert.Equal(SpecialType.System_Int32, typeInfo.Type.SpecialType);
Semantics\OperatorTests.cs (28)
7060Assert.Equal(comp.GetSpecialType(SpecialType.System_Boolean), info.ConvertedType.GetSymbol()); 7215Assert.Equal(comp.GetSpecialType(SpecialType.System_Boolean).GetPublicSymbol(), info.ConvertedType); 7498type = compilation.CreatePointerTypeSymbol(compilation.GetSpecialType(SpecialType.System_Byte)); 7638symbol1.ContainingType.SpecialType == SpecialType.System_Char); 7867types[types.Length - 2] = compilation.CreatePointerTypeSymbol(compilation.GetSpecialType(SpecialType.System_Byte)); 7870types[types.Length - 1] = compilation.CreatePointerTypeSymbol(compilation.GetSpecialType(SpecialType.System_SByte)); 8027types[types.Length - 2] = compilation.CreatePointerTypeSymbol(compilation.GetSpecialType(SpecialType.System_Byte)); 8030types[types.Length - 1] = compilation.CreatePointerTypeSymbol(compilation.GetSpecialType(SpecialType.System_SByte)); 8177compilation.GetSpecialType(SpecialType.System_Boolean)); 8179else if (leftType.SpecialType == SpecialType.System_Delegate && rightType.SpecialType == SpecialType.System_Delegate) 8182compilation.GetSpecialType(SpecialType.System_Delegate), compilation.GetSpecialType(SpecialType.System_Delegate), 8183compilation.GetSpecialType(SpecialType.System_Boolean)); 8188compilation.GetSpecialType(SpecialType.System_Boolean)); 8229signature = new BinaryOperatorSignature(op | BinaryOperatorKind.Pointer, leftType, rightType, compilation.GetSpecialType(SpecialType.System_Int64)); 8258signature = new BinaryOperatorSignature(op | BinaryOperatorKind.Enum, leftType, rightType, compilation.GetSpecialType(SpecialType.System_Boolean)); 8281compilation.CreatePointerTypeSymbol(compilation.GetSpecialType(SpecialType.System_Void)), 8282compilation.CreatePointerTypeSymbol(compilation.GetSpecialType(SpecialType.System_Void)), 8283compilation.GetSpecialType(SpecialType.System_Boolean)); 8343leftType.SpecialType == SpecialType.System_Boolean || rightType.SpecialType == SpecialType.System_Boolean || 8344(leftType.SpecialType == SpecialType.System_Decimal && (rightType.SpecialType == SpecialType.System_Double || rightType.SpecialType == SpecialType.System_Single)) || 8345(rightType.SpecialType == SpecialType.System_Decimal && (leftType.SpecialType == SpecialType.System_Double || leftType.SpecialType == SpecialType.System_Single))) &&
Semantics\OverloadResolutionTests.cs (1)
7264Assert.Equal(SpecialType.System_Int32, methodSymbol.TypeArguments.Single().SpecialType);
Semantics\PrimaryConstructorTests.cs (13)
376Assert.Equal(SpecialType.System_Int32, x.Type.SpecialType); 380Assert.Equal(SpecialType.System_String, y.Type.SpecialType); 447Assert.Equal(SpecialType.System_Int32, x.Type.SpecialType); 451Assert.Equal(SpecialType.System_String, y.Type.SpecialType); 560Assert.Equal(SpecialType.System_Int32, x.Type.SpecialType); 564Assert.Equal(SpecialType.System_String, y.Type.SpecialType); 594Assert.Equal(SpecialType.System_Int32, a.Type.SpecialType); 598Assert.Equal(SpecialType.System_String, b.Type.SpecialType); 630Assert.Equal(SpecialType.System_Int32, p1.Type.SpecialType); 636Assert.Equal(SpecialType.System_String, p2.Type.SpecialType); 642Assert.Equal(SpecialType.System_Int32, p2.Type.SpecialType); 686Assert.Equal(SpecialType.System_Int32, p1.Type.SpecialType); 691Assert.Equal(SpecialType.System_String, p2.Type.SpecialType);
Semantics\QueryTests.cs (6)
2179Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType); 2209Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType); 2236Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType); 2242Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType); 2248Assert.Equal(SpecialType.System_Int32, info2.Type.SpecialType); 2301Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType);
Semantics\RawInterpolationTests_Handler.cs (6)
2705comp.MakeTypeMissing(SpecialType.System_Boolean); 2730comp.MakeTypeMissing(SpecialType.System_Void); 2907Assert.Equal(SpecialType.System_String, semanticInfo.Type.SpecialType); 3128Assert.Equal(SpecialType.System_Object, semanticInfo.ConvertedType.SpecialType); 3134Assert.Equal(SpecialType.System_String, semanticInfo.Type.SpecialType); 3135Assert.Equal(SpecialType.System_String, semanticInfo.ConvertedType.SpecialType);
Semantics\RecordStructTests.cs (3)
395Assert.Equal(SpecialType.System_ValueType, point.BaseTypeNoUseSiteDiagnostics.SpecialType); 485Assert.Equal(SpecialType.System_ValueType, point.BaseTypeNoUseSiteDiagnostics.SpecialType); 4372comp.MakeTypeMissing(SpecialType.System_Boolean);
Semantics\RecordTests.cs (6)
120Assert.Equal(SpecialType.System_Object, point.BaseTypeNoUseSiteDiagnostics.SpecialType); 12482verifyReturnType(property.GetMethod, CSharpCustomModifier.CreateOptional(comp.GetSpecialType(SpecialType.System_Int32))); 12487CSharpCustomModifier.CreateOptional(comp.GetSpecialType(SpecialType.System_UInt16))); 12490CSharpCustomModifier.CreateOptional(comp.GetSpecialType(SpecialType.System_Byte))); 12492CSharpCustomModifier.CreateOptional(comp.GetSpecialType(SpecialType.System_UInt16))); 18510comp.MakeTypeMissing(SpecialType.System_Boolean);
Semantics\RefFieldTests.cs (1)
2101Assert.Equal(SpecialType.System_Int16, type.EnumUnderlyingType.SpecialType);
Semantics\RefLocalsAndReturnsTests.cs (12)
4360Assert.Equal(SpecialType.System_Int32, ((IArrayTypeSymbol)model.GetTypeInfo(left).Type).ElementType.SpecialType); 4363Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(right).Type.SpecialType); 4388Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)model.GetTypeInfo(left).Type).PointedAtType.SpecialType); 4391Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(right).Type.SpecialType); 4416Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)model.GetTypeInfo(left).Type).PointedAtType.SpecialType); 4419Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(right).Type.SpecialType); 4444Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(left).Type.SpecialType); 4447Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(right).Type.SpecialType); 4475Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(right).Type.SpecialType); 4503Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(right).Type.SpecialType); 4534Assert.Equal(SpecialType.System_Object, model.GetTypeInfo(left).Type.SpecialType); 4537Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(right).Type.SpecialType);
Semantics\StackAllocInitializerTests.cs (13)
1038Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj1Value.Type).PointedAtType.SpecialType); 1046Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj2Value.Type).PointedAtType.SpecialType); 1047Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj2Value.ConvertedType).PointedAtType.SpecialType); 1062Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj4Value.Type).PointedAtType.SpecialType); 1063Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj4Value.ConvertedType).PointedAtType.SpecialType); 1070Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj5Value.Type).PointedAtType.SpecialType); 1071Assert.Equal(SpecialType.System_Double, ((IPointerTypeSymbol)obj5Value.ConvertedType).PointedAtType.SpecialType); 1149Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj2Value.Type).PointedAtType.SpecialType); 1150Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj2Value.ConvertedType).PointedAtType.SpecialType); 1165Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj4Value.Type).PointedAtType.SpecialType); 1166Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj4Value.ConvertedType).PointedAtType.SpecialType); 1173Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj5Value.Type).PointedAtType.SpecialType); 1174Assert.Equal(SpecialType.System_Double, ((IPointerTypeSymbol)obj5Value.ConvertedType).PointedAtType.SpecialType);
Semantics\StackAllocSpanExpressionsTests.cs (13)
60Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj1Value.Type).PointedAtType.SpecialType); 68Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj2Value.Type).PointedAtType.SpecialType); 69Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj2Value.ConvertedType).PointedAtType.SpecialType); 84Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj4Value.Type).PointedAtType.SpecialType); 85Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj4Value.ConvertedType).PointedAtType.SpecialType); 92Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj5Value.Type).PointedAtType.SpecialType); 93Assert.Equal(SpecialType.System_Double, ((IPointerTypeSymbol)obj5Value.ConvertedType).PointedAtType.SpecialType); 143Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj2Value.Type).PointedAtType.SpecialType); 144Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj2Value.ConvertedType).PointedAtType.SpecialType); 159Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj4Value.Type).PointedAtType.SpecialType); 160Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj4Value.ConvertedType).PointedAtType.SpecialType); 167Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)obj5Value.Type).PointedAtType.SpecialType); 168Assert.Equal(SpecialType.System_Double, ((IPointerTypeSymbol)obj5Value.ConvertedType).PointedAtType.SpecialType);
Semantics\TargetTypedConditionalOperatorTests.cs (1)
363Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(conditionalExpr.Condition).Type!.SpecialType);
Semantics\TopLevelStatementsTests.cs (4)
7477comp.MakeTypeMissing(SpecialType.System_Int32); 7499comp.MakeTypeMissing(SpecialType.System_Int32); 7563comp.MakeTypeMissing(SpecialType.System_Int32); 7594comp.MakeTypeMissing(SpecialType.System_String);
Semantics\UnsafeTests.cs (54)
3075Assert.False(compilation.GetSpecialType(SpecialType.System_ArgIterator).IsManagedTypeNoUseSiteDiagnostics); 3076Assert.False(compilation.GetSpecialType(SpecialType.System_RuntimeArgumentHandle).IsManagedTypeNoUseSiteDiagnostics); 3092Assert.True(libComp.GetSpecialType(SpecialType.System_TypedReference).IsManagedTypeNoUseSiteDiagnostics); 3124Assert.Equal(SpecialType.System_TypedReference, ((PointerTypeSymbol)returnType).PointedAtType.SpecialType); 3128Assert.Equal(SpecialType.System_TypedReference, ((PointerTypeSymbol)parameterType).PointedAtType.SpecialType); 3214Assert.True(comp.GetSpecialType(SpecialType.System_TypedReference).IsManagedTypeNoUseSiteDiagnostics); 3235Assert.True(comp.GetSpecialType(SpecialType.System_TypedReference).IsManagedTypeNoUseSiteDiagnostics); 3256Assert.True(comp.GetSpecialType(SpecialType.System_TypedReference).IsManagedTypeNoUseSiteDiagnostics); 3297Assert.True(comp.GetSpecialType(SpecialType.System_TypedReference).IsManagedTypeNoUseSiteDiagnostics); 4434Assert.Equal(SpecialType.System_Int32, ((IPointerTypeSymbol)type).PointedAtType.SpecialType); 4711Assert.Equal(SpecialType.System_Int32, type.SpecialType); 5044Assert.Equal(SpecialType.System_Void, callSummary.Type.SpecialType); 5045Assert.Equal(SpecialType.System_Void, callSummary.ConvertedType.SpecialType); 5107Assert.Equal(SpecialType.System_Void, callSummary.Type.SpecialType); 5327var intType = compilation.GetSpecialType(SpecialType.System_Int32); 5394var intType = compilation.GetSpecialType(SpecialType.System_Int32); 5452var intType = compilation.GetSpecialType(SpecialType.System_Int32); 5550Assert.NotEqual(SpecialType.System_Void, ((IPointerTypeSymbol)type).PointedAtType.SpecialType); 5554Assert.Equal(SpecialType.System_Void, ((IPointerTypeSymbol)convertedType).PointedAtType.SpecialType); 6079Assert.Equal(SpecialType.System_Int64, summary.Type.SpecialType); 6080Assert.Equal(SpecialType.System_Int64, summary.ConvertedType.SpecialType); 6506Assert.Equal(SpecialType.System_Boolean, summary.Type.SpecialType); 6507Assert.Equal(SpecialType.System_Boolean, summary.ConvertedType.SpecialType); 7349Assert.Equal(SpecialType.System_Char, ((IPointerTypeSymbol)type).PointedAtType.SpecialType); 7380var stringSymbol = compilation.GetSpecialType(SpecialType.System_String); 7381var charSymbol = compilation.GetSpecialType(SpecialType.System_Char); 7452var stringSymbol = compilation.GetSpecialType(SpecialType.System_String); 7453var charSymbol = compilation.GetSpecialType(SpecialType.System_Char); 7455var voidSymbol = compilation.GetSpecialType(SpecialType.System_Void); 7734private static readonly Dictionary<SpecialType, int> s_specialTypeSizeOfMap = new Dictionary<SpecialType, int> 7736{ SpecialType.System_SByte, 1 }, 7737{ SpecialType.System_Byte, 1 }, 7738{ SpecialType.System_Int16, 2 }, 7739{ SpecialType.System_UInt16, 2 }, 7740{ SpecialType.System_Int32, 4 }, 7741{ SpecialType.System_UInt32, 4 }, 7742{ SpecialType.System_Int64, 8 }, 7743{ SpecialType.System_UInt64, 8 }, 7744{ SpecialType.System_Char, 2 }, 7745{ SpecialType.System_Single, 4 }, 7746{ SpecialType.System_Double, 8 }, 7747{ SpecialType.System_Boolean, 1 }, 7748{ SpecialType.System_Decimal, 16 }, 7791Assert.NotEqual(SpecialType.None, type.SpecialType); 7804Assert.Equal(SpecialType.System_Int32, sizeOfSummary.Type.SpecialType); 7866Assert.Equal(SpecialType.System_Int32, sizeOfSummary.Type.SpecialType); 7913Assert.Equal(SpecialType.None, type.SpecialType); 7926Assert.Equal(SpecialType.System_Int32, sizeOfSummary.Type.SpecialType); 8459Assert.Equal(SpecialType.System_Char, ((IPointerTypeSymbol)stackAllocSummary.Type).PointedAtType.SpecialType); 8460Assert.Equal(SpecialType.System_Void, ((IPointerTypeSymbol)stackAllocSummary.ConvertedType).PointedAtType.SpecialType); 8471Assert.Equal(SpecialType.System_Char, typeSummary.Type.SpecialType); 8483Assert.Equal(SpecialType.System_Int16, countSummary.Type.SpecialType); 8484Assert.Equal(SpecialType.System_Int32, countSummary.ConvertedType.SpecialType);
Semantics\UsingStatementTests.cs (2)
67Assert.Equal(SpecialType.System_IDisposable, declaredLocal.Type.SpecialType); 1854Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(node).Type.SpecialType);
Semantics\Utf8StringsLiteralsTests.cs (2)
1916comp.MakeTypeMissing(SpecialType.System_Byte); 1943comp.MakeTypeMissing(SpecialType.System_Int32);
Utilities\ValueSetTests.cs (17)
492Assert.Same(ForByte, ForSpecialType(SpecialType.System_Byte)); 493Assert.Same(ForSByte, ForSpecialType(SpecialType.System_SByte)); 494Assert.Same(ForShort, ForSpecialType(SpecialType.System_Int16)); 495Assert.Same(ForUShort, ForSpecialType(SpecialType.System_UInt16)); 496Assert.Same(ForInt, ForSpecialType(SpecialType.System_Int32)); 497Assert.Same(ForUInt, ForSpecialType(SpecialType.System_UInt32)); 498Assert.Same(ForLong, ForSpecialType(SpecialType.System_Int64)); 499Assert.Same(ForULong, ForSpecialType(SpecialType.System_UInt64)); 500Assert.Same(ForFloat, ForSpecialType(SpecialType.System_Single)); 501Assert.Same(ForDouble, ForSpecialType(SpecialType.System_Double)); 502Assert.Same(ForString, ForSpecialType(SpecialType.System_String)); 503Assert.Same(ForDecimal, ForSpecialType(SpecialType.System_Decimal)); 504Assert.Same(ForChar, ForSpecialType(SpecialType.System_Char)); 505Assert.Same(ForBool, ForSpecialType(SpecialType.System_Boolean)); 506Assert.Same(ForNint, ForSpecialType(SpecialType.System_IntPtr, isNative: true)); 507Assert.Same(ForNuint, ForSpecialType(SpecialType.System_UIntPtr, isNative: true)); 508Assert.Null(ForSpecialType(SpecialType.System_Enum));
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (501)
Compilation\CompilationAPITests.cs (48)
1514comp.GetSpecialType((SpecialType)100); 1520comp.GetSpecialType(SpecialType.None); 1526comp.GetSpecialType((SpecialType)000); 1532comp.GetSpecialType(default(SpecialType)); 2462var elementType = comp.GetSpecialType(SpecialType.System_Object); 2491var elementType = comp.GetSpecialType(SpecialType.System_Object); 2521ImmutableArray.Create((ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32), 2522(ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32)), 2533ImmutableArray.Create((ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32), 2534(ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32)), 2545ImmutableArray.Create((ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32), 2546(ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32)), 2557ImmutableArray.Create((ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32), 2558(ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32)), 2599ImmutableArray.Create((ITypeSymbol)compilation.GetSpecialType(SpecialType.System_Int32)), 2608ImmutableArray.Create<ITypeSymbol>(compilation.GetSpecialType(SpecialType.System_Int32)), 2627ImmutableArray.Create<ITypeSymbol>(compilation.GetSpecialType(SpecialType.System_Int32), 2628compilation.GetSpecialType(SpecialType.System_Int32)), 2644ImmutableArray.Create<ITypeSymbol>(compilation.GetSpecialType(SpecialType.System_Int32), compilation.GetSpecialType(SpecialType.System_Boolean)), 2659var memberTypes = ImmutableArray.Create<ITypeSymbol>(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)); 2699var memberTypes = ImmutableArray.Create<ITypeSymbol>(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)); 2743var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2760var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2761var boolType = compilation.GetSpecialType(SpecialType.System_Boolean).GetPublicSymbol(); 2780var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2790var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2791var nullableIntType = compilation.GetSpecialType(SpecialType.System_Nullable_T).GetPublicSymbol().Construct(intType); 2818var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2838var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2873var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2905var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2939var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2951var boolType = compilation.GetSpecialType(SpecialType.System_Boolean).GetPublicSymbol(); 2970var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2980var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 2981var nullableIntType = compilation.GetSpecialType(SpecialType.System_Nullable_T).GetPublicSymbol().Construct(intType); 3016var intType = compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 3033var typeArguments = ImmutableArray.Create<ITypeSymbol>(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)); 3053typeArguments = ImmutableArray.Create<ITypeSymbol>(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)); 3068var typeArguments = ImmutableArray.Create<ITypeSymbol>(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)); 3088typeArguments = ImmutableArray.Create<ITypeSymbol>(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String));
Compilation\GetSemanticInfoBrokenCodeTests.cs (1)
271Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType);
Compilation\GetSemanticInfoTests.cs (52)
381ConversionTestHelper(model, (v1 as CastExpressionSyntax).Expression, comp.GetSpecialType(SpecialType.System_UInt32), ConversionKind.ExplicitNumeric); 384ConversionTestHelper(model, (v2 as AssignmentExpressionSyntax).Right, comp.GetSpecialType(SpecialType.System_Object), ConversionKind.Boxing); 387ConversionTestHelper(model, (v3 as CastExpressionSyntax).Expression, comp.GetSpecialType(SpecialType.System_Int32), ConversionKind.Unboxing); 1143Assert.Equal(SpecialType.System_Boolean, info.Type.SpecialType); 1325Assert.Equal(SpecialType.System_Void, bindInfo.Type.SpecialType); 1352Assert.Equal(SpecialType.System_Void, bindInfo.Type.SpecialType); 1380Assert.Equal(SpecialType.System_Void, bindInfo.Type.SpecialType); 1422Assert.Equal(SpecialType.System_Int32, bindInfo.Type.SpecialType); 1423Assert.Equal(SpecialType.System_Int32, bindInfo.ConvertedType.SpecialType); 1463Assert.Equal(SpecialType.System_Int32, bindInfo.Type.SpecialType); //still have the type since all candidates agree 1464Assert.Equal(SpecialType.System_Int32, bindInfo.ConvertedType.SpecialType); 2458Assert.Equal(SpecialType.System_Double, info.Type.SpecialType); 2459Assert.Equal(SpecialType.System_Double, info.ConvertedType.SpecialType); 2487Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType); 2488Assert.Equal(SpecialType.System_Int32, info.ConvertedType.SpecialType); 2511Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType); 2512Assert.Equal(SpecialType.System_Int32, info.ConvertedType.SpecialType); 3611Assert.Equal(SpecialType.System_Int32, literalTypeInfo.Type.SpecialType); 3612Assert.Equal(SpecialType.System_Object, literalTypeInfo.ConvertedType.SpecialType); 3636Assert.Equal(SpecialType.System_Int32, literalTypeInfo.Type.SpecialType); 3637Assert.Equal(SpecialType.System_Int32, literalTypeInfo.ConvertedType.SpecialType); 3644Assert.Equal(SpecialType.System_Int64, castTypeInfo.Type.SpecialType); 3645Assert.Equal(SpecialType.System_Object, castTypeInfo.ConvertedType.SpecialType); 3669Assert.Equal(SpecialType.System_Int32, literalTypeInfo.Type.SpecialType); 3670Assert.Equal(SpecialType.System_Int32, literalTypeInfo.ConvertedType.SpecialType); 3677Assert.Equal(SpecialType.System_Object, castTypeInfo.Type.SpecialType); 3678Assert.Equal(SpecialType.System_Object, castTypeInfo.ConvertedType.SpecialType); 3705Assert.Equal(SpecialType.System_Int32, literalTypeInfo.Type.SpecialType); 3706Assert.Equal(SpecialType.System_Int32, literalTypeInfo.ConvertedType.SpecialType); 3713Assert.Equal(SpecialType.System_Int64, cast1TypeInfo.Type.SpecialType); 3714Assert.Equal(SpecialType.System_Int64, cast1TypeInfo.ConvertedType.SpecialType); 3725Assert.Equal(SpecialType.System_Object, cast2TypeInfo.Type.SpecialType); 3726Assert.Equal(SpecialType.System_Object, cast2TypeInfo.ConvertedType.SpecialType); 4064Assert.Equal(SpecialType.System_Collections_Generic_ICollection_T, ((TypeSymbol)reducedFrom1.Parameters[0].Type.OriginalDefinition).SpecialType); 4075Assert.Equal(SpecialType.System_Collections_Generic_ICollection_T, ((TypeSymbol)reducedFrom2.Parameters[0].Type.OriginalDefinition).SpecialType); 4116Assert.Equal(SpecialType.System_Collections_Generic_IEnumerable_T, ((ITypeSymbol)info0.Symbol.OriginalDefinition).SpecialType); 4117Assert.Equal(SpecialType.System_Int32, ((INamedTypeSymbol)info0.Symbol).TypeArguments.Single().SpecialType); 4120Assert.Equal(SpecialType.System_Int32, ((ITypeSymbol)info1.Symbol).SpecialType); 4124Assert.Equal(SpecialType.System_Collections_Generic_IEnumerable_T, ((ITypeSymbol)info2.Symbol.OriginalDefinition).SpecialType); 4125Assert.Equal(SpecialType.System_Int32, ((INamedTypeSymbol)info2.Symbol).TypeArguments.Single().SpecialType); 4171Assert.Equal(SpecialType.System_Int32, ((ITypeSymbol)info1.Symbol).SpecialType); 4175Assert.Equal(SpecialType.System_Collections_Generic_IEnumerable_T, ((ITypeSymbol)info2.Symbol.OriginalDefinition).SpecialType); 4176Assert.Equal(SpecialType.System_Int32, ((INamedTypeSymbol)info2.Symbol).TypeArguments.Single().SpecialType); 5399var objectType = compilation.GetSpecialType(SpecialType.System_Object); 5523var otherFuncType = comp.GetWellKnownType(WellKnownType.System_Func_T).Construct(comp.GetSpecialType(SpecialType.System_Int32)); 5537var otherFuncType = comp.GetWellKnownType(WellKnownType.System_Func_T).Construct(comp.GetSpecialType(SpecialType.System_Int32)); 5727var typeInt = comp.GetSpecialType(SpecialType.System_Int32); 5916Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType); 5925var specialType = (SpecialType)(-1); 5948var specialType = SpecialType.Count + 1;
Compilation\QueryClauseInfoTests.cs (2)
21var obj = c.GetSpecialType(SpecialType.System_Object); 22var int32 = c.GetSpecialType(SpecialType.System_Int32);
Compilation\SemanticModelAPITests.cs (30)
55Assert.Equal(SpecialType.System_Int32, typeInfo.Type.SpecialType); 59Assert.Equal(SpecialType.System_Char, typeInfo.Type.SpecialType); 142Assert.Equal(SpecialType.System_Int32, typeInfo.Type.SpecialType); 152Assert.Equal(SpecialType.System_Char, typeInfo.Type.SpecialType); 708Assert.Equal(compilation.GetSpecialType(SpecialType.System_String), (info.Symbol as IArrayTypeSymbol).ElementType); 1929Assert.Equal(ConstantValue.Default(SpecialType.System_Int32), labelSymbol.SwitchCaseLabelConstant); 3166Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType); 3201Assert.Equal(SpecialType.System_Int32, info.Type.SpecialType); 3202Assert.Equal(SpecialType.System_Int64, info.ConvertedType.SpecialType); 3745var stringType = comp.GetSpecialType(SpecialType.System_String); 3916Assert.True(typeInfo0.Type != null && typeInfo0.Type.SpecialType == SpecialType.System_Int16); 3923var type1 = comp.GetSpecialType(SpecialType.System_Nullable_T).Construct(comp.GetSpecialType(SpecialType.System_Int32)); 3930var type2 = comp.GetSpecialType(SpecialType.System_Nullable_T).Construct(comp.GetSpecialType(SpecialType.System_Int32)); 4190Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[0]).Type.SpecialType); 4215Assert.Equal(SpecialType.System_Int32, model.GetTypeInfo(actual[0]).Type.SpecialType); 4219Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(actual[1]).Type.SpecialType); 4280Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[0]).Type.SpecialType); 4284Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[1]).Type.SpecialType); 4287Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[2]).Type.SpecialType); 4291Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[3]).Type.SpecialType); 4295Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[4]).Type.SpecialType); 4299Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[5]).Type.SpecialType); 4303Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[6]).Type.SpecialType); 4307Assert.Equal(SpecialType.System_String, model.GetTypeInfo(actual[7]).Type.SpecialType); 4433Assert.Equal(SpecialType.System_Boolean, originalTypeInfo.Type.SpecialType); 4436Assert.Equal(SpecialType.System_Boolean, speculativeTypeInfo.Type.SpecialType); 4504Assert.Equal(SpecialType.System_String, type.TupleElements[0].Type.SpecialType); 4505Assert.Equal(SpecialType.System_Int32, type.TupleElements[1].Type.SpecialType);
Compilation\SemanticModelGetDeclaredSymbolAPITests.cs (9)
347Assert.Equal(SpecialType.System_Int32, paramSymbol.Type.SpecialType); 724Assert.Equal(ConstantValue.Default(SpecialType.System_Int32), labelSymbol.SwitchCaseLabelConstant); 1387Assert.Equal(9, symbolsInC.Where(s => s.ContainingType == null || s.ContainingType.SpecialType != SpecialType.System_Object).Count()); 1767var baseType = compilation.GetSpecialType(SpecialType.System_Object); 1776var valueType = compilation.GetSpecialType(SpecialType.System_Int32); 1823var type = compilation.GetSpecialType(SpecialType.System_Collections_Generic_IList_T); 1824type = type.Construct(compilation.GetSpecialType(SpecialType.System_String)); 1833type = compilation.GetSpecialType(SpecialType.System_Double); 3674Assert.Equal(SpecialType.System_Int32, parameter.Type.SpecialType);
Compilation\SemanticModelGetSemanticInfoTests.cs (18)
342Assert.Equal(SpecialType.System_String, semanticInfo.Type.SpecialType); 430Assert.Equal(SpecialType.System_String, semanticInfo.Type.SpecialType); 1287type = compilation.GetSpecialType(SpecialType.System_String); 1314type = compilation.GetSpecialType(SpecialType.System_String); 5356Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 5381Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 6090Assert.Equal(SpecialType.System_Void, semanticInfo.Type.SpecialType); 6209Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 6229Assert.Equal(SpecialType.System_String, ((IArrayTypeSymbol)semanticInfo.Type).ElementType.SpecialType); 6231Assert.Equal(SpecialType.System_Collections_IEnumerable, semanticInfo.ConvertedType.SpecialType); 6251Assert.Equal(SpecialType.System_String, semanticInfo.Type.SpecialType); 6255Assert.Equal(SpecialType.System_String, ((ITypeSymbol)symbol).SpecialType); 8173Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 8197Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 8218Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 8334Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 9096Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 10985Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType);
Compilation\SemanticModelGetSemanticInfoTests_LateBound.cs (2)
299Assert.Equal(SpecialType.System_Int32, semanticInfo.Type.SpecialType); 300Assert.Equal(SpecialType.System_Int32, semanticInfo.ConvertedType.SpecialType);
Compilation\TypeInfoTests.cs (4)
20var obj = c.GetSpecialType(SpecialType.System_Object).GetPublicSymbol(); 21var int32 = c.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(); 45var intEnum1 = c.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).GetPublicSymbol().Construct(int32); 46var intEnum2 = c.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).GetPublicSymbol().Construct(int32);
DocumentationComments\CrefTests.cs (16)
1270Single(m => m.Parameters.Single().Type.SpecialType == SpecialType.System_Int32); 2218var expectedSymbol = compilation.GetSpecialType(SpecialType.System_Int32); 2412Single(method => method.ParameterTypesWithAnnotations.Single().SpecialType == SpecialType.System_Int32); 2597Single(method => method.ParameterTypesWithAnnotations.First().SpecialType == SpecialType.System_Int32); 2805Single(method => method.ParameterTypesWithAnnotations.Single().SpecialType == SpecialType.System_Int32); 2841Single(method => method.ParameterTypesWithAnnotations.Single().SpecialType == SpecialType.System_Int32 && method.ReturnType.SpecialType == SpecialType.System_Int32); 3006var typeInt = ((Compilation)compilation).GetSpecialType(SpecialType.System_Int32); 3078var expectedParameterType = compilation.GetSpecialType(SpecialType.System_Int32).ISymbol; 3136var expectedReturnType = compilation.GetSpecialType(SpecialType.System_Int32).ISymbol; 5403Assert.Equal(compilation.GetSpecialType(SpecialType.System_Int32), model.GetSymbolInfo(crefSyntaxes[0]).Symbol); 5404Assert.Equal(compilation.GetSpecialType(SpecialType.System_Int64), model.GetSymbolInfo(crefSyntaxes[1]).Symbol); 5720Assert.Equal(SpecialType.System_Decimal, symbol.ContainingType.SpecialType); 5921var expectedSymbol = compilation.GetSpecialType(SpecialType.System_String). 6218Assert.Equal(compilation.GetSpecialType(SpecialType.System_Int32), info.Symbol); 6251Assert.Equal(compilation.GetSpecialType(SpecialType.System_Int32), info.Symbol);
Symbols\AccessorOverriddenOrHiddenMembersTests.cs (1)
1053var disposeMethod = (IMethodSymbol)compilation.GetSpecialType(SpecialType.System_IDisposable).GetMembers("Dispose").Single();
Symbols\AnonymousTypesSymbolTests.cs (2)
1925ImmutableArray.Create<ITypeSymbol>(compilation.GetSpecialType(SpecialType.System_Int32).GetPublicSymbol(), compilation.GetSpecialType(SpecialType.System_Boolean).GetPublicSymbol()),
Symbols\AssemblyAndNamespaceTests.cs (3)
381var objectType = comp.GetSpecialType(SpecialType.System_Object); 385Assert.Equal(objectType, comp.Assembly.GetSpecialType(SpecialType.System_Object)); 386Assert.Equal(objectType, comp.Assembly.CorLibrary.GetSpecialType(SpecialType.System_Object));
Symbols\CompilationCreationTests.cs (9)
76Assert.Equal(SpecialType.None, c107.SpecialType); 78for (int i = 1; i <= (int)SpecialType.Count; i++) 80NamedTypeSymbol type = c1.GetSpecialType((SpecialType)i); 81if (i == (int)SpecialType.System_Runtime_CompilerServices_RuntimeFeature || 82i == (int)SpecialType.System_Runtime_CompilerServices_PreserveBaseOverridesAttribute) 91Assert.Equal((SpecialType)i, type.SpecialType); 94Assert.Equal(SpecialType.None, c107.SpecialType); 98Assert.Equal(SpecialType.None, arrayOfc107.SpecialType); 102Assert.Equal(SpecialType.None, c2.GlobalNamespace.GetTypeMembers("C107").Single().SpecialType);
Symbols\ConversionTests.cs (4)
348Assert.Equal(ConversionKind.Identity, tuple.Item2.ClassifyConversion(tuple.Item1, comp.GetSpecialType(SpecialType.System_Boolean)).Kind); 1720var destinationType = comp.GlobalNamespace.GetMember<INamedTypeSymbol>("C").Construct(comp.GetSpecialType(SpecialType.System_Int32)); 1804Assert.Equal(SpecialType.System_Byte, method.Parameters.Single().Type.SpecialType); 1838Assert.Equal(SpecialType.System_Byte, method.Parameters.Single().Type.SpecialType);
Symbols\CorLibrary\Choosing.cs (3)
40var obj = corLib.GetSpecialType(SpecialType.System_Object); 51Assert.Same(obj, consumer.GetSpecialType(SpecialType.System_Object)); 72Assert.True(consumer.GetSpecialType(SpecialType.System_Object).IsErrorType());
Symbols\CorLibrary\CorTypes.cs (22)
33for (int i = 1; i <= (int)SpecialType.Count; i++) 35var t = noMsCorLibRef.GetSpecialType((SpecialType)i); 36Assert.Equal((SpecialType)i, t.SpecialType); 47Assert.Equal(SpecialType.System_Int32, p.SpecialType); 61for (int i = 1; i <= (int)SpecialType.Count; i++) 63var t = msCorLibRef.GetSpecialType((SpecialType)i); 64Assert.Equal((SpecialType)i, t.SpecialType); 99else if (((NamedTypeSymbol)m).SpecialType != SpecialType.None) 104if (count >= (int)SpecialType.Count) 111Assert.Equal((int)SpecialType.Count, count + knownMissingTypes.Count); 122for (int i = 1; i <= (int)SpecialType.Count; i++) 125var t = msCorLibRef.GetSpecialType((SpecialType)i); 126Assert.Equal((SpecialType)i, t.SpecialType); 128if (t.SpecialType == SpecialType.System_Object) 162for (int i = 1; i <= (int)SpecialType.Count; i++) 164if (i != (int)SpecialType.System_Object) 167var t = c1.GetSpecialType((SpecialType)i); 168Assert.Equal((SpecialType)i, t.SpecialType); 178Assert.Equal(SpecialType.System_Object, system_object.SpecialType); 182Assert.Same(system_object, c1.GetSpecialType(SpecialType.System_Object)); 184Assert.Throws<ArgumentOutOfRangeException>(() => c1.GetSpecialType(SpecialType.None)); 185Assert.Throws<ArgumentOutOfRangeException>(() => c1.GetSpecialType(SpecialType.Count + 1));
Symbols\DefaultInterfaceImplementationTests.cs (21)
34657var test1i1 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)); 34658var test1i1m1 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)).GetMember<MethodSymbol>("M1"); 34659var test1i1m2 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)).GetMember<MethodSymbol>("M2"); 34661var test2i1 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)); 34662var test2i1m1 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)).GetMember<MethodSymbol>("M1"); 34663var test2i1m2 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)).GetMember<MethodSymbol>("M2"); 34664var test2i2 = i2.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)); 34665var test2i2m1 = i2.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)).GetMember<MethodSymbol>("I1<T>.M1"); 34666var test2i2m2 = i2.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)).GetMember<MethodSymbol>("I1<T>.M2"); 38954var test1i1 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)); 38955var test1i1m1 = GetSingleProperty(i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32))); 38957var test2i1 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)); 38958var test2i1m1 = GetSingleProperty(i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64))); 38959var test2i2 = i2.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)); 38960var test2i2m1 = GetSingleProperty(i2.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64))); 41630var test1i1 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)); 41631var test1i1m1 = GetSingleEvent(i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32))); 41633var test2i1 = i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)); 41634var test2i1m1 = GetSingleEvent(i1.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64))); 41635var test2i2 = i2.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)); 41636var test2i2m1 = GetSingleEvent(i2.Construct(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int64)));
Symbols\ExtensionMethodTests.cs (14)
43Assert.Equal(SpecialType.System_Object, parameter.Type.SpecialType); 49Assert.Equal(SpecialType.System_Object, parameter.Type.SpecialType); 2532var intType = compilation.GetSpecialType(SpecialType.System_Int32); 2533var stringType = compilation.GetSpecialType(SpecialType.System_String); 2603Assert.Equal(SpecialType.System_Object, method.Parameters.Single().Type.SpecialType); 2811var int32Type = compilation.GetSpecialType(SpecialType.System_Int32); 2855var int32Type = compilation2.GetSpecialType(SpecialType.System_Int32); 2878int32Type = compilation2.GetSpecialType(SpecialType.System_Int32); 4040Assert.Equal(SpecialType.System_Int32, parameter.Type.SpecialType); 4046Assert.Equal(SpecialType.System_Int32, parameter.Type.SpecialType); 4070Assert.Equal(SpecialType.System_Int32, parameter.Type.SpecialType); 4076Assert.Equal(SpecialType.System_Int32, parameter.Type.SpecialType); 4100var systemVoidType = compilation.GetSpecialType(SpecialType.System_Void); 4101Assert.Equal(SpecialType.System_Void, systemVoidType.SpecialType);
Symbols\FunctionPointerTypeSymbolTests.cs (21)
46Assert.Equal(SpecialType.System_Object, pointerType.Signature.ReturnType.SpecialType); 267Assert.Equal(SpecialType.System_String, pointerType.Signature.ReturnType.SpecialType); 380Assert.Equal(SpecialType.System_Int32, firstParam.Parameters.Single().Type.SpecialType); 383Assert.Equal(SpecialType.System_Object, secondParam.Parameters.Single().Type.SpecialType); 390Assert.Equal(SpecialType.System_Object, fourthParam.Parameters[0].Type.SpecialType); 391Assert.Equal(SpecialType.System_Object, fourthParam.Parameters[1].Type.SpecialType); 396Assert.Equal(SpecialType.System_Object, fifthParam.Parameters[1].Type.SpecialType); 1535var @string = comp.GetSpecialType(SpecialType.System_String); 1558var @string = comp.GetSpecialType(SpecialType.System_String); 1586var @string = comp.GetSpecialType(SpecialType.System_String); 1602var @string = comp.GetSpecialType(SpecialType.System_String); 1603var @void = comp.GetSpecialType(SpecialType.System_Void); 1621var @string = comp.GetSpecialType(SpecialType.System_String); 1642var @string = comp.GetSpecialType(SpecialType.System_String); 1654var @string = comp.GetSpecialType(SpecialType.System_String); 1962var returnType = mainComp.GetSpecialType(SpecialType.System_String).GetPublicSymbol(); 1982var returnType = comp.GetSpecialType(SpecialType.System_String); 1984var objectMod = CSharpCustomModifier.CreateOptional(comp.GetSpecialType(SpecialType.System_Object)); 2087var returnType = comp.GetSpecialType(SpecialType.System_String); 2138var returnType = comp.GetSpecialType(SpecialType.System_String); 2140var objectMod = CSharpCustomModifier.CreateOptional(comp.GetSpecialType(SpecialType.System_Object));
Symbols\GenericConstraintTests.cs (1)
6603Assert.Equal(SpecialType.System_ValueType, typeSymbol.SpecialType);
Symbols\IndexerTests.cs (27)
56CheckIndexer(type.Indexers.Single(), true, true, SpecialType.System_String, SpecialType.System_String); 59CheckIndexer(type.Indexers.Single(), false, true, SpecialType.System_Object, SpecialType.System_Int32, SpecialType.None); 62CheckIndexer(type.Indexers.Single(), true, false, SpecialType.System_Object, SpecialType.System_String); 130CheckIndexer(type.Indexers.Single(), true, true, SpecialType.System_Object, SpecialType.System_String); 133CheckIndexer(type.Indexers.Single(), true, false, SpecialType.System_Object, SpecialType.System_String); 136CheckIndexer(type.Indexers.Single(), true, true, SpecialType.System_Object, SpecialType.System_String); 141CheckIndexer(typeAProperties[0], true, true, SpecialType.System_Object, SpecialType.System_String); 142CheckIndexer(typeAProperties[1], true, false, SpecialType.System_Object, SpecialType.System_String); 143CheckIndexer(typeAProperties[2], true, true, SpecialType.System_Object, SpecialType.System_String); 146CheckIndexer(sourceType.Indexers.Single(), true, true, SpecialType.System_Object, SpecialType.System_String); 157CheckIndexer(sourceType.Indexers.Single(), true, true, SpecialType.System_Object, SpecialType.System_String); 174private static void CheckIndexer(PropertySymbol property, bool hasGet, bool hasSet, SpecialType expectedType, params SpecialType[] expectedParameterTypes) 210private static void CheckParameters(ImmutableArray<ParameterSymbol> parameters, SpecialType[] expectedTypes) 2868var substitutedType = unsubstitutedType.Construct(comp.GetSpecialType(SpecialType.System_Int32));
Symbols\InterfaceImplementationTests.cs (1)
1864Assert.Equal(SpecialType.System_Void, returnType.SpecialType);
Symbols\Metadata\PE\BaseTypeResolution.cs (2)
313Assert.Equal("System.Object", ((SourceModuleSymbol)c1.Assembly.Modules[0]).GetCorLibType(SpecialType.System_Object).ToTestDisplayString()); 318Assert.Equal("System.Object[missing]", ((SourceModuleSymbol)c2.Assembly.Modules[0]).GetCorLibType(SpecialType.System_Object).ToTestDisplayString());
Symbols\Metadata\PE\DynamicTransformsTests.cs (4)
47_objectType = _assembly.CorLibrary.GetSpecialType(SpecialType.System_Object); 48_intType = _assembly.CorLibrary.GetSpecialType(SpecialType.System_Int32); 318Assert.Equal(SpecialType.System_Void, prop2.SetMethod.ReturnType.SpecialType); 373var nullableStruct = _assembly.CorLibrary.GetSpecialType(SpecialType.System_Nullable_T).Construct(structType);
Symbols\Metadata\PE\LoadingEvents.cs (2)
116Assert.Equal(SpecialType.System_Void, accessor.ReturnType.SpecialType); 181Assert.Equal(SpecialType.System_Int32, nonDelegateEvent.Type.SpecialType);
Symbols\Metadata\PE\LoadingFields.cs (1)
64Assert.Same(((PEModuleSymbol)module2).GetCorLibType(SpecialType.System_Int32), f2.Type);
Symbols\Metadata\PE\LoadingIndexers.cs (1)
1076Assert.Equal(SpecialType.System_Void, accessor.ReturnType.SpecialType);
Symbols\Metadata\PE\MissingTypeReferences.cs (4)
318Assert.Equal(asm1.GetSpecialType(SpecialType.System_Boolean), asm1.GetSpecialType(SpecialType.System_Boolean)); 319Assert.Equal(asm1.GetSpecialType(SpecialType.System_Boolean), asm2.GetSpecialType(SpecialType.System_Boolean));
Symbols\MissingSpecialMember.cs (11)
157var specialType = comp.GetSpecialType(SpecialType.System_String); 159Assert.Equal(SpecialType.System_String, specialType.SpecialType); 164Assert.Equal(SpecialType.None, lookupType.SpecialType); 235var specialType = comp.GetSpecialType(SpecialType.System_Nullable_T); 237Assert.Equal(SpecialType.System_Nullable_T, specialType.SpecialType); 241Assert.Equal(SpecialType.System_Nullable_T, lookupType.SpecialType); 528for (var special = SpecialType.None + 1; special <= SpecialType.Count; special++) 533if (special == SpecialType.System_Runtime_CompilerServices_RuntimeFeature || 534special == SpecialType.System_Runtime_CompilerServices_PreserveBaseOverridesAttribute)
Symbols\MockAssemblySymbol.cs (1)
48internal override NamedTypeSymbol GetDeclaredSpecialType(SpecialType type)
Symbols\OverriddenOrHiddenMembersTests.cs (1)
2867var obj = compilation.GetSpecialType(SpecialType.System_Object);
Symbols\Retargeting\RetargetCustomModifiers.cs (2)
172Assert.Equal(SpecialType.System_Int32, volatileFld.Type.SpecialType); 213Assert.Equal(SpecialType.System_DateTime, p1Type.PointedAtType.SpecialType);
Symbols\Retargeting\RetargetingTests.cs (22)
346Assert.Equal(SpecialType.System_Enum, sourceType.BaseType().SpecialType); 348Assert.Equal(SpecialType.System_Int32, sourceType.EnumUnderlyingType.SpecialType); 355Assert.Equal(SpecialType.System_Enum, retargetingType.BaseType().SpecialType); 357Assert.Equal(SpecialType.System_Int32, retargetingType.EnumUnderlyingType.SpecialType); 383Assert.Equal(SpecialType.System_Enum, sourceType.BaseType().SpecialType); 385Assert.Equal(SpecialType.System_Int16, sourceType.EnumUnderlyingType.SpecialType); 392Assert.Equal(SpecialType.System_Enum, retargetingType.BaseType().SpecialType); 394Assert.Equal(SpecialType.System_Int16, retargetingType.EnumUnderlyingType.SpecialType); 414Assert.Equal(SpecialType.System_Object, sourceType.BaseType().SpecialType); 419Assert.Equal(SpecialType.System_Object, retargetingType.BaseType().SpecialType); 443Assert.Equal(SpecialType.System_Int16, sourceType.BaseType().SpecialType); 449Assert.Equal(SpecialType.System_Int16, retargetingType.BaseType().SpecialType); 492Assert.Equal(SpecialType.System_ValueType, sourceType.BaseType().SpecialType); 497Assert.Equal(SpecialType.System_ValueType, retargetingType.BaseType().SpecialType); 524Assert.Equal(SpecialType.System_Int16, sourceType.Interfaces().Single().SpecialType); 526Assert.Equal(SpecialType.System_ValueType, sourceType.BaseType().SpecialType); 531Assert.Equal(SpecialType.System_Int16, retargetingType.Interfaces().Single().SpecialType); 533Assert.Equal(SpecialType.System_ValueType, retargetingType.BaseType().SpecialType); 582Assert.Equal(SpecialType.System_Int16, sourceType.Interfaces().Single().SpecialType); 588Assert.Equal(SpecialType.System_Int16, retargetingType.Interfaces().Single().SpecialType); 651Assert.Equal(SpecialType.System_Int32, sourceTypeParameterConstraint.SpecialType); 658Assert.Equal(SpecialType.System_Int32, retargetingTypeParameterConstraint.SpecialType);
Symbols\Source\BaseClassTests.cs (2)
2033Assert.Equal(SpecialType.System_Int32, typeInfo.Type.SpecialType); 2034Assert.Equal(SpecialType.System_Int64, typeInfo.ConvertedType.SpecialType);
Symbols\Source\ClsComplianceTests.cs (14)
3157var intType = helper.GetSpecialType(SpecialType.System_Int32); 3159foreach (SpecialType st in Enum.GetValues(typeof(SpecialType))) 3163case SpecialType.None: 3164case SpecialType.System_Void: 3165case SpecialType.System_Runtime_CompilerServices_IsVolatile: // static 3166case SpecialType.System_Runtime_CompilerServices_RuntimeFeature: // static and not available 3167case SpecialType.System_Runtime_CompilerServices_PreserveBaseOverridesAttribute: // not available 3183case SpecialType.System_SByte: 3184case SpecialType.System_UInt16: 3185case SpecialType.System_UInt32: 3186case SpecialType.System_UInt64: 3187case SpecialType.System_UIntPtr: 3188case SpecialType.System_TypedReference:
Symbols\Source\CustomModifierCopyTests.cs (23)
680var baseIndexer1 = (PropertySymbol)baseClass.GetMembers().Where(IsPropertyWithSingleParameter(SpecialType.System_Int32, isArrayType: true)).Single(); 681var baseIndexer2 = (PropertySymbol)baseClass.GetMembers().Where(IsPropertyWithSingleParameter(SpecialType.System_Int64, isArrayType: true)).Single(); 684var derivedIndexer1 = (PropertySymbol)derivedClass.GetMembers().Where(IsPropertyWithSingleParameter(SpecialType.System_Int32, isArrayType: true)).Single(); 685var derivedIndexer2 = (PropertySymbol)derivedClass.GetMembers().Where(IsPropertyWithSingleParameter(SpecialType.System_Int64, isArrayType: true)).Single(); 688var derived2Indexer1 = (PropertySymbol)derived2Class.GetMembers().Where(IsPropertyWithSingleParameter(SpecialType.System_Int32, isArrayType: true)).Single(); 689var derived2Indexer2 = (PropertySymbol)derived2Class.GetMembers().Where(IsPropertyWithSingleParameter(SpecialType.System_Int64, isArrayType: true)).Single(); 778Assert.Equal(SpecialType.System_Object, interfaceMethod.ParameterTypesWithAnnotations.Single().SpecialType); 823Assert.Equal(SpecialType.System_Object, classMethod.ParameterTypesWithAnnotations.Single().SpecialType); 1260Assert.Equal(SpecialType.System_Object, classMethod.ReturnType.SpecialType); 1299Assert.Equal(SpecialType.System_Object, interfaceMethod.ReturnType.SpecialType); 1638var int8Type = comp.GetSpecialType(SpecialType.System_SByte); 1639var int16Type = comp.GetSpecialType(SpecialType.System_Int16); 1640var int32Type = comp.GetSpecialType(SpecialType.System_Int32); 1641var int64Type = comp.GetSpecialType(SpecialType.System_Int64); 1755var int8Type = comp.GetSpecialType(SpecialType.System_SByte); 1756var int16Type = comp.GetSpecialType(SpecialType.System_Int16); 1852var int8Type = comp.GetSpecialType(SpecialType.System_SByte); 1853var int16Type = comp.GetSpecialType(SpecialType.System_Int16); 1854var int32Type = comp.GetSpecialType(SpecialType.System_Int32); 1855var int64Type = comp.GetSpecialType(SpecialType.System_Int64); 1954var int8Type = comp.GetSpecialType(SpecialType.System_SByte); 1955var int16Type = comp.GetSpecialType(SpecialType.System_Int16); 1979private static Func<Symbol, bool> IsPropertyWithSingleParameter(SpecialType paramSpecialType, bool isArrayType = false)
Symbols\Source\DelegateTests.cs (4)
115Assert.Equal(comp.GetSpecialType(SpecialType.System_Object), ctor.Parameters[0].Type); 116Assert.Equal(comp.GetSpecialType(SpecialType.System_IntPtr), ctor.Parameters[1].Type); 171Assert.Equal(SpecialType.System_AsyncCallback, lastParameterType.SpecialType); 187Assert.Equal(SpecialType.System_IAsyncResult, lastParameterType.SpecialType);
Symbols\Source\EnumTests.cs (11)
81VerifyEnumsValue(comp, "Suits", SpecialType.System_Byte, null, (byte)2, null); 98VerifyEnumsValue(comp, "Suits", SpecialType.System_Int16, (short)0, (short)1, (short)2, null, null, null); 694VerifyEnumsValue(comp, "c1.COLORS", SpecialType.System_UInt32, 0u, 1u, 2u); 713VerifyEnumsValue(comp, "Figure", SpecialType.System_Int32, 0, 1, 2); 724VerifyEnumsValue(comp, "Figure", SpecialType.System_Int16, (short)0, (short)1, (short)2); 733VerifyEnumsValue(comp, "Figure", SpecialType.System_Int32, 0, 1, 2); 986Assert.Equal(SpecialType.System_Int32, type.SpecialType); 993var specialType = SpecialType.System_Int32; 998specialType = SpecialType.System_Int64; 1003private List<Symbol> VerifyEnumsValue(CSharpCompilation comp, string enumName, SpecialType underlyingType, params object[] expectedEnumValues)
Symbols\Source\ExpressionBodiedPropertyTests.cs (2)
274Assert.Equal(SpecialType.System_Int32, i.Type.SpecialType); 277Assert.Equal(SpecialType.System_Int32, i.Type.SpecialType);
Symbols\Source\MethodTests.cs (4)
1379Assert.Equal(SpecialType.System_Int32, classCBaseTypeArguments[0].SpecialType); 1380Assert.Equal(SpecialType.System_Int64, classCBaseTypeArguments[1].SpecialType); 1907Assert.Equal(SpecialType.System_Void, staticConstructor.ReturnType.SpecialType); 1931Assert.Equal(SpecialType.System_Void, staticConstructor.ReturnType.SpecialType);
Symbols\Source\ModifierTests.cs (1)
152var intType = comp.GetSpecialType(SpecialType.System_Int32);
Symbols\Source\NullablePublicAPITests.cs (3)
2638Assert.Equal(SpecialType.System_String, symbol.Type.SpecialType); 4219Assert.Equal(SpecialType.System_String, ((IFieldSymbol)symbolInfo.Symbol).Type.SpecialType); 4249Assert.Equal(SpecialType.System_String, symbolInfo.Type.SpecialType);
Symbols\Source\PropertyTests.cs (20)
1883Assert.True(getters.Any(getter => getter.Parameters[0].Type.SpecialType == SpecialType.System_Int32)); 1884Assert.True(getters.Any(getter => getter.Parameters[0].Type.SpecialType == SpecialType.System_String)); 1887getter.Parameters[0].Type.SpecialType == SpecialType.System_Int32 && 1888getter.Parameters[1].Type.SpecialType == SpecialType.System_String)); 2624Assert.Equal(SpecialType.System_String, iap2.Type.SpecialType); 2626Assert.Equal(SpecialType.System_String, iam2.ReturnType.SpecialType); 2642Assert.Equal(SpecialType.System_String, iap2.Type.SpecialType); 2644Assert.Equal(SpecialType.System_String, iam2.ReturnType.SpecialType); 2660Assert.Equal(SpecialType.System_String, iap2.Type.SpecialType); 2662Assert.Equal(SpecialType.System_String, iam2.ReturnType.SpecialType); 2678Assert.Equal(SpecialType.System_String, iap2.Type.SpecialType); 2680Assert.Equal(SpecialType.System_String, iam2.ReturnType.SpecialType); 2712Assert.Equal(SpecialType.System_Object, iap.Type.SpecialType); 2714Assert.Equal(SpecialType.System_Object, iam.ReturnType.SpecialType); 2717Assert.Equal(SpecialType.System_String, iap2.Type.SpecialType); 2719Assert.Equal(SpecialType.System_String, iam2.ReturnType.SpecialType); 2730Assert.Equal(SpecialType.System_Object, iap.Type.SpecialType); 2732Assert.Equal(SpecialType.System_Object, iam.ReturnType.SpecialType); 2735Assert.Equal(SpecialType.System_String, iap2.Type.SpecialType); 2737Assert.Equal(SpecialType.System_String, iam2.ReturnType.SpecialType);
Symbols\Source\RecordTests.cs (10)
36Assert.Equal(SpecialType.System_Int32, x.Type.SpecialType); 40Assert.Equal(SpecialType.System_String, y.Type.SpecialType); 56Assert.Equal(SpecialType.System_Int32, x.Type.SpecialType); 88Assert.Equal(SpecialType.System_Int32, a.Type.SpecialType); 92Assert.Equal(SpecialType.System_String, b.Type.SpecialType); 121Assert.Equal(SpecialType.System_Int32, p1.Type.SpecialType); 127Assert.Equal(SpecialType.System_String, p2.Type.SpecialType); 133Assert.Equal(SpecialType.System_Int32, p2.Type.SpecialType); 154Assert.Equal(SpecialType.System_Int32, x.Type.SpecialType); 188Assert.Equal(SpecialType.System_Int32, y.Type.SpecialType);
Symbols\Source\TypeMapTests.cs (7)
117Assert.Equal(SpecialType.System_Int32, neti.TypeArguments()[0].SpecialType); 137var _int = compilation.GetSpecialType(SpecialType.System_Int32); 138var _byte = compilation.GetSpecialType(SpecialType.System_Byte); 139var _char = compilation.GetSpecialType(SpecialType.System_Char); 179var _int = compilation.GetSpecialType(SpecialType.System_Int32); 180var _byte = compilation.GetSpecialType(SpecialType.System_Byte); 181var _char = compilation.GetSpecialType(SpecialType.System_Char);
Symbols\Source\UsingAliasTests.cs (2)
105Assert.Equal(SpecialType.System_Object, usingAliasType.SpecialType); 220Assert.Equal(SpecialType.System_Object, usingAliasType.SpecialType);
Symbols\SymbolDistinguisherTests.cs (2)
315var errorType = dummyComp.GetSpecialType(SpecialType.System_Int32); 316var validType = CreateEmptyCompilation("", new[] { MscorlibRef }).GetSpecialType(SpecialType.System_Int32);
Symbols\TypedConstantTests.cs (7)
34_arrayType = _compilation.CreateArrayTypeSymbol(_compilation.GetSpecialType(SpecialType.System_Object)); 35_intType = _compilation.GetSpecialType(SpecialType.System_Int32); 36_stringType = _compilation.GetSpecialType(SpecialType.System_String); 37_enumString1 = _compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(_compilation.GetSpecialType(SpecialType.System_String)); 38_enumString2 = _compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(_compilation.GetSpecialType(SpecialType.System_String));
Symbols\TypeResolutionTests.cs (1)
127Assert.Equal(SpecialType.System_Int32, intSym.SpecialType);
Symbols\TypeTests.cs (26)
1253Assert.Equal(SpecialType.System_Object, typeC.BaseType().SpecialType); 1328if (derived.BaseType().SpecialType != SpecialType.System_Object) 1342Assert.Equal(SpecialType.System_Object, derivedTypes[1].BaseType().SpecialType); 1352Assert.Equal(SpecialType.System_Object, derivedTypes[4].BaseType().SpecialType); 1480Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), varX.Type.OriginalDefinition); 1507Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), memType.OriginalDefinition); 1512Assert.Same(comp.GetSpecialType(SpecialType.System_SByte), underType); 1520Assert.Same(comp.GetSpecialType(SpecialType.System_Byte), underType); 1525Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), memType.OriginalDefinition); 1529Assert.Same(comp.GetSpecialType(SpecialType.System_Char), underType); 1539Assert.Same(comp.GetSpecialType(SpecialType.System_Int16), underType); 1544Assert.Same(comp.GetSpecialType(SpecialType.System_UInt16), memType.GetNullableUnderlyingType()); 1546Assert.Same(comp.GetSpecialType(SpecialType.System_UInt32), memType.GetNullableUnderlyingType()); 1550Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), memType.OriginalDefinition); 1553Assert.Same(comp.GetSpecialType(SpecialType.System_Int32), underType); 1560Assert.Same(comp.GetSpecialType(SpecialType.System_Int64), memType.GetNullableUnderlyingType()); 1562Assert.Same(comp.GetSpecialType(SpecialType.System_UInt64), memType.GetNullableUnderlyingType()); 1569Assert.Same(comp.GetSpecialType(SpecialType.System_Decimal), underType); 1576Assert.Same(comp.GetSpecialType(SpecialType.System_Double), memType.GetNullableUnderlyingType()); 1579Assert.Same(comp.GetSpecialType(SpecialType.System_Single), (memType as ArrayTypeSymbol).ElementType.GetNullableUnderlyingType()); 1616Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), memType.OriginalDefinition); 1641Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), memType.OriginalDefinition); 1688Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), memType.OriginalDefinition); 1704Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), memType.OriginalDefinition); 1766Assert.Same(comp.GetSpecialType(SpecialType.System_Nullable_T), memType.OriginalDefinition); 1782Assert.Same(comp.GetSpecialType(SpecialType.System_Decimal), ((ITypeSymbol)tinfo.ConvertedType).GetNullableUnderlyingType());
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (1)
Diagnostics\DiagnosticTest.cs (1)
113var type = TypeWithAnnotations.Create(comp.GetSpecialType(SpecialType.System_Object));
Microsoft.CodeAnalysis.CSharp.Test.Utilities (4)
Extensions.cs (2)
537Assert.Equal(SpecialType.System_Void, accessor.ReturnType.SpecialType); 547Assert.Equal(SpecialType.System_Void, accessor.ReturnType.SpecialType);
FunctionPointerUtilities.cs (1)
332public static Action<TypeSymbol> IsSpecialType(SpecialType specialType)
MetadataTestHelpers.cs (1)
16internal static NamedTypeSymbol GetCorLibType(this ModuleSymbol module, SpecialType typeId)
Microsoft.CodeAnalysis.CSharp.WinRT.UnitTests (3)
CodeGen\WinMdEventTests.cs (1)
672Assert.Equal(SpecialType.System_Void, type.Type.SpecialType);
Metadata\WinMdEventTests.cs (2)
3576var voidType = compilation.GetSpecialType(SpecialType.System_Void); 3607var voidType = compilation.GetSpecialType(SpecialType.System_Void);
Microsoft.CodeAnalysis.CSharp.Workspaces (237)
CastSimplifier.cs (9)
92Parent.Parent: IConversionOperation { Type.SpecialType: SpecialType.System_Object } conversionOperation 470if (castNode.IsParentKind(SyntaxKind.Interpolation) && originalConversionOperation.Type?.SpecialType is SpecialType.System_Object) 579if (current.ContainingType.SpecialType == SpecialType.System_Object) 675=> type.IsSignedIntegralType() || type?.SpecialType is SpecialType.System_IntPtr; 769if (binaryOperation.LeftOperand.Type?.SpecialType == SpecialType.System_Object && 776else if (binaryOperation.RightOperand.Type?.SpecialType == SpecialType.System_Object && 959=> type?.SpecialType is SpecialType.System_Double or SpecialType.System_Single; 1217rewrittenType.SpecialType == SpecialType.System_Enum;
CodeGeneration\CSharpSyntaxGenerator.cs (28)
3258case SpecialType.System_Boolean: 3260case SpecialType.System_SByte: 3261case SpecialType.System_Byte: 3262case SpecialType.System_Int16: 3263case SpecialType.System_UInt16: 3264case SpecialType.System_Int32: 3265case SpecialType.System_UInt32: 3266case SpecialType.System_Int64: 3267case SpecialType.System_UInt64: 3268case SpecialType.System_Decimal: 3269case SpecialType.System_Single: 3270case SpecialType.System_Double: 3443public override SyntaxNode TypeExpression(SpecialType specialType) 3446SpecialType.System_Boolean => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.BoolKeyword)), 3447SpecialType.System_Byte => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.ByteKeyword)), 3448SpecialType.System_Char => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.CharKeyword)), 3449SpecialType.System_Decimal => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.DecimalKeyword)), 3450SpecialType.System_Double => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.DoubleKeyword)), 3451SpecialType.System_Int16 => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.ShortKeyword)), 3452SpecialType.System_Int32 => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.IntKeyword)), 3453SpecialType.System_Int64 => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.LongKeyword)), 3454SpecialType.System_Object => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.ObjectKeyword)), 3455SpecialType.System_SByte => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.SByteKeyword)), 3456SpecialType.System_Single => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.FloatKeyword)), 3457SpecialType.System_String => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.StringKeyword)), 3458SpecialType.System_UInt16 => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.UShortKeyword)), 3459SpecialType.System_UInt32 => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.UIntKeyword)), 3460SpecialType.System_UInt64 => SyntaxFactory.PredefinedType(SyntaxFactory.Token(SyntaxKind.ULongKeyword)),
CSharpFlagsEnumGenerator.cs (1)
22SpecialType underlyingSpecialType,
CSharpTypeInferenceService.TypeInferrer.cs (35)
581return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 842return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 972return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 982return CreateResult(SpecialType.System_Boolean); 1037if (parentTypes.Any(static parentType => parentType.InferredType.SpecialType == SpecialType.System_String || parentType.InferredType.TypeKind == TypeKind.Delegate)) 1039return parentTypes.Where(parentType => parentType.InferredType.SpecialType == SpecialType.System_String || parentType.InferredType.TypeKind == TypeKind.Delegate); 1070return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 1077return CreateResult(SpecialType.System_Boolean); 1118return CreateResult(SpecialType.System_Boolean); 1141return CreateResult(SpecialType.System_Object, NullableAnnotation.Annotated); 1155else if (symbol.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T) 1162return compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(symbol); 1183return CreateResult(SpecialType.System_Boolean); 1219return CreateResult(SpecialType.System_Boolean); 1260return CreateResult(SpecialType.System_Void); 1277? this.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 1280enumerableType ??= this.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T); 1288.Construct(Compilation.GetSpecialType(SpecialType.System_Object))); 1307return CreateResult(SpecialType.System_Boolean); 1318return CreateResult(SpecialType.System_Boolean); 1631return CreateResult(SpecialType.System_Object); 1936return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 1954return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 1961return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 1970return CreateResult(SpecialType.System_Boolean); 2019return types.Select(t => t.InferredType.SpecialType == SpecialType.System_Void ? new TypeInferenceInfo(task) : new TypeInferenceInfo(taskOfT.Construct(t.InferredType))); 2057return this.Compilation.GetSpecialType(SpecialType.System_Void); 2189return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 2222return CreateResult(SpecialType.System_IDisposable); 2246return CreateResult(SpecialType.System_IDisposable); 2250return CreateResult(this.Compilation.GetSpecialType(SpecialType.System_Int32)); 2253if (laterUsageInference is not [] and not [{ InferredType.SpecialType: SpecialType.System_Object }]) 2282if (inferredDescendantTypes is not [] and not [{ InferredType.SpecialType: SpecialType.System_Object }]) 2434return SpecializedCollections.SingletonEnumerable(new TypeInferenceInfo(Compilation.GetSpecialType(SpecialType.System_Boolean))); 2445return CreateResult(SpecialType.System_Boolean);
ExpressionGenerator.cs (6)
125var isNotSingle = !IsSpecialType(type, SpecialType.System_Single); 136if (value is double && !IsSpecialType(type, SpecialType.System_Double)) 141if (value is uint && !IsSpecialType(type, SpecialType.System_UInt32)) 146if (value is long && !IsSpecialType(type, SpecialType.System_Int64)) 151if (value is ulong && !IsSpecialType(type, SpecialType.System_UInt64)) 160var isNotDecimal = !IsSpecialType(type, SpecialType.System_Decimal);
InternalExtensions.cs (1)
36if (typeInfo.Type != null && typeInfo.Type.SpecialType == SpecialType.System_Void)
ITypeParameterSymbolExtensions.cs (1)
64if (type.SpecialType != SpecialType.System_Object)
ITypeSymbolExtensions.TypeSyntaxGeneratorVisitor.cs (2)
117syntax = SyntaxFactory.IdentifierName(symbol.SpecialType == SpecialType.System_IntPtr ? "nint" : "nuint"); 221if (symbol.SpecialType == SpecialType.System_Void)
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Extensions\ITypeSymbolExtensions.cs\ITypeSymbolExtensions.cs (13)
13case SpecialType.System_Boolean: 14case SpecialType.System_Char: 15case SpecialType.System_SByte: 16case SpecialType.System_Int16: 17case SpecialType.System_Int32: 18case SpecialType.System_Int64: 19case SpecialType.System_Byte: 20case SpecialType.System_UInt16: 21case SpecialType.System_UInt32: 22case SpecialType.System_UInt64: 23case SpecialType.System_Single: 24case SpecialType.System_Double: 27case SpecialType.System_Decimal:
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Workspace\CSharp\Extensions\ExpressionSyntaxExtensions.cs\ExpressionSyntaxExtensions.cs (1)
114targetType = semanticModel.Compilation.GetSpecialType(SpecialType.System_Object);
NamedTypeGenerator.cs (2)
245var baseList = namedType.EnumUnderlyingType != null && namedType.EnumUnderlyingType.SpecialType != SpecialType.System_Int32 324if (namedType.TypeKind == TypeKind.Class && namedType.BaseType != null && namedType.BaseType.SpecialType != Microsoft.CodeAnalysis.SpecialType.System_Object)
Recommendations\CSharpRecommendationServiceRunner.cs (2)
526namedSymbols = namedSymbols.RemoveAll(s => s.ContainingType.SpecialType is SpecialType.System_Object or SpecialType.System_ValueType);
Recommendations\CSharpRecommendationServiceRunner_Conversions.cs (109)
20private static readonly ImmutableArray<SpecialType> s_predefinedEnumConversionTargets = ImmutableArray.Create( 21SpecialType.System_Byte, 22SpecialType.System_Char, 23SpecialType.System_Decimal, 24SpecialType.System_Double, 25SpecialType.System_Single, 26SpecialType.System_Int32, 27SpecialType.System_Int64, 28SpecialType.System_SByte, 29SpecialType.System_Int16, 30SpecialType.System_UInt32, 31SpecialType.System_UInt64, 32SpecialType.System_UInt16); 34private static readonly ImmutableArray<SpecialType> s_sbyteConversions = ImmutableArray.Create( 35SpecialType.System_Byte, 36SpecialType.System_Char, 37SpecialType.System_UInt32, 38SpecialType.System_UInt64, 39SpecialType.System_UInt16); 41private static readonly ImmutableArray<SpecialType> s_byteConversions = ImmutableArray.Create( 42SpecialType.System_Char, 43SpecialType.System_SByte); 45private static readonly ImmutableArray<SpecialType> s_int16Conversions = ImmutableArray.Create( 46SpecialType.System_Byte, 47SpecialType.System_Char, 48SpecialType.System_UInt32, 49SpecialType.System_UInt64, 50SpecialType.System_UInt16, 51SpecialType.System_SByte); 53private static readonly ImmutableArray<SpecialType> s_uint16Conversions = ImmutableArray.Create( 54SpecialType.System_Byte, 55SpecialType.System_Char, 56SpecialType.System_SByte, 57SpecialType.System_Int16); 59private static readonly ImmutableArray<SpecialType> s_int32Conversions = ImmutableArray.Create( 60SpecialType.System_Byte, 61SpecialType.System_Char, 62SpecialType.System_SByte, 63SpecialType.System_Int16, 64SpecialType.System_UInt32, 65SpecialType.System_UInt16, 66SpecialType.System_UInt64); 68private static readonly ImmutableArray<SpecialType> s_uint32Conversions = ImmutableArray.Create( 69SpecialType.System_Byte, 70SpecialType.System_Char, 71SpecialType.System_Int32, 72SpecialType.System_SByte, 73SpecialType.System_Int16, 74SpecialType.System_UInt16); 76private static readonly ImmutableArray<SpecialType> s_int64Conversions = ImmutableArray.Create( 77SpecialType.System_Byte, 78SpecialType.System_Char, 79SpecialType.System_Int32, 80SpecialType.System_UInt32, 81SpecialType.System_UInt64, 82SpecialType.System_UInt16, 83SpecialType.System_SByte, 84SpecialType.System_Int16); 86private static readonly ImmutableArray<SpecialType> s_uint64Conversions = ImmutableArray.Create( 87SpecialType.System_Byte, 88SpecialType.System_Char, 89SpecialType.System_Int32, 90SpecialType.System_Int64, 91SpecialType.System_UInt32, 92SpecialType.System_UInt16, 93SpecialType.System_SByte, 94SpecialType.System_Int16); 96private static readonly ImmutableArray<SpecialType> s_charConversions = ImmutableArray.Create( 97SpecialType.System_Byte, 98SpecialType.System_SByte, 99SpecialType.System_Int16); 101private static readonly ImmutableArray<SpecialType> s_singleConversions = ImmutableArray.Create( 102SpecialType.System_Byte, 103SpecialType.System_Char, 104SpecialType.System_Decimal, 105SpecialType.System_Int32, 106SpecialType.System_Int64, 107SpecialType.System_UInt32, 108SpecialType.System_UInt64, 109SpecialType.System_UInt16, 110SpecialType.System_SByte, 111SpecialType.System_Int16); 113private static readonly ImmutableArray<SpecialType> s_doubleConversions = ImmutableArray.Create( 114SpecialType.System_Byte, 115SpecialType.System_Char, 116SpecialType.System_Decimal, 117SpecialType.System_Single, 118SpecialType.System_Int32, 119SpecialType.System_Int64, 120SpecialType.System_UInt32, 121SpecialType.System_UInt64, 122SpecialType.System_UInt16, 123SpecialType.System_SByte, 124SpecialType.System_Int16); 139? compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(container) 201public static ImmutableArray<SpecialType>? GetPredefinedNumericConversions(ITypeSymbol container) 204SpecialType.System_SByte => s_sbyteConversions, 205SpecialType.System_Byte => s_byteConversions, 206SpecialType.System_Int16 => s_int16Conversions, 207SpecialType.System_UInt16 => s_uint16Conversions, 208SpecialType.System_Int32 => s_int32Conversions, 209SpecialType.System_UInt32 => s_uint32Conversions, 210SpecialType.System_Int64 => s_int64Conversions, 211SpecialType.System_UInt64 => s_uint64Conversions, 212SpecialType.System_Char => s_charConversions, 213SpecialType.System_Single => s_singleConversions, 214SpecialType.System_Double => s_doubleConversions, 220ITypeSymbol container, INamedTypeSymbol containerWithoutNullable, ArrayBuilder<ISymbol> symbols, ImmutableArray<SpecialType> specialTypes) 224foreach (var specialType in specialTypes)
Recommendations\CSharpRecommendationServiceRunner_Operators.cs (3)
55=> container.IsSpecialType() || container.SpecialType is SpecialType.System_IntPtr or SpecialType.System_UIntPtr; 96return symbol.Parameters.Length == 2 && symbol.ReturnType.SpecialType == SpecialType.System_Boolean;
Rename\CSharpRenameRewriterLanguageService.cs (1)
1066if (!method.ReturnsVoid && !method.Parameters.Any() && method.ReturnType.SpecialType == SpecialType.System_Boolean)
Simplification\Simplifiers\AbstractCSharpSimplifier.cs (23)
35/// Returns the predefined keyword kind for a given <see cref="SpecialType"/>. 37/// <param name="specialType">The <see cref="SpecialType"/> of this type.</param> 39protected static SyntaxToken? TryGetPredefinedKeywordToken(SemanticModel semanticModel, SpecialType specialType) 43SpecialType.System_Boolean => SyntaxKind.BoolKeyword, 44SpecialType.System_Byte => SyntaxKind.ByteKeyword, 45SpecialType.System_SByte => SyntaxKind.SByteKeyword, 46SpecialType.System_Int32 => SyntaxKind.IntKeyword, 47SpecialType.System_UInt32 => SyntaxKind.UIntKeyword, 48SpecialType.System_Int16 => SyntaxKind.ShortKeyword, 49SpecialType.System_UInt16 => SyntaxKind.UShortKeyword, 50SpecialType.System_Int64 => SyntaxKind.LongKeyword, 51SpecialType.System_UInt64 => SyntaxKind.ULongKeyword, 52SpecialType.System_Single => SyntaxKind.FloatKeyword, 53SpecialType.System_Double => SyntaxKind.DoubleKeyword, 54SpecialType.System_Decimal => SyntaxKind.DecimalKeyword, 55SpecialType.System_String => SyntaxKind.StringKeyword, 56SpecialType.System_Char => SyntaxKind.CharKeyword, 57SpecialType.System_Object => SyntaxKind.ObjectKeyword, 58SpecialType.System_Void => SyntaxKind.VoidKeyword, 65if (specialType is SpecialType.System_IntPtr or SpecialType.System_UIntPtr && 69return SyntaxFactory.Identifier(specialType == SpecialType.System_IntPtr ? "nint" : "nuint"); 393semanticModel.GetTypeInfo(invocationExpr).Type.SpecialType == SpecialType.System_String;
Microsoft.CodeAnalysis.CSharp.Workspaces.UnitTests (28)
CodeGeneration\SyntaxGeneratorTests.cs (28)
278var intType = _emptyCompilation.GetSpecialType(SpecialType.System_Int32); 291VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Byte), "byte"); 292VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_SByte), "sbyte"); 294VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Int16), "short"); 295VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_UInt16), "ushort"); 297VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Int32), "int"); 298VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_UInt32), "uint"); 300VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Int64), "long"); 301VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_UInt64), "ulong"); 303VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Single), "float"); 304VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Double), "double"); 306VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Char), "char"); 307VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_String), "string"); 309VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Object), "object"); 310VerifySyntax<TypeSyntax>(Generator.TypeExpression(SpecialType.System_Decimal), "decimal"); 316var genericType = _emptyCompilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T); 319var arrayType = _emptyCompilation.CreateArrayTypeSymbol(_emptyCompilation.GetSpecialType(SpecialType.System_Int32)); 406var intType = _emptyCompilation.GetSpecialType(SpecialType.System_Int32); 782Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32)), 786Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32), initializer: Generator.LiteralExpression(0)), 790Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32), accessibility: Accessibility.Public), 794Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32), accessibility: Accessibility.NotApplicable, modifiers: DeclarationModifiers.Static | DeclarationModifiers.ReadOnly), 798Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32), accessibility: Accessibility.NotApplicable, modifiers: DeclarationModifiers.Required), 855_emptyCompilation.GetSpecialType(SpecialType.System_Int32), 856_emptyCompilation.GetSpecialType(SpecialType.System_String) 859var returnType = Generator.TypeExpression(SpecialType.System_Boolean); 983var doubleType = _emptyCompilation.GetSpecialType(SpecialType.System_Decimal); 985m.Name == WellKnownMemberNames.ImplicitConversionName && m.Parameters[0].Type.Equals(_emptyCompilation.GetSpecialType(SpecialType.System_Byte)));
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (2)
CodeGeneration\CodeGenerationTests.cs (2)
522SpecialType specialType = SpecialType.None,
Microsoft.CodeAnalysis.ExpressionEvaluator.ExpressionCompiler (19)
PDB\PdbHelpers.cs (19)
89(SpecialType.System_Boolean, short shortVal) => ConstantValue.Create(shortVal != 0), 90(SpecialType.System_Byte, short shortVal) when unchecked((byte)shortVal) == shortVal => ConstantValue.Create((byte)shortVal), 91(SpecialType.System_SByte, short shortVal) when unchecked((sbyte)shortVal) == shortVal => ConstantValue.Create((sbyte)shortVal), 92(SpecialType.System_Int16, short shortVal) => ConstantValue.Create(shortVal), 93(SpecialType.System_Char, ushort ushortVal) => ConstantValue.Create((char)ushortVal), 94(SpecialType.System_UInt16, ushort ushortVal) => ConstantValue.Create(ushortVal), 95(SpecialType.System_Int32, int intVal) => ConstantValue.Create(intVal), 96(SpecialType.System_UInt32, uint uintVal) => ConstantValue.Create(uintVal), 97(SpecialType.System_Int64, long longVal) => ConstantValue.Create(longVal), 98(SpecialType.System_UInt64, ulong ulongVal) => ConstantValue.Create(ulongVal), 99(SpecialType.System_Single, float floatVal) => ConstantValue.Create(floatVal), 100(SpecialType.System_Double, double doubleVal) => ConstantValue.Create(doubleVal), 101(SpecialType.System_String, 0) => ConstantValue.Null, 102(SpecialType.System_String, null) => ConstantValue.Create(string.Empty), 103(SpecialType.System_String, string str) => ConstantValue.Create(str), 104(SpecialType.System_Object, 0) => ConstantValue.Null, 105(SpecialType.System_Decimal, decimal decimalValue) => ConstantValue.Create(decimalValue), 106(SpecialType.System_DateTime, double doubleVal) => ConstantValue.Create(DateTimeUtilities.ToDateTime(doubleVal)), 107(SpecialType.None, 0) when type.IsReferenceType => ConstantValue.Null,
Microsoft.CodeAnalysis.Features (112)
AbstractForEachCastDiagnosticAnalyzer.cs (1)
141=> collectionElementType.SpecialType != SpecialType.System_Object ||
AbstractPopulateSwitchDiagnosticAnalyzer.cs (1)
97if (type is not { SpecialType: SpecialType.System_Boolean })
AbstractRemoveRedundantEqualityDiagnosticAnalyzer.cs (2)
60if (rightOperand.Type.SpecialType != SpecialType.System_Boolean || 61leftOperand.Type.SpecialType != SpecialType.System_Boolean)
AbstractRemoveUnnecessaryPragmaSuppressionsDiagnosticAnalyzer.cs (2)
827attribute.AttributeConstructor?.Parameters is [_, { Name: "checkId", Type.SpecialType: SpecialType.System_String }, ..] && 836attribute.AttributeConstructor.Parameters[0].Type.SpecialType == SpecialType.System_String &&
AbstractRemoveUnusedMembersDiagnosticAnalyzer.cs (2)
590attribute.ConstructorArguments is [{ Kind: TypedConstantKind.Primitive, Type.SpecialType: SpecialType.System_String, Value: string value }]) 728(IsSpecialMethodWithMatchingProperty("ShouldSerialize") && methodSymbol.ReturnType.SpecialType == SpecialType.System_Boolean ||
AbstractRemoveUnusedParametersAndValuesDiagnosticAnalyzer.SymbolStartAnalyzer.BlockAnalyzer.cs (1)
144value.Type.SpecialType == SpecialType.System_Void)
AbstractRemoveUnusedParametersAndValuesDiagnosticAnalyzer.SymbolStartAnalyzer.cs (2)
241method.Parameters is [{ Type.SpecialType: SpecialType.System_Object }, var secondParam] && 280methodSymbol.Parameters[0].Type.SpecialType == SpecialType.System_String &&
AbstractSimplifyConditionalDiagnosticAnalyzer.cs (2)
154typeInfo.Type?.SpecialType == SpecialType.System_Boolean && 155typeInfo.ConvertedType?.SpecialType == SpecialType.System_Boolean;
AbstractSimplifyInterpolationHelpers.cs (1)
127return method.ContainingType.SpecialType == SpecialType.System_Object
AbstractUseIsNullForReferenceEqualsDiagnosticAnalyzer.cs (1)
34var objectType = context.Compilation.GetSpecialType(SpecialType.System_Object);
AbstractUseNullPropagationDiagnosticAnalyzer.cs (4)
86var objectType = context.Compilation.GetSpecialType(SpecialType.System_Object); 154if (type is not INamedTypeSymbol namedType || namedType.ConstructedFrom.SpecialType != SpecialType.System_Nullable_T) 182var whenPartIsNullable = whenPartType?.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T; 360if (typeSymbol?.SpecialType == SpecialType.System_Object)
AbstractUseNullPropagationDiagnosticAnalyzer_IfStatement.cs (1)
89var whenPartIsNullable = semanticModel.GetTypeInfo(whenPartMatch).Type?.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T;
AbstractValidateFormatStringDiagnosticAnalyzer.cs (1)
303if (containingType.SpecialType != SpecialType.System_String)
AddDebuggerDisplay\AbstractAddDebuggerDisplayCodeRefactoringProvider.cs (1)
166returnType: generator.TypeExpression(SpecialType.System_String),
Completion\Providers\AbstractObjectCreationCompletionProvider.cs (2)
68if (type.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T) 71if (type.SpecialType == SpecialType.System_Void)
Completion\Providers\AbstractRecommendationServiceBasedCompletionProvider.cs (1)
58var inferredTypes = context.InferredTypes.Where(t => t.SpecialType != SpecialType.System_Void).ToSet();
Completion\Providers\AbstractSymbolCompletionProvider.cs (1)
65if (symbol.ContainingType?.SpecialType == SpecialType.System_Object)
ConvertCast\AbstractConvertCastCodeRefactoringProvider.cs (1)
55if (type is { IsReferenceType: true } or { OriginalDefinition.SpecialType: SpecialType.System_Nullable_T })
ConvertForEachToFor\AbstractConvertForEachToForCodeRefactoringProvider.cs (2)
239if (collectionType.SpecialType == SpecialType.System_String) 241var charType = model.Compilation.GetSpecialType(SpecialType.System_Char);
ConvertForToForEach\AbstractConvertForToForEachCodeRefactoringProvider.cs (5)
112var ienumerableType = semanticModel.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T); 113var ienumeratorType = semanticModel.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerator_T); 345var indexerType = GetIndexerType(containingType, collectionType, semanticModel.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T)); 349indexerType ?? semanticModel.Compilation.GetSpecialType(SpecialType.System_Object)); 534=> property is { IsIndexer: true, Parameters: [{ Type.SpecialType: SpecialType.System_Int32 }] };
ConvertNumericLiteral\AbstractConvertNumericLiteralCodeRefactoringProvider.cs (9)
151private static bool IsIntegral(SpecialType specialType) 155case SpecialType.System_Byte: 156case SpecialType.System_SByte: 157case SpecialType.System_Int16: 158case SpecialType.System_UInt16: 159case SpecialType.System_Int32: 160case SpecialType.System_UInt32: 161case SpecialType.System_Int64: 162case SpecialType.System_UInt64:
ConvertToInterpolatedString\AbstractConvertConcatenationToInterpolatedStringRefactoringProvider.cs (1)
251method.ContainingType?.SpecialType == SpecialType.System_String &&
ConvertToInterpolatedString\AbstractConvertPlaceholderToInterpolatedStringRefactoringProvider.cs (2)
45var stringType = semanticModel.Compilation.GetSpecialType(SpecialType.System_String); 103var shouldReplaceInvocation = invocationSymbol is { ContainingType.SpecialType: SpecialType.System_String, Name: nameof(string.Format) };
ConvertTupleToStruct\AbstractConvertTupleToStructCodeRefactoringProvider.cs (1)
861model.Compilation.GetSpecialType(SpecialType.System_Void),
DesignerAttribute\DesignerAttributeDiscoveryService.cs (1)
262if (attribute is { ConstructorArguments: [{ Type.SpecialType: SpecialType.System_String, Value: string stringValue }] })
EmbeddedLanguages\EmbeddedLanguageDetector.cs (1)
170m => m is IMethodSymbol { Parameters: [{ Type.SpecialType: SpecialType.System_String }, ..] });
ExtractClass\AbstractExtractClassRefactoringProvider.cs (1)
147private static bool HasBaseType(INamedTypeSymbol containingType) => containingType.BaseType?.SpecialType != SpecialType.System_Object;
ExtractMethod\MethodExtractor.Analyzer.cs (5)
187returnType = model.Compilation.GetSpecialType(SpecialType.System_Void); 208if (taskType is object && returnType.Equals(model.Compilation.GetSpecialType(SpecialType.System_Void))) 244var returnType = SelectionResult.GetContainingScopeType() ?? compilation.GetSpecialType(SpecialType.System_Object); 256: compilation.GetSpecialType(SpecialType.System_Void); 621return type.OriginalDefinition.SpecialType == SpecialType.None && !WellKnownFrameworkValueType(compilation, type);
ExtractMethod\MethodExtractor.AnalyzerResult.cs (1)
144return ReturnType.SpecialType != SpecialType.System_Void && !AwaitTaskReturn;
ExtractMethod\MethodExtractor.CodeGenerator.cs (1)
207if (type != null && type.SpecialType != SpecialType.System_Void)
GenerateComparisonOperators\GenerateComparisonOperatorsCodeRefactoringProvider.cs (1)
185var boolType = compilation.GetSpecialType(SpecialType.System_Boolean);
GenerateEqualsAndGetHashCodeFromMembers\AbstractGenerateEqualsAndGetHashCodeService.cs (1)
140returnType: compilation.GetSpecialType(SpecialType.System_Int32),
GenerateEqualsAndGetHashCodeFromMembers\GenerateEqualsAndGetHashCodeAction.cs (2)
181compilation.GetSpecialType(SpecialType.System_Boolean), 198compilation.GetSpecialType(SpecialType.System_Boolean),
GenerateMember\GenerateConstructor\AbstractGenerateConstructorService.State.cs (9)
378case SpecialType.System_Boolean: 379case SpecialType.System_Byte: 380case SpecialType.System_Char: 381case SpecialType.System_Int16: 382case SpecialType.System_Int32: 383case SpecialType.System_Int64: 384case SpecialType.System_Double: 385case SpecialType.System_Single: 386case SpecialType.System_String:
GenerateMember\GenerateParameterizedMember\AbstractGenerateDeconstructMethodService.State.cs (1)
80returnType: semanticModel.Compilation.GetSpecialType(SpecialType.System_Void),
GenerateMember\GenerateParameterizedMember\AbstractGenerateParameterizedMemberService.cs (1)
65if (typeParameters.Length == 0 && returnType.SpecialType != SpecialType.System_Void)
GenerateMember\GenerateVariable\AbstractGenerateVariableService.State.cs (1)
450inferredType = inferredType.SpecialType == SpecialType.System_Void
GenerateType\AbstractGenerateTypeService.GenerateNamedType.cs (1)
75return _state.Compilation.GetSpecialType(SpecialType.System_Void);
GenerateType\AbstractGenerateTypeService.State.cs (6)
251SpecialType.System_Object or 252SpecialType.System_Array or 253SpecialType.System_Delegate or 254SpecialType.System_MulticastDelegate or 255SpecialType.System_ValueType or 256SpecialType.System_Enum)
HashCodeAnalyzer.cs (1)
38var objectType = compilation.GetSpecialType(SpecialType.System_Object);
ImplementInterface\AbstractImplementInterfaceService.CodeAction.cs (1)
387var condition3 = typeParameter.HasReferenceTypeConstraint && typeParameter.ConstraintTypes.Any(static ts => ts.IsReferenceType && ts.SpecialType != SpecialType.System_Object);
ImplementInterface\AbstractImplementInterfaceService.DisposePatternCodeAction.cs (3)
42var idisposable = compilation.GetSpecialType(SpecialType.System_IDisposable); 271compilation.GetSpecialType(SpecialType.System_Boolean), 357var boolType = compilation.GetSpecialType(SpecialType.System_Boolean);
InheritanceMargin\AbstractInheritanceMarginService_Helpers.cs (3)
288.WhereAsArray(symbol => !symbol.IsErrorType() && symbol.SpecialType is not (SpecialType.System_Object or SpecialType.System_ValueType or SpecialType.System_Enum));
InitializeParameter\AbstractAddParameterCheckCodeRefactoringProvider.cs (5)
108if (parameter.Type.SpecialType == SpecialType.System_String) 161if (parameter.Type.SpecialType == SpecialType.System_String) 235else if (parameter.Type.SpecialType == SpecialType.System_String && 303return targetMethod.ContainingType.SpecialType == SpecialType.System_String; 393var stringType = compilation.GetSpecialType(SpecialType.System_String);
InlineHints\AbstractInlineParameterNameHintsService.cs (1)
239return parameter.Type.SpecialType == SpecialType.System_Boolean;
IntroduceUsingStatement\AbstractIntroduceUsingStatementCodeRefactoringProvider.cs (1)
70var disposableType = semanticModel.Compilation.GetSpecialType(SpecialType.System_IDisposable);
IntroduceVariable\AbstractIntroduceLocalForExpressionCodeRefactoringProvider.cs (1)
46type.SpecialType == SpecialType.System_Void)
IntroduceVariable\AbstractIntroduceVariableService.AbstractIntroduceVariableCodeAction.cs (1)
114return typeInfo.Type ?? typeInfo.ConvertedType ?? semanticModel.Compilation.GetSpecialType(SpecialType.System_Object);
IntroduceVariable\AbstractIntroduceVariableService.cs (2)
413if (typeInfo.Type?.SpecialType == SpecialType.System_String && 431return semanticModel.Compilation.GetSpecialType(SpecialType.System_Object);
IntroduceVariable\AbstractIntroduceVariableService.State_Block.cs (1)
33if (type == null || type.SpecialType == SpecialType.System_Void)
IntroduceVariable\AbstractIntroduceVariableService.State_Query.cs (1)
32if (info.Type == null || info.Type.SpecialType == SpecialType.System_Void)
LanguageServices\SymbolDisplayService\AbstractSymbolDisplayService.AbstractSymbolDescriptionBuilder.cs (1)
512if (symbol.IsEnumType() && symbol.EnumUnderlyingType.SpecialType != SpecialType.System_Int32)
MetadataAsSource\AbstractMetadataAsSourceService.WrappedNamedTypeSymbol.cs (1)
69public SpecialType SpecialType => _symbol.SpecialType;
PopulateSwitchStatementHelpers.cs (1)
139if (member is not IFieldSymbol fieldSymbol || fieldSymbol.Type.SpecialType != SpecialType.None)
PreferFrameworkType\PreferFrameworkTypeCodeFixProvider.cs (2)
61var replacementNode = typeSymbol.SpecialType is SpecialType.System_IntPtr or SpecialType.System_UIntPtr
PreferFrameworkType\PreferFrameworkTypeDiagnosticAnalyzerBase.cs (1)
90typeSymbol.SpecialType is SpecialType.None)
QuickInfo\QuickInfoUtilities.cs (1)
47if (symbol is INamedTypeSymbol { SpecialType: SpecialType.System_Void })
ReplaceMethodWithProperty\ReplaceMethodWithPropertyCodeRefactoringProvider.cs (1)
132if (current.ContainingType.SpecialType == SpecialType.System_Object)
RQName\RQNodeBuilder.cs (2)
70if (type != type.ConstructedFrom || type.SpecialType == SpecialType.System_Void) 265if (symbol.SpecialType == SpecialType.System_Void)
ValueTracking\ValueTracker.cs (1)
247return methodSymbol.ReturnType.SpecialType != SpecialType.System_Void;
Microsoft.CodeAnalysis.Scripting (38)
Hosting\ObjectFormatter\CommonPrimitiveFormatter.cs (18)
64case SpecialType.System_Int32: 67case SpecialType.System_String: 70case SpecialType.System_Boolean: 73case SpecialType.System_Char: 76case SpecialType.System_Int64: 79case SpecialType.System_Double: 82case SpecialType.System_Byte: 85case SpecialType.System_Decimal: 88case SpecialType.System_UInt32: 91case SpecialType.System_UInt64: 94case SpecialType.System_Single: 97case SpecialType.System_Int16: 100case SpecialType.System_UInt16: 103case SpecialType.System_DateTime: 106case SpecialType.System_SByte: 109case SpecialType.System_Object: 110case SpecialType.System_Void: 111case SpecialType.None:
Hosting\ObjectFormatter\CommonTypeNameFormatter.cs (1)
22protected abstract string GetPrimitiveTypeName(SpecialType type);
Hosting\ObjectFormatter\ObjectFormatterHelpers.cs (19)
276internal static SpecialType GetPrimitiveSpecialType(Type type) 282return SpecialType.System_Int32; 287return SpecialType.System_String; 292return SpecialType.System_Boolean; 297return SpecialType.System_Char; 302return SpecialType.System_Int64; 307return SpecialType.System_Double; 312return SpecialType.System_Byte; 317return SpecialType.System_Decimal; 322return SpecialType.System_UInt32; 327return SpecialType.System_UInt64; 332return SpecialType.System_Single; 337return SpecialType.System_Int16; 342return SpecialType.System_UInt16; 347return SpecialType.System_DateTime; 352return SpecialType.System_SByte; 357return SpecialType.System_Object; 362return SpecialType.System_Void; 365return SpecialType.None;
Microsoft.CodeAnalysis.Test.Utilities (20)
Compilation\ControlFlowGraphVerifier.cs (2)
954&& arguments[0].Value.Type.SpecialType == SpecialType.System_Int32 955&& arguments[1].Value.Type.SpecialType == SpecialType.System_Int32;
Compilation\IRuntimeEnvironment.cs (1)
201var corLibIdentity = compilation.GetSpecialType(SpecialType.System_Object).ContainingAssembly.Identity;
Diagnostics\CouldHaveMoreSpecificTypeAnalyzer.cs (2)
226return baseType.TypeKind == TypeKind.Class && baseType.SpecialType == SpecialType.System_Object; 266(targetTypeKind == TypeKind.Class && (sourceTypeKind == TypeKind.Structure || sourceTypeKind == TypeKind.Interface) && targetType.SpecialType == SpecialType.System_Object))
Diagnostics\LocalCouldBeConstAnalyzer.cs (2)
89if ((!localType.IsReferenceType || localType.SpecialType == SpecialType.System_String) && localType.SpecialType != SpecialType.None)
Diagnostics\OperationTestAnalyzer.cs (12)
159conditionRight.Type.SpecialType == SpecialType.System_Int32 && 176setupAssignment.Value.Type.SpecialType == SpecialType.System_Int32) 241advanceAssignment.Value.Type.SpecialType == SpecialType.System_Int32) 250advanceOperation.RightOperand.Type.SpecialType == SpecialType.System_Int32) 265advanceAssignment.Value.Type.SpecialType == SpecialType.System_Int32) 357singleValueExpression.Type.SpecialType == SpecialType.System_Int32) 377rangeMinExpression.Type.SpecialType == SpecialType.System_Int32 && 380rangeMaxExpression.Type.SpecialType == SpecialType.System_Int32) 400relationalValueExpression.Type.SpecialType == SpecialType.System_Int32) 587if (argumentValue.HasValue && argument.Type.SpecialType == SpecialType.System_Int32) 631if (literal.Type.SpecialType == SpecialType.System_Int32 && 1521if (binary.OperatorKind == BinaryOperatorKind.Multiply && binary.Type.SpecialType == SpecialType.System_Double)
Platform\CoreClr\CoreCLRRuntimeEnvironment.cs (1)
55var corLibIdentity = mainCompilation.GetSpecialType(SpecialType.System_Object).ContainingAssembly.Identity;
Microsoft.CodeAnalysis.UnitTests (34)
CommonTypedConstantTests.cs (6)
30_intType = _compilation.GetSpecialType(SpecialType.System_Int32); 31_stringType = _compilation.GetSpecialType(SpecialType.System_String); 32_enumString1 = _compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(_compilation.GetSpecialType(SpecialType.System_String)); 33_enumString2 = _compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(_compilation.GetSpecialType(SpecialType.System_String));
CorLibTypesTests.cs (28)
20for (int i = 1; i <= (int)SpecialType.Count; i++) 22string name = SpecialTypes.GetMetadataName((SpecialType)i); 23Assert.Equal((SpecialType)i, SpecialTypes.GetTypeFromMetadataName(name)); 26for (int i = 0; i <= (int)SpecialType.Count; i++) 28Cci.PrimitiveTypeCode code = SpecialTypes.GetTypeCode((SpecialType)i); 32Assert.Equal((SpecialType)i, SpecialTypes.GetTypeFromMetadataName(code)); 38SpecialType id = SpecialTypes.GetTypeFromMetadataName((Cci.PrimitiveTypeCode)i); 40if (id != SpecialType.None) 46Assert.Equal(SpecialType.System_Boolean, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Boolean)); 47Assert.Equal(SpecialType.System_Char, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Char)); 48Assert.Equal(SpecialType.System_Void, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Void)); 49Assert.Equal(SpecialType.System_String, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.String)); 50Assert.Equal(SpecialType.System_Int64, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Int64)); 51Assert.Equal(SpecialType.System_Int32, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Int32)); 52Assert.Equal(SpecialType.System_Int16, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Int16)); 53Assert.Equal(SpecialType.System_SByte, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Int8)); 54Assert.Equal(SpecialType.System_UInt64, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.UInt64)); 55Assert.Equal(SpecialType.System_UInt32, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.UInt32)); 56Assert.Equal(SpecialType.System_UInt16, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.UInt16)); 57Assert.Equal(SpecialType.System_Byte, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.UInt8)); 58Assert.Equal(SpecialType.System_Single, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Float32)); 59Assert.Equal(SpecialType.System_Double, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.Float64)); 60Assert.Equal(SpecialType.System_IntPtr, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.IntPtr)); 61Assert.Equal(SpecialType.System_UIntPtr, SpecialTypes.GetTypeFromMetadataName(Cci.PrimitiveTypeCode.UIntPtr)); 72var knownMissingTypes = new HashSet<SpecialType>() 76for (var specialType = SpecialType.None + 1; specialType <= SpecialType.Count; specialType++)
Microsoft.CodeAnalysis.VisualBasic (1669)
Analysis\FlowAnalysis\AbstractFlowPass.vb (5)
342Case SpecialType.None, 343SpecialType.System_Nullable_T, 344SpecialType.System_IntPtr, 345SpecialType.System_UIntPtr 821Debug.Assert(node.ValueOpt IsNot Nothing OrElse node.HasErrors OrElse node.Type.SpecialType = SpecialType.System_Void)
Analysis\InitializerRewriter.vb (2)
213If expr.Type.SpecialType <> SpecialType.System_Void Then 227Debug.Assert(submissionResult.Type.SpecialType <> SpecialType.System_Void)
Binding\Binder.vb (6)
427Public Function GetSpecialType(typeId As SpecialType, node As SyntaxNodeOrToken, diagBag As BindingDiagnosticBag) As NamedTypeSymbol 432Public Shared Function GetSpecialType(compilation As VisualBasicCompilation, typeId As SpecialType, node As SyntaxNodeOrToken, diagBag As BindingDiagnosticBag) As NamedTypeSymbol 437Public Function GetSpecialType(typeId As SpecialType, node As SyntaxNodeOrToken, diagBag As BindingDiagnosticBag, ByRef reportedAnError As Boolean, suppressUseSiteError As Boolean) As NamedTypeSymbol 441Public Shared Function GetSpecialType(compilation As VisualBasicCompilation, typeId As SpecialType, node As SyntaxNodeOrToken, diagBag As BindingDiagnosticBag, ByRef reportedAnError As Boolean, suppressUseSiteError As Boolean) As NamedTypeSymbol 522If candidateProperty.Type.SpecialType <> SpecialType.System_String OrElse 536If parameterType.OriginalDefinition.SpecialType <> SpecialType.System_Collections_Generic_IEnumerable_T OrElse
Binding\Binder_AnonymousTypes.vb (1)
128Dim objectType As TypeSymbol = GetSpecialType(SpecialType.System_Object, initializerSyntax, diagnostics)
Binding\Binder_Attributes.vb (1)
795ReportDiagnostic(diagBag, conv.Operand.Syntax, ERRID.ERR_RequiredAttributeConstConversion2, If(conv.Operand.Type, _binder.Compilation.GetSpecialType(SpecialType.System_Object)), conv.Type)
Binding\Binder_Conversions.vb (30)
122(targetType.IsObjectType() OrElse targetType.SpecialType = SpecialType.System_ValueType) Then 245(targetType.IsObjectType() OrElse targetType.SpecialType = SpecialType.System_ValueType) Then 268Dim targetType As SpecialType 271Case SyntaxKind.CBoolKeyword : targetType = SpecialType.System_Boolean 272Case SyntaxKind.CByteKeyword : targetType = SpecialType.System_Byte 273Case SyntaxKind.CCharKeyword : targetType = SpecialType.System_Char 274Case SyntaxKind.CDateKeyword : targetType = SpecialType.System_DateTime 275Case SyntaxKind.CDecKeyword : targetType = SpecialType.System_Decimal 276Case SyntaxKind.CDblKeyword : targetType = SpecialType.System_Double 277Case SyntaxKind.CIntKeyword : targetType = SpecialType.System_Int32 278Case SyntaxKind.CLngKeyword : targetType = SpecialType.System_Int64 279Case SyntaxKind.CObjKeyword : targetType = SpecialType.System_Object 280Case SyntaxKind.CSByteKeyword : targetType = SpecialType.System_SByte 281Case SyntaxKind.CShortKeyword : targetType = SpecialType.System_Int16 282Case SyntaxKind.CSngKeyword : targetType = SpecialType.System_Single 283Case SyntaxKind.CStrKeyword : targetType = SpecialType.System_String 284Case SyntaxKind.CUIntKeyword : targetType = SpecialType.System_UInt32 285Case SyntaxKind.CULngKeyword : targetType = SpecialType.System_UInt64 286Case SyntaxKind.CUShortKeyword : targetType = SpecialType.System_UInt16 381Dim nullableOfT As NamedTypeSymbol = Compilation.GetSpecialType(SpecialType.System_Nullable_T) 382intermediateTargetType = Compilation.GetSpecialType(SpecialType.System_Nullable_T). 501(targetType.IsObjectType() OrElse targetType.SpecialType = SpecialType.System_ValueType) Then 703If targetGenericDefinition.SpecialType = SpecialType.System_Collections_Generic_IList_T OrElse 704targetGenericDefinition.SpecialType = SpecialType.System_Collections_Generic_ICollection_T OrElse 705targetGenericDefinition.SpecialType = SpecialType.System_Collections_Generic_IReadOnlyList_T OrElse 706targetGenericDefinition.SpecialType = SpecialType.System_Collections_Generic_IReadOnlyCollection_T OrElse 737Dim iEnumerable_T As NamedTypeSymbol = Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 988targetType.SpecialType <> SpecialType.System_MulticastDelegate) 1715If (targetType.SpecialType = SpecialType.System_String) AndAlso IsIEnumerableOfXElement(sourceType, useSiteInfo) Then 1754(targetElement.IsObjectType() OrElse targetElement.SpecialType = SpecialType.System_ValueType) AndAlso
Binding\Binder_Delegates.vb (2)
229If targetType.SpecialType = SpecialType.System_Delegate OrElse 230targetType.SpecialType = SpecialType.System_MulticastDelegate Then
Binding\Binder_Expressions.vb (38)
531expressionType = GetSpecialType(SpecialType.System_Object, expression.Syntax, diagnostics) 672If typeSym.IsArrayType AndAlso DirectCast(typeSym, ArrayTypeSymbol).ElementType.SpecialType = SpecialType.System_Void Then 744Return New BoundNameOfOperator(node, argument, ConstantValue.Create(value), GetSpecialType(SpecialType.System_String, node, diagnostics)) 757Dim resultType As TypeSymbol = GetSpecialType(SpecialType.System_Boolean, node, diagnostics) 782operand = ApplyImplicitConversion(node, GetSpecialType(SpecialType.System_Object, node.Expression, diagnostics), operand, diagnostics) 951resultType = GetSpecialType(SpecialType.System_Nullable_T, expr.Syntax, diagnostics).Construct(resultType) 1237(exprType IsNot Nothing AndAlso exprType.SpecialType = SpecialType.System_Void) Then 1414GetSpecialType(SpecialType.System_Object, expr.Syntax, diagnostics), Nothing) 1514(originalTargetType.SpecialType = SpecialType.System_Collections_Generic_IEnumerable_T OrElse 1515originalTargetType.SpecialType = SpecialType.System_Collections_Generic_IList_T OrElse 1516originalTargetType.SpecialType = SpecialType.System_Collections_Generic_ICollection_T OrElse 1517originalTargetType.SpecialType = SpecialType.System_Collections_Generic_IReadOnlyList_T OrElse 1518originalTargetType.SpecialType = SpecialType.System_Collections_Generic_IReadOnlyCollection_T) Then 1919dominantType = GetSpecialType(SpecialType.System_Object, node, diagnostics) 1986dominantType = If(boundFirstArg.Type, If(boundSecondArg.Type, GetSpecialType(SpecialType.System_Object, node, diagnostics))) 2458MemberLookup.GetTypeForIntrinsicAlias(name) <> SpecialType.None Then 3721GetSpecialType(SpecialType.System_String, node.Name, diagnostics))), 3738If type.SpecialType = SpecialType.System_Object OrElse type.IsExtensibleInterfaceNoUseSiteDiagnostics() Then 3740Dim arg = New BoundLiteral(name, ConstantValue.Create(node.Name.Identifier.ValueText), GetSpecialType(SpecialType.System_String, name, diagnostics)) 3759Dim arg = New BoundLiteral(name, ConstantValue.Create(node.Name.Identifier.ValueText), GetSpecialType(SpecialType.System_String, name, diagnostics)) 3776If type.SpecialType = SpecialType.System_Array Then 3802GetSpecialType(SpecialType.System_String, node.Name, diagnostics))), 3845Dim specialType As SpecialType = GetSpecialTypeForTypeCharacter(typeChar, typeCharacterString) 3847If specialType <> Microsoft.CodeAnalysis.SpecialType.None Then 3868Dim specialType As SpecialType = GetSpecialTypeForTypeCharacter(typeChar, typeCharacterString) 3870If specialType <> specialType.None Then 3892Dim int32Type = GetSpecialType(SpecialType.System_Int32, node.ArgumentList, diagnostics) 4103Dim Int32Type = GetSpecialType(SpecialType.System_Int32, node, diagnostics) 4187inferredElementType = GetSpecialType(SpecialType.System_Object, node, diagnostics) 4319Dim int32Type = GetSpecialType(SpecialType.System_Int32, arrayBoundsOpt, diagnostics) 4434Dim specialType As SpecialType = SpecialTypeExtensions.FromRuntimeTypeOfLiteralValue(value) 4437Debug.Assert(specialType <> specialType.None AndAlso 4438specialType <> specialType.System_Byte AndAlso 4439specialType <> specialType.System_SByte) 4573Debug.Assert(dominantType.IsArrayType AndAlso DirectCast(dominantType, ArrayTypeSymbol).Rank = 1 AndAlso DirectCast(dominantType, ArrayTypeSymbol).ElementType.SpecialType = SpecialType.System_Object) 4579dominantType = GetSpecialType(SpecialType.System_Object, syntax, diagnostics) 4584dominantType = GetSpecialType(SpecialType.System_Object, syntax, diagnostics) 4898resultType = GetSpecialType(SpecialType.System_Void, node, diagnostics)
Binding\Binder_Initializers.vb (4)
159If fieldSymbol.Type.SpecialType = SpecialType.System_DateTime Then 164ElseIf fieldSymbol.Type.SpecialType = SpecialType.System_Decimal Then 214If expression.Type Is Nothing OrElse expression.Type.SpecialType <> SpecialType.System_Void Then 511Dim fieldType = If(fieldSymbol.HasDeclaredType, fieldSymbol.Type, GetSpecialType(SpecialType.System_Object, asNewSyntax, BindingDiagnosticBag.Discarded)) ' prevent recursion if field type is inferred.
Binding\Binder_InterpolatedString.vb (1)
32Return New BoundInterpolatedStringExpression(syntax, contentBuilder.ToImmutableAndFree(), binder:=Me, type:=GetSpecialType(SpecialType.System_String, syntax, diagnostics))
Binding\Binder_Invocation.vb (10)
338If target.Type.SpecialType = SpecialType.System_Object OrElse 339target.Type.SpecialType = SpecialType.System_Array Then 2725GetSpecialType(SpecialType.System_Int32, node, diagnostics)).MakeCompilerGenerated()}).AsImmutableOrNull(), 3184literal = New BoundLiteral(syntax, callerInfoValue, GetSpecialType(SpecialType.System_Int32, syntax, ignoreDiagnostics)) 3187literal = New BoundLiteral(syntax, callerInfoValue, GetSpecialType(SpecialType.System_String, syntax, ignoreDiagnostics)) 3225defaultConstantValue = ConstantValue.Default(SpecialType.System_Int32) 3228If paramNullableUnderlyingTypeOrSelf.GetEnumUnderlyingTypeOrSelf().SpecialType = SpecialType.System_Int32 Then 3231defaultArgumentType = GetSpecialType(SpecialType.System_Int32, syntax, diagnostics) 3234ElseIf defaultSpecialType <> SpecialType.None Then 3255If param.Type.SpecialType = SpecialType.System_Object Then
Binding\Binder_Lambda.vb (20)
61If originalRetTypeDef.SpecialType <> SpecialType.System_Collections_Generic_IEnumerable_T AndAlso 62originalRetTypeDef.SpecialType <> SpecialType.System_Collections_Generic_IEnumerator_T AndAlso 63returnType.SpecialType <> SpecialType.System_Collections_IEnumerable AndAlso 64returnType.SpecialType <> SpecialType.System_Collections_IEnumerator Then 73returnType = GetSpecialType(SpecialType.System_Void, node.SubOrFunctionHeader, diagnostics) 133objectType = GetSpecialType(SpecialType.System_Object, unboundParam.IdentifierSyntax, diagnostics) 172If target.ReturnType.SpecialType <> SpecialType.System_Void AndAlso 174Not ((source.Flags And SourceMemberFlags.Iterator) <> 0 AndAlso (target.ReturnType.SpecialType = SpecialType.System_Collections_IEnumerable OrElse 175target.ReturnType.SpecialType = SpecialType.System_Collections_IEnumerator)) Then 188If origTargetReturnType.SpecialType <> SpecialType.System_Collections_Generic_IEnumerable_T AndAlso 189origTargetReturnType.SpecialType <> SpecialType.System_Collections_Generic_IEnumerator_T Then 205Compilation.GetSpecialType(SpecialType.System_Void), ' No need to report use-site error. 289If source.ReturnType Is Nothing AndAlso target.ReturnType.SpecialType <> SpecialType.System_Void Then 773Dim targetSignature As New UnboundLambda.TargetSignature(ImmutableArray(Of ParameterSymbol).Empty, Compilation.GetSpecialType(SpecialType.System_Void), returnsByRef:=False) 850commonParameterTypes(i) = Compilation.GetSpecialType(SpecialType.System_Object) 863Compilation.GetSpecialType(SpecialType.System_Void), 925lambdaReturnType = GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T, source.Syntax, diagnostics). 926Construct(GetSpecialType(SpecialType.System_Object, source.Syntax, diagnostics)) 942lambdaReturnType = GetSpecialType(SpecialType.System_Object, source.Syntax, diagnostics) 997lambdaReturnType = GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T, source.Syntax, diagnostics).Construct(lambdaReturnType)
Binding\Binder_Latebound.vb (4)
60Dim objType = Me.GetSpecialType(SpecialType.System_Object, node, diagnostics) 165Dim objectType = GetSpecialType(SpecialType.System_Object, node, diagnostics) 183argument = omitted.Update(GetSpecialType(SpecialType.System_Object, argument.Syntax, diagnostics)) 227Dim objType = Me.GetSpecialType(SpecialType.System_Object, node, diagnostics)
Binding\Binder_Lookup.vb (21)
419If specialType <> specialType.None Then 448Public Shared Function GetTypeForIntrinsicAlias(possibleAlias As String) As SpecialType 453Return SpecialType.System_DateTime 455Return SpecialType.System_UInt16 457Return SpecialType.System_Int16 459Return SpecialType.System_UInt32 461Return SpecialType.System_Int32 463Return SpecialType.System_UInt64 465Return SpecialType.System_Int64 467Return SpecialType.None 832Return iFaceSpecial = SpecialType.System_Collections_Generic_IEnumerable_T OrElse 833iFaceSpecial = SpecialType.System_Collections_Generic_IList_T OrElse 834iFaceSpecial = SpecialType.System_Collections_Generic_ICollection_T OrElse 836iFaceSpecial = SpecialType.System_Collections_Generic_IReadOnlyList_T OrElse 837iFaceSpecial = SpecialType.System_Collections_Generic_IReadOnlyCollection_T OrElse 839iFaceSpecial = SpecialType.System_Collections_IEnumerable OrElse 1471Dim obj As NamedTypeSymbol = binder.SourceModule.ContainingAssembly.GetSpecialType(SpecialType.System_Object) 1928If container IsNot Nothing And container.SpecialType = SpecialType.System_Void Then 2006binder.SourceModule.ContainingAssembly.GetSpecialType(SpecialType.System_Object), 2163Return typeParameter.ContainingAssembly.GetSpecialType(If(typeParameter.HasValueTypeConstraint, SpecialType.System_ValueType, SpecialType.System_Object))
Binding\Binder_ObjectInitializer.vb (3)
605If initializedObjectType.SpecialType = SpecialType.System_Object OrElse initializedObjectType.IsErrorType Then 608If initializedObjectType.SpecialType = SpecialType.System_Object Then 803Dim ienumerable = GetSpecialType(SpecialType.System_Collections_IEnumerable,
Binding\Binder_Operators.vb (28)
45Dim booleanType = GetSpecialType(SpecialType.System_Boolean, node, diagnostics) 81GetSpecialType(SpecialType.System_Object, targetArgument.Syntax, diagnostics), 104GetSpecialType(SpecialType.System_Object, targetArgument.Syntax, diagnostics), 256Dim intrinsicOperatorType As SpecialType = SpecialType.None 303If intrinsicOperatorType = SpecialType.None Then 342Dim booleanType As TypeSymbol = GetSpecialTypeForBinaryOperator(node, leftType, rightType, SpecialType.System_Boolean, 454Dim rightTargetType As TypeSymbol = GetSpecialTypeForBinaryOperator(node, leftType, rightType, SpecialType.System_Int32, 791stringType = GetSpecialType(SpecialType.System_String, dbNullOperand.Syntax, diagnostics) 809specialType As SpecialType, 813Debug.Assert(specialType <> Microsoft.CodeAnalysis.SpecialType.None) 882If ofSpecialType <> SpecialType.None Then 990Dim defaultRightSpecialType As SpecialType 995defaultRightSpecialType = SpecialType.System_String 999defaultRightSpecialType = SpecialType.System_Boolean 1019defaultRightSpecialType = SpecialType.System_Int32 1038Dim defaultLeftSpecialType As SpecialType = SpecialType.None 1052defaultLeftSpecialType = SpecialType.System_String 1058defaultLeftSpecialType = SpecialType.System_Int32 1061If defaultLeftSpecialType = SpecialType.None OrElse defaultLeftSpecialType = rightType.SpecialType Then 1092If leftType.SpecialType <> SpecialType.System_String Then 1093rightType = GetSpecialType(SpecialType.System_String, right.Syntax, diagnostics) 1113Dim int32Type = GetSpecialType(SpecialType.System_Int32, node.Operand, diagnostics) 1124Dim intrinsicOperatorType As SpecialType = SpecialType.None 1158If intrinsicOperatorType = SpecialType.None Then 1177If operandType.SpecialType = SpecialType.System_Object Then
Binding\Binder_Query.vb (5)
2331Dim boolSymbol As NamedTypeSymbol = GetSpecialType(SpecialType.System_Boolean, condition, diagnostics) 3470Dim intrinsicOperatorType As SpecialType = SpecialType.None 3483intrinsicOperatorType <> SpecialType.None Then 4390inferredType = GetSpecialType(SpecialType.System_Object, source.Syntax, additionalDiagnostics)
Binding\Binder_SelectCase.vb (14)
390Dim booleanType = GetSpecialType(SpecialType.System_Boolean, selectExpression.Syntax, diagnostics) 694Case SpecialType.System_Boolean, 695SpecialType.System_Byte, 696SpecialType.System_UInt16, 697SpecialType.System_UInt32, 698SpecialType.System_UInt64 701Case SpecialType.System_SByte, 702SpecialType.System_Int16, 703SpecialType.System_Int32, 704SpecialType.System_Int64, 705SpecialType.System_Char 708Case SpecialType.System_Single, 709SpecialType.System_Double 712Case SpecialType.System_Decimal
Binding\Binder_Statements.vb (40)
779target.Type.SpecialType <> SpecialType.System_Array AndAlso 780target.Type.SpecialType <> SpecialType.System_Object Then 1336If hasExplicitType AndAlso Not (symbol.IsConst AndAlso type.SpecialType = SpecialType.System_Object) Then 2178Dim int32 As NamedTypeSymbol = GetSpecialType(SpecialType.System_Int32, midExpression, diagnostics) 2190Dim stringType As NamedTypeSymbol = GetSpecialType(SpecialType.System_String, midExpression, diagnostics) 2235Compilation.GetSpecialType(SpecialType.System_Void), 2422Dim container = If(exprSymbol IsNot Nothing, exprSymbol.ContainingSymbol, Compilation.GetSpecialType(SpecialType.System_Object)) 2722GetSpecialType(SpecialType.System_Void, conditionalAccess.Syntax, diagnostics)) 3136Me.GetSpecialType(SpecialType.System_Int32, forStatement, diagnostics)) 3162Dim integerType = GetSpecialType(SpecialType.System_Int32, node, diagnostics) 3163Dim booleanType = GetSpecialType(SpecialType.System_Boolean, node, diagnostics) 3459Dim idisposableType = Compilation.GetSpecialType(SpecialType.System_IDisposable) 3475Debug.Assert(enumeratorType.SpecialType = SpecialType.System_Collections_IEnumerator) 3720Dim interfaceSpecialType As SpecialType = SpecialType.None 3742Dim genericIEnumerable = GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T, collectionSyntax, ienumerableUseSiteDiagnostics) 3777interfaceSpecialType = SpecialType.System_Collections_Generic_IEnumerable_T 3782Dim ienumerable = GetSpecialType(SpecialType.System_Collections_IEnumerable, collectionSyntax, ienumerableUseSiteDiagnostics) 3792interfaceSpecialType = SpecialType.System_Collections_IEnumerable 3843If interfaceSpecialType <> SpecialType.None Then 3850If interfaceSpecialType = SpecialType.System_Collections_Generic_IEnumerable_T Then 3910If interfaceSpecialType = SpecialType.System_Collections_Generic_IEnumerable_T Then 3954elementType = GetSpecialType(SpecialType.System_Char, collectionSyntax, diagnostics) 3960Dim idisposable = GetSpecialType(SpecialType.System_IDisposable, collectionSyntax, diagnostics) 3974getEnumeratorReturnType.SpecialType = SpecialType.System_Collections_IEnumerator Then 4136DirectCast(boundMoveNextCall, BoundCall).Method.OriginalDefinition.ReturnType.SpecialType <> SpecialType.System_Boolean Then 4326Dim valueTypeSymbol = interfaceType.ContainingAssembly.GetSpecialType(SpecialType.System_ValueType) 4417Dim iDisposable = GetSpecialType(SpecialType.System_IDisposable, 4921Dim boolSymbol As NamedTypeSymbol = GetSpecialType(SpecialType.System_Boolean, node, diagnostics) 4948Return Compilation.GetSpecialType(SpecialType.System_Void) 4952Return Compilation.GetSpecialType(SpecialType.System_Void) 4986If retType.SpecialType = SpecialType.System_Void Then 4992If(isAsync AndAlso Not methodReturnType.SpecialType = SpecialType.System_Void, ERRID.ERR_ReturnFromNonGenericTaskAsync, ERRID.ERR_ReturnFromNonFunction))) 5076Dim returnSpecialType As SpecialType = If(returnNamedType IsNot Nothing, returnNamedType.SpecialType, Nothing) 5078If returnSpecialType = SpecialType.System_Collections_Generic_IEnumerable_T OrElse 5079returnSpecialType = SpecialType.System_Collections_Generic_IEnumerator_T Then 5084If returnSpecialType = SpecialType.System_Collections_IEnumerable OrElse 5085returnSpecialType = SpecialType.System_Collections_IEnumerator Then 5087Return GetSpecialType(SpecialType.System_Object, node, diagnostics) 5205GetSpecialType(SpecialType.System_Int32, node.ErrorNumber, diagnostics),
Binding\Binder_Symbols.vb (18)
64If type.SpecialType = SpecialType.System_Void Then 765Dim type As SpecialType 768type = SpecialType.System_Object 770type = SpecialType.System_Boolean 772type = SpecialType.System_DateTime 774type = SpecialType.System_Char 776type = SpecialType.System_String 778type = SpecialType.System_Decimal 780type = SpecialType.System_Byte 782type = SpecialType.System_SByte 784type = SpecialType.System_UInt16 786type = SpecialType.System_Int16 788type = SpecialType.System_UInt32 790type = SpecialType.System_Int32 792type = SpecialType.System_UInt64 794type = SpecialType.System_Int64 796type = SpecialType.System_Single 798type = SpecialType.System_Double
Binding\Binder_Utils.vb (35)
295Dim nullableType As NamedTypeSymbol = DirectCast(GetSpecialType(SpecialType.System_Nullable_T, syntax, diagBag), NamedTypeSymbol) 673Dim specialType As SpecialType = GetSpecialTypeForTypeCharacter(identifier.GetTypeCharacter(), typeCharacterString) 675If specialType <> Microsoft.CodeAnalysis.SpecialType.None Then 695Return GetSpecialType(SpecialType.System_Object, identifier, diagBag) 699Public Shared Function GetSpecialTypeForTypeCharacter(typeChar As TypeCharacter, ByRef typeCharacterString As String) As SpecialType 700Dim specialType As SpecialType = SpecialType.None 704specialType = SpecialType.System_Decimal 707specialType = SpecialType.System_Decimal 710specialType = SpecialType.System_Double 713specialType = SpecialType.System_Double 716specialType = SpecialType.System_Int32 719specialType = SpecialType.System_Int32 722specialType = SpecialType.System_Int64 725specialType = SpecialType.System_Int64 728specialType = SpecialType.System_Int16 731specialType = SpecialType.System_Single 734specialType = SpecialType.System_Single 737specialType = SpecialType.System_String 740specialType = SpecialType.System_UInt32 743specialType = SpecialType.System_UInt64 746specialType = SpecialType.System_UInt16 1374Case SpecialType.System_Boolean, 1375SpecialType.System_Byte, 1376SpecialType.System_SByte, 1377SpecialType.System_Int16, 1378SpecialType.System_UInt16, 1379SpecialType.System_Int32, 1380SpecialType.System_UInt32, 1381SpecialType.System_Int64, 1382SpecialType.System_UInt64, 1383SpecialType.System_Single, 1384SpecialType.System_Double, 1385SpecialType.System_Char 1408If(operandType, GetSpecialType(SpecialType.System_Object, operand.Syntax, diagnostics)),
Binding\Binder_XmlLiterals.vb (7)
292Dim prefixesType = CreateArrayType(GetSpecialType(SpecialType.System_String, syntax, diagnostics)) 647If receiverType.SpecialType = SpecialType.System_Object Then 674memberAccess = BadExpression(syntax, ImmutableArray.Create(receiver, name), Compilation.GetSpecialType(SpecialType.System_String)) 697If receiverType.SpecialType = SpecialType.System_Object Then 797Return BadExpression(syntax, Compilation.GetSpecialType(SpecialType.System_String)) 903Dim result = BadExpression(syntax, Compilation.GetSpecialType(SpecialType.System_String)) 1057Dim result = New BoundLiteral(syntax, ConstantValue.Create(str), GetSpecialType(SpecialType.System_String, syntax, diagnostics), hasErrors:=hasErrors)
Binding\DocumentationCommentCrefBinder_Compat.vb (17)
351Dim type As SpecialType 354type = SpecialType.System_Object 356type = SpecialType.System_Boolean 358type = SpecialType.System_DateTime 360type = SpecialType.System_Char 362type = SpecialType.System_String 364type = SpecialType.System_Decimal 366type = SpecialType.System_Byte 368type = SpecialType.System_SByte 370type = SpecialType.System_UInt16 372type = SpecialType.System_Int16 374type = SpecialType.System_UInt32 376type = SpecialType.System_Int32 378type = SpecialType.System_UInt64 380type = SpecialType.System_Int64 382type = SpecialType.System_Single 384type = SpecialType.System_Double
Binding\ImplicitVariableBinder.vb (2)
157Dim localSpecialType As SpecialType = SpecialType.System_Object
Binding\SyntheticBoundTrees\SynthesizedPropertyAccessorBase.vb (4)
264accessor.ContainingAssembly.GetSpecialType(SpecialType.System_Object)), 266accessor.ContainingAssembly.GetSpecialType(SpecialType.System_Boolean))).MakeCompilerGenerated, 344accessor.ContainingAssembly.GetSpecialType(SpecialType.System_Object)), 346accessor.ContainingAssembly.GetSpecialType(SpecialType.System_Boolean))).MakeCompilerGenerated,
Binding\SyntheticBoundTrees\SynthesizedStringSwitchHashMethod.vb (4)
57Dim i As LocalSymbol = F.SynthesizedLocal(Me.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)) 58Dim hashCode As LocalSymbol = F.SynthesizedLocal(Me.ContainingAssembly.GetSpecialType(SpecialType.System_UInt32)) 98F.Binary(BinaryOperatorKind.IsNot, Me.ContainingAssembly.GetSpecialType(SpecialType.System_Boolean), 119F.Binary(BinaryOperatorKind.LessThan, Me.ContainingAssembly.GetSpecialType(SpecialType.System_Boolean),
BoundTree\BoundAssignmentOperator.vb (2)
42left.GetPropertyOrXmlProperty().ContainingAssembly.GetSpecialType(SpecialType.System_Void), 44left.Type.ContainingAssembly.GetSpecialType(SpecialType.System_Void),
BoundTree\BoundAwaitOperator.vb (1)
15Debug.Assert(Type.Equals(GetResult.Type) OrElse Type.SpecialType = SpecialType.System_Void)
BoundTree\BoundExpressionExtensions.vb (6)
373If node.Value.Discriminator = ConstantValueTypeDiscriminator.Int32 AndAlso node.Type.SpecialType = SpecialType.System_Int32 Then 426Dim type As SpecialType = expression.Type.SpecialType 428Case SpecialType.System_Int16 431Case SpecialType.System_Int32 434Case SpecialType.System_Int64 456If type Is Nothing OrElse type.SpecialType = SpecialType.System_Object Then
BoundTree\BoundInterpolatedStringExpression.vb (1)
40Debug.Assert(Type.SpecialType = SpecialType.System_String)
BoundTree\BoundLocalDeclaration.vb (1)
43(LocalSymbol.IsConst AndAlso LocalSymbol.Type.SpecialType = SpecialType.System_Object AndAlso
BoundTree\BoundSequence.vb (1)
16Debug.Assert(Me.ValueOpt IsNot Nothing OrElse Me.HasErrors OrElse Me.Type.SpecialType = SpecialType.System_Void)
CodeGen\EmitConversion.vb (13)
203Debug.Assert(typeFrom.SpecialType = SpecialType.System_Object OrElse 204typeFrom.SpecialType = SpecialType.System_ValueType OrElse 205typeFrom.SpecialType = SpecialType.System_Enum OrElse 337If typeTo.SpecialType <> SpecialType.System_Object Then 379Debug.Assert(typeTo.SpecialType = SpecialType.System_Object OrElse 380typeTo.SpecialType = SpecialType.System_ValueType OrElse 381typeTo.SpecialType = SpecialType.System_Enum) 426Debug.Assert(typeFrom.SpecialType = SpecialType.System_Object OrElse 427typeFrom.SpecialType = SpecialType.System_ValueType OrElse 428typeFrom.SpecialType = SpecialType.System_Enum OrElse 509Debug.Assert(typeTo.SpecialType = SpecialType.System_Object OrElse 510typeTo.SpecialType = SpecialType.System_ValueType OrElse 511typeTo.SpecialType = SpecialType.System_Enum OrElse
CodeGen\EmitExpression.vb (10)
518Debug.Assert(sequence.ValueOpt IsNot Nothing OrElse sequence.Type.SpecialType = SpecialType.System_Void) 643If field.IsConst AndAlso specType <> SpecialType.System_Decimal AndAlso specType <> SpecialType.System_DateTime Then 1500Debug.Assert(expression.Type.SpecialType = SpecialType.System_Int32 OrElse expression.Type.SpecialType = SpecialType.System_Int64 OrElse expression.Type.SpecialType = SpecialType.System_UIntPtr) 1682If rightType.IsReferenceType OrElse (right.ConstantValueOpt IsNot Nothing AndAlso rightType.SpecialType <> SpecialType.System_Decimal) Then 2181Debug.Assert(node.Type.SpecialType = SpecialType.System_Int32) 2197Debug.Assert(node.Type.SpecialType = SpecialType.System_Int32) 2236Debug.Assert(node.Type.SpecialType = SpecialType.System_Int32)
CodeGen\EmitOperators.vb (9)
442Debug.Assert(binOp.Left.Type.SpecialType = SpecialType.System_Boolean) 443Debug.Assert(binOp.Right.Type.SpecialType = SpecialType.System_Boolean) 498Debug.Assert(binOp.Left.Type.SpecialType = SpecialType.System_Boolean) 499Debug.Assert(binOp.Right.Type.SpecialType = SpecialType.System_Boolean) 505Debug.Assert(binOp.Left.Type.SpecialType = SpecialType.System_Boolean) 506Debug.Assert(binOp.Right.Type.SpecialType = SpecialType.System_Boolean) 512Debug.Assert(binOp.Left.Type.SpecialType = SpecialType.System_Boolean) 513Debug.Assert(binOp.Right.Type.SpecialType = SpecialType.System_Boolean) 601Debug.Assert(condition.Type.SpecialType = SpecialType.System_Boolean)
CodeGen\EmitStatement.vb (4)
815Debug.Assert(binOp.Left.IsNothingLiteral() OrElse binOp.Left.Type.SpecialType = SpecialType.System_Object OrElse binOp.WasCompilerGenerated) 816Debug.Assert(binOp.Right.IsNothingLiteral() OrElse binOp.Right.Type.SpecialType = SpecialType.System_Object OrElse binOp.WasCompilerGenerated) 1053If exprType.SpecialType <> SpecialType.System_String Then 1105Dim UInt32Type = DirectCast(_module.GetSpecialType(SpecialType.System_UInt32, syntaxNode, _diagnostics).GetInternalSymbol(), TypeSymbol)
CodeGen\ResumableStateMachineStateAllocator.vb (1)
82f.SpecialType(SpecialType.System_Boolean),
Compilation\ClsComplianceChecker.vb (8)
347Debug.Assert(baseType IsNot Nothing OrElse symbol.SpecialType = SpecialType.System_Object, "Only object has no base.") 440Debug.Assert(symbol.DelegateReturnType.SpecialType = SpecialType.System_Void) 630Case SpecialType.System_TypedReference, SpecialType.System_UIntPtr 632Case SpecialType.System_SByte, SpecialType.System_UInt16, SpecialType.System_UInt32, SpecialType.System_UInt64
Compilation\MethodCompiler.vb (2)
1865Dim objectType = constructor.ContainingAssembly.GetSpecialType(SpecialType.System_Object) 2030Dim voidType As NamedTypeSymbol = constructor.ContainingAssembly.GetSpecialType(SpecialType.System_Void)
Compilation\VisualBasicCompilation.vb (14)
846Return info.Type.SpecialType <> SpecialType.System_Void 851Return info.Type.SpecialType <> SpecialType.System_Void 1948Friend Shadows Function GetSpecialType(typeId As SpecialType) As NamedTypeSymbol 1967Return GetSpecialType(SpecialType.System_Object) 2794Private Protected Overrides Function CommonGetSpecialType(specialType As SpecialType) As INamedTypeSymbolInternal 2967If returnType.SpecialType <> SpecialType.None AndAlso 2968leftType.SpecialType <> SpecialType.None AndAlso 2969rightType.SpecialType <> SpecialType.None Then 2972If resolved <> SpecialType.None Then 2978If resolved <> SpecialType.System_Object Then 2987resolved = SpecialType.System_Boolean 3034If returnType.SpecialType <> SpecialType.None AndAlso 3035operandType.SpecialType <> SpecialType.None Then 3042If resolved <> SpecialType.None AndAlso
Emit\EditAndContinue\PEDeltaAssemblyBuilder.vb (2)
81_deepTranslator = New VisualBasicSymbolMatcher.DeepTranslator(sourceAssembly.GetSpecialType(SpecialType.System_Object)) 205Debug.Assert(type.BaseTypeNoUseSiteDiagnostics.SpecialType = SpecialType.System_MulticastDelegate)
Emit\EditAndContinue\VisualBasicSymbolMatcher.vb (1)
34_symbols = New MatchSymbols(anonymousTypeMap, sourceAssembly, otherAssembly, otherSynthesizedMembersOpt, otherDeletedMembersOpt, New DeepTranslator(otherAssembly.GetSpecialType(SpecialType.System_Object)))
Emit\NamedTypeSymbolAdapter.vb (1)
233baseType = AdaptedNamedTypeSymbol.ContainingAssembly.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_Object)
Emit\NoPia\EmbeddedTypesManager.vb (3)
46Dim type = ModuleBeingBuilt.Compilation.GetSpecialType(SpecialType.System_String) 109ImmutableArray.Create(New TypedConstant(ctor.Parameters(0).Type, TypedConstantKind.Type, ctor.ContainingAssembly.GetSpecialType(SpecialType.System_Object))), 196If type.SpecialType <> SpecialType.None OrElse
Emit\PEModuleBuilder.vb (4)
592Friend NotOverridable Overrides Function GetSpecialType(specialType As SpecialType, syntaxNodeOpt As SyntaxNode, diagnostics As DiagnosticBag) As Cci.INamedTypeReference 599Private Function GetUntranslatedSpecialType(specialType As SpecialType, syntaxNodeOpt As SyntaxNode, diagnostics As DiagnosticBag) As NamedTypeSymbol 622Return namedType.SpecialType = CType(platformType, SpecialType) 751Return New SynthesizedPrivateImplementationDetailsSharedConstructor(SourceModule, details, GetUntranslatedSpecialType(SpecialType.System_Void, syntaxOpt, diagnostics)).GetCciAdapter()
Emit\SymbolTranslator.vb (1)
217If declaredBase IsNot Nothing AndAlso declaredBase.SpecialType = SpecialType.System_ValueType Then
Emit\TypeParameterSymbolAdapter.vb (2)
199If t.SpecialType = SpecialType.System_ValueType Then 211Dim typeRef As INamedTypeReference = _module.GetSpecialType(CodeAnalysis.SpecialType.System_ValueType,
Lowering\AsyncRewriter\AsyncRewriter.AsyncMethodToClassRewriter.Await.vb (3)
78condition:=Me.F.Convert(Me.F.SpecialType(SpecialType.System_Boolean), rewrittenIsCompleted), 93If rewrittenType.SpecialType <> SpecialType.System_Void Then 120awaiterFieldType = Me.F.SpecialType(SpecialType.System_Object)
Lowering\AsyncRewriter\AsyncRewriter.AsyncMethodToClassRewriter.Expressions.vb (2)
629Me.F.SpecialType(SpecialType.System_Object))) 633Me.F.SpecialType(SpecialType.System_Object))))
Lowering\AsyncRewriter\AsyncRewriter.AsyncMethodToClassRewriter.Spilling.vb (21)
453Case SpecialType.System_Void, 454SpecialType.System_Boolean, 455SpecialType.System_Char, 456SpecialType.System_SByte, 457SpecialType.System_Byte, 458SpecialType.System_Int16, 459SpecialType.System_UInt16, 460SpecialType.System_Int32, 461SpecialType.System_UInt32, 462SpecialType.System_Int64, 463SpecialType.System_UInt64, 464SpecialType.System_Decimal, 465SpecialType.System_Single, 466SpecialType.System_Double, 467SpecialType.System_IntPtr, 468SpecialType.System_UIntPtr, 469SpecialType.System_TypedReference, 470SpecialType.System_ArgIterator, 471SpecialType.System_RuntimeArgumentHandle 474Case SpecialType.System_Object, 475SpecialType.System_String
Lowering\AsyncRewriter\AsyncRewriter.vb (6)
53Me._resultType = Me.F.SpecialType(SpecialType.System_Void) 57Me._resultType = Me.F.SpecialType(SpecialType.System_Void) 136Me.StateField = Me.F.StateMachineField(Me.F.SpecialType(SpecialType.System_Int32), Me.Method, GeneratedNames.MakeStateMachineStateFieldName(), Accessibility.Public) 311EnsureSpecialType(SpecialType.System_Object, bag) 312EnsureSpecialType(SpecialType.System_Void, bag) 313EnsureSpecialType(SpecialType.System_ValueType, bag)
Lowering\AsyncRewriter\AsyncStateMachine.vb (2)
22asyncMethod.ContainingAssembly.GetSpecialType(If(typeKind = TypeKind.Struct, SpecialType.System_ValueType, SpecialType.System_Object)),
Lowering\ExpressionLambdaRewriter\ExpressionLambdaRewriter.vb (3)
81_int32Type = _factory.SpecialType(SpecialType.System_Int32) 90_objectType = _factory.SpecialType(SpecialType.System_Object) 684If resultType.SpecialType = SpecialType.System_Int64 Then
Lowering\ExpressionLambdaRewriter\ExpressionLambdaRewriter_BinaryOperator.vb (18)
139Dim resultUnderlyingSpecialType As SpecialType = resultUnderlyingType.SpecialType 178Dim operandUnderlyingSpecialType As SpecialType = operandUnderlyingType.SpecialType 194Debug.Assert(operandUnderlyingSpecialType <> SpecialType.System_Object OrElse isIsIsNot) 197Debug.Assert(operandUnderlyingSpecialType <> SpecialType.System_String) 199If operandUnderlyingSpecialType = SpecialType.System_Decimal Then 201ElseIf operandUnderlyingSpecialType = SpecialType.System_DateTime Then 216If operandUnderlyingSpecialType = SpecialType.System_Boolean Then 272Dim resultUnderlyingSpecialType As SpecialType = resultUnderlyingType.SpecialType 287Dim systemBool As TypeSymbol = _factory.SpecialType(SpecialType.System_Boolean) 313Dim resultUnderlyingSpecialType As SpecialType = resultUnderlyingType.SpecialType 326If resultUnderlyingSpecialType = SpecialType.System_Object Then 329ElseIf resultUnderlyingSpecialType = SpecialType.System_Decimal Then 352Dim needToCastBackToByteOrSByte As Boolean = resultUnderlyingSpecialType = SpecialType.System_Byte OrElse 353resultUnderlyingSpecialType = SpecialType.System_SByte 378Debug.Assert(resultUnderlyingSpecialType = SpecialType.System_Byte OrElse resultUnderlyingSpecialType = SpecialType.System_SByte) 429Debug.Assert(conversion.Type.IsNullableType AndAlso conversion.Type.GetNullableUnderlyingType.SpecialType = SpecialType.System_Int32) 471Dim isInt32 As Boolean = shiftedType.GetNullableUnderlyingTypeOrSelf.SpecialType = SpecialType.System_Int32
Lowering\ExpressionLambdaRewriter\ExpressionLambdaRewriter_Conversion.vb (122)
241Return CreateTypeAs(If(typeTo.SpecialType = SpecialType.System_Object, 247Return ConvertIfNeeded(objectConversion, _factory.SpecialType(SpecialType.System_Object), typeTo, False) 258argumentType = _factory.SpecialType(SpecialType.System_String) 261argumentType = _factory.SpecialType(SpecialType.System_Object) 273Dim typeBeforeNegationIsByte As Boolean = typeBeforeNegation.SpecialType = SpecialType.System_SByte 276typeBeforeNegation = _factory.SpecialType(SpecialType.System_Int32) 311Case SpecialType.System_Byte 312Return Me._factory.SpecialType(SpecialType.System_SByte) 313Case SpecialType.System_UInt16 314Return Me._factory.SpecialType(SpecialType.System_Int16) 315Case SpecialType.System_UInt32 316Return Me._factory.SpecialType(SpecialType.System_Int32) 317Case SpecialType.System_UInt64 318Return Me._factory.SpecialType(SpecialType.System_Int64) 428Private Function GetConversionHelperMethod(stFrom As SpecialType, stTo As SpecialType) As MethodSymbol 433Case SpecialType.System_Boolean 435Case SpecialType.System_SByte : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanInt32 436Case SpecialType.System_Byte : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanInt32 437Case SpecialType.System_Int16 : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanInt32 438Case SpecialType.System_UInt16 : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanInt32 439Case SpecialType.System_Int32 : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanInt32 440Case SpecialType.System_UInt32 : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanUInt32 441Case SpecialType.System_Int64 : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanInt64 442Case SpecialType.System_UInt64 : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanUInt64 443Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanSingle 444Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanDouble 445Case SpecialType.System_Decimal : wellKnownHelper = WellKnownMember.System_Convert__ToBooleanDecimal 446Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToBooleanString 447Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToBooleanObject 450Case SpecialType.System_Byte 452Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToByteDouble 453Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToByteSingle 454Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToByte 455Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToByteString 456Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToByteObject 459Case SpecialType.System_SByte 461Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToSByteDouble 462Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToSByteSingle 463Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToSByte 464Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToSByteString 465Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToSByteObject 468Case SpecialType.System_Int16 470Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToInt16Double 471Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToInt16Single 472Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToInt16 473Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToShortString 474Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToShortObject 477Case SpecialType.System_UInt16 479Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToUInt16Double 480Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToUInt16Single 481Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToUInt16 482Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToUShortString 483Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToUShortObject 486Case SpecialType.System_Int32 488Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToInt32Double 489Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToInt32Single 490Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToInt32 491Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToIntegerString 492Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToIntegerObject 495Case SpecialType.System_UInt32 497Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToUInt32Double 498Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToUInt32Single 499Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToUInt32 500Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToUIntegerString 501Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToUIntegerObject 504Case SpecialType.System_Int64 506Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToInt64Double 507Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToInt64Single 508Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToInt64 509Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToLongString 510Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToLongObject 513Case SpecialType.System_UInt64 515Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.System_Convert__ToUInt64Double 516Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.System_Convert__ToUInt64Single 517Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToUInt64 518Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToULongString 519Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToULongObject 522Case SpecialType.System_Decimal 524Case SpecialType.System_SByte : specialHelper = SpecialMember.System_Decimal__op_Implicit_FromInt32 525Case SpecialType.System_Byte : specialHelper = SpecialMember.System_Decimal__op_Implicit_FromInt32 526Case SpecialType.System_Int16 : specialHelper = SpecialMember.System_Decimal__op_Implicit_FromInt32 527Case SpecialType.System_UInt16 : specialHelper = SpecialMember.System_Decimal__op_Implicit_FromInt32 528Case SpecialType.System_Int32 : specialHelper = SpecialMember.System_Decimal__op_Implicit_FromInt32 529Case SpecialType.System_UInt32 : specialHelper = SpecialMember.System_Decimal__op_Implicit_FromUInt32 530Case SpecialType.System_Int64 : specialHelper = SpecialMember.System_Decimal__op_Implicit_FromInt64 531Case SpecialType.System_UInt64 : specialHelper = SpecialMember.System_Decimal__op_Implicit_FromUInt64 532Case SpecialType.System_Single : specialHelper = SpecialMember.System_Decimal__op_Explicit_FromSingle 533Case SpecialType.System_Double : specialHelper = SpecialMember.System_Decimal__op_Explicit_FromDouble 534Case SpecialType.System_Boolean : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDecimalBoolean 535Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDecimalString 536Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDecimalObject 539Case SpecialType.System_Single 541Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToSingle 542Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToSingleString 543Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToSingleObject 546Case SpecialType.System_Double 548Case SpecialType.System_Decimal : specialHelper = SpecialMember.System_Decimal__op_Explicit_ToDouble 549Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDoubleString 550Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDoubleObject 553Case SpecialType.System_Char 555Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToCharString 556Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToCharObject 559Case SpecialType.System_String 561Case SpecialType.System_Boolean : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringBoolean 562Case SpecialType.System_SByte, 563SpecialType.System_Int16, 564SpecialType.System_Int32 : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringInt32 566Case SpecialType.System_Byte : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringByte 568Case SpecialType.System_UInt16, 569SpecialType.System_UInt32 : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringUInt32 571Case SpecialType.System_Int64 : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringInt64 572Case SpecialType.System_UInt64 : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringUInt64 573Case SpecialType.System_Single : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringSingle 574Case SpecialType.System_Double : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringDouble 575Case SpecialType.System_Decimal : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringDecimal 576Case SpecialType.System_DateTime : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringDateTime 577Case SpecialType.System_Char : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringChar 578Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringObject 581Case SpecialType.System_DateTime 583Case SpecialType.System_String : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDateString 584Case SpecialType.System_Object : wellKnownHelper = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDateObject
Lowering\ExpressionLambdaRewriter\ExpressionLambdaRewriter_UnaryOperator.vb (3)
26Dim origArgUnderlyingSpecialType As SpecialType = origArgUnderlyingType.SpecialType 73Dim needToCastBackToByteOrSByte As Boolean = origArgUnderlyingSpecialType = SpecialType.System_Byte OrElse 74origArgUnderlyingSpecialType = SpecialType.System_SByte
Lowering\Instrumentation\CodeCoverageInstrumenter.vb (3)
119Dim payloadElementType As TypeSymbol = methodBodyFactory.SpecialType(SpecialType.System_Boolean) 216methodBodyFactory.SpecialType(SpecialType.System_Int32), fileIndices.ToImmutable()) 285_methodBodyFactory.SpecialType(SpecialType.System_Boolean),
Lowering\IteratorRewriter\IteratorRewriter.vb (16)
37Me._elementType = method.ContainingAssembly.GetSpecialType(SpecialType.System_Object) 63Dim isEnumerable As Boolean = retSpecialType = SpecialType.System_Collections_Generic_IEnumerable_T OrElse 64retSpecialType = SpecialType.System_Collections_IEnumerable 68elementType = method.ContainingAssembly.GetSpecialType(SpecialType.System_Object) 103EnsureSpecialType(SpecialType.System_Object, bag) 104EnsureSpecialType(SpecialType.System_Boolean, bag) 105EnsureSpecialType(SpecialType.System_Int32, bag) 106EnsureSpecialType(SpecialType.System_IDisposable, bag) 110EnsureSpecialType(SpecialType.System_Collections_IEnumerator, bag) 116EnsureSpecialType(SpecialType.System_Collections_Generic_IEnumerator_T, bag) 120EnsureSpecialType(SpecialType.System_Collections_IEnumerable, bag) 122EnsureSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T, bag) 139Me.StateField = Me.F.StateMachineField(Me.F.SpecialType(SpecialType.System_Int32), Me.Method, GeneratedNames.MakeStateMachineStateFieldName(), Accessibility.Public) 146F.StateMachineField(F.SpecialType(SpecialType.System_Int32), Me.Method, GeneratedNames.MakeIteratorInitialThreadIdName(), Accessibility.Public), 181Dim getEnumeratorGeneric = Me.OpenMethodImplementation(F.SpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(_elementType), 275Me.OpenPropertyImplementation(F.SpecialType(SpecialType.System_Collections_Generic_IEnumerator_T).Construct(_elementType),
Lowering\IteratorRewriter\IteratorStateMachine.vb (7)
29iteratorMethod.ContainingAssembly.GetSpecialType(SpecialType.System_Object), 34Dim intType = DeclaringCompilation.GetSpecialType(SpecialType.System_Int32) 51interfaces.Add(containingAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(elementType)) 52interfaces.Add(containingAssembly.GetSpecialType(SpecialType.System_Collections_IEnumerable)) 55interfaces.Add(containingAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerator_T).Construct(elementType)) 56interfaces.Add(containingAssembly.GetSpecialType(SpecialType.System_IDisposable)) 57interfaces.Add(containingAssembly.GetSpecialType(SpecialType.System_Collections_IEnumerator))
Lowering\LambdaRewriter\LambdaFrame.vb (2)
178Dim type = ContainingAssembly.GetSpecialType(SpecialType.System_Object) 190Dim type = ContainingAssembly.GetSpecialType(SpecialType.System_Object)
Lowering\LambdaRewriter\LambdaRewriter.vb (2)
430Dim bool = frame.ContainingAssembly.GetSpecialType(SpecialType.System_Boolean) 434Dim obj = frame.ContainingAssembly.GetSpecialType(SpecialType.System_Object)
Lowering\LocalRewriter\LocalRewriter.vb (3)
559Private Function GetSpecialType(specialType As SpecialType) As NamedTypeSymbol 565Private Function GetSpecialTypeWithUseSiteDiagnostics(specialType As SpecialType, syntax As SyntaxNode) As NamedTypeSymbol 772If type.SpecialType = SpecialType.System_Void Then
Lowering\LocalRewriter\LocalRewriter_BinaryOperators.vb (4)
488Debug.Assert(memberSymbol.ReturnType.SpecialType = SpecialType.System_Int32) 527Debug.Assert(memberSymbol.ReturnType.SpecialType = SpecialType.System_Int32) 699Debug.Assert(memberSymbol.ReturnType.SpecialType = SpecialType.System_Int32) 765Debug.Assert(memberSymbol.Parameters(2).Type.GetEnumUnderlyingTypeOrSelf().SpecialType = SpecialType.System_Int32)
Lowering\LocalRewriter\LocalRewriter_Constant.vb (2)
47currentMethod.ContainingType.SpecialType <> SpecialType.System_Decimal Then 147currentMethod.ContainingType.SpecialType <> SpecialType.System_DateTime) Then
Lowering\LocalRewriter\LocalRewriter_Conversion.vb (72)
138If specialType <> SpecialType.System_Double AndAlso specialType <> SpecialType.System_Single Then 318node.Type.SpecialType <> SpecialType.System_MulticastDelegate) 863result = RewriteFromObjectConversion(rewrittenConversion, Compilation.GetSpecialType(SpecialType.System_Object), underlyingTypeTo) 925Case SpecialType.System_Boolean : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToBooleanObject 926Case SpecialType.System_SByte : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToSByteObject 927Case SpecialType.System_Byte : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToByteObject 928Case SpecialType.System_Int16 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToShortObject 929Case SpecialType.System_UInt16 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToUShortObject 930Case SpecialType.System_Int32 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToIntegerObject 931Case SpecialType.System_UInt32 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToUIntegerObject 932Case SpecialType.System_Int64 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToLongObject 933Case SpecialType.System_UInt64 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToULongObject 934Case SpecialType.System_Single : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToSingleObject 935Case SpecialType.System_Double : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDoubleObject 936Case SpecialType.System_Decimal : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDecimalObject 937Case SpecialType.System_DateTime : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDateObject 938Case SpecialType.System_Char : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToCharObject 939Case SpecialType.System_String : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringObject 1015Case SpecialType.System_Boolean : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringBoolean 1016Case SpecialType.System_SByte, 1017SpecialType.System_Int16, 1018SpecialType.System_Int32 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringInt32 1020Case SpecialType.System_Byte : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringByte 1022Case SpecialType.System_UInt16, 1023SpecialType.System_UInt32 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringUInt32 1025Case SpecialType.System_Int64 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringInt64 1026Case SpecialType.System_UInt64 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringUInt64 1027Case SpecialType.System_Single : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringSingle 1028Case SpecialType.System_Double : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringDouble 1029Case SpecialType.System_Decimal : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringDecimal 1030Case SpecialType.System_DateTime : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringDateTime 1031Case SpecialType.System_Char : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToStringChar 1090Case SpecialType.System_Boolean : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToBooleanString 1091Case SpecialType.System_SByte : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToSByteString 1092Case SpecialType.System_Byte : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToByteString 1093Case SpecialType.System_Int16 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToShortString 1094Case SpecialType.System_UInt16 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToUShortString 1095Case SpecialType.System_Int32 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToIntegerString 1096Case SpecialType.System_UInt32 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToUIntegerString 1097Case SpecialType.System_Int64 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToLongString 1098Case SpecialType.System_UInt64 : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToULongString 1099Case SpecialType.System_Single : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToSingleString 1100Case SpecialType.System_Double : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDoubleString 1101Case SpecialType.System_Decimal : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDecimalString 1102Case SpecialType.System_DateTime : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToDateString 1103Case SpecialType.System_Char : member = WellKnownMember.Microsoft_VisualBasic_CompilerServices_Conversions__ToCharString 1159Case SpecialType.System_SByte, 1160SpecialType.System_Byte, 1161SpecialType.System_Int16, 1162SpecialType.System_UInt16, 1163SpecialType.System_Int32 : member = SpecialMember.System_Decimal__CtorInt32 1164Case SpecialType.System_UInt32 : member = SpecialMember.System_Decimal__CtorUInt32 1165Case SpecialType.System_Int64 : member = SpecialMember.System_Decimal__CtorInt64 1166Case SpecialType.System_UInt64 : member = SpecialMember.System_Decimal__CtorUInt64 1167Case SpecialType.System_Single : member = SpecialMember.System_Decimal__CtorSingle 1168Case SpecialType.System_Double : member = SpecialMember.System_Decimal__CtorDouble 1230Case SpecialType.System_Boolean : member = WellKnownMember.System_Convert__ToBooleanDecimal 1231Case SpecialType.System_SByte : member = WellKnownMember.System_Convert__ToSByteDecimal 1232Case SpecialType.System_Byte : member = WellKnownMember.System_Convert__ToByteDecimal 1233Case SpecialType.System_Int16 : member = WellKnownMember.System_Convert__ToInt16Decimal 1234Case SpecialType.System_UInt16 : member = WellKnownMember.System_Convert__ToUInt16Decimal 1235Case SpecialType.System_Int32 : member = WellKnownMember.System_Convert__ToInt32Decimal 1236Case SpecialType.System_UInt32 : member = WellKnownMember.System_Convert__ToUInt32Decimal 1237Case SpecialType.System_Int64 : member = WellKnownMember.System_Convert__ToInt64Decimal 1238Case SpecialType.System_UInt64 : member = WellKnownMember.System_Convert__ToUInt64Decimal 1239Case SpecialType.System_Single : member = WellKnownMember.System_Convert__ToSingleDecimal 1240Case SpecialType.System_Double : member = WellKnownMember.System_Convert__ToDoubleDecimal 1335Case SpecialType.System_Single 1337Case SpecialType.System_Double 1354Case SpecialType.System_Single 1356Case SpecialType.System_Double
Lowering\LocalRewriter\LocalRewriter_ForEach.vb (9)
209Debug.Assert(collectionExpression.Type.SpecialType = SpecialType.System_String OrElse 242Dim integerType = GetSpecialTypeWithUseSiteDiagnostics(SpecialType.System_Int32, syntaxNode) 245ConstantValue.Default(SpecialType.System_Int32), 286elementType = GetSpecialType(SpecialType.System_Char) 366Debug.Assert(expressionType.SpecialType <> SpecialType.System_Object) 397Debug.Assert(expressionType.SpecialType <> SpecialType.System_Object) 465Dim booleanType = GetSpecialTypeWithUseSiteDiagnostics(SpecialType.System_Boolean, statementSyntax) 592Debug.Assert(enumeratorInfo.MoveNext.Type.SpecialType = SpecialType.System_Boolean) 724Dim voidType = GetSpecialTypeWithUseSiteDiagnostics(SpecialType.System_Void, syntaxNode)
Lowering\LocalRewriter\LocalRewriter_ForTo.vb (7)
141type:=GetSpecialType(SpecialType.System_Boolean))) 416Debug.Assert(Compilation.GetSpecialType(SpecialType.System_Object) Is rewrittenControlVariable.Type) 445Compilation.GetSpecialType(SpecialType.System_Boolean), 449arguments, Compilation.GetSpecialType(SpecialType.System_Boolean), hasErrors:=True) 500Compilation.GetSpecialType(SpecialType.System_Boolean), 504arguments, Compilation.GetSpecialType(SpecialType.System_Boolean), hasErrors:=True) 679Dim booleanType = GetSpecialType(SpecialType.System_Boolean)
Lowering\LocalRewriter\LocalRewriter_InterpolatedString.vb (1)
19Debug.Assert(node.Type.SpecialType = SpecialType.System_String)
Lowering\LocalRewriter\LocalRewriter_LateBindingHelpers.vb (13)
74Dim intType = Me.GetSpecialType(SpecialType.System_Int32) 114Dim intType = Me.GetSpecialType(SpecialType.System_Int32) 203Dim intType = Me.GetSpecialType(SpecialType.System_Int32) 270Dim intType = Me.GetSpecialType(SpecialType.System_Int32) 328Dim intType = Me.GetSpecialType(SpecialType.System_Int32) 345Dim intType = Me.GetSpecialType(SpecialType.System_Int32) 402Me.GetSpecialType(SpecialType.System_Void)) 461Me.GetSpecialType(SpecialType.System_Void)) 535Return New BoundSequence(syntax, ImmutableArray(Of LocalSymbol).Empty, ImmutableArray.Create(Of BoundExpression)(memberAccess), Nothing, Me.GetSpecialType(SpecialType.System_Void)) 540Return New BoundSequence(syntax, ImmutableArray(Of LocalSymbol).Empty, ImmutableArray.Create(Of BoundExpression)(memberAccess), Nothing, Me.GetSpecialType(SpecialType.System_Void)) 614Return New BoundSequence(syntax, ImmutableArray(Of LocalSymbol).Empty, ImmutableArray.Create(Of BoundExpression)(invocation), Nothing, Me.GetSpecialType(SpecialType.System_Void)) 619Return New BoundSequence(syntax, ImmutableArray(Of LocalSymbol).Empty, ImmutableArray.Create(Of BoundExpression)(invocation), Nothing, Me.GetSpecialType(SpecialType.System_Void)) 952Dim intType = Me.GetSpecialType(SpecialType.System_Int32)
Lowering\LocalRewriter\LocalRewriter_LocalDeclaration.vb (2)
173Dim objectType = GetSpecialTypeWithUseSiteDiagnostics(SpecialType.System_Object, syntax) 174Dim booleanType = GetSpecialTypeWithUseSiteDiagnostics(SpecialType.System_Boolean, syntax)
Lowering\LocalRewriter\LocalRewriter_NullableHelpers.vb (2)
67hasValueExpr = New BoundLiteral(operand.Syntax, ConstantValue.True, Me.GetSpecialType(SpecialType.System_Boolean)) 263Me.Compilation.GetSpecialType(SpecialType.System_Boolean), hasErrors:=True)
Lowering\LocalRewriter\LocalRewriter_ObjectCreation.vb (1)
333sequenceType = GetSpecialType(SpecialType.System_Void)
Lowering\LocalRewriter\LocalRewriter_RaiseEvent.vb (2)
80Me.Compilation.GetSpecialType(SpecialType.System_Object)), 82Me.Compilation.GetSpecialType(SpecialType.System_Boolean)).MakeCompilerGenerated
Lowering\LocalRewriter\LocalRewriter_RedimClause.vb (1)
95Compilation.GetSpecialType(SpecialType.System_Void)))
Lowering\LocalRewriter\LocalRewriter_SelectCase.vb (3)
171Me.ReportBadType(selectCaseExpr, Compilation.GetSpecialType(SpecialType.System_Int32)) 172Me.ReportBadType(selectCaseExpr, Compilation.GetSpecialType(SpecialType.System_UInt32)) 173Me.ReportBadType(selectCaseExpr, Compilation.GetSpecialType(SpecialType.System_String))
Lowering\LocalRewriter\LocalRewriter_StringConcat.vb (1)
121If method.IsShared AndAlso method.ContainingType.SpecialType = SpecialType.System_String Then
Lowering\LocalRewriter\LocalRewriter_SyncLock.vb (1)
24Dim objectType = GetSpecialType(SpecialType.System_Object)
Lowering\LocalRewriter\LocalRewriter_Throw.vb (1)
22If expressionOpt.Type.SpecialType = SpecialType.System_Int32 Then
Lowering\LocalRewriter\LocalRewriter_UnstructuredExceptionHandling.vb (4)
42Dim int32 = nodeFactory.SpecialType(SpecialType.System_Int32) 144Dim int32 = nodeFactory.SpecialType(SpecialType.System_Int32) 145Dim bool = nodeFactory.SpecialType(SpecialType.System_Boolean) 408nodeFactory.SpecialType(SpecialType.System_Boolean),
Lowering\LocalRewriter\LocalRewriter_XmlLiterals.vb (3)
261Me.GetSpecialType(SpecialType.System_Int32))), 326Return New BoundLiteral(syntax, ConstantValue.Create(str), GetSpecialType(SpecialType.System_String)).MakeCompilerGenerated() 350Dim size = (New BoundLiteral(syntax, ConstantValue.Create(items.Length), GetSpecialType(SpecialType.System_Int32))).MakeCompilerGenerated()
Lowering\MethodToClassRewriter\MethodToClassRewriter.vb (1)
485Debug.Assert(node.ValueOpt IsNot Nothing OrElse node.HasErrors OrElse node.Type.SpecialType = SpecialType.System_Void)
Lowering\StateMachineRewriter\StateMachineRewriter.StateMachineMethodToClassRewriter.vb (1)
95CachedState = F.SynthesizedLocal(F.SpecialType(SpecialType.System_Int32), SynthesizedLocalKind.StateMachineCachedState, F.Syntax)
Lowering\StateMachineRewriter\StateMachineRewriter.vb (1)
378Friend Function EnsureSpecialType(type As SpecialType, bag As BindingDiagnosticBag) As Symbol
Lowering\SyntheticBoundNodeFactory.vb (18)
226Public Function SpecialType(st As SpecialType) As NamedTypeSymbol 232Dim nullableType As NamedTypeSymbol = SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Nullable_T) 423Return Binary(BinaryOperatorKind.AndAlso, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right) 427Return Binary(BinaryOperatorKind.OrElse, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right) 431Return Binary(BinaryOperatorKind.Equals, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right) 435Return Binary(BinaryOperatorKind.LessThan, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right) 439Dim boundNode = New BoundLiteral(_syntax, ConstantValue.Create(value), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean)) 445Dim boundNode = New BoundLiteral(_syntax, ConstantValue.Create(value), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 758Dim boundNode = New BoundLiteral(_syntax, ConstantValue.Create(value), SpecialType(Microsoft.CodeAnalysis.SpecialType.System_String)) 765Dim boundNode = New BoundLiteral(_syntax, value, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_String)) 928Dim boundNode As New BoundMethodDefIndex(Syntax, method, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 937Dim boundNode As New BoundMaximumMethodDefIndex(Syntax, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 955Dim boundNode As New BoundModuleVersionIdString(Syntax, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_String)) 975Dim boundNode As New BoundSourceDocumentIndex(Syntax, document, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32)) 1032Dim boundNode = Binary(BinaryOperatorKind.Is, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), left, right) 1039Dim boundNode = Binary(BinaryOperatorKind.Is, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), operand, Me.Null(operand.Type)) 1046Dim boundNode = Binary(BinaryOperatorKind.IsNot, SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Boolean), operand, Me.Null(operand.Type)) 1103Me.SpecialType(Microsoft.CodeAnalysis.SpecialType.System_Void),
Operations\VisualBasicOperationFactory.vb (1)
1415DirectCast(_semanticModel.Compilation.GetSpecialType(SpecialType.System_Boolean), TypeSymbol),
Operations\VisualBasicOperationFactory_Methods.vb (2)
666Return If(leftOpt?.Type?.SpecialType = SpecialType.System_Object, BinaryOperatorKind.ObjectValueEquals, BinaryOperatorKind.Equals) 668Return If(leftOpt?.Type?.SpecialType = SpecialType.System_Object, BinaryOperatorKind.ObjectValueNotEquals, BinaryOperatorKind.NotEquals)
Preprocessor\CConst.vb (39)
24Public MustOverride ReadOnly Property SpecialType As SpecialType 41Case SpecialType.System_Boolean 43Case SpecialType.System_Byte 45Case SpecialType.System_Char 47Case SpecialType.System_DateTime 49Case SpecialType.System_Decimal 51Case SpecialType.System_Double 53Case SpecialType.System_Int16 55Case SpecialType.System_Int32 57Case SpecialType.System_Int64 59Case SpecialType.System_SByte 61Case SpecialType.System_Single 63Case SpecialType.System_String 65Case SpecialType.System_UInt16 67Case SpecialType.System_UInt32 69Case SpecialType.System_UInt64 77Return New CConst(Of Object)(Nothing, SpecialType.System_Object) 81Return New CConst(Of Boolean)(value, SpecialType.System_Boolean) 85Return New CConst(Of Byte)(value, SpecialType.System_Byte) 89Return New CConst(Of SByte)(value, SpecialType.System_SByte) 93Return New CConst(Of Char)(value, SpecialType.System_Char) 97Return New CConst(Of Short)(value, SpecialType.System_Int16) 101Return New CConst(Of UShort)(value, SpecialType.System_UInt16) 105Return New CConst(Of Integer)(value, SpecialType.System_Int32) 109Return New CConst(Of UInteger)(value, SpecialType.System_UInt32) 113Return New CConst(Of Long)(value, SpecialType.System_Int64) 117Return New CConst(Of ULong)(value, SpecialType.System_UInt64) 121Return New CConst(Of Decimal)(value, SpecialType.System_Decimal) 125Return New CConst(Of String)(value, SpecialType.System_String) 129Return New CConst(Of Single)(value, SpecialType.System_Single) 133Return New CConst(Of Double)(value, SpecialType.System_Double) 137Return New CConst(Of Date)(value, SpecialType.System_DateTime) 142Return SpecialType = SpecialType.None 180Private ReadOnly _specialType As SpecialType 183Friend Sub New(value As T, specialType As SpecialType) 188Private Sub New(value As T, specialType As SpecialType, id As ERRID) 195Public Overrides ReadOnly Property SpecialType As SpecialType 229Public Overrides ReadOnly Property SpecialType As SpecialType 231Return SpecialType.None
Preprocessor\ExpressionEvaluator.vb (190)
25Const _____Byte = CType(SpecialType.System_Byte, Byte) 26Const ____SByte = CType(SpecialType.System_SByte, Byte) 27Const ____Int16 = CType(SpecialType.System_Int16, Byte) 28Const ___UInt16 = CType(SpecialType.System_UInt16, Byte) 29Const ____Int32 = CType(SpecialType.System_Int32, Byte) 30Const ___UInt32 = CType(SpecialType.System_UInt32, Byte) 31Const ____Int64 = CType(SpecialType.System_Int64, Byte) 32Const ___UInt64 = CType(SpecialType.System_UInt64, Byte) 33Const ___Single = CType(SpecialType.System_Single, Byte) 34Const ___Double = CType(SpecialType.System_Double, Byte) 35Const __Decimal = CType(SpecialType.System_Decimal, Byte) 36Const _DateTime = CType(SpecialType.System_DateTime, Byte) 37Const _____Char = CType(SpecialType.System_Char, Byte) 38Const __Boolean = CType(SpecialType.System_Boolean, Byte) 39Const ___String = CType(SpecialType.System_String, Byte) 40Const ___Object = CType(SpecialType.System_Object, Byte) 73Private Shared Function TypeCodeToDominantTypeIndex(specialType As SpecialType) As Integer 75Case SpecialType.System_Byte 77Case SpecialType.System_SByte 79Case SpecialType.System_Int16 81Case SpecialType.System_UInt16 83Case SpecialType.System_Int32 85Case SpecialType.System_UInt32 87Case SpecialType.System_Int64 89Case SpecialType.System_UInt64 91Case SpecialType.System_Single 93Case SpecialType.System_Double 95Case SpecialType.System_Decimal 97Case SpecialType.System_DateTime 99Case SpecialType.System_Char 101Case SpecialType.System_Boolean 103Case SpecialType.System_String 105Case SpecialType.System_Object 325Private Shared Function AsTypeCharacter(specialType As SpecialType) As TypeCharacter 327Case SpecialType.System_Int32 330Case SpecialType.System_Int64 333Case SpecialType.System_Decimal 336Case SpecialType.System_Single 339Case SpecialType.System_Double 342Case SpecialType.System_String 350Private Shared Function GetSpecialType(predefinedType As PredefinedTypeSyntax) As SpecialType 354Return SpecialType.System_Int16 357Return SpecialType.System_UInt16 360Return SpecialType.System_Int32 363Return SpecialType.System_UInt32 366Return SpecialType.System_Int64 369Return SpecialType.System_UInt64 372Return SpecialType.System_Decimal 375Return SpecialType.System_Single 378Return SpecialType.System_Double 381Return SpecialType.System_SByte 384Return SpecialType.System_Byte 387Return SpecialType.System_Boolean 390Return SpecialType.System_Char 393Return SpecialType.System_DateTime 396Return SpecialType.System_String 400Return SpecialType.System_Object 417If specialType <> SpecialType.System_Object AndAlso specialType <> SpecialType.System_String Then 421If value.SpecialType = SpecialType.System_Object OrElse 422value.SpecialType = SpecialType.System_String Then 428If specialType = SpecialType.System_Double OrElse specialType = SpecialType.System_Single Then 448If val.SpecialType = SpecialType.System_Object OrElse 449val.SpecialType = SpecialType.System_String Then 455If specialType = SpecialType.System_Double OrElse specialType = SpecialType.System_Single Then 483Dim specialType As SpecialType 487specialType = SpecialType.System_Boolean 490specialType = SpecialType.System_DateTime 493specialType = SpecialType.System_Double 496specialType = SpecialType.System_SByte 499specialType = SpecialType.System_Byte 502specialType = SpecialType.System_Char 505specialType = SpecialType.System_Int16 508specialType = SpecialType.System_UInt16 511specialType = SpecialType.System_Int32 514specialType = SpecialType.System_UInt32 517specialType = SpecialType.System_Int64 520specialType = SpecialType.System_UInt64 523specialType = SpecialType.System_Single 526specialType = SpecialType.System_String 529specialType = SpecialType.System_Decimal 573If Not IsNothing(whenFalse) AndAlso whenFalse.SpecialType <> SpecialType.System_Object Then 577If whenTrue.SpecialType <> SpecialType.System_Object Then 581Dim dominantType As SpecialType = CType(s_dominantType(TypeCodeToDominantTypeIndex(whenTrue.SpecialType), TypeCodeToDominantTypeIndex(whenFalse.SpecialType)), SpecialType) 611If specialType = SpecialType.System_Boolean Then 620Case SpecialType.System_Char 621Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, SpecialType.System_Char.GetDisplayName(), SpecialType.System_Boolean.GetDisplayName()) 622Case SpecialType.System_DateTime 623Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, SpecialType.System_DateTime.GetDisplayName(), SpecialType.System_Boolean.GetDisplayName()) 624Case SpecialType.System_Object 630Case SpecialType.System_String 631Return ReportSemanticError(ERRID.ERR_RequiredConstConversion2, expr, SpecialType.System_String.GetDisplayName(), SpecialType.System_Boolean.GetDisplayName()) 633Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, specialType, SpecialType.System_Boolean.GetDisplayName()) 637Private Shared Function ConvertToNumeric(value As CConst, toSpecialType As SpecialType, expr As ExpressionSyntax) As CConst 659Case SpecialType.System_Boolean 663numericVal = NarrowIntegralResult(numericVal, SpecialType.System_Int64, toSpecialType, False) 667Case SpecialType.System_Char 668Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, SpecialType.System_Char.GetDisplayName(), toSpecialType.GetDisplayName()) 670Case SpecialType.System_DateTime 671Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, SpecialType.System_DateTime.GetDisplayName(), toSpecialType.GetDisplayName()) 673Case SpecialType.System_Object 676Case SpecialType.System_String 677Return ReportSemanticError(ERRID.ERR_RequiredConstConversion2, expr, SpecialType.System_String.GetDisplayName(), toSpecialType.GetDisplayName()) 684Private Shared Function ConvertNumericToNumeric(value As CConst, toSpecialType As SpecialType, expr As ExpressionSyntax) As CConst 695Private Shared Function Convert(value As CConst, toSpecialType As SpecialType, expr As ExpressionSyntax) As CConst 710Case SpecialType.System_Boolean 712Case SpecialType.System_Char 714Case SpecialType.System_DateTime 716Case SpecialType.System_Object 718Case SpecialType.System_String 731If fromSpecialType = SpecialType.System_Char Then 740Case SpecialType.System_Boolean 741Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, fromSpecialType, SpecialType.System_Char.GetDisplayName()) 743Case SpecialType.System_DateTime 744Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, fromSpecialType, SpecialType.System_Char.GetDisplayName()) 746Case SpecialType.System_Object 753Case SpecialType.System_String 759Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, fromSpecialType, SpecialType.System_Char.GetDisplayName()) 769If fromSpecialType = SpecialType.System_DateTime Then 774Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, fromSpecialType, SpecialType.System_DateTime.GetDisplayName()) 778Case SpecialType.System_Boolean 779Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, fromSpecialType, SpecialType.System_DateTime.GetDisplayName()) 781Case SpecialType.System_Char 782Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, fromSpecialType, SpecialType.System_DateTime.GetDisplayName()) 784Case SpecialType.System_String 787Case SpecialType.System_Object 795Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, fromSpecialType, SpecialType.System_DateTime.GetDisplayName()) 805If specialType = SpecialType.System_String Then 814Case SpecialType.System_Boolean 817Case SpecialType.System_Char 821Case SpecialType.System_DateTime 824Case SpecialType.System_Object 832Return ReportSemanticError(ERRID.ERR_TypeMismatch2, expr, specialType, SpecialType.System_String.GetDisplayName()) 845Return ReportSemanticError(ERRID.ERR_RequiredConstConversion2, expr, value.SpecialType.GetDisplayName(), SpecialType.System_Object.GetDisplayName()) 852If specialType = SpecialType.None Then 856If specialType = SpecialType.System_String OrElse 857(specialType = SpecialType.System_Object AndAlso Not IsNothing(val)) OrElse 858specialType = SpecialType.System_Char OrElse specialType = SpecialType.System_DateTime Then 869Case SpecialType.System_Boolean 871Case SpecialType.System_Byte 873Case SpecialType.System_Decimal 875Case SpecialType.System_Double 877Case SpecialType.System_Int16 879Case SpecialType.System_Int32 881Case SpecialType.System_Int64 883Case SpecialType.System_SByte 885Case SpecialType.System_Single 887Case SpecialType.System_UInt16 889Case SpecialType.System_UInt32 891Case SpecialType.System_UInt64 898If specialType = SpecialType.System_Boolean Then 908Case SpecialType.System_Boolean 910Case SpecialType.System_Byte 912Case SpecialType.System_Decimal 914Case SpecialType.System_Double 916Case SpecialType.System_Int16 918Case SpecialType.System_Int32 920Case SpecialType.System_Int64 922Case SpecialType.System_SByte 924Case SpecialType.System_Single 926Case SpecialType.System_UInt16 928Case SpecialType.System_UInt32 930Case SpecialType.System_UInt64 944Return val.SpecialType = SpecialType.System_Object AndAlso val.ValueAsObject Is Nothing 956Dim OperandType As SpecialType = SpecialType.None 1000Right = ConvertToNumeric(Right, SpecialType.System_Int32, expr.Right) 1006Right = ConvertToNumeric(Right, SpecialType.System_Int32, expr.Right) 1023OperandType = SpecialType.System_String 1029OperandType = SpecialType.System_Int32 1045OperandType = SpecialType.System_String 1060If ResultType = SpecialType.None Then 1077If ResultType = SpecialType.System_String Then 1089ResultType = SpecialType.System_Boolean 1103resultType As SpecialType, 1112If left.SpecialType.IsIntegralType() OrElse left.SpecialType = SpecialType.System_Char OrElse left.SpecialType = SpecialType.System_DateTime Then 1116If resultType = SpecialType.System_Boolean Then 1282If resultType = SpecialType.System_Boolean Then 1407ElseIf left.SpecialType = SpecialType.System_Decimal Then 1411If resultType = SpecialType.System_Boolean Then 1491ElseIf left.SpecialType = SpecialType.System_String Then 1540ElseIf left.SpecialType = SpecialType.System_Boolean Then
Preprocessor\OperatorResolution.vb (39)
28Private Function TypeCodeToIndex(specialType As SpecialType) As Integer 30Case SpecialType.None 32Case SpecialType.System_Boolean 34Case SpecialType.System_SByte 36Case SpecialType.System_Byte 38Case SpecialType.System_Int16 40Case SpecialType.System_UInt16 42Case SpecialType.System_Int32 44Case SpecialType.System_UInt32 46Case SpecialType.System_Int64 48Case SpecialType.System_UInt64 50Case SpecialType.System_Decimal 52Case SpecialType.System_Single 54Case SpecialType.System_Double 56Case SpecialType.System_DateTime 58Case SpecialType.System_Char 60Case SpecialType.System_String 62Case SpecialType.System_Object 78Const t_r4 As Byte = CType(SpecialType.System_Single, Byte) 79Const t_r8 As Byte = CType(SpecialType.System_Double, Byte) 80Const t_dec As Byte = CType(SpecialType.System_Decimal, Byte) 81Const t_str As Byte = CType(SpecialType.System_String, Byte) 83Const t_bad As Byte = CType(SpecialType.None, Byte) 84Const t_i1 As Byte = CType(SpecialType.System_SByte, Byte) 85Const t_i2 As Byte = CType(SpecialType.System_Int16, Byte) 86Const t_i4 As Byte = CType(SpecialType.System_Int32, Byte) 87Const t_i8 As Byte = CType(SpecialType.System_Int64, Byte) 88Const t_ui1 As Byte = CType(SpecialType.System_Byte, Byte) 89Const t_ui2 As Byte = CType(SpecialType.System_UInt16, Byte) 90Const t_ui4 As Byte = CType(SpecialType.System_UInt32, Byte) 91Const t_ui8 As Byte = CType(SpecialType.System_UInt64, Byte) 93Const t_ref As Byte = CType(SpecialType.System_Object, Byte) 94Const t_bool As Byte = CType(SpecialType.System_Boolean, Byte) 95Const t_date As Byte = CType(SpecialType.System_DateTime, Byte) 96Const t_char As Byte = CType(SpecialType.System_Char, Byte) 298Friend Function LookupInOperatorTables(opcode As SyntaxKind, left As SpecialType, right As SpecialType) As SpecialType 349Return CType(s_table(whichTable, TypeCodeToIndex(left), TypeCodeToIndex(right)), SpecialType)
Preprocessor\TypeHelpers.vb (2)
29If specialType = SpecialType.System_Char Then 33If specialType = SpecialType.System_DateTime Then
Semantics\CompileTimeCalculations.vb (7)
259sourceType As SpecialType, 260resultType As SpecialType, 550resultType As SpecialType, 559Case SpecialType.System_Double 562Case SpecialType.System_Single 729sourceType As SpecialType, 730resultType As SpecialType,
Semantics\Conversions.vb (37)
1181(originalTargetType.SpecialType = SpecialType.System_Collections_Generic_IEnumerable_T OrElse 1182originalTargetType.SpecialType = SpecialType.System_Collections_Generic_IList_T OrElse 1183originalTargetType.SpecialType = SpecialType.System_Collections_Generic_ICollection_T OrElse 1184originalTargetType.SpecialType = SpecialType.System_Collections_Generic_IReadOnlyList_T OrElse 1185originalTargetType.SpecialType = SpecialType.System_Collections_Generic_IReadOnlyCollection_T) Then 1477Dim nullableOfT As NamedTypeSymbol = booleanType.ContainingAssembly.GetSpecialType(SpecialType.System_Nullable_T) 2062Dim valueType = typeParameter.ContainingAssembly.GetSpecialType(SpecialType.System_ValueType) 2325If source.SpecialType = SpecialType.System_Void OrElse destination.SpecialType = SpecialType.System_Void Then 2344If destination.SpecialType = SpecialType.System_Object Then 2471If dstUnderlyingSpecial <> SpecialType.System_Collections_Generic_IList_T AndAlso 2472dstUnderlyingSpecial <> SpecialType.System_Collections_Generic_ICollection_T AndAlso 2473dstUnderlyingSpecial <> SpecialType.System_Collections_Generic_IEnumerable_T AndAlso 2474dstUnderlyingSpecial <> SpecialType.System_Collections_Generic_IReadOnlyList_T AndAlso 2475dstUnderlyingSpecial <> SpecialType.System_Collections_Generic_IReadOnlyCollection_T Then 3335Case SpecialType.System_Byte, SpecialType.System_SByte, SpecialType.System_Boolean 3337Case SpecialType.System_Int16, SpecialType.System_UInt16 3339Case SpecialType.System_Int32, SpecialType.System_UInt32 3341Case SpecialType.System_Int64, SpecialType.System_UInt64 3380If source.SpecialType = SpecialType.System_Void OrElse destination.SpecialType = SpecialType.System_Void Then 3390If destination.SpecialType = SpecialType.System_Object Then 3423If source.SpecialType = SpecialType.System_Object Then 3619If source.SpecialType = SpecialType.System_String Then 3621ElseIf destination.SpecialType = SpecialType.System_String Then 3630If array.IsSZArray AndAlso array.ElementType.SpecialType = SpecialType.System_Char Then 3704If destination.SpecialType = SpecialType.System_Object Then 3746If destination.SpecialType = SpecialType.System_ValueType Then 3752Dim valueType = typeParameter.ContainingAssembly.GetSpecialType(SpecialType.System_ValueType) 3900If source.SpecialType = SpecialType.System_Object Then 3906If source.SpecialType = SpecialType.System_ValueType Then 3912Dim valueType = typeParameter.ContainingAssembly.GetSpecialType(SpecialType.System_ValueType)
Semantics\Operators.vb (100)
359If method.Parameters(1).Type.GetNullableUnderlyingTypeOrSelf().SpecialType <> Microsoft.CodeAnalysis.SpecialType.System_Int32 Then 429ElseIf If(containingType.SpecialType = SpecialType.System_Nullable_T, 470If containingType.SpecialType = SpecialType.System_Nullable_T Then 501<Out()> ByRef intrinsicOperatorType As SpecialType, 508intrinsicOperatorType = SpecialType.None 529If sourceType.SpecialType <> SpecialType.System_Object AndAlso 559If intrinsicOperatorType <> SpecialType.None Then 576operandSpecialType As SpecialType 577) As SpecialType 579Dim intrinsicOperatorType As SpecialType 589Case SpecialType.System_Boolean, 590SpecialType.System_SByte, 591SpecialType.System_Byte, 592SpecialType.System_Int16, 593SpecialType.System_UInt16, 594SpecialType.System_Int32, 595SpecialType.System_UInt32, 596SpecialType.System_Int64, 597SpecialType.System_UInt64, 598SpecialType.System_Object 602Case SpecialType.System_Decimal, 603SpecialType.System_Single, 604SpecialType.System_Double, 605SpecialType.System_String 607intrinsicOperatorType = SpecialType.System_Int64 610intrinsicOperatorType = SpecialType.None 620Case SpecialType.System_Boolean 621intrinsicOperatorType = SpecialType.System_Int16 623Case SpecialType.System_SByte, 624SpecialType.System_Byte, 625SpecialType.System_Int16, 626SpecialType.System_UInt16, 627SpecialType.System_Int32, 628SpecialType.System_UInt32, 629SpecialType.System_Int64, 630SpecialType.System_UInt64, 631SpecialType.System_Decimal, 632SpecialType.System_Single, 633SpecialType.System_Double, 634SpecialType.System_Object 638Case SpecialType.System_String 639intrinsicOperatorType = SpecialType.System_Double 642intrinsicOperatorType = SpecialType.None 652Case SpecialType.System_Boolean, 653SpecialType.System_Byte 655intrinsicOperatorType = SpecialType.System_Int16 657Case SpecialType.System_SByte, 658SpecialType.System_Int16, 659SpecialType.System_Int32, 660SpecialType.System_Int64, 661SpecialType.System_Decimal, 662SpecialType.System_Single, 663SpecialType.System_Double, 664SpecialType.System_Object 668Case SpecialType.System_UInt16 669intrinsicOperatorType = SpecialType.System_Int32 671Case SpecialType.System_UInt32 672intrinsicOperatorType = SpecialType.System_Int64 674Case SpecialType.System_UInt64 675intrinsicOperatorType = SpecialType.System_Decimal 677Case SpecialType.System_String 678intrinsicOperatorType = SpecialType.System_Double 681intrinsicOperatorType = SpecialType.None 858<Out()> ByRef intrinsicOperatorType As SpecialType, 866intrinsicOperatorType = SpecialType.None 903intrinsicOperatorType = SpecialType.System_Object 929intrinsicOperatorType = SpecialType.System_Object 957If leftSpecialType = SpecialType.None AndAlso leftEnumUnderlying.IsCharSZArray() Then 958leftSpecialType = SpecialType.System_String 961If rightSpecialType = SpecialType.None AndAlso rightEnumUnderlying.IsCharSZArray() Then 962rightSpecialType = SpecialType.System_String 967If intrinsicOperatorType <> SpecialType.None Then 975intrinsicOperatorType <> SpecialType.None AndAlso 976intrinsicOperatorType <> SpecialType.System_String AndAlso 977intrinsicOperatorType <> SpecialType.System_Object AndAlso 992If (leftEnumUnderlying.SpecialType <> SpecialType.System_Object AndAlso 995(rightEnumUnderlying.SpecialType <> SpecialType.System_Object AndAlso 1637left As SpecialType, 1638right As SpecialType 1639) As SpecialType 1645Return SpecialType.None 1697Return CType(BinaryOperatorTables.Table(tableKind, leftIndex.Value, rightIndex.Value), SpecialType) 1721Const tErr As SByte = SpecialType.None 1722Const tObj As SByte = SpecialType.System_Object 1723Const tStr As SByte = SpecialType.System_String 1724Const tDbl As SByte = SpecialType.System_Double 1725Const tSBy As SByte = SpecialType.System_SByte 1726Const tShr As SByte = SpecialType.System_Int16 1727Const tInt As SByte = SpecialType.System_Int32 1728Const tLng As SByte = SpecialType.System_Int64 1729Const tDec As SByte = SpecialType.System_Decimal 1730Const tSng As SByte = SpecialType.System_Single 1731Const tByt As SByte = SpecialType.System_Byte 1732Const tUSh As SByte = SpecialType.System_UInt16 1733Const tUIn As SByte = SpecialType.System_UInt32 1734Const tULn As SByte = SpecialType.System_UInt64 1735Const tBoo As SByte = SpecialType.System_Boolean 1736Const tChr As SByte = SpecialType.System_Char 1737Const tDat As SByte = SpecialType.System_DateTime 3163Dim nullableOfT As NamedTypeSymbol = opSet(0).ContainingAssembly.GetSpecialType(SpecialType.System_Nullable_T)
Semantics\OverloadResolution.vb (6)
2097If leftSpecialType = SpecialType.System_Byte AndAlso rightSpecialType = SpecialType.System_SByte Then 2101If leftSpecialType = SpecialType.System_SByte AndAlso rightSpecialType = SpecialType.System_Byte Then 3246If targetType.SpecialType <> SpecialType.System_Object Then 3369argumentType.SpecialType <> SpecialType.System_Object Then
Semantics\TypeInference\TypeArgumentInference.vb (6)
186arrayType.ElementType.SpecialType = SpecialType.System_Object Then 468Graph.ObjectType = unboundLambda.Binder.GetSpecialType(SpecialType.System_Object, lambdaParameter.IdentifierSyntax, Graph.Diagnostic) 2143Dim inferenceSignature As New UnboundLambda.TargetSignature(delegateParams, unboundLambda.Binder.Compilation.GetSpecialType(SpecialType.System_Void), returnsByRef:=False) 2211TypeSymbol.Equals(lambdaReturnNamedType.OriginalDefinition, argument.GetBinderFromLambda().Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T), TypeCompareKind.ConsiderEverything) OrElse 2212TypeSymbol.Equals(lambdaReturnNamedType.OriginalDefinition, argument.GetBinderFromLambda().Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerator_T), TypeCompareKind.ConsiderEverything)) 2225unboundLambda.Binder.Compilation.GetSpecialType(SpecialType.System_Void),
SymbolDisplay\SymbolDisplayVisitor_Constants.vb (4)
14Protected Overrides Sub AddExplicitlyCastedLiteralValue(namedType As INamedTypeSymbol, type As SpecialType, value As Object) 20Protected Overrides Sub AddLiteralValue(type As SpecialType, value As Object) 24Case SpecialType.System_String 27Case SpecialType.System_Char
Symbols\AnonymousTypes\AnonymousType_SymbolCollection.vb (9)
130Return Compilation.GetSpecialType(SpecialType.System_Boolean) 136Return Compilation.GetSpecialType(SpecialType.System_Int32) 142Return Compilation.GetSpecialType(SpecialType.System_Object) 148Return Compilation.GetSpecialType(SpecialType.System_IntPtr) 154Return Compilation.GetSpecialType(SpecialType.System_IAsyncResult) 160Return Compilation.GetSpecialType(SpecialType.System_AsyncCallback) 166Return Compilation.GetSpecialType(SpecialType.System_MulticastDelegate) 172Return Compilation.GetSpecialType(SpecialType.System_String) 178Return Compilation.GetSpecialType(SpecialType.System_Void)
Symbols\ArrayTypeSymbol.vb (4)
48Dim systemArray = declaringAssembly.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_Array) 73declaringAssembly.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_Array), 80Dim iListOfT = declaringAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IList_T) 81Dim iReadOnlyListOfT = declaringAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IReadOnlyList_T)
Symbols\AssemblySymbol.vb (8)
319Friend MustOverride Function GetDeclaredSpecialType(type As SpecialType) As NamedTypeSymbol 370GetSpecialType(SpecialType.System_Runtime_CompilerServices_PreserveBaseOverridesAttribute).IsClassType() 410Debug.Assert(SpecialMembers.GetDescriptor(feature).DeclaringTypeId = SpecialType.System_Runtime_CompilerServices_RuntimeFeature) 412Dim runtimeFeature = GetSpecialType(SpecialType.System_Runtime_CompilerServices_RuntimeFeature) 469Friend Function GetSpecialType(type As SpecialType) As NamedTypeSymbol 470If type <= SpecialType.None OrElse type > SpecialType.Count Then 483Return GetSpecialType(SpecialType.System_Object)
Symbols\Attributes\AttributeData.vb (10)
426If [property].Type IsNot Nothing AndAlso [property].Type.SpecialType = SpecialType.System_String AndAlso 444ctorArgument.DecodeValue(Of ClassInterfaceType)(SpecialType.System_Enum), 445CType(ctorArgument.DecodeValue(Of Short)(SpecialType.System_Int16), ClassInterfaceType)) 471ctorArgument.DecodeValue(Of ComInterfaceType)(SpecialType.System_Enum), 472CType(ctorArgument.DecodeValue(Of Short)(SpecialType.System_Int16), ComInterfaceType)) 489ctorArgument.DecodeValue(Of Cci.TypeLibTypeFlags)(SpecialType.System_Enum), 490CType(ctorArgument.DecodeValue(Of Short)(SpecialType.System_Int16), Cci.TypeLibTypeFlags)) 496Dim guidString As String = Me.GetConstructorArgument(Of String)(0, SpecialType.System_String) 509Return Me.GetConstructorArgument(Of String)(0, SpecialType.System_String) 516If prop?.Type.SpecialType = SpecialType.System_String Then
Symbols\Attributes\SourceAttributeData.vb (14)
181foundMatch = specType = SpecialType.System_Boolean 185foundMatch = specType = SpecialType.System_Char 189foundMatch = specType = SpecialType.System_SByte 193foundMatch = specType = SpecialType.System_Byte 197foundMatch = specType = SpecialType.System_Int16 201foundMatch = specType = SpecialType.System_UInt16 205foundMatch = specType = SpecialType.System_Int32 209foundMatch = specType = SpecialType.System_UInt32 213foundMatch = specType = SpecialType.System_Int64 217foundMatch = specType = SpecialType.System_UInt64 221foundMatch = specType = SpecialType.System_Single 225foundMatch = specType = SpecialType.System_Double 229foundMatch = specType = SpecialType.System_String 233foundMatch = specType = SpecialType.System_Object
Symbols\ConstantValueUtils.vb (1)
44boundValueType = binder.GetSpecialType(SpecialType.System_Object, initValueSyntax, diagnostics)
Symbols\ConstraintsHelper.vb (8)
175Case SpecialType.System_Object, 176SpecialType.System_ValueType, 177SpecialType.System_Enum, 178SpecialType.System_Delegate, 179SpecialType.System_MulticastDelegate, 180SpecialType.System_Array 1060Case SpecialType.System_Object, SpecialType.System_ValueType
Symbols\ErrorMethodSymbol.vb (1)
170Return _returnType.SpecialType = SpecialType.System_Void
Symbols\EventSymbol.vb (1)
160Return ContainingAssembly.GetSpecialType(SpecialType.System_Void)
Symbols\FieldSymbol.vb (4)
104Return specialType <> Microsoft.CodeAnalysis.SpecialType.System_DateTime AndAlso specialType <> Microsoft.CodeAnalysis.SpecialType.System_Decimal 122Return specialType = Microsoft.CodeAnalysis.SpecialType.System_DateTime OrElse specialType = Microsoft.CodeAnalysis.SpecialType.System_Decimal
Symbols\Metadata\PE\MetadataDecoder.vb (5)
161Return New MissingMetadataTypeSymbol.TopLevel(New MissingModuleSymbolWithName(ModuleSymbol.ContainingAssembly, moduleName), emittedName, SpecialType.None) 369Dim baseSpecialType As SpecialType = If(candidate.BaseTypeNoUseSiteDiagnostics?.SpecialType, SpecialType.None) 370If baseSpecialType = SpecialType.None OrElse baseSpecialType <> If(baseType?.SpecialType, SpecialType.None) Then
Symbols\Metadata\PE\PEFieldSymbol.vb (7)
164If Me.Type.SpecialType = SpecialType.System_DateTime Then 169ElseIf Me.Type.SpecialType = SpecialType.System_Decimal Then 240ElseIf selfOrUnderlyingSpecialType = SpecialType.System_DateTime Then 243ElseIf selfOrUnderlyingSpecialType = SpecialType.System_Boolean Then 246ElseIf selfOrUnderlyingSpecialType = SpecialType.System_Char Then 274If Me.Type.SpecialType = SpecialType.System_DateTime Then 278ElseIf Me.Type.SpecialType = SpecialType.System_Decimal Then
Symbols\Metadata\PE\PEMethodSymbol.vb (1)
847Return Me.ReturnType.SpecialType = SpecialType.System_Void
Symbols\Metadata\PE\PEModuleSymbol.vb (1)
282If (keepLookingForDeclaredCorTypes AndAlso t.SpecialType <> SpecialType.None) Then
Symbols\Metadata\PE\PENamedTypeSymbol.vb (16)
1009Dim baseCorTypeId As SpecialType = base.SpecialType 1011If baseCorTypeId = SpecialType.System_Enum Then 1014ElseIf baseCorTypeId = SpecialType.System_MulticastDelegate OrElse 1015(baseCorTypeId = SpecialType.System_Delegate AndAlso Me.SpecialType <> SpecialType.System_MulticastDelegate) Then 1018ElseIf (baseCorTypeId = SpecialType.System_ValueType AndAlso 1019Me.SpecialType <> SpecialType.System_Enum) Then 1150If specialType = SpecialType.None OrElse specialType = SpecialType.System_Nullable_T Then 1294specialtype <> SpecialType.System_Enum AndAlso specialtype <> SpecialType.System_MulticastDelegate Then 1297If base IsNot Nothing AndAlso base.SpecialType = SpecialType.None AndAlso base.ContainingAssembly?.IsMissing Then 1304Case SpecialType.System_Enum, 1305SpecialType.System_Delegate, 1306SpecialType.System_MulticastDelegate, 1307SpecialType.System_ValueType
Symbols\Metadata\PE\PENamedTypeSymbolWithEmittedNamespaceName.vb (3)
21Private ReadOnly _corTypeId As SpecialType 40_corTypeId = SpecialType.None 44Public Overrides ReadOnly Property SpecialType As SpecialType
Symbols\Metadata\PE\PETypeParameterSymbol.vb (1)
203(typeSymbol.SpecialType = Microsoft.CodeAnalysis.SpecialType.System_ValueType) Then
Symbols\Metadata\PE\SymbolFactory.vb (1)
33Friend Overrides Function GetSpecialType(moduleSymbol As PEModuleSymbol, specialType As SpecialType) As TypeSymbol
Symbols\MetadataOrSourceAssemblySymbol.vb (6)
40Friend Overrides Function GetDeclaredSpecialType(type As SpecialType) As NamedTypeSymbol 70Dim typeId As SpecialType = corType.SpecialType 71Debug.Assert(typeId <> SpecialType.None) 78New NamedTypeSymbol(SpecialType.Count) {}, Nothing) 87Debug.Assert(_cachedSpecialTypes > 0 AndAlso _cachedSpecialTypes <= SpecialType.Count) 97Return Me.CorLibrary Is Me AndAlso _cachedSpecialTypes < SpecialType.Count
Symbols\MethodSymbol.vb (3)
523If returnType.SpecialType <> SpecialType.System_Int32 AndAlso returnType.SpecialType <> SpecialType.System_Void Then 545Return array.IsSZArray AndAlso array.ElementType.SpecialType = SpecialType.System_String
Symbols\MissingAssemblySymbol.vb (3)
151Friend Overrides Function GetDeclaredSpecialType(type As SpecialType) As NamedTypeSymbol 192Friend Overrides Function GetDeclaredSpecialType(type As SpecialType) As NamedTypeSymbol 200Interlocked.CompareExchange(_lazySpecialTypes, New NamedTypeSymbol(SpecialType.Count) {}, Nothing)
Symbols\MissingMetadataTypeSymbol.vb (13)
55Dim arg = If(Me.SpecialType <> SpecialType.None, DirectCast(CustomSymbolDisplayFormatter.DefaultErrorFormat(Me), Object), Me) 99Public Sub New([module] As ModuleSymbol, ByRef fullname As MetadataTypeName, Optional typeId As SpecialType = CType(-1, SpecialType)) 101Debug.Assert(typeId = CType(-1, SpecialType) OrElse typeId = SpecialType.None OrElse Arity = 0 OrElse MangleName) 177Public Overrides ReadOnly Property SpecialType As SpecialType 180Dim typeId As SpecialType = SpecialType.None 193Return CType(_lazyTypeId, SpecialType) 233Public Sub New(moduleSymbol As ModuleSymbol, ByRef emittedName As MetadataTypeName, errorInfo As DiagnosticInfo, Optional typeId As SpecialType = CType(-1, SpecialType)) 287Public Overrides ReadOnly Property SpecialType As SpecialType 289Return SpecialType.None ' do not have nested types among CORE types yet.
Symbols\Retargeting\RetargetingAssemblySymbol.vb (1)
181Friend Overrides Function GetDeclaredSpecialType(type As SpecialType) As NamedTypeSymbol
Symbols\SignatureOnlyMethodSymbol.vb (1)
144Return ReturnType.SpecialType = SpecialType.System_Void
Symbols\Source\ImplicitNamedTypeSymbol.vb (1)
51Dim baseType = DeclaringCompilation.GetSpecialType(SpecialType.System_Object)
Symbols\Source\SourceAssemblySymbol.vb (7)
912Dim obj = GetSpecialType(SpecialType.System_Object) 1134Dim arg As Integer = attrData.GetConstructorArgument(Of Integer)(i, SpecialType.System_Int32) 1501Dim int32Type = Me.DeclaringCompilation.GetSpecialType(SpecialType.System_Int32) 1519Dim boolType = Me.DeclaringCompilation.GetSpecialType(SpecialType.System_Boolean) 1540Dim int32Type = Me.DeclaringCompilation.GetSpecialType(SpecialType.System_Int32) 1573Dim stringType = _compilation.GetSpecialType(SpecialType.System_String) 1582Dim stringType = _compilation.GetSpecialType(SpecialType.System_String)
Symbols\Source\SourceComplexParameterSymbol.vb (2)
378Case SpecialType.System_DateTime 383Case SpecialType.System_Decimal
Symbols\Source\SourceDelegateMethodSymbol.vb (8)
81Dim voidType = binder.GetSpecialType(SpecialType.System_Void, syntax, diagnostics) 82Dim iAsyncResultType = binder.GetSpecialType(SpecialType.System_IAsyncResult, syntax, diagnostics) 83Dim objectType = binder.GetSpecialType(SpecialType.System_Object, syntax, diagnostics) 84Dim intPtrType = binder.GetSpecialType(SpecialType.System_IntPtr, syntax, diagnostics) 85Dim asyncCallbackType = binder.GetSpecialType(SpecialType.System_AsyncCallback, syntax, diagnostics) 123Return binder.GetSpecialType(SpecialType.System_Void, syntax, diagnostics) 258If(returnType.SpecialType = SpecialType.System_Void, SourceMemberFlags.MethodIsSub, Nothing), 331If(invoke.ReturnType.SpecialType = SpecialType.System_Void, SourceMemberFlags.MethodIsSub, Nothing),
Symbols\Source\SourceFieldSymbol.vb (4)
663If Me.Type.SpecialType = SpecialType.System_DateTime Then 666Dim specialTypeInt64 = Me.ContainingAssembly.GetSpecialType(SpecialType.System_Int64) 677ElseIf Me.Type.SpecialType = SpecialType.System_Decimal Then 732Dim offset = attrData.CommonConstructorArguments(0).DecodeValue(Of Integer)(SpecialType.System_Int32)
Symbols\Source\SourceMemberFieldSymbol.vb (2)
254constantType = ContainingAssembly.GetSpecialType(SpecialType.System_Object) 259constantType = ContainingAssembly.GetSpecialType(SpecialType.System_Object)
Symbols\Source\SourceMethodSymbol.vb (15)
1526Dim conditionalSymbol As String = attrdata.GetConstructorArgument(Of String)(0, SpecialType.System_String) 1678charSet = namedArg.Value.DecodeValue(Of CharSet)(SpecialType.System_Enum) 1681setLastError = namedArg.Value.DecodeValue(Of Boolean)(SpecialType.System_Boolean) 1684exactSpelling = namedArg.Value.DecodeValue(Of Boolean)(SpecialType.System_Boolean) 1687preserveSig = namedArg.Value.DecodeValue(Of Boolean)(SpecialType.System_Boolean) 1690callingConvention = namedArg.Value.DecodeValue(Of System.Runtime.InteropServices.CallingConvention)(SpecialType.System_Enum) 1693bestFitMapping = namedArg.Value.DecodeValue(Of Boolean)(SpecialType.System_Boolean) 1696throwOnUnmappable = namedArg.Value.DecodeValue(Of Boolean)(SpecialType.System_Boolean) 2249Return binder.GetSpecialType(SpecialType.System_Void, Syntax, diagBag) 2255binder.GetSpecialType(SpecialType.System_Void, Syntax, diagBag)) 2270retType = binder.GetSpecialType(SpecialType.System_Void, Syntax, diagBag) 2325If originalRetTypeDef.SpecialType <> SpecialType.System_Collections_Generic_IEnumerable_T AndAlso 2326originalRetTypeDef.SpecialType <> SpecialType.System_Collections_Generic_IEnumerator_T AndAlso 2327retType.SpecialType <> SpecialType.System_Collections_IEnumerable AndAlso 2328retType.SpecialType <> SpecialType.System_Collections_IEnumerator Then
Symbols\Source\SourceModuleSymbol.vb (1)
1098Dim charSet As CharSet = attrData.GetConstructorArgument(Of CharSet)(0, SpecialType.System_Enum)
Symbols\Source\SourceNamedTypeSymbol.vb (26)
34Private ReadOnly _corTypeId As SpecialType 91_corTypeId = SpecialType.None 100Public Overrides ReadOnly Property SpecialType As SpecialType 1252Private Function IsRestrictedBaseClass(type As SpecialType) As Boolean 1254Case SpecialType.System_Array, 1255SpecialType.System_Delegate, 1256SpecialType.System_MulticastDelegate, 1257SpecialType.System_Enum, 1258SpecialType.System_ValueType 1372If declaredOrDefaultBase Is Nothing AndAlso Me.SpecialType <> Microsoft.CodeAnalysis.SpecialType.System_Object Then 1378ReportUseSiteInfoForBaseType(Me.DeclaringCompilation.GetSpecialType(SpecialType.System_Object), declaredBase, diagnostics) 1382declaredOrDefaultBase = GetSpecialType(SpecialType.System_Object) 1388declaredOrDefaultBase = GetSpecialType(SpecialType.System_Enum) 1391declaredOrDefaultBase = GetSpecialType(SpecialType.System_ValueType) 1394declaredOrDefaultBase = GetSpecialType(SpecialType.System_MulticastDelegate) 1397declaredOrDefaultBase = GetSpecialType(SpecialType.System_Object) 1412Private Function GetSpecialType(type As SpecialType) As NamedTypeSymbol 1502Return GetSpecialType(SpecialType.System_Enum) 1505Return GetSpecialType(SpecialType.System_MulticastDelegate) 1788Return bodyBinder.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32, syntax.EnumStatement.Identifier, diagnostics) 2035Dim conditionalSymbol As String = attrdata.GetConstructorArgument(Of String)(0, SpecialType.System_String) 2127Debug.Assert(Me.IsOrDerivedFromWellKnownClass(WellKnownType.System_Attribute, DeclaringCompilation, CompoundUseSiteInfo(Of AssemblySymbol).Discarded) OrElse Me.SpecialType = Microsoft.CodeAnalysis.SpecialType.System_Object) 2474Dim stringType = GetSpecialType(SpecialType.System_String) 2496New TypedConstant(GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, _comClassData.ClassId)))) 2502New TypedConstant(GetSpecialType(SpecialType.System_Int32), TypedConstantKind.Enum, CInt(ClassInterfaceType.None))))) 2523New TypedConstant(GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, eventInterfaceName))))
Symbols\Source\SourceNamedTypeSymbol_ComClass.vb (9)
62Me.InterfaceShadows = attrData.DecodeNamedArgument("InterfaceShadows", Microsoft.CodeAnalysis.SpecialType.System_Boolean, False) 556method.ReturnType.SpecialType = SpecialType.System_Collections_IEnumerator Then 590prop.Type.SpecialType = SpecialType.System_Collections_IEnumerator Then 994New TypedConstant(_comClass.GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, id)))) 1001New TypedConstant(_comClass.GetSpecialType(SpecialType.System_Int16), 1008ImmutableArray.Create(New TypedConstant(_comClass.GetSpecialType(SpecialType.System_Boolean), 1015ImmutableArray.Create(New TypedConstant(_comClass.GetSpecialType(SpecialType.System_String), 1348ImmutableArray.Create(New TypedConstant(_interface.ComClass.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32), 1844ImmutableArray.Create(New TypedConstant(_interface.ComClass.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_Int32),
Symbols\Source\SourceNamedTypeSymbol_GroupClass.vb (4)
29Dim baseTypeNames() As String = If(attributeData.GetConstructorArgument(Of String)(0, SpecialType.System_String), "").Split(separatorComma, StringSplitOptions.None) 30Dim createMethods() As String = If(attributeData.GetConstructorArgument(Of String)(1, SpecialType.System_String), "").Split(separatorComma, StringSplitOptions.None) 31Dim disposeMethods() As String = If(attributeData.GetConstructorArgument(Of String)(2, SpecialType.System_String), "").Split(separatorComma, StringSplitOptions.None) 37defaultInstances = If(attributeData.GetConstructorArgument(Of String)(3, Microsoft.CodeAnalysis.SpecialType.System_String), "").Split(separatorComma, StringSplitOptions.None)
Symbols\Source\SourceNamespaceSymbol.vb (1)
63If type IsNot Nothing AndAlso type.SpecialType <> SpecialType.None Then
Symbols\Source\SourceParameterSymbol.vb (1)
250If attribute.ConstructorArguments.Single().TryDecodeValue(SpecialType.System_String, parameterName) Then
Symbols\Source\SourceParameterSymbolBase.vb (3)
60Case SpecialType.System_DateTime 63ImmutableArray.Create(New TypedConstant(compilation.GetSpecialType(SpecialType.System_Int64), 67Case SpecialType.System_Decimal
Symbols\Source\SourcePropertyAccessorSymbol.vb (1)
240Return binder.GetSpecialType(SpecialType.System_Void, Me.DeclarationSyntax, diagBag)
Symbols\Source\SourcePropertySymbol.vb (5)
279bodyBinder.GetSpecialType(SpecialType.System_Void, identifier, diagnostics), 387If originalRetTypeDef.SpecialType <> SpecialType.System_Collections_Generic_IEnumerable_T AndAlso 388originalRetTypeDef.SpecialType <> SpecialType.System_Collections_Generic_IEnumerator_T AndAlso 389type.SpecialType <> SpecialType.System_Collections_IEnumerable AndAlso 390type.SpecialType <> SpecialType.System_Collections_IEnumerator Then
Symbols\Source\SourceWithEventsBackingFieldSymbol.vb (1)
75ImmutableArray.Create(New TypedConstant(compilation.GetSpecialType(SpecialType.System_String),
Symbols\Source\SynthesizedEntryPointSymbol.vb (4)
25Dim submissionArrayType = compilation.CreateArrayTypeSymbol(compilation.GetSpecialType(SpecialType.System_Object)) 42compilation.GetSpecialType(SpecialType.System_Void), 70Return _returnType.SpecialType = SpecialType.System_Void 229Debug.Assert(returnType.SpecialType = SpecialType.System_Void)
Symbols\Source\SynthesizedEventAccessorSymbol.vb (2)
82type = compilation.GetSpecialType(SpecialType.System_Void) 281Dim boolType As TypeSymbol = compilation.GetSpecialType(SpecialType.System_Boolean)
Symbols\Source\SynthesizedInteractiveInitializerMethod.vb (2)
95Return _returnType.SpecialType = SpecialType.System_Void 167resultType = compilation.GetSpecialType(SpecialType.System_Object)
Symbols\Source\SynthesizedMainTypeEntryPoint.vb (1)
44Return ContainingAssembly.GetSpecialType(SpecialType.System_Void)
Symbols\Source\SynthesizedMyGroupCollectionPropertyAccessorSymbol.vb (1)
212Return ContainingAssembly.GetSpecialType(SpecialType.System_Void)
Symbols\Source\SynthesizedSubmissionConstructorSymbol.vb (4)
33Dim submissionArrayType = compilation.CreateArrayTypeSymbol(compilation.GetSpecialType(SpecialType.System_Object)) 65Dim submissionArrayType = compilation.CreateArrayTypeSymbol(compilation.GetSpecialType(SpecialType.System_Object)) 68Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 69Dim objectType = compilation.GetSpecialType(SpecialType.System_Object)
Symbols\SpecialMembers.vb (1)
67Dim type = GetDeclaredSpecialType(CType(descriptor.DeclaringTypeId, SpecialType))
Symbols\SpecialTypeExtensions.vb (169)
10Public Function IsFloatingType(this As SpecialType) As Boolean 12Case SpecialType.System_Single, 13SpecialType.System_Double 21Public Function IsIntrinsicType(this As SpecialType) As Boolean 22Return this = SpecialType.System_String OrElse this.IsIntrinsicValueType() 26Public Function IsIntrinsicValueType(this As SpecialType) As Boolean 28Case SpecialType.System_Boolean, 29SpecialType.System_Byte, 30SpecialType.System_SByte, 31SpecialType.System_Int16, 32SpecialType.System_UInt16, 33SpecialType.System_Int32, 34SpecialType.System_UInt32, 35SpecialType.System_Int64, 36SpecialType.System_UInt64, 37SpecialType.System_Single, 38SpecialType.System_Double, 39SpecialType.System_Decimal, 40SpecialType.System_DateTime, 41SpecialType.System_Char 49Public Function IsPrimitiveType(this As SpecialType) As Boolean 51Case SpecialType.System_Boolean, 52SpecialType.System_Byte, 53SpecialType.System_Char, 54SpecialType.System_Double, 55SpecialType.System_Int16, 56SpecialType.System_Int32, 57SpecialType.System_Int64, 58SpecialType.System_UInt16, 59SpecialType.System_UInt32, 60SpecialType.System_UInt64, 61SpecialType.System_IntPtr, 62SpecialType.System_UIntPtr, 63SpecialType.System_SByte, 64SpecialType.System_Single 72Public Function IsStrictSupertypeOfConcreteDelegate(this As SpecialType) As Boolean 74Case SpecialType.System_Object, 75SpecialType.System_Delegate, 76SpecialType.System_MulticastDelegate 84Public Function IsRestrictedType(this As SpecialType) As Boolean 86Case SpecialType.System_TypedReference, 87SpecialType.System_ArgIterator, 88SpecialType.System_RuntimeArgumentHandle 96Public Function IsValidTypeForAttributeArgument(this As SpecialType) As Boolean 98Case SpecialType.System_Boolean, 99SpecialType.System_Byte, 100SpecialType.System_SByte, 101SpecialType.System_Int16, 102SpecialType.System_UInt16, 103SpecialType.System_Int32, 104SpecialType.System_UInt32, 105SpecialType.System_Int64, 106SpecialType.System_UInt64, 107SpecialType.System_Single, 108SpecialType.System_Double, 109SpecialType.System_Char, 110SpecialType.System_Object, 111SpecialType.System_String 119Public Function IsValidTypeForSwitchTable(this As SpecialType) As Boolean 121Case SpecialType.System_Byte, 122SpecialType.System_SByte, 123SpecialType.System_Int16, 124SpecialType.System_UInt16, 125SpecialType.System_Int32, 126SpecialType.System_UInt32, 127SpecialType.System_Int64, 128SpecialType.System_UInt64, 129SpecialType.System_Char, 130SpecialType.System_Boolean, 131SpecialType.System_String 139Public Function TypeToIndex(type As SpecialType) As Integer? 143Case SpecialType.System_Object 145Case SpecialType.System_String 147Case SpecialType.System_Boolean 149Case SpecialType.System_Char 151Case SpecialType.System_SByte 153Case SpecialType.System_Int16 155Case SpecialType.System_Int32 157Case SpecialType.System_Int64 159Case SpecialType.System_Byte 161Case SpecialType.System_UInt16 163Case SpecialType.System_UInt32 165Case SpecialType.System_UInt64 167Case SpecialType.System_Single 169Case SpecialType.System_Double 171Case SpecialType.System_Decimal 173Case SpecialType.System_DateTime 184Public Function GetNativeCompilerVType(this As SpecialType) As String 186Case SpecialType.System_Void 188Case SpecialType.System_Boolean 190Case SpecialType.System_Char 192Case SpecialType.System_SByte 194Case SpecialType.System_Byte 196Case SpecialType.System_Int16 198Case SpecialType.System_UInt16 200Case SpecialType.System_Int32 202Case SpecialType.System_UInt32 204Case SpecialType.System_Int64 206Case SpecialType.System_UInt64 208Case SpecialType.System_Decimal 210Case SpecialType.System_Single 212Case SpecialType.System_Double 214Case SpecialType.System_String 216Case SpecialType.System_IntPtr, SpecialType.System_UIntPtr 218Case SpecialType.System_Array 220Case SpecialType.System_DateTime 228Public Function GetDisplayName(this As SpecialType) As String 235Public Function TryGetKeywordText(this As SpecialType) As String 237Case SpecialType.System_SByte 239Case SpecialType.System_Int16 241Case SpecialType.System_Int32 243Case SpecialType.System_Int64 245Case SpecialType.System_Byte 247Case SpecialType.System_UInt16 249Case SpecialType.System_UInt32 251Case SpecialType.System_UInt64 253Case SpecialType.System_Single 255Case SpecialType.System_Double 257Case SpecialType.System_Decimal 259Case SpecialType.System_Char 261Case SpecialType.System_Boolean 263Case SpecialType.System_String 265Case SpecialType.System_Object 267Case SpecialType.System_DateTime 269Case SpecialType.System_Void 277Friend Function ToConstantValueDiscriminator(this As SpecialType) As ConstantValueTypeDiscriminator 279Case SpecialType.System_SByte 281Case SpecialType.System_Byte 283Case SpecialType.System_Int16 285Case SpecialType.System_UInt16 287Case SpecialType.System_Int32 289Case SpecialType.System_UInt32 291Case SpecialType.System_Int64 293Case SpecialType.System_UInt64 295Case SpecialType.System_Char 297Case SpecialType.System_Boolean 299Case SpecialType.System_Single 301Case SpecialType.System_Double 303Case SpecialType.System_Decimal 305Case SpecialType.System_DateTime 307Case SpecialType.System_String 315Friend Function GetShiftSizeMask(this As SpecialType) As Integer 317Case SpecialType.System_SByte, SpecialType.System_Byte 320Case SpecialType.System_Int16, SpecialType.System_UInt16 323Case SpecialType.System_Int32, SpecialType.System_UInt32 326Case SpecialType.System_Int64, SpecialType.System_UInt64 335Public Function ToRuntimeType(this As SpecialType) As Type 337Case SpecialType.System_SByte 339Case SpecialType.System_Int16 341Case SpecialType.System_Int32 343Case SpecialType.System_Int64 345Case SpecialType.System_Byte 347Case SpecialType.System_UInt16 349Case SpecialType.System_UInt32 351Case SpecialType.System_UInt64 353Case SpecialType.System_Single 355Case SpecialType.System_Double 357Case SpecialType.System_Decimal 359Case SpecialType.System_Char 361Case SpecialType.System_Boolean 363Case SpecialType.System_String 365Case SpecialType.System_Object 367Case SpecialType.System_DateTime 369Case SpecialType.System_Void
Symbols\SynthesizedSymbols\SynthesizedConstructorBase.vb (2)
47m_voidType = binder.GetSpecialType(SpecialType.System_Void, syntaxReference.GetSyntax(), diagnostics) 52m_voidType = ContainingAssembly.GetSpecialType(SpecialType.System_Void)
Symbols\SynthesizedSymbols\SynthesizedDelegateMethodSymbol.vb (1)
253Return _returnType.SpecialType = SpecialType.System_Void
Symbols\SynthesizedSymbols\SynthesizedEventDelegateSymbol.vb (1)
240Return _containingType.ContainingAssembly.GetSpecialType(Microsoft.CodeAnalysis.SpecialType.System_MulticastDelegate)
Symbols\SynthesizedSymbols\SynthesizedGlobal_StringSwitchHashMethodSymbol.vb (2)
34_parameters = ImmutableArray.Create(Of ParameterSymbol)(New SynthesizedParameterSimpleSymbol(Me, compilation.GetSpecialType(SpecialType.System_String), 0, "s")) 35_returnType = compilation.GetSpecialType(SpecialType.System_UInt32)
Symbols\SynthesizedSymbols\SynthesizedMethod.vb (1)
96Dim type = ContainingAssembly.GetSpecialType(SpecialType.System_Void)
Symbols\TypedConstant.vb (4)
37If constant.Kind = TypedConstantKind.Type OrElse constant.TypeInternal.SpecialType = SpecialType.System_Object Then 54Dim splType As SpecialType = DirectCast(constant.TypeInternal, NamedTypeSymbol).EnumUnderlyingType.SpecialType 66Private Function DisplayUnsignedEnumConstant(constant As TypedConstant, splType As SpecialType, ByVal constantToDecode As ULong, ByVal typeName As String) As String 130Private Function DisplaySignedEnumConstant(constant As TypedConstant, ByVal splType As SpecialType, ByVal constantToDecode As Long, ByVal typeName As String) As String
Symbols\TypeParameterSymbol.vb (3)
255Case SpecialType.System_Object, 256SpecialType.System_ValueType, 257SpecialType.System_Enum
Symbols\TypeSymbol.vb (2)
276Public Overridable ReadOnly Property SpecialType As SpecialType Implements ITypeSymbol.SpecialType, ITypeSymbolInternal.SpecialType 278Return SpecialType.None
Symbols\TypeSymbolExtensions.vb (32)
15Return this.OriginalDefinition.SpecialType = SpecialType.System_Nullable_T 172If array.IsSZArray AndAlso array.ElementType.SpecialType = SpecialType.System_Char Then 190If type.SpecialType = SpecialType.None AndAlso 211If type.SpecialType = SpecialType.None AndAlso 285Public Function GetSpecialTypeSafe(this As TypeSymbol) As SpecialType 286Return If(this IsNot Nothing, this.SpecialType, SpecialType.None) 316Return this.SpecialType = SpecialType.System_Single 321Return this.SpecialType = SpecialType.System_Double 326Return this.SpecialType = SpecialType.System_Boolean 331Return this.SpecialType = SpecialType.System_Char 336Return this.SpecialType = SpecialType.System_String 341Return this.SpecialType = SpecialType.System_Object 351Return this.SpecialType = SpecialType.System_Void 356Return this.SpecialType = SpecialType.System_Decimal 361Return this.SpecialType = SpecialType.System_DateTime 430Case SpecialType.System_Boolean 432Case SpecialType.System_Byte 434Case SpecialType.System_SByte 436Case SpecialType.System_Int16 438Case SpecialType.System_UInt16 440Case SpecialType.System_Int32 442Case SpecialType.System_UInt32 444Case SpecialType.System_Int64 446Case SpecialType.System_UInt64 448Case SpecialType.System_Single 450Case SpecialType.System_Double 452Case SpecialType.System_Decimal 454Case SpecialType.System_DateTime 456Case SpecialType.System_Char 458Case SpecialType.System_String 682Dim genericIEnumerable = typeWithContainingAssembly.ContainingAssembly.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 734fieldType.SpecialType = SpecialType.System_Object OrElse
Symbols\WellKnownMembers.vb (5)
236Dim specialTypeByte = GetSpecialType(SpecialType.System_Byte) 239Dim specialTypeUInt32 = GetSpecialType(SpecialType.System_UInt32) 326Dim type = If(descriptor.DeclaringTypeId <= SpecialType.Count, 327GetSpecialType(CType(descriptor.DeclaringTypeId, SpecialType)), 705Dim stringType = GetSpecialType(SpecialType.System_String)
Syntax\VisualBasicSyntaxTree.ConditionalSymbolsMap.vb (10)
179Case SpecialType.System_Boolean 182Case SpecialType.System_Byte 185Case SpecialType.System_Int16 188Case SpecialType.System_Int32 191Case SpecialType.System_Int64 194Case SpecialType.System_SByte 197Case SpecialType.System_UInt16 200Case SpecialType.System_UInt32 203Case SpecialType.System_UInt64 206Case SpecialType.System_String
Utilities\TypeUnification.vb (1)
151If t2.Type.SpecialType = SpecialType.System_Void Then
Utilities\VarianceAmbiguity.vb (2)
138If typeArgument1.SpecialType <> SpecialType.System_Object AndAlso 139typeArgument2.SpecialType <> SpecialType.System_Object AndAlso
VisualBasicExtensions.vb (1)
788Public Function GetSpecialType(compilation As Compilation, typeId As SpecialType) As INamedTypeSymbol
Microsoft.CodeAnalysis.VisualBasic.CodeStyle (16)
CastAnalyzer.vb (15)
228If If(castType?.SpecialType = SpecialType.System_Object, False) AndAlso 322DirectCast(castExpressionType.OriginalDefinition, ITypeSymbol).SpecialType = SpecialType.System_Nullable_T 384Case SpecialType.System_Single, SpecialType.System_Double 386Case SpecialType.System_UInt32, SpecialType.System_Int32, 387SpecialType.System_UInt64, SpecialType.System_Int64, 388SpecialType.System_Decimal 400ElseIf castType.SpecialType = SpecialType.System_DateTime 401Return Not outerType.SpecialType = SpecialType.System_DateTime 402ElseIf castType.SpecialType = SpecialType.System_Boolean 403Return Not (outerType.IsNumericType OrElse outerType.SpecialType = SpecialType.System_Boolean) 406If castType.OriginalDefinition?.SpecialType = SpecialType.System_Nullable_T Then 418If castType.Equals(outerType) OrElse outerType.SpecialType = SpecialType.System_Object Then
ExpressionSyntaxExtensions.vb (1)
111If typeInfo.Type IsNot Nothing AndAlso typeInfo.Type.SpecialType = SpecialType.System_Void Then
Microsoft.CodeAnalysis.VisualBasic.CodeStyle.Fixes (112)
ITypeSymbolExtensions.vb (49)
19Public Function GetPredefinedCastKeyword(specialType As SpecialType) As SyntaxKind 21Case specialType.System_Boolean 23Case specialType.System_Byte 25Case specialType.System_Char 27Case specialType.System_DateTime 29Case specialType.System_Decimal 31Case specialType.System_Double 33Case specialType.System_Int32 35Case specialType.System_Int64 37Case specialType.System_Object 39Case specialType.System_SByte 41Case specialType.System_Single 43Case specialType.System_Int16 45Case SpecialType.System_String 47Case specialType.System_UInt32 49Case specialType.System_UInt64 51Case specialType.System_UInt16 60Dim specialType As SpecialType 63specialType = specialType.System_Boolean 65specialType = specialType.System_Byte 67specialType = specialType.System_Char 69specialType = specialType.System_DateTime 71specialType = specialType.System_Decimal 73specialType = specialType.System_Double 75specialType = specialType.System_Int32 77specialType = specialType.System_Int64 79specialType = specialType.System_Object 81specialType = specialType.System_SByte 83specialType = specialType.System_Single 85specialType = specialType.System_String 87specialType = specialType.System_Int16 89specialType = specialType.System_UInt32 91specialType = specialType.System_UInt64 93specialType = specialType.System_UInt16 104Case SpecialType.System_Boolean, 105SpecialType.System_Byte, 106SpecialType.System_SByte, 107SpecialType.System_Int16, 108SpecialType.System_UInt16, 109SpecialType.System_Int32, 110SpecialType.System_UInt32, 111SpecialType.System_Int64, 112SpecialType.System_UInt64, 113SpecialType.System_Single, 114SpecialType.System_Double, 115SpecialType.System_Decimal, 116SpecialType.System_DateTime, 117SpecialType.System_Char, 118SpecialType.System_String
StringExtensions.vb (16)
97Case SpecialType.System_Boolean, 98SpecialType.System_Byte, 99SpecialType.System_SByte, 100SpecialType.System_Int16, 101SpecialType.System_UInt16, 102SpecialType.System_Int32, 103SpecialType.System_UInt32, 104SpecialType.System_Int64, 105SpecialType.System_UInt64, 106SpecialType.System_Single, 107SpecialType.System_Double, 108SpecialType.System_Decimal, 109SpecialType.System_DateTime, 110SpecialType.System_Char, 111SpecialType.System_String, 112SpecialType.System_Object
TypeSyntaxGeneratorVisitor.vb (17)
81If symbol.OriginalDefinition.SpecialType = SpecialType.System_Nullable_T Then 96Case SpecialType.System_Object 98Case SpecialType.System_Boolean 100Case SpecialType.System_Char 102Case SpecialType.System_SByte 104Case SpecialType.System_Byte 106Case SpecialType.System_Int16 108Case SpecialType.System_UInt16 110Case SpecialType.System_Int32 112Case SpecialType.System_Int64 114Case SpecialType.System_UInt32 116Case SpecialType.System_UInt64 118Case SpecialType.System_Decimal 120Case SpecialType.System_Single 122Case SpecialType.System_Double 124Case SpecialType.System_String 126Case SpecialType.System_DateTime
VisualBasicTypeInferenceService.TypeInferrer.vb (30)
235Return CreateResult(Compilation.GetSpecialType(SpecialType.System_Int32)) 282Return CreateResult(Compilation.GetSpecialType(SpecialType.System_Int32)) 412Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 452Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 486Return types.Select(Function(t) New TypeInferenceInfo(If(t.InferredType.SpecialType = SpecialType.System_Void, task, taskOfT.Construct(t.InferredType)))) 505New TypeInferenceInfo(Me.Compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(t.InferredType)), 511If t.InferredType.OriginalDefinition.SpecialType = SpecialType.System_Nullable_T Then 534Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 544If otherSideTypes.Any(Function(t) t.InferredType.SpecialType <> SpecialType.System_Object AndAlso Not t.InferredType.IsErrorType()) Then 568Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 574Return CreateResult(SpecialType.System_Boolean) 594Return CreateResult(SpecialType.System_Boolean) 598Return CreateResult(SpecialType.System_Boolean) 605Return CreateResult(SpecialType.System_IDisposable) 648Return CreateResult(SpecialType.System_Void) 660Dim type = Me.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 664Dim type = Me.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 665Return CreateResult(type.Construct(Compilation.GetSpecialType(SpecialType.System_Object))) 694Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 698Return CreateResult(SpecialType.System_Boolean) 773If memberType.OriginalDefinition.SpecialType = SpecialType.System_Collections_Generic_IEnumerable_T OrElse 774memberType.OriginalDefinition.SpecialType = SpecialType.System_Collections_Generic_IEnumerator_T Then 806Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 815Return CreateResult(SpecialType.System_Boolean) 823Return CreateResult(SpecialType.System_Boolean) 841Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 848Return CreateResult(SpecialType.System_Boolean) 857Return CreateResult(SpecialType.System_IDisposable) 869Return CreateResult(SpecialType.System_Boolean) 873Return CreateResult(SpecialType.System_Boolean)
Microsoft.CodeAnalysis.VisualBasic.EditorFeatures (1)
NavigationBar\VisualBasicEditorNavigationBarItemService_CodeGeneration.vb (1)
239returnType:=compilation.GetSpecialType(SpecialType.System_Void),
Microsoft.CodeAnalysis.VisualBasic.EditorFeatures.UnitTests (7)
EditAndContinue\TopLevelEditingTests.vb (7)
3096SemanticEdit(SemanticEditKind.Delete, Function(c) c.GetMembers("S.C.F2").FirstOrDefault(Function(m) m.GetParameters().Any(Function(p) p.Type.SpecialType = SpecialType.System_Byte)), deletedSymbolContainerProvider:=Function(c) c.GetMember("S.C")) 3100SemanticEdit(SemanticEditKind.Insert, Function(c) c.GetMember(Of NamedTypeSymbol)("S").GetMember(Of NamedTypeSymbol)("C").GetMembers("F2").FirstOrDefault(Function(m) m.GetParameters().Any(Function(p) p.Type.SpecialType = SpecialType.System_Int32))) 4192SemanticEdit(SemanticEditKind.Insert, Function(c) c.GetMembers("S.F").FirstOrDefault(Function(m) m.GetParameters().Any(Function(p) p.Type.SpecialType = SpecialType.System_Byte))) 4196SemanticEdit(SemanticEditKind.Delete, Function(c) c.GetMembers("S.F").FirstOrDefault(Function(m) m.GetParameters().Any(Function(p) p.Type.SpecialType = SpecialType.System_Int32)), deletedSymbolContainerProvider:=Function(c) c.GetMember("S")) 7807SemanticEdit(SemanticEditKind.Delete, Function(c) c.GetMembers("C.set_P").FirstOrDefault(Function(m) m.GetParameters().Any(Function(p) p.Type.SpecialType = SpecialType.System_Int32)), deletedSymbolContainerProvider:=Function(c) c.GetMember("C")), 10553SemanticEdit(SemanticEditKind.Delete, Function(c) c.GetMembers("C.get_P").FirstOrDefault(Function(m) m.GetParameters().Any(Function(p) p.Type.SpecialType = SpecialType.System_Int32)), deletedSymbolContainerProvider:=Function(c) c.GetMember("C")), 10572SemanticEdit(SemanticEditKind.Delete, Function(c) c.GetMembers("C.get_P").FirstOrDefault(Function(m) m.GetParameters().Any(Function(p) p.Type.SpecialType = SpecialType.System_Int32)), deletedSymbolContainerProvider:=Function(c) c.GetMember("C")),
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (83)
Attributes\AttributeTests.vb (1)
2199Dim classYOfInt As NamedTypeSymbol = classY.Construct(ImmutableArray.Create(Of TypeSymbol)(m.ContainingAssembly.GetSpecialType(SpecialType.System_Int32)))
Attributes\AttributeTests_Synthesized.vb (1)
1829New TypedConstant(comp.GetSpecialType(SpecialType.System_String), TypedConstantKind.Primitive, "unused"))))
Attributes\AttributeTests_Tuples.vb (2)
323Assert.Equal(SpecialType.System_Object, sender.Type.SpecialType) 443Assert.True(constant.Type.SpecialType = SpecialType.System_String)
CodeGen\CodeGenTuples.vb (54)
6865Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 6888Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 6889Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 6917Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 6918Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 6940Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 6941Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 6960Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 6961Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 6980Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 6981Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7001Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7019Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7020Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7044Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7045Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7069Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7070Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7094Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7095Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7119Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7120Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7150Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7169Dim intType As NamedTypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7191Dim intType As NamedTypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7219Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7245Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7246Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7268Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7269Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7291Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7292Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7309Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7310Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7327Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7343Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7344Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7364Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7365Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7385Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7386Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7406Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7407Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7433Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7450Dim intType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 7482Dim stringType As ITypeSymbol = comp.GetSpecialType(SpecialType.System_String) 7503Dim intType = comp.GetSpecialType(SpecialType.System_Int32) 7504Dim stringType = comp.GetSpecialType(SpecialType.System_String) 7530Dim intType As NamedTypeSymbol = comp.GetSpecialType(SpecialType.System_String) 8935Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 10122Sub(t) Assert.Equal(SpecialType.System_Int32, t.SpecialType)) 16411Assert.False(m1ToString.ReturnType.SpecialType = SpecialType.System_Void) 20505Sub(t) Assert.Equal(SpecialType.System_Int32, t.SpecialType)) 20520Sub(t) Assert.Equal(SpecialType.System_Int32, t.SpecialType))
Emit\CompilationEmitTests.vb (2)
3818Assert.Equal(SpecialType.System_ValueType, typeSymbol.SpecialType) 4282compilation.GetSpecialType(SpecialType.System_Int32)
Emit\EmitMetadata.vb (17)
512Assert.Same([Module].GetCorLibType(SpecialType.System_Array), parameter1Type) 513Assert.Same([Module].GetCorLibType(SpecialType.System_Boolean), m2.Parameters.Single().Type) 514Assert.Same([Module].GetCorLibType(SpecialType.System_Char), m3.Parameters.Single().Type) 518Assert.Same([Module].GetCorLibType(SpecialType.System_Void), m4.ReturnType) 519Assert.Same([Module].GetCorLibType(SpecialType.System_SByte), method4ParamTypes(0)) 520Assert.Same([Module].GetCorLibType(SpecialType.System_Single), method4ParamTypes(1)) 521Assert.Same([Module].GetCorLibType(SpecialType.System_Double), method4ParamTypes(2)) 522Assert.Same([Module].GetCorLibType(SpecialType.System_Int16), method4ParamTypes(3)) 523Assert.Same([Module].GetCorLibType(SpecialType.System_Int32), method4ParamTypes(4)) 524Assert.Same([Module].GetCorLibType(SpecialType.System_Int64), method4ParamTypes(5)) 525Assert.Same([Module].GetCorLibType(SpecialType.System_IntPtr), method4ParamTypes(6)) 526Assert.Same([Module].GetCorLibType(SpecialType.System_String), method4ParamTypes(7)) 527Assert.Same([Module].GetCorLibType(SpecialType.System_Byte), method4ParamTypes(8)) 528Assert.Same([Module].GetCorLibType(SpecialType.System_UInt16), method4ParamTypes(9)) 529Assert.Same([Module].GetCorLibType(SpecialType.System_UInt32), method4ParamTypes(10)) 530Assert.Same([Module].GetCorLibType(SpecialType.System_UInt64), method4ParamTypes(11)) 531Assert.Same([Module].GetCorLibType(SpecialType.System_UIntPtr), method4ParamTypes(12))
Emit\NoPiaEmbedTypes.vb (5)
1024Assert.Equal(SpecialType.System_ValueType, test2.BaseType.SpecialType) 1092Assert.Equal(SpecialType.System_Int32, test9.EnumUnderlyingType.SpecialType) 1166Assert.Equal(SpecialType.System_MulticastDelegate, test11.BaseType.SpecialType) 1308Assert.Equal(SpecialType.System_Void, paramInfo(0).Type.SpecialType) 1881Assert.Equal(expr.Type.SpecialType, SpecialType.System_String)
PDB\PDBTests.vb (1)
192Dim stInt = c1.GetSpecialType(SpecialType.System_Int32)
Microsoft.CodeAnalysis.VisualBasic.ExpressionEvaluator.ExpressionCompiler (10)
Binders\PlaceholderLocalBinder.vb (2)
73Dim type = Compilation.GetSpecialType(If(specialType = SpecialType.None, SpecialType.System_Object, specialType))
CompilationContext.vb (5)
95_voidType = Me.Compilation.GetSpecialType(SpecialType.System_Void) 134Dim objectType = Me.Compilation.GetSpecialType(SpecialType.System_Object) 200Dim objectType = Me.Compilation.GetSpecialType(SpecialType.System_Object) 514Case SpecialType.System_Void 518Case SpecialType.System_Boolean
Rewriters\LocalDeclarationRewriter.vb (2)
61Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 64compilation.GetSpecialType(SpecialType.System_Byte),
Symbols\EEMethodSymbol.vb (1)
263Return ReturnType.SpecialType = SpecialType.System_Void
Microsoft.CodeAnalysis.VisualBasic.ExpressionEvaluator.ExpressionCompiler.UnitTests (8)
ExpressionCompilerTests.vb (6)
1439Assert.Equal(SpecialType.System_Object, method.ReturnType.SpecialType) 1708Assert.Equal(SpecialType.System_Void, method.ReturnType.SpecialType) 2553Assert.Equal(DirectCast(methodData.Method, MethodSymbol).ReturnType.SpecialType, SpecialType.System_Boolean) 3367Assert.Equal(DirectCast(methodData.Method, MethodSymbol).ReturnType.SpecialType, SpecialType.System_String) 3439Assert.Equal(SpecialType.System_Int32, methodData.Method.ReturnType.SpecialType) 3474Assert.Equal(SpecialType.System_Int32, methodData.Method.ReturnType.SpecialType)
LocalsTests.vb (2)
1971Assert.Equal(SpecialType.System_Int32, testData.GetMethodData(typeName & ".<>m0").Method.ReturnType.SpecialType) 1980Assert.Equal(SpecialType.System_Int32, methodData.Method.ReturnType.SpecialType)
Microsoft.CodeAnalysis.VisualBasic.Features (47)
CodeFixes\GenerateEvent\GenerateEventCodeFixProvider.vb (3)
144returnType:=semanticModel.Compilation.GetSpecialType(SpecialType.System_Void), 286semanticModel.Compilation.GetSpecialType(SpecialType.System_Void)) 393returnType:=semanticModel.Compilation.GetSpecialType(SpecialType.System_Void),
Completion\CompletionProviders\OverrideCompletionProvider.vb (1)
193If overriddenMember.ContainingType.SpecialType = SpecialType.System_Object Then
Completion\KeywordRecommenders\Expressions\TrueFalseKeywordRecommender.vb (1)
37Return types.Any(Function(t) t.SpecialType = SpecialType.System_Boolean)
Completion\KeywordRecommenders\Types\BuiltInTypesKeywordRecommender.vb (19)
89SpecialType.System_Boolean, 90SpecialType.System_Byte, 91SpecialType.System_Char, 92SpecialType.System_DateTime, 93SpecialType.System_Decimal, 94SpecialType.System_Double, 95SpecialType.System_Int32, 96SpecialType.System_Int64, 97SpecialType.System_Object, 98SpecialType.System_SByte, 99SpecialType.System_Int16, 100SpecialType.System_Single, 101SpecialType.System_String, 102SpecialType.System_UInt32, 103SpecialType.System_UInt64, 104SpecialType.System_UInt16} 114Dim specialType As SpecialType = DirectCast(s_intrinsicSpecialTypes(i), SpecialType) 128Private Shared Function GetDocumentationCommentText(context As VisualBasicSyntaxContext, type As SpecialType, cancellationToken As CancellationToken) As String
Completion\Providers\DefaultArgumentProvider.vb (13)
26Case SpecialType.System_Boolean 28Case SpecialType.System_Char 30Case SpecialType.System_Byte 32Case SpecialType.System_SByte 34Case SpecialType.System_Int16 36Case SpecialType.System_UInt16 38Case SpecialType.System_Int32 40Case SpecialType.System_UInt32 42Case SpecialType.System_Int64 44Case SpecialType.System_UInt64 46Case SpecialType.System_Decimal 48Case SpecialType.System_Single 50Case SpecialType.System_Double
ExtractMethod\Extensions.vb (1)
474Return type Is Nothing OrElse type.SpecialType = SpecialType.System_Object
ExtractMethod\VisualBasicMethodExtractor.vb (1)
91If type.SpecialType = SpecialType.System_Void Then
ExtractMethod\VisualBasicMethodExtractor.VisualBasicCodeGenerator.vb (1)
357Return method.Parameters(0).Type.SpecialType = SpecialType.System_Boolean
ExtractMethod\VisualBasicSelectionResult.vb (1)
198If If(info.Type?.SpecialType = SpecialType.System_String, False) AndAlso
GenerateMember\GenerateParameterizedMember\VisualBasicGenerateParameterizedMemberService.vb (6)
44Return Me.Document.SemanticModel.Compilation.GetSpecialType(SpecialType.System_Int32) 46Return Me.Document.SemanticModel.Compilation.GetSpecialType(SpecialType.System_Int64) 48Return Me.Document.SemanticModel.Compilation.GetSpecialType(SpecialType.System_Decimal) 50Return Me.Document.SemanticModel.Compilation.GetSpecialType(SpecialType.System_Single) 52Return Me.Document.SemanticModel.Compilation.GetSpecialType(SpecialType.System_Double) 54Return Me.Document.SemanticModel.Compilation.GetSpecialType(SpecialType.System_String)
Microsoft.CodeAnalysis.VisualBasic.Scripting (17)
Hosting\ObjectFormatter\VisualBasicTypeNameFormatter.vb (17)
18Protected Overrides Function GetPrimitiveTypeName(type As SpecialType) As String 20Case SpecialType.System_Boolean 22Case SpecialType.System_Byte 24Case SpecialType.System_Char 26Case SpecialType.System_Decimal 28Case SpecialType.System_Double 30Case SpecialType.System_Int16 32Case SpecialType.System_Int32 34Case SpecialType.System_Int64 36Case SpecialType.System_SByte 38Case SpecialType.System_Single 40Case SpecialType.System_String 42Case SpecialType.System_UInt16 44Case SpecialType.System_UInt32 46Case SpecialType.System_UInt64 48Case SpecialType.System_DateTime 50Case SpecialType.System_Object
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (156)
Compilation\CompilationAPITests.vb (54)
325Dim ntSmb = comp.GetSpecialType(typeId:=SpecialType.Count) 326Assert.Equal(SpecialType.Count, ntSmb.SpecialType) 328ntSmb = comp.GetSpecialType(CType(31, SpecialType)) 405Assert.Equal(SpecialType.System_Array, comp.GetTypeByMetadataName("System.Array").SpecialType) 1344comp.GetSpecialType((SpecialType.None)) 1350comp.GetSpecialType(CType(0, SpecialType)) 1355comp.GetSpecialType(CType(100, SpecialType)) 1478Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 1479Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 1494Dim intType As TypeSymbol = comp.GetSpecialType(SpecialType.System_Int32) 1495Dim stringType As TypeSymbol = comp.GetSpecialType(SpecialType.System_String) 1511Dim elementType = comp.GetSpecialType(SpecialType.System_Object) 1536Dim elementType = comp.GetSpecialType(SpecialType.System_Object) 1562ImmutableArray.Create(DirectCast(compilation.GetSpecialType(SpecialType.System_Int32), ITypeSymbol), 1563DirectCast(compilation.GetSpecialType(SpecialType.System_Int32), ITypeSymbol)), 1575ImmutableArray.Create(DirectCast(Compilation.GetSpecialType(SpecialType.System_Int32), ITypeSymbol), 1576DirectCast(Compilation.GetSpecialType(SpecialType.System_Int32), ITypeSymbol)), 1586ImmutableArray.Create(DirectCast(compilation.GetSpecialType(SpecialType.System_Int32), ITypeSymbol), 1587DirectCast(compilation.GetSpecialType(SpecialType.System_Int32), ITypeSymbol)), 1607ImmutableArray.Create(DirectCast(compilation.GetSpecialType(SpecialType.System_Int32), ITypeSymbol), 1608DirectCast(compilation.GetSpecialType(SpecialType.System_Int32), ITypeSymbol)), 1634ImmutableArray.Create(Of ITypeSymbol)(compilation.GetSpecialType(SpecialType.System_Int32)), 1648ImmutableArray.Create(Of ITypeSymbol)(compilation.GetSpecialType(SpecialType.System_Int32)), 1663ImmutableArray.Create(Of ITypeSymbol)(compilation.GetSpecialType(SpecialType.System_Int32), compilation.GetSpecialType(SpecialType.System_Boolean)), 1677Dim memberTypes = ImmutableArray.Create(Of ITypeSymbol)(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)) 1715Dim memberTypes = ImmutableArray.Create(Of ITypeSymbol)(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)) 1746Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1761Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1762Dim boolType = compilation.GetSpecialType(SpecialType.System_Boolean) 1771Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 1780Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 1781Dim boolType = compilation.GetSpecialType(SpecialType.System_Boolean) 1792Dim doubleType = compilation.GetSpecialType(SpecialType.System_Double) 1808Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1817Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1818Dim nullableIntType = compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(intType) 1839Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1851Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1860Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1861Dim nullableIntType = compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(intType) 1895Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1904Dim intType = compilation.GetSpecialType(SpecialType.System_Int32) 1917Dim intType = Compilation.GetSpecialType(SpecialType.System_Int32) 1942Dim typeArguments = ImmutableArray.Create(Of ITypeSymbol)(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)) 1960typeArguments = ImmutableArray.Create(Of ITypeSymbol)(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)) 1974Dim typeArguments = ImmutableArray.Create(Of ITypeSymbol)(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String)) 1992typeArguments = ImmutableArray.Create(Of ITypeSymbol)(comp.GetSpecialType(SpecialType.System_Object), comp.GetSpecialType(SpecialType.System_String))
Compilation\SemanticModelGetDeclaredSymbolAPITests.vb (1)
8Imports Microsoft.CodeAnalysis.SpecialType
Semantics\AccessCheckTests.vb (2)
8Imports Microsoft.CodeAnalysis.SpecialType 795Assert.Equal(sourceAssem.GetSpecialType(SpecialType.System_Object), sourceAssem.ObjectType)
Semantics\ArrayLiteralTests.vb (1)
8Imports Microsoft.CodeAnalysis.SpecialType
Semantics\BinaryOperators.vb (27)
9Imports Microsoft.CodeAnalysis.SpecialType 982types(types.Length - 1) = compilation.GetSpecialType(SpecialType.System_String) 1036If (leftType.SpecialType <> SpecialType.System_Object AndAlso 1038(rightType.SpecialType <> SpecialType.System_Object AndAlso 1088Dim leftSpecial As SpecialType = leftType.GetEnumUnderlyingTypeOrSelf().SpecialType 1089Dim rightSpecial As SpecialType = rightType.GetEnumUnderlyingTypeOrSelf().SpecialType 1091Dim resultType As SpecialType = OverloadResolution.ResolveNotLiftedIntrinsicBinaryOperator(op, leftSpecial, rightSpecial) 1095If resultType = SpecialType.None AndAlso 1096(leftSpecial = SpecialType.None OrElse rightSpecial = SpecialType.None OrElse 1097(op = BinaryOperatorKind.Subtract AndAlso leftSpecial = SpecialType.System_DateTime AndAlso rightSpecial = SpecialType.System_DateTime)) Then 1099If leftSpecial = SpecialType.System_Object OrElse rightSpecial = SpecialType.System_Object OrElse TypeSymbol.Equals(leftType, rightType, TypeCompareKind.ConsiderEverything) Then 1100If leftSpecial = SpecialType.System_Object OrElse rightSpecial = SpecialType.System_Object Then 1101resultType = SpecialType.System_Object 1104Dim nonSpecialType = If(leftSpecial = SpecialType.System_Object, rightType, leftType) 1114resultType = SpecialType.None 1128If resultType = SpecialType.None Then 1183If resultType <> SpecialType.System_Object Then 1184returnName = compilation.GetSpecialType(SpecialType.System_Boolean).ToTestDisplayString() 1188If resultType <> SpecialType.System_Object Then 1189rightName = compilation.GetSpecialType(SpecialType.System_Int32).ToTestDisplayString() 1203If(op = BinaryOperatorKind.Add AndAlso resultType = SpecialType.System_String, 1212If(op = BinaryOperatorKind.Add AndAlso resultType = SpecialType.System_String, 1220If op = BinaryOperatorKind.Add AndAlso resultType = SpecialType.System_String Then
Semantics\CompoundAssignment.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\ConditionalExpressionsTests.vb (1)
9Imports Microsoft.CodeAnalysis.SpecialType
Semantics\Conversions.vb (6)
8Imports Microsoft.CodeAnalysis.SpecialType 460If type2.IsEnumType() AndAlso type1.SpecialType = SpecialType.System_Int32 Then 2184Private Function HasBuiltInWideningConversions(from As SpecialType, [to] As SpecialType) As ConversionKind 2303Private Function HasBuiltInNarrowingConversions(from As SpecialType, [to] As SpecialType) As ConversionKind
Semantics\ForeachTest.vb (7)
1168Assert.Equal(SpecialType.System_Object, loopInfo.CurrentProperty.Type.SpecialType) 1172Assert.Equal(SpecialType.System_Char, typeInfo.Type.SpecialType) 1208Assert.Equal(SpecialType.System_Object, loopInfo.CurrentProperty.Type.SpecialType) 1212Assert.Equal(SpecialType.System_Char, typeInfo.Type.SpecialType) 1256Assert.Equal(comp.GetSpecialType(SpecialType.System_Array), loopInfo0.GetEnumeratorMethod.ContainingType) ' Unlike C#, the spec doesn't say that arrays use IEnumerable 1260Assert.Equal(SpecialType.System_String, loopInfo0.ElementType.SpecialType) 1269Assert.Equal(SpecialType.System_Object, loopInfo1.ElementType.SpecialType) ' No longer string.
Semantics\GetExtendedSemanticInfoTests.vb (3)
8Imports Microsoft.CodeAnalysis.SpecialType 1960Assert.Equal(SpecialType.System_Void, semanticInfo.Type.SpecialType) 1961Assert.Equal(SpecialType.System_Void, semanticInfo.ConvertedType.SpecialType)
Semantics\GetSemanticInfoTests.vb (23)
10Imports Microsoft.CodeAnalysis.SpecialType 3785Assert.Equal(info.Type.SpecialType, SpecialType.System_Object) 3796Assert.Equal(info.Type.SpecialType, SpecialType.System_Object) 4520Assert.Equal(SpecialType.System_Collections_Generic_ICollection_T, CType(reducedFrom1.Parameters(0).Type.OriginalDefinition, TypeSymbol).SpecialType) 4531Assert.Equal(SpecialType.System_Collections_Generic_ICollection_T, CType(reducedFrom2.Parameters(0).Type.OriginalDefinition, TypeSymbol).SpecialType) 5722Dim otherFuncType = comp.GetWellKnownType(WellKnownType.System_Func_T).Construct(comp.GetSpecialType(SpecialType.System_Int32)) 5737Dim otherFuncType = comp.GetWellKnownType(WellKnownType.System_Func_T).Construct(comp.GetSpecialType(SpecialType.System_Int32)) 5944Dim typeInt = comp.GetSpecialType(SpecialType.System_Int32) 6151Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType) 6156Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType) 6213Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType) 6218Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType) 6223Assert.Equal(SpecialType.System_Object, model.GetTypeInfo(expr).Type.SpecialType) 6253Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType) 6283Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType) 6313Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType) 6351Assert.Equal(SpecialType.System_Boolean, model.GetTypeInfo(expr).Type.SpecialType) 6364Dim type = CType(SpecialType.None - 1, SpecialType) 6373Assert.StartsWith(expectedStartString:=$"Unexpected SpecialType: '{SpecialType.None - 1}'.", actualString:=ex.Message) 6389Dim type = CType(SpecialType.Count + 1, SpecialType) 6398Assert.StartsWith(expectedStartString:=$"Unexpected SpecialType: '{SpecialType.Count + 1}'.", actualString:=ex.Message)
Semantics\InterpolatedStringTests.vb (9)
376Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 427Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 769Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 820Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 876Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 877Dim objectType = compilation.GetSpecialType(SpecialType.System_Object) 933Dim stringType = compilation.GetSpecialType(SpecialType.System_String) 934Dim objectType = compilation.GetSpecialType(SpecialType.System_Object) 991Dim stringType = compilation.GetSpecialType(SpecialType.System_String)
Semantics\IsIsNot.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\MissingRuntimeHelpers.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\NameOfTests.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\NativeIntegerTests.vb (2)
51Assert.Equal(If(signed, SpecialType.System_IntPtr, SpecialType.System_UIntPtr), type.SpecialType)
Semantics\OverloadResolution.vb (2)
8Imports Microsoft.CodeAnalysis.SpecialType 2512Dim prev As SpecialType = 0
Semantics\RedimStatementTests.vb (1)
9Imports Microsoft.CodeAnalysis.SpecialType
Semantics\TooLongNameTests.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\TypeArgumentInference.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\TypeOfTests.vb (1)
763Assert.Equal(SpecialType.System_Object, typeInfo.ConvertedType.SpecialType)
Semantics\UnaryOperators.vb (4)
7Imports Microsoft.CodeAnalysis.SpecialType 722Dim special As SpecialType = type.GetEnumUnderlyingTypeOrSelf().SpecialType 724Dim resultType As SpecialType = OverloadResolution.ResolveNotLiftedIntrinsicUnaryOperator(op, special) 726If resultType = SpecialType.None Then
Semantics\UserDefinedBinaryOperators.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\UserDefinedConversions.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\UserDefinedForToLoop.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\UserDefinedUnaryOperators.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\VariableTypeInference.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Semantics\VarianceConversions.vb (1)
7Imports Microsoft.CodeAnalysis.SpecialType
Microsoft.CodeAnalysis.VisualBasic.Symbol.UnitTests (208)
DocumentationComments\DocCommentTests.vb (4)
4898TestSymbolAndTypeInfoForType(model, names(0), compilation.GetSpecialType(SpecialType.System_UInt16)) 4899TestSymbolAndTypeInfoForType(model, names(1), compilation.GetSpecialType(SpecialType.System_UInt16)) 4926TestSymbolAndTypeInfoForType(model, names(0), compilation.GetSpecialType(SpecialType.System_String)) 4927TestSymbolAndTypeInfoForType(model, names(1), compilation.GetSpecialType(SpecialType.System_String))
SymbolsTests\AssemblyAndNamespaceTests.vb (3)
526Dim objectType = comp.GetSpecialType(SpecialType.System_Object) 530Assert.Equal(objectType, comp.Assembly.GetSpecialType(SpecialType.System_Object)) 531Assert.Equal(objectType, comp.Assembly.CorLibrary.GetSpecialType(SpecialType.System_Object))
SymbolsTests\CompilationCreationTests.vb (9)
92Assert.Equal(SpecialType.None, c107.SpecialType) 94For i As Integer = 1 To SpecialType.Count Step 1 95Dim type As NamedTypeSymbol = c1.Assembly.GetSpecialType(CType(i, SpecialType)) 97If i = SpecialType.System_Runtime_CompilerServices_RuntimeFeature Or 98i = SpecialType.System_Runtime_CompilerServices_PreserveBaseOverridesAttribute Then 104Assert.Equal(CType(i, SpecialType), type.SpecialType) 107Assert.Equal(SpecialType.None, c107.SpecialType) 111Assert.Equal(SpecialType.None, arrayOfc107.SpecialType) 115Assert.Equal(SpecialType.None, c2.GlobalNamespace.GetTypeMembers("C107").Single().SpecialType)
SymbolsTests\CorLibrary\Choosing.vb (4)
46Dim obj = corLib.GetSpecialType(SpecialType.System_Object) 61Assert.Same(obj, consumer.GetSpecialType(SpecialType.System_Object)) 76Dim obj = corLib.GetSpecialType(SpecialType.System_Object) 88Assert.True(consumer.GetSpecialType(SpecialType.System_Object).IsErrorType())
SymbolsTests\CorLibrary\CorTypes.vb (26)
20For i As Integer = 1 To SpecialType.Count 21Dim t = noMsCorLibRef.GetSpecialType(CType(i, SpecialType)) 22Assert.Equal(CType(i, SpecialType), t.SpecialType) 33Assert.Equal(SpecialType.System_Int32, p.SpecialType) 43For i As Integer = 1 To SpecialType.Count 44Dim t = msCorLibRef.GetSpecialType(CType(i, SpecialType)) 45Assert.Equal(CType(i, SpecialType), t.SpecialType) 73ElseIf (DirectCast(m, NamedTypeSymbol).SpecialType <> SpecialType.None) Then 77If (count >= SpecialType.Count) Then 83Assert.Equal(count + knownMissingTypes.Count, CType(SpecialType.Count, Integer)) 92For i As Integer = 1 To SpecialType.Count 94Dim t = msCorLibRef.GetSpecialType(CType(i, SpecialType)) 95Assert.Equal(CType(i, SpecialType), t.SpecialType) 97If (t.SpecialType = SpecialType.System_Object) Then 126For i As Integer = 1 To SpecialType.Count 127If (i <> SpecialType.System_Object) Then 129Dim t = c1.Assembly.GetSpecialType(CType(i, SpecialType)) 130Assert.Equal(CType(i, SpecialType), t.SpecialType) 140Assert.Equal(SpecialType.System_Object, system_object.SpecialType) 144Assert.Same(system_object, c1.Assembly.GetSpecialType(SpecialType.System_Object)) 146Assert.Throws(Of ArgumentOutOfRangeException)(Function() c1.GetSpecialType(SpecialType.None)) 147Assert.Throws(Of ArgumentOutOfRangeException)(Function() c1.GetSpecialType(CType(SpecialType.Count + 1, SpecialType))) 148Assert.Throws(Of ArgumentOutOfRangeException)(Function() msCorLibRef.GetSpecialType(SpecialType.None)) 149Assert.Throws(Of ArgumentOutOfRangeException)(Function() msCorLibRef.GetSpecialType(CType(SpecialType.Count + 1, SpecialType)))
SymbolsTests\ExtensionMethods\ExtensionMethodTests.vb (1)
2563Dim reducedMethodOnVoid = extensionMethod.ReduceExtensionMethod(compilation.GetSpecialType(SpecialType.System_Void))
SymbolsTests\InstantiatingGenerics.vb (4)
467Dim int = compilation.GetSpecialType(SpecialType.System_Int32) 689Dim int = compilation.GetSpecialType(SpecialType.System_Int32) 690Dim bte = compilation.GetSpecialType(SpecialType.System_Byte) 691Dim chr = compilation.GetSpecialType(SpecialType.System_Char)
SymbolsTests\Metadata\PE\BaseTypeResolution.vb (2)
295Assert.Equal("System.Object", DirectCast(c1.Assembly.Modules(0), SourceModuleSymbol).GetCorLibType(SpecialType.System_Object).ToTestDisplayString()) 300Assert.Equal("System.Object[missing]", DirectCast(c2.Assembly.Modules(0), SourceModuleSymbol).GetCorLibType(SpecialType.System_Object).ToTestDisplayString())
SymbolsTests\Metadata\PE\LoadingEvents.vb (2)
123Assert.Equal(SpecialType.System_Void, accessor.ReturnType.SpecialType) 155Assert.Equal(SpecialType.System_Int32, nonDelegateEvent.Type.SpecialType)
SymbolsTests\Metadata\PE\LoadingFields.vb (1)
60Assert.Same(DirectCast(module2, PEModuleSymbol).GetCorLibType(SpecialType.System_Int32), f2.Type)
SymbolsTests\Metadata\PE\LoadingOperators.vb (1)
2800Dim nullable = compilation.GetSpecialType(SpecialType.System_Nullable_T)
SymbolsTests\Metadata\PE\MissingTypeReferences.vb (4)
421Assert.Equal(asm1.GetSpecialType(SpecialType.System_Boolean), asm1.GetSpecialType(SpecialType.System_Boolean)) 422Assert.Equal(asm2.GetSpecialType(SpecialType.System_Boolean), asm1.GetSpecialType(SpecialType.System_Boolean))
SymbolsTests\Metadata\WinMdEventTest.vb (2)
1605Dim voidType = compilation.GetSpecialType(SpecialType.System_Void) 1632Dim voidType = compilation.GetSpecialType(SpecialType.System_Void)
SymbolsTests\Retargeting\RetargetCustomModifiers.vb (1)
120Assert.Equal(SpecialType.System_Int32, volatileFld.[Type].SpecialType)
SymbolsTests\Retargeting\RetargetingTests.vb (20)
363Assert.Equal(SpecialType.System_Enum, sourceType.BaseType.SpecialType) 365Assert.Equal(SpecialType.System_Int32, sourceType.EnumUnderlyingType.SpecialType) 372Assert.Equal(SpecialType.System_Enum, retargetingType.BaseType.SpecialType) 374Assert.Equal(SpecialType.System_Int32, retargetingType.EnumUnderlyingType.SpecialType) 401Assert.Equal(SpecialType.System_Enum, sourceType.BaseType.SpecialType) 403Assert.Equal(SpecialType.System_Int16, sourceType.EnumUnderlyingType.SpecialType) 410Assert.Equal(SpecialType.System_Enum, retargetingType.BaseType.SpecialType) 412Assert.Equal(SpecialType.System_Int16, retargetingType.EnumUnderlyingType.SpecialType) 434Assert.Equal(SpecialType.System_Object, sourceType.BaseType.SpecialType) 439Assert.Equal(SpecialType.System_Object, retargetingType.BaseType.SpecialType) 474Assert.Equal(SpecialType.System_Object, sourceType.BaseType.SpecialType) 479Assert.Equal(SpecialType.System_Object, retargetingType.BaseType.SpecialType) 501Assert.Equal(SpecialType.System_ValueType, sourceType.BaseType.SpecialType) 506Assert.Equal(SpecialType.System_ValueType, retargetingType.BaseType.SpecialType) 541Assert.Equal(SpecialType.System_ValueType, sourceType.BaseType.SpecialType) 547Assert.Equal(SpecialType.System_ValueType, retargetingType.BaseType.SpecialType) 633Assert.Equal(SpecialType.System_Int16, sourceTypeParameterConstraint.SpecialType) 639Assert.Equal(SpecialType.System_Int16, retargetingTypeParameterConstraint.SpecialType) 675Assert.Equal(SpecialType.System_Int16, sourceTypeParameterConstraint.SpecialType) 682Assert.Equal(SpecialType.System_Int16, retargetingTypeParameterConstraint.SpecialType)
SymbolsTests\Source\BaseClassTests.vb (3)
2290Dim typeC = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("C").Construct(comp.GetSpecialType(SpecialType.System_Int32)) 2325Dim typeC = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("C").Construct(comp.GetSpecialType(SpecialType.System_Int32)) 2355Dim typeC = comp.GlobalNamespace.GetMember(Of NamedTypeSymbol)("C").Construct(comp.GetSpecialType(SpecialType.System_Int32))
SymbolsTests\Source\ClsComplianceTests.vb (12)
2560Dim integerType = helper.GetSpecialType(SpecialType.System_Int32) 2562For Each st As SpecialType In [Enum].GetValues(GetType(SpecialType)) 2564Case SpecialType.None, SpecialType.System_Void, SpecialType.System_Runtime_CompilerServices_IsVolatile 2578Case SpecialType.System_SByte, SpecialType.System_UInt16, SpecialType.System_UInt32, SpecialType.System_UInt64, SpecialType.System_UIntPtr, SpecialType.System_TypedReference
SymbolsTests\Source\DelegateTests.vb (2)
251Assert.Equal(compilation.GetSpecialType(SpecialType.System_Object), ctor.Parameters(0).Type) 252Assert.Equal(compilation.GetSpecialType(SpecialType.System_IntPtr), ctor.Parameters(1).Type)
SymbolsTests\Source\EnumTests.vb (13)
110Dim fields = VerifyEnumsValue(text, "Suits", SpecialType.System_Byte, Nothing, CByte(2), Nothing) 137fields = VerifyEnumsValue(text, "Suits", SpecialType.System_Byte, Nothing, CByte(2), Nothing) 166fields = VerifyEnumsValue(text, "Suits", SpecialType.System_Int16, CShort(0), CShort(1), CShort(2), Nothing, Nothing, Nothing) 259VerifyEnumsValue(text, "c1.EnumTest", SpecialType.System_Int32, Nothing, Nothing) 821VerifyEnumsValue(comp, "c1.COLORS", SpecialType.System_UInt32, 0UI, 1UI, 2UI) 845VerifyEnumsValue(comp, "Figure", SpecialType.System_Int32, 0, 1, 2) 865VerifyEnumsValue(comp, "Figure", SpecialType.System_Int64, CLng(0), CLng(1), CLng(2)) 886VerifyEnumsValue(comp, "Figure", SpecialType.System_Int32, 0, 1, 2) 1212Assert.Equal(type.SpecialType, SpecialType.System_Int32) 1350Return VerifyEnumsValue(comp, enumName, If(expectedEnumValues.Any() AndAlso expectedEnumValues.First().GetType() Is GetType(Long), SpecialType.System_Int64, SpecialType.System_Int32), expectedEnumValues) 1353Private Shared Function VerifyEnumsValue(text As XElement, enumName As String, underlyingType As SpecialType, ParamArray expectedEnumValues As Object()) As List(Of Symbol) 1358Private Shared Function VerifyEnumsValue(comp As VisualBasicCompilation, enumName As String, underlyingType As SpecialType, ParamArray expectedEnumValues As Object()) As List(Of Symbol)
SymbolsTests\Source\FieldTests.vb (9)
113Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Nullable_T), fieldP.Type.OriginalDefinition) 114Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Char), DirectCast(fieldP.Type, NamedTypeSymbol).TypeArguments(0)) 121Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Char), fieldQ.Type) 128Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Object), fieldR.Type) 135Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Int64), fieldS.Type) 142Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Int32), fieldT.Type) 150Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Decimal), DirectCast(fieldU.Type, ArrayTypeSymbol).ElementType) 172Assert.Same(sourceMod.GetCorLibType(SpecialType.System_UInt32), fieldL.Type) 535Dim substitutedType = type.Construct(compilation.GetSpecialType(SpecialType.System_Int32))
SymbolsTests\Source\ImplementsTests.vb (17)
1736Dim ifooTypeSayWithString = (From m In ifooMethods Where m.Parameters(0).Type.SpecialType = SpecialType.System_String).First() 1737Dim ifooTypeSayWithInt = (From m In ifooMethods Where m.Parameters(0).Type.SpecialType = SpecialType.System_Int32).First() 2220Dim ifooTypeStyleWithString = (From m In ifooProps Where m.Parameters(0).Type.SpecialType = SpecialType.System_String).First() 2222Dim ifooTypeStyleWithInt = (From m In ifooProps Where m.Parameters(0).Type.SpecialType = SpecialType.System_Int32).First() 2312Dim ifooTypeSayWithString = (From m In ifooMethods Where m.Parameters(0).Type.SpecialType = SpecialType.System_String).First() 2313Dim ifooTypeSayWithInt = (From m In ifooMethods Where m.Parameters(0).Type.SpecialType = SpecialType.System_Int32).First() 2314Dim ifooTypeSayWithLong = (From m In ifooMethods Where m.Parameters(0).Type.SpecialType = SpecialType.System_Int64).First() 2401Dim ifooTypeStyleWithString = (From m In ifooProps Where m.Parameters(0).Type.SpecialType = SpecialType.System_String).First() 2403Dim ifooTypeStyleWithInt = (From m In ifooProps Where m.Parameters(0).Type.SpecialType = SpecialType.System_Int32).First() 2405Dim ifooTypeStyleWithLong = (From m In ifooProps Where m.Parameters(0).Type.SpecialType = SpecialType.System_Int64).First() 2483Dim ifooTypeSayWithInt = (From m In ifooMethods Where m.Parameters(0).Type.SpecialType = SpecialType.System_Int32).First() 2532Dim listOfString = listOfT.Construct(comp.GetSpecialType(SpecialType.System_String)) 2535Dim outerOfInt = outerOfX.Construct(comp.GetSpecialType(SpecialType.System_Int32)) 2544Dim iFooOfIntIntListOfString = iFooOfIntTU.Construct(comp.GetSpecialType(SpecialType.System_Int32), listOfString) 2546Dim fooOfIntString = fooOfIntY.Construct(comp.GetSpecialType(SpecialType.System_String)) 2549Dim ifooOfIntIntStringSay1 = (From m In iFooOfIntIntListOfStringMethods Where TypeSymbol.Equals(m.Parameters(0).Type, comp.GetSpecialType(SpecialType.System_Int32), TypeCompareKind.ConsiderEverything)).First() 2550Dim ifooOfIntIntStringSay2 = (From m In iFooOfIntIntListOfStringMethods Where Not TypeSymbol.Equals(m.Parameters(0).Type, comp.GetSpecialType(SpecialType.System_Int32), TypeCompareKind.ConsiderEverything)).First()
SymbolsTests\Source\MethodTests.vb (15)
680Dim constructedC = classC.Construct((New TypeSymbol() {compilation.GetSpecialType(SpecialType.System_Int32)}).AsImmutableOrNull()) 755Dim constructedM1 = m1.Construct((New TypeSymbol() {compilation.GetSpecialType(SpecialType.System_String), compilation.GetSpecialType(SpecialType.System_Boolean)}).AsImmutableOrNull()) 766Assert.Throws(Of InvalidOperationException)(Sub() constructedM1.Construct((New TypeSymbol() {compilation.GetSpecialType(SpecialType.System_String), compilation.GetSpecialType(SpecialType.System_Boolean)}).AsImmutableOrNull())) 770Dim constructedM1WrongArity = m1.Construct((New TypeSymbol() {compilation.GetSpecialType(SpecialType.System_String)}).AsImmutableOrNull()) 782constructedM1 = m1.Construct((New TypeSymbol() {compilation.GetSpecialType(SpecialType.System_String), compilation.GetSpecialType(SpecialType.System_Boolean)}).AsImmutableOrNull()) 784Assert.Throws(Of InvalidOperationException)(Sub() constructedM1.Construct((New TypeSymbol() {compilation.GetSpecialType(SpecialType.System_String), compilation.GetSpecialType(SpecialType.System_Boolean)}).AsImmutableOrNull())) 785Dim constructedM1_2 = m1.Construct(compilation.GetSpecialType(SpecialType.System_Byte), compilation.GetSpecialType(SpecialType.System_Boolean)) 786Dim constructedM1_3 = m1.Construct((New TypeSymbol() {compilation.GetSpecialType(SpecialType.System_String), compilation.GetSpecialType(SpecialType.System_Boolean)}).AsImmutableOrNull()) 801Dim constructedM3 = m3.Construct(compilation.GetSpecialType(SpecialType.System_String))
SymbolsTests\Source\OverridesTests.vb (9)
2497Dim x1StringArgGetter = (From meth In x1Getters Let params = meth.Parameters Where params.Length = 1 AndAlso params(0).Type.SpecialType = SpecialType.System_String Select meth).First() 2500Dim x1LongArgGetter = (From meth In x1Getters Let params = meth.Parameters Where params.Length = 1 AndAlso params(0).Type.SpecialType = SpecialType.System_Int64 Select meth).First() 2507Dim x2LongArgGetter = (From meth In x2Getters Let params = meth.Parameters Where params.Length = 1 AndAlso params(0).Type.SpecialType = SpecialType.System_Int64 Select meth).First() 2510Dim x2DoubleArgGetter = (From meth In x2Getters Let params = meth.Parameters Where params.Length = 1 AndAlso params(0).Type.SpecialType = SpecialType.System_Double Select meth).First() 2517Dim x1StringArgSetter = (From meth In x1Setters Let params = meth.Parameters Where params.Length = 2 AndAlso params(0).Type.SpecialType = SpecialType.System_String Select meth).First() 2520Dim x1LongArgSetter = (From meth In x1Setters Let params = meth.Parameters Where params.Length = 2 AndAlso params(0).Type.SpecialType = SpecialType.System_Int64 Select meth).First() 2527Dim x2LongArgSetter = (From meth In x2Setters Let params = meth.Parameters Where params.Length = 2 AndAlso params(0).Type.SpecialType = SpecialType.System_Int64 Select meth).First() 2530Dim x2DoubleArgSetter = (From meth In x2Setters Let params = meth.Parameters Where params.Length = 2 AndAlso params(0).Type.SpecialType = SpecialType.System_Double Select meth).First() 2548Dim obj = compilation.GetSpecialType(SpecialType.System_Object)
SymbolsTests\Source\PropertyTests.vb (19)
782Assert.Equal(SpecialType.System_Object, [property].Type.SpecialType) 783Assert.Equal(SpecialType.System_Int32, [property].Parameters(0).Type.SpecialType) 785Assert.Equal(SpecialType.System_Int32, [property].GetMethod.Parameters(0).Type.SpecialType) 787Assert.Equal(SpecialType.System_Int32, [property].SetMethod.Parameters(0).Type.SpecialType) 788Assert.Equal(SpecialType.System_Object, [property].SetMethod.Parameters(1).Type.SpecialType) 854Assert.Equal(SpecialType.System_String, P2s.ElementAt(1).Type.SpecialType) 3796Assert.Equal(SpecialType.System_Int32, bindings.GetSpeculativeSemanticInfoSummary(position, SyntaxFactory.ParseExpression("Goo().Items(1)"), SpeculativeBindingOption.BindAsExpression).Type.SpecialType) 3797Assert.Equal(SpecialType.System_Int32, bindings.GetSpeculativeSemanticInfoSummary(position, SyntaxFactory.ParseExpression("Goo.Items(1)"), SpeculativeBindingOption.BindAsExpression).Type.SpecialType) 3798Assert.Equal(SpecialType.System_Int32, bindings.GetSpeculativeSemanticInfoSummary(position, SyntaxFactory.ParseExpression("Goo()(1)"), SpeculativeBindingOption.BindAsExpression).Type.SpecialType) 3799Assert.Equal(SpecialType.System_Int32, bindings.GetSpeculativeSemanticInfoSummary(position, SyntaxFactory.ParseExpression("Goo(1)"), SpeculativeBindingOption.BindAsExpression).Type.SpecialType) 3800Assert.Equal(SpecialType.System_Int32, bindings.GetSpeculativeSemanticInfoSummary(position, SyntaxFactory.ParseExpression("dd.Item(1)"), SpeculativeBindingOption.BindAsExpression).Type.SpecialType) 3801Assert.Equal(SpecialType.System_Int32, bindings.GetSpeculativeSemanticInfoSummary(position, SyntaxFactory.ParseExpression("Bar(1)"), SpeculativeBindingOption.BindAsExpression).Type.SpecialType) 4342Assert.Equal(SpecialType.System_Object, propertiesDictionary!Typeless.Type.SpecialType) 4343Assert.Equal(SpecialType.System_String, propertiesDictionary!StringType.Type.SpecialType) 4344Assert.Equal(SpecialType.System_Int32, propertiesDictionary!IntegerType.Type.SpecialType) 4345Assert.Equal(SpecialType.System_Int64, propertiesDictionary!LongType.Type.SpecialType) 4346Assert.Equal(SpecialType.System_Decimal, propertiesDictionary!DecimalType.Type.SpecialType) 4347Assert.Equal(SpecialType.System_Single, propertiesDictionary!SingleType.Type.SpecialType) 4348Assert.Equal(SpecialType.System_Double, propertiesDictionary!DoubleType.Type.SpecialType)
SymbolsTests\Source\SyntheticEntryPoint.vb (1)
8Imports Microsoft.CodeAnalysis.SpecialType
SymbolsTests\Source\TypeBindingTests.vb (7)
48Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Int32), arrayTypeA.ElementType) 49Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Array), arrayTypeA.BaseType) 60Assert.Same(sourceMod.GetCorLibType(SpecialType.System_String), arrayTypeB3.ElementType) 89Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Nullable_T), namedTypeA.OriginalDefinition) 90Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Int32), namedTypeA.TypeArguments(0)) 231Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Int32), fieldB.Type) 445Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Int32), containerTypeB.TypeArguments(0))
SymbolsTests\Source\TypeTests.vb (3)
3800Dim modifiers = ImmutableArray.Create(VisualBasicCustomModifier.CreateOptional(compilation.GetSpecialType(SpecialType.System_Object))) 3864Dim modifiers = ImmutableArray.Create(VisualBasicCustomModifier.CreateOptional(compilation.GetSpecialType(SpecialType.System_Object))) 3925Dim modifiers = ImmutableArray.Create(VisualBasicCustomModifier.CreateOptional(compilation.GetSpecialType(SpecialType.System_Object)))
SymbolsTests\TypedConstantTests.vb (2)
27_namedType = _compilation.GetSpecialType(SpecialType.System_Byte) 29_arrayType = _compilation.CreateArrayTypeSymbol(_compilation.GetSpecialType(SpecialType.System_Object))
SymbolsTests\WellKnownTypeValidationTests.vb (12)
37Dim special = comp.GetSpecialType(SpecialType.System_String) 39Assert.Equal(SpecialType.System_String, special.SpecialType) 44Assert.Equal(SpecialType.None, lookup.SpecialType) 121Dim special = comp.GetSpecialType(SpecialType.System_Nullable_T) 123Assert.Equal(SpecialType.System_Nullable_T, special.SpecialType) 127Assert.Equal(SpecialType.System_Nullable_T, lookup.SpecialType) 453For special As SpecialType = CType(SpecialType.None + 1, SpecialType) To SpecialType.Count 457If special = SpecialType.System_Runtime_CompilerServices_RuntimeFeature OrElse 458special = SpecialType.System_Runtime_CompilerServices_PreserveBaseOverridesAttribute Then
Microsoft.CodeAnalysis.VisualBasic.Syntax.UnitTests (15)
Syntax\ConstantExpressionEvaluatorTests.vb (15)
12Assert.Equal(ConstantValueTypeDiscriminator.SByte, SpecialType.System_SByte.ToConstantValueDiscriminator()) 13Assert.Equal(ConstantValueTypeDiscriminator.Byte, SpecialType.System_Byte.ToConstantValueDiscriminator()) 14Assert.Equal(ConstantValueTypeDiscriminator.Int16, SpecialType.System_Int16.ToConstantValueDiscriminator()) 15Assert.Equal(ConstantValueTypeDiscriminator.UInt16, SpecialType.System_UInt16.ToConstantValueDiscriminator()) 16Assert.Equal(ConstantValueTypeDiscriminator.Int32, SpecialType.System_Int32.ToConstantValueDiscriminator()) 17Assert.Equal(ConstantValueTypeDiscriminator.UInt32, SpecialType.System_UInt32.ToConstantValueDiscriminator()) 18Assert.Equal(ConstantValueTypeDiscriminator.Int64, SpecialType.System_Int64.ToConstantValueDiscriminator()) 19Assert.Equal(ConstantValueTypeDiscriminator.UInt64, SpecialType.System_UInt64.ToConstantValueDiscriminator()) 20Assert.Equal(ConstantValueTypeDiscriminator.Char, SpecialType.System_Char.ToConstantValueDiscriminator()) 21Assert.Equal(ConstantValueTypeDiscriminator.Boolean, SpecialType.System_Boolean.ToConstantValueDiscriminator()) 22Assert.Equal(ConstantValueTypeDiscriminator.Single, SpecialType.System_Single.ToConstantValueDiscriminator()) 23Assert.Equal(ConstantValueTypeDiscriminator.Double, SpecialType.System_Double.ToConstantValueDiscriminator()) 24Assert.Equal(ConstantValueTypeDiscriminator.Decimal, SpecialType.System_Decimal.ToConstantValueDiscriminator()) 25Assert.Equal(ConstantValueTypeDiscriminator.DateTime, SpecialType.System_DateTime.ToConstantValueDiscriminator()) 26Assert.Equal(ConstantValueTypeDiscriminator.String, SpecialType.System_String.ToConstantValueDiscriminator())
Microsoft.CodeAnalysis.VisualBasic.Test.Utilities (2)
MetadataHelpers.vb (1)
12Friend Function GetCorLibType(this As ModuleSymbol, typeId As SpecialType) As NamedTypeSymbol
MockSymbols.vb (1)
779Friend Overrides Function GetDeclaredSpecialType(type As SpecialType) As NamedTypeSymbol
Microsoft.CodeAnalysis.VisualBasic.Workspaces (203)
CastAnalyzer.vb (15)
228If If(castType?.SpecialType = SpecialType.System_Object, False) AndAlso 322DirectCast(castExpressionType.OriginalDefinition, ITypeSymbol).SpecialType = SpecialType.System_Nullable_T 384Case SpecialType.System_Single, SpecialType.System_Double 386Case SpecialType.System_UInt32, SpecialType.System_Int32, 387SpecialType.System_UInt64, SpecialType.System_Int64, 388SpecialType.System_Decimal 400ElseIf castType.SpecialType = SpecialType.System_DateTime 401Return Not outerType.SpecialType = SpecialType.System_DateTime 402ElseIf castType.SpecialType = SpecialType.System_Boolean 403Return Not (outerType.IsNumericType OrElse outerType.SpecialType = SpecialType.System_Boolean) 406If castType.OriginalDefinition?.SpecialType = SpecialType.System_Nullable_T Then 418If castType.Equals(outerType) OrElse outerType.SpecialType = SpecialType.System_Object Then
CodeCleanup\AsyncOrIteratorFunctionReturnTypeFixer.vb (5)
133Case SpecialType.System_Collections_IEnumerable, SpecialType.System_Collections_IEnumerator, 134SpecialType.System_Collections_Generic_IEnumerable_T, SpecialType.System_Collections_Generic_IEnumerator_T 137Dim iEnumerableOfT = semanticModel.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T)
CodeGeneration\ExpressionGenerator.vb (28)
71Return GenerateIntegralLiteralExpression(type, SpecialType.System_SByte, DirectCast(value, SByte), canUseFieldReference, LiteralSpecialValues.SByteSpecialValues, Function(x) x < 0, Function(x) -x, "128") 73Return GenerateIntegralLiteralExpression(type, SpecialType.System_Int16, DirectCast(value, Short), canUseFieldReference, LiteralSpecialValues.Int16SpecialValues, Function(x) x < 0, Function(x) -x, "32768") 75Return GenerateIntegralLiteralExpression(type, SpecialType.System_Int32, DirectCast(value, Integer), canUseFieldReference, LiteralSpecialValues.Int32SpecialValues, Function(x) x < 0, Function(x) -x, "2147483648") 77Return GenerateIntegralLiteralExpression(type, SpecialType.System_Int64, DirectCast(value, Long), canUseFieldReference, LiteralSpecialValues.Int64SpecialValues, Function(x) x < 0, Function(x) -x, "9223372036854775808") 79Return GenerateNonNegativeIntegralLiteralExpression(type, SpecialType.System_Byte, DirectCast(value, Byte), canUseFieldReference, LiteralSpecialValues.ByteSpecialValues) 81Return GenerateNonNegativeIntegralLiteralExpression(type, SpecialType.System_UInt16, DirectCast(value, UShort), canUseFieldReference, LiteralSpecialValues.UInt16SpecialValues) 83Return GenerateNonNegativeIntegralLiteralExpression(type, SpecialType.System_UInt32, DirectCast(value, UInteger), canUseFieldReference, LiteralSpecialValues.UInt32SpecialValues) 85Return GenerateNonNegativeIntegralLiteralExpression(type, SpecialType.System_UInt64, DirectCast(value, ULong), canUseFieldReference, LiteralSpecialValues.UInt64SpecialValues) 116If Not IsSpecialType(type, SpecialType.System_String) Then 163specialType As SpecialType, 179specialType As SpecialType, 216If TypeOf value Is Byte AndAlso Not IsSpecialType(type, SpecialType.System_Byte) Then 218ElseIf TypeOf value Is SByte AndAlso Not IsSpecialType(type, SpecialType.System_SByte) Then 229If TypeOf value Is Short AndAlso Not IsSpecialType(type, SpecialType.System_Int16) Then 232ElseIf TypeOf value Is Long AndAlso Not IsSpecialType(type, SpecialType.System_Int64) Then 239Dim typeIsNotDecimal = Not IsSpecialType(type, SpecialType.System_Decimal) 249ElseIf TypeOf value Is UShort AndAlso Not IsSpecialType(type, SpecialType.System_UInt16) Then 252ElseIf TypeOf value Is UInteger AndAlso Not IsSpecialType(type, SpecialType.System_UInt32) Then 258Dim typeIsNotULong = Not IsSpecialType(type, SpecialType.System_UInt64) 266ElseIf TypeOf value Is Single AndAlso Not IsSpecialType(type, SpecialType.System_Single) Then 269ElseIf TypeOf value Is Double AndAlso Not IsSpecialType(type, SpecialType.System_Double) Then 295type, SpecialType.System_Double, value, canUseFieldReference, 320type, SpecialType.System_Single, value, canUseFieldReference, 326specialType As SpecialType, 375Dim field = GenerateFieldReference(SpecialType.System_Decimal, value, LiteralSpecialValues.DecimalSpecialValues) 389Private Function AddSpecialTypeAnnotation(type As SpecialType, expression As MemberAccessExpressionSyntax) As MemberAccessExpressionSyntax 390If SpecialType.None <> type Then 397Private Function GenerateFieldReference(Of TStructure)(type As SpecialType,
CodeGeneration\MethodGenerator.vb (1)
70Dim isSub = method.ReturnType.SpecialType = SpecialType.System_Void
CodeGeneration\NamedTypeGenerator.vb (2)
149If(namedType.EnumUnderlyingType IsNot Nothing AndAlso namedType.EnumUnderlyingType.SpecialType <> SpecialType.System_Int32, 207namedType.BaseType.SpecialType = SpecialType.System_Object Then
CodeGeneration\ParameterGenerator.vb (1)
48elementType.OriginalDefinition.SpecialType <> SpecialType.System_Nullable_T Then
CodeGeneration\VisualBasicFlagsEnumGenerator.vb (1)
20underlyingSpecialType As SpecialType,
CodeGeneration\VisualBasicSyntaxGenerator.vb (17)
412Public Overrides Function TypeExpression(specialType As SpecialType) As SyntaxNode 414Case SpecialType.System_Boolean 416Case SpecialType.System_Byte 418Case SpecialType.System_Char 420Case SpecialType.System_Decimal 422Case SpecialType.System_Double 424Case SpecialType.System_Int16 426Case SpecialType.System_Int32 428Case SpecialType.System_Int64 430Case SpecialType.System_Object 432Case SpecialType.System_SByte 434Case SpecialType.System_Single 436Case SpecialType.System_String 438Case SpecialType.System_UInt16 440Case SpecialType.System_UInt32 442Case SpecialType.System_UInt64 444Case SpecialType.System_DateTime
ITypeSymbolExtensions.vb (49)
19Public Function GetPredefinedCastKeyword(specialType As SpecialType) As SyntaxKind 21Case specialType.System_Boolean 23Case specialType.System_Byte 25Case specialType.System_Char 27Case specialType.System_DateTime 29Case specialType.System_Decimal 31Case specialType.System_Double 33Case specialType.System_Int32 35Case specialType.System_Int64 37Case specialType.System_Object 39Case specialType.System_SByte 41Case specialType.System_Single 43Case specialType.System_Int16 45Case SpecialType.System_String 47Case specialType.System_UInt32 49Case specialType.System_UInt64 51Case specialType.System_UInt16 60Dim specialType As SpecialType 63specialType = specialType.System_Boolean 65specialType = specialType.System_Byte 67specialType = specialType.System_Char 69specialType = specialType.System_DateTime 71specialType = specialType.System_Decimal 73specialType = specialType.System_Double 75specialType = specialType.System_Int32 77specialType = specialType.System_Int64 79specialType = specialType.System_Object 81specialType = specialType.System_SByte 83specialType = specialType.System_Single 85specialType = specialType.System_String 87specialType = specialType.System_Int16 89specialType = specialType.System_UInt32 91specialType = specialType.System_UInt64 93specialType = specialType.System_UInt16 104Case SpecialType.System_Boolean, 105SpecialType.System_Byte, 106SpecialType.System_SByte, 107SpecialType.System_Int16, 108SpecialType.System_UInt16, 109SpecialType.System_Int32, 110SpecialType.System_UInt32, 111SpecialType.System_Int64, 112SpecialType.System_UInt64, 113SpecialType.System_Single, 114SpecialType.System_Double, 115SpecialType.System_Decimal, 116SpecialType.System_DateTime, 117SpecialType.System_Char, 118SpecialType.System_String
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\VisualBasic\Extensions\ExpressionSyntaxExtensions.vb\ExpressionSyntaxExtensions.vb (1)
111If typeInfo.Type IsNot Nothing AndAlso typeInfo.Type.SpecialType = SpecialType.System_Void Then
Recommendations\VisualBasicRecommendationServiceRunner.vb (1)
156Return typeSymbol.SpecialType <> SpecialType.System_Delegate
Rename\VisualBasicRenameRewriterLanguageService.vb (1)
945If Not method.ReturnsVoid AndAlso Not method.Parameters.Any() AndAlso method.ReturnType.SpecialType = SpecialType.System_Boolean Then
Simplification\Simplifiers\AbstractVisualBasicSimplifier.vb (17)
21Protected Shared Function GetPredefinedKeywordKind(type As SpecialType) As SyntaxKind 23Case SpecialType.System_Boolean 25Case SpecialType.System_Byte 27Case SpecialType.System_SByte 29Case SpecialType.System_Int32 31Case SpecialType.System_UInt32 33Case SpecialType.System_Int16 35Case SpecialType.System_UInt16 37Case SpecialType.System_Int64 39Case SpecialType.System_UInt64 41Case SpecialType.System_Single 43Case SpecialType.System_Double 45Case SpecialType.System_Decimal 47Case SpecialType.System_String 49Case SpecialType.System_Char 51Case SpecialType.System_Object 53Case SpecialType.System_DateTime
Simplification\Simplifiers\ExpressionSimplifier.vb (1)
246If isInCref AndAlso TypeOf rightSymbol Is IMethodSymbol AndAlso Not containingType.SpecialType = SpecialType.None Then
StringExtensions.vb (16)
97Case SpecialType.System_Boolean, 98SpecialType.System_Byte, 99SpecialType.System_SByte, 100SpecialType.System_Int16, 101SpecialType.System_UInt16, 102SpecialType.System_Int32, 103SpecialType.System_UInt32, 104SpecialType.System_Int64, 105SpecialType.System_UInt64, 106SpecialType.System_Single, 107SpecialType.System_Double, 108SpecialType.System_Decimal, 109SpecialType.System_DateTime, 110SpecialType.System_Char, 111SpecialType.System_String, 112SpecialType.System_Object
TypeSyntaxGeneratorVisitor.vb (17)
81If symbol.OriginalDefinition.SpecialType = SpecialType.System_Nullable_T Then 96Case SpecialType.System_Object 98Case SpecialType.System_Boolean 100Case SpecialType.System_Char 102Case SpecialType.System_SByte 104Case SpecialType.System_Byte 106Case SpecialType.System_Int16 108Case SpecialType.System_UInt16 110Case SpecialType.System_Int32 112Case SpecialType.System_Int64 114Case SpecialType.System_UInt32 116Case SpecialType.System_UInt64 118Case SpecialType.System_Decimal 120Case SpecialType.System_Single 122Case SpecialType.System_Double 124Case SpecialType.System_String 126Case SpecialType.System_DateTime
VisualBasicTypeInferenceService.TypeInferrer.vb (30)
235Return CreateResult(Compilation.GetSpecialType(SpecialType.System_Int32)) 282Return CreateResult(Compilation.GetSpecialType(SpecialType.System_Int32)) 412Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 452Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 486Return types.Select(Function(t) New TypeInferenceInfo(If(t.InferredType.SpecialType = SpecialType.System_Void, task, taskOfT.Construct(t.InferredType)))) 505New TypeInferenceInfo(Me.Compilation.GetSpecialType(SpecialType.System_Nullable_T).Construct(t.InferredType)), 511If t.InferredType.OriginalDefinition.SpecialType = SpecialType.System_Nullable_T Then 534Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 544If otherSideTypes.Any(Function(t) t.InferredType.SpecialType <> SpecialType.System_Object AndAlso Not t.InferredType.IsErrorType()) Then 568Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 574Return CreateResult(SpecialType.System_Boolean) 594Return CreateResult(SpecialType.System_Boolean) 598Return CreateResult(SpecialType.System_Boolean) 605Return CreateResult(SpecialType.System_IDisposable) 648Return CreateResult(SpecialType.System_Void) 660Dim type = Me.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 664Dim type = Me.Compilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 665Return CreateResult(type.Construct(Compilation.GetSpecialType(SpecialType.System_Object))) 694Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 698Return CreateResult(SpecialType.System_Boolean) 773If memberType.OriginalDefinition.SpecialType = SpecialType.System_Collections_Generic_IEnumerable_T OrElse 774memberType.OriginalDefinition.SpecialType = SpecialType.System_Collections_Generic_IEnumerator_T Then 806Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 815Return CreateResult(SpecialType.System_Boolean) 823Return CreateResult(SpecialType.System_Boolean) 841Return CreateResult(Me.Compilation.GetSpecialType(SpecialType.System_Int32)) 848Return CreateResult(SpecialType.System_Boolean) 857Return CreateResult(SpecialType.System_IDisposable) 869Return CreateResult(SpecialType.System_Boolean) 873Return CreateResult(SpecialType.System_Boolean)
Microsoft.CodeAnalysis.VisualBasic.Workspaces.UnitTests (30)
CodeGeneration\SyntaxGeneratorTests.vb (30)
24Me._ienumerableInt = _emptyCompilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T).Construct(_emptyCompilation.GetSpecialType(SpecialType.System_Int32)) 254Dim intType = _emptyCompilation.GetSpecialType(SpecialType.System_Int32) 266VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Byte), "Byte") 267VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_SByte), "SByte") 269VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Int16), "Short") 270VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_UInt16), "UShort") 272VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Int32), "Integer") 273VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_UInt32), "UInteger") 275VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Int64), "Long") 276VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_UInt64), "ULong") 278VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Single), "Single") 279VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Double), "Double") 281VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Char), "Char") 282VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_String), "String") 284VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Object), "Object") 285VerifySyntax(Of TypeSyntax)(Generator.TypeExpression(SpecialType.System_Decimal), "Decimal") 290Dim genericType = _emptyCompilation.GetSpecialType(SpecialType.System_Collections_Generic_IEnumerable_T) 293Dim arrayType = _emptyCompilation.CreateArrayTypeSymbol(_emptyCompilation.GetSpecialType(SpecialType.System_Int32)) 368Dim intType = _emptyCompilation.GetSpecialType(SpecialType.System_Int32) 828Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32)), 832Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32), initializer:=Generator.LiteralExpression(0)), 836Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32), accessibility:=Accessibility.Public), 840Generator.FieldDeclaration("fld", Generator.TypeExpression(SpecialType.System_Int32), modifiers:=DeclarationModifiers.Static Or DeclarationModifiers.ReadOnly Or DeclarationModifiers.WithEvents), 938_emptyCompilation.GetSpecialType(SpecialType.System_Int32), 939_emptyCompilation.GetSpecialType(SpecialType.System_String) 943Dim returnType = Generator.TypeExpression(SpecialType.System_Boolean) 1074Dim doubleType = _emptyCompilation.GetSpecialType(SpecialType.System_Decimal) 1076Function(m) m.Name = WellKnownMemberNames.ImplicitConversionName AndAlso m.Parameters(0).Type.Equals(_emptyCompilation.GetSpecialType(SpecialType.System_Byte))) 1336Dim params = {Generator.ParameterDeclaration("sender", Generator.TypeExpression(SpecialType.System_Object)), Generator.ParameterDeclaration("args", Generator.IdentifierName("EventArgs"))}
Microsoft.CodeAnalysis.Workspaces (369)
AbstractFlagsEnumGenerator.cs (5)
15protected abstract SyntaxNode CreateExplicitlyCastedLiteralValue(SyntaxGenerator generator, INamedTypeSymbol enumType, SpecialType underlyingSpecialType, object constantValue); 81var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType; 141SyntaxGenerator generator, IFieldSymbol field, INamedTypeSymbol enumType, SpecialType underlyingSpecialType) 175var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType; 191var underlyingSpecialType = enumType.EnumUnderlyingType.SpecialType;
AbstractSpeculationAnalyzer.cs (6)
707&& symbol.ContainingType.SpecialType == SpecialType.System_Object 983if (newReceiverType.SpecialType != SpecialType.None) 990return newSymbolContainingType.SpecialType is SpecialType.System_Array or 991SpecialType.System_Delegate or 992SpecialType.System_Enum or 993SpecialType.System_String;
AbstractTypeInferenceService.AbstractTypeInferrer.cs (2)
83protected IEnumerable<TypeInferenceInfo> CreateResult(SpecialType type, NullableAnnotation nullableAnnotation = NullableAnnotation.None) 127symbol.ContainingType?.SpecialType == SpecialType.System_Enum;
AbstractTypeInferenceService.cs (1)
48? ImmutableArray.Create<ITypeSymbol>(semanticModel.Compilation.GetSpecialType(SpecialType.System_Boolean))
CodeGenerationAbstractNamedTypeSymbol.cs (1)
34SpecialType specialType,
CodeGenerationArrayTypeSymbol.cs (1)
13: base(null, null, default, Accessibility.NotApplicable, default, string.Empty, SpecialType.None, nullableAnnotation)
CodeGenerationHelpers.cs (12)
84public static bool IsSpecialType([NotNullWhen(true)] ITypeSymbol? type, SpecialType specialType) 137SpecialType.System_SByte => value is sbyte, 138SpecialType.System_Byte => value is byte, 139SpecialType.System_Int16 => value is short, 140SpecialType.System_UInt16 => value is ushort, 141SpecialType.System_Int32 => value is int, 142SpecialType.System_UInt32 => value is uint, 143SpecialType.System_Int64 => value is long, 144SpecialType.System_UInt64 => value is ulong, 145SpecialType.System_Decimal => value is decimal, 146SpecialType.System_Single => value is float, 147SpecialType.System_Double => value is double,
CodeGenerationMethodSymbol.cs (1)
80=> this.ReturnType == null || this.ReturnType.SpecialType == SpecialType.System_Void;
CodeGenerationNamedTypeSymbol.cs (1)
39SpecialType specialType,
CodeGenerationPointerTypeSymbol.cs (1)
14: base(null, null, default, Accessibility.NotApplicable, default, string.Empty, SpecialType.None, NullableAnnotation.None)
CodeGenerationSymbolFactory.cs (5)
424SpecialType specialType = SpecialType.None, 443SpecialType specialType = SpecialType.None, 495specialType: SpecialType.None,
CodeGenerationTypeParameterSymbol.cs (1)
35: base(containingType?.ContainingAssembly, containingType, attributes, Accessibility.NotApplicable, default, name, SpecialType.None, nullableAnnotation)
CodeGenerationTypeSymbol.cs (2)
19public SpecialType SpecialType { get; protected set; } 28SpecialType specialType,
Editing\SyntaxGenerator.cs (2)
797underlyingType: type.EnumUnderlyingType is null or { SpecialType: SpecialType.System_Int32 } 1940public abstract SyntaxNode TypeExpression(SpecialType specialType);
EnumUtilties.cs (9)
19internal static ulong ConvertEnumUnderlyingTypeToUInt64(object value, SpecialType specialType) 28case SpecialType.System_SByte: 30case SpecialType.System_Int16: 32case SpecialType.System_Int32: 34case SpecialType.System_Int64: 36case SpecialType.System_Byte: 38case SpecialType.System_UInt16: 40case SpecialType.System_UInt32: 42case SpecialType.System_UInt64:
FindSymbols\FindReferences\DependentProjectsFinder.cs (1)
243typeNameConstant.Type.SpecialType != SpecialType.System_String ||
FindSymbols\FindReferences\DependentTypeFinder.cs (5)
215case SpecialType.System_Object: 219predicateOpt: n => n.BaseType?.SpecialType == SpecialType.System_Object).ConfigureAwait(false); 221case SpecialType.System_ValueType: 225case SpecialType.System_Enum: 229case SpecialType.System_MulticastDelegate:
IMethodSymbolExtensions.cs (2)
44method.Parameters is [{ Type.SpecialType: SpecialType.System_Object }, var secondParam] && 105methodSymbol.ReturnType.SpecialType == SpecialType.System_Int32 ||
IntegerUtilities.cs (7)
60public static long Convert(long v, SpecialType type) 63SpecialType.System_SByte => unchecked((sbyte)v), 64SpecialType.System_Byte => unchecked((byte)v), 65SpecialType.System_Int16 => unchecked((short)v), 66SpecialType.System_UInt16 => unchecked((ushort)v), 67SpecialType.System_Int32 => unchecked((int)v), 68SpecialType.System_UInt32 => unchecked((uint)v),
ISemanticFactsExtensions.cs (2)
119=> type?.SpecialType is SpecialType.System_Single or SpecialType.System_Double;
J\s\src\Compilers\Core\Portable\SpecialTypeExtensions.cs\SpecialTypeExtensions.cs (142)
15public static bool IsClrInteger(this SpecialType specialType) 19case SpecialType.System_Boolean: 20case SpecialType.System_Char: 21case SpecialType.System_Byte: 22case SpecialType.System_SByte: 23case SpecialType.System_Int16: 24case SpecialType.System_UInt16: 25case SpecialType.System_Int32: 26case SpecialType.System_UInt32: 27case SpecialType.System_Int64: 28case SpecialType.System_UInt64: 29case SpecialType.System_IntPtr: 30case SpecialType.System_UIntPtr: 40public static bool IsBlittable(this SpecialType specialType) 44case SpecialType.System_Boolean: 45case SpecialType.System_Char: 46case SpecialType.System_Byte: 47case SpecialType.System_SByte: 48case SpecialType.System_Int16: 49case SpecialType.System_UInt16: 50case SpecialType.System_Int32: 51case SpecialType.System_UInt32: 52case SpecialType.System_Int64: 53case SpecialType.System_UInt64: 54case SpecialType.System_Single: 55case SpecialType.System_Double: 62public static bool IsValueType(this SpecialType specialType) 66case SpecialType.System_Void: 67case SpecialType.System_Boolean: 68case SpecialType.System_Char: 69case SpecialType.System_Byte: 70case SpecialType.System_SByte: 71case SpecialType.System_Int16: 72case SpecialType.System_UInt16: 73case SpecialType.System_Int32: 74case SpecialType.System_UInt32: 75case SpecialType.System_Int64: 76case SpecialType.System_UInt64: 77case SpecialType.System_Single: 78case SpecialType.System_Double: 79case SpecialType.System_Decimal: 80case SpecialType.System_IntPtr: 81case SpecialType.System_UIntPtr: 82case SpecialType.System_Nullable_T: 83case SpecialType.System_DateTime: 84case SpecialType.System_TypedReference: 85case SpecialType.System_ArgIterator: 86case SpecialType.System_RuntimeArgumentHandle: 87case SpecialType.System_RuntimeFieldHandle: 88case SpecialType.System_RuntimeMethodHandle: 89case SpecialType.System_RuntimeTypeHandle: 96public static int SizeInBytes(this SpecialType specialType) 100case SpecialType.System_SByte: 102case SpecialType.System_Byte: 104case SpecialType.System_Int16: 106case SpecialType.System_UInt16: 108case SpecialType.System_Int32: 110case SpecialType.System_UInt32: 112case SpecialType.System_Int64: 114case SpecialType.System_UInt64: 116case SpecialType.System_Char: 118case SpecialType.System_Single: 120case SpecialType.System_Double: 122case SpecialType.System_Boolean: 125case SpecialType.System_Decimal: 139public static bool IsPrimitiveRecursiveStruct(this SpecialType specialType) 143case SpecialType.System_Boolean: 144case SpecialType.System_Byte: 145case SpecialType.System_Char: 146case SpecialType.System_Double: 147case SpecialType.System_Int16: 148case SpecialType.System_Int32: 149case SpecialType.System_Int64: 150case SpecialType.System_UInt16: 151case SpecialType.System_UInt32: 152case SpecialType.System_UInt64: 153case SpecialType.System_IntPtr: 154case SpecialType.System_UIntPtr: 155case SpecialType.System_SByte: 156case SpecialType.System_Single: 163public static bool IsValidEnumUnderlyingType(this SpecialType specialType) 167case SpecialType.System_Byte: 168case SpecialType.System_SByte: 169case SpecialType.System_Int16: 170case SpecialType.System_UInt16: 171case SpecialType.System_Int32: 172case SpecialType.System_UInt32: 173case SpecialType.System_Int64: 174case SpecialType.System_UInt64: 181public static bool IsNumericType(this SpecialType specialType) 185case SpecialType.System_Byte: 186case SpecialType.System_SByte: 187case SpecialType.System_Int16: 188case SpecialType.System_UInt16: 189case SpecialType.System_Int32: 190case SpecialType.System_UInt32: 191case SpecialType.System_Int64: 192case SpecialType.System_UInt64: 193case SpecialType.System_Single: 194case SpecialType.System_Double: 195case SpecialType.System_Decimal: 205public static bool IsIntegralType(this SpecialType specialType) 209case SpecialType.System_Byte: 210case SpecialType.System_SByte: 211case SpecialType.System_Int16: 212case SpecialType.System_UInt16: 213case SpecialType.System_Int32: 214case SpecialType.System_UInt32: 215case SpecialType.System_Int64: 216case SpecialType.System_UInt64: 223public static bool IsUnsignedIntegralType(this SpecialType specialType) 227case SpecialType.System_Byte: 228case SpecialType.System_UInt16: 229case SpecialType.System_UInt32: 230case SpecialType.System_UInt64: 237public static bool IsSignedIntegralType(this SpecialType specialType) 241case SpecialType.System_SByte: 242case SpecialType.System_Int16: 243case SpecialType.System_Int32: 244case SpecialType.System_Int64: 256public static int VBForToShiftBits(this SpecialType specialType) 260case SpecialType.System_SByte: 262case SpecialType.System_Int16: 264case SpecialType.System_Int32: 266case SpecialType.System_Int64: 273public static SpecialType FromRuntimeTypeOfLiteralValue(object value) 282return SpecialType.System_Int32; 287return SpecialType.System_String; 292return SpecialType.System_Boolean; 297return SpecialType.System_Char; 302return SpecialType.System_Int64; 307return SpecialType.System_Double; 312return SpecialType.System_UInt32; 317return SpecialType.System_UInt64; 322return SpecialType.System_Single; 327return SpecialType.System_Decimal; 332return SpecialType.System_Int16; 337return SpecialType.System_UInt16; 342return SpecialType.System_DateTime; 347return SpecialType.System_Byte; 352return SpecialType.System_SByte; 355return SpecialType.None;
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\INamedTypeSymbolExtensions.cs\INamedTypeSymbolExtensions.cs (1)
615ContainingType.SpecialType: SpecialType.System_Object,
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ISymbolExtensions.cs\ISymbolExtensions.cs (4)
448.Select(p => (p.Type ?? compilation.GetSpecialType(SpecialType.System_Object)).WithNullableAnnotation(p.NullableAnnotation)); 453types = types.Concat((method.ReturnType ?? compilation.GetSpecialType(SpecialType.System_Object)).WithNullableAnnotation(method.ReturnNullableAnnotation)); 619if (!returnType.GetMembers().OfType<IPropertySymbol>().Any(p => p.Name == WellKnownMemberNames.IsCompleted && p.Type.SpecialType == SpecialType.System_Boolean && p.GetMethod != null)) 669ReturnType.SpecialType: SpecialType.System_Boolean,
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ITypeSymbolExtensions.cs\ITypeSymbolExtensions.cs (55)
57=> symbol?.SpecialType == SpecialType.System_Void; 60=> symbol?.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T; 270case SpecialType.System_Array or SpecialType.System_ValueType: 273case SpecialType.System_Delegate: 274case SpecialType.System_MulticastDelegate: 275case SpecialType.System_Enum: 288case SpecialType.System_Byte: 289case SpecialType.System_SByte: 290case SpecialType.System_Int16: 291case SpecialType.System_UInt16: 292case SpecialType.System_Int32: 293case SpecialType.System_UInt32: 294case SpecialType.System_Int64: 295case SpecialType.System_UInt64: 296case SpecialType.System_Single: 297case SpecialType.System_Double: 298case SpecialType.System_Decimal: 299case SpecialType.System_IntPtr when type.IsNativeIntegerType: 300case SpecialType.System_UIntPtr when type.IsNativeIntegerType: 376case SpecialType.System_Object: 377case SpecialType.System_Void: 378case SpecialType.System_Boolean: 379case SpecialType.System_SByte: 380case SpecialType.System_Byte: 381case SpecialType.System_Decimal: 382case SpecialType.System_Single: 383case SpecialType.System_Double: 384case SpecialType.System_Int16: 385case SpecialType.System_Int32: 386case SpecialType.System_Int64: 387case SpecialType.System_Char: 388case SpecialType.System_String: 389case SpecialType.System_UInt16: 390case SpecialType.System_UInt32: 391case SpecialType.System_UInt64: 392case SpecialType.System_IntPtr when symbol.IsNativeIntegerType: 393case SpecialType.System_UIntPtr when symbol.IsNativeIntegerType: 404typeSymbol.AllInterfaces.Any(static i => i.SpecialType == SpecialType.System_Collections_IEnumerable) && 646case SpecialType.System_Boolean: 647case SpecialType.System_Char: 648case SpecialType.System_SByte: 649case SpecialType.System_Byte: 650case SpecialType.System_Int16: 651case SpecialType.System_UInt16: 652case SpecialType.System_Int32: 653case SpecialType.System_UInt32: 654case SpecialType.System_Int64: 655case SpecialType.System_UInt64: 656case SpecialType.System_Decimal: 657case SpecialType.System_Single: 658case SpecialType.System_Double: 661case SpecialType.System_IntPtr: 662case SpecialType.System_UIntPtr: 665case SpecialType.System_DateTime:
J\s\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\SpecialTypeExtensions.cs\SpecialTypeExtensions.cs (20)
11public static PredefinedType ToPredefinedType(this SpecialType specialType) 14SpecialType.System_Object => PredefinedType.Object, 15SpecialType.System_Void => PredefinedType.Void, 16SpecialType.System_Boolean => PredefinedType.Boolean, 17SpecialType.System_Char => PredefinedType.Char, 18SpecialType.System_SByte => PredefinedType.SByte, 19SpecialType.System_Byte => PredefinedType.Byte, 20SpecialType.System_Int16 => PredefinedType.Int16, 21SpecialType.System_UInt16 => PredefinedType.UInt16, 22SpecialType.System_Int32 => PredefinedType.Int32, 23SpecialType.System_UInt32 => PredefinedType.UInt32, 24SpecialType.System_Int64 => PredefinedType.Int64, 25SpecialType.System_UInt64 => PredefinedType.UInt64, 26SpecialType.System_Decimal => PredefinedType.Decimal, 27SpecialType.System_Single => PredefinedType.Single, 28SpecialType.System_Double => PredefinedType.Double, 29SpecialType.System_String => PredefinedType.String, 30SpecialType.System_DateTime => PredefinedType.DateTime, 31SpecialType.System_IntPtr => PredefinedType.IntPtr, 32SpecialType.System_UIntPtr => PredefinedType.UIntPtr,
PredefinedTypeExtensions.cs (21)
11public static SpecialType ToSpecialType(this PredefinedType predefinedType) 14PredefinedType.Object => SpecialType.System_Object, 15PredefinedType.Void => SpecialType.System_Void, 16PredefinedType.Boolean => SpecialType.System_Boolean, 17PredefinedType.Char => SpecialType.System_Char, 18PredefinedType.SByte => SpecialType.System_SByte, 19PredefinedType.Byte => SpecialType.System_Byte, 20PredefinedType.Int16 => SpecialType.System_Int16, 21PredefinedType.UInt16 => SpecialType.System_UInt16, 22PredefinedType.Int32 => SpecialType.System_Int32, 23PredefinedType.UInt32 => SpecialType.System_UInt32, 24PredefinedType.Int64 => SpecialType.System_Int64, 25PredefinedType.UInt64 => SpecialType.System_UInt64, 26PredefinedType.Decimal => SpecialType.System_Decimal, 27PredefinedType.Single => SpecialType.System_Single, 28PredefinedType.Double => SpecialType.System_Double, 29PredefinedType.String => SpecialType.System_String, 30PredefinedType.DateTime => SpecialType.System_DateTime, 31PredefinedType.IntPtr => SpecialType.System_IntPtr, 32PredefinedType.UIntPtr => SpecialType.System_UIntPtr, 33_ => SpecialType.None,
Recommendations\AbstractRecommendationService.cs (1)
79if (namedType.SpecialType == SpecialType.System_Void)
SemanticModelExtensions.cs (2)
173type.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T || 190if (type.SpecialType == SpecialType.System_String)
Shared\Extensions\SyntaxGeneratorExtensions_CreateEqualsMethod.cs (19)
47returnType: compilation.GetSpecialType(SpecialType.System_Boolean), 52parameters: ImmutableArray.Create(CodeGenerationSymbolFactory.CreateParameterSymbol(compilation.GetSpecialType(SpecialType.System_Object).WithNullableAnnotation(NullableAnnotation.Annotated), ObjName)), 409case SpecialType.System_Boolean: 410case SpecialType.System_Char: 411case SpecialType.System_SByte: 412case SpecialType.System_Byte: 413case SpecialType.System_Int16: 414case SpecialType.System_UInt16: 415case SpecialType.System_Int32: 416case SpecialType.System_UInt32: 417case SpecialType.System_Int64: 418case SpecialType.System_UInt64: 419case SpecialType.System_Decimal: 420case SpecialType.System_Single: 421case SpecialType.System_Double: 422case SpecialType.System_String: 423case SpecialType.System_DateTime: 441method.ReturnType.SpecialType == SpecialType.System_Boolean && 442method.Parameters[0].Type.SpecialType == SpecialType.System_Object &&
Shared\Utilities\EditorBrowsableHelpers.cs (1)
110var shortType = compilation.GetSpecialType(SpecialType.System_Int16);
Shared\Utilities\EnumValueUtilities.cs (9)
57private static object CreateOne(SpecialType specialType) 60SpecialType.System_SByte => (sbyte)1, 61SpecialType.System_Byte => (byte)1, 62SpecialType.System_Int16 => (short)1, 63SpecialType.System_UInt16 => (ushort)1, 64SpecialType.System_Int32 => 1, 65SpecialType.System_UInt32 => (uint)1, 66SpecialType.System_Int64 => (long)1, 67SpecialType.System_UInt64 => (ulong)1,
SimplificationHelpers.cs (2)
78var specialType = SpecialTypeAnnotation.GetSpecialType(annotation2); 79if (specialType != SpecialType.None)
SpecialTypeAnnotation.cs (8)
14private static readonly ConcurrentDictionary<SpecialType, string> s_fromSpecialTypes = new(); 15private static readonly ConcurrentDictionary<string, SpecialType> s_toSpecialTypes = new(); 17public static SyntaxAnnotation Create(SpecialType specialType) 20public static SpecialType GetSpecialType(SyntaxAnnotation annotation) 23private static string CreateFromSpecialTypes(SpecialType arg) 26private static SpecialType CreateToSpecialTypes(string arg) 27=> (SpecialType)Enum.Parse(typeof(SpecialType), arg);
SymbolEquivalenceComparer.cs (1)
180=> symbol.IsKind(SymbolKind.NamedType, out ITypeSymbol? typeSymbol) && typeSymbol.SpecialType == SpecialType.System_Object;
SyntaxGeneratorExtensions.cs (1)
77_ => compilation.GetSpecialType(SpecialType.System_Object),
SyntaxGeneratorExtensions_CreateGetHashCodeMethod.cs (4)
136? factory.SimpleLocalDeclarationStatement(generatorInternal, compilation.GetSpecialType(SpecialType.System_Int32), HashCodeName, CreateLiteralExpression(factory, initHash)) 137: factory.LocalDeclarationStatement(compilation.GetSpecialType(SpecialType.System_Int64), HashCodeName, CreateLiteralExpression(factory, initHash))); 166compilation.GetSpecialType(SpecialType.System_Int32), 210method.ReturnType.SpecialType == SpecialType.System_Int32 &&
SyntaxGeneratorExtensions_Negate.cs (11)
61SpecialType? patternValueType, 279SpecialType? patternValueType) 281if (patternValueType is SpecialType specialType && specialType.IsNumericType()) 421if (containingType?.SpecialType == SpecialType.System_Array || 422containingType?.SpecialType == SpecialType.System_String) 432case SpecialType.System_Byte: 433case SpecialType.System_UInt16: 434case SpecialType.System_UInt32: 435case SpecialType.System_UInt64: 471SpecialType? patternValueType) 478if (patternValueType == SpecialType.System_Boolean)
Microsoft.CodeAnalysis.Workspaces.UnitTests (18)
Editing\SyntaxEditorTests.cs (5)
56editor.ReplaceNode(fieldX, editor.Generator.FieldDeclaration("Y", editor.Generator.TypeExpression(SpecialType.System_String), Accessibility.Public)); 107editor.InsertAfter(fieldX, editor.Generator.FieldDeclaration("Y", editor.Generator.TypeExpression(SpecialType.System_String), Accessibility.Public)); 134editor.InsertBefore(fieldX, editor.Generator.FieldDeclaration("Y", editor.Generator.TypeExpression(SpecialType.System_String), Accessibility.Public)); 182editor.InsertAfter(fieldX, editor.Generator.FieldDeclaration("Y", editor.Generator.TypeExpression(SpecialType.System_String), Accessibility.Public)); 183editor.InsertBefore(fieldX, editor.Generator.FieldDeclaration("Z", editor.Generator.TypeExpression(SpecialType.System_Object), Accessibility.Public));
SymbolKeyTests.cs (11)
652var constructed = method.Construct(compilation.GetSpecialType(SpecialType.System_Int32), method.TypeParameters[1]); 670var constructed = type.Construct(compilation.GetSpecialType(SpecialType.System_Int32), type.TypeParameters[1]); 690var constructed = outer.Construct(compilation.GetSpecialType(SpecialType.System_String)); 720var a_string = a.Construct(compilation.GetSpecialType(SpecialType.System_String)); 727var a_string_b_int = a_string_b.Construct(compilation.GetSpecialType(SpecialType.System_Int32)); 732var a_string_b_int_m_datetime = ((IMethodSymbol)a_string_b_int_m).Construct(compilation.GetSpecialType(SpecialType.System_DateTime)); 735var a_b_int = a_b.Construct(compilation.GetSpecialType(SpecialType.System_Int32)); 737var a_b_int_m_datetime = ((IMethodSymbol)a_b_int_m).Construct(compilation.GetSpecialType(SpecialType.System_DateTime)); 742var a_b_m_datetime = ((IMethodSymbol)a_b_m).Construct(compilation.GetSpecialType(SpecialType.System_DateTime)); 1242var symbolKey1 = SymbolKey.Create(compilation1.GetSpecialType(SpecialType.System_Int32)); 1243var symbolKey2 = SymbolKey.Create(compilation2.GetSpecialType(SpecialType.System_Int32));
SyntaxNodeTests.cs (1)
103var cgenField = gen.FieldDeclaration("X", gen.TypeExpression(SpecialType.System_Int32), Accessibility.Private);
UtilityTest\DocumentationCommentIdTests.cs (1)
340var intType = compilation.GetSpecialType(SpecialType.System_Int32);
Microsoft.VisualStudio.LanguageServices (9)
Library\ObjectBrowser\AbstractDescriptionBuilder.cs (1)
94typeSymbol.SpecialType == SpecialType.System_Void)
Library\ObjectBrowser\AbstractListItemFactory.cs (2)
208if (namedTypeSymbol.SpecialType == SpecialType.System_Object) 276typeSymbol.SpecialType != SpecialType.System_Object)
Library\ObjectBrowser\ObjectList.cs (1)
439if (typeSymbol.SpecialType == SpecialType.System_Object)
Library\VsNavInfo\NavInfoFactory.cs (1)
78if (typeSymbol.SpecialType == SpecialType.System_Nullable_T)
ProjectSystem\AbstractEntryPointFinder.cs (3)
51if (!symbol.ReturnsVoid && symbol.ReturnType.SpecialType != SpecialType.System_Int32) 63var specialType = elementType.SpecialType; 65if (specialType == SpecialType.System_String)
Venus\ContainedLanguageCodeSupport.cs (1)
195returnType: targetDocument.Project.GetCompilationAsync(cancellationToken).WaitAndGetResult_Venus(cancellationToken).GetSpecialType(SpecialType.System_Void),
Microsoft.VisualStudio.LanguageServices.CSharp (27)
CodeModel\CSharpCodeModelService.cs (18)
658var specialType = GetSpecialType((EnvDTE.vsCMTypeRef)type); 716case SpecialType.System_Void: 718case SpecialType.System_String: 720case SpecialType.System_Object: 722case SpecialType.System_Char: 724case SpecialType.System_Byte: 726case SpecialType.System_Boolean: 728case SpecialType.System_Int16: 730case SpecialType.System_Int32: 732case SpecialType.System_Int64: 734case SpecialType.System_Single: 736case SpecialType.System_Double: 738case SpecialType.System_Decimal: 740case SpecialType.System_UInt16: 742case SpecialType.System_UInt32: 744case SpecialType.System_UInt64: 746case SpecialType.System_SByte: 979var specialType = predefinedType.ToSpecialType();
CodeModel\MethodXml\MethodXmlBuilder.cs (2)
303GenerateType(SpecialType.System_Char); 308GenerateNumber((ushort)ch, SpecialType.System_UInt16);
LanguageService\CSharpHelpContextService.cs (1)
534if (symbol is ITypeSymbol type && type.OriginalDefinition.SpecialType == SpecialType.System_Nullable_T)
ObjectBrowser\DescriptionBuilder.cs (6)
102if (underlyingType.SpecialType != SpecialType.System_Int32) 114if (baseType.SpecialType is not SpecialType.System_Object and 115not SpecialType.System_Delegate and 116not SpecialType.System_MulticastDelegate and 117not SpecialType.System_Enum and 118not SpecialType.System_ValueType)
Microsoft.VisualStudio.LanguageServices.Implementation (19)
CodeModel\AbstractCodeModelObject_CodeGen.cs (1)
261specialType: SpecialType.None,
CodeModel\AbstractCodeModelService.cs (14)
280var obj = project.GetRequiredCompilationAsync(CancellationToken.None).Result.GetSpecialType(SpecialType.System_Object); 786protected SpecialType GetSpecialType(EnvDTE.vsCMTypeRef type) 789EnvDTE.vsCMTypeRef.vsCMTypeRefBool => SpecialType.System_Boolean, 790EnvDTE.vsCMTypeRef.vsCMTypeRefByte => SpecialType.System_Byte, 791EnvDTE.vsCMTypeRef.vsCMTypeRefChar => SpecialType.System_Char, 792EnvDTE.vsCMTypeRef.vsCMTypeRefDecimal => SpecialType.System_Decimal, 793EnvDTE.vsCMTypeRef.vsCMTypeRefDouble => SpecialType.System_Double, 794EnvDTE.vsCMTypeRef.vsCMTypeRefFloat => SpecialType.System_Single, 795EnvDTE.vsCMTypeRef.vsCMTypeRefInt => SpecialType.System_Int32, 796EnvDTE.vsCMTypeRef.vsCMTypeRefLong => SpecialType.System_Int64, 797EnvDTE.vsCMTypeRef.vsCMTypeRefObject => SpecialType.System_Object, 798EnvDTE.vsCMTypeRef.vsCMTypeRefShort => SpecialType.System_Int16, 799EnvDTE.vsCMTypeRef.vsCMTypeRefString => SpecialType.System_String, 800EnvDTE.vsCMTypeRef.vsCMTypeRefVoid => SpecialType.System_Void,
CodeModel\FileCodeModel_CodeGen.cs (1)
316: semanticModel.Compilation.GetSpecialType(SpecialType.System_Void);
CodeModel\InternalElements\CodeDelegate.cs (1)
84this.FileCodeModel.GetCompilation().GetSpecialType(SpecialType.System_Delegate));
CodeModel\MethodXml\AbstractMethodXmlBuilder.cs (2)
408protected void GenerateType(SpecialType specialType) 439protected void GenerateNumber(object value, SpecialType specialType)
Microsoft.VisualStudio.LanguageServices.VisualBasic (21)
CodeModel\MethodXML\MethodXmlBuilder.vb (1)
542GenerateNumber(upperBound, SemanticModel.Compilation.GetSpecialType(SpecialType.System_Int32))
CodeModel\VisualBasicCodeModelService.vb (16)
753If typeSymbol.SpecialType = SpecialType.System_Void Then 766If typeSymbol.SpecialType = SpecialType.System_Object Then 775Case SpecialType.System_Boolean 777Case SpecialType.System_SByte 779Case SpecialType.System_Byte 781Case SpecialType.System_Int16 783Case SpecialType.System_UInt16 785Case SpecialType.System_Int32 787Case SpecialType.System_UInt32 789Case SpecialType.System_Int64 791Case SpecialType.System_UInt64 793Case SpecialType.System_Decimal 795Case SpecialType.System_Single 797Case SpecialType.System_Double 799Case SpecialType.System_Char 801Case SpecialType.System_String
CodeModel\VisualBasicCodeModelService_Prototype.vb (1)
98Not methodSymbol.ReturnType.SpecialType = SpecialType.System_Void Then
Help\VisualBasicHelpContextService.vb (1)
107If type.SpecialType <> SpecialType.None Then
Help\VisualBasicHelpContextService.Visitor.vb (1)
450ElseIf TypeOf symbol Is ITypeSymbol AndAlso DirectCast(symbol, ITypeSymbol).SpecialType <> SpecialType.None Then
ObjectBrowser\DescriptionBuilder.vb (1)
107If underlyingType IsNot Nothing AndAlso underlyingType.SpecialType <> SpecialType.System_Int32 Then
Roslyn.Compilers.VisualBasic.IOperation.UnitTests (1)
IOperation\IOperationTests_ICompoundAssignmentOperation.vb (1)
101Where(Function(sym) sym.ReturnType.SpecialType = SpecialType.System_Int32).