22 references to WRN_GivenExpressionNeverMatchesPattern
Microsoft.CodeAnalysis.CSharp (4)
Binder\Binder_Patterns.cs (1)
104
diagnostics.Add(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, node.Location);
Errors\ErrorFacts.cs (2)
465
case ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
:
1936
or ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
Generated\ErrorFacts.Generated.cs (1)
190
case ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
:
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (16)
Semantics\PatternMatchingTests.cs (4)
3169
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "1L is int.MaxValue").WithLocation(8, 27),
3172
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "1 is int.MaxValue").WithLocation(9, 27),
6032
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "s is string s2").WithLocation(9, 13),
6445
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "s is string t").WithLocation(8, 13)
Semantics\PatternMatchingTests2.cs (9)
1384
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "3 is 4").WithLocation(5, 34)
1405
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "s is string { Length: 3 }").WithLocation(6, 34)
1473
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "s is string { Length: 3 }").WithLocation(7, 13)
2464
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "1 is < 0").WithLocation(5, 13),
2467
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "1 is < 1").WithLocation(6, 13),
2473
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "1 is <= 0").WithLocation(8, 13),
2485
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "1 is > 1").WithLocation(12, 13),
2488
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "1 is > 2").WithLocation(13, 13),
2497
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "1 is >= 2").WithLocation(16, 13)
Semantics\PatternMatchingTests3.cs (3)
6493
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "s is string t").WithLocation(12, 15),
6768
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, $"i is not ({pattern})").WithLocation(17, 13)
6823
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, $"i is {pattern}").WithLocation(12, 15),
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (1)
Semantics\NullableReferenceTypesVsPatterns.cs (1)
1472
Diagnostic(ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
, "2 is 3").WithLocation(6, 13));
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (1)
Diagnostics\DiagnosticTest.cs (1)
284
case ErrorCode.
WRN_GivenExpressionNeverMatchesPattern
: