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.
Created attachment 154759 [details] Example where auto completion doesn't work. When adding a class with a generic that self-references itself, NetBeans doesn't support auto completion anymore for superclassing or implementing. Please see the attached classes: * Foo shows the buggy behaviour (auto complete serializable), * Bar shows the correct behaviour for a stripped down case (auto complete serializable) If you want it to "implements Serializable" and start typing, NetBeans won't propose suggestions and can't add imports. This works for classes not having this kind of self-references / nested generics. I suspect the parser to be confused by the construct. ------- Expected behaviour: when typing and after hitting CTRL+SHIFT after "Ser", I get proposed "java.io.Serializable" as a completion: public class Foo<T extends List<T>> implements Serializable { ------- Actual behaviour: when typing and after hitting CTRL+SHIFT after "Ser", I get displayed "no suggestions": public class Foo<T extends List<T>> implements Ser { but if I remove the List generic, it works with auto completion: public class Bar<T extends List> implements Serializable {
Created attachment 154760 [details] Example where auto completion DOES work. Please note the missing generic parameter for list.
reproducible
Fixed in jet-main. http://hg.netbeans.org/jet-main/rev/5b65d63bfaeb
Integrated into 'main-silver', will be available in build *201508060002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/5b65d63bfaeb User: Dusan Balek <dbalek@netbeans.org> Log: Issue #253611 - Generics confuse auto completion - fixed.