94 references to ERR_RefLocalOrParamExpected
Microsoft.CodeAnalysis.CSharp (17)
Binder\Binder.ValueChecks.cs (16)
1016if (errorCode is ErrorCode.ERR_InvalidAddrOp or ErrorCode.ERR_RefLocalOrParamExpected) 1052Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 1064Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 1089Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 1175Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 1202Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 1227Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 1248if (errorCode is ErrorCode.ERR_InvalidAddrOp or ErrorCode.ERR_IncrementLvalueExpected or ErrorCode.ERR_RefReturnThis or ErrorCode.ERR_RefLocalOrParamExpected or ErrorCode.ERR_RefLvalueExpected) 1344diagnostics.Add(ErrorCode.ERR_RefLocalOrParamExpected, node.Location); 1422Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 1663Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 1972Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 2140Error(diagnostics, ErrorCode.ERR_RefLocalOrParamExpected, node); 3511return ErrorCode.ERR_RefLocalOrParamExpected; 3539return ErrorCode.ERR_RefLocalOrParamExpected; 3583return ErrorCode.ERR_RefLocalOrParamExpected;
Errors\ErrorFacts.cs (1)
1884or ErrorCode.ERR_RefLocalOrParamExpected
Microsoft.CodeAnalysis.CSharp.Emit2.UnitTests (4)
CodeGen\IndexAndRangeTests.cs (4)
1522Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "[1]").WithLocation(2, 22), 1525Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "[^1]").WithLocation(3, 22), 1528Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "b[1]").WithLocation(6, 1), 1531Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "b[^1]").WithLocation(7, 1)
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (2)
Semantics\RecordTests.cs (2)
9708Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "X").WithLocation(15, 28), 9711Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "X").WithLocation(17, 22)
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (71)
Semantics\NullableReferenceTypesTests.cs (1)
7926Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "y2! = ref y").WithLocation(8, 10),
Semantics\RefEscapingTests.cs (10)
9789Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(6, 9), 9798Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(8, 9)); 9819Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(6, 9), 9825Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(8, 9)); 9846Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(6, 9), 9852Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(8, 9)); 9875Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(6, 9), 9881Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(8, 9)); 9902Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(6, 9), 9908Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(8, 9));
Semantics\RefFieldTests.cs (37)
9948Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "P0").WithLocation(9, 9), 9951Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "P1").WithLocation(10, 9), 9954Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "P2").WithLocation(11, 9), 9957Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "s.P0").WithLocation(23, 9), 9960Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "s.P1").WithLocation(24, 9), 9963Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "s.P2").WithLocation(25, 9)); 10019Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "P0").WithLocation(9, 9), 10022Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "P1").WithLocation(10, 9), 10025Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "P2").WithLocation(11, 9), 10028Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "s.P0").WithLocation(20, 9), 10031Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "s.P1").WithLocation(21, 9), 10034Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "s.P2").WithLocation(22, 9)); 20720Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "Property").WithLocation(8, 27) 20747Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "Property").WithLocation(8, 27), 20774Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "[0]").WithLocation(2, 19), 20777Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "r2[0]").WithLocation(5, 1) 20801Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "[0]").WithLocation(2, 19), 20804Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "r2[0]").WithLocation(5, 1) 20908Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "Property").WithLocation(7, 27) 20958Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "field").WithLocation(3, 19), 20961Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "r2.field").WithLocation(6, 1) 20984Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "Property").WithLocation(3, 19), 20987Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "r2.Property").WithLocation(6, 1) 21010Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "[0]").WithLocation(3, 19), 21013Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "r2[0]").WithLocation(6, 1) 21044Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "[0]").WithLocation(7, 35), 21047Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "c2.array[0]").WithLocation(15, 9) 21078Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "[0]").WithLocation(9, 37), 21081Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "c2.pointer[0]").WithLocation(17, 9) 21312Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "field").WithLocation(3, 23), 21315Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "s.D.field").WithLocation(6, 1) 21534Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "field").WithLocation(3, 23), 21537Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "r2.field").WithLocation(6, 1) 21563Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "[0]").WithLocation(3, 23), 21566Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "s.D[0]").WithLocation(6, 1) 21590Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "X").WithLocation(4, 36), 21593Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "a2[y: x, x: x].X").WithLocation(7, 1)
Semantics\RefLocalsAndReturnsTests.cs (23)
180Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(7, 9)); 743Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "c").WithLocation(13, 13)); 875Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(10, 9), 878Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(13, 9), 881Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(16, 9), 884Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(18, 9), 887Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(21, 9), 890Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(24, 9)); 907Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "this").WithLocation(6, 9)); 925Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "_f").WithLocation(7, 9)); 943Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "2 + 3").WithLocation(7, 10)); 962Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "x").WithLocation(8, 9)); 1002Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "M2()").WithLocation(8, 9)); 1025Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "P").WithLocation(8, 9)); 1043Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "b ? ref x : ref y").WithLocation(5, 10)); 1061Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "x = ref y").WithLocation(5, 10)); 4707Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "a").WithLocation(6, 9)); 4741Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "array[0]").WithLocation(6, 9)); 4769Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "*ptr").WithLocation(6, 9)); 4797Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "ptr[0]").WithLocation(6, 9)); 4825Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "__refvalue(__makeref(x), int)").WithLocation(6, 9)); 4853Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "d[0]").WithLocation(6, 9)); 4881Diagnostic(ErrorCode.ERR_RefLocalOrParamExpected, "d.member").WithLocation(6, 9));