27 references to WRN_ReturnNotNullIfNotNull
Microsoft.CodeAnalysis.CSharp (5)
Errors\ErrorFacts.cs (3)
82
nullableWarnings.Add(GetId(ErrorCode.
WRN_ReturnNotNullIfNotNull
));
499
case ErrorCode.
WRN_ReturnNotNullIfNotNull
:
2097
or ErrorCode.
WRN_ReturnNotNullIfNotNull
FlowAnalysis\NullableWalker.cs (1)
1423
Diagnostics.Add(ErrorCode.
WRN_ReturnNotNullIfNotNull
, location, inputParam.Name);
Generated\ErrorFacts.Generated.cs (1)
251
case ErrorCode.
WRN_ReturnNotNullIfNotNull
:
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (2)
Semantics\ExtensionTests.cs (2)
48918
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;").WithArguments("o").WithLocation(26, 17),
48921
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;").WithArguments("o").WithLocation(36, 13));
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (19)
Semantics\NullableReferenceTypesTests.cs (19)
32115
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;").WithArguments("s1").WithLocation(33, 13)
32188
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;", isSuppressed: false).WithArguments("p").WithLocation(15, 13),
32191
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return M1();", isSuppressed: false).WithArguments("p").WithLocation(20, 13),
32194
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return M1();", isSuppressed: false).WithArguments("p").WithLocation(29, 9));
32253
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;", isSuppressed: false).WithArguments("p").WithLocation(21, 13),
32256
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return M1();", isSuppressed: false).WithArguments("p").WithLocation(26, 13),
32259
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return M1();", isSuppressed: false).WithArguments("p").WithLocation(31, 13));
32292
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;", isSuppressed: false).WithArguments("q").WithLocation(15, 13),
32295
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return M1();", isSuppressed: false).WithArguments("p").WithLocation(18, 9));
32357
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return default;", isSuppressed: false).WithArguments("t").WithLocation(10, 13),
32360
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return default;", isSuppressed: false).WithArguments("t").WithLocation(31, 13),
32460
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;", isSuppressed: false).WithArguments("p").WithLocation(17, 13),
32463
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;", isSuppressed: false).WithArguments("p").WithLocation(23, 13),
32469
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return pOut;", isSuppressed: false).WithArguments("p").WithLocation(33, 9),
32531
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;").WithArguments("p").WithLocation(41, 13),
32591
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return local1();").WithArguments("p").WithLocation(40, 13),
32652
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;").WithArguments("p").WithLocation(19, 17),
32655
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return null;").WithArguments("p").WithLocation(25, 17),
32661
Diagnostic(ErrorCode.
WRN_ReturnNotNullIfNotNull
, "return pOut;").WithArguments("p").WithLocation(35, 13),
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (1)
Diagnostics\DiagnosticTest.cs (1)
292
case ErrorCode.
WRN_ReturnNotNullIfNotNull
: