1 write to InitializerOpt
Microsoft.CodeAnalysis.CSharp (1)
Generated\BoundNodes.xml.Generated.cs (1)
7128
this.
InitializerOpt
= initializerOpt;
26 references to InitializerOpt
Microsoft.CodeAnalysis.CSharp (26)
Binder\Binder_Attributes.cs (2)
985
if (node.
InitializerOpt
== null)
1006
initializer = VisitArguments(node.
InitializerOpt
.Initializers, diagnostics, ref attrHasErrors, curArgumentHasErrors);
BoundTree\BoundNode.cs (1)
362
this is BoundArrayCreation { Bounds: [BoundLiteral { WasCompilerGenerated: true }],
InitializerOpt
: BoundArrayInitialization { WasCompilerGenerated: true }, WasCompilerGenerated: true } or
CodeGen\EmitArrayInitializer.cs (2)
473
if (wrappedExpression is not BoundArrayCreation {
InitializerOpt
: { } initializer } ac)
691
var initializer = arrayCreation.
InitializerOpt
;
CodeGen\EmitExpression.cs (2)
2388
if (expression.
InitializerOpt
!= null)
2390
EmitArrayInitializers(arrayType, expression.
InitializerOpt
);
FlowAnalysis\AbstractFlowPass.cs (1)
2829
VisitRvalue(node.
InitializerOpt
);
FlowAnalysis\NullableWalker.cs (2)
4552
var initialization = node.
InitializerOpt
;
7013
elements = array.
InitializerOpt
!.Initializers;
FlowAnalysis\NullableWalker.DebugVerifier.cs (1)
110
this.Visit(node.
InitializerOpt
);
Generated\BoundNodes.xml.Generated.cs (5)
7140
if (bounds != this.Bounds || initializerOpt != this.
InitializerOpt
|| !TypeSymbol.Equals(type, this.Type, TypeCompareKind.ConsiderEverything))
10576
this.Visit(node.
InitializerOpt
);
11903
BoundArrayInitialization? initializerOpt = (BoundArrayInitialization?)this.Visit(node.
InitializerOpt
);
14343
BoundArrayInitialization? initializerOpt = (BoundArrayInitialization?)this.Visit(node.
InitializerOpt
);
16667
new TreeDumperNode("initializerOpt", null, new TreeDumperNode[] { Visit(node.
InitializerOpt
, null) }),
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (2)
341
if (node.
InitializerOpt
!= null)
345
return _bound.StaticCall(WellKnownMember.System_Linq_Expressions_Expression__NewArrayInit, boundType, Expressions(node.
InitializerOpt
.Initializers));
Lowering\DiagnosticsPass_ExpressionTrees.cs (1)
81
if (_inExpressionLambda && node.
InitializerOpt
!= null && !arrayType.IsSZArray)
Lowering\LocalRewriter\LocalRewriter_Call.cs (1)
1261
if (paramsArray is BoundArrayCreation { Bounds: [BoundLiteral] bounds,
InitializerOpt
: BoundArrayInitialization { Initializers: var elements } initialization } creation)
Lowering\LocalRewriter\LocalRewriter_ObjectOrCollectionInitializerExpression.cs (1)
543
if (argument is BoundArrayCreation { IsParamsArrayOrCollection: true,
InitializerOpt
: var initializers })
Lowering\LocalRewriter\LocalRewriter_StringConcat.cs (1)
188
var initializer = args.
InitializerOpt
;
Lowering\SpillSequenceSpiller.cs (1)
808
var init = (BoundArrayInitialization)VisitExpression(ref builder, node.
InitializerOpt
);
Operations\CSharpOperationFactory.cs (3)
1207
IArrayInitializerOperation? arrayInitializer = (IArrayInitializerOperation?)Create(boundArrayCreation.
InitializerOpt
);
1211
(boundArrayCreation.
InitializerOpt
?.Syntax == syntax && !boundArrayCreation.
InitializerOpt
.WasCompilerGenerated);