Community
Participate
Working Groups
Created attachment 124616 [details] Problems view Build ID: 3.5 M5 Unfortunately I was not able to isolate a small test case, actually I can't understand what't going wrong there... Steps To Reproduce: install 3.5 M5 milestone and import "findBugs" project as described below. The project didn't compile, there are 31 compile errors reported, all of them related to different package-info.java files (see screenshot). 3 error types: "The attribute value is undefined for the annotation type DefaultAnnotationForParameters" "edu.umd.cs.findbugs.annotations.NonNull cannot be resolved to a type" "edu.umd.cs.findbugs.annotations.DefaultAnnotationForParameters cannot be resolved to a type" Of course all of the mentioned classes are compiled and on the classpath (it's a part of the project). Clean/rebuild/restart/changing compile target from 1.5 to 1.6 didn't help. Example: edu.umd.cs.findbugs.ba.type.package-info.java contains this: ########### @javax.annotation.ParametersAreNonnullByDefault @edu.umd.cs.findbugs.annotations.DefaultAnnotationForParameters(edu.umd.cs.findbugs.annotations.NonNull.class) package edu.umd.cs.findbugs.ba.type; ########### If just "touching" the file by adding a space to it, it compiles. Full project build causes the error appear again. With 3.4.1 and Sun's javac compilation works fine... ========================================================= To get findbugs project, just follow this steps (SVN must be installed): 1) Choose [File | Import | SVN | Checkout Projects from SVN]. The import wizard opens. 2) In the wizard, proceed as follows: a) Choose [Create a new repository location]. Click [Next] b) Enter http://findbugs.googlecode.com/svn as url. Click [Next] c) Select 2 children of the <trunk> element (hold CTRL key): <trunk> | +- findbugs Click [Next] d) Do not change defaults on the next page. Click [Next] e) Choose the workspace location for project sources, e.g. D:\Projects\FBWorkspace. f) Click [Finish]. g) Source code will be checked out from SVN. This can take time, especially with the slow internet connection (~10 MB need to be downloaded first time).
(In reply to comment #0) > c) Select 2 children of the <trunk> element (hold CTRL key): > <trunk> > | > +- findbugs > Click [Next] What 2 children ? findbugs and ?
Sorry, it was a "copy and paste" from http://code.google.com/p/findbugs/source/browse/trunk/eclipsePlugin/doc/building_findbugsplugin.txt?r=10519 You just need findBugs project, it is self-contained.
Created attachment 125166 [details] Proposed patch We cannot resolve all annotations in a package-info.java file until after types know their fields/methods, but we can check for the deprecated annotation.
Created attachment 125407 [details] Updated patch and testcase
Fix and test released for 3.5M6
Verified for 3.5M6 using I20090309-0100: the 'findbugs' project compiles without any error. (In reply to comment #4) > Created an attachment (id=125407) [details] > Updated patch and testcase > The test case released in this patch does concern bug 258906 and not this one. I verified that it passes with or without this bug fix, hence there's currently no regression test for this peculiar issue. However, I do not know if it was possible to write one though.
*** Bug 267765 has been marked as a duplicate of this bug. ***