26 references to ValueType
Microsoft.CodeAnalysis.CSharp (13)
Binder\Binder_Constraints.cs (8)
144
if (isForOverride && (constraints & (TypeParameterConstraintKind.
ValueType
| TypeParameterConstraintKind.ReferenceType)) != 0)
185
if (isForOverride && (constraints & (TypeParameterConstraintKind.
ValueType
| TypeParameterConstraintKind.ReferenceType)) != 0)
191
constraints |= TypeParameterConstraintKind.
ValueType
;
200
if ((constraints & TypeParameterConstraintKind.
ValueType
) != 0)
231
if (isForOverride && (constraints & (TypeParameterConstraintKind.
ValueType
| TypeParameterConstraintKind.ReferenceType)) != 0)
346
(constraints & (TypeParameterConstraintKind.ReferenceType | TypeParameterConstraintKind.
ValueType
)) != (TypeParameterConstraintKind.ReferenceType | TypeParameterConstraintKind.
ValueType
));
535
if ((constraints & TypeParameterConstraintKind.
ValueType
) != 0)
Symbols\Source\SourceOrdinaryMethodSymbol.cs (2)
658
switch (declaredConstraints[i].Constraints & (TypeParameterConstraintKind.ReferenceType | TypeParameterConstraintKind.
ValueType
| TypeParameterConstraintKind.Default))
667
case TypeParameterConstraintKind.
ValueType
:
Symbols\Source\TypeParameterConstraintClause.cs (3)
32
/// Cannot be combined with <see cref="ReferenceType"/>, <see cref="
ValueType
"/> or <see cref="Unmanaged"/>.
59
AllValueTypeKinds =
ValueType
| Unmanaged,
64
AllNonNullableKinds = ReferenceType |
ValueType
| Constructor | Unmanaged | AllowByRefLike,
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (11)
Compilation\SemanticModelGetDeclaredSymbolAPITests.cs (1)
1490
CompilationUtils.CheckConstraints(symbol, TypeParameterConstraintKind.
ValueType
, "I<int>");
Symbols\GenericConstraintTests.cs (10)
38
CheckConstraints(type.TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5289
CheckConstraints(@namespace.GetMember<NamedTypeSymbol>("V1").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5290
CheckConstraints(@namespace.GetMember<NamedTypeSymbol>("V2").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5291
CheckConstraints(@namespace.GetMember<NamedTypeSymbol>("V3").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5292
CheckConstraints(@namespace.GetMember<NamedTypeSymbol>("V4").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5332
CheckConstraints(type.GetMember<MethodSymbol>("M2").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5335
CheckConstraints(type.GetMember<MethodSymbol>("M2").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5338
CheckConstraints(type.GetMember<MethodSymbol>("M2").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5632
CheckConstraints(type.GetMember<MethodSymbol>("M2").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType");
5635
CheckConstraints(type.GetMember<MethodSymbol>("M2").TypeParameters[0], TypeParameterConstraintKind.
ValueType
, true, false, "ValueType", "ValueType", "ValueType");
Microsoft.CodeAnalysis.CSharp.Test.Utilities (2)
CompilationTestUtils.cs (2)
182
constraints |= TypeParameterConstraintKind.
ValueType
;
200
constraints |= TypeParameterConstraintKind.
ValueType
;