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)
2513
or ErrorCode.
ERR_ProtectedInExtension
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (18)
Semantics\ExtensionTests.cs (18)
38547
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "M").WithArguments("E.extension(int).M()").WithLocation(5, 24),
38550
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "P").WithArguments("E.extension(int).P").WithLocation(6, 23),
38553
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).P2.get").WithLocation(7, 35),
38556
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "set").WithArguments("E.extension(int).P3.set").WithLocation(8, 45),
38562
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "this").WithArguments("E.extension(int).this[int]").WithLocation(9, 23),
38568
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).this[int, int].get").WithLocation(10, 51));
38592
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "M").WithArguments("E.extension(int).M()").WithLocation(5, 33),
38595
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "P").WithArguments("E.extension(int).P").WithLocation(6, 32),
38598
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).P2.get").WithLocation(7, 44),
38601
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "set").WithArguments("E.extension(int).P3.set").WithLocation(8, 54),
38607
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "this").WithArguments("E.extension(int).this[int]").WithLocation(9, 32),
38613
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).this[int, int].get").WithLocation(10, 60));
38637
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "M").WithArguments("E.extension(int).M()").WithLocation(5, 32),
38640
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "P").WithArguments("E.extension(int).P").WithLocation(6, 31),
38643
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).P2.get").WithLocation(7, 43),
38646
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "set").WithArguments("E.extension(int).P3.set").WithLocation(8, 53),
38652
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "this").WithArguments("E.extension(int).this[int]").WithLocation(9, 31),
38658
Diagnostic(ErrorCode.
ERR_ProtectedInExtension
, "get").WithArguments("E.extension(int).this[int, int].get").WithLocation(10, 59));