98 references to Type
Microsoft.CodeAnalysis.CodeStyle (1)
AbstractRemoveUnusedMembersDiagnosticAnalyzer.cs (1)
590attribute.ConstructorArguments is [{ Kind: TypedConstantKind.Primitive, Type.SpecialType: SpecialType.System_String, Value: string value }])
Microsoft.CodeAnalysis.CSharp (4)
Symbols\TypedConstantExtensions.cs (4)
52SpecialType splType = ((INamedTypeSymbol)constant.Type!).EnumUnderlyingType!.SpecialType; 56string typeName = constant.Type.ToDisplayString(SymbolDisplayFormat.QualifiedNameOnlyFormat); 82var members = constant.Type!.GetMembers(); 161var members = constant.Type!.GetMembers();
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (1)
ExpressionGenerator.cs (1)
31return GenerateExpression(generator, typedConstant.Type, typedConstant.Value, canUseFieldReference: true);
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (1)
CodeGen\CodeGenAsyncIteratorTests.cs (1)
859Assert.Equal("System.Type", argument.Type.ToTestDisplayString());
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (9)
Attributes\AttributeTests.cs (7)
4605Assert.Equal("Bar", ca.Type.Name); 5460Assert.Equal("object[]", args[0].Type.ToDisplayString()); 5464Assert.Equal("int[]", args[1].Type.ToDisplayString()); 5470Assert.Equal("object[]", named["P"].Type.ToDisplayString()); 5474Assert.Equal("int[]", named["F"].Type.ToDisplayString()); 5504Assert.Equal("Type", args[0].Type.Name); 5508Assert.Equal("String", args[1].Type.Name);
Attributes\AttributeTests_Dynamic.cs (1)
551Assert.Equal("System.Boolean", actualTransformFlag.Type.ToTestDisplayString());
Attributes\AttributeTests_Tuples.cs (1)
647Assert.True(constant.Type.SpecialType == SpecialType.System_String);
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (22)
Symbols\Metadata\PE\LoadingAttributes.cs (10)
496var t = field.GetAttributes().First().CommonConstructorArguments.Single().Type; 503t = arg.CommonConstructorArguments.Single().Type; 509t = arg.CommonConstructorArguments.Single().Type; 625Assert.Equal("System.Runtime.InteropServices.ClassInterfaceType", a.CommonConstructorArguments[0].Type.ToDisplayString()); 1004Assert.Equal("sbyte[]", attrSym.CommonConstructorArguments[0].Type.ToDisplayString()); 1069Assert.Equal("char[]", a.CommonConstructorArguments[0].Type.ToDisplayString()); 1074Assert.Equal("string[]", a.CommonConstructorArguments[1].Type.ToDisplayString()); 1079Assert.Equal("ushort[]", na0[1].Type.ToDisplayString()); 1081Assert.Equal("ushort", elem[1].Type.ToDisplayString()); 1094Assert.Equal("ulong[]", a.CommonNamedArguments[0].Value.Type.ToDisplayString());
Symbols\Retargeting\RetargetCustomAttributes.cs (4)
307Assert.Equal("object[]", args[0].Type.ToDisplayString()); 311Assert.Equal("int[]", args[1].Type.ToDisplayString()); 317Assert.Equal("object[]", named["P"].Type.ToDisplayString()); 321Assert.Equal("int[]", named["F"].Type.ToDisplayString());
Symbols\TypedConstantTests.cs (8)
50Assert.Equal<object>(common.Type, lang.Type); 54Assert.Equal(common.Type, common2.Type); 64Assert.Equal<object>(commonArray.Type, langArray.Type); 68Assert.Equal(commonArray.Type, commonArray2.Type);
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
ExpressionGenerator.cs (1)
31return GenerateExpression(generator, typedConstant.Type, typedConstant.Value, canUseFieldReference: true);
Microsoft.CodeAnalysis.Features (4)
AbstractRemoveUnusedMembersDiagnosticAnalyzer.cs (1)
590attribute.ConstructorArguments is [{ Kind: TypedConstantKind.Primitive, Type.SpecialType: SpecialType.System_String, Value: string value }])
DesignerAttribute\DesignerAttributeDiscoveryService.cs (1)
262if (attribute is { ConstructorArguments: [{ Type.SpecialType: SpecialType.System_String, Value: string stringValue }] })
EditAndContinue\AbstractEditAndContinueAnalyzer.cs (2)
6029SymbolEquivalenceComparer.Instance.Equals(x.Type, y.Type) &&
Microsoft.CodeAnalysis.VisualBasic (3)
Symbols\TypedConstant.vb (3)
57Dim typeName As String = constant.Type.ToDisplayString(SymbolDisplayFormat.QualifiedNameOnlyFormat) 78Dim members = constant.Type.GetMembers() 142Dim members = constant.Type.GetMembers()
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (23)
Attributes\AttributeTests.vb (16)
267Assert.Equal("System.Configuration.Assemblies.AssemblyHashAlgorithm", a.CommonConstructorArguments(0).Type.ToDisplayString) 272Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString) 277Assert.Equal("Boolean", a.CommonConstructorArguments(0).Type.ToDisplayString) 282Assert.Equal("System.Reflection.AssemblyNameFlags", a.CommonConstructorArguments(0).Type.ToDisplayString) 287Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString) 292Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString) 297Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString) 302Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString) 1222Assert.Equal(tc.Type.ToDisplayString, "B(Of Integer).E") 1902Assert.Equal("Bar", ca.Type.Name) 4081Assert.Equal("Object()", args(0).Type.ToDisplayString()) 4085Assert.Equal("Integer()", args(1).Type.ToDisplayString()) 4091Assert.Equal("Object()", named("P").Type.ToDisplayString()) 4095Assert.Equal("Integer()", named("F").Type.ToDisplayString()) 4182Assert.Equal("Type", args(0).Type.Name) 4186Assert.Equal("String", args(1).Type.Name)
Attributes\AttributeTests_Tuples.vb (1)
443Assert.True(constant.Type.SpecialType = SpecialType.System_String)
Attributes\AttributeTests_WellKnownAttributes.vb (6)
102Assert.Equal("String", attrSym.CommonConstructorArguments(0).Type.ToDisplayString) 107Assert.Equal("System.Runtime.InteropServices.ComInterfaceType", attrSym.CommonConstructorArguments(0).Type.ToDisplayString()) 119Assert.Equal("Boolean", attrSym.CommonNamedArguments(0).Value.Type.ToDisplayString) 235Assert.Equal("String", attrSym.CommonConstructorArguments(0).Type.ToDisplayString) 3443Assert.Equal("Boolean", attrSym.CommonNamedArguments(0).Value.Type.ToDisplayString) 3452Assert.Equal("Boolean", attrSym.CommonNamedArguments(0).Value.Type.ToDisplayString)
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (1)
Binding\BindingErrorTests.vb (1)
1174Assert.Null(argument.Type)
Microsoft.CodeAnalysis.VisualBasic.Symbol.UnitTests (25)
SymbolsTests\Metadata\PE\LoadingAttributes.vb (13)
559Dim t = field.GetAttributes.First().CommonConstructorArguments.Single().Type 566t = arg.CommonConstructorArguments.Single().Type 572t = arg.CommonConstructorArguments.Single().Type 686Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString) 695Assert.Equal("String", a.CommonConstructorArguments(0).Type.ToDisplayString) 701Assert.Equal("Boolean", a.CommonNamedArguments(0).Value.Type.ToDisplayString) 712Assert.Equal("System.Runtime.InteropServices.ClassInterfaceType", a.CommonConstructorArguments(0).Type.ToDisplayString) 1100Assert.Equal("SByte()", attrSym.CommonConstructorArguments(0).Type.ToDisplayString()) 1162Assert.Equal("Char()", a.CommonConstructorArguments(0).Type.ToDisplayString()) 1166Assert.Equal("String()", a.CommonConstructorArguments(1).Type.ToDisplayString()) 1171Assert.Equal("UShort()", na0(1).Type.ToDisplayString()) 1173Assert.Equal("UShort", elem(1).Type.ToDisplayString()) 1182Assert.Equal("ULong()", a.CommonNamedArguments(0).Value.Type.ToDisplayString)
SymbolsTests\Retargeting\RetargetingCustomAttributes.vb (4)
279Assert.Equal("Object()", args(0).Type.ToDisplayString()) 283Assert.Equal("Integer()", args(1).Type.ToDisplayString()) 289Assert.Equal("Object()", named("P").Type.ToDisplayString()) 293Assert.Equal("Integer()", named("F").Type.ToDisplayString())
SymbolsTests\TypedConstantTests.vb (8)
40Assert.Equal(Of Object)(common.Type, lang.Type) 44Assert.Equal(common.Type, common2.Type) 53Assert.Equal(Of Object)(commonArray.Type, langArray.Type) 57Assert.Equal(commonArray.Type, commonArray2.Type)
Microsoft.CodeAnalysis.VisualBasic.Workspaces (1)
CodeGeneration\ExpressionGenerator.vb (1)
21Return GenerateExpression(generator, typedConstant.Type, typedConstant.Value, canUseFieldReference:=True)
Microsoft.CodeAnalysis.Workspaces (2)
FindSymbols\FindReferences\DependentProjectsFinder.cs (2)
242if (typeNameConstant.Type == null || 243typeNameConstant.Type.SpecialType != SpecialType.System_String ||