43 references to True
Microsoft.CodeAnalysis.CSharp (43)
Binder\Binder_Operators.cs (10)
2932return (leftIsNull == rightIsNull) == (op == BinaryOperatorKind.Equal) ? ConstantValue.True : ConstantValue.False; 5049Debug.Assert(constantValue == ConstantValue.True || constantValue == ConstantValue.False); 5051ErrorCode errorCode = constantValue == ConstantValue.True ? ErrorCode.WRN_IsAlwaysTrue : ErrorCode.WRN_IsAlwaysFalse; 5060/// - <see cref="ConstantValue.True"/> 5295return operandCouldBeNull ? null : ConstantValue.True; 5304return operandCouldBeNull ? null : ConstantValue.True; 5319return operandCouldBeNull ? null : ConstantValue.True; 5336return operandCouldBeNull ? null : ConstantValue.True; 5348? ConstantValue.True : ConstantValue.False; 6096else if (conditionValue == ConstantValue.True)
Binder\Binder_Patterns.cs (2)
1397/// - <see cref="ConstantValue.True"/> if the matched type catches all of them 1418return ConstantValue.True;
Binder\DecisionDagBuilder.cs (9)
752Tests test = MakeConstantTest(syntax, temp, sense ? ConstantValue.True : ConstantValue.False); 797Tests test = MakeConstantTest(syntax, boolResult, ConstantValue.True); 2115else if (matches == ConstantValue.True) 2125if (matches == ConstantValue.True) 2350Debug.Assert((hasValueTest.Value == ConstantValue.True || hasValueTest.Value == ConstantValue.False)); 2351if (hasValueTest.Value == ConstantValue.True || hasValueTest.Value == ConstantValue.False) 2353sense = hasValueTest.Value == ConstantValue.True; 2368bool isTrue = tryGetValueTest.Value == ConstantValue.True; 3162public bool IsFullyMatched => RemainingTests is Tests.True && (WhenClause is null || WhenClause.ConstantValueOpt == ConstantValue.True);
FlowAnalysis\AbstractFlowPass.cs (1)
678return node.ConstantValueOpt == ConstantValue.True;
FlowAnalysis\NullableWalker.DebugVerifier.cs (1)
385if (node.WhenClause?.ConstantValueOpt != ConstantValue.True)
FlowAnalysis\NullableWalker_Patterns.cs (1)
654if (w.WhenExpression != null && w.WhenExpression.ConstantValueOpt != ConstantValue.True)
Lowering\LocalRewriter\LocalRewriter.DecisionDagRewriter.cs (2)
1017if (whenExpression is not null && whenExpression.ConstantValueOpt != ConstantValue.True) 1169if (whenClause.WhenExpression != null && whenClause.WhenExpression.ConstantValueOpt != ConstantValue.True)
Lowering\LocalRewriter\LocalRewriter_BinaryOperator.cs (13)
287if (loweredRight.ConstantValueOpt == ConstantValue.True) return loweredLeft; 288if (loweredLeft.ConstantValueOpt == ConstantValue.True) return loweredRight; 301if (loweredLeft.ConstantValueOpt == ConstantValue.True) return loweredLeft; 311if (loweredRight.ConstantValueOpt == ConstantValue.True) return loweredLeft; 312if (loweredLeft.ConstantValueOpt == ConstantValue.True) return loweredRight; 337if (loweredLeft.ConstantValueOpt == ConstantValue.True) return loweredRight; 338if (loweredRight.ConstantValueOpt == ConstantValue.True) return loweredLeft; 356if (loweredLeft.ConstantValueOpt == ConstantValue.True) 359if (loweredRight.ConstantValueOpt == ConstantValue.True) 370if (loweredLeft.ConstantValueOpt == ConstantValue.True) 373if (loweredRight.ConstantValueOpt == ConstantValue.True) 635testOperator == UnaryOperatorKind.DynamicTrue && constantLeft == ConstantValue.True) 677bool leftTestIsConstantFalse = testOperator == UnaryOperatorKind.DynamicFalse && constantLeft == ConstantValue.True ||
Lowering\LocalRewriter\LocalRewriter_ConditionalOperator.cs (1)
52if (conditionConstantValue == ConstantValue.True)
Lowering\LocalRewriter\LocalRewriter_IsOperator.cs (1)
86Debug.Assert(constantValue == ConstantValue.True || constantValue == ConstantValue.False);
Lowering\LocalRewriter\LocalRewriter_UnaryOperator.cs (1)
91if (constant == ConstantValue.True || constant == ConstantValue.False)
Utilities\TypeUnionValueSet.cs (1)
254else if (matches == ConstantValue.True)