117 references to IsDynamic
Microsoft.CodeAnalysis.CSharp (90)
Binder\Binder.IdentifierUsedAsValueFinder.cs (1)
259
Debug.Assert(!type.
IsDynamic
());
Binder\Binder_Await.cs (1)
86
type.
IsDynamic
() ||
Binder\Binder_Deconstruct.cs (1)
622
if (receiver.Type?.
IsDynamic
() ?? false)
Binder\Binder_Expressions.cs (7)
1344
if (type.
IsDynamic
())
1367
if (type.
IsDynamic
()
4930
if (initializerType.
IsDynamic
())
5366
if (initializerType.
IsDynamic
())
5504
if (implicitReceiver.Type.
IsDynamic
())
6414
Debug.Assert(!leftType.
IsDynamic
());
6548
if ((object)leftType != null && leftType.
IsDynamic
())
Binder\Binder_Invocation.cs (3)
260
if ((object)boundExpression.Type != null && boundExpression.Type.
IsDynamic
())
1167
Debug.Assert(parameterType.
IsDynamic
() || parameterType.SpecialType == SpecialType.System_Object);
1401
if (parameterType.
IsDynamic
() || parameterType.SpecialType == SpecialType.System_Object)
Binder\Binder_Lookup.cs (1)
1745
return (object)type != null && (type.IsDelegateType() || type.
IsDynamic
() || type.IsFunctionPointer());
Binder\Binder_Operators.cs (8)
375
Debug.Assert((object)left.Type != null && left.Type.
IsDynamic
() || (object)right.Type != null && right.Type.
IsDynamic
());
524
if ((object)leftType != null && leftType.
IsDynamic
() || (object)rightType != null && rightType.
IsDynamic
())
1030
if (type.
IsDynamic
())
2259
if (operandType.
IsDynamic
())
3969
if ((object)optRightType != null && optRightType.
IsDynamic
())
4126
if (underlyingRightConversion.Exists && rightOperand.Type?.
IsDynamic
() != true)
Binder\Binder_Patterns.cs (5)
304
if (inputType.
IsDynamic
())
309
if (inputType.IsErrorType() || inputType.
IsDynamic
())
357
Debug.Assert(!inputType.
IsDynamic
());
749
if (patternType.
IsDynamic
())
812
if (expressionType.
IsDynamic
())
Binder\Binder_QueryErrors.cs (1)
45
if (instanceArgument.Type.
IsDynamic
())
Binder\Binder_TupleOperators.cs (4)
88
if ((object)leftType != null && leftType.
IsDynamic
() || (object)rightType != null && rightType.
IsDynamic
())
183
Debug.Assert((object)left.Type != null && left.Type.
IsDynamic
() || (object)right.Type != null && right.Type.
IsDynamic
());
Binder\DecisionDagBuilder.cs (1)
461
if (input.Type.
IsDynamic
() ? type.SpecialType == SpecialType.System_Object : conversion.IsImplicit)
Binder\ForEachLoopBinder.cs (1)
1078
if (collectionExprType.
IsDynamic
())
Binder\Semantics\Conversions\Conversions.cs (1)
315
if (parameter.Type.
IsDynamic
())
Binder\Semantics\OverloadResolution\AnalyzedArguments.cs (1)
101
if ((object?)argument.Type != null && argument.Type.
IsDynamic
() && (!hasRefKinds || RefKinds[i] == Microsoft.CodeAnalysis.RefKind.None))
Binder\Semantics\OverloadResolution\MethodTypeInference.cs (6)
2836
if (source.
IsDynamic
() && !destination.
IsDynamic
())
3011
Debug.Assert(!method.GetParameterType(0).
IsDynamic
());
3206
if (newCandidate.Type.
IsDynamic
())
3244
if (x.Type.
IsDynamic
() ^ y.Type.
IsDynamic
()) { return false; }
Binder\Semantics\OverloadResolution\OverloadResolution.cs (6)
2314
if (t1.
IsDynamic
() || t2.
IsDynamic
())
2316
Debug.Assert(t1.
IsDynamic
() && t2.
IsDynamic
() ||
2317
t1.
IsDynamic
() && t2.SpecialType == SpecialType.System_Object ||
2318
t2.
IsDynamic
() && t1.SpecialType == SpecialType.System_Object);
Binder\UsingStatementBinder.cs (3)
134
if (declarationTypeOpt.
IsDynamic
())
277
Debug.Assert(expressionOpt.Type?.
IsDynamic
() != true || result.Kind == ConversionKind.ImplicitDynamic);
285
Debug.Assert(!declarationTypeOpt.
IsDynamic
() || result.Kind == ConversionKind.ImplicitDynamic);
BoundTree\BoundExpressionExtensions.cs (1)
114
return type is { } && type.
IsDynamic
();
CodeGen\EmitExpression.cs (1)
723
Debug.Assert(argument.Type.
IsDynamic
(), "passing args byref should not clone them into temps");
Compilation\CSharpCompilation.cs (1)
2017
RoslynDebug.Assert(!namedType.
IsDynamic
());
Compilation\CSharpSemanticModel.cs (3)
3882
Debug.Assert(returnType.
IsDynamic
());
3886
Debug.Assert(rightType.
IsDynamic
());
3891
Debug.Assert(leftType.
IsDynamic
());
FlowAnalysis\NullableWalker.cs (5)
3372
return type.IsErrorType() || type.
IsDynamic
() || type.HasUseSiteError || (type.IsAnonymousType && canIgnoreAnonymousType((NamedTypeSymbol)type));
7292
if (value.Type is null || value.Type.
IsDynamic
() || value.ConstantValueOpt != null)
10737
Debug.Assert(node.Type.
IsDynamic
());
10756
Debug.Assert(node.Type.
IsDynamic
());
10863
Debug.Assert(node.Type.
IsDynamic
());
Lowering\AsyncRewriter\AsyncMethodBuilderMemberCollection.cs (1)
257
if (resultType.
IsDynamic
())
Lowering\AsyncRewriter\AsyncMethodToStateMachineRewriter.cs (2)
437
if (awaiterTemp.Type.
IsDynamic
())
481
blockBuilder.Add(awaiterTemp.Type.
IsDynamic
()
Lowering\Extensions.cs (1)
40
if (expr.Type.
IsDynamic
())
Lowering\LocalRewriter\LocalRewriter.PatternLocalRewriter.cs (1)
200
if (inputType.
IsDynamic
())
Lowering\LocalRewriter\LocalRewriter_ConditionalAccess.cs (1)
55
var lowerToConditional = node.AccessExpression.Type.
IsDynamic
();
Lowering\LocalRewriter\LocalRewriter_DeconstructionAssignmentOperator.cs (1)
464
effects, temps, isDynamicAssignment: variable.Type.
IsDynamic
());
Lowering\LocalRewriter\LocalRewriter_ObjectOrCollectionInitializerExpression.cs (1)
317
if (memberInit.MemberSymbol == null && memberInit.Type.
IsDynamic
())
Lowering\LocalRewriter\LocalRewriter_StringInterpolation.cs (1)
151
if (actualCall.Type!.
IsDynamic
())
Lowering\LocalRewriter\LocalRewriter_UnaryOperator.cs (1)
85
|| type.
IsDynamic
());
Lowering\LocalRewriter\LocalRewriter_UsingStatement.cs (2)
156
if (expressionType.
IsDynamic
())
235
if (localType.
IsDynamic
())
Lowering\LocalRewriter\LoweredDynamicOperationFactory.cs (1)
876
if (argType is { } && !argType.
IsDynamic
())
Operations\CSharpOperationFactory.cs (2)
854
Debug.Assert(boundObjectInitializerMember.Type.
IsDynamic
());
1447
if (boundBinaryOperator.Type.
IsDynamic
() &&
Symbols\Compilation_WellKnownMembers.cs (1)
752
if (type.
IsDynamic
() && refKindOpt == RefKind.None && customModifiersCount == 0)
Symbols\Metadata\PE\DynamicTypeDecoder.cs (1)
145
PeekFlag() && (type.SpecialType != SpecialType.System_Object && !type.
IsDynamic
()))
Symbols\NamedTypeSymbol.cs (1)
1007
return other.
IsDynamic
() ? other : this;
Symbols\ReducedExtensionMethodSymbol.cs (1)
123
if (thisType.
IsDynamic
())
Symbols\Source\ParameterHelpers.cs (1)
752
conversion.IsIdentity && parameterType.SpecialType == SpecialType.System_Object && defaultExpression.Type.
IsDynamic
())
Symbols\Source\SourceUserDefinedOperatorSymbolBase.cs (2)
543
if (source.
IsDynamic
() || target.
IsDynamic
())
Symbols\Synthesized\SynthesizedEntryPointSymbol.cs (1)
476
Debug.Assert(!initializer.ReturnType.
IsDynamic
());
Symbols\Synthesized\SynthesizedIntrinsicOperatorSymbol.cs (5)
41
Debug.Assert((leftType.
IsDynamic
() || rightType.
IsDynamic
()) == returnType.
IsDynamic
());
42
Debug.Assert(_containingType.
IsDynamic
() == returnType.
IsDynamic
());
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (19)
Semantics\OperatorTests.cs (19)
7539
Assert.Equal(type.
IsDynamic
() ? CandidateReason.LateBound : CandidateReason.None, info1.CandidateReason);
7574
if (type.
IsDynamic
())
7629
expectChecked = (type.
IsDynamic
() || symbol1.ContainingType.EnumUnderlyingTypeOrSelf().SpecialType.IsIntegralType());
7636
expectChecked = (type.
IsDynamic
() || type.IsPointerType() ||
8088
if (leftType.
IsDynamic
() || rightType.
IsDynamic
())
8108
Assert.Equal(leftType.
IsDynamic
() || rightType.
IsDynamic
() ? CandidateReason.LateBound : CandidateReason.None, info1.CandidateReason);
8140
bool isDynamic = (leftType.
IsDynamic
() || rightType.
IsDynamic
());
8159
if (leftType.
IsDynamic
() && !rightType.IsPointerType() && !rightType.IsRestrictedType())
8163
else if (rightType.
IsDynamic
() && !leftType.IsPointerType() && !leftType.IsRestrictedType())
8328
if (!rightType.
IsDynamic
())
8333
if (!leftType.
IsDynamic
())
8391
Assert.Equal(isDynamic, signature.ReturnType.
IsDynamic
());
8483
if (rightType.
IsDynamic
())
8501
if (leftType.
IsDynamic
())
8515
if (rightType.
IsDynamic
())
8524
if (leftType.
IsDynamic
())
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (8)
Symbols\Source\PropertyTests.cs (8)
2619
Assert.False(iap.Type.
IsDynamic
());
2621
Assert.False(iam.ReturnType.
IsDynamic
());
2637
Assert.False(iap.Type.
IsDynamic
());
2639
Assert.False(iam.ReturnType.
IsDynamic
());
2655
Assert.True(iap.Type.
IsDynamic
());
2657
Assert.True(iam.ReturnType.
IsDynamic
());
2673
Assert.True(iap.Type.
IsDynamic
());
2675
Assert.True(iam.ReturnType.
IsDynamic
());