Bug 177174

Summary: [assist] Wrong names are proposed as unresolved local variable
Product: [Eclipse Project] JDT Reporter: David Audel <david_audel>
Component: CoreAssignee: David Audel <david_audel>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.3   
Target Milestone: 3.3 M7   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Proposed fix none

Description David Audel CLA 2007-03-13 12:55:12 EDT
Build id: I20070306-1200

public class X {
	void foo () {
		label : {
			la| // do ctrl+space at |
		}
	}
}

'label' is proposed and should not.
Comment 1 David Audel CLA 2007-03-13 13:00:54 EDT
Another bug in the smae area

public class X {
	void foo () {
		label : {
			la| // do ctrl+space at |
			{
				break label;
			}
		}
	}
}

there is two 'label' proposals.
Comment 2 David Audel CLA 2007-04-12 04:57:47 EDT
Another problem.

public class X {
  void foo() {
    return (zzz) zz| // do ctrl+space at |
  }
}

'zzz' shouldn't be proposed
Comment 3 David Audel CLA 2007-04-12 05:16:23 EDT
Created attachment 63593 [details]
Proposed fix

Algorithm to accumulate potential unresolved names is rewritten.
Performances of unresolved names propositions are slightly improved.
Comment 4 David Audel CLA 2007-04-12 05:22:56 EDT
Released for 3.3M7

Tests added
  CompletionTests#testNameWithUnresolvedReferences012() -> testNameWithUnresolvedReferences017()
Comment 5 Olivier Thomann CLA 2007-04-27 09:43:53 EDT
Verified for 3.3M7 using I20070427-0010