20 references to ERR_ProtectedInExtension
Microsoft.CodeAnalysis.CSharp (2)
Binder\Semantics\AccessCheck.cs (1)
699
return containingType.IsExtension ? ErrorCode.
ERR_ProtectedInExtension
Errors\ErrorFacts.cs (1)
2520
or ErrorCode.
ERR_ProtectedInExtension
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (18)
Semantics\ExtensionTests.cs (18)
44862
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "M").WithArguments("E.extension(int).M()").WithLocation(5, 24),
44865
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "P").WithArguments("E.extension(int).P").WithLocation(6, 23),
44868
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).P2.get").WithLocation(7, 35),
44871
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "set").WithArguments("E.extension(int).P3.set").WithLocation(8, 45),
44877
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "this").WithArguments("E.extension(int).this[int]").WithLocation(9, 23),
44883
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).this[int, int].get").WithLocation(10, 51));
44907
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "M").WithArguments("E.extension(int).M()").WithLocation(5, 33),
44910
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "P").WithArguments("E.extension(int).P").WithLocation(6, 32),
44913
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).P2.get").WithLocation(7, 44),
44916
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "set").WithArguments("E.extension(int).P3.set").WithLocation(8, 54),
44922
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "this").WithArguments("E.extension(int).this[int]").WithLocation(9, 32),
44928
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).this[int, int].get").WithLocation(10, 60));
44952
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "M").WithArguments("E.extension(int).M()").WithLocation(5, 32),
44955
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "P").WithArguments("E.extension(int).P").WithLocation(6, 31),
44958
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).P2.get").WithLocation(7, 43),
44961
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "set").WithArguments("E.extension(int).P3.set").WithLocation(8, 53),
44967
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "this").WithArguments("E.extension(int).this[int]").WithLocation(9, 31),
44973
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).this[int, int].get").WithLocation(10, 59));