116 references to TypeArguments
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (12)
Attributes\AttributeTests_Tuples.vb (3)
365Dim firstTuple = field6Type.TypeArguments.Single() 760Dim typeArg = constraint.TypeArguments.Single() 865Dim typeArg = interfaceImpl.TypeArguments.Single()
CodeGen\CodeGenTuples.vb (9)
10112Dim first = field2Type.TypeArguments(0) 20500Assert.Equal(1, constraint.TypeArguments.Length) 20501Dim typeArg As TypeSymbol = constraint.TypeArguments(0) 20515Assert.Equal(1, constraint.TypeArguments.Length) 20516typeArg = constraint.TypeArguments(0) 22538Dim tuple = iEnumerable.TypeArguments()(0) 22545Dim tuple = iEnumerable.TypeArguments()(0) 22621Dim tuple = DirectCast(iEnumerable.TypeArguments()(0), NamedTypeSymbol).TypeArguments()(0)
Microsoft.CodeAnalysis.VisualBasic.ExpressionEvaluator.ExpressionCompiler.UnitTests (13)
ExpressionCompilerTestBase.vb (1)
361AssertEx.All(type.TypeArguments, Function(typeArgument) type.IsContainingSymbolOfAllTypeParameters(typeArgument))
ExpressionCompilerTests.vb (2)
2023Assert.Equal(returnType.TypeArguments(0).ContainingSymbol, containingType.ContainingType) 2029Dim typeArg = localType.TypeArguments(0)
LocalsTests.vb (10)
1140Assert.Equal(typeParameterU, returnType.TypeArguments(0)) 1141Assert.Equal(typeParameterV, returnType.TypeArguments(1)) 1143Assert.Equal(typeParameterT, returnType.TypeArguments(0)) 1160Assert.Equal(typeParameterV, returnType.TypeArguments(0)) 1162Assert.Equal(typeParameterU, returnType.TypeArguments(0)) 1223Assert.Equal(typeParameterT, returnType.TypeArguments(0)) 1224Assert.Equal(typeParameterU, returnType.TypeArguments(1)) 1225Assert.Equal(typeParameterV, returnType.TypeArguments(2)) 1226Assert.Equal(method.TypeParameters.Single(), returnType.TypeArguments(3)) 2015Assert.Equal("T", typeVariablesType.TypeArguments.Single().Name)
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (3)
Compilation\SemanticModelAPITests.vb (3)
545Assert.False(DirectCast(oldSymbol, NamedTypeSymbol).TypeArguments.Single.IsErrorType) 557Assert.False(DirectCast(newSymbol, NamedTypeSymbol).TypeArguments.Single.IsErrorType) 560Assert.True(DirectCast(newSymbol, NamedTypeSymbol).TypeArguments.Single.IsErrorType)
Microsoft.CodeAnalysis.VisualBasic.Symbol.UnitTests (87)
SymbolsTests\CompilationCreationTests.vb (6)
1803Dim args1 = retval1.ContainingType.TypeArguments.Concat(retval1.TypeArguments) 1819Dim args3 = retval3.TypeArguments 1912Assert.Equal(0, type3.TypeArguments.Length) 1916Assert.Equal(1, typeC6.TypeArguments.Length) 1917Assert.Same(localC6Params(0), typeC6.TypeArguments(0))
SymbolsTests\CustomModifiersTests.vb (1)
286Dim withoutModifiers = withModifiers.OriginalDefinition.Construct(withModifiers.TypeArguments)
SymbolsTests\InstantiatingGenerics.vb (36)
39typeArguments = type.TypeArguments 42constructedFromTypeArguments = type.ConstructedFrom.TypeArguments 264Assert.Same(g1_C2.TypeParameters(0), g1_C2.TypeArguments(0)) 499Assert.Same(int, c1OfIntInt.TypeArguments(0)) 501Assert.Same(c1OfIntInt_c2.TypeParameters(0), c1OfIntInt_c2.TypeArguments(0)) 504Assert.Same(c1OfIntInt_c2_c3.TypeParameters(0), c1OfIntInt_c2_c3.TypeArguments(0)) 514Assert.Same(c1OfIntInt.TypeArguments(0), c1OfIntInt_c2_c3_F1.ReturnType) 515Assert.Same(c1OfIntInt_c2.TypeArguments(0), c1OfIntInt_c2_c3_F2.ReturnType) 516Assert.Same(c1OfIntInt_c2_c3.TypeArguments(0), c1OfIntInt_c2_c3_F3.ReturnType) 517Assert.Same(c1OfIntInt.TypeArguments(1), c1OfIntInt_c2_c3_F4.ReturnType) 518Assert.Same(c1OfIntInt_c2.TypeArguments(1), c1OfIntInt_c2_c3_F5.ReturnType) 519Assert.Same(c1OfIntInt_c2_c3.TypeArguments(1), c1OfIntInt_c2_c3_F6.ReturnType) 538Assert.Same(int, c1OfIntInt.TypeArguments(0)) 540Assert.NotSame(c1OfIntInt_c2Of.TypeParameters(0), c1OfIntInt_c2Of.TypeArguments(0)) 541Assert.Same(c1OfIntInt_c2Of.TypeParameters(0).OriginalDefinition, c1OfIntInt_c2Of.TypeArguments(0)) 545Assert.NotSame(c1OfIntInt_c2Of_c3Of.TypeParameters(0), c1OfIntInt_c2Of_c3Of.TypeArguments(0)) 546Assert.Same(c1OfIntInt_c2Of_c3Of.TypeParameters(0).OriginalDefinition, c1OfIntInt_c2Of_c3Of.TypeArguments(0)) 557Assert.Same(c1OfIntInt.TypeArguments(0), c1OfIntInt_c2Of_c3Of_F1.ReturnType) 558Assert.Same(c1OfIntInt_c2Of.TypeArguments(0), c1OfIntInt_c2Of_c3Of_F2.ReturnType) 559Assert.Same(c1OfIntInt_c2Of_c3Of.TypeArguments(0), c1OfIntInt_c2Of_c3Of_F3.ReturnType) 560Assert.Same(c1OfIntInt.TypeArguments(1), c1OfIntInt_c2Of_c3Of_F4.ReturnType) 561Assert.Same(c1OfIntInt_c2Of.TypeArguments(1), c1OfIntInt_c2Of_c3Of_F5.ReturnType) 562Assert.Same(c1OfIntInt_c2Of_c3Of.TypeArguments(1), c1OfIntInt_c2Of_c3Of_F6.ReturnType) 574Assert.True(c1OfIntInt_c2Of_c3OfInt.TypeArguments(1).IsDefinition) 578Assert.NotEqual(c1OfIntInt_c2Of_c3.TypeParameters(1), c1OfIntInt_c2Of_c3OfInt.TypeArguments(1)) 579Assert.Same(c1OfIntInt_c2Of_c3.TypeParameters(1).OriginalDefinition, c1OfIntInt_c2Of_c3OfInt.TypeArguments(1)) 643Assert.Same(alphaConstructedC2.TypeArguments(0), c1OfIntInt_c2.TypeParameters(1)) 644Assert.NotSame(alphaConstructedC2.TypeArguments(0), c1OfIntInt_c2_1.TypeParameters(1)) 645Assert.Same(alphaConstructedC2.TypeArguments(1), c1OfIntInt_c2.TypeParameters(0)) 646Assert.NotSame(alphaConstructedC2.TypeArguments(1), c1OfIntInt_c2_1.TypeParameters(0)) 651Assert.Same(alphaConstructedC2.TypeArguments(0), c1OfIntInt_c2.TypeParameters(0)) 652Assert.NotSame(alphaConstructedC2.TypeArguments(0), c1OfIntInt_c2_1.TypeParameters(0)) 653Assert.Same(alphaConstructedC2.TypeArguments(1), c1OfIntInt) 658Assert.Same(alphaConstructedC2.TypeArguments(0), c1OfIntInt) 659Assert.Same(alphaConstructedC2.TypeArguments(1), c1OfIntInt_c2.TypeParameters(1)) 660Assert.NotSame(alphaConstructedC2.TypeArguments(1), c1OfIntInt_c2_1.TypeParameters(1))
SymbolsTests\Metadata\MetadataTypeTests.vb (4)
139Assert.Equal(0, class1.TypeArguments.Length) 194Assert.Equal(2, type1.TypeArguments.Length) 248Assert.Equal(1, type1.TypeArguments.Length) 300Assert.Equal(0, type1.TypeArguments.Length)
SymbolsTests\Metadata\PE\BaseTypeResolution.vb (2)
74Assert.Same(DirectCast(base, NamedTypeSymbol).TypeArguments(0), orderablePartitioner.TypeParameters(0)) 156For Each arg In CorTypes_Derived.BaseType.TypeArguments()
SymbolsTests\Metadata\PE\LoadingGenericTypeParameters.vb (9)
30Assert.Equal(0, objectType.TypeArguments.Length) 39Assert.Equal(1, C1.TypeArguments.Length) 43Assert.Equal(C1_T, C1.TypeArguments(0)) 81Assert.Equal(1, C2.TypeArguments.Length) 91Assert.Equal(0, C3.TypeArguments.Length) 96Assert.Equal(1, C4.TypeArguments.Length) 107Assert.Equal(2, TC2.TypeArguments.Length) 112Assert.Equal(TC2_T1, TC2.TypeArguments(0)) 113Assert.Equal(TC2_T2, TC2.TypeArguments(1))
SymbolsTests\Metadata\PE\MissingTypeReferences.vb (3)
85Assert.Equal(genericBase, constructedFrom.Construct(genericBase.TypeArguments)) 252Dim type2 = DirectCast(DirectCast(genericBase.ContainingSymbol.ContainingSymbol.OriginalDefinition, NamedTypeSymbol).Construct(type1.TypeArguments), SubstitutedErrorType) 290Assert.Same(param2, missing2.TypeArguments(0))
SymbolsTests\Metadata\PE\NoPia.vb (3)
947Assert.NotEqual(SymbolKind.ErrorType, (DirectCast(varI5_Foo.ReturnType, NamedTypeSymbol)).TypeArguments(0).Kind) 953Assert.NotEqual(SymbolKind.ErrorType, (DirectCast(varI7_Foo.ReturnType, NamedTypeSymbol)).TypeArguments(0).Kind) 956Assert.NotEqual(SymbolKind.ErrorType, (DirectCast(varI7_Bar.ReturnType, NamedTypeSymbol)).TypeArguments(0).Kind)
SymbolsTests\Metadata\PE\NoPiaInstantiationOfGenericClassAndStruct.vb (2)
85Dim outer = DirectCast(importedField.Type, NamedTypeSymbol).TypeArguments.Single() 88Dim inner = DirectCast(outer, NamedTypeSymbol).TypeArguments.Single()
SymbolsTests\Metadata\WinMdEventTest.vb (1)
1706Assert.Equal(fieldLikeEvent.Type, DirectCast(type, NamedTypeSymbol).TypeArguments.Single())
SymbolsTests\Retargeting\RetargetingTests.vb (2)
145CheckTypes(sourceType.TypeArguments(0), retargetingType.TypeArguments(0))
SymbolsTests\Source\FieldTests.vb (1)
114Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Char), DirectCast(fieldP.Type, NamedTypeSymbol).TypeArguments(0))
SymbolsTests\Source\MethodTests.vb (1)
648Assert.Same(tpU, DirectCast(m1.ReturnType, NamedTypeSymbol).TypeArguments(0))
SymbolsTests\Source\PropertyTests.vb (4)
4630Assert.Equal(type.TypeArguments(0), prop.Type) 4631Assert.Equal(type.TypeArguments(1), prop.Parameters(0).Type) 4643Assert.Equal(type.TypeArguments(0), prop.Type) 4644Assert.Equal(type.TypeArguments(1), prop.Parameters(0).Type)
SymbolsTests\Source\TypeBindingTests.vb (8)
90Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Int32), namedTypeA.TypeArguments(0)) 341Assert.Equal("System.Environment", typeA.TypeArguments(0).ToTestDisplayString()) 342Assert.Same(classR, typeA.TypeArguments(1)) 348Assert.Same(classR, typeB.TypeArguments(0)) 445Assert.Same(sourceMod.GetCorLibType(SpecialType.System_Int32), containerTypeB.TypeArguments(0)) 518Assert.Equal("System.Environment", typeA.TypeArguments(0).ToTestDisplayString()) 519Assert.Same(classR, typeA.TypeArguments(1)) 525Assert.Same(classR, typeB.TypeArguments(0))
SymbolsTests\Source\TypeTests.vb (3)
610Assert.Equal(1, classA.TypeArguments.Length) 620Assert.Equal(1, igoo.TypeArguments.Length) 631Assert.Equal(2, structS.TypeArguments.Length)
SymbolsTests\SymbolErrorTests.vb (1)
22516Assert.Equal(0, errTypeSym.TypeArguments.Length)
Microsoft.CodeAnalysis.VisualBasic.Test.Utilities (1)
Extensions.vb (1)
248Dim actArgs = namedType.TypeArguments()