Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 322543

Summary: [clean up] Stops working after 100 problems in one CU
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: UIAssignee: Markus Keller <markus.kell.r>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert
Version: 3.7   
Target Milestone: 3.7 M2   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on:    
Bug Blocks: 325195    

Description Markus Keller CLA 2010-08-12 10:44:52 EDT
HEAD

Clean Ups like "Add missing Override annotations" stop working after 100 problems in one CU.

Problem is most probably that the compiler only reports the first 100 problems. That makes sense in the Java editor and for batch compilations, but refactorings and clean ups should see all problems.

Possible fix is to add

    options.put(JavaCore.COMPILER_PB_MAX_PER_UNIT, "0"); //$NON-NLS-1$

in RefactoringASTParser#getCompilerOptions(IJavaElement).
Comment 1 Markus Keller CLA 2010-09-09 05:24:19 EDT
Rajesh, can you please write a new test for this? Something like CleanUpTest#testAddOverride15(), but where you generate 200 methods in a loop. The test should fail in HEAD but become green with the fix in comment 0.
Comment 2 Markus Keller CLA 2010-09-13 07:02:56 EDT
> Possible fix is to add
> 
>     options.put(JavaCore.COMPILER_PB_MAX_PER_UNIT, "0"); //$NON-NLS-1$
> 
> in RefactoringASTParser#getCompilerOptions(IJavaElement).

I've released that to HEAD for 3.7 M2.
Comment 3 Dani Megert CLA 2010-09-14 02:31:16 EDT
(In reply to comment #1)
> Rajesh, can you please write a new test for this? Something like
> CleanUpTest#testAddOverride15(), but where you generate 200 methods in a loop.
> The test should fail in HEAD but become green with the fix in comment 0.
Filed bug 325195 for the test.
Comment 4 Dani Megert CLA 2010-09-16 05:08:29 EDT
Verified in I20100915-2024.