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

Bug 256009

Summary: [content assist] Code completion fails on local array variables
Product: [Eclipse Project] JDT Reporter: someone <temp4746>
Component: TextAssignee: JDT-Text-Inbox <jdt-text-inbox>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert
Version: 3.4.1   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
An example video showing the bug none

Description someone CLA 2008-11-20 14:55:40 EST
Build ID: M20080911-1700

Steps To Reproduce:
1. Create a local array variable
2. Try to write the first few letters of the variable name and then invoke code completion (ctrl+space) on it somewhere in the code.
3. Once you press enter it wont complete the code just leave it as typed.

More information:
Version: Eclipse 3.4.1 java package
JRE: JRE 6u10

Invoking code completion without having anything writen does work.

Example code:
public class Example {
	public static void main(String[] args) {
		int[] test;
		t //Try to invoke code completion here it wont work
	}
}
Comment 1 Dani Megert CLA 2008-11-21 03:11:59 EST
Cannot neither reproduce with Eclipse SDK 3.4.1 nor 3.5 (I20081116-1700).

Hint: reset the Java > Editor > Content Assist > Advanced settings.
Comment 2 someone CLA 2008-11-21 09:06:11 EST
I just managed to reproduce it using eclipse 3.4.1 sdk.

The dialog for code comletion does open but once you press enter trying to complete the name of the array nothing happens.

For the example above it just leaves it as "t".
Comment 3 someone CLA 2008-11-21 09:18:36 EST
Created attachment 118471 [details]
An example video showing the bug

Here is a video showing this bug.
Comment 4 Dani Megert CLA 2008-11-21 09:48:46 EST
Sorry, but I guess something is broken in your workspace or download:

1. download either of:
http://download.eclipse.org/eclipse/downloads/drops/R-3.4.1-200809111700/index.php
http://www.eclipse.org/downloads/download.php?file=/technology/epp/downloads/release/ganymede/SR1/eclipse-java-ganymede-SR1-win32.zip
2. start fresh workspace
3. paste example source from comment 0 into Package Explorer
==> code assist works and 'test' gets inserted.
Comment 5 someone CLA 2008-11-21 10:14:06 EST
I tried it and it didnt help.

Pherhaps it's a locale issue or a jre/jdk version specific issue.

I am using jre 6 update 10,
And an hebrew locale.

Can you please test it with this configuration?
Comment 6 Dani Megert CLA 2008-11-21 10:17:09 EST
>And an hebrew locale.
That's the key. Please provide such information next time when reporting a bug.

*** This bug has been marked as a duplicate of bug 244667 ***
Comment 7 someone CLA 2008-11-21 10:20:42 EST
Alright thanks for the help ;)

I'll remeber to include this sort of info next time.