Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
2.5.7, 2.5.8, 3.0.0-beta-3
-
None
-
None
Description
When overriding a method as `protected` with a super method being package-private (no modifier in Java or `@PackageScope` in Groovy), compilation fails with an error similar to this:
... exampleMethod(java.lang.Object -> java.lang.Object) in com.example.Child cannot override exampleMethod in com.example.Base; attempting to assign weaker access privileges; was package-private ...
This edge case seems to be missed at GROOVY-8651.
I submitted a pull request at https://github.com/apache/groovy/pull/1038
Attachments
Issue Links
- links to