49 references to ERR_RefReadonlyNotField
Microsoft.CodeAnalysis.CSharp (2)
Binder\Binder.ValueChecks.cs (1)
2872
ErrorCode.
ERR_RefReadonlyNotField
,
Errors\ErrorFacts.cs (1)
1786
case ErrorCode.
ERR_RefReadonlyNotField
:
Microsoft.CodeAnalysis.CSharp.Emit.UnitTests (4)
CodeGen\CodeGenInParametersTests.cs (1)
1208
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "arg1").WithArguments("variable", "arg1").WithLocation(6, 25),
CodeGen\CodeGenRefReadonlyReturnTests.cs (2)
636
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "M()").WithArguments("method", "M").WithLocation(6, 25),
642
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "P").WithArguments("property", "P").WithLocation(8, 26),
Emit\CompilationEmitTests.cs (1)
1380
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "y").WithArguments("variable", "y").WithLocation(12, 9),
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (43)
Semantics\OverloadResolutionTests.cs (2)
11099
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "y").WithArguments("variable", "y").WithLocation(13, 10),
11108
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "y").WithArguments("variable", "y").WithLocation(13, 10),
Semantics\RefExtensionMethodsTests.cs (1)
2129
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "p").WithArguments("variable", "p").WithLocation(6, 17));
Semantics\RefFieldTests.cs (36)
7195
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.RefReadonly").WithArguments("field", "RefReadonly").WithLocation(12, 73),
7198
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.ReadonlyRefReadonly").WithArguments("field", "ReadonlyRefReadonly").WithLocation(14, 73),
7201
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.RefReadonly").WithArguments("field", "RefReadonly").WithLocation(17, 75),
7204
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.ReadonlyRefReadonly").WithArguments("field", "ReadonlyRefReadonly").WithLocation(19, 75),
7207
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.RefReadonly").WithArguments("field", "RefReadonly").WithLocation(22, 88),
7210
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.ReadonlyRefReadonly").WithArguments("field", "ReadonlyRefReadonly").WithLocation(24, 88),
7213
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.RefReadonly").WithArguments("field", "RefReadonly").WithLocation(27, 73),
7216
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.ReadonlyRefReadonly").WithArguments("field", "ReadonlyRefReadonly").WithLocation(29, 73));
7509
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(8, 16),
7512
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(9, 16),
7515
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(18, 20),
7518
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(19, 20),
7521
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(27, 16),
7524
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(28, 16));
7615
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(8, 16),
7618
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(9, 16),
7621
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(18, 20),
7624
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(19, 20),
7627
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(27, 16),
7630
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "F").WithArguments("field", "F").WithLocation(28, 16));
7721
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(14, 49),
7724
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(15, 49),
7727
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(20, 51),
7730
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(21, 51),
7733
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(26, 64),
7736
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(27, 64),
7739
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(32, 49),
7742
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(33, 49));
7833
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(14, 49),
7836
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(15, 49),
7839
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(20, 51),
7842
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(21, 51),
7845
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(26, 64),
7848
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(27, 64),
7851
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(32, 49),
7854
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "s.F").WithArguments("field", "F").WithLocation(33, 49));
Semantics\RefLocalsAndReturnsTests.cs (4)
429
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "x").WithArguments("variable", "x").WithLocation(6, 30));
1449
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "y").WithArguments("variable", "y").WithLocation(9, 19),
1498
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "L2()").WithArguments("method", "L2").WithLocation(17, 15));
1520
Diagnostic(ErrorCode.
ERR_RefReadonlyNotField
, "L()").WithArguments("method", "L").WithLocation(8, 25),