17 overrides of TypeParameters
Microsoft.CodeAnalysis.VisualBasic (15)
Lowering\StateMachineRewriter\SynthesizedContainer.vb (1)
118
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\AnonymousTypes\PublicSymbols\AnonymousTypeOrDelegatePublicSymbol.vb (1)
71
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\AnonymousTypes\SynthesizedSymbols\AnonymousTypeOrDelegateTemplateSymbol.vb (1)
128
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\ErrorTypeSymbol.vb (1)
198
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\Metadata\PE\PENamedTypeSymbol.vb (1)
840
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\Retargeting\RetargetingNamedTypeSymbol.vb (1)
87
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\Source\ImplicitNamedTypeSymbol.vb (1)
65
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\Source\SourceNamedTypeSymbol.vb (1)
769
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\Source\SourceNamedTypeSymbol_ComClass.vb (1)
968
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\SubstitutedNamedType.vb (3)
706
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
871
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
967
Public NotOverridable Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\SynthesizedSymbols\SynthesizedEventDelegateSymbol.vb (1)
367
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\Tuples\TupleTypeSymbol.vb (1)
200
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Symbols\UnboundGenericType.vb (1)
109
Public MustOverride Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Microsoft.CodeAnalysis.VisualBasic.ExpressionEvaluator.ExpressionCompiler (1)
Symbols\EENamedTypeSymbol.vb (1)
125
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
Microsoft.CodeAnalysis.VisualBasic.Test.Utilities (1)
MockSymbols.vb (1)
271
Public Overrides ReadOnly Property
TypeParameters
As ImmutableArray(Of TypeParameterSymbol)
341 references to TypeParameters
Microsoft.CodeAnalysis.VisualBasic (51)
Binding\Binder_Conversions.vb (1)
812
Dim typeParameters As ImmutableArray(Of TypeParameterSymbol) = source.
TypeParameters
Binding\Binder_Symbols.vb (2)
127
newTypeArguments(i) = genericType.
TypeParameters
(i).OriginalDefinition
1006
StaticCast(Of TypeSymbol).From(namedType.OriginalDefinition.
TypeParameters
)))
Binding\DocumentationCommentTypeParamBinder.vb (1)
42
Return DirectCast(Me.CommentedSymbol, NamedTypeSymbol).
TypeParameters
Binding\NamedTypeBinder.vb (2)
118
For Each tp In _typeSymbol.
TypeParameters
141
For Each tp In _typeSymbol.
TypeParameters
Compilation\ClsComplianceChecker.vb (1)
184
CheckTypeParameterCompliance(symbol.
TypeParameters
, symbol)
Compilation\SyntaxTreeSemanticModel.vb (1)
1127
Return Me.GetTypeParameterSymbol(typeSymbol.
TypeParameters
, typeParameter)
Emit\EditAndContinue\PEDeltaAssemblyBuilder.vb (2)
176
Dim n = type.
TypeParameters
.Length
212
Debug.Assert(method.Parameters.Length + If(method.IsSub, 0, 1) = type.
TypeParameters
.Length)
Emit\EditAndContinue\VisualBasicSymbolMatcher.vb (1)
487
otherTypeParameters = DirectCast(otherContainer, NamedTypeSymbol).
TypeParameters
Emit\NamedTypeSymbolAdapter.vb (1)
372
Return AdaptedNamedTypeSymbol.
TypeParameters
.Select(Function(t) t.GetCciAdapter())
Lowering\LambdaRewriter\LambdaRewriter.vb (1)
1099
_currentTypeParameters = translatedLambdaContainer.
TypeParameters
Semantics\Conversions.vb (1)
2759
Dim typeParameters As ImmutableArray(Of TypeParameterSymbol) = source.
TypeParameters
Semantics\TypeInference\TypeArgumentInference.vb (2)
1490
Select Case parameterTypeAsNamedType.
TypeParameters
(typeArgumentIndex).Variance
1501
Debug.Assert(VarianceKind.None = parameterTypeAsNamedType.
TypeParameters
(typeArgumentIndex).Variance)
Symbols\ConstraintsHelper.vb (1)
579
Return CheckConstraints(type, substitution, type.OriginalDefinition.
TypeParameters
, type.TypeArgumentsNoUseSiteDiagnostics, diagnosticsBuilder, useSiteDiagnosticsBuilder, template)
Symbols\InstanceTypeSymbol.vb (3)
26
Return StaticCast(Of TypeSymbol).From(Me.
TypeParameters
)
55
Dim substitution = VisualBasic.Symbols.TypeSubstitution.Create(Me, Me.
TypeParameters
, typeArguments, allowAlphaRenamedTypeParametersAsArguments:=True)
231
GetUnificationUseSiteDiagnosticRecursive(Me.
TypeParameters
, owner, checkedTypes))
Symbols\Metadata\PE\MemberRefMetadataDecoder.vb (1)
88
typeArgument = namedType.
TypeParameters
(position - arityOffset)
Symbols\Metadata\PE\TupleTypeDecoder.vb (2)
202
Return If(decodedType.
TypeParameters
.IsEmpty,
231
subst = TypeSubstitution.Create(definition, definition.
TypeParameters
, newTypeArgs, False)
Symbols\NamedTypeSymbol.vb (1)
1160
Return StaticCast(Of ITypeParameterSymbol).From(Me.
TypeParameters
)
Symbols\NamedTypeSymbolExtensions.vb (1)
86
If current.
TypeParameters
.HaveVariance() Then
Symbols\Retargeting\RetargetingNamedTypeSymbol.vb (1)
94
RetargetingTranslator.Retarget(_underlyingType.
TypeParameters
), Nothing)
Symbols\Retargeting\RetargetingSymbolTranslator.vb (2)
483
newParameters.AddRange(genericType.
TypeParameters
)
1019
Return retargetedContainingType.
TypeParameters
(typeParameter.Ordinal)
Symbols\Source\SourceMemberContainerTypeSymbol.vb (9)
313
Dim typeParams =
TypeParameters
384
If container.
TypeParameters
.HaveVariance() Then
607
Return ConstructedType.
TypeParameters
(_typeParameterIndex)
844
If container.
TypeParameters
.HaveVariance() Then
855
If container.
TypeParameters
.HaveVariance() Then
909
Debug.Assert(namedType.
TypeParameters
(0).Variance = VarianceKind.None, "unexpected: a nullable type should have one generic parameter with no variance")
931
Select Case namedType.
TypeParameters
(argumentIndex).Variance
940
argumentRequiredVariance = namedType.
TypeParameters
(argumentIndex).Variance
2935
TypeParameters
.MatchesAnyName(sym.Name) Then
Symbols\SubstitutedNamedType.vb (3)
670
Dim typeParametersDefinitions As ImmutableArray(Of TypeParameterSymbol) = fullInstanceType.
TypeParameters
969
Return ConstructedFrom.
TypeParameters
981
Return _substitution.GetTypeArgumentsCustomModifiersFor(OriginalDefinition.
TypeParameters
(ordinal))
Symbols\SynthesizedSymbols\SynthesizedEventDelegateSymbol.vb (1)
402
If container.
TypeParameters
.HaveVariance() Then
Symbols\Tuples\TupleTypeSymbol.vb (1)
473
Dim subst = TypeSubstitution.Create(definition, definition.
TypeParameters
, typeArgumentsBuilder.ToImmutable(), False)
Symbols\TypeSubstitution.vb (3)
180
result(i) = originalDefinition.
TypeParameters
(i)
599
typeParametersDefinitions = DirectCast(memberDefinition, NamedTypeSymbol).
TypeParameters
817
typeParametersDefinitions = DirectCast(targetGenericDefinition, NamedTypeSymbol).
TypeParameters
Symbols\TypeSymbolExtensions.vb (2)
1163
Return type.
TypeParameters
1182
builder.AddRange(type.
TypeParameters
)
Symbols\UnboundGenericType.vb (3)
427
Return Me.ConstructedFrom.
TypeParameters
471
result = VisualBasic.Symbols.TypeSubstitution.Create(OriginalDefinition, OriginalDefinition.
TypeParameters
, Me.TypeArgumentsNoUseSiteDiagnostics)
555
Dim typeParametersDefinitions As ImmutableArray(Of TypeParameterSymbol) = originalDefinition.
TypeParameters
Utilities\VarianceAmbiguity.vb (1)
70
nestingType1.
TypeParameters
(iTypeParameter).Variance,
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (9)
Attributes\AttributeTests_Tuples.vb (2)
364
Assert.Equal(1, field6Type.
TypeParameters
.Length)
758
Dim typeParam = t.
TypeParameters
.Single()
CodeGen\CodeGenTuples.vb (6)
15084
Assert.True(m1Tuple.
TypeParameters
.IsEmpty)
16308
Assert.True(m1Tuple.
TypeParameters
.IsEmpty)
20495
Assert.Equal(1, c.
TypeParameters
.Length)
20496
Dim param = c.
TypeParameters
(0)
20510
Assert.Equal(1, c2.
TypeParameters
.Length)
20511
param = c2.
TypeParameters
(0)
Emit\EmitMetadata.vb (1)
163
For Each param In t.
TypeParameters
Microsoft.CodeAnalysis.VisualBasic.ExpressionEvaluator.ExpressionCompiler (2)
CompilationContext.vb (2)
1366
Dim desiredTypeParameters = candidateSubstitutedSourceType.OriginalDefinition.
TypeParameters
1425
Dim sourceTypeTypeParameters As ImmutableArray(Of TypeParameterSymbol) = candidateMethodDefinition.ContainingType.
TypeParameters
Microsoft.CodeAnalysis.VisualBasic.ExpressionEvaluator.ExpressionCompiler.UnitTests (4)
ExpressionCompilerTestBase.vb (1)
360
AssertEx.All(type.
TypeParameters
, Function(typeParameter) type.IsContainingSymbolOfAllTypeParameters(typeParameter))
LocalsTests.vb (3)
1134
Dim containingTypeTypeParameters = containingType.
TypeParameters
1285
Assert.Equal(containingType.
TypeParameters
(1), method.ReturnType)
2014
Assert.Equal("T", typeVariablesType.
TypeParameters
.Single().Name)
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (3)
DeclaringSyntaxNodeTests.vb (3)
425
For Each s In c1.
TypeParameters
430
For Each tp In (DirectCast(f.Type, NamedTypeSymbol)).
TypeParameters
442
For Each tp In (DirectCast(f.Type, NamedTypeSymbol)).
TypeParameters
Microsoft.CodeAnalysis.VisualBasic.Symbol.UnitTests (272)
DocumentationComments\DocCommentTests.vb (1)
11652
Assert.Equal([class].
TypeParameters
.Single(), info0.CandidateSymbols.Single())
SymbolsTests\AnonymousTypes\AnonymousTypesEmittedSymbolsTests.vb (7)
75
Assert.Equal(3, type.
TypeParameters
.Length)
347
CheckPropertyAccessorsAndField(m, type, "aab", type.
TypeParameters
(0), False)
351
CheckPropertyAccessorsAndField(m, type, "AAB", type.
TypeParameters
(0), True)
382
Assert.Equal(type.
TypeParameters
(0), constr.Parameters(0).Type)
385
Assert.Equal(type.
TypeParameters
(1), constr.Parameters(1).Type)
388
Assert.Equal(type.
TypeParameters
(2), constr.Parameters(2).Type)
610
Assert.Equal(3, type.
TypeParameters
.Length)
SymbolsTests\CompilationCreationTests.vb (9)
1804
Dim params1 = retval1.ContainingType.
TypeParameters
.Concat(retval1.
TypeParameters
)
1805
Assert.Same(params1(0), type1.
TypeParameters
(0))
1806
Assert.Same(params1(1).OriginalDefinition, type2.
TypeParameters
(0).OriginalDefinition)
1820
Dim params3 = retval3.
TypeParameters
1821
Assert.Same(params3(0), type6.
TypeParameters
(0))
1913
Assert.Equal(0, type3.
TypeParameters
.Length)
1914
Dim localC6Params = typeC6.
TypeParameters
1937
Assert.Same((DirectCast(localC6_T, RetargetingTypeParameterSymbol)).UnderlyingTypeParameter, asm3.GlobalNamespace.GetTypeMembers("C6").Single().
TypeParameters
(0))
SymbolsTests\GenericConstraintTests.vb (14)
3619
CheckConstraints(type.
TypeParameters
(0), TypeParameterConstraintKind.None)
3620
CheckConstraints(type.
TypeParameters
(1), TypeParameterConstraintKind.None, "T")
3621
CheckConstraints(type.
TypeParameters
(2), TypeParameterConstraintKind.None, "A", "B")
3741
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("O1").
TypeParameters
(0), TypeParameterConstraintKind.None)
3742
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("O2").
TypeParameters
(0), TypeParameterConstraintKind.None, "Object")
3743
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("V1").
TypeParameters
(0), TypeParameterConstraintKind.ValueType)
3744
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("V2").
TypeParameters
(0), TypeParameterConstraintKind.ValueType)
3745
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("V3").
TypeParameters
(0), TypeParameterConstraintKind.ValueType)
3746
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("V4").
TypeParameters
(0), TypeParameterConstraintKind.ValueType)
3747
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("V5").
TypeParameters
(0), TypeParameterConstraintKind.None, "ValueType")
3748
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("R1").
TypeParameters
(0), TypeParameterConstraintKind.None, "A")
3749
CheckConstraints([namespace].GetMember(Of NamedTypeSymbol)("R2").
TypeParameters
(0), TypeParameterConstraintKind.ReferenceType, "A")
4393
CheckConstraints(type.
TypeParameters
(0), TypeParameterConstraintKind.None)
4395
CheckConstraints(type.
TypeParameters
(0), TypeParameterConstraintKind.None, "C")
SymbolsTests\InstantiatingGenerics.vb (100)
38
typeParameters = type.
TypeParameters
41
constructedFromTypeParameters = type.ConstructedFrom.
TypeParameters
43
originalDefinitionTypeParameters = type.OriginalDefinition.
TypeParameters
172
Assert.Same(type, type.Construct(type.
TypeParameters
.As(Of TypeSymbol)()))
225
Dim C1_T = C1.
TypeParameters
(0)
230
Dim C2_T = C2.
TypeParameters
(0)
239
Dim C4_T = C4.
TypeParameters
(0)
244
Dim TC2_T1 = TC2.
TypeParameters
(0)
245
Dim TC2_T2 = TC2.
TypeParameters
(1)
251
Dim C108_T = C108.
TypeParameters
(0)
262
Assert.NotEqual(C2.
TypeParameters
(0), g1_C2.
TypeParameters
(0))
263
Assert.Same(C2.
TypeParameters
(0), g1_C2.
TypeParameters
(0).OriginalDefinition)
264
Assert.Same(g1_C2.
TypeParameters
(0), g1_C2.TypeArguments(0))
484
Assert.Same(c3.
TypeParameters
(0), c3OfIntInt.
TypeParameters
(0))
489
substitution = TypeSubstitution.Create(c1, {c1.
TypeParameters
(0), c1.
TypeParameters
(1)}, {int, int})
498
Assert.Same(c1.
TypeParameters
(0), c1OfIntInt.
TypeParameters
(0))
500
Assert.NotSame(c2.
TypeParameters
(0), c1OfIntInt_c2.
TypeParameters
(0))
501
Assert.Same(c1OfIntInt_c2.
TypeParameters
(0), c1OfIntInt_c2.TypeArguments(0))
502
Assert.Same(c1OfIntInt_c2, c1OfIntInt_c2.
TypeParameters
(0).ContainingSymbol)
503
Assert.NotSame(c3.
TypeParameters
(0), c1OfIntInt_c2_c3.
TypeParameters
(0))
504
Assert.Same(c1OfIntInt_c2_c3.
TypeParameters
(0), c1OfIntInt_c2_c3.TypeArguments(0))
505
Assert.Same(c1OfIntInt_c2_c3, c1OfIntInt_c2_c3.
TypeParameters
(0).ContainingSymbol)
521
substitution = TypeSubstitution.Create(c3, {c1.
TypeParameters
(0), c1.
TypeParameters
(1)}, {int, int})
537
Assert.Same(c1.
TypeParameters
(0), c1OfIntInt.
TypeParameters
(0))
539
Assert.NotSame(c2.
TypeParameters
(0), c1OfIntInt_c2Of.
TypeParameters
(0))
540
Assert.NotSame(c1OfIntInt_c2Of.
TypeParameters
(0), c1OfIntInt_c2Of.TypeArguments(0))
541
Assert.Same(c1OfIntInt_c2Of.
TypeParameters
(0).OriginalDefinition, c1OfIntInt_c2Of.TypeArguments(0))
542
Assert.NotSame(c1OfIntInt_c2Of, c1OfIntInt_c2Of.
TypeParameters
(0).ContainingSymbol)
543
Assert.Same(c1OfIntInt_c2Of.ConstructedFrom, c1OfIntInt_c2Of.
TypeParameters
(0).ContainingSymbol)
544
Assert.NotSame(c3.
TypeParameters
(0), c1OfIntInt_c2Of_c3Of.
TypeParameters
(0))
545
Assert.NotSame(c1OfIntInt_c2Of_c3Of.
TypeParameters
(0), c1OfIntInt_c2Of_c3Of.TypeArguments(0))
546
Assert.Same(c1OfIntInt_c2Of_c3Of.
TypeParameters
(0).OriginalDefinition, c1OfIntInt_c2Of_c3Of.TypeArguments(0))
547
Assert.NotSame(c1OfIntInt_c2Of_c3Of, c1OfIntInt_c2Of_c3Of.
TypeParameters
(0).ContainingSymbol)
548
Assert.Same(c1OfIntInt_c2Of_c3Of.ConstructedFrom, c1OfIntInt_c2Of_c3Of.
TypeParameters
(0).ContainingSymbol)
565
{c1.
TypeParameters
(0), c1.
TypeParameters
(1), c2.
TypeParameters
(0), c2.
TypeParameters
(1)},
566
{int, int, c2.
TypeParameters
(0), c2.
TypeParameters
(1)})
571
Dim c1OfIntInt_c2Of_c3OfInt = c1OfIntInt_c2Of_c3.Construct(int, c3.
TypeParameters
(1))
575
Assert.False(c1OfIntInt_c2Of_c3OfInt.
TypeParameters
(1).IsDefinition)
578
Assert.NotEqual(c1OfIntInt_c2Of_c3.
TypeParameters
(1), c1OfIntInt_c2Of_c3OfInt.TypeArguments(1))
579
Assert.Same(c1OfIntInt_c2Of_c3.
TypeParameters
(1).OriginalDefinition, c1OfIntInt_c2Of_c3OfInt.TypeArguments(1))
581
Assert.Same(c3.
TypeParameters
(1), c1OfIntInt_c2Of_c3.
TypeParameters
(1).OriginalDefinition)
582
Assert.Same(c3.
TypeParameters
(1).Name, c1OfIntInt_c2Of_c3.
TypeParameters
(1).Name)
583
Assert.Equal(c3.
TypeParameters
(1).HasConstructorConstraint, c1OfIntInt_c2Of_c3.
TypeParameters
(1).HasConstructorConstraint)
584
Assert.Equal(c3.
TypeParameters
(1).HasReferenceTypeConstraint, c1OfIntInt_c2Of_c3.
TypeParameters
(1).HasReferenceTypeConstraint)
585
Assert.Equal(c3.
TypeParameters
(1).HasValueTypeConstraint, c1OfIntInt_c2Of_c3.
TypeParameters
(1).HasValueTypeConstraint)
586
Assert.Equal(c3.
TypeParameters
(1).Ordinal, c1OfIntInt_c2Of_c3.
TypeParameters
(1).Ordinal)
588
Assert.Throws(Of InvalidOperationException)(Sub() c1OfIntInt_c2_c3.Construct(c3.
TypeParameters
(0), c3.
TypeParameters
(1)))
590
Dim c1OfIntInt_c2Of_c3Constructed = c1OfIntInt_c2Of_c3.Construct(c3.
TypeParameters
(0), c3.
TypeParameters
(1))
601
Assert.Same(c3, c3.Construct(c3.
TypeParameters
(0), c3.
TypeParameters
(1)))
603
substitution = TypeSubstitution.Create(c1, {c1.
TypeParameters
(0), c1.
TypeParameters
(1)}, {int, int})
606
substitution = TypeSubstitution.Create(c5, {c1.
TypeParameters
(0), c1.
TypeParameters
(1)}, {int, int})
610
Assert.Equal(0, c1OfIntInt_C5_1.
TypeParameters
.Length)
637
Assert.Same(c1OfIntInt_c2, c1OfIntInt_c2.Construct(New List(Of TypeSymbol) From {c1OfIntInt_c2.
TypeParameters
(0), c1OfIntInt_c2.
TypeParameters
(1)}))
639
Assert.Same(c1OfIntInt_c2, c1OfIntInt_c2.Construct(c1OfIntInt_c2_1.
TypeParameters
(0), c1OfIntInt_c2_1.
TypeParameters
(1)))
640
Dim alphaConstructedC2 = c1OfIntInt_c2.Construct(c1OfIntInt_c2_1.
TypeParameters
(1), c1OfIntInt_c2_1.
TypeParameters
(0))
643
Assert.Same(alphaConstructedC2.TypeArguments(0), c1OfIntInt_c2.
TypeParameters
(1))
644
Assert.NotSame(alphaConstructedC2.TypeArguments(0), c1OfIntInt_c2_1.
TypeParameters
(1))
645
Assert.Same(alphaConstructedC2.TypeArguments(1), c1OfIntInt_c2.
TypeParameters
(0))
646
Assert.NotSame(alphaConstructedC2.TypeArguments(1), c1OfIntInt_c2_1.
TypeParameters
(0))
648
alphaConstructedC2 = c1OfIntInt_c2.Construct(c1OfIntInt_c2_1.
TypeParameters
(0), c1OfIntInt)
651
Assert.Same(alphaConstructedC2.TypeArguments(0), c1OfIntInt_c2.
TypeParameters
(0))
652
Assert.NotSame(alphaConstructedC2.TypeArguments(0), c1OfIntInt_c2_1.
TypeParameters
(0))
655
alphaConstructedC2 = c1OfIntInt_c2.Construct(c1OfIntInt, c1OfIntInt_c2_1.
TypeParameters
(1))
659
Assert.Same(alphaConstructedC2.TypeArguments(1), c1OfIntInt_c2.
TypeParameters
(1))
660
Assert.NotSame(alphaConstructedC2.TypeArguments(1), c1OfIntInt_c2_1.
TypeParameters
(1))
702
substitution1 = TypeSubstitution.Create(c1, {c1.
TypeParameters
(0), c1.
TypeParameters
(1)}, {int, int})
705
substitution2 = TypeSubstitution.Create(c4, {c3.
TypeParameters
(0), c4.
TypeParameters
(0)}, {bte, chr})
718
Assert.Null(TypeSubstitution.Create(c4, {c1.
TypeParameters
(0)}, {c1.
TypeParameters
(0)}))
SymbolsTests\Metadata\MetadataTypeTests.vb (4)
140
Assert.Equal(0, class1.
TypeParameters
.Length)
195
Assert.Equal(2, type1.
TypeParameters
.Length)
249
Assert.Equal(1, type1.
TypeParameters
.Length)
301
Assert.Equal(0, type1.
TypeParameters
.Length)
SymbolsTests\Metadata\PE\BaseTypeResolution.vb (1)
74
Assert.Same(DirectCast(base, NamedTypeSymbol).TypeArguments(0), orderablePartitioner.
TypeParameters
(0))
SymbolsTests\Metadata\PE\LoadCustomModifiers.vb (2)
143
Dim badTypeParameter = compilation.GetTypeByMetadataName("TestRef`1").
TypeParameters
.Single()
211
Dim badTypeParameter = compilation.GetTypeByMetadataName("D`1").
TypeParameters
.Single()
SymbolsTests\Metadata\PE\LoadingAttributes.vb (3)
1066
Dim tp = igoo.
TypeParameters
(0)
1075
tp = igoo.
TypeParameters
(1)
1193
Dim tp = foo.
TypeParameters
(0)
SymbolsTests\Metadata\PE\LoadingFields.vb (1)
43
Assert.Same(vbFields.
TypeParameters
(0), f1.Type)
SymbolsTests\Metadata\PE\LoadingGenericTypeParameters.vb (20)
29
Assert.Equal(0, objectType.
TypeParameters
.Length)
38
Assert.Equal(1, C1.
TypeParameters
.Length)
41
Dim C1_T = C1.
TypeParameters
(0)
80
Assert.Equal(1, C2.
TypeParameters
.Length)
83
Dim C2_T = C2.
TypeParameters
(0)
90
Assert.Equal(0, C3.
TypeParameters
.Length)
95
Assert.Equal(1, C4.
TypeParameters
.Length)
98
Dim C4_T = C4.
TypeParameters
(0)
106
Assert.Equal(2, TC2.
TypeParameters
.Length)
109
Dim TC2_T1 = TC2.
TypeParameters
(0)
110
Dim TC2_T2 = TC2.
TypeParameters
(1)
124
Dim T = C100.
TypeParameters
(0)
131
T = C101.
TypeParameters
(0)
138
T = C102.
TypeParameters
(0)
146
T = C103.
TypeParameters
(0)
154
T = C104.
TypeParameters
(0)
162
T = C105.
TypeParameters
(0)
169
T = C106.
TypeParameters
(0)
179
T = C201.
TypeParameters
(0)
184
T = C202.
TypeParameters
(0)
SymbolsTests\Metadata\PE\MissingTypeReferences.vb (20)
280
Dim param1 = missing.
TypeParameters
(0)
281
Dim param2 = missing2.
TypeParameters
(0)
293
Assert.Same(missing, missing.Construct(missing.
TypeParameters
.As(Of TypeSymbol)()))
295
Dim wrongSubstitution = TypeSubstitution.Create(TC7, {TC7.
TypeParameters
(0)}.AsImmutableOrNull(),
298
Dim substitution = TypeSubstitution.Create(missing, {TC.
TypeParameters
(0), TC.
TypeParameters
(1), missing.
TypeParameters
(0)}.AsImmutableOrNull(),
299
ImmutableArray.Create(Of TypeSymbol)(TC.
TypeParameters
(1), TC.
TypeParameters
(0), TC.
TypeParameters
(1)))
314
substitution = TypeSubstitution.Create(TC, {TC.
TypeParameters
(0), TC.
TypeParameters
(1)}.AsImmutableOrNull(),
315
ImmutableArray.Create(Of TypeSymbol)(TC.
TypeParameters
(1), TC.
TypeParameters
(0)))
323
ImmutableArray.Create(Of TypeSymbol)(TC.
TypeParameters
(0)))
331
substitution = TypeSubstitution.Create(TC, {TC.
TypeParameters
(0)}.AsImmutableOrNull(),
338
ImmutableArray.Create(Of TypeSymbol)(TC.
TypeParameters
(1)))
348
ImmutableArray.Create(Of TypeSymbol)(TC.
TypeParameters
(0)))
358
substitution = TypeSubstitution.Create(TC, {TC.
TypeParameters
(0)}.AsImmutableOrNull(),
365
ImmutableArray.Create(Of TypeSymbol)(TC.
TypeParameters
(1)))
SymbolsTests\Metadata\PE\VisualBasicCompilerFeatureRequiredTests.vb (1)
227
Assert.True(onClassTypeParameter.
TypeParameters
(0).HasUnsupportedMetadata)
SymbolsTests\Retargeting\RetargetingTests.vb (39)
132
CheckTypeParameters(sourceType.
TypeParameters
(0), retargetingType.
TypeParameters
(0))
315
Dim i_ct_v2 = compilation1_v2.GetTypeByMetadataName("I`1").Construct(ImmutableArray.Create(Of TypeSymbol)(c.
TypeParameters
(0)))
631
Dim sourceTypeParameter = sourceType.
TypeParameters
.Single()
637
Dim retargetingTypeParameter = retargetingType.
TypeParameters
.Single()
672
Dim sourceTypeParameter = sourceType.
TypeParameters
.Single()
679
Dim retargetingTypeParameter = retargetingType.
TypeParameters
.Single()
1327
Assert.Equal(sourceType.
TypeParameters
.Length, retargetingType.
TypeParameters
.Length)
1328
For i = 0 To sourceType.
TypeParameters
.Length - 1
1329
CheckTypeParameters(sourceType.
TypeParameters
(i), retargetingType.
TypeParameters
(i))
1337
Assert.Equal(sourceType.
TypeParameters
.Length, retargetingType.
TypeParameters
.Length)
1338
Assert.Equal(1, sourceType.
TypeParameters
(0).ConstraintTypes.Length)
1339
Assert.Equal(sourceType.
TypeParameters
(0).ConstraintTypes.Length, retargetingType.
TypeParameters
(0).ConstraintTypes.Length)
1340
Assert.False(sourceType.
TypeParameters
(0).HasConstructorConstraint)
1341
Assert.Equal(sourceType.
TypeParameters
(0).HasConstructorConstraint, retargetingType.
TypeParameters
(0).HasConstructorConstraint)
1342
For i = 0 To sourceType.
TypeParameters
(0).ConstraintTypes.Length - 1
1343
CheckTypes(sourceType.
TypeParameters
(0).ConstraintTypes(i), retargetingType.
TypeParameters
(0).ConstraintTypes(i))
1345
Assert.Equal("TestInterface", CType(sourceType.
TypeParameters
(0).ConstraintTypes(0), SourceNamedTypeSymbol).Name)
1352
Assert.Equal(sourceType.
TypeParameters
.Length, retargetingType.
TypeParameters
.Length)
1353
Assert.Equal(1, sourceType.
TypeParameters
(0).ConstraintTypes.Length)
1354
Assert.Equal(sourceType.
TypeParameters
(0).ConstraintTypes.Length, retargetingType.
TypeParameters
(0).ConstraintTypes.Length)
1355
Assert.True(sourceType.
TypeParameters
(0).HasConstructorConstraint)
1356
Assert.Equal(sourceType.
TypeParameters
(0).HasConstructorConstraint, retargetingType.
TypeParameters
(0).HasConstructorConstraint)
1357
For i = 0 To sourceType.
TypeParameters
.Length - 1
1358
CheckTypeParameters(sourceType.
TypeParameters
(i), retargetingType.
TypeParameters
(i))
1359
CheckTypes(sourceType.
TypeParameters
(0).ConstraintTypes(i), retargetingType.
TypeParameters
(0).ConstraintTypes(i))
1361
Assert.Equal("TestClass", CType(sourceType.
TypeParameters
(0).ConstraintTypes(0), SourceNamedTypeSymbol).Name)
3104
Assert.Equal(CType(sourceType.GetMember("Del_G_Sub_Constraint"), SourceNamedTypeSymbol).TypeParameters(0).ConstraintTypes(0), CType(retargetingType.GetMember("Del_G_Sub_Constraint"), RetargetingNamedTypeSymbol).UnderlyingNamedType.
TypeParameters
(0).ConstraintTypes(0))
SymbolsTests\Source\DelegateTests.vb (1)
197
Dim param1Type = subGenDel.
TypeParameters
(0)
SymbolsTests\Source\PropertyTests.vb (3)
4611
Assert.Equal(type.
TypeParameters
.Length, 0)
4622
Assert.Equal(type.
TypeParameters
.Length, 2)
4635
Assert.Equal(type.
TypeParameters
.Length, 2)
SymbolsTests\Source\SourceSymbolTests.vb (1)
326
Dim tp1 = DirectCast(classD.
TypeParameters
(0), TypeParameterSymbol)
SymbolsTests\Source\TypeBindingTests.vb (2)
281
Assert.Same(classD.
TypeParameters
(0), fieldJ.Type)
282
Assert.Same(classC.
TypeParameters
(1), fieldK.Type)
SymbolsTests\Source\TypeTests.vb (42)
41
Assert.NotSame(b1.
TypeParameters
(0), b2.
TypeParameters
(0)) ' they've been alpha renamed independently
42
Assert.Equal(b1.
TypeParameters
(0), b2.
TypeParameters
(0)) ' but happen to be the same type
117
Assert.Equal(0, classB.
TypeParameters
.Length)
134
Assert.Equal(1, delegateB.
TypeParameters
.Length)
135
Assert.Equal(0, delegateB.
TypeParameters
(0).Ordinal)
136
Assert.Same(delegateB, delegateB.
TypeParameters
(0).ContainingSymbol)
243
Assert.Equal(1, outerClass.
TypeParameters
.Length)
244
Dim outerTypeParam = outerClass.
TypeParameters
(0)
293
Assert.Equal(1, i2Arity1.
TypeParameters
.Length)
294
Dim i2Arity1TypeParam = i2Arity1.
TypeParameters
(0)
307
Assert.Equal(2, i2Arity2.
TypeParameters
.Length)
308
Dim i2Arity2TypeParam0 = i2Arity2.
TypeParameters
(0)
311
Dim i2Arity2TypeParam1 = i2Arity2.
TypeParameters
(1)
608
Assert.Equal(1, classA.
TypeParameters
.Length)
609
Assert.Equal("V", classA.
TypeParameters
(0).Name)
618
Assert.Equal(1, igoo.
TypeParameters
.Length)
619
Assert.Equal("T", igoo.
TypeParameters
(0).Name)
628
Assert.Equal(2, structS.
TypeParameters
.Length)
629
Assert.Equal("X", structS.
TypeParameters
(0).Name)
630
Assert.Equal("Y", structS.
TypeParameters
(1).Name)
652
Dim typeParams = interfaceZ.
TypeParameters
928
Assert.Equal(1, type2.
TypeParameters
.Length)
3807
Dim modifiedU = ImmutableArray.Create(New TypeWithModifiers(iDefinition.
TypeParameters
.Single(), modifiers))
3808
Dim i1 = iDefinition.Construct(TypeSubstitution.Create(iDefinition, iDefinition.
TypeParameters
, modifiedU))
3817
Dim modifiedT = ImmutableArray.Create(New TypeWithModifiers(cDefinition.
TypeParameters
.Single(), modifiers))
3818
Dim c2 = cDefinition.Construct(TypeSubstitution.Create(cDefinition, cDefinition.
TypeParameters
, modifiedT))
3825
Dim i2a = i2.Construct(iDefinition.
TypeParameters
.Single())
3831
ImmutableArray.Create(cDefinition.
TypeParameters
.Single(), iDefinition.
TypeParameters
.Single()),
3837
Dim c4 = cDefinition.Construct(TypeSubstitution.Create(cDefinition, cDefinition.
TypeParameters
, modifiedT))
3872
Dim modifiedT = New TypeWithModifiers(cDefinition.
TypeParameters
.Single(), modifiers)
3873
Dim modifiedU = New TypeWithModifiers(c2Definition.
TypeParameters
.Single(), modifiers)
3874
Dim modifiedV = New TypeWithModifiers(iDefinition.
TypeParameters
.Single(), modifiers)
3877
ImmutableArray.Create(cDefinition.
TypeParameters
.Single(), c2Definition.
TypeParameters
.Single(), iDefinition.
TypeParameters
.Single()),
3936
Dim modifiedU = ImmutableArray.Create(New TypeWithModifiers(definition.
TypeParameters
.Single(), modifiers))
3937
Dim t1 = definition.Construct(TypeSubstitution.Create(definition, definition.
TypeParameters
, modifiedU))
3951
Dim ctp = c.
TypeParameters
(0)
3952
Dim ctp2 = c2.
TypeParameters
(0)
SymbolsTests\SymbolErrorTests.vb (1)
23196
Assert.Equal(0, myMod.
TypeParameters
.Length)