42 references to WRN_ImplicitCopyInReadOnlyMember
Microsoft.CodeAnalysis.CSharp (4)
Binder\Binder_Invocation.cs (1)
1850
Error(diagnostics, ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, receiver.Syntax, method, ThisParameterSymbol.SymbolName);
Errors\ErrorFacts.cs (2)
472
case ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
:
1995
or ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
Generated\ErrorFacts.Generated.cs (1)
227
case ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
:
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (9)
CodeGen\CodeGenReadonlyStructTests.cs (8)
1725
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "M2").WithArguments("S.M2()", "this").WithLocation(9, 9));
2238
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "ToString").WithArguments("S.ToString()", "this").WithLocation(12, 9),
2241
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "GetHashCode").WithArguments("S.GetHashCode()", "this").WithLocation(13, 9),
2244
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "Equals").WithArguments("S.Equals(object)", "this").WithLocation(14, 9));
2391
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "GetType").WithArguments("S.GetType()", "this").WithLocation(12, 9),
2394
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "ToString").WithArguments("S.ToString()", "this").WithLocation(13, 9),
2397
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "GetHashCode").WithArguments("S.GetHashCode()", "this").WithLocation(14, 9),
2400
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "Equals").WithArguments("S.Equals(object)", "this").WithLocation(15, 9));
CodeGen\IndexAndRangeTests.cs (1)
362
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Length.get", "this").WithLocation(24, 9),
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (4)
Semantics\PatternMatchingTests_ListPatterns.cs (4)
3778
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Length.get", "this").WithLocation(11, 13),
3781
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.this[int].get", "this").WithLocation(11, 13),
3784
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Length.get", "this").WithLocation(12, 13),
3787
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Slice(int, int)", "this").WithLocation(12, 13)
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (23)
Semantics\IndexAndRangeTests.cs (10)
113
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Length.get", "this").WithLocation(11, 13),
116
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.this[int].get", "this").WithLocation(11, 13),
119
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Length.get", "this").WithLocation(12, 13),
122
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Slice(int, int)", "this").WithLocation(12, 13));
146
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.this[int].get", "this").WithLocation(11, 13),
149
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Slice(int, int)", "this").WithLocation(12, 13));
173
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Length.get", "this").WithLocation(11, 13),
176
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Length.get", "this").WithLocation(12, 13));
200
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Count.get", "this").WithLocation(11, 13),
203
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S.Count.get", "this").WithLocation(12, 13));
Semantics\ReadOnlyStructsTests.cs (12)
517
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S1.GetPinnableReference()", "this").WithLocation(12, 25));
623
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "M").WithArguments("S.M()", "this").WithLocation(11, 13));
665
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "P2").WithArguments("S.P2.get", "this").WithLocation(11, 17));
805
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "E").WithArguments("S.E.add", "this").WithLocation(10, 9),
808
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "E").WithArguments("S.E.remove", "this").WithLocation(12, 9));
936
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "E").WithArguments("S.E.add", "this").WithLocation(9, 9),
939
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "E").WithArguments("S.E.remove", "this").WithLocation(10, 9),
1846
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S1.GetEnumerator()", "this").WithLocation(13, 27));
1909
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S1.GetAsyncEnumerator()", "this").WithLocation(16, 33));
1953
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S1.Dispose()", "this").WithLocation(13, 16));
2002
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("S1.Deconstruct(out int, out int)", "this").WithLocation(11, 22));
2405
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "P3").WithArguments("S.P3.get", "this").WithLocation(22, 9));
Semantics\RefEscapingTests.cs (1)
7963
Diagnostic(ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
, "this").WithArguments("Vec4.Self2()", "this").WithLocation(16, 30),
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (2)
Diagnostics\DiagnosticTest.cs (2)
381
case ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
:
521
ErrorCode.
WRN_ImplicitCopyInReadOnlyMember
,