Community
Participate
Working Groups
With the fix for bug 372012 a missing @NonNullByDefault on any package (via package-info.java) is reported against the package, good. However, in the package explorer this marker is rendered twice: for the current package and for the parent package, e.g.: bug372012 package-info.java bug372012.p1 package-info.java bug372012.p1.p2 if the default is missing only in bug372012.p1.p2 two warning or error overlays are shown on packages bug372012.p1.p2 *and* bug372012.p1. This seems to correlate with the fact that problems in any CU are additionally rendered on the containing package, where it makes sense to make problems visible even if packages are shown collapsed. However, for a package propagating the overlay also to the parent is undesired.
Good catch. But this will be a tough one to solve. ProblemsLabelDecorator#getErrorTicksFromMarkers(..) uses IResource#findMaxProblemSeverity(..) on the package's folder with depth=1. Now, we need to exclude subfolders that are packages. We have to make sure that the fix doesn't void the performance benefits from bug 177384. Maybe the fix can also fix a related bug in the decoration of packages: - create folder "no-pack" with file "build.xml" inside a package - open build.xml with the Ant editor and paste this line: <project name="project"> => package doesn't show the error decoration, but it should
Fixed both issues with http://git.eclipse.org/c/jdt/eclipse.jdt.ui.git/commit/?id=d8af25bc1d18d24931f14543d0010a00d16604da > We have to make sure that the fix doesn't void the performance benefits from > bug 177384. The main benefits were that we avoid creating Marker objects. That's still in. Now, we just have separate calls to IResource#findMaxProblemSeverity(.., DEPTH_ZERO), but the old DEPTH_ONE calls did exactly the same internally.
Verified in I20120430-2000.