2441 references to BoundKind
Microsoft.CodeAnalysis.CSharp (2422)
Binder\Binder.cs (1)
888RoslynDebug.Assert(statement.Kind != BoundKind.StatementList);
Binder\Binder.ValueChecks.cs (235)
738case BoundKind.PropertyGroup: 748case BoundKind.Local: 752case BoundKind.OutVariablePendingInference: 753case BoundKind.OutDeconstructVarPendingInference: 757case BoundKind.DiscardExpression: 761case BoundKind.PropertyAccess: 799case BoundKind.IndexerAccess: 803case BoundKind.ImplicitIndexerAccess: 821case BoundKind.UnconvertedObjectCreationExpression: 822case BoundKind.UnconvertedCollectionExpression: 823case BoundKind.UnconvertedConditionalOperator: 824case BoundKind.UnconvertedSwitchExpression: 825case BoundKind.TupleLiteral: 832case BoundKind.PointerIndirectionOperator: 840case BoundKind.PointerElementAccess: 855if (expr.Kind == BoundKind.MethodGroup && valueKind != BindValueKind.RValueOrMethodGroup) 881if ((object)otherSymbol != null && receiver?.Kind == BoundKind.TypeOrValueExpression) 921case BoundKind.TypeOrValueExpression: 922case BoundKind.QueryClause when ((BoundQueryClause)expression).Value.Kind == BoundKind.TypeOrValueExpression: 954case BoundKind.PropertyAccess: 955case BoundKind.IndexerAccess: 956case BoundKind.ImplicitIndexerAccess when ((BoundImplicitIndexerAccess)expr).IndexerOrSliceAccess.Kind == BoundKind.IndexerAccess: 959case BoundKind.EventAccess: 979case BoundKind.NamespaceExpression: 984case BoundKind.TypeExpression: 989case BoundKind.Lambda: 990case BoundKind.UnboundLambda: 995case BoundKind.UnconvertedAddressOfOperator: 1000case BoundKind.MethodGroup when valueKind == BindValueKind.AddressOf: 1005case BoundKind.MethodGroup: 1011case BoundKind.RangeVariable: 1027case BoundKind.Conversion: 1038case BoundKind.ArrayAccess: 1042case BoundKind.PointerIndirectionOperator: 1044case BoundKind.RefValueOperator: 1046case BoundKind.DynamicMemberAccess: 1047case BoundKind.DynamicIndexerAccess: 1048case BoundKind.DynamicObjectInitializerMember: 1060case BoundKind.PointerElementAccess: 1077case BoundKind.Parameter: 1081case BoundKind.Local: 1085case BoundKind.ThisReference: 1113case BoundKind.ImplicitReceiver: 1114case BoundKind.ObjectOrCollectionValuePlaceholder: 1118case BoundKind.Call: 1122case BoundKind.FunctionPointerInvocation: 1130case BoundKind.ImplicitIndexerAccess: 1144case BoundKind.InlineArrayAccess: 1166case BoundKind.ImplicitIndexerReceiverPlaceholder: 1169case BoundKind.DeconstructValuePlaceholder: 1172case BoundKind.ConditionalOperator: 1192case BoundKind.FieldAccess: 1198case BoundKind.AssignmentOperator: 1209case BoundKind.ValuePlaceholder: 1210case BoundKind.CollectionBuilderElementsPlaceholder: 1262case BoundKind.NamespaceExpression: 1265case BoundKind.TypeExpression: 1915return Flags.Includes(BinderFlags.ObjectInitializerMember) && receiver.Kind == BoundKind.ObjectOrCollectionValuePlaceholder || 2079ReportDiagnosticsIfObsolete(diagnostics, setMethod, node, receiver?.Kind == BoundKind.BaseReference); 2130ReportDiagnosticsIfObsolete(diagnostics, getMethod, node, receiver?.Kind == BoundKind.BaseReference); 2214if (receiverOpt?.Kind == BoundKind.BaseReference && member.IsAbstract) 2696if (argument.Kind == BoundKind.ArgListOperator) 3737case BoundKind.ArrayAccess: 3738case BoundKind.PointerIndirectionOperator: 3739case BoundKind.PointerElementAccess: 3743case BoundKind.RefValueOperator: 3749case BoundKind.DiscardExpression: 3753case BoundKind.DynamicMemberAccess: 3754case BoundKind.DynamicIndexerAccess: 3760case BoundKind.Parameter: 3763case BoundKind.Local: 3766case BoundKind.CapturedReceiverPlaceholder: 3770case BoundKind.ThisReference: 3775case BoundKind.ConditionalOperator: 3788case BoundKind.FieldAccess: 3791case BoundKind.EventAccess: 3810case BoundKind.Call: 3830case BoundKind.FunctionPointerInvocation: 3845case BoundKind.IndexerAccess: 3855case BoundKind.ImplicitIndexerAccess: 3894case BoundKind.InlineArrayAccess: 3915case BoundKind.PropertyAccess: 3923case BoundKind.AssignmentOperator: 3935case BoundKind.Conversion: 3942case BoundKind.UnaryOperator: 3949case BoundKind.BinaryOperator: 3956case BoundKind.UserDefinedConditionalLogicalOperator: 3962case BoundKind.CompoundAssignmentOperator: 3969case BoundKind.IncrementOperator: 4021case BoundKind.ArrayAccess: 4022case BoundKind.PointerIndirectionOperator: 4023case BoundKind.PointerElementAccess: 4027case BoundKind.RefValueOperator: 4038case BoundKind.DiscardExpression: 4042case BoundKind.DynamicMemberAccess: 4043case BoundKind.DynamicIndexerAccess: 4049case BoundKind.Parameter: 4053case BoundKind.Local: 4057case BoundKind.CapturedReceiverPlaceholder: 4065case BoundKind.ThisReference: 4070case BoundKind.ConditionalOperator: 4082case BoundKind.FieldAccess: 4086case BoundKind.EventAccess: 4096case BoundKind.Call: 4120case BoundKind.IndexerAccess: 4139case BoundKind.ImplicitIndexerAccess: 4191case BoundKind.InlineArrayAccess: 4216case BoundKind.FunctionPointerInvocation: 4233case BoundKind.PropertyAccess: 4251case BoundKind.AssignmentOperator: 4268case BoundKind.Conversion: 4280case BoundKind.UnaryOperator: 4287case BoundKind.BinaryOperator: 4294case BoundKind.UserDefinedConditionalLogicalOperator: 4300case BoundKind.CompoundAssignmentOperator: 4307case BoundKind.IncrementOperator: 4314case BoundKind.ThrowExpression: 4377case BoundKind.ThisReference: 4381case BoundKind.DefaultLiteral: 4382case BoundKind.DefaultExpression: 4383case BoundKind.Utf8String: 4387case BoundKind.Parameter: 4390case BoundKind.FromEndIndexExpression: 4395case BoundKind.TupleLiteral: 4396case BoundKind.ConvertedTupleLiteral: 4400case BoundKind.MakeRefOperator: 4401case BoundKind.RefValueOperator: 4407case BoundKind.DiscardExpression: 4410case BoundKind.DeconstructValuePlaceholder: 4411case BoundKind.InterpolatedStringArgumentPlaceholder: 4412case BoundKind.AwaitableValuePlaceholder: 4413case BoundKind.ValuePlaceholder: 4414case BoundKind.CollectionBuilderElementsPlaceholder: 4417case BoundKind.Local: 4420case BoundKind.CapturedReceiverPlaceholder: 4425case BoundKind.StackAllocArrayCreation: 4426case BoundKind.ConvertedStackAllocExpression: 4429case BoundKind.ConditionalOperator: 4444case BoundKind.NullCoalescingOperator: 4450case BoundKind.FieldAccess: 4463case BoundKind.Call: 4477case BoundKind.FunctionPointerInvocation: 4485case BoundKind.IndexerAccess: 4495case BoundKind.ImplicitIndexerAccess: 4527case BoundKind.InlineArrayAccess: 4540case BoundKind.PropertyAccess: 4548case BoundKind.ObjectCreationExpression: 4566case BoundKind.NewT: 4581case BoundKind.WithExpression: 4587case BoundKind.UnaryOperator: 4598case BoundKind.Conversion: 4635case BoundKind.AssignmentOperator: 4639case BoundKind.NullCoalescingAssignmentOperator: 4644case BoundKind.IncrementOperator: 4665case BoundKind.CompoundAssignmentOperator: 4687case BoundKind.BinaryOperator: 4700case BoundKind.RangeExpression: 4706case BoundKind.UserDefinedConditionalLogicalOperator: 4713case BoundKind.QueryClause: 4716case BoundKind.RangeVariable: 4719case BoundKind.ObjectInitializerExpression: 4723case BoundKind.CollectionInitializerExpression: 4727case BoundKind.ObjectInitializerMember: 4733case BoundKind.ImplicitReceiver: 4734case BoundKind.ObjectOrCollectionValuePlaceholder: 4739case BoundKind.InterpolatedStringHandlerPlaceholder: 4744case BoundKind.DisposableValuePlaceholder: 4749case BoundKind.PointerElementAccess: 4750case BoundKind.PointerIndirectionOperator: 4754case BoundKind.AsOperator: 4755case BoundKind.AwaitExpression: 4756case BoundKind.ConditionalAccess: 4757case BoundKind.ConditionalReceiver: 4758case BoundKind.ArrayAccess: 4762case BoundKind.ArgList: 4766case BoundKind.ConvertedSwitchExpression: 4767case BoundKind.UnconvertedSwitchExpression: 4883if (expr.Kind == BoundKind.AssignmentOperator) 5037case BoundKind.ThisReference: 5042case BoundKind.DefaultLiteral: 5043case BoundKind.DefaultExpression: 5044case BoundKind.Utf8String: 5048case BoundKind.Parameter: 5051case BoundKind.TupleLiteral: 5052case BoundKind.ConvertedTupleLiteral: 5056case BoundKind.MakeRefOperator: 5057case BoundKind.RefValueOperator: 5061case BoundKind.DiscardExpression: 5065case BoundKind.DeconstructValuePlaceholder: 5066case BoundKind.AwaitableValuePlaceholder: 5067case BoundKind.InterpolatedStringArgumentPlaceholder: 5068case BoundKind.ValuePlaceholder: 5069case BoundKind.CollectionBuilderElementsPlaceholder: 5077case BoundKind.Local: 5086case BoundKind.CapturedReceiverPlaceholder: 5091case BoundKind.StackAllocArrayCreation: 5092case BoundKind.ConvertedStackAllocExpression: 5100case BoundKind.UnconvertedConditionalOperator: 5108case BoundKind.ConditionalOperator: 5124case BoundKind.NullCoalescingOperator: 5129case BoundKind.FieldAccess: 5142case BoundKind.Call: 5161case BoundKind.FunctionPointerInvocation: 5173case BoundKind.IndexerAccess: 5187case BoundKind.ImplicitIndexerAccess: 5229case BoundKind.InlineArrayAccess: 5246case BoundKind.PropertyAccess: 5258case BoundKind.ObjectCreationExpression: 5286case BoundKind.NewT: 5306case BoundKind.WithExpression: 5317case BoundKind.UnaryOperator: 5332case BoundKind.FromEndIndexExpression: 5336case BoundKind.Conversion: 5387case BoundKind.AssignmentOperator: 5392case BoundKind.NullCoalescingAssignmentOperator: 5397case BoundKind.IncrementOperator: 5422case BoundKind.CompoundAssignmentOperator: 5446case BoundKind.BinaryOperator: 5468case BoundKind.RangeExpression: 5478case BoundKind.UserDefinedConditionalLogicalOperator: 5489case BoundKind.QueryClause: 5493case BoundKind.RangeVariable: 5497case BoundKind.ObjectInitializerExpression: 5501case BoundKind.CollectionInitializerExpression: 5505case BoundKind.PointerElementAccess: 5509case BoundKind.PointerIndirectionOperator: 5513case BoundKind.AsOperator: 5514case BoundKind.AwaitExpression: 5515case BoundKind.ConditionalAccess: 5516case BoundKind.ConditionalReceiver: 5517case BoundKind.ArrayAccess: 5521case BoundKind.UnconvertedSwitchExpression: 5522case BoundKind.ConvertedSwitchExpression:
Binder\Binder_Attributes.cs (5)
822case BoundKind.FieldAccess: 827case BoundKind.PropertyAccess: 872case BoundKind.Conversion: 874case BoundKind.TypeOfOperator: 876case BoundKind.ArrayCreation:
Binder\Binder_Await.cs (3)
81if (expression.Kind != BoundKind.Call || 600if (getAwaiterCall.Kind != BoundKind.Call) 716if (getAwaiterGetResultCall.Kind != BoundKind.Call)
Binder\Binder_Conversions.cs (18)
141if (conversion.IsAnonymousFunction && source.Kind == BoundKind.UnboundLambda) 215if (source.Kind == BoundKind.UnconvertedSwitchExpression) 237if (source.Kind == BoundKind.UnconvertedCollectionExpression) 260if (source.Kind == BoundKind.UnconvertedConditionalOperator) 1832if (boundExpression.Kind == BoundKind.FieldAccess || boundExpression.Kind == BoundKind.PropertyAccess) 1839if (boundExpression.Kind != BoundKind.MethodGroup) 2640Debug.Assert(source.Kind is BoundKind.MethodGroup or BoundKind.UnboundLambda); 2647if (source.Kind == BoundKind.UnboundLambda && 2656source.Kind == BoundKind.MethodGroup && 3047if (node.Kind != BoundKind.MethodGroup) 3190if (receiverOpt.Kind == BoundKind.QueryClause) 3292while (receiverOpt.Kind == BoundKind.QueryClause) 3297return receiverOpt.Kind == BoundKind.TypeExpression; 3309case BoundKind.ThisReference: 3310case BoundKind.HostObjectMemberReference: 3311case BoundKind.PreviousSubmissionReference:
Binder\Binder_Deconstruct.cs (9)
213if (boundRHS.Kind == BoundKind.TupleLiteral) 373case BoundKind.DeconstructionVariablePendingInference: 378case BoundKind.DiscardExpression: 408case BoundKind.DeconstructionVariablePendingInference: 412case BoundKind.DiscardExpression: 490if (element.Kind == BoundKind.TupleLiteral) 599if (expression.Kind == BoundKind.DiscardExpression) 663if (memberAccess.Kind != BoundKind.MethodGroup) 795if (expression == null && checkedVariable.Kind != BoundKind.DiscardExpression)
Binder\Binder_Expressions.cs (71)
224BoundKind exprKind = expr.Kind; 226if (expr.HasAnyErrors && ((object)resultType != null || exprKind == BoundKind.UnboundLambda || exprKind == BoundKind.DefaultLiteral)) 231if (exprKind == BoundKind.BadExpression) 278if (valueOrType.Kind == BoundKind.TypeExpression) 448Debug.Assert(expr.Kind is BoundKind.UnboundLambda or BoundKind.MethodGroup); 578if (expr.Kind == BoundKind.ArgListOperator) 620if (IsEarlyAttributeBinder && result.Kind == BoundKind.MethodGroup && (!IsInsideNameof || EnclosingNameofArgument != node)) 2848if (operand.Kind == BoundKind.UnboundLambda) 2897case BoundKind.MethodGroup: 2907case BoundKind.TupleLiteral: 2931case BoundKind.StackAllocArrayCreation: 2937case BoundKind.UnconvertedConditionalOperator when operand.Type is null: 2938case BoundKind.UnconvertedSwitchExpression when operand.Type is null: 2943case BoundKind.UnconvertedCollectionExpression: 2948case BoundKind.UnconvertedAddressOfOperator: 3194case BoundKind.PropertyAccess: 3195case BoundKind.IndexerAccess: 3585else if (argument.Kind == BoundKind.OutVariablePendingInference) 3589else if (argument.Kind == BoundKind.OutDeconstructVarPendingInference) 3593else if (argument.Kind == BoundKind.DiscardExpression && !argument.HasExpressionType()) 3629(BoundKind.OutVariablePendingInference or BoundKind.OutDeconstructVarPendingInference or BoundKind.DiscardExpression or BoundKind.ArgListOperator)); 5602else if (argument.Kind == BoundKind.MethodGroup) 6039if (boundMember.Kind == BoundKind.PropertyGroup) 6081BoundKind boundMemberKind = boundMember.Kind; 6093case BoundKind.FieldAccess: 6110case BoundKind.EventAccess: 6113case BoundKind.PropertyAccess: 6117case BoundKind.IndexerAccess: 6150case BoundKind.ImplicitIndexerAccess: 6161case BoundKind.DynamicObjectInitializerMember: 6164case BoundKind.DynamicIndexerAccess: 6174case BoundKind.ArrayAccess: 6175case BoundKind.PointerElementAccess: 6669if (addMethodInvocation.Kind == BoundKind.DynamicInvocation) 6680else if (addMethodInvocation.Kind == BoundKind.Call) 6709Debug.Assert(addMethodInvocation.Kind == BoundKind.BadExpression); 7190case BoundKind.ObjectCreationExpression: 7196case BoundKind.BadExpression: 7933if (boundLeft.Kind == BoundKind.UnboundLambda) 7980case BoundKind.NamespaceExpression: 7990case BoundKind.TypeExpression: 8000case BoundKind.TypeOrValueExpression: 8010if (boundLeft.Kind == BoundKind.Literal && ((BoundLiteral)boundLeft).ConstantValueOpt == ConstantValue.Null) 8200case BoundKind.MethodGroup: 8223case BoundKind.PropertyGroup: 8325bool leftIsBaseReference = boundLeft.Kind == BoundKind.BaseReference; 8432if (boundLeft.HasAnyErrors && boundLeft.Kind != BoundKind.TypeOrValueExpression) 8453else if (boundLeft.Kind == BoundKind.TypeExpression || 8454boundLeft.Kind == BoundKind.BaseReference || 8464else if (boundLeft.Kind == BoundKind.AwaitableValuePlaceholder && boundLeft.Type.IsIAsyncEnumerableType(Compilation)) 8695ReportDiagnosticsIfObsolete(diagnostics, symbol, node, hasBaseReceiver: left.Kind == BoundKind.BaseReference); 9312ReportDiagnosticsIfObsolete(diagnostics, propertySymbol, node, hasBaseReceiver: receiver?.Kind == BoundKind.BaseReference); 9428case BoundKind.PreviousSubmissionReference: 9431case BoundKind.TypeExpression: 9433case BoundKind.QueryClause: 9632if (receiver.Kind == BoundKind.PropertyGroup) 10048if (index.Kind == BoundKind.OutVariablePendingInference) 10052else if (index.Kind == BoundKind.DiscardExpression && !index.HasExpressionType()) 10240LookupOptions lookupOptions = expr.Kind == BoundKind.BaseReference ? LookupOptions.UseBaseReferenceAccessibility : LookupOptions.Default; 10354BoundKind receiverKind = receiver.Kind; 10355if (receiverKind == BoundKind.BaseReference) 10360else if (receiverKind == BoundKind.TypeOrValueExpression) 10496ReportDiagnosticsIfObsolete(diagnostics, property, syntax, hasBaseReceiver: receiver != null && receiver.Kind == BoundKind.BaseReference); 10507if (!gotError && receiver != null && receiver.Kind == BoundKind.ThisReference && receiver.WasCompilerGenerated) 11659if (access.Kind == BoundKind.MethodGroup) 11826if (receiver.Kind == BoundKind.UnboundLambda)
Binder\Binder_Initializers.cs (2)
268if (statement.Kind == BoundKind.LabeledStatement) 271while (labeledStatementBody.Kind == BoundKind.LabeledStatement)
Binder\Binder_Invocation.cs (40)
108if (!allowFieldsAndProperties && (boundExpression.Kind == BoundKind.FieldAccess || boundExpression.Kind == BoundKind.PropertyAccess)) 113if (boundExpression.Kind == BoundKind.FieldAccess) 125Debug.Assert(allowFieldsAndProperties || boundExpression.Kind is (BoundKind.MethodGroup or BoundKind.BadExpression)); 130Debug.Assert(!args.Any(static e => e.Kind == BoundKind.OutVariablePendingInference || 131e.Kind == BoundKind.OutDeconstructVarPendingInference || 132e.Kind == BoundKind.DiscardExpression && !e.HasExpressionType())); 146if (queryClause != null && result.Kind == BoundKind.DynamicInvocation) 162if (boundExpression.Kind == BoundKind.FieldAccess) 247string name = boundExpression.Kind == BoundKind.MethodGroup ? GetName(node.Expression) : null; 281if (argument.Kind == BoundKind.OutVariablePendingInference) 358else if (boundExpression.Kind == BoundKind.MethodGroup) 411if (expression.Kind == BoundKind.MethodGroup) 421case BoundKind.BaseReference: 426case BoundKind.ThisReference: 449case BoundKind.TypeOrValueExpression: 594if (arg.Kind == BoundKind.Lambda || arg.Kind == BoundKind.UnboundLambda) 600else if (arg.Kind == BoundKind.MethodGroup) 606else if (arg.Kind == BoundKind.ArgListOperator) 735Debug.Assert(extensionMemberAccess.Kind != BoundKind.MethodGroup); 1082case BoundKind.Call: 1096else if (call.ReceiverOpt.Kind == BoundKind.BaseReference && this.ContainingType.IsRestrictedType()) 1104case BoundKind.DynamicInvocation: 1117case BoundKind.FunctionPointerInvocation: 1314if (!gotError && method.RequiresInstanceReceiver && receiver != null && receiver.Kind == BoundKind.ThisReference && receiver.WasCompilerGenerated) 1330bool hasBaseReceiver = receiver != null && receiver.Kind == BoundKind.BaseReference; 1964case BoundKind.TypeOrValueExpression: 1990case BoundKind.QueryClause: 2028if ((object)expr != null && expr.Kind != BoundKind.TypeExpression) 2169case BoundKind.UnboundLambda: 2206case BoundKind.OutVariablePendingInference: 2207case BoundKind.DiscardExpression: 2215if (argument.Kind == BoundKind.OutVariablePendingInference) 2226else if (argument.Kind == BoundKind.DiscardExpression) 2240case BoundKind.OutDeconstructVarPendingInference: 2245case BoundKind.Parameter: 2246case BoundKind.Local: 2334var originalMethods = (expr.Kind == BoundKind.MethodGroup) ? ((BoundMethodGroup)expr).Methods : ImmutableArray<MethodSymbol>.Empty;
Binder\Binder_Operators.cs (43)
43if (left.Kind == BoundKind.EventAccess) 111if (left.Kind == BoundKind.EventAccess && !CheckEventValueKind((BoundEventAccess)left, BindValueKind.Assignable, diagnostics)) 312Debug.Assert(left.Kind != BoundKind.EventAccess || hasError); 907if (result.Kind == BoundKind.TypeExpression 912else if (result.Kind == BoundKind.BadExpression) 1335case (BoundKind.DefaultLiteral, _) when !isEquality: 1336case (_, BoundKind.DefaultLiteral) when !isEquality: 1340case (BoundKind.DefaultLiteral, BoundKind.DefaultLiteral): 1343case (BoundKind.DefaultLiteral, _) when right.Type is TypeParameterSymbol: 1347case (_, BoundKind.DefaultLiteral) when left.Type is TypeParameterSymbol: 1351case (BoundKind.UnconvertedObjectCreationExpression, _): 1354case (_, BoundKind.UnconvertedObjectCreationExpression): 2917if (left.Kind == BoundKind.Conversion && right.Kind == BoundKind.Conversion) 4037case BoundKind.NamespaceExpression: 4038case BoundKind.TypeExpression: 4166BoundKind exprKind = expr.Kind; 4169case BoundKind.FieldAccess: 4170case BoundKind.EventAccess: 4174if (exprKind == BoundKind.FieldAccess) 4216case BoundKind.InlineArrayAccess: 4228case BoundKind.RangeVariable: 4236case BoundKind.Parameter: 4259case BoundKind.ThisReference: 4260case BoundKind.BaseReference: 4265case BoundKind.Local: 4275case BoundKind.PointerIndirectionOperator: //Covers ->, since the receiver will be one of these. 4276case BoundKind.ConvertedStackAllocExpression: 4280case BoundKind.PointerElementAccess: 4295case BoundKind.PropertyAccess: // Never fixed 4296case BoundKind.IndexerAccess: // Never fixed 4762case BoundKind.UnboundLambda: 4763case BoundKind.Lambda: 4764case BoundKind.MethodGroup: // New in Roslyn - see DevDiv #864740. 4892operand.Kind == BoundKind.MethodGroup || 5310case BoundKind.UnboundLambda: 5311case BoundKind.Lambda: 5312case BoundKind.MethodGroup: // New in Roslyn - see DevDiv #864740. 5321case BoundKind.TupleLiteral: 5322case BoundKind.ConvertedTupleLiteral: 5621if (leftOperand.Kind == BoundKind.UnboundLambda || leftOperand.Kind == BoundKind.MethodGroup)
Binder\Binder_Patterns.cs (11)
520wasExpression = expression.Kind != BoundKind.TypeExpression; 527Debug.Assert(expression is { Kind: BoundKind.TypeExpression, Type: { } }); 549wasExpression = expression.Kind switch { BoundKind.BadExpression => false, BoundKind.TypeExpression => false, _ => true }; 698if (convertedExpression.Kind == BoundKind.Conversion) 1577if (boundMember.Kind == BoundKind.PropertyGroup) 1587case BoundKind.FieldAccess: 1588case BoundKind.PropertyAccess: 1591case BoundKind.IndexerAccess: 1592case BoundKind.DynamicIndexerAccess: 1593case BoundKind.EventAccess:
Binder\Binder_Query.cs (7)
929while (ultimateReceiver.Kind == BoundKind.QueryClause) 936Debug.Assert(ultimateReceiver.Kind != BoundKind.MethodGroup || ultimateReceiver.HasAnyErrors); 954else if (ultimateReceiver.Kind == BoundKind.NamespaceExpression) 958else if (ultimateReceiver.Kind == BoundKind.Lambda || ultimateReceiver.Kind == BoundKind.UnboundLambda) 966else if (ultimateReceiver.Kind == BoundKind.TypeExpression) 974else if (ultimateReceiver.Kind == BoundKind.TypeOrValueExpression)
Binder\Binder_QueryErrors.cs (1)
220if (arg.Kind == BoundKind.UnboundLambda)
Binder\Binder_Statements.cs (39)
152(result.Kind == BoundKind.Block && 899BoundExpression expression = value.Kind is BoundKind.UnboundLambda or BoundKind.MethodGroup ? 1252case BoundKind.AddressOfOperator: 1256case BoundKind.FieldAccess: 1434bool discardAssignment = op1.Kind == BoundKind.DiscardExpression; 1513if (op1.Kind != BoundKind.DynamicIndexerAccess && 1514op1.Kind != BoundKind.DynamicMemberAccess && 1515op1.Kind != BoundKind.DynamicObjectInitializerMember) 1531if ((op1.Kind == BoundKind.EventAccess) && 1588else if (op1.Kind is BoundKind.Local or BoundKind.Parameter) 1601Debug.Assert(op1.Kind != BoundKind.Parameter); // If the assert fails, add a corresponding test. 1678case BoundKind.PropertyAccess: 1685case BoundKind.IndexerAccess: 1692case BoundKind.ImplicitIndexerAccess: 1817(propertyIsStatic || receiver?.Kind == BoundKind.ThisReference); 1852else if (receiver.Kind == BoundKind.BaseReference) 1978if (expression.HasAnyErrors && expression.Kind != BoundKind.UnboundLambda) 2368case BoundKind.BadExpression: 2372case BoundKind.UnboundLambda: 2377case BoundKind.TupleLiteral: 2401case BoundKind.MethodGroup: 2406case BoundKind.UnconvertedAddressOfOperator: 2411case BoundKind.Literal: 2428case BoundKind.StackAllocArrayCreation: 2434case BoundKind.UnconvertedSwitchExpression: 2447case BoundKind.UnconvertedCollectionExpression: 2452case BoundKind.AddressOfOperator when targetType.IsFunctionPointer(): 2457case BoundKind.UnconvertedConditionalOperator: 2486Debug.Assert(operand.HasAnyErrors && operand.Kind != BoundKind.UnboundLambda, "Missing a case in implicit conversion error reporting"); 2729if (expr.Kind == BoundKind.AssignmentOperator) 2732if (assignment.Right.Kind == BoundKind.Literal && assignment.Right.ConstantValueOpt.Discriminator == ConstantValueTypeDiscriminator.Boolean) 3210if (!argument.HasAnyErrors || argument.Kind == BoundKind.UnboundLambda) 3501if (expression.Kind == BoundKind.DelegateCreationExpression || expression.Kind == BoundKind.NameOfOperator) 3529if ((refKind != RefKind.None) != (returnRefKind != RefKind.None) && expression.Kind != BoundKind.ThrowExpression) 4187if (boundAccess.Kind != BoundKind.MethodGroup) 4215if (patternMethodCall.Kind != BoundKind.Call)
Binder\Binder_TupleOperators.cs (2)
224Debug.Assert((object)left.Type != null || left.Kind == BoundKind.TupleLiteral); 225Debug.Assert((object)right.Type != null || right.Kind == BoundKind.TupleLiteral);
Binder\DecisionDagBuilder.cs (3)
3623if (RemainingTests[0] is One { Test: { Kind: BoundKind.DagNonNullTest } planA }) 3630case One { Test: { Kind: BoundKind.DagTypeTest } planB1 }: 3637case One { Test: { Kind: BoundKind.DagValueTest } planB2 }:
Binder\DecisionDagBuilder_ListPatterns.cs (1)
19list.Subpatterns.Count(p => p.Kind == BoundKind.SlicePattern) == (list.HasSlice ? 1 : 0) &&
Binder\ForEachLoopBinder.cs (1)
410if (iterationErrorExpression.Kind == BoundKind.DiscardExpression)
Binder\ForLoopBinder.cs (2)
108Debug.Assert(increment.Kind != BoundKind.StatementList || ((BoundStatementList)increment).Statements.Length > 1); 113if (increment.Kind == BoundKind.StatementList)
Binder\LockOrUsingBinder.cs (2)
61case BoundKind.Local: 64case BoundKind.Parameter:
Binder\RefSafetyAnalysis.cs (1)
602if (node.Left.Kind != BoundKind.DiscardExpression)
Binder\Semantics\Conversions\ConversionsBase.cs (16)
1061case BoundKind.Literal: 1069case BoundKind.DefaultLiteral: 1072case BoundKind.ExpressionWithNullability: 1082case BoundKind.TupleLiteral: 1090case BoundKind.UnboundLambda: 1097case BoundKind.MethodGroup: 1105case BoundKind.UnconvertedInterpolatedString: 1106case BoundKind.BinaryOperator when ((BoundBinaryOperator)sourceExpression).IsUnconvertedInterpolatedStringAddition: 1113case BoundKind.StackAllocArrayCreation: 1121case BoundKind.UnconvertedAddressOfOperator when destination is FunctionPointerTypeSymbol funcPtrType: 1129case BoundKind.ThrowExpression: 1132case BoundKind.UnconvertedObjectCreationExpression: 1135case BoundKind.UnconvertedCollectionExpression: 1410if (sourceExpression.Kind == BoundKind.TupleLiteral) 1646if (source.Kind != BoundKind.UnboundLambda) 1949if (sourceExpressionOpt?.Kind == BoundKind.TupleLiteral)
Binder\Semantics\Operators\BinaryOperatorOverloadResolution.cs (1)
469&& nonDelegate.Kind == BoundKind.UnboundLambda)
Binder\Semantics\OverloadResolution\MethodGroup.cs (1)
117if (this.Receiver.Kind == BoundKind.TypeExpression)
Binder\Semantics\OverloadResolution\MethodTypeInference.cs (17)
637if (argument.Kind == BoundKind.UnboundLambda && target.Type.GetDelegateType() is { }) 642else if (argument.Kind == BoundKind.UnconvertedCollectionExpression) 646else if (argument.Kind != BoundKind.TupleLiteral || 879if (argument.Kind == BoundKind.TupleLiteral && (object)argument.Type == null) 883else if (argument.Kind == BoundKind.UnconvertedCollectionExpression) 1023if ((isFunctionPointer && argument.Kind != BoundKind.UnconvertedAddressOfOperator) || 1024(!isFunctionPointer && argument.Kind is not (BoundKind.UnboundLambda or BoundKind.MethodGroup))) 1079if ((isFunctionPointer && argument.Kind != BoundKind.UnconvertedAddressOfOperator) || 1080(!isFunctionPointer && argument.Kind is not (BoundKind.UnboundLambda or BoundKind.MethodGroup))) 1448if (source.Kind is not (BoundKind.MethodGroup or BoundKind.UnconvertedAddressOfOperator)) 1459if (delegateOrFunctionPointerType.IsFunctionPointer() != (source.Kind == BoundKind.UnconvertedAddressOfOperator)) 1559if (source.Kind != BoundKind.UnboundLambda) 1613if (source.Kind != BoundKind.UnboundLambda) 3091if (source.Kind != BoundKind.UnboundLambda)
Binder\Semantics\OverloadResolution\OverloadResolution.cs (18)
2173var argumentKind = arguments[i].Kind; 2177if (argumentKind == BoundKind.ArgListOperator) 2315var argumentKind = arguments[i].Kind; 2319if (argumentKind == BoundKind.ArgListOperator) 2479if (arguments[i].Kind == BoundKind.ArgListOperator) 2625if (arguments[i].Kind != BoundKind.ArgListOperator) 2952var nodeKind = node.Kind; 2953if (nodeKind == BoundKind.OutVariablePendingInference || 2954nodeKind == BoundKind.OutDeconstructVarPendingInference || 2955(nodeKind == BoundKind.DiscardExpression && !node.HasExpressionType())) 3275if (node.Kind == BoundKind.TupleLiteral) 3291if (node.Kind == BoundKind.UnboundLambda && 3331if (lambda.Body.Statements[0].Kind == BoundKind.ReturnStatement) 3607if (node?.Kind == BoundKind.MethodGroup) 4557if (argument.Kind == BoundKind.ArgListOperator) 4732if (argument.Kind == BoundKind.OutVariablePendingInference || 4733argument.Kind == BoundKind.OutDeconstructVarPendingInference || 4734(argument.Kind == BoundKind.DiscardExpression && (object)argType == null))
Binder\Semantics\OverloadResolution\OverloadResolutionResult.cs (13)
682if (receiverOpt?.Kind == BoundKind.QueryClause) 1109if (argument.Kind == BoundKind.UnboundLambda) 1249argument.Kind != BoundKind.OutDeconstructVarPendingInference && 1250argument.Kind != BoundKind.OutVariablePendingInference && 1251argument.Kind != BoundKind.DiscardExpression) 1257if (argument.Kind == BoundKind.UnboundLambda && refArg == refParameter) 1261else if (argument.Kind == BoundKind.MethodGroup && parameterType.TypeKind == TypeKind.Delegate && 1266else if (argument.Kind == BoundKind.MethodGroup && parameterType.TypeKind == TypeKind.FunctionPointer) 1270else if (argument.Kind == BoundKind.UnconvertedAddressOfOperator && 1275else if (argument.Kind == BoundKind.UnconvertedCollectionExpression) 1340Debug.Assert(argument.Kind != BoundKind.OutDeconstructVarPendingInference); 1341Debug.Assert(argument.Kind != BoundKind.OutVariablePendingInference); 1342Debug.Assert(argument.Kind != BoundKind.DiscardExpression || argument.HasExpressionType());
BoundTree\BoundExpression.cs (15)
61if ((Kind != BoundKind.Local && Kind != BoundKind.Parameter) || this.WasConverted) 81case BoundKind.TupleLiteral: 82case BoundKind.UnconvertedSwitchExpression: 83case BoundKind.UnconvertedObjectCreationExpression: 84case BoundKind.UnconvertedConditionalOperator: 85case BoundKind.DefaultLiteral: 86case BoundKind.UnconvertedInterpolatedString: 87case BoundKind.UnconvertedCollectionExpression: 89case BoundKind.StackAllocArrayCreation: 94case BoundKind.BinaryOperator: 97case BoundKind.Local when !WasConverted: 98case BoundKind.Parameter when !WasConverted: 623return this.Condition.Kind == BoundKind.UnaryOperator && ((BoundUnaryOperator)this.Condition).OperatorKind.IsDynamic(); 689if (argument.Kind == BoundKind.TupleLiteral)
BoundTree\BoundExpressionExtensions.cs (22)
24case BoundKind.Local: 27case BoundKind.Parameter: 30case BoundKind.FieldAccess: 33case BoundKind.Call: 36case BoundKind.PropertyAccess: 39case BoundKind.IndexerAccess: 42case BoundKind.ImplicitIndexerAccess: 45case BoundKind.InlineArrayAccess: 63case BoundKind.ObjectInitializerMember: 83return node is { Kind: BoundKind.Literal, ConstantValueOpt: { Discriminator: ConstantValueTypeDiscriminator.Null } }; 88return node.Kind == BoundKind.DefaultLiteral; 93return node.Kind == BoundKind.UnconvertedObjectCreationExpression; 109if (node.Kind == BoundKind.DefaultExpression || node.Kind == BoundKind.DefaultLiteral) 137Debug.Assert(expr.Kind is BoundKind.MethodGroup or BoundKind.UnboundLambda); 182case BoundKind.MethodGroup: 196case BoundKind.BadExpression: 204case BoundKind.DelegateCreationExpression: 213case BoundKind.Call: 227case BoundKind.IndexerAccess: 254case BoundKind.Conversion:
BoundTree\BoundMethodGroup.cs (1)
61if (this.ReceiverOpt == null || this.ReceiverOpt.Kind == BoundKind.TypeExpression)
BoundTree\BoundNode.cs (7)
17private readonly BoundKind _kind; 73protected BoundNode(BoundKind kind, SyntaxNode syntax) 76kind == BoundKind.SequencePoint || 77kind == BoundKind.SequencePointExpression || 78kind == (BoundKind)byte.MaxValue || // used in SpillSequenceSpiller 85protected BoundNode(BoundKind kind, SyntaxNode syntax, bool hasErrors) 377public BoundKind Kind
BoundTree\BoundNodeExtensions.cs (5)
42if (statement!.Kind == BoundKind.ExpressionStatement) 45if (expression.Kind == BoundKind.Sequence && ((BoundSequence)expression).SideEffects.IsDefaultOrEmpty) 51return expression.Kind == BoundKind.Call && ((BoundCall)expression).IsConstructorInitializer(); 64(receiverOpt.Kind == BoundKind.ThisReference || receiverOpt.Kind == BoundKind.BaseReference);
BoundTree\BoundStatementExtensions.cs (6)
18case BoundKind.LabelStatement: 19case BoundKind.LabeledStatement: 20case BoundKind.SwitchSection: 34case BoundKind.LabelStatement: 38case BoundKind.LabeledStatement: 42case BoundKind.SwitchSection:
BoundTree\BoundTreeRewriter.cs (4)
250if (child.Kind != BoundKind.BinaryOperator) 265if (child.Kind != BoundKind.BinaryOperator) 344if (child.Kind != BoundKind.BinaryPattern) 359if (child.Kind != BoundKind.BinaryPattern)
BoundTree\BoundTreeVisitors.cs (48)
33case BoundKind.TypeExpression: 35case BoundKind.NamespaceExpression: 37case BoundKind.UnaryOperator: 39case BoundKind.IncrementOperator: 41case BoundKind.BinaryOperator: 43case BoundKind.CompoundAssignmentOperator: 45case BoundKind.AssignmentOperator: 47case BoundKind.NullCoalescingOperator: 49case BoundKind.ConditionalOperator: 51case BoundKind.ArrayAccess: 53case BoundKind.TypeOfOperator: 55case BoundKind.DefaultLiteral: 57case BoundKind.DefaultExpression: 59case BoundKind.IsOperator: 61case BoundKind.AsOperator: 63case BoundKind.Conversion: 65case BoundKind.SequencePointExpression: 67case BoundKind.SequencePoint: 69case BoundKind.SequencePointWithSpan: 71case BoundKind.Block: 73case BoundKind.LocalDeclaration: 75case BoundKind.MultipleLocalDeclarations: 77case BoundKind.Sequence: 79case BoundKind.NoOpStatement: 81case BoundKind.ReturnStatement: 83case BoundKind.ThrowStatement: 85case BoundKind.ExpressionStatement: 87case BoundKind.BreakStatement: 89case BoundKind.ContinueStatement: 91case BoundKind.IfStatement: 93case BoundKind.ForEachStatement: 95case BoundKind.TryStatement: 97case BoundKind.Literal: 99case BoundKind.ThisReference: 101case BoundKind.Local: 103case BoundKind.Parameter: 105case BoundKind.LabelStatement: 107case BoundKind.GotoStatement: 109case BoundKind.LabeledStatement: 111case BoundKind.StatementList: 113case BoundKind.ConditionalGoto: 115case BoundKind.Call: 117case BoundKind.ObjectCreationExpression: 119case BoundKind.DelegateCreationExpression: 121case BoundKind.FieldAccess: 123case BoundKind.PropertyAccess: 125case BoundKind.Lambda: 127case BoundKind.NameOfOperator:
BoundTree\BoundTreeWalker.cs (2)
121while (current.Kind == BoundKind.BinaryOperator) 159while (current.Kind == BoundKind.BinaryPattern)
BoundTree\Constructors.cs (3)
71case BoundKind.FieldAccess: 74case BoundKind.Local: 213Debug.Assert(method is ErrorMethodSymbol || arguments[i].Kind == BoundKind.ArgListOperator);
BoundTree\Expression.cs (2)
170(this.Kind == BoundKind.StatementList || this.Kind == BoundKind.Scope) ? StaticCast<BoundNode?>.From(this.Statements) : ImmutableArray<BoundNode?>.Empty;
CodeGen\CodeGenerator_HasHome.cs (17)
53case BoundKind.ArrayAccess: 63case BoundKind.PointerIndirectionOperator: 64case BoundKind.RefValueOperator: 67case BoundKind.ThisReference: 82case BoundKind.ThrowExpression: 86case BoundKind.Parameter: 90case BoundKind.Local: 97case BoundKind.Call: 102case BoundKind.Dup: 108case BoundKind.FieldAccess: 111case BoundKind.Sequence: 114case BoundKind.AssignmentOperator: 124case BoundKind.ComplexConditionalReceiver: 137goto case BoundKind.ConditionalReceiver; 139case BoundKind.ConditionalReceiver: 144case BoundKind.ConditionalOperator: 257fieldAccess.ReceiverOpt.Kind == BoundKind.ThisReference;
CodeGen\EmitAddress.cs (25)
28case BoundKind.RefValueOperator: 32case BoundKind.Local: 35case BoundKind.Dup: 39case BoundKind.ConditionalReceiver: 45case BoundKind.ComplexConditionalReceiver: 49case BoundKind.Parameter: 52case BoundKind.FieldAccess: 55case BoundKind.ArrayAccess: 64case BoundKind.ThisReference: 85case BoundKind.PreviousSubmissionReference: 89case BoundKind.BaseReference: 93case BoundKind.PassByCopy: 96case BoundKind.Sequence: 99case BoundKind.PointerIndirectionOperator: 106case BoundKind.PseudoVariable: 110case BoundKind.Call: 121case BoundKind.FunctionPointerInvocation: 133case BoundKind.DefaultExpression: 143case BoundKind.ConditionalOperator: 152case BoundKind.AssignmentOperator: 164case BoundKind.ThrowExpression: 355case BoundKind.Local: 364case BoundKind.Sequence: 367case BoundKind.FieldAccess: 522if (receiver.Kind != BoundKind.ConditionalReceiver)
CodeGen\EmitArrayInitializer.cs (4)
347if (inits[0].Kind == BoundKind.ArrayInitialization) 369Debug.Assert(inits.All((init) => init.Kind != BoundKind.ArrayInitialization) || 370inits.All((init) => init.Kind == BoundKind.ArrayInitialization), 373return inits.Length != 0 && inits[0].Kind == BoundKind.ArrayInitialization;
CodeGen\EmitExpression.cs (145)
98case BoundKind.AssignmentOperator: 102case BoundKind.Call: 106case BoundKind.ObjectCreationExpression: 110case BoundKind.DelegateCreationExpression: 114case BoundKind.ArrayCreation: 118case BoundKind.ConvertedStackAllocExpression: 122case BoundKind.ReadOnlySpanFromArray: 126case BoundKind.Conversion: 130case BoundKind.Local: 134case BoundKind.Dup: 138case BoundKind.PassByCopy: 142case BoundKind.Parameter: 149case BoundKind.FieldAccess: 153case BoundKind.ArrayAccess: 157case BoundKind.RefArrayAccess: 161case BoundKind.ArrayLength: 165case BoundKind.ThisReference: 172case BoundKind.PreviousSubmissionReference: 176case BoundKind.BaseReference: 189case BoundKind.Sequence: 193case BoundKind.SequencePointExpression: 197case BoundKind.UnaryOperator: 201case BoundKind.BinaryOperator: 205case BoundKind.NullCoalescingOperator: 209case BoundKind.IsOperator: 213case BoundKind.AsOperator: 217case BoundKind.DefaultExpression: 221case BoundKind.TypeOfOperator: 228case BoundKind.SizeOfOperator: 235case BoundKind.ModuleVersionId: 240case BoundKind.ModuleVersionIdString: 245case BoundKind.ThrowIfModuleCancellationRequested: 250case BoundKind.ModuleCancellationTokenExpression: 255case BoundKind.InstrumentationPayloadRoot: 260case BoundKind.MethodDefIndex: 265case BoundKind.MaximumMethodDefIndex: 270case BoundKind.SourceDocumentIndex: 275case BoundKind.LocalId: 280case BoundKind.ParameterId: 285case BoundKind.MethodInfo: 292case BoundKind.FieldInfo: 299case BoundKind.ConditionalOperator: 303case BoundKind.AddressOfOperator: 307case BoundKind.PointerIndirectionOperator: 311case BoundKind.ArgList: 315case BoundKind.ArgListOperator: 320case BoundKind.RefTypeOperator: 324case BoundKind.MakeRefOperator: 328case BoundKind.RefValueOperator: 332case BoundKind.LoweredConditionalAccess: 336case BoundKind.ConditionalReceiver: 340case BoundKind.ComplexConditionalReceiver: 344case BoundKind.PseudoVariable: 348case BoundKind.ThrowExpression: 352case BoundKind.FunctionPointerInvocation: 356case BoundKind.FunctionPointerLoad: 362Debug.Assert(expression.Kind != BoundKind.BadExpression); 444(receiver.Kind == BoundKind.Local && IsStackLocal(((BoundLocal)receiver).LocalSymbol)) || 870Debug.Assert(sequence.Value.Kind != BoundKind.TypeExpression || !used); 871if (sequence.Value.Kind != BoundKind.TypeExpression) 1013Debug.Assert(arguments[i].Kind == BoundKind.ArgListOperator); 1242else if (receiver.Kind == BoundKind.Conversion) 1253else if (receiver.Kind == BoundKind.FieldAccess) 1284if (receiver.Kind == BoundKind.Conversion && ((BoundConversion)receiver).ConversionKind == ConversionKind.Unboxing) 1297case BoundKind.Parameter: 1301case BoundKind.Local: 1305case BoundKind.Sequence: 1308case BoundKind.FieldAccess: 1527Debug.Assert(receiver.Kind != BoundKind.BaseReference, "base should always use call"); 1538case BoundKind.ArrayCreation: 1541case BoundKind.ObjectCreationExpression: 1546case BoundKind.Conversion: 1566case BoundKind.ThisReference: 1573case BoundKind.FieldAccess: 1577case BoundKind.Local: 1581case BoundKind.DelegateCreationExpression: 1584case BoundKind.Sequence: 1588case BoundKind.AssignmentOperator: 1592case BoundKind.TypeOfOperator: 1595case BoundKind.ConditionalReceiver: 1611case BoundKind.ThisReference: 1614case BoundKind.Sequence: 1657Debug.Assert(receiver.Kind == BoundKind.ThisReference); 2163case BoundKind.TypeExpression: 2164case BoundKind.Parameter: 2165case BoundKind.Local: 2166case BoundKind.ThisReference: 2168case BoundKind.FieldAccess: 2179case BoundKind.PassByCopy: 2182case BoundKind.BinaryOperator: 2195case BoundKind.Conversion: 2244case BoundKind.Local: 2247case BoundKind.Parameter: 2250case BoundKind.Call: 2253case BoundKind.FunctionPointerInvocation: 2256case BoundKind.Dup: 2259case BoundKind.Sequence: 2656if (objCreation.Arguments.Length > 0 && objCreation.Arguments[0].Kind == BoundKind.ConvertedStackAllocExpression) 2690if (left.Kind == BoundKind.ArrayAccess && left.Type.TypeKind == TypeKind.TypeParameter && !left.Type.IsValueType) 2695if (left.Kind == BoundKind.FieldAccess) 2799case BoundKind.Parameter: 2802case BoundKind.Local: 2818case BoundKind.RefValueOperator: 2822case BoundKind.FieldAccess: 2840case BoundKind.Parameter: 2852case BoundKind.Local: 2904case BoundKind.ArrayAccess: 2913case BoundKind.ThisReference: 2924case BoundKind.Dup: 2935case BoundKind.ConditionalOperator: 2947case BoundKind.PointerIndirectionOperator: 2957case BoundKind.Sequence: 2970case BoundKind.Call: 2981case BoundKind.FunctionPointerInvocation: 2992case BoundKind.PropertyAccess: 2993case BoundKind.IndexerAccess: 2995case BoundKind.PreviousSubmissionReference: 2999case BoundKind.PseudoVariable: 3004case BoundKind.ModuleVersionId: 3005case BoundKind.InstrumentationPayloadRoot: 3008case BoundKind.AssignmentOperator: 3047Debug.Assert(lhs.Kind != BoundKind.Parameter || exprTempsAfter <= exprTempsBefore); 3049if (lhs.Kind == BoundKind.Local && ((BoundLocal)lhs).LocalSymbol.SynthesizedKind.IsLongLived()) 3107case BoundKind.FieldAccess: 3111case BoundKind.Local: 3138case BoundKind.ArrayAccess: 3144case BoundKind.ThisReference: 3148case BoundKind.Parameter: 3152case BoundKind.Dup: 3157case BoundKind.ConditionalOperator: 3162case BoundKind.RefValueOperator: 3163case BoundKind.PointerIndirectionOperator: 3164case BoundKind.PseudoVariable: 3168case BoundKind.Sequence: 3175case BoundKind.Call: 3180case BoundKind.FunctionPointerInvocation: 3185case BoundKind.ModuleVersionId: 3189case BoundKind.InstrumentationPayloadRoot: 3193case BoundKind.AssignmentOperator: 3202case BoundKind.PreviousSubmissionReference: 3960case BoundKind.Conversion: 3974case BoundKind.AssignmentOperator: 3978case BoundKind.Sequence: 3982case BoundKind.Local: 3991case BoundKind.Dup:
CodeGen\EmitOperators.cs (3)
94if (child.Kind != BoundKind.BinaryOperator || child.ConstantValueOpt != null) 118if (child.Kind != BoundKind.BinaryOperator || child.ConstantValueOpt != null) 507if (condition.Kind == BoundKind.BinaryOperator)
CodeGen\EmitStatement.cs (31)
31case BoundKind.Block: 35case BoundKind.Scope: 39case BoundKind.SequencePoint: 43case BoundKind.SequencePointWithSpan: 47case BoundKind.SavePreviousSequencePoint: 51case BoundKind.RestorePreviousSequencePoint: 55case BoundKind.StepThroughSequencePoint: 59case BoundKind.ExpressionStatement: 63case BoundKind.StatementList: 67case BoundKind.ReturnStatement: 71case BoundKind.GotoStatement: 75case BoundKind.LabelStatement: 79case BoundKind.ConditionalGoto: 83case BoundKind.ThrowStatement: 87case BoundKind.TryStatement: 91case BoundKind.SwitchDispatch: 95case BoundKind.StateMachineScope: 99case BoundKind.NoOpStatement: 418case BoundKind.BinaryOperator: 526case BoundKind.LoweredConditionalAccess: 536(receiver.Kind == BoundKind.Local && IsStackLocal(((BoundLocal)receiver).LocalSymbol)) || 575case BoundKind.UnaryOperator: 585case BoundKind.IsOperator: 602case BoundKind.Sequence: 1158while (exceptionSource.Kind == BoundKind.Sequence) 1168case BoundKind.Local: 1178case BoundKind.FieldAccess: 1291if (expression.Kind == BoundKind.Sequence) 1299if (expression.Kind == BoundKind.SequencePointExpression) 1308case BoundKind.Local: 1317case BoundKind.Parameter:
CodeGen\Optimizer.cs (34)
450Debug.Assert(expr.Kind != BoundKind.Label); 761if (value != null && value.Kind == BoundKind.Local && ((BoundLocal)value).LocalSymbol == local) 769if (lastSideeffect.Kind == BoundKind.AssignmentOperator) 773assignment.Right.Kind == BoundKind.Sequence) 949bool mayPushReceiver = (right.Kind == BoundKind.ObjectCreationExpression && 995assignmentLocal.Type.IsPointerOrFunctionPointer() && right.Kind == BoundKind.Conversion && 1040(lhs.Kind is BoundKind.Local or BoundKind.Parameter or BoundKind.FieldAccess && lhs.GetRefKind() != RefKind.None), 1045case BoundKind.ThisReference: 1049case BoundKind.Parameter: 1057case BoundKind.Local: 1065case BoundKind.Call: 1069case BoundKind.FunctionPointerInvocation: 1073case BoundKind.ConditionalOperator: 1077case BoundKind.AssignmentOperator: 1081case BoundKind.Sequence: 1086case BoundKind.RefValueOperator: 1087case BoundKind.PointerIndirectionOperator: 1088case BoundKind.PseudoVariable: 1091case BoundKind.ModuleVersionId: 1092case BoundKind.InstrumentationPayloadRoot: 1094goto case BoundKind.FieldAccess; 1096case BoundKind.FieldAccess: 1097case BoundKind.ArrayAccess: 1109if (lhs.Kind == BoundKind.FieldAccess) 1434if (boundExpression.Kind == BoundKind.Local) 1486if (child.Kind != BoundKind.BinaryOperator || child.ConstantValueOpt != null) 1502if (child.Kind != BoundKind.BinaryOperator || child.ConstantValueOpt != null) 1708if (exceptionSourceOpt.Kind == BoundKind.Local) 1947top.Item1.Kind == BoundKind.Local && 2129if (child.Kind != BoundKind.BinaryOperator || child.ConstantValueOpt != null) 2145if (child.Kind != BoundKind.BinaryOperator || child.ConstantValueOpt != null) 2358if (exceptionSource.Kind == BoundKind.Local)
Compilation\CSharpSemanticModel.cs (56)
2096var highestBoundExprKind = highestBoundExpr?.Kind ?? BoundKind.NoOpStatement; 2101if (highestBoundExprKind == BoundKind.Lambda) // the enclosing conversion is explicit 2117if (tupleLiteralConversion.Operand.Kind == BoundKind.ConvertedTupleLiteral) 2131else if (highestBoundExprKind == BoundKind.FixedLocalCollectionInitializer) 2202if (highestBoundExprKind != BoundKind.Conversion) 2206else if (((BoundConversion)highestBoundExpr).Operand.Kind != BoundKind.Conversion) 2224else if (boundNodeForSyntacticParent?.Kind == BoundKind.DelegateCreationExpression) 2231case BoundKind.MethodGroup: 2236case BoundKind.Lambda: 2242case BoundKind.UnboundLambda: 2311if (boundExpr != null && boundExpr.Kind != BoundKind.TypeExpression) 3368case BoundKind.MethodGroup: 3372case BoundKind.PropertyGroup: 3377case BoundKind.BadExpression: 3400case BoundKind.DelegateCreationExpression: 3403case BoundKind.TypeExpression: 3411boundNodeForSyntacticParent.Kind == BoundKind.BadExpression && 3433case BoundKind.TypeOrValueExpression: 3443case BoundKind.Call: 3468case BoundKind.FunctionPointerInvocation: 3476case BoundKind.UnconvertedAddressOfOperator: 3490case BoundKind.IndexerAccess: 3504case BoundKind.ImplicitIndexerAccess: 3508case BoundKind.EventAssignmentOperator: 3525case BoundKind.EventAccess when boundNodeForSyntacticParent is BoundEventAssignmentOperator { ResultKind: LookupResultKind.Viable } parentOperator && 3536case BoundKind.Conversion: 3559case BoundKind.BinaryOperator: 3563case BoundKind.UnaryOperator: 3567case BoundKind.UserDefinedConditionalLogicalOperator: 3573case BoundKind.CompoundAssignmentOperator: 3577case BoundKind.IncrementOperator: 3581case BoundKind.AwaitExpression: 3586case BoundKind.ConditionalOperator: 3592case BoundKind.Attribute: 3627case BoundKind.QueryClause: 3638case BoundKind.DynamicInvocation: 3646case BoundKind.DynamicCollectionElementInitializer: 3654case BoundKind.DynamicIndexerAccess: 3662case BoundKind.DynamicMemberAccess: 3667case BoundKind.DynamicObjectCreationExpression: 3674case BoundKind.ObjectCreationExpression: 3691case BoundKind.ThisReference: 3692case BoundKind.BaseReference: 3703case BoundKind.FromEndIndexExpression: 3713case BoundKind.RangeExpression: 4000case BoundKind.Attribute: 4014case BoundKind.BadExpression: 4279case BoundKind.Call: 4300case BoundKind.DelegateCreationExpression: 4310case BoundKind.Conversion: 4342case BoundKind.DynamicInvocation: 4348case BoundKind.BadExpression: 4359case BoundKind.NameOfOperator: 4428case BoundKind.IndexerAccess: 4449case BoundKind.BadExpression:
Compilation\MemberSemanticModel.cs (12)
1239Debug.Assert(highestBoundNode.Kind != BoundKind.UnboundLambda); 1783case BoundKind.UnboundLambda: 1785goto case BoundKind.Lambda; 1786case BoundKind.Lambda: 1790case BoundKind.QueryClause: 1812case BoundKind.QueryClause: 1816case BoundKind.Call: 1828while (receiver?.Kind == BoundKind.MethodGroup) 1845case BoundKind.Conversion: 1848case BoundKind.UnboundLambda: 1852case BoundKind.Lambda: 1895if (expr.Kind == BoundKind.QueryClause)
Compilation\MemberSemanticModel.NodeMapBuilder.cs (5)
93if (existing[i].Kind == BoundKind.TypeExpression && nodesToAdd[i].Kind == BoundKind.TypeOrValueExpression) 101else if (existing[i].Kind == BoundKind.TypeOrValueExpression && nodesToAdd[i].Kind == BoundKind.TypeExpression) 169if (node.Kind == BoundKind.UnboundLambda)
Compiler\MethodBodySynthesizer.Lowered.cs (1)
333if (body.Kind != BoundKind.Block) body = F.Block(body);
Compiler\MethodCompiler.cs (5)
623(init.Kind == BoundKind.FieldEqualsValue) && !((BoundFieldEqualsValue)init).Field.IsMetadataConstant)); 1342if (processedInitializers.LoweredInitializers.Kind == BoundKind.StatementList) 2000case BoundKind.ConstructorMethodBody: 2030case BoundKind.NonConstructorMethodBody: 2036case BoundKind.Block:
FlowAnalysis\AbstractFlowPass.cs (25)
556case BoundKind.Parameter: 560case BoundKind.Local: 564case BoundKind.ThisReference: 565case BoundKind.BaseReference: 568case BoundKind.PropertyAccess: 585case BoundKind.FieldAccess: 592case BoundKind.EventAccess: 599case BoundKind.TupleLiteral: 600case BoundKind.ConvertedTupleLiteral: 604case BoundKind.InlineArrayAccess: 849case BoundKind.LabeledStatement: 855case BoundKind.LabelStatement: 861case BoundKind.SwitchSection: 1870if (pend.Branch.Kind != BoundKind.YieldReturnStatement) 2132if (expr.Kind != BoundKind.PropertyAccess) 2165var refKind = node.Left.Kind == BoundKind.BadExpression 2246receiverOpt.Kind != BoundKind.TypeExpression && 2427var childKind = child.Kind; 2429if (childKind == BoundKind.BinaryOperator) 2442else if (childKind == BoundKind.UserDefinedConditionalLogicalOperator) 2469case BoundKind.BinaryOperator: 2473case BoundKind.UserDefinedConditionalLogicalOperator: 2489case BoundKind.BinaryOperator: 2494case BoundKind.UserDefinedConditionalLogicalOperator: 2506Debug.Assert(!isBool || binary.Kind != BoundKind.UserDefinedConditionalLogicalOperator);
FlowAnalysis\ControlFlowPass.cs (12)
215case BoundKind.GotoStatement: 222case BoundKind.BreakStatement: 223case BoundKind.ContinueStatement: 230case BoundKind.ReturnStatement: 243case BoundKind.NoOpStatement: 244case BoundKind.Block: 245case BoundKind.ThrowStatement: 246case BoundKind.LabeledStatement: 247case BoundKind.LocalFunctionStatement: 250case BoundKind.StatementList: 306case BoundKind.YieldBreakStatement: 307case BoundKind.YieldReturnStatement:
FlowAnalysis\DataFlowsOutWalker.cs (14)
120case BoundKind.ListPattern: 121case BoundKind.RecursivePattern: 122case BoundKind.DeclarationPattern: 127case BoundKind.FieldAccess: 139case BoundKind.LocalDeclaration: 144case BoundKind.ThisReference: 149case BoundKind.Local: 154case BoundKind.Parameter: 159case BoundKind.CatchBlock: 165case BoundKind.RangeVariable: 170case BoundKind.EventAccess: 185case BoundKind.LocalFunctionStatement: 241case BoundKind.Parameter: return ((BoundParameter)node).ParameterSymbol; 242case BoundKind.ThisReference: return this.MethodThisParameter;
FlowAnalysis\DefiniteAssignment.cs (81)
242if (node.Kind == BoundKind.Attribute) 737Debug.Assert(fieldOrEventAccess.Kind == BoundKind.FieldAccess || fieldOrEventAccess.Kind == BoundKind.EventAccess); 743case BoundKind.FieldAccess: 759case BoundKind.EventAccess: 776case BoundKind.ThisReference: 780case BoundKind.Local: 784case BoundKind.Parameter: 788case BoundKind.InlineArrayAccess: 873if (value is { ConstantValueOpt: not null, Kind: not BoundKind.InterpolatedString }) return false; 877case BoundKind.Conversion: 891case BoundKind.DefaultLiteral: 892case BoundKind.DefaultExpression: 894case BoundKind.ObjectCreationExpression: 897case BoundKind.TupleLiteral: 898case BoundKind.ConvertedTupleLiteral: 899case BoundKind.Utf8String: 915case BoundKind.FieldAccess: 930if (n.Kind == BoundKind.Local) 942case BoundKind.EventAccess: 963case BoundKind.ThisReference: 967case BoundKind.Local: 971case BoundKind.Parameter: 975case BoundKind.RangeVariable: 979case BoundKind.InlineArrayAccess: 1024case BoundKind.FieldAccess: 1040case BoundKind.EventAccess: 1052case BoundKind.PropertyAccess: 1076receiver.Kind != BoundKind.TypeExpression && 1093receiverOpt.Kind != BoundKind.TypeExpression && 1336case BoundKind.ThisReference: 1349case BoundKind.Local: 1355case BoundKind.FieldAccess: 1367case BoundKind.EventAccess: 1379case BoundKind.InlineArrayAccess: 1385case BoundKind.PropertyAccess: 1407case BoundKind.Parameter: 1414case BoundKind.RangeVariable: 1439case BoundKind.FieldAccess: 1448case BoundKind.Local: 1452case BoundKind.RangeVariable: 1454case BoundKind.Parameter: 1456case BoundKind.ThisReference: 1458case BoundKind.BaseReference: 1491case BoundKind.ListPattern: 1492case BoundKind.RecursivePattern: 1493case BoundKind.DeclarationPattern: 1509case BoundKind.LocalDeclaration: 1520case BoundKind.Local: 1538case BoundKind.InlineArrayAccess: 1568case BoundKind.Parameter: 1585case BoundKind.ObjectInitializerMember: 1597case BoundKind.ThisReference: 1598case BoundKind.FieldAccess: 1599case BoundKind.EventAccess: 1600case BoundKind.PropertyAccess: 1609case BoundKind.RangeVariable: 1613case BoundKind.BadExpression: 1624case BoundKind.TupleLiteral: 1625case BoundKind.ConvertedTupleLiteral: 1957case BoundKind.DeclarationPattern: 1964case BoundKind.DiscardPattern: 1965case BoundKind.TypePattern: 1967case BoundKind.SlicePattern: 1976case BoundKind.ConstantPattern: 1982case BoundKind.RecursivePattern: 2016case BoundKind.ITuplePattern: 2025case BoundKind.ListPattern: 2036case BoundKind.RelationalPattern: 2042case BoundKind.NegatedPattern: 2048case BoundKind.BinaryPattern: 2157if (stmt.Kind != BoundKind.LocalFunctionStatement) 2405if (pending.Branch.Kind == BoundKind.ReturnStatement) 2479if (initializer.Kind == BoundKind.AddressOfOperator) 2552case BoundKind.Local: 2555case BoundKind.Parameter: 2558case BoundKind.FieldAccess: 2566case BoundKind.EventAccess: 2574case BoundKind.ThisReference: 2575case BoundKind.BaseReference: 2579case BoundKind.InlineArrayAccess:
FlowAnalysis\ExitPointsWalker.cs (9)
127case BoundKind.GotoStatement: 130case BoundKind.BreakStatement: 133case BoundKind.ContinueStatement: 136case BoundKind.YieldBreakStatement: 137case BoundKind.ReturnStatement: 140case BoundKind.YieldReturnStatement: 141case BoundKind.AwaitExpression: 142case BoundKind.UsingStatement: 143case BoundKind.ForEachStatement when ((BoundForEachStatement)pending.Branch).EnumeratorInfoOpt is { MoveNextAwaitableInfo: not null }:
FlowAnalysis\LocalDataFlowPass.cs (9)
215case BoundKind.ThisReference: 216case BoundKind.BaseReference: 218case BoundKind.Local: 220case BoundKind.Parameter: 222case BoundKind.RangeVariable: 224case BoundKind.FieldAccess: 225case BoundKind.EventAccess: 226case BoundKind.PropertyAccess: 233case BoundKind.AssignmentOperator:
FlowAnalysis\NullableWalker.cs (71)
294private static readonly ImmutableArray<BoundKind> s_skippedExpressions = ImmutableArray.Create(BoundKind.ArrayInitialization, 295BoundKind.ObjectInitializerExpression, 296BoundKind.CollectionInitializerExpression, 297BoundKind.DynamicCollectionElementInitializer); 392|| expr.Kind == BoundKind.ExpressionWithNullability 462private bool IsAnalyzingAttribute => methodMainNode.Kind == BoundKind.Attribute; 575Debug.Assert(expression != null || placeholder.Kind == BoundKind.InterpolatedStringArgumentPlaceholder); 596case BoundKind.DeconstructValuePlaceholder: 597case BoundKind.InterpolatedStringHandlerPlaceholder: 598case BoundKind.InterpolatedStringArgumentPlaceholder: 599case BoundKind.ObjectOrCollectionValuePlaceholder: 602case BoundKind.ImplicitIndexerValuePlaceholder: 2070case BoundKind.FieldAccess: 2086case BoundKind.EventAccess: 2099case BoundKind.PropertyAccess: 2117receiver.Kind != BoundKind.TypeExpression && 2145case BoundKind.ThisReference: 2146case BoundKind.BaseReference: 2152case BoundKind.Conversion: 2195case BoundKind.DefaultLiteral: 2196case BoundKind.DefaultExpression: 2197case BoundKind.ObjectCreationExpression: 2198case BoundKind.DynamicObjectCreationExpression: 2199case BoundKind.AnonymousObjectCreationExpression: 2200case BoundKind.NewT: 2201case BoundKind.TupleLiteral: 2202case BoundKind.ConvertedTupleLiteral: 2204case BoundKind.ConditionalAccess: 2206case BoundKind.ConditionalReceiver: 2614case BoundKind.Conversion: 2621case BoundKind.DefaultLiteral: 2622case BoundKind.DefaultExpression: 3139if (!expr.IsSuppressed && RemoveConversion(expr, includeExplicitConversions: false).expression.Kind != BoundKind.ThrowExpression) 4358Debug.Assert(node.Kind is BoundKind.ObjectCreationExpression or BoundKind.DynamicObjectCreationExpression or BoundKind.NewT or BoundKind.NoPiaObjectCreationExpression); 4451case BoundKind.AssignmentOperator: 4466case BoundKind.CollectionElementInitializer: 4496case BoundKind.ObjectInitializerMember: 5228if (child.Kind == BoundKind.ArrayInitialization) 5851case BoundKind.Conversion: 5855case BoundKind.AsOperator: 5858case BoundKind.ConditionalAccess: 6045while (possiblyConversion.Kind == BoundKind.Conversion) 8024return (argument.Kind == BoundKind.Lambda); 8675/// other than <see cref="BoundKind.ExpressionWithNullability"/> which is an expression 8682case BoundKind.DefaultLiteral: 8683case BoundKind.DefaultExpression: 8684case BoundKind.Literal: 8686case BoundKind.ExpressionWithNullability: 8688case BoundKind.MethodGroup: 8689case BoundKind.UnboundLambda: 8690case BoundKind.UnconvertedObjectCreationExpression: 8691case BoundKind.ConvertedTupleLiteral: 8692case BoundKind.UnconvertedCollectionExpression: 8732if (argument.Kind == BoundKind.Lambda) 8741if (argument.Kind == BoundKind.CollectionExpression) 8877if (expr.Kind != BoundKind.Conversion) 8962case BoundKind.InterpolatedString: 9801if (operandType.Type?.IsTupleType == true || conversionOperand.Kind == BoundKind.TupleLiteral) 10811if (left.Kind == BoundKind.EventAccess && ((BoundEventAccess)left).EventSymbol.IsWindowsRuntimeEvent) 11229case BoundKind.TupleLiteral: 11230case BoundKind.ConvertedTupleLiteral: 11247case BoundKind.TupleLiteral: 11248case BoundKind.ConvertedTupleLiteral: 11250case BoundKind.Conversion: 11598if (initializer.Kind == BoundKind.AddressOfOperator) 11604if (node.Expression.Kind == BoundKind.AddressOfOperator) 11890if (node.Expression.Kind != BoundKind.Conversion)
FlowAnalysis\NullableWalker.SnapshotManager.cs (1)
106if (node.Kind == BoundKind.TypeExpression || node.WasCompilerGenerated)
FlowAnalysis\ReadWriteWalker.cs (14)
147if (!IsInside && node.Span.Contains(RegionSpan) && (expr.Kind == BoundKind.FieldAccess)) 190case BoundKind.Local: 196case BoundKind.ThisReference: 202case BoundKind.BaseReference: 208case BoundKind.Parameter: 214case BoundKind.RangeVariable: 220case BoundKind.FieldAccess: 226case BoundKind.InlineArrayAccess: 240case BoundKind.RangeVariable: 244case BoundKind.QueryClause: 255case BoundKind.FieldAccess: 265case BoundKind.InlineArrayAccess: 306case BoundKind.Parameter: 308case BoundKind.PropertyAccess:
FlowAnalysis\RegionAnalysisContext.cs (2)
51case BoundKind.NamespaceExpression: 52case BoundKind.TypeExpression:
Generated\BoundNodes.xml.Generated.cs (603)
261protected BoundInitializer(BoundKind kind, SyntaxNode syntax, bool hasErrors) 266protected BoundInitializer(BoundKind kind, SyntaxNode syntax) 275protected BoundEqualsValue(BoundKind kind, SyntaxNode syntax, ImmutableArray<LocalSymbol> locals, BoundExpression value, bool hasErrors = false) 293: base(BoundKind.FieldEqualsValue, syntax, locals, value, hasErrors || value.HasErrors()) 323: base(BoundKind.PropertyEqualsValue, syntax, locals, value, hasErrors || value.HasErrors()) 353: base(BoundKind.ParameterEqualsValue, syntax, locals, value, hasErrors || value.HasErrors()) 383: base(BoundKind.GlobalStatementInitializer, syntax, hasErrors || statement.HasErrors()) 410protected BoundExpression(BoundKind kind, SyntaxNode syntax, TypeSymbol? type, bool hasErrors) 416protected BoundExpression(BoundKind kind, SyntaxNode syntax, TypeSymbol? type) 427protected BoundValuePlaceholderBase(BoundKind kind, SyntaxNode syntax, TypeSymbol? type, bool hasErrors) 432protected BoundValuePlaceholderBase(BoundKind kind, SyntaxNode syntax, TypeSymbol? type) 441protected BoundEarlyValuePlaceholderBase(BoundKind kind, SyntaxNode syntax, TypeSymbol? type, bool hasErrors) 446protected BoundEarlyValuePlaceholderBase(BoundKind kind, SyntaxNode syntax, TypeSymbol? type) 456: base(BoundKind.ValuePlaceholder, syntax, type, hasErrors) 461: base(BoundKind.ValuePlaceholder, syntax, type) 484: base(BoundKind.CapturedReceiverPlaceholder, syntax, type, hasErrors || receiver.HasErrors()) 512: base(BoundKind.DeconstructValuePlaceholder, syntax, type, hasErrors) 522: base(BoundKind.DeconstructValuePlaceholder, syntax, type) 553: base(BoundKind.TupleOperandPlaceholder, syntax, type, hasErrors) 561: base(BoundKind.TupleOperandPlaceholder, syntax, type) 588: base(BoundKind.AwaitableValuePlaceholder, syntax, type, hasErrors) 593: base(BoundKind.AwaitableValuePlaceholder, syntax, type) 617: base(BoundKind.DisposableValuePlaceholder, syntax, type, hasErrors) 625: base(BoundKind.DisposableValuePlaceholder, syntax, type) 652: base(BoundKind.ObjectOrCollectionValuePlaceholder, syntax, type, hasErrors) 661: base(BoundKind.ObjectOrCollectionValuePlaceholder, syntax, type) 690: base(BoundKind.ImplicitIndexerValuePlaceholder, syntax, type, hasErrors) 698: base(BoundKind.ImplicitIndexerValuePlaceholder, syntax, type) 725: base(BoundKind.ImplicitIndexerReceiverPlaceholder, syntax, type, hasErrors) 734: base(BoundKind.ImplicitIndexerReceiverPlaceholder, syntax, type) 763: base(BoundKind.ListPatternReceiverPlaceholder, syntax, type, hasErrors) 771: base(BoundKind.ListPatternReceiverPlaceholder, syntax, type) 798: base(BoundKind.ListPatternIndexPlaceholder, syntax, type, hasErrors) 806: base(BoundKind.ListPatternIndexPlaceholder, syntax, type) 833: base(BoundKind.SlicePatternReceiverPlaceholder, syntax, type, hasErrors) 841: base(BoundKind.SlicePatternReceiverPlaceholder, syntax, type) 868: base(BoundKind.SlicePatternRangePlaceholder, syntax, type, hasErrors) 876: base(BoundKind.SlicePatternRangePlaceholder, syntax, type) 903: base(BoundKind.CollectionBuilderElementsPlaceholder, syntax, type, hasErrors) 908: base(BoundKind.CollectionBuilderElementsPlaceholder, syntax, type) 931: base(BoundKind.Dup, syntax, type, hasErrors) 937: base(BoundKind.Dup, syntax, type) 962: base(BoundKind.PassByCopy, syntax, type, hasErrors || expression.HasErrors()) 990: base(BoundKind.BadExpression, syntax, type, hasErrors || childBoundNodes.HasErrors()) 1027: base(BoundKind.BadStatement, syntax, hasErrors || childBoundNodes.HasErrors()) 1055: base(BoundKind.ExtractedFinallyBlock, syntax, hasErrors || finallyBlock.HasErrors()) 1083: base(BoundKind.TypeExpression, syntax, type, hasErrors || boundContainingTypeOpt.HasErrors() || boundDimensionsOpt.HasErrors()) 1118: base(BoundKind.TypeOrValueExpression, syntax, type, hasErrors) 1134: base(BoundKind.TypeOrValueExpression, syntax, type) 1167: base(BoundKind.NamespaceExpression, syntax, null, hasErrors) 1177: base(BoundKind.NamespaceExpression, syntax, null) 1208: base(BoundKind.UnaryOperator, syntax, type, hasErrors || operand.HasErrors()) 1250: base(BoundKind.IncrementOperator, syntax, type, hasErrors || operand.HasErrors() || operandPlaceholder.HasErrors() || operandConversion.HasErrors() || resultPlaceholder.HasErrors() || resultConversion.HasErrors()) 1298: base(BoundKind.AddressOfOperator, syntax, type, hasErrors || operand.HasErrors()) 1330: base(BoundKind.UnconvertedAddressOfOperator, syntax, null, hasErrors || operand.HasErrors()) 1359: base(BoundKind.FunctionPointerLoad, syntax, type, hasErrors) 1370: base(BoundKind.FunctionPointerLoad, syntax, type) 1402: base(BoundKind.PointerIndirectionOperator, syntax, type, hasErrors || operand.HasErrors()) 1434: base(BoundKind.PointerElementAccess, syntax, type, hasErrors || expression.HasErrors() || index.HasErrors()) 1471: base(BoundKind.FunctionPointerInvocation, syntax, type, hasErrors || invokedExpression.HasErrors() || arguments.HasErrors()) 1508: base(BoundKind.RefTypeOperator, syntax, type, hasErrors || operand.HasErrors()) 1540: base(BoundKind.MakeRefOperator, syntax, type, hasErrors || operand.HasErrors()) 1570: base(BoundKind.RefValueOperator, syntax, type, hasErrors || operand.HasErrors()) 1602: base(BoundKind.FromEndIndexExpression, syntax, type, hasErrors || operand.HasErrors()) 1634: base(BoundKind.RangeExpression, syntax, type, hasErrors || leftOperandOpt.HasErrors() || rightOperandOpt.HasErrors()) 1666protected BoundBinaryOperatorBase(BoundKind kind, SyntaxNode syntax, BoundExpression left, BoundExpression right, TypeSymbol type, bool hasErrors = false) 1686: base(BoundKind.BinaryOperator, syntax, left, right, type, hasErrors || left.HasErrors() || right.HasErrors()) 1724: base(BoundKind.TupleBinaryOperator, syntax, type, hasErrors || left.HasErrors() || right.HasErrors()) 1762: base(BoundKind.UserDefinedConditionalLogicalOperator, syntax, left, right, type, hasErrors || trueFalseOperandPlaceholder.HasErrors() || trueFalseOperandConversion.HasErrors() || left.HasErrors() || right.HasErrors()) 1815: base(BoundKind.CompoundAssignmentOperator, syntax, type, hasErrors || left.HasErrors() || right.HasErrors() || leftPlaceholder.HasErrors() || leftConversion.HasErrors() || finalPlaceholder.HasErrors() || finalConversion.HasErrors()) 1862: base(BoundKind.AssignmentOperator, syntax, type, hasErrors || left.HasErrors() || right.HasErrors()) 1896: base(BoundKind.DeconstructionAssignmentOperator, syntax, type, hasErrors || left.HasErrors() || right.HasErrors()) 1931: base(BoundKind.NullCoalescingOperator, syntax, type, hasErrors || leftOperand.HasErrors() || rightOperand.HasErrors() || leftPlaceholder.HasErrors() || leftConversion.HasErrors()) 1972: base(BoundKind.NullCoalescingAssignmentOperator, syntax, type, hasErrors || leftOperand.HasErrors() || rightOperand.HasErrors()) 2003: base(BoundKind.UnconvertedConditionalOperator, syntax, null, hasErrors || condition.HasErrors() || consequence.HasErrors() || alternative.HasErrors()) 2042: base(BoundKind.ConditionalOperator, syntax, type, hasErrors || condition.HasErrors() || consequence.HasErrors() || alternative.HasErrors()) 2086: base(BoundKind.ArrayAccess, syntax, type, hasErrors || expression.HasErrors() || indices.HasErrors()) 2119: base(BoundKind.RefArrayAccess, syntax, null, hasErrors || arrayAccess.HasErrors()) 2148: base(BoundKind.ArrayLength, syntax, type, hasErrors || expression.HasErrors()) 2178: base(BoundKind.AwaitableInfo, syntax, hasErrors || awaitableInstancePlaceholder.HasErrors() || getAwaiter.HasErrors() || runtimeAsyncAwaitCall.HasErrors() || runtimeAsyncAwaitCallPlaceholder.HasErrors()) 2219: base(BoundKind.AwaitExpression, syntax, type, hasErrors || expression.HasErrors() || awaitableInfo.HasErrors()) 2253protected BoundTypeOf(BoundKind kind, SyntaxNode syntax, MethodSymbol? getTypeFromHandle, TypeSymbol type, bool hasErrors) 2262protected BoundTypeOf(BoundKind kind, SyntaxNode syntax, MethodSymbol? getTypeFromHandle, TypeSymbol type) 2278: base(BoundKind.TypeOfOperator, syntax, getTypeFromHandle, type, hasErrors || sourceType.HasErrors()) 2307: base(BoundKind.BlockInstrumentation, syntax, hasErrors || prologue.HasErrors() || epilogue.HasErrors()) 2339: base(BoundKind.MethodDefIndex, syntax, type, hasErrors) 2353: base(BoundKind.MethodDefIndex, syntax, type) 2383: base(BoundKind.LocalId, syntax, type, hasErrors) 2394: base(BoundKind.LocalId, syntax, type) 2426: base(BoundKind.ParameterId, syntax, type, hasErrors) 2437: base(BoundKind.ParameterId, syntax, type) 2469: base(BoundKind.StateMachineInstanceId, syntax, type, hasErrors) 2477: base(BoundKind.StateMachineInstanceId, syntax, type) 2504: base(BoundKind.MaximumMethodDefIndex, syntax, type, hasErrors) 2512: base(BoundKind.MaximumMethodDefIndex, syntax, type) 2539: base(BoundKind.InstrumentationPayloadRoot, syntax, type, hasErrors) 2548: base(BoundKind.InstrumentationPayloadRoot, syntax, type) 2577: base(BoundKind.ThrowIfModuleCancellationRequested, syntax, type, hasErrors) 2585: base(BoundKind.ThrowIfModuleCancellationRequested, syntax, type) 2612: base(BoundKind.ModuleCancellationTokenExpression, syntax, type, hasErrors) 2620: base(BoundKind.ModuleCancellationTokenExpression, syntax, type) 2647: base(BoundKind.ModuleVersionId, syntax, type, hasErrors) 2655: base(BoundKind.ModuleVersionId, syntax, type) 2682: base(BoundKind.ModuleVersionIdString, syntax, type, hasErrors) 2690: base(BoundKind.ModuleVersionIdString, syntax, type) 2717: base(BoundKind.SourceDocumentIndex, syntax, type, hasErrors) 2727: base(BoundKind.SourceDocumentIndex, syntax, type) 2757: base(BoundKind.MethodInfo, syntax, type, hasErrors) 2768: base(BoundKind.MethodInfo, syntax, type) 2800: base(BoundKind.FieldInfo, syntax, type, hasErrors) 2811: base(BoundKind.FieldInfo, syntax, type) 2843: base(BoundKind.DefaultLiteral, syntax, null, hasErrors) 2848: base(BoundKind.DefaultLiteral, syntax, null) 2866: base(BoundKind.DefaultExpression, syntax, type, hasErrors || targetType.HasErrors()) 2897: base(BoundKind.IsOperator, syntax, type, hasErrors || operand.HasErrors() || targetType.HasErrors()) 2932: base(BoundKind.AsOperator, syntax, type, hasErrors || operand.HasErrors() || targetType.HasErrors() || operandPlaceholder.HasErrors() || operandConversion.HasErrors()) 2969: base(BoundKind.SizeOfOperator, syntax, type, hasErrors || sourceType.HasErrors()) 3001: base(BoundKind.Conversion, syntax, type, hasErrors || operand.HasErrors()) 3049: base(BoundKind.ReadOnlySpanFromArray, syntax, type, hasErrors || operand.HasErrors()) 3082: base(BoundKind.ArgList, syntax, type, hasErrors) 3090: base(BoundKind.ArgList, syntax, type) 3117: base(BoundKind.ArgListOperator, syntax, type, hasErrors || arguments.HasErrors()) 3148: base(BoundKind.FixedLocalCollectionInitializer, syntax, type, hasErrors || elementPointerPlaceholder.HasErrors() || elementPointerConversion.HasErrors() || expression.HasErrors()) 3186protected BoundStatement(BoundKind kind, SyntaxNode syntax, bool hasErrors) 3191protected BoundStatement(BoundKind kind, SyntaxNode syntax) 3201: base(BoundKind.SequencePoint, syntax, hasErrors || statementOpt.HasErrors()) 3226: base(BoundKind.SequencePointWithSpan, syntax, hasErrors || statementOpt.HasErrors()) 3253: base(BoundKind.SavePreviousSequencePoint, syntax, hasErrors) 3262: base(BoundKind.SavePreviousSequencePoint, syntax) 3290: base(BoundKind.RestorePreviousSequencePoint, syntax, hasErrors) 3299: base(BoundKind.RestorePreviousSequencePoint, syntax) 3327: base(BoundKind.StepThroughSequencePoint, syntax, hasErrors) 3333: base(BoundKind.StepThroughSequencePoint, syntax) 3358: base(BoundKind.Block, syntax, statements, hasErrors || instrumentation.HasErrors() || statements.HasErrors()) 3394: base(BoundKind.Scope, syntax, statements, hasErrors || statements.HasErrors()) 3423: base(BoundKind.StateMachineScope, syntax, hasErrors || statement.HasErrors()) 3454: base(BoundKind.LocalDeclaration, syntax, hasErrors || declaredTypeOpt.HasErrors() || initializerOpt.HasErrors() || argumentsOpt.HasErrors()) 3489protected BoundMultipleLocalDeclarationsBase(BoundKind kind, SyntaxNode syntax, ImmutableArray<BoundLocalDeclaration> localDeclarations, bool hasErrors = false) 3504: base(BoundKind.MultipleLocalDeclarations, syntax, localDeclarations, hasErrors || localDeclarations.HasErrors()) 3530: base(BoundKind.UsingLocalDeclarations, syntax, localDeclarations, hasErrors || awaitOpt.HasErrors() || localDeclarations.HasErrors()) 3560: base(BoundKind.LocalFunctionStatement, syntax, hasErrors || blockBody.HasErrors() || expressionBody.HasErrors()) 3592: base(BoundKind.NoOpStatement, syntax, hasErrors) 3598: base(BoundKind.NoOpStatement, syntax) 3623: base(BoundKind.ReturnStatement, syntax, hasErrors || expressionOpt.HasErrors()) 3656: base(BoundKind.YieldReturnStatement, syntax, hasErrors || expression.HasErrors()) 3684: base(BoundKind.YieldBreakStatement, syntax, hasErrors) 3689: base(BoundKind.YieldBreakStatement, syntax) 3701: base(BoundKind.ThrowStatement, syntax, hasErrors || expressionOpt.HasErrors()) 3726: base(BoundKind.ExpressionStatement, syntax, hasErrors || expression.HasErrors()) 3754: base(BoundKind.BreakStatement, syntax, hasErrors) 3763: base(BoundKind.BreakStatement, syntax) 3791: base(BoundKind.ContinueStatement, syntax, hasErrors) 3800: base(BoundKind.ContinueStatement, syntax) 3828: base(BoundKind.SwitchStatement, syntax, hasErrors || expression.HasErrors() || switchSections.HasErrors() || reachabilityDecisionDag.HasErrors() || defaultLabel.HasErrors()) 3873: base(BoundKind.SwitchDispatch, syntax, hasErrors || expression.HasErrors()) 3909: base(BoundKind.IfStatement, syntax, hasErrors || condition.HasErrors() || consequence.HasErrors() || alternativeOpt.HasErrors()) 3941protected BoundLoopStatement(BoundKind kind, SyntaxNode syntax, LabelSymbol breakLabel, LabelSymbol continueLabel, bool hasErrors) 3952protected BoundLoopStatement(BoundKind kind, SyntaxNode syntax, LabelSymbol breakLabel, LabelSymbol continueLabel) 3969protected BoundConditionalLoopStatement(BoundKind kind, SyntaxNode syntax, ImmutableArray<LocalSymbol> locals, BoundExpression condition, BoundStatement body, LabelSymbol breakLabel, LabelSymbol continueLabel, bool hasErrors = false) 3992: base(BoundKind.DoStatement, syntax, locals, condition, body, breakLabel, continueLabel, hasErrors || condition.HasErrors() || body.HasErrors()) 4022: base(BoundKind.WhileStatement, syntax, locals, condition, body, breakLabel, continueLabel, hasErrors || condition.HasErrors() || body.HasErrors()) 4052: base(BoundKind.ForStatement, syntax, breakLabel, continueLabel, hasErrors || initializer.HasErrors() || condition.HasErrors() || increment.HasErrors() || body.HasErrors()) 4094: base(BoundKind.ForEachStatement, syntax, breakLabel, continueLabel, hasErrors || elementPlaceholder.HasErrors() || elementConversion.HasErrors() || iterationVariableType.HasErrors() || iterationErrorExpressionOpt.HasErrors() || expression.HasErrors() || deconstructionOpt.HasErrors() || body.HasErrors()) 4143: base(BoundKind.ForEachDeconstructStep, syntax, hasErrors || deconstructionAssignment.HasErrors() || targetPlaceholder.HasErrors()) 4174: base(BoundKind.UsingStatement, syntax, hasErrors || declarationsOpt.HasErrors() || expressionOpt.HasErrors() || body.HasErrors() || awaitOpt.HasErrors()) 4213: base(BoundKind.FixedStatement, syntax, hasErrors || declarations.HasErrors() || body.HasErrors()) 4247: base(BoundKind.LockStatement, syntax, hasErrors || argument.HasErrors() || body.HasErrors()) 4278: base(BoundKind.TryStatement, syntax, hasErrors || tryBlock.HasErrors() || catchBlocks.HasErrors() || finallyBlockOpt.HasErrors()) 4315: base(BoundKind.CatchBlock, syntax, hasErrors || exceptionSourceOpt.HasErrors() || exceptionFilterPrologueOpt.HasErrors() || exceptionFilterOpt.HasErrors() || body.HasErrors()) 4356: base(BoundKind.Literal, syntax, type, hasErrors) 4362: base(BoundKind.Literal, syntax, type) 4387: base(BoundKind.Utf8String, syntax, type, hasErrors) 4397: base(BoundKind.Utf8String, syntax, type) 4427: base(BoundKind.ThisReference, syntax, type, hasErrors) 4435: base(BoundKind.ThisReference, syntax, type) 4462: base(BoundKind.PreviousSubmissionReference, syntax, type, hasErrors) 4470: base(BoundKind.PreviousSubmissionReference, syntax, type) 4497: base(BoundKind.HostObjectMemberReference, syntax, type, hasErrors) 4505: base(BoundKind.HostObjectMemberReference, syntax, type) 4532: base(BoundKind.BaseReference, syntax, type, hasErrors) 4537: base(BoundKind.BaseReference, syntax, type) 4561: base(BoundKind.Local, syntax, type, hasErrors) 4574: base(BoundKind.Local, syntax, type) 4610: base(BoundKind.PseudoVariable, syntax, type, hasErrors) 4622: base(BoundKind.PseudoVariable, syntax, type) 4655: base(BoundKind.RangeVariable, syntax, type, hasErrors || value.HasErrors()) 4688: base(BoundKind.Parameter, syntax, type, hasErrors) 4698: base(BoundKind.Parameter, syntax, type) 4728: base(BoundKind.LabelStatement, syntax, hasErrors) 4737: base(BoundKind.LabelStatement, syntax) 4765: base(BoundKind.GotoStatement, syntax, hasErrors || caseExpressionOpt.HasErrors() || labelExpressionOpt.HasErrors()) 4797: base(BoundKind.LabeledStatement, syntax, hasErrors || body.HasErrors()) 4828: base(BoundKind.Label, syntax, type, hasErrors) 4837: base(BoundKind.Label, syntax, type) 4864protected BoundStatementList(BoundKind kind, SyntaxNode syntax, ImmutableArray<BoundStatement> statements, bool hasErrors = false) 4874: base(BoundKind.StatementList, syntax, hasErrors || statements.HasErrors()) 4902: base(BoundKind.ConditionalGoto, syntax, hasErrors || condition.HasErrors()) 4934protected BoundSwitchExpression(BoundKind kind, SyntaxNode syntax, BoundExpression expression, ImmutableArray<BoundSwitchExpressionArm> switchArms, BoundDecisionDag reachabilityDecisionDag, LabelSymbol? defaultLabel, bool reportedNotExhaustive, TypeSymbol? type, bool hasErrors = false) 4959: base(BoundKind.SwitchExpressionArm, syntax, hasErrors || pattern.HasErrors() || whenClause.HasErrors() || value.HasErrors()) 4998: base(BoundKind.UnconvertedSwitchExpression, syntax, expression, switchArms, reachabilityDecisionDag, defaultLabel, reportedNotExhaustive, type, hasErrors || expression.HasErrors() || switchArms.HasErrors() || reachabilityDecisionDag.HasErrors()) 5026: base(BoundKind.ConvertedSwitchExpression, syntax, expression, switchArms, reachabilityDecisionDag, defaultLabel, reportedNotExhaustive, type, hasErrors || expression.HasErrors() || switchArms.HasErrors() || reachabilityDecisionDag.HasErrors()) 5060: base(BoundKind.DecisionDag, syntax, hasErrors || rootNode.HasErrors()) 5089protected BoundDecisionDagNode(BoundKind kind, SyntaxNode syntax, bool hasErrors) 5094protected BoundDecisionDagNode(BoundKind kind, SyntaxNode syntax) 5104: base(BoundKind.EvaluationDecisionDagNode, syntax, hasErrors || evaluation.HasErrors() || next.HasErrors()) 5135: base(BoundKind.TestDecisionDagNode, syntax, hasErrors || test.HasErrors() || whenTrue.HasErrors() || whenFalse.HasErrors()) 5169: base(BoundKind.WhenDecisionDagNode, syntax, hasErrors || whenExpression.HasErrors() || whenTrue.HasErrors() || whenFalse.HasErrors()) 5204: base(BoundKind.LeafDecisionDagNode, syntax, hasErrors) 5213: base(BoundKind.LeafDecisionDagNode, syntax) 5240protected BoundDagTest(BoundKind kind, SyntaxNode syntax, BoundDagTemp input, bool hasErrors = false) 5255: base(BoundKind.DagTemp, syntax, hasErrors || source.HasErrors()) 5287: base(BoundKind.DagTypeTest, syntax, input, hasErrors || input.HasErrors()) 5316: base(BoundKind.DagNonNullTest, syntax, input, hasErrors || input.HasErrors()) 5344: base(BoundKind.DagExplicitNullTest, syntax, input, hasErrors || input.HasErrors()) 5370: base(BoundKind.DagValueTest, syntax, input, hasErrors || input.HasErrors()) 5399: base(BoundKind.DagRelationalTest, syntax, input, hasErrors || input.HasErrors()) 5429protected BoundDagEvaluation(BoundKind kind, SyntaxNode syntax, BoundDagTemp input, bool hasErrors = false) 5442: base(BoundKind.DagDeconstructEvaluation, syntax, input, hasErrors || input.HasErrors()) 5471: base(BoundKind.DagTypeEvaluation, syntax, input, hasErrors || input.HasErrors()) 5500: base(BoundKind.DagFieldEvaluation, syntax, input, hasErrors || input.HasErrors()) 5529: base(BoundKind.DagPropertyEvaluation, syntax, input, hasErrors || input.HasErrors()) 5560: base(BoundKind.DagIndexEvaluation, syntax, input, hasErrors || input.HasErrors()) 5591: base(BoundKind.DagIndexerEvaluation, syntax, input, hasErrors || lengthTemp.HasErrors() || indexerAccess.HasErrors() || receiverPlaceholder.HasErrors() || argumentPlaceholder.HasErrors() || input.HasErrors()) 5638: base(BoundKind.DagSliceEvaluation, syntax, input, hasErrors || lengthTemp.HasErrors() || indexerAccess.HasErrors() || receiverPlaceholder.HasErrors() || argumentPlaceholder.HasErrors() || input.HasErrors()) 5687: base(BoundKind.DagAssignmentEvaluation, syntax, input, hasErrors || target.HasErrors() || input.HasErrors()) 5716: base(BoundKind.SwitchSection, syntax, statements, hasErrors || switchLabels.HasErrors() || statements.HasErrors()) 5748: base(BoundKind.SwitchLabel, syntax, hasErrors || pattern.HasErrors() || whenClause.HasErrors()) 5780protected BoundMethodOrPropertyGroup(BoundKind kind, SyntaxNode syntax, BoundExpression? receiverOpt, LookupResultKind resultKind, bool hasErrors = false) 5795: base(BoundKind.SequencePointExpression, syntax, type, hasErrors || expression.HasErrors()) 5823: base(BoundKind.Sequence, syntax, type, hasErrors || sideEffects.HasErrors() || value.HasErrors()) 5859: base(BoundKind.SpillSequence, syntax, type, hasErrors || sideEffects.HasErrors() || value.HasErrors()) 5895: base(BoundKind.DynamicMemberAccess, syntax, type, hasErrors || receiver.HasErrors()) 5933protected BoundDynamicInvocableBase(BoundKind kind, SyntaxNode syntax, BoundExpression expression, ImmutableArray<BoundExpression> arguments, TypeSymbol? type, bool hasErrors = false) 5951: base(BoundKind.DynamicInvocation, syntax, expression, arguments, type, hasErrors || expression.HasErrors() || arguments.HasErrors()) 5987: base(BoundKind.ConditionalAccess, syntax, type, hasErrors || receiver.HasErrors() || accessExpression.HasErrors()) 6020: base(BoundKind.LoweredConditionalAccess, syntax, type, hasErrors || receiver.HasErrors() || whenNotNull.HasErrors() || whenNullOpt.HasErrors()) 6061: base(BoundKind.ConditionalReceiver, syntax, type, hasErrors) 6070: base(BoundKind.ConditionalReceiver, syntax, type) 6099: base(BoundKind.ComplexConditionalReceiver, syntax, type, hasErrors || valueTypeReceiver.HasErrors() || referenceTypeReceiver.HasErrors()) 6132: base(BoundKind.MethodGroup, syntax, receiverOpt, resultKind, hasErrors || receiverOpt.HasErrors()) 6173: base(BoundKind.PropertyGroup, syntax, receiverOpt, resultKind, hasErrors || receiverOpt.HasErrors()) 6201: base(BoundKind.Call, syntax, type, hasErrors || receiverOpt.HasErrors() || arguments.HasErrors()) 6260: base(BoundKind.EventAssignmentOperator, syntax, type, hasErrors || receiverOpt.HasErrors() || argument.HasErrors()) 6299: base(BoundKind.Attribute, syntax, type, hasErrors || constructorArguments.HasErrors() || namedArguments.HasErrors()) 6344: base(BoundKind.UnconvertedObjectCreationExpression, syntax, null, hasErrors || arguments.HasErrors()) 6381protected BoundObjectCreationExpressionBase(BoundKind kind, SyntaxNode syntax, TypeSymbol type, bool hasErrors) 6389protected BoundObjectCreationExpressionBase(BoundKind kind, SyntaxNode syntax, TypeSymbol type) 6403: base(BoundKind.ObjectCreationExpression, syntax, type, hasErrors || arguments.HasErrors() || initializerExpressionOpt.HasErrors()) 6453protected BoundCollectionExpressionBase(BoundKind kind, SyntaxNode syntax, ImmutableArray<BoundNode> elements, TypeSymbol? type, bool hasErrors = false) 6472: base(BoundKind.UnconvertedCollectionExpression, syntax, elements, null, hasErrors || withElement.HasErrors() || elements.HasErrors()) 6501: base(BoundKind.UnconvertedWithElement, syntax, hasErrors || arguments.HasErrors()) 6533: base(BoundKind.CollectionExpression, syntax, elements, type, hasErrors || placeholder.HasErrors() || collectionCreation.HasErrors() || collectionBuilderElementsPlaceholder.HasErrors() || unconvertedCollectionExpression.HasErrors() || elements.HasErrors()) 6582: base(BoundKind.CollectionExpressionSpreadExpressionPlaceholder, syntax, type, hasErrors) 6587: base(BoundKind.CollectionExpressionSpreadExpressionPlaceholder, syntax, type) 6610: base(BoundKind.CollectionExpressionSpreadElement, syntax, hasErrors || expression.HasErrors() || expressionPlaceholder.HasErrors() || conversion.HasErrors() || lengthOrCount.HasErrors() || elementPlaceholder.HasErrors() || iteratorBody.HasErrors()) 6649protected BoundTupleExpression(BoundKind kind, SyntaxNode syntax, ImmutableArray<BoundExpression> arguments, ImmutableArray<string?> argumentNamesOpt, ImmutableArray<bool> inferredNamesOpt, TypeSymbol? type, bool hasErrors = false) 6668: base(BoundKind.TupleLiteral, syntax, arguments, argumentNamesOpt, inferredNamesOpt, type, hasErrors || arguments.HasErrors()) 6695: base(BoundKind.ConvertedTupleLiteral, syntax, arguments, argumentNamesOpt, inferredNamesOpt, type, hasErrors || sourceTuple.HasErrors() || arguments.HasErrors()) 6725: base(BoundKind.DynamicObjectCreationExpression, syntax, type, hasErrors || arguments.HasErrors() || initializerExpressionOpt.HasErrors()) 6768: base(BoundKind.NoPiaObjectCreationExpression, syntax, type, hasErrors || initializerExpressionOpt.HasErrors()) 6799protected BoundObjectInitializerExpressionBase(BoundKind kind, SyntaxNode syntax, BoundObjectOrCollectionValuePlaceholder placeholder, ImmutableArray<BoundExpression> initializers, TypeSymbol type, bool hasErrors = false) 6819: base(BoundKind.ObjectInitializerExpression, syntax, placeholder, initializers, type, hasErrors || placeholder.HasErrors() || initializers.HasErrors()) 6847: base(BoundKind.ObjectInitializerMember, syntax, type, hasErrors || arguments.HasErrors()) 6896: base(BoundKind.DynamicObjectInitializerMember, syntax, type, hasErrors) 6908: base(BoundKind.DynamicObjectInitializerMember, syntax, type) 6941: base(BoundKind.CollectionInitializerExpression, syntax, placeholder, initializers, type, hasErrors || placeholder.HasErrors() || initializers.HasErrors()) 6969: base(BoundKind.CollectionElementInitializer, syntax, type, hasErrors || arguments.HasErrors() || implicitReceiverOpt.HasErrors()) 7014: base(BoundKind.DynamicCollectionElementInitializer, syntax, expression, arguments, type, hasErrors || expression.HasErrors() || arguments.HasErrors()) 7046: base(BoundKind.ImplicitReceiver, syntax, type, hasErrors) 7054: base(BoundKind.ImplicitReceiver, syntax, type) 7081: base(BoundKind.AnonymousObjectCreationExpression, syntax, type, hasErrors || arguments.HasErrors() || declarations.HasErrors()) 7117: base(BoundKind.AnonymousPropertyDeclaration, syntax, type, hasErrors) 7127: base(BoundKind.AnonymousPropertyDeclaration, syntax, type) 7157: base(BoundKind.NewT, syntax, type, hasErrors || initializerExpressionOpt.HasErrors()) 7187: base(BoundKind.DelegateCreationExpression, syntax, type, hasErrors || argument.HasErrors()) 7223: base(BoundKind.ArrayCreation, syntax, type, hasErrors || bounds.HasErrors() || initializerOpt.HasErrors()) 7255: base(BoundKind.ArrayInitialization, syntax, null, hasErrors || initializers.HasErrors()) 7285protected BoundStackAllocArrayCreationBase(BoundKind kind, SyntaxNode syntax, TypeSymbol elementType, BoundExpression count, BoundArrayInitialization? initializerOpt, TypeSymbol? type, bool hasErrors = false) 7305: base(BoundKind.StackAllocArrayCreation, syntax, elementType, count, initializerOpt, type, hasErrors || count.HasErrors() || initializerOpt.HasErrors()) 7332: base(BoundKind.ConvertedStackAllocExpression, syntax, elementType, count, initializerOpt, type, hasErrors || count.HasErrors() || initializerOpt.HasErrors()) 7361: base(BoundKind.FieldAccess, syntax, type, hasErrors || receiverOpt.HasErrors()) 7401: base(BoundKind.HoistedFieldAccess, syntax, type, hasErrors) 7411: base(BoundKind.HoistedFieldAccess, syntax, type) 7441: base(BoundKind.PropertyAccess, syntax, type, hasErrors || receiverOpt.HasErrors()) 7479: base(BoundKind.EventAccess, syntax, type, hasErrors || receiverOpt.HasErrors()) 7515: base(BoundKind.IndexerAccess, syntax, type, hasErrors || receiverOpt.HasErrors() || arguments.HasErrors()) 7566: base(BoundKind.ImplicitIndexerAccess, syntax, type, hasErrors || receiver.HasErrors() || argument.HasErrors() || lengthOrCountAccess.HasErrors() || receiverPlaceholder.HasErrors() || indexerOrSliceAccess.HasErrors() || argumentPlaceholders.HasErrors()) 7615: base(BoundKind.InlineArrayAccess, syntax, type, hasErrors || expression.HasErrors() || argument.HasErrors()) 7656: base(BoundKind.DynamicIndexerAccess, syntax, type, hasErrors || receiver.HasErrors() || arguments.HasErrors()) 7696: base(BoundKind.Lambda, syntax, type, hasErrors || unboundLambda.HasErrors() || body.HasErrors()) 7736: base(BoundKind.UnboundLambda, syntax, null, hasErrors) 7747: base(BoundKind.UnboundLambda, syntax, null) 7780: base(BoundKind.QueryClause, syntax, type, hasErrors || value.HasErrors() || operation.HasErrors() || cast.HasErrors() || unoptimizedForm.HasErrors()) 7821: base(BoundKind.TypeOrInstanceInitializers, syntax, statements, hasErrors || statements.HasErrors()) 7847: base(BoundKind.NameOfOperator, syntax, type, hasErrors || argument.HasErrors()) 7883protected BoundInterpolatedStringBase(BoundKind kind, SyntaxNode syntax, ImmutableArray<BoundExpression> parts, ConstantValue? constantValueOpt, TypeSymbol? type, bool hasErrors = false) 7900: base(BoundKind.UnconvertedInterpolatedString, syntax, parts, constantValueOpt, type, hasErrors || parts.HasErrors()) 7926: base(BoundKind.InterpolatedString, syntax, parts, constantValueOpt, type, hasErrors || parts.HasErrors()) 7954: base(BoundKind.InterpolatedStringHandlerPlaceholder, syntax, type, hasErrors) 7959: base(BoundKind.InterpolatedStringHandlerPlaceholder, syntax, type) 7982: base(BoundKind.InterpolatedStringArgumentPlaceholder, syntax, type, hasErrors) 7991: base(BoundKind.InterpolatedStringArgumentPlaceholder, syntax, type) 8020: base(BoundKind.StringInsert, syntax, null, hasErrors || value.HasErrors() || alignment.HasErrors() || format.HasErrors()) 8055: base(BoundKind.IsPatternExpression, syntax, type, hasErrors || expression.HasErrors() || pattern.HasErrors() || reachabilityDecisionDag.HasErrors()) 8096protected BoundPattern(BoundKind kind, SyntaxNode syntax, TypeSymbol inputType, TypeSymbol narrowedType, bool hasErrors) 8107protected BoundPattern(BoundKind kind, SyntaxNode syntax, TypeSymbol inputType, TypeSymbol narrowedType) 8125: base(BoundKind.ConstantPattern, syntax, inputType, narrowedType, hasErrors || value.HasErrors()) 8162: base(BoundKind.DiscardPattern, syntax, inputType, narrowedType, hasErrors) 8175: base(BoundKind.DiscardPattern, syntax, inputType, narrowedType) 8201protected BoundObjectPattern(BoundKind kind, SyntaxNode syntax, Symbol? variable, BoundExpression? variableAccess, TypeSymbol inputType, TypeSymbol narrowedType, bool hasErrors = false) 8219: base(BoundKind.DeclarationPattern, syntax, variable, variableAccess, inputType, narrowedType, hasErrors || declaredType.HasErrors() || variableAccess.HasErrors()) 8255: base(BoundKind.RecursivePattern, syntax, variable, variableAccess, inputType, narrowedType, hasErrors || declaredType.HasErrors() || deconstruction.HasErrors() || properties.HasErrors() || variableAccess.HasErrors()) 8296: base(BoundKind.ListPattern, syntax, variable, variableAccess, inputType, narrowedType, hasErrors || subpatterns.HasErrors() || lengthAccess.HasErrors() || indexerAccess.HasErrors() || receiverPlaceholder.HasErrors() || argumentPlaceholder.HasErrors() || variableAccess.HasErrors()) 8340: base(BoundKind.SlicePattern, syntax, inputType, narrowedType, hasErrors || pattern.HasErrors() || indexerAccess.HasErrors() || receiverPlaceholder.HasErrors() || argumentPlaceholder.HasErrors()) 8379: base(BoundKind.ITuplePattern, syntax, inputType, narrowedType, hasErrors || subpatterns.HasErrors()) 8418protected BoundSubpattern(BoundKind kind, SyntaxNode syntax, BoundPattern pattern, bool hasErrors = false) 8433: base(BoundKind.PositionalSubpattern, syntax, pattern, hasErrors || pattern.HasErrors()) 8461: base(BoundKind.PropertySubpattern, syntax, pattern, hasErrors || member.HasErrors() || pattern.HasErrors()) 8491: base(BoundKind.PropertySubpatternMember, syntax, hasErrors || receiver.HasErrors()) 8523: base(BoundKind.TypePattern, syntax, inputType, narrowedType, hasErrors || declaredType.HasErrors()) 8559: base(BoundKind.BinaryPattern, syntax, inputType, narrowedType, hasErrors || left.HasErrors() || right.HasErrors()) 8598: base(BoundKind.NegatedPattern, syntax, inputType, narrowedType, hasErrors || negated.HasErrors()) 8632: base(BoundKind.RelationalPattern, syntax, inputType, narrowedType, hasErrors || value.HasErrors()) 8671: base(BoundKind.DiscardExpression, syntax, type, hasErrors) 8678: base(BoundKind.DiscardExpression, syntax, type) 8706: base(BoundKind.ThrowExpression, syntax, type, hasErrors || expression.HasErrors()) 8733protected VariablePendingInference(BoundKind kind, SyntaxNode syntax, Symbol variableSymbol, BoundExpression? receiverOpt, bool hasErrors = false) 8751: base(BoundKind.OutVariablePendingInference, syntax, variableSymbol, receiverOpt, hasErrors || receiverOpt.HasErrors()) 8777: base(BoundKind.DeconstructionVariablePendingInference, syntax, variableSymbol, receiverOpt, hasErrors || receiverOpt.HasErrors()) 8803: base(BoundKind.OutDeconstructVarPendingInference, syntax, null, hasErrors) 8810: base(BoundKind.OutDeconstructVarPendingInference, syntax, null) 8837protected BoundMethodBodyBase(BoundKind kind, SyntaxNode syntax, BoundBlock? blockBody, BoundBlock? expressionBody, bool hasErrors = false) 8851: base(BoundKind.NonConstructorMethodBody, syntax, blockBody, expressionBody, hasErrors || blockBody.HasErrors() || expressionBody.HasErrors()) 8874: base(BoundKind.ConstructorMethodBody, syntax, blockBody, expressionBody, hasErrors || initializer.HasErrors() || blockBody.HasErrors() || expressionBody.HasErrors()) 8904: base(BoundKind.ExpressionWithNullability, syntax, type, hasErrors || expression.HasErrors()) 8935: base(BoundKind.WithExpression, syntax, type, hasErrors || receiver.HasErrors() || initializerExpression.HasErrors()) 8975case BoundKind.FieldEqualsValue: 8977case BoundKind.PropertyEqualsValue: 8979case BoundKind.ParameterEqualsValue: 8981case BoundKind.GlobalStatementInitializer: 8983case BoundKind.ValuePlaceholder: 8985case BoundKind.CapturedReceiverPlaceholder: 8987case BoundKind.DeconstructValuePlaceholder: 8989case BoundKind.TupleOperandPlaceholder: 8991case BoundKind.AwaitableValuePlaceholder: 8993case BoundKind.DisposableValuePlaceholder: 8995case BoundKind.ObjectOrCollectionValuePlaceholder: 8997case BoundKind.ImplicitIndexerValuePlaceholder: 8999case BoundKind.ImplicitIndexerReceiverPlaceholder: 9001case BoundKind.ListPatternReceiverPlaceholder: 9003case BoundKind.ListPatternIndexPlaceholder: 9005case BoundKind.SlicePatternReceiverPlaceholder: 9007case BoundKind.SlicePatternRangePlaceholder: 9009case BoundKind.CollectionBuilderElementsPlaceholder: 9011case BoundKind.Dup: 9013case BoundKind.PassByCopy: 9015case BoundKind.BadExpression: 9017case BoundKind.BadStatement: 9019case BoundKind.ExtractedFinallyBlock: 9021case BoundKind.TypeExpression: 9023case BoundKind.TypeOrValueExpression: 9025case BoundKind.NamespaceExpression: 9027case BoundKind.UnaryOperator: 9029case BoundKind.IncrementOperator: 9031case BoundKind.AddressOfOperator: 9033case BoundKind.UnconvertedAddressOfOperator: 9035case BoundKind.FunctionPointerLoad: 9037case BoundKind.PointerIndirectionOperator: 9039case BoundKind.PointerElementAccess: 9041case BoundKind.FunctionPointerInvocation: 9043case BoundKind.RefTypeOperator: 9045case BoundKind.MakeRefOperator: 9047case BoundKind.RefValueOperator: 9049case BoundKind.FromEndIndexExpression: 9051case BoundKind.RangeExpression: 9053case BoundKind.BinaryOperator: 9055case BoundKind.TupleBinaryOperator: 9057case BoundKind.UserDefinedConditionalLogicalOperator: 9059case BoundKind.CompoundAssignmentOperator: 9061case BoundKind.AssignmentOperator: 9063case BoundKind.DeconstructionAssignmentOperator: 9065case BoundKind.NullCoalescingOperator: 9067case BoundKind.NullCoalescingAssignmentOperator: 9069case BoundKind.UnconvertedConditionalOperator: 9071case BoundKind.ConditionalOperator: 9073case BoundKind.ArrayAccess: 9075case BoundKind.RefArrayAccess: 9077case BoundKind.ArrayLength: 9079case BoundKind.AwaitableInfo: 9081case BoundKind.AwaitExpression: 9083case BoundKind.TypeOfOperator: 9085case BoundKind.BlockInstrumentation: 9087case BoundKind.MethodDefIndex: 9089case BoundKind.LocalId: 9091case BoundKind.ParameterId: 9093case BoundKind.StateMachineInstanceId: 9095case BoundKind.MaximumMethodDefIndex: 9097case BoundKind.InstrumentationPayloadRoot: 9099case BoundKind.ThrowIfModuleCancellationRequested: 9101case BoundKind.ModuleCancellationTokenExpression: 9103case BoundKind.ModuleVersionId: 9105case BoundKind.ModuleVersionIdString: 9107case BoundKind.SourceDocumentIndex: 9109case BoundKind.MethodInfo: 9111case BoundKind.FieldInfo: 9113case BoundKind.DefaultLiteral: 9115case BoundKind.DefaultExpression: 9117case BoundKind.IsOperator: 9119case BoundKind.AsOperator: 9121case BoundKind.SizeOfOperator: 9123case BoundKind.Conversion: 9125case BoundKind.ReadOnlySpanFromArray: 9127case BoundKind.ArgList: 9129case BoundKind.ArgListOperator: 9131case BoundKind.FixedLocalCollectionInitializer: 9133case BoundKind.SequencePoint: 9135case BoundKind.SequencePointWithSpan: 9137case BoundKind.SavePreviousSequencePoint: 9139case BoundKind.RestorePreviousSequencePoint: 9141case BoundKind.StepThroughSequencePoint: 9143case BoundKind.Block: 9145case BoundKind.Scope: 9147case BoundKind.StateMachineScope: 9149case BoundKind.LocalDeclaration: 9151case BoundKind.MultipleLocalDeclarations: 9153case BoundKind.UsingLocalDeclarations: 9155case BoundKind.LocalFunctionStatement: 9157case BoundKind.NoOpStatement: 9159case BoundKind.ReturnStatement: 9161case BoundKind.YieldReturnStatement: 9163case BoundKind.YieldBreakStatement: 9165case BoundKind.ThrowStatement: 9167case BoundKind.ExpressionStatement: 9169case BoundKind.BreakStatement: 9171case BoundKind.ContinueStatement: 9173case BoundKind.SwitchStatement: 9175case BoundKind.SwitchDispatch: 9177case BoundKind.IfStatement: 9179case BoundKind.DoStatement: 9181case BoundKind.WhileStatement: 9183case BoundKind.ForStatement: 9185case BoundKind.ForEachStatement: 9187case BoundKind.ForEachDeconstructStep: 9189case BoundKind.UsingStatement: 9191case BoundKind.FixedStatement: 9193case BoundKind.LockStatement: 9195case BoundKind.TryStatement: 9197case BoundKind.CatchBlock: 9199case BoundKind.Literal: 9201case BoundKind.Utf8String: 9203case BoundKind.ThisReference: 9205case BoundKind.PreviousSubmissionReference: 9207case BoundKind.HostObjectMemberReference: 9209case BoundKind.BaseReference: 9211case BoundKind.Local: 9213case BoundKind.PseudoVariable: 9215case BoundKind.RangeVariable: 9217case BoundKind.Parameter: 9219case BoundKind.LabelStatement: 9221case BoundKind.GotoStatement: 9223case BoundKind.LabeledStatement: 9225case BoundKind.Label: 9227case BoundKind.StatementList: 9229case BoundKind.ConditionalGoto: 9231case BoundKind.SwitchExpressionArm: 9233case BoundKind.UnconvertedSwitchExpression: 9235case BoundKind.ConvertedSwitchExpression: 9237case BoundKind.DecisionDag: 9239case BoundKind.EvaluationDecisionDagNode: 9241case BoundKind.TestDecisionDagNode: 9243case BoundKind.WhenDecisionDagNode: 9245case BoundKind.LeafDecisionDagNode: 9247case BoundKind.DagTemp: 9249case BoundKind.DagTypeTest: 9251case BoundKind.DagNonNullTest: 9253case BoundKind.DagExplicitNullTest: 9255case BoundKind.DagValueTest: 9257case BoundKind.DagRelationalTest: 9259case BoundKind.DagDeconstructEvaluation: 9261case BoundKind.DagTypeEvaluation: 9263case BoundKind.DagFieldEvaluation: 9265case BoundKind.DagPropertyEvaluation: 9267case BoundKind.DagIndexEvaluation: 9269case BoundKind.DagIndexerEvaluation: 9271case BoundKind.DagSliceEvaluation: 9273case BoundKind.DagAssignmentEvaluation: 9275case BoundKind.SwitchSection: 9277case BoundKind.SwitchLabel: 9279case BoundKind.SequencePointExpression: 9281case BoundKind.Sequence: 9283case BoundKind.SpillSequence: 9285case BoundKind.DynamicMemberAccess: 9287case BoundKind.DynamicInvocation: 9289case BoundKind.ConditionalAccess: 9291case BoundKind.LoweredConditionalAccess: 9293case BoundKind.ConditionalReceiver: 9295case BoundKind.ComplexConditionalReceiver: 9297case BoundKind.MethodGroup: 9299case BoundKind.PropertyGroup: 9301case BoundKind.Call: 9303case BoundKind.EventAssignmentOperator: 9305case BoundKind.Attribute: 9307case BoundKind.UnconvertedObjectCreationExpression: 9309case BoundKind.ObjectCreationExpression: 9311case BoundKind.UnconvertedCollectionExpression: 9313case BoundKind.UnconvertedWithElement: 9315case BoundKind.CollectionExpression: 9317case BoundKind.CollectionExpressionSpreadExpressionPlaceholder: 9319case BoundKind.CollectionExpressionSpreadElement: 9321case BoundKind.TupleLiteral: 9323case BoundKind.ConvertedTupleLiteral: 9325case BoundKind.DynamicObjectCreationExpression: 9327case BoundKind.NoPiaObjectCreationExpression: 9329case BoundKind.ObjectInitializerExpression: 9331case BoundKind.ObjectInitializerMember: 9333case BoundKind.DynamicObjectInitializerMember: 9335case BoundKind.CollectionInitializerExpression: 9337case BoundKind.CollectionElementInitializer: 9339case BoundKind.DynamicCollectionElementInitializer: 9341case BoundKind.ImplicitReceiver: 9343case BoundKind.AnonymousObjectCreationExpression: 9345case BoundKind.AnonymousPropertyDeclaration: 9347case BoundKind.NewT: 9349case BoundKind.DelegateCreationExpression: 9351case BoundKind.ArrayCreation: 9353case BoundKind.ArrayInitialization: 9355case BoundKind.StackAllocArrayCreation: 9357case BoundKind.ConvertedStackAllocExpression: 9359case BoundKind.FieldAccess: 9361case BoundKind.HoistedFieldAccess: 9363case BoundKind.PropertyAccess: 9365case BoundKind.EventAccess: 9367case BoundKind.IndexerAccess: 9369case BoundKind.ImplicitIndexerAccess: 9371case BoundKind.InlineArrayAccess: 9373case BoundKind.DynamicIndexerAccess: 9375case BoundKind.Lambda: 9377case BoundKind.UnboundLambda: 9379case BoundKind.QueryClause: 9381case BoundKind.TypeOrInstanceInitializers: 9383case BoundKind.NameOfOperator: 9385case BoundKind.UnconvertedInterpolatedString: 9387case BoundKind.InterpolatedString: 9389case BoundKind.InterpolatedStringHandlerPlaceholder: 9391case BoundKind.InterpolatedStringArgumentPlaceholder: 9393case BoundKind.StringInsert: 9395case BoundKind.IsPatternExpression: 9397case BoundKind.ConstantPattern: 9399case BoundKind.DiscardPattern: 9401case BoundKind.DeclarationPattern: 9403case BoundKind.RecursivePattern: 9405case BoundKind.ListPattern: 9407case BoundKind.SlicePattern: 9409case BoundKind.ITuplePattern: 9411case BoundKind.PositionalSubpattern: 9413case BoundKind.PropertySubpattern: 9415case BoundKind.PropertySubpatternMember: 9417case BoundKind.TypePattern: 9419case BoundKind.BinaryPattern: 9421case BoundKind.NegatedPattern: 9423case BoundKind.RelationalPattern: 9425case BoundKind.DiscardExpression: 9427case BoundKind.ThrowExpression: 9429case BoundKind.OutVariablePendingInference: 9431case BoundKind.DeconstructionVariablePendingInference: 9433case BoundKind.OutDeconstructVarPendingInference: 9435case BoundKind.NonConstructorMethodBody: 9437case BoundKind.ConstructorMethodBody: 9439case BoundKind.ExpressionWithNullability: 9441case BoundKind.WithExpression: 17462internal static PipelinePhase DoesNotSurvive(BoundKind kind) 17466BoundKind.ValuePlaceholder => PipelinePhase.LocalRewriting, 17467BoundKind.DeconstructValuePlaceholder => PipelinePhase.LocalRewriting, 17468BoundKind.TupleOperandPlaceholder => PipelinePhase.InitialBinding, 17469BoundKind.AwaitableValuePlaceholder => PipelinePhase.StateMachineRewriting, 17470BoundKind.DisposableValuePlaceholder => PipelinePhase.InitialBinding, 17471BoundKind.ImplicitIndexerReceiverPlaceholder => PipelinePhase.LocalRewriting, 17472BoundKind.ListPatternReceiverPlaceholder => PipelinePhase.LocalRewriting, 17473BoundKind.ListPatternIndexPlaceholder => PipelinePhase.LocalRewriting, 17474BoundKind.SlicePatternReceiverPlaceholder => PipelinePhase.LocalRewriting, 17475BoundKind.SlicePatternRangePlaceholder => PipelinePhase.LocalRewriting, 17476BoundKind.CollectionBuilderElementsPlaceholder => PipelinePhase.LocalRewriting, 17477BoundKind.TypeOrValueExpression => PipelinePhase.InitialBinding, 17478BoundKind.UnconvertedAddressOfOperator => PipelinePhase.InitialBinding, 17479BoundKind.UnconvertedConditionalOperator => PipelinePhase.InitialBinding, 17480BoundKind.AwaitableInfo => PipelinePhase.StateMachineRewriting, 17481BoundKind.AwaitExpression => PipelinePhase.StateMachineRewriting, 17482BoundKind.DefaultLiteral => PipelinePhase.LocalRewriting, 17483BoundKind.LocalFunctionStatement => PipelinePhase.ClosureConversion, 17484BoundKind.YieldReturnStatement => PipelinePhase.StateMachineRewriting, 17485BoundKind.YieldBreakStatement => PipelinePhase.StateMachineRewriting, 17486BoundKind.IfStatement => PipelinePhase.LocalRewriting, 17487BoundKind.UsingStatement => PipelinePhase.LocalRewriting, 17488BoundKind.UnconvertedSwitchExpression => PipelinePhase.InitialBinding, 17489BoundKind.SpillSequence => PipelinePhase.Spilling, 17490BoundKind.UnconvertedObjectCreationExpression => PipelinePhase.InitialBinding, 17491BoundKind.UnconvertedCollectionExpression => PipelinePhase.InitialBinding, 17492BoundKind.TupleLiteral => PipelinePhase.InitialBinding, 17493BoundKind.TypeOrInstanceInitializers => PipelinePhase.LocalRewriting, 17494BoundKind.UnconvertedInterpolatedString => PipelinePhase.InitialBinding, 17495BoundKind.InterpolatedStringHandlerPlaceholder => PipelinePhase.LocalRewriting, 17496BoundKind.InterpolatedStringArgumentPlaceholder => PipelinePhase.LocalRewriting, 17497BoundKind.DeconstructionVariablePendingInference => PipelinePhase.LocalRewriting,
Lowering\AsyncRewriter\AsyncMethodToStateMachineRewriter.cs (3)
315if (node.Expression.Kind == BoundKind.AwaitExpression) 319else if (node.Expression.Kind == BoundKind.AssignmentOperator) 322if (expression.Right.Kind == BoundKind.AwaitExpression)
Lowering\ClosureConversion\ClosureConversion.Analysis.cs (6)
111case BoundKind.SequencePoint: 115case BoundKind.SequencePointWithSpan: 119case BoundKind.Block: 120case BoundKind.StatementList: 121case BoundKind.FieldEqualsValue: 124case BoundKind.GlobalStatementInitializer:
Lowering\ClosureConversion\ClosureConversion.cs (3)
1109if (visited.Kind != BoundKind.Call) 1336if (node.Argument.Kind == BoundKind.Lambda) 1383receiver.Kind == BoundKind.TypeExpression &&
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (42)
141case BoundKind.ReturnStatement: 149case BoundKind.ExpressionStatement: 151case BoundKind.SequencePoint: 154case BoundKind.SequencePointWithSpan: 187case BoundKind.ArrayAccess: 189case BoundKind.ArrayCreation: 191case BoundKind.ArrayLength: 193case BoundKind.AsOperator: 195case BoundKind.BaseReference: 197case BoundKind.BinaryOperator: 201case BoundKind.UserDefinedConditionalLogicalOperator: 204case BoundKind.Call: 206case BoundKind.ConditionalOperator: 208case BoundKind.Conversion: 210case BoundKind.PassByCopy: 212case BoundKind.DelegateCreationExpression: 214case BoundKind.FieldAccess: 221case BoundKind.IsOperator: 223case BoundKind.Lambda: 225case BoundKind.NewT: 227case BoundKind.NullCoalescingOperator: 229case BoundKind.ObjectCreationExpression: 231case BoundKind.Parameter: 233case BoundKind.PointerIndirectionOperator: 235case BoundKind.PointerElementAccess: 237case BoundKind.PropertyAccess: 239case BoundKind.SizeOfOperator: 241case BoundKind.UnaryOperator: 244case BoundKind.DefaultExpression: 245case BoundKind.HostObjectMemberReference: 246case BoundKind.Literal: 247case BoundKind.Local: 248case BoundKind.MethodInfo: 249case BoundKind.PreviousSubmissionReference: 250case BoundKind.ThisReference: 251case BoundKind.TypeOfOperator: 253case BoundKind.ValuePlaceholder: 540if (operand.Kind == BoundKind.Conversion) 805if (node.Argument.Kind == BoundKind.MethodGroup) 807throw ExceptionUtilities.UnexpectedValue(BoundKind.MethodGroup); 989case BoundKind.ObjectInitializerExpression: 1040case BoundKind.CollectionInitializerExpression:
Lowering\DiagnosticsPass_ExpressionTrees.cs (8)
253if (_inExpressionLambda && node.Left.Kind != BoundKind.ObjectInitializerMember && node.Left.Kind != BoundKind.DynamicObjectInitializerMember) 277bool hasBaseReceiver = node.ReceiverOpt != null && node.ReceiverOpt.Kind == BoundKind.BaseReference; 292bool hasBaseReceiver = node.ReceiverOpt != null && node.ReceiverOpt.Kind == BoundKind.BaseReference; 711if (current.Left.Kind == BoundKind.BinaryOperator) 815if (operand.Kind == BoundKind.FieldAccess) 915if (node.Argument.Kind != BoundKind.MethodGroup) 999if (node.Expression.Kind == BoundKind.MethodGroup)
Lowering\DiagnosticsPass_Warnings.cs (25)
33case BoundKind.FieldAccess: 36case BoundKind.Local: 43case BoundKind.DiscardExpression: 97if (receiverOpt != null && receiverOpt.Kind == BoundKind.FieldAccess) 141while (receiver.Kind == BoundKind.Conversion) 148return receiver.Kind != BoundKind.ThisReference && receiver.Kind != BoundKind.BaseReference; 203case BoundKind.Local: 207case BoundKind.FieldAccess: 212case BoundKind.EventAccess: 217case BoundKind.Parameter: 221case BoundKind.RangeVariable: 225case BoundKind.ThisReference: 226case BoundKind.PreviousSubmissionReference: 227case BoundKind.HostObjectMemberReference: 316if (node.Left.ConstantValueOpt != null && node.Right.ConstantValueOpt == null && node.Right.Kind == BoundKind.Conversion) 321if (node.Right.ConstantValueOpt != null && node.Left.ConstantValueOpt == null && node.Left.Kind == BoundKind.Conversion) 346return node.Kind == BoundKind.Conversion && ((BoundConversion)node).ExplicitCastInCode; 352if (node.Kind != BoundKind.Conversion) return false; 576if (operand.Kind == BoundKind.Conversion) 605if (expr.Kind != BoundKind.Conversion) 864if (node.Kind == BoundKind.Conversion) 888while (right.Kind == BoundKind.Conversion) 903if (right.Kind != BoundKind.ConvertedTupleLiteral && right.Kind != BoundKind.TupleLiteral)
Lowering\Extensions.cs (4)
51if (expr.Kind == BoundKind.ObjectCreationExpression) 56else if (expr.Kind == BoundKind.Conversion) 97if (expr.Kind == BoundKind.ObjectCreationExpression) 103if (expr.Kind == BoundKind.Conversion)
Lowering\InitializerRewriter.cs (4)
46(initializer.Kind == BoundKind.GlobalStatementInitializer) && 84return (statement.Kind == BoundKind.ExpressionStatement) && ((ExpressionStatementSyntax)statement.Syntax).SemicolonToken.IsMissing ? 123case BoundKind.FieldEqualsValue: 125case BoundKind.GlobalStatementInitializer:
Lowering\Instrumentation\CodeCoverageInstrumenter.cs (8)
529case BoundKind.IfStatement: 532case BoundKind.WhileStatement: 535case BoundKind.ForEachStatement: 538case BoundKind.DoStatement: 541case BoundKind.UsingStatement: 547case BoundKind.FixedStatement: 550case BoundKind.LockStatement: 553case BoundKind.SwitchStatement:
Lowering\Instrumentation\DebugInfoInjector.cs (1)
123if (rewritten.Kind == BoundKind.Block)
Lowering\Instrumentation\Instrumenter.cs (1)
307Debug.Assert(original.Kind == BoundKind.SwitchStatement);
Lowering\LocalRewriter\LocalRewriter.cs (44)
290node.Kind is not (BoundKind.ImplicitReceiver or BoundKind.ObjectOrCollectionValuePlaceholder or BoundKind.ValuePlaceholder or BoundKind.CollectionBuilderElementsPlaceholder)) 313return node.Kind == BoundKind.DeconstructionAssignmentOperator && !((BoundDeconstructionAssignmentOperator)node).IsUsed; 718if (initializer.Kind == BoundKind.Block) 890case BoundKind.Block: 895if (initializer.Kind == BoundKind.ExpressionStatement) 897goto case BoundKind.ExpressionStatement; 902case BoundKind.ExpressionStatement: 903return ((BoundExpressionStatement)initializer).Expression.Kind == BoundKind.AssignmentOperator; 920if (statement.Kind != BoundKind.ExpressionStatement) 931Debug.Assert(assignment.Left.Kind == BoundKind.FieldAccess); 1029case BoundKind.Parameter: 1030case BoundKind.Local: 1031case BoundKind.ArrayAccess: 1032case BoundKind.ThisReference: 1033case BoundKind.PointerIndirectionOperator: 1034case BoundKind.PointerElementAccess: 1035case BoundKind.RefValueOperator: 1036case BoundKind.PseudoVariable: 1037case BoundKind.DiscardExpression: 1040case BoundKind.DeconstructValuePlaceholder: 1045case BoundKind.InterpolatedStringArgumentPlaceholder: 1052case BoundKind.InterpolatedStringHandlerPlaceholder: 1057case BoundKind.CollectionExpressionSpreadExpressionPlaceholder: 1061case BoundKind.AwaitableValuePlaceholder: 1066case BoundKind.EventAccess: 1080case BoundKind.FieldAccess: 1091case BoundKind.Sequence: 1094case BoundKind.AssignmentOperator: 1097case BoundKind.ConditionalOperator: 1100case BoundKind.Call: 1103case BoundKind.PropertyAccess: 1106case BoundKind.IndexerAccess: 1109case BoundKind.ImplicitIndexerAccess: 1112case BoundKind.ImplicitIndexerReceiverPlaceholder: 1116case BoundKind.InlineArrayAccess: 1119case BoundKind.ImplicitIndexerValuePlaceholder: 1124case BoundKind.ListPatternReceiverPlaceholder: 1125case BoundKind.SlicePatternReceiverPlaceholder: 1126case BoundKind.SlicePatternRangePlaceholder: 1127case BoundKind.ListPatternIndexPlaceholder: 1130case BoundKind.Conversion:
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (4)
388ImmutableArray<BoundDecisionDagNode> nodesToLower = sortedNodes.WhereAsArray(n => n.Kind != BoundKind.WhenDecisionDagNode && n.Kind != BoundKind.LeafDecisionDagNode); 980if (!sortedNodes.Any(static n => n.Kind == BoundKind.WhenDecisionDagNode)) return; 1192Debug.Assert(left.Kind == BoundKind.Local && left == binding.VariableAccess);
Lowering\LocalRewriter\LocalRewriter.PatternLocalRewriter.cs (4)
534if ((loweredInput.Kind == BoundKind.Local || loweredInput.Kind == BoundKind.Parameter) 659if (canShareInputs && (expr.Kind == BoundKind.Parameter || expr.Kind == BoundKind.Local) && _tempAllocator.TrySetTemp(temp, expr))
Lowering\LocalRewriter\LocalRewriter_AssignmentOperator.cs (19)
29case BoundKind.PropertyAccess: 33case BoundKind.IndexerAccess: 37case BoundKind.ImplicitIndexerAccess: 43case BoundKind.EventAccess: 54case BoundKind.DynamicMemberAccess: 62case BoundKind.DynamicIndexerAccess: 105case BoundKind.DynamicIndexerAccess: 116case BoundKind.DynamicMemberAccess: 125case BoundKind.EventAccess: 185case BoundKind.DynamicIndexerAccess: 186case BoundKind.DynamicMemberAccess: 189case BoundKind.PropertyAccess: 209case BoundKind.IndexerAccess: 230case BoundKind.Local: 231case BoundKind.Parameter: 232case BoundKind.FieldAccess: 242case BoundKind.DiscardExpression: 247case BoundKind.Sequence: 253if (sequence.Value.Kind == BoundKind.IndexerAccess)
Lowering\LocalRewriter\LocalRewriter_BinaryOperator.cs (13)
291if (loweredRight.Kind == BoundKind.Local || loweredRight.Kind == BoundKind.Parameter) 303if (loweredRight.Kind == BoundKind.Local || loweredRight.Kind == BoundKind.Parameter) 490if (loweredLeft.Kind == BoundKind.ArrayLength && loweredRight.IsDefaultValue()) 505if (loweredRight.Kind == BoundKind.ArrayLength && loweredLeft.IsDefaultValue()) 520if (loweredLeft.Kind == BoundKind.ArrayLength && loweredRight.IsDefaultValue()) 524else if (loweredRight.Kind == BoundKind.ArrayLength && loweredLeft.IsDefaultValue()) 660if (constantLeft == null && loweredLeft.Kind != BoundKind.Local && loweredLeft.Kind != BoundKind.Parameter) 721if (expression.Kind == BoundKind.Conversion) 1627if (nonNullRight != null && nonNullRight.ConstantValueOpt != null && left.Kind == BoundKind.Sequence) 1630if (seq.Value.Kind == BoundKind.ConditionalOperator)
Lowering\LocalRewriter\LocalRewriter_Block.cs (2)
111case BoundKind.LabeledStatement: 114case BoundKind.UsingLocalDeclarations:
Lowering\LocalRewriter\LocalRewriter_Call.cs (10)
35case BoundKind.MethodGroup: 43Debug.Assert(methodGroup.ReceiverOpt == null || methodGroup.ReceiverOpt.Kind != BoundKind.TypeOrValueExpression); 71case BoundKind.DynamicMemberAccess: 572case BoundKind.Parameter: 574goto case BoundKind.Local; 576case BoundKind.Local: 580case BoundKind.PassByCopy: 582case BoundKind.Conversion: 1621if (argument.Kind == BoundKind.Local) 1710if (argument.Kind == BoundKind.Local)
Lowering\LocalRewriter\LocalRewriter_CompoundAssignmentOperator.cs (40)
99if (node.Left.Kind == BoundKind.DynamicMemberAccess && 289Debug.Assert(receiverOpt.Kind != BoundKind.TypeExpression); 611Debug.Assert(receiver.Kind != BoundKind.TypeExpression); 723case BoundKind.PropertyAccess: 738case BoundKind.IndexerAccess: 750case BoundKind.ImplicitIndexerAccess: 763case BoundKind.FieldAccess: 780case BoundKind.ArrayAccess: 808case BoundKind.InlineArrayAccess: 812case BoundKind.DynamicMemberAccess: 815case BoundKind.DynamicIndexerAccess: 818case BoundKind.Local: 819case BoundKind.Parameter: 820case BoundKind.ThisReference: // a special kind of parameter 821case BoundKind.PseudoVariable: 829case BoundKind.Call: 833case BoundKind.FunctionPointerInvocation: 837case BoundKind.ConditionalOperator: 841case BoundKind.AssignmentOperator: 845case BoundKind.PointerElementAccess: 846case BoundKind.PointerIndirectionOperator: 847case BoundKind.RefValueOperator: 850case BoundKind.EventAccess: 973case BoundKind.ThisReference: 976case BoundKind.BaseReference: 979case BoundKind.Literal: 983case BoundKind.Parameter: 988case BoundKind.Local: 991case BoundKind.TypeExpression: 1015case BoundKind.Parameter: 1017goto case BoundKind.Local; 1018case BoundKind.Local: 1019case BoundKind.Lambda: 1020case BoundKind.ThisReference: 1021case BoundKind.BaseReference: 1022case BoundKind.Literal: 1025case BoundKind.Conversion: 1030case BoundKind.PassByCopy: 1033case BoundKind.ObjectCreationExpression: 1045case BoundKind.Call:
Lowering\LocalRewriter\LocalRewriter_Conversion.cs (4)
243case BoundKind.Sequence: 247case BoundKind.Conversion: 1320if (operand.Kind == BoundKind.Sequence) 1323if (seq.Value.Kind == BoundKind.ConditionalOperator)
Lowering\LocalRewriter\LocalRewriter_DeconstructionAssignmentOperator.cs (13)
62if (right.Kind == BoundKind.ConditionalOperator) 114Debug.Assert(right is not ({ Kind: BoundKind.TupleLiteral } or BoundConversion { Operand.Kind: BoundKind.TupleLiteral })); 117right is { Kind: BoundKind.ConvertedTupleLiteral } or BoundConversion { Operand.Kind: BoundKind.ConvertedTupleLiteral } 252if (leftTarget.Kind != BoundKind.DiscardExpression) 304if (right.Kind == BoundKind.Conversion) 328private static bool IsTupleExpression(BoundKind kind) 330return kind == BoundKind.TupleLiteral || kind == BoundKind.ConvertedTupleLiteral; 451case BoundKind.DiscardExpression: 455case BoundKind.TupleLiteral: 456case BoundKind.ConvertedTupleLiteral:
Lowering\LocalRewriter\LocalRewriter_DelegateCreationExpression.cs (1)
28if (node.Argument.Kind == BoundKind.MethodGroup)
Lowering\LocalRewriter\LocalRewriter_ExpressionStatement.cs (7)
50case BoundKind.AwaitExpression: 53case BoundKind.AssignmentOperator: 57case BoundKind.CompoundAssignmentOperator: 60case BoundKind.Call: 71case BoundKind.DynamicInvocation: 75case BoundKind.ConditionalAccess: 78case BoundKind.IncrementOperator:
Lowering\LocalRewriter\LocalRewriter_Field.cs (1)
66if (rewrittenReceiver?.Kind == BoundKind.DefaultExpression)
Lowering\LocalRewriter\LocalRewriter_FixedStatement.cs (1)
245Debug.Assert(initializerExpr.Kind == BoundKind.AddressOfOperator);
Lowering\LocalRewriter\LocalRewriter_ForStatement.cs (6)
51Debug.Assert(original.Kind is BoundKind.ForStatement or BoundKind.ForEachStatement or BoundKind.CollectionExpressionSpreadElement); 148case BoundKind.ForEachStatement: 151case BoundKind.ForStatement: 154case BoundKind.CollectionExpressionSpreadElement:
Lowering\LocalRewriter\LocalRewriter_IndexerAccess.cs (8)
536if (node.LengthOrCountAccess.Kind is not BoundKind.Local || receiver.Kind is not (BoundKind.Local or BoundKind.Parameter)) 578if (makeOffsetInput.ConstantValueOpt is null && lengthAccess.Kind is not BoundKind.ArrayLength) 839if (node.LengthOrCountAccess.Kind is not BoundKind.Local || receiver.Kind is not (BoundKind.Local or BoundKind.Parameter)) 990if ((rewriteFlags & captureLength) != 0 && lengthAccess.Kind is not BoundKind.Local)
Lowering\LocalRewriter\LocalRewriter_IsOperator.cs (2)
33if (rewrittenOperand.Kind == BoundKind.MethodGroup) 37if (receiver != null && receiver.Kind != BoundKind.ThisReference)
Lowering\LocalRewriter\LocalRewriter_IsPatternOperator.cs (2)
244while (node.Kind != BoundKind.LeafDecisionDagNode && node.Kind != BoundKind.WhenDecisionDagNode)
Lowering\LocalRewriter\LocalRewriter_NullCoalescingAssignmentOperator.cs (2)
103Debug.Assert(!_inExpressionLambda && lhsRead.Kind != BoundKind.PropertyAccess); 107if (lhsRead.Kind == BoundKind.Call)
Lowering\LocalRewriter\LocalRewriter_NullCoalescingOperator.cs (2)
192if (expression.Kind != BoundKind.Call) 221while (expression.Kind == BoundKind.Conversion)
Lowering\LocalRewriter\LocalRewriter_ObjectOrCollectionInitializerExpression.cs (12)
72case BoundKind.ObjectInitializerExpression: 75case BoundKind.CollectionInitializerExpression: 91if (initializer.Kind != BoundKind.CollectionElementInitializer) 137if (initializer.Kind == BoundKind.CollectionElementInitializer) 144Debug.Assert(initializer.Kind == BoundKind.DynamicCollectionElementInitializer); 314bool isRhsNestedInitializer = right.Kind is BoundKind.ObjectInitializerExpression or BoundKind.CollectionInitializerExpression; 327case BoundKind.ObjectInitializerMember: 408case BoundKind.DynamicObjectInitializerMember: 434case BoundKind.ArrayAccess: 480case BoundKind.PointerElementAccess: 513case BoundKind.ImplicitIndexerAccess:
Lowering\LocalRewriter\LocalRewriter_StringConcat.cs (1)
627if (expr.Kind == BoundKind.Conversion)
Lowering\LocalRewriter\LocalRewriter_StringInterpolation.cs (1)
191if (length == 1 && result is not ({ Kind: BoundKind.InterpolatedString } or { ConstantValueOpt.IsString: true }))
Lowering\LocalRewriter\LocalRewriter_TryStatement.cs (4)
52case BoundKind.NoOpStatement: 54case BoundKind.Block: 63case BoundKind.SequencePoint: 68case BoundKind.SequencePointWithSpan:
Lowering\LocalRewriter\LocalRewriter_UnaryOperator.cs (10)
46if (node.Operand.Kind == BoundKind.BinaryOperator) 322if (loweredOperand.Kind == BoundKind.Sequence) 325if (seq.Value.Kind == BoundKind.ConditionalOperator) 636case BoundKind.Local: 639case BoundKind.Parameter: 643case BoundKind.FieldAccess: 1023case BoundKind.PropertyAccess: 1027case BoundKind.DynamicMemberAccess: 1031case BoundKind.IndexerAccess: 1035case BoundKind.DynamicIndexerAccess:
Lowering\LocalRewriter\LocalRewriter_UsingStatement.cs (1)
40BoundBlock tryBlock = rewrittenBody.Kind == BoundKind.Block
Lowering\LocalRewriter\LocalRewriter_WhileStatement.cs (6)
49Debug.Assert(loop.Kind is BoundKind.WhileStatement or BoundKind.ForEachStatement or BoundKind.CollectionExpressionSpreadElement); 74case BoundKind.WhileStatement: 78case BoundKind.ForEachStatement: 82case BoundKind.CollectionExpressionSpreadElement:
Lowering\LocalRewriter\LoweredDynamicOperationFactory.cs (2)
226if (loweredReceiver.Kind == BoundKind.TypeExpression) 673int discardCount = loweredArguments.Count(a => a.Kind == BoundKind.DiscardExpression);
Lowering\MethodToClassRewriter.cs (6)
259if (originalLeft.Kind != BoundKind.Local) 273Debug.Assert(originalRight.Kind != BoundKind.ConvertedStackAllocExpression); 295if (rewrittenLeft.Kind != BoundKind.Local && originalRight.Kind == BoundKind.ConvertedStackAllocExpression) 377return originalReceiver is { Kind: BoundKind.BaseReference } && 378rewrittenReceiver is { Kind: not BoundKind.BaseReference };
Lowering\SpillSequenceSpiller.cs (22)
19private const BoundKind SpillSequenceBuilderKind = (BoundKind)byte.MaxValue; 316case BoundKind.ArrayInitialization: 323case BoundKind.ArgListOperator: 336case BoundKind.Sequence: 349case BoundKind.AssignmentOperator: 352assignment is not { Left.Kind: BoundKind.Local, Right.Kind: BoundKind.ArrayAccess }) // Optimize for some known to be safe scenarios. 378case BoundKind.ThisReference: 379case BoundKind.BaseReference: 387case BoundKind.Parameter: 395case BoundKind.Local: 404case BoundKind.FieldAccess: 422case BoundKind.Literal: 423case BoundKind.TypeExpression: 426case BoundKind.ConditionalReceiver: 431case BoundKind.Call: 479case BoundKind.ObjectCreationExpression: 885case BoundKind.Local: 886case BoundKind.Parameter: 890case BoundKind.FieldAccess: 899case BoundKind.ArrayAccess:
Lowering\StateMachineRewriter\IteratorAndAsyncCaptureWalker.cs (1)
316if (node.ReceiverOpt != null && node.ReceiverOpt.Kind == BoundKind.ThisReference)
Lowering\StateMachineRewriter\MethodToStateMachineRewriter.cs (3)
417if (statement.Kind == BoundKind.Block) 421if (rewrittenStatements.Length == 1 && rewrittenStatements[0].Kind == BoundKind.StateMachineScope) 620if (node.Left.Kind != BoundKind.Local)
Lowering\StateMachineRewriter\RefInitializationHoister.cs (8)
149case BoundKind.ArrayAccess: 186case BoundKind.FieldAccess: 216if (receiver.Kind != BoundKind.ThisReference && !isFieldOfStruct) 225case BoundKind.ThisReference: 226case BoundKind.BaseReference: 227case BoundKind.DefaultExpression: 230case BoundKind.Call: 251case BoundKind.ConditionalOperator:
Lowering\SyntheticBoundNodeFactory.cs (3)
586if (body.Kind != BoundKind.Block) 1742var discardsPresent = arguments.Any(static a => a.Kind == BoundKind.DiscardExpression); 1747(arg, t) => arg.Kind == BoundKind.DiscardExpression ? t.factory.MakeTempForDiscard((BoundDiscardExpression)arg, t.builder) : arg,
Operations\CSharpOperationFactory.cs (173)
36case BoundKind.DeconstructValuePlaceholder: 38case BoundKind.DeconstructionAssignmentOperator: 40case BoundKind.Call: 42case BoundKind.Local: 44case BoundKind.FieldAccess: 46case BoundKind.PropertyAccess: 48case BoundKind.IndexerAccess: 50case BoundKind.EventAccess: 52case BoundKind.EventAssignmentOperator: 54case BoundKind.Parameter: 56case BoundKind.Literal: 58case BoundKind.Utf8String: 60case BoundKind.DynamicInvocation: 62case BoundKind.DynamicIndexerAccess: 64case BoundKind.ObjectCreationExpression: 66case BoundKind.WithExpression: 68case BoundKind.DynamicObjectCreationExpression: 70case BoundKind.ObjectInitializerExpression: 72case BoundKind.CollectionInitializerExpression: 74case BoundKind.ObjectInitializerMember: 76case BoundKind.CollectionElementInitializer: 78case BoundKind.DynamicObjectInitializerMember: 80case BoundKind.DynamicMemberAccess: 82case BoundKind.DynamicCollectionElementInitializer: 84case BoundKind.UnboundLambda: 86case BoundKind.Lambda: 88case BoundKind.Conversion: 90case BoundKind.AsOperator: 92case BoundKind.IsOperator: 94case BoundKind.SizeOfOperator: 96case BoundKind.TypeOfOperator: 98case BoundKind.ArrayCreation: 100case BoundKind.ArrayInitialization: 102case BoundKind.CollectionExpression: 104case BoundKind.DefaultLiteral: 106case BoundKind.DefaultExpression: 108case BoundKind.BaseReference: 110case BoundKind.ThisReference: 112case BoundKind.AssignmentOperator: 114case BoundKind.CompoundAssignmentOperator: 116case BoundKind.IncrementOperator: 118case BoundKind.BadExpression: 120case BoundKind.NewT: 122case BoundKind.NoPiaObjectCreationExpression: 124case BoundKind.UnaryOperator: 126case BoundKind.BinaryOperator: 127case BoundKind.UserDefinedConditionalLogicalOperator: 129case BoundKind.TupleBinaryOperator: 131case BoundKind.ConditionalOperator: 133case BoundKind.NullCoalescingOperator: 135case BoundKind.AwaitExpression: 137case BoundKind.ArrayAccess: 139case BoundKind.ImplicitIndexerAccess: 141case BoundKind.InlineArrayAccess: 143case BoundKind.NameOfOperator: 145case BoundKind.ThrowExpression: 147case BoundKind.AddressOfOperator: 149case BoundKind.ImplicitReceiver: 151case BoundKind.ConditionalAccess: 153case BoundKind.ConditionalReceiver: 155case BoundKind.FieldEqualsValue: 157case BoundKind.PropertyEqualsValue: 159case BoundKind.ParameterEqualsValue: 161case BoundKind.Block: 163case BoundKind.ContinueStatement: 165case BoundKind.BreakStatement: 167case BoundKind.YieldBreakStatement: 169case BoundKind.GotoStatement: 171case BoundKind.NoOpStatement: 173case BoundKind.IfStatement: 175case BoundKind.WhileStatement: 177case BoundKind.DoStatement: 179case BoundKind.ForStatement: 181case BoundKind.ForEachStatement: 183case BoundKind.TryStatement: 185case BoundKind.CatchBlock: 187case BoundKind.FixedStatement: 189case BoundKind.UsingStatement: 191case BoundKind.ThrowStatement: 193case BoundKind.ReturnStatement: 195case BoundKind.YieldReturnStatement: 197case BoundKind.LockStatement: 199case BoundKind.BadStatement: 201case BoundKind.LocalDeclaration: 203case BoundKind.MultipleLocalDeclarations: 204case BoundKind.UsingLocalDeclarations: 206case BoundKind.LabelStatement: 208case BoundKind.LabeledStatement: 210case BoundKind.ExpressionStatement: 212case BoundKind.TupleLiteral: 213case BoundKind.ConvertedTupleLiteral: 215case BoundKind.InterpolatedString: 217case BoundKind.StringInsert: 219case BoundKind.LocalFunctionStatement: 221case BoundKind.AnonymousObjectCreationExpression: 223case BoundKind.ConstantPattern: 225case BoundKind.DeclarationPattern: 227case BoundKind.RecursivePattern: 229case BoundKind.ITuplePattern: 231case BoundKind.DiscardPattern: 233case BoundKind.BinaryPattern: 235case BoundKind.NegatedPattern: 237case BoundKind.RelationalPattern: 239case BoundKind.TypePattern: 241case BoundKind.SlicePattern: 243case BoundKind.ListPattern: 245case BoundKind.SwitchStatement: 247case BoundKind.SwitchLabel: 249case BoundKind.IsPatternExpression: 251case BoundKind.QueryClause: 253case BoundKind.DelegateCreationExpression: 255case BoundKind.RangeVariable: 257case BoundKind.ConstructorMethodBody: 259case BoundKind.NonConstructorMethodBody: 261case BoundKind.DiscardExpression: 263case BoundKind.NullCoalescingAssignmentOperator: 265case BoundKind.FromEndIndexExpression: 267case BoundKind.RangeExpression: 269case BoundKind.SwitchSection: 271case BoundKind.ConvertedSwitchExpression: 273case BoundKind.SwitchExpressionArm: 275case BoundKind.ObjectOrCollectionValuePlaceholder: 277case BoundKind.FunctionPointerInvocation: 279case BoundKind.UnconvertedAddressOfOperator: 281case BoundKind.InterpolatedStringArgumentPlaceholder: 283case BoundKind.InterpolatedStringHandlerPlaceholder: 285case BoundKind.Attribute: 288case BoundKind.ArgList: 289case BoundKind.ArgListOperator: 290case BoundKind.ConvertedStackAllocExpression: 291case BoundKind.FixedLocalCollectionInitializer: 292case BoundKind.GlobalStatementInitializer: 293case BoundKind.HostObjectMemberReference: 294case BoundKind.MakeRefOperator: 295case BoundKind.MethodGroup: 296case BoundKind.NamespaceExpression: 297case BoundKind.PointerElementAccess: 298case BoundKind.PointerIndirectionOperator: 299case BoundKind.PreviousSubmissionReference: 300case BoundKind.RefTypeOperator: 301case BoundKind.RefValueOperator: 302case BoundKind.Sequence: 303case BoundKind.StackAllocArrayCreation: 304case BoundKind.TypeExpression: 305case BoundKind.TypeOrValueExpression: 313case BoundKind.FixedLocalCollectionInitializer: 325case BoundKind.CollectionBuilderElementsPlaceholder: 333case BoundKind.UnconvertedInterpolatedString: 334case BoundKind.UnconvertedConditionalOperator: 335case BoundKind.UnconvertedSwitchExpression: 336case BoundKind.AnonymousPropertyDeclaration: 407case BoundKind.LocalDeclaration: 411case BoundKind.MultipleLocalDeclarations: 412case BoundKind.UsingLocalDeclarations: 531case BoundKind.LocalDeclaration: 537case BoundKind.MultipleLocalDeclarations: 538case BoundKind.UsingLocalDeclarations: 973if (receiver?.Kind == BoundKind.TypeExpression) 1085Debug.Assert(boundOperand.Kind == BoundKind.BadExpression || 1087ExpressionOpt?.Kind == BoundKind.BadExpression); 1097if (boundOperand.Kind == BoundKind.ConvertedTupleLiteral && TypeSymbol.Equals(boundOperand.Type, boundConversion.Type, TypeCompareKind.ConsiderEverything2)) 1111if (boundConversion.ExplicitCastInCode && conversion.IsIdentity && boundOperand.Kind == BoundKind.Conversion) 1117nestedOperand.Kind == BoundKind.ConvertedTupleLiteral && 1133if ((boundOperand.Kind == BoundKind.Lambda || 1134boundOperand.Kind == BoundKind.UnboundLambda || 1135boundOperand.Kind == BoundKind.MethodGroup) && 1377boundAssignmentOperator.Right?.Kind == BoundKind.ObjectInitializerExpression || 1378boundAssignmentOperator.Right?.Kind == BoundKind.CollectionInitializerExpression; 1684if (boundIndexerAccess.LengthOrCountAccess.Kind == BoundKind.ArrayLength) 2321if (part.Kind == BoundKind.StringInsert) 2580if (variable == null && boundDeclarationPattern.VariableAccess?.Kind == BoundKind.DiscardExpression) 2794Debug.Assert(boundSwitchLabel.Pattern.Kind == BoundKind.DiscardPattern); 2798boundSwitchLabel.Pattern.Kind == BoundKind.ConstantPattern &&
Operations\CSharpOperationFactory_Methods.cs (14)
25if (statement.Kind == BoundKind.StatementList) 100if (instance == null || instance.Kind == BoundKind.TypeExpression) 106if (symbol != null && symbol.IsStatic && instance.WasCompilerGenerated && instance.Kind == BoundKind.ThisReference) 163if (boundDelegateCreationExpression.Argument.Kind == BoundKind.MethodGroup && 198case BoundKind.ObjectInitializerMember: 209case BoundKind.IndexerAccess: 217case BoundKind.ObjectCreationExpression: 225case BoundKind.Attribute: 232case BoundKind.Call: 241case BoundKind.CollectionElementInitializer: 250case BoundKind.FunctionPointerInvocation: 393|| (receiverOpt.Kind != BoundKind.ThisReference 394&& receiverOpt.Kind != BoundKind.BaseReference 395&& receiverOpt.Kind != BoundKind.ObjectOrCollectionValuePlaceholder)))
Symbols\ConstantValueUtils.cs (1)
97while (unconvertedBoundValue.Kind == BoundKind.Conversion)
Symbols\FunctionTypeSymbol.cs (2)
68Debug.Assert(expression.Kind is BoundKind.MethodGroup or BoundKind.UnboundLambda);
Symbols\Source\ParameterHelpers.cs (4)
1107case BoundKind.DefaultLiteral: 1108case BoundKind.DefaultExpression: 1110case BoundKind.ObjectCreationExpression: 1112case BoundKind.Conversion:
Symbols\Source\SourceComplexParameterSymbol.cs (1)
407if (convertedExpression.ConstantValueOpt == null && convertedExpression.Kind == BoundKind.Conversion &&
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (19)
Semantics\ConstantTests.cs (4)
592var actual = ParseAndGetConstantFoldingSteps(source, node => node.Kind == BoundKind.BinaryOperator); 641var actual = ParseAndGetConstantFoldingSteps(source, node => node.Kind == BoundKind.UnaryOperator); 1448return ParseAndGetConstantFoldingSteps(source, node => node.Kind != BoundKind.Literal && node.Kind != BoundKind.Local);
Semantics\FieldInitializerBindingTests.cs (1)
274Assert.Equal(BoundKind.FieldEqualsValue, boundInit.Kind);
Semantics\SemanticAnalyzerTests.cs (14)
1332Assert.Equal(BoundKind.LocalDeclaration, block.Statements[0].Kind); 1335Assert.Equal(BoundKind.ObjectCreationExpression, decl.InitializerOpt.Kind); 1360Assert.Equal(BoundKind.LocalDeclaration, block.Statements[0].Kind); 1363Assert.Equal(BoundKind.ObjectCreationExpression, decl.InitializerOpt.Kind); 1388Assert.Equal(BoundKind.LocalDeclaration, block.Statements[0].Kind); 1391Assert.Equal(BoundKind.ObjectCreationExpression, decl.InitializerOpt.Kind); 1425Assert.Equal(BoundKind.LocalDeclaration, block.Statements[0].Kind); 1428Assert.Equal(BoundKind.ObjectCreationExpression, decl.InitializerOpt.Kind); 1459Assert.Equal(BoundKind.LocalDeclaration, block.Statements[0].Kind); 1462Assert.Equal(BoundKind.ObjectCreationExpression, decl.InitializerOpt.Kind); 1494Assert.Equal(BoundKind.LocalDeclaration, block.Statements[0].Kind); 1497Assert.Equal(BoundKind.ObjectCreationExpression, decl.InitializerOpt.Kind); 1529Assert.Equal(BoundKind.LocalDeclaration, block.Statements[0].Kind); 1532Assert.Equal(BoundKind.ObjectCreationExpression, decl.InitializerOpt.Kind);