38 references to IsRestrictedType
Microsoft.CodeAnalysis.CSharp (38)
Binder\Binder_AnonymousTypes.cs (1)
231
else if (expressionType.
IsRestrictedType
())
Binder\Binder_Conversions.cs (2)
731
if (elementType.IsPointerOrFunctionPointer() || elementType.
IsRestrictedType
())
735
else if (inlineArrayType.
IsRestrictedType
())
Binder\Binder_Expressions.cs (10)
1246
if ((object)argument.Type != null && argument.Type.
IsRestrictedType
())
1935
if (refKind != RefKind.None || type.
IsRestrictedType
())
2059
if (localSymbol.RefKind == RefKind.None && type.
IsRestrictedType
(ignoreSpanLikeTypes: true))
2103
else if (parameter.Type.
IsRestrictedType
(ignoreSpanLikeTypes: true))
2119
(parameter.RefKind != RefKind.None || parameter.Type.
IsRestrictedType
()) &&
2126
else if (parameter.Type.
IsRestrictedType
(ignoreSpanLikeTypes: true))
3249
&& type.
IsRestrictedType
())
4080
if (bestType.
IsRestrictedType
())
7562
if (typeArgument.Type.IsPointerOrFunctionPointer() || typeArgument.Type.
IsRestrictedType
())
10978
if ((!accessType.IsReferenceType && !accessType.IsValueType) || accessType.IsPointerOrFunctionPointer() || accessType.
IsRestrictedType
())
Binder\Binder_Invocation.cs (3)
1050
if (call.ReceiverOpt.Type.
IsRestrictedType
() && !call.Method.ContainingType.IsInterface && !TypeSymbol.Equals(call.Method.ContainingType, call.ReceiverOpt.Type, TypeCompareKind.ConsiderEverything2))
1056
else if (call.ReceiverOpt.Kind == BoundKind.BaseReference && this.ContainingType.
IsRestrictedType
())
1069
dynInvoke.Expression.Type.
IsRestrictedType
())
Binder\Binder_Operators.cs (3)
363
return !type.IsPointerOrFunctionPointer() && !type.
IsRestrictedType
() && !type.IsVoidType();
3518
if (targetType.
IsRestrictedType
() || operandType.
IsRestrictedType
())
Binder\ForEachLoopBinder.cs (1)
528
if (builder.InlineArraySpanType == WellKnownType.Unknown && getEnumeratorType.
IsRestrictedType
() && (IsDirectlyInIterator || IsInAsyncMethod()))
Binder\Semantics\Conversions\Conversions.cs (1)
458
if (method.RequiresInstanceReceiver && methodGroup.Receiver?.Type?.
IsRestrictedType
() == true)
Binder\Semantics\Conversions\ConversionsBase.cs (2)
3342
if (source.
IsRestrictedType
())
3825
if (destination.
IsRestrictedType
())
Lowering\ClosureConversion\ClosureConversion.Analysis.Tree.cs (1)
698
if (type.
IsRestrictedType
() == true)
Lowering\DiagnosticsPass_ExpressionTrees.cs (1)
378
type.
IsRestrictedType
())
Lowering\StateMachineRewriter\IteratorAndAsyncCaptureWalker.cs (3)
142
!parameter.Type.
IsRestrictedType
(),
146
!local.Type.
IsRestrictedType
(),
212
if (type.
IsRestrictedType
() ||
Symbols\AnonymousTypes\AnonymousTypeManager.Templates.cs (1)
335
(type.IsTypeParameter() || !type.
IsRestrictedType
(ignoreSpanLikeTypes: runtimeSupportsByRefLikeGenerics)) &&
Symbols\Source\SourceMemberFieldSymbol.cs (1)
62
else if (type.
IsRestrictedType
(ignoreSpanLikeTypes: true))
Symbols\Source\SourceMethodSymbol.cs (1)
73
else if (parameter.Type.
IsRestrictedType
())
Symbols\Source\SourceNamedTypeSymbol.cs (2)
1682
if (!this.
IsRestrictedType
(ignoreSpanLikeTypes: true))
1892
else if (this.
IsRestrictedType
())
Symbols\Source\SourcePropertySymbolBase.cs (1)
1833
if (type.
IsRestrictedType
(ignoreSpanLikeTypes: true))
Symbols\Synthesized\Records\SynthesizedRecordEquals.cs (1)
144
else if (parameterType.
IsRestrictedType
())
Symbols\TypeSymbolExtensions.cs (1)
149
&& !type.
IsRestrictedType
();
Symbols\TypeWithAnnotations.cs (2)
898
internal override bool IsRestrictedType(TypeSymbol typeSymbol, bool ignoreSpanLikeTypes) => typeSymbol.
IsRestrictedType
(ignoreSpanLikeTypes);
971
internal override bool IsRestrictedType(TypeSymbol typeSymbol, bool ignoreSpanLikeTypes) => typeSymbol.
IsRestrictedType
(ignoreSpanLikeTypes);