Bug 88082 - ASTParser#createASTs(..) does not use the given progress monitor
Summary: ASTParser#createASTs(..) does not use the given progress monitor
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.1 M7   Edit
Assignee: Jerome Lanneluc CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 89537
  Show dependency tree
 
Reported: 2005-03-15 12:21 EST by Markus Keller CLA
Modified: 2005-05-12 10:02 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Markus Keller CLA 2005-03-15 12:21:16 EST
v_541

AFAICS, ASTParser#createASTs(..) does not use the given progress monitor. It
stays at 0 all the time.
Comment 1 Frederic Fusier CLA 2005-03-15 13:13:02 EST
3.0.1 with v_541!? I guess you wanted to say 3.1 for version...
Comment 2 Markus Keller CLA 2005-03-15 14:08:37 EST
Oops, 3.1 of course. I'm running with 3.0.2 RC2 as host eclipse and I forgot to
switch bugzilla back to 3.1 after having filed a 3.0.1 bug...
Comment 3 Dirk Baeumer CLA 2005-05-02 05:42:56 EDT
Jerome, can we do something here for M7. We really show bad progress reporting
in refactorings the use the AST pipeline.
Comment 4 Jerome Lanneluc CLA 2005-05-02 11:08:26 EDT
Changed
CompilationUnitResolver#resolved(ICompilationUnit[],String[],ASTRequestor,int,Map,IJavaProject,WorkingCopyOwner,IProgressMonitor)
 and
CompilationUnitResolver#parse(ICompilationUnit[],ASTRequestor,int,Map,IProgressMonitor)
to report progress to the given progress monitor (and also checking cancel on
this progress monitor).
Comment 5 Markus Keller CLA 2005-05-03 06:05:30 EDT
Progress reporting still does not work in N20050503-0010.

I could make it work by removing a SubProgressMonitor in CompilationUnitResolver. 

I simply replaced line 444 of rev. 1.104 by this line:
    IProgressMonitor subProgressMonitor = monitor;
Comment 6 Jerome Lanneluc CLA 2005-05-03 06:34:54 EDT
I should have asked this before: can you please provide a test case ?
Comment 7 Markus Keller CLA 2005-05-03 07:00:17 EDT
I should have provided the test case before ;-):

- import org.junit as source
- set compiler compliance to 5.0 and link a 1.5 JRE
- on the project, run Refactor > Infer Type Arguments
Comment 8 Jerome Lanneluc CLA 2005-05-03 07:52:44 EDT
Thanks Markus.

Changed CompilationUnitResolver#resolve(...) and parse(...) to not use a
SubProgressMonitor. Also improved handling of OperationCanceledException.
Comment 9 Frederic Fusier CLA 2005-05-12 10:02:19 EDT
Verified for 3.1 M7 using build I20050509-2010 + jdt.core HEAD.