43 references to True
Microsoft.CodeAnalysis.CSharp (43)
Binder\Binder_Operators.cs (10)
2932
return (leftIsNull == rightIsNull) == (op == BinaryOperatorKind.Equal) ? ConstantValue.
True
: ConstantValue.False;
5022
Debug.Assert(constantValue == ConstantValue.
True
|| constantValue == ConstantValue.False);
5024
ErrorCode errorCode = constantValue == ConstantValue.
True
? ErrorCode.WRN_IsAlwaysTrue : ErrorCode.WRN_IsAlwaysFalse;
5033
/// - <see cref="ConstantValue.
True
"/>
5268
return operandCouldBeNull ? null : ConstantValue.
True
;
5277
return operandCouldBeNull ? null : ConstantValue.
True
;
5292
return operandCouldBeNull ? null : ConstantValue.
True
;
5309
return operandCouldBeNull ? null : ConstantValue.
True
;
5321
? ConstantValue.
True
: ConstantValue.False;
6069
else if (conditionValue == ConstantValue.
True
)
Binder\Binder_Patterns.cs (2)
1156
/// - <see cref="ConstantValue.
True
"/> if the matched type catches all of them
1177
return ConstantValue.
True
;
Binder\DecisionDagBuilder.cs (9)
758
Tests test = MakeConstantTest(syntax, temp, sense ? ConstantValue.
True
: ConstantValue.False);
803
Tests test = MakeConstantTest(syntax, boolResult, ConstantValue.
True
);
2088
else if (matches == ConstantValue.
True
)
2098
if (matches == ConstantValue.
True
)
2323
Debug.Assert((hasValueTest.Value == ConstantValue.
True
|| hasValueTest.Value == ConstantValue.False));
2324
if (hasValueTest.Value == ConstantValue.
True
|| hasValueTest.Value == ConstantValue.False)
2326
sense = hasValueTest.Value == ConstantValue.
True
;
2341
bool isTrue = tryGetValueTest.Value == ConstantValue.
True
;
3135
public bool IsFullyMatched => RemainingTests is Tests.True && (WhenClause is null || WhenClause.ConstantValueOpt == ConstantValue.
True
);
FlowAnalysis\AbstractFlowPass.cs (1)
678
return node.ConstantValueOpt == ConstantValue.
True
;
FlowAnalysis\NullableWalker.DebugVerifier.cs (1)
385
if (node.WhenClause?.ConstantValueOpt != ConstantValue.
True
)
FlowAnalysis\NullableWalker_Patterns.cs (1)
652
if (w.WhenExpression != null && w.WhenExpression.ConstantValueOpt != ConstantValue.
True
)
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (2)
1017
if (whenExpression is not null && whenExpression.ConstantValueOpt != ConstantValue.
True
)
1169
if (whenClause.WhenExpression != null && whenClause.WhenExpression.ConstantValueOpt != ConstantValue.
True
)
Lowering\LocalRewriter\LocalRewriter_BinaryOperator.cs (13)
287
if (loweredRight.ConstantValueOpt == ConstantValue.
True
) return loweredLeft;
288
if (loweredLeft.ConstantValueOpt == ConstantValue.
True
) return loweredRight;
301
if (loweredLeft.ConstantValueOpt == ConstantValue.
True
) return loweredLeft;
311
if (loweredRight.ConstantValueOpt == ConstantValue.
True
) return loweredLeft;
312
if (loweredLeft.ConstantValueOpt == ConstantValue.
True
) return loweredRight;
337
if (loweredLeft.ConstantValueOpt == ConstantValue.
True
) return loweredRight;
338
if (loweredRight.ConstantValueOpt == ConstantValue.
True
) return loweredLeft;
356
if (loweredLeft.ConstantValueOpt == ConstantValue.
True
)
359
if (loweredRight.ConstantValueOpt == ConstantValue.
True
)
370
if (loweredLeft.ConstantValueOpt == ConstantValue.
True
)
373
if (loweredRight.ConstantValueOpt == ConstantValue.
True
)
635
testOperator == UnaryOperatorKind.DynamicTrue && constantLeft == ConstantValue.
True
)
677
bool leftTestIsConstantFalse = testOperator == UnaryOperatorKind.DynamicFalse && constantLeft == ConstantValue.
True
||
Lowering\LocalRewriter\LocalRewriter_ConditionalOperator.cs (1)
52
if (conditionConstantValue == ConstantValue.
True
)
Lowering\LocalRewriter\LocalRewriter_IsOperator.cs (1)
86
Debug.Assert(constantValue == ConstantValue.
True
|| constantValue == ConstantValue.False);
Lowering\LocalRewriter\LocalRewriter_UnaryOperator.cs (1)
91
if (constant == ConstantValue.
True
|| constant == ConstantValue.False)
Utilities\TypeUnionValueSet.cs (1)
241
else if (matches == ConstantValue.
True
)