Base:
property
IsTupleType
Microsoft.CodeAnalysis.CSharp.Symbols.TypeSymbol.IsTupleType
70 references to IsTupleType
Microsoft.CodeAnalysis.CSharp (48)
Binder\Binder_Conversions.cs (2)
912
if (targetType.
IsTupleType
)
922
if (sourceTuple.Type is NamedTypeSymbol {
IsTupleType
: true } sourceType)
Emitter\Model\PEModuleBuilder.cs (1)
951
else if (namedTypeSymbol.
IsTupleType
)
FlowAnalysis\NullableWalker.cs (6)
3391
(FieldSymbol { ContainingType: {
IsTupleType
: true }, TupleElementIndex: var oi } originalField, FieldSymbol { ContainingType: {
IsTupleType
: true }, TupleElementIndex: var ui } updatedField) =>
3577
if (containingType?.
IsTupleType
== true && !isDefaultValueTypeConstructor)
7613
Debug.Assert(tupleType.
IsTupleType
);
7683
if (valueTuple is null || !valueTuple.
IsTupleType
)
9516
if (expr.Type is NamedTypeSymbol {
IsTupleType
: true } tupleType)
Lowering\LocalRewriter\LocalRewriter_Field.cs (1)
26
if (fieldSymbol.ContainingType.
IsTupleType
)
Lowering\LocalRewriter\LocalRewriter_TupleCreationExpression.cs (1)
45
Debug.Assert(type.
IsTupleType
);
Symbols\ConstraintsHelper.cs (1)
560
Debug.Assert(tuple.
IsTupleType
);
Symbols\ErrorTypeSymbol.cs (1)
142
if (
IsTupleType
)
Symbols\FieldSymbol.cs (2)
438
return ContainingType.
IsTupleType
? this : null;
474
if (!ContainingType.
IsTupleType
)
Symbols\Metadata\PE\PENamedTypeSymbol.cs (1)
1407
if (
IsTupleType
)
Symbols\Metadata\PE\TupleTypeDecoder.cs (1)
290
if (decodedType.
IsTupleType
)
Symbols\NamedTypeSymbol.cs (3)
902
if (this.
IsTupleType
&& !tupleNamesEquals(other, comparison))
1028
return
IsTupleType
? MergeTupleNames((NamedTypeSymbol)other, result) : result;
1048
bool isTuple = typeA.
IsTupleType
;
Symbols\Source\SourceMemberContainerSymbol.cs (3)
1248
return (
IsTupleType
|| IsRecord || IsRecordStruct) ? GetMembers().Select(m => m.Name) : this.declaration.MemberNames;
2702
if (!membersAndInitializers.HaveIndexers && !this.
IsTupleType
&& _lazyEarlyAttributeDecodingMembersDictionary is object)
4597
if (!this.
IsTupleType
)
Symbols\SubstitutedFieldSymbol.cs (1)
66
if (this.ContainingType.
IsTupleType
&& this.IsDefaultTupleElement)
Symbols\SubstitutedNamedTypeSymbol.cs (3)
174
if (
IsTupleType
)
240
if (
IsTupleType
)
302
if (
IsTupleType
)
Symbols\Tuples\TupleErrorFieldSymbol.cs (1)
195
Debug.Assert(newOwner.
IsTupleType
&& newOwner.TupleElementTypesWithAnnotations.Length > TupleElementIndex);
Symbols\Tuples\TupleFieldSymbol.cs (6)
53
Debug.Assert(container.
IsTupleType
);
108
if (!originalContainer.
IsTupleType
)
210
Debug.Assert(newOwner.
IsTupleType
);
266
Debug.Assert(container.
IsTupleType
);
267
Debug.Assert(underlyingField.ContainingType.
IsTupleType
);
331
Debug.Assert(newOwner.
IsTupleType
);
Symbols\Tuples\TupleTypeSymbol.cs (11)
113
Debug.Assert(tupleCompatibleType.
IsTupleType
);
119
if (!
IsTupleType
|| (original._lazyTupleData == null && this._lazyTupleData == null) || TupleData!.EqualsIgnoringTupleUnderlyingType(original.TupleData))
128
=> this._lazyTupleData != null ? this.TupleData!.TupleUnderlyingType : (this.
IsTupleType
? this : null);
172
Debug.Assert(
IsTupleType
);
179
Debug.Assert(
IsTupleType
);
542
if (!
IsTupleType
)
566
=>
IsTupleType
? TupleData!.TupleElementTypesWithAnnotations(this) : default;
569
=>
IsTupleType
? TupleData!.TupleElements(this) : default;
573
return
IsTupleType
? TupleData!.GetTupleMemberSymbolForUnderlyingMember(underlyingMemberOpt) : null;
578
Debug.Assert(
IsTupleType
);
929
Debug.Assert(underlyingType.
IsTupleType
);
Symbols\TypeUnification.cs (1)
279
var typeParts = namedType.
IsTupleType
? namedType.TupleElementTypesWithAnnotations : namedType.TypeArgumentsWithAnnotationsNoUseSiteDiagnostics;
Symbols\Wrapped\WrappedNamedTypeSymbol.cs (2)
131
if (
IsTupleType
)
144
if (
IsTupleType
)
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (22)
CodeGen\CodeGenTupleTest.cs (22)
3343
Assert.True(mTuple.
IsTupleType
);
4471
Assert.True(vt2.
IsTupleType
);
4499
Assert.True(unnamedTuple.
IsTupleType
);
4510
Assert.True(namedTuple.
IsTupleType
);
5826
Assert.False(vt8.
IsTupleType
);
6030
Assert.False(vt8.OriginalDefinition.
IsTupleType
);
6931
Assert.False(stringType.
IsTupleType
);
11162
Assert.True(m1Tuple.
IsTupleType
);
11426
Assert.True(m1Tuple.
IsTupleType
);
11816
Assert.True(m3TupleRestTuple.
IsTupleType
);
12744
Assert.True(m1Tuple.
IsTupleType
);
13456
Assert.True(sym.ContainingType.
IsTupleType
);
13465
Assert.True(sym.ContainingType.
IsTupleType
);
13474
Assert.True(sym.ContainingType.
IsTupleType
);
13942
Assert.True(m1Tuple.
IsTupleType
);
14106
Assert.True(m1Tuple.
IsTupleType
);
26938
Assert.True(tuple.
IsTupleType
);
27005
Assert.True(tuple1.
IsTupleType
);
27021
Assert.True(tuple2.
IsTupleType
);
28288
Assert.True(namedType.
IsTupleType
);
28370
Assert.False(namedType.
IsTupleType
);
28458
Assert.True(namedType.
IsTupleType
);