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 133890 [details] Example project to reproduce issue. If we have this: Pair<Integer, Pair<? extends Pair<String, String>, ? extends Pair<String, String>>> pair7 = new Pair<Integer, Pair<BookAuthor, BookAuthor>>(789, new Pair<>(new BookAuthor("\"Book1\"", "Author1"), new BookAuthor("\"Book2\"", "Author2"))); NetBeans shows error badge with note that says: Incompatible type required: Pair<Integer,? extends Pair<String,String>,? extends Pair<String,String>>> found: Pair<Integer,Pair<BookAuthor,BookAuthor>> Then there is a refactoring options to: Chagee type of pair7 to Pair<Integer,Pair<BookAuthor,BookAuthor>> When this is chosen, it produces: Pair<Integer, Pair<BookAuthor, BookAuthor>>> pair7 = new Pair<Integer, Pair<BookAuthor, BookAuthor>>(789, new Pair<>(new BookAuthor("\"Book1\"", "Author1"), new BookAuthor("\"Book2\"", "Author2"))); Which is an error because there are 3 closing ">" instead of 2. See attached project. Product Version: NetBeans IDE 7.3.1 (Build 201304162201) Java: 1.7.0_21; Java HotSpot(TM) 64-Bit Server VM 23.21-b01 Runtime: Java(TM) SE Runtime Environment 1.7.0_21-b11 System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
http://hg.netbeans.org/jet-main/rev/2c3c1c32660b
Integrated into 'main-golden', will be available in build *201305021042* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/2c3c1c32660b User: Jan Lahoda <jlahoda@netbeans.org> Log: #229123: correcting removal of a parameterized type's type parameter - removal of the ending angle bracket.
Verified fixed in: Product Version: NetBeans IDE Dev (Build 201305022300) Java: 1.7.0_21; Java HotSpot(TM) 64-Bit Server VM 23.21-b01 Runtime: Java(TM) SE Runtime Environment 1.7.0_21-b11 System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
Honza, if you want to push it into release73, please do so today .
After thinking about it, lets defer to next patch, if any, or to 7.4. Has been a problem for years, and I would like to get more confidence in the patch before backporting.
*** Bug 231559 has been marked as a duplicate of this bug. ***