This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 189399 - Code completion inserts invalid semi-colon
Summary: Code completion inserts invalid semi-colon
Status: CLOSED DUPLICATE of bug 177657
Alias: None
Product: java
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: PC Windows XP
: P3 normal (vote)
Assignee: Dusan Balek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-08-11 13:57 UTC by wvreeven
Modified: 2010-08-16 12:42 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
NetBeans project that shows how to reproduce the issue (12.81 KB, application/octet-stream)
2010-08-11 13:57 UTC, wvreeven
Details

Note You need to log in before you can comment on or make changes to this bug.
Description wvreeven 2010-08-11 13:57:49 UTC
Created attachment 101315 [details]
NetBeans project that shows how to reproduce the issue

This little bug is very easy to reproduce. Whenever code completion on a collection is performed, a semi-colon is inserted at the wrong place. Please refer to the attached NetBeans project and follow the instructions (which are also put in the Java code):

Insert code above the declaration of "anotherString" by
- typing stringH [ctrl-space] and selecting stringHolder
- typing .g [ctrl-space] and selecting getStrings
- typing . [ctrl-space] and selecting add(String e)
The result will be that a semi-colon is inserted in the declaration of anotherString like this

String; anotherString = "Another Code Completion Demo";

The first semi-colon (right behind the first word in the line, String) is inserted when "add" is selected. I get this issue constantly when I refer to collection members like this, which is a LOT :-)
Comment 1 Jan Lahoda 2010-08-16 12:33:10 UTC
Duplicate of bug #177657, thanks for the report anyway.

*** This bug has been marked as a duplicate of bug 177657 ***
Comment 2 wvreeven 2010-08-16 12:42:11 UTC
Thanks, I couldn't find the existing bug using the query tool.