Base:
property
ConstantValueOpt
Microsoft.CodeAnalysis.CSharp.BoundExpression.ConstantValueOpt
2 writes to ConstantValueOpt
Microsoft.CodeAnalysis.CSharp (2)
Generated\BoundNodes.xml.Generated.cs (2)
4192this.ConstantValueOpt = constantValueOpt; 4198this.ConstantValueOpt = constantValueOpt;
18 references to ConstantValueOpt
Microsoft.CodeAnalysis.CSharp (18)
Binder\Binder_Expressions.cs (1)
6651if (boundLeft.Kind == BoundKind.Literal && ((BoundLiteral)boundLeft).ConstantValueOpt == ConstantValue.Null)
Binder\Binder_InterpolatedString.cs (3)
784Debug.Assert(boundLiteral.ConstantValueOpt != null && boundLiteral.ConstantValueOpt.IsString); 785var literalText = boundLiteral.ConstantValueOpt.StringValue;
BoundTree\BoundNode_Source.cs (2)
223var value = literal.ConstantValueOpt?.Value?.ToString(); 229switch (literal.ConstantValueOpt?.Discriminator)
BoundTree\Formatting.cs (1)
39get { return ConstantValueOpt?.IsNull == true ? MessageID.IDS_NULL.Localize() : base.Display; }
FlowAnalysis\NullableWalker.cs (1)
10675SetResultType(node, TypeWithState.Create(node.Type, node.Type?.CanContainNull() != false && node.ConstantValueOpt?.IsNull == true ? NullableFlowState.MaybeDefault : NullableFlowState.NotNull));
Generated\BoundNodes.xml.Generated.cs (4)
4208if (constantValueOpt != this.ConstantValueOpt || !TypeSymbol.Equals(type, this.Type, TypeCompareKind.ConsiderEverything)) 11049return node.Update(node.ConstantValueOpt, type); 13012BoundLiteral updatedNode = node.Update(node.ConstantValueOpt, infoAndType.Type); 15384new TreeDumperNode("constantValueOpt", node.ConstantValueOpt, null),
Lowering\ClosureConversion\ExpressionLambdaRewriter.cs (1)
488return Constant(literal.Update(literal.ConstantValueOpt, promotedType));
Lowering\LocalRewriter\LocalRewriter_Literal.cs (2)
19Debug.Assert(node.ConstantValueOpt is { }); 20return MakeLiteral(node.Syntax, node.ConstantValueOpt, node.Type, oldNodeOpt: node);
Lowering\LocalRewriter\LocalRewriter_StringInterpolation.cs (2)
230Debug.Assert(fillin.Format.ConstantValueOpt is { }); 231stringBuilder.Append(':').Append(fillin.Format.ConstantValueOpt.StringValue);
Operations\CSharpOperationFactory.cs (1)
675ConstantValue? constantValue = boundLiteral.ConstantValueOpt;