[jira] [Commented] (NETBEANS-4356) Unneeded/redundant cast added by code completion
[ https://issues.apache.org/jira/browse/NETBEANS-4356?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17115451#comment-17115451 ] Ernie Rael commented on NETBEANS-4356: -- I removed the regression label. (it also exhibits this behavior with NB11.3/jdk-1.8/nb-javac) Guess I use instanceof less than I thought. > Unneeded/redundant cast added by code completion > > > Key: NETBEANS-4356 > URL: https://issues.apache.org/jira/browse/NETBEANS-4356 > Project: NetBeans > Issue Type: Bug > Components: editor - Completion Templates >Affects Versions: 12.0 > Environment: Product Version: Apache NetBeans IDE 12.0-beta4 > Updates: Updates available to version NetBeans 8.2 Patch 2 > Java: 14.0.1; Java HotSpot(TM) 64-Bit Server VM 14.0.1+7 > Runtime: Java(TM) SE Runtime Environment 14.0.1+7 > System: Windows 7 version 6.1 running on amd64; UTF-8; en_US (nb) >Reporter: Ernie Rael >Priority: Major > Labels: pull-request-available > Attachments: the-example.jar > > Time Spent: 10m > Remaining Estimate: 0h > > Consider the code, caret shown as '|', > {code:java} > static private void xxx(ViMark m) { > if(m instanceof Filemark) { > if(m.getb|) > } > } > {code} > Bring up code completion, it show info for Filemark, not ViMark; that could > be handy in some cases. BTW, ViMark is an interface. Select method > getBuffer() and the result is > {code:java} > if(((Filemark)m).getBuffer()) > {code} > ViMark has a getBuffer method, the cast is bogus. The project is marked 1.8 > source. > I tried it after removing cachedir, still failed. A simple test case works. > I'll try to get a smaller case. -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Commented] (NETBEANS-4356) Unneeded/redundant cast added by code completion
[ https://issues.apache.org/jira/browse/NETBEANS-4356?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17113390#comment-17113390 ] Ernie Rael commented on NETBEANS-4356: -- the-example.jar has a minimal project that exhibits the problem. Fails starting up with empty userdir. Unzip the file, open play/UneededCast.java, try code completion as indicated. Would be nice if a fix could... > Unneeded/redundant cast added by code completion > > > Key: NETBEANS-4356 > URL: https://issues.apache.org/jira/browse/NETBEANS-4356 > Project: NetBeans > Issue Type: Bug > Components: editor - Completion Templates >Affects Versions: 12.0 > Environment: Product Version: Apache NetBeans IDE 12.0-beta4 > Updates: Updates available to version NetBeans 8.2 Patch 2 > Java: 14.0.1; Java HotSpot(TM) 64-Bit Server VM 14.0.1+7 > Runtime: Java(TM) SE Runtime Environment 14.0.1+7 > System: Windows 7 version 6.1 running on amd64; UTF-8; en_US (nb) >Reporter: Ernie Rael >Priority: Major > Labels: regresion > Attachments: the-example.jar > > > Consider the code, caret shown as '|', > {code:java} > static private void xxx(ViMark m) { > if(m instanceof Filemark) { > if(m.getb|) > } > } > {code} > Bring up code completion, it show info for Filemark, not ViMark; that could > be handy in some cases. BTW, ViMark is an interface. Select method > getBuffer() and the result is > {code:java} > if(((Filemark)m).getBuffer()) > {code} > ViMark has a getBuffer method, the cast is bogus. The project is marked 1.8 > source. > I tried it after removing cachedir, still failed. A simple test case works. > I'll try to get a smaller case. -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
[jira] [Commented] (NETBEANS-4356) Unneeded/redundant cast added by code completion
[ https://issues.apache.org/jira/browse/NETBEANS-4356?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17112710#comment-17112710 ] Ernie Rael commented on NETBEANS-4356: -- [~jlahoda] added you in case you could triage or ... > Unneeded/redundant cast added by code completion > > > Key: NETBEANS-4356 > URL: https://issues.apache.org/jira/browse/NETBEANS-4356 > Project: NetBeans > Issue Type: Bug > Components: editor - Completion Templates >Affects Versions: 12.0 > Environment: Product Version: Apache NetBeans IDE 12.0-beta4 > Updates: Updates available to version NetBeans 8.2 Patch 2 > Java: 14.0.1; Java HotSpot(TM) 64-Bit Server VM 14.0.1+7 > Runtime: Java(TM) SE Runtime Environment 14.0.1+7 > System: Windows 7 version 6.1 running on amd64; UTF-8; en_US (nb) >Reporter: Ernie Rael >Priority: Major > Labels: regresion > > Consider the code, caret shown as '|', > {code:java} > static private void xxx(ViMark m) { > if(m instanceof Filemark) { > if(m.getb|) > } > } > {code} > Bring up code completion, it show info for Filemark, not ViMark; that could > be handy in some cases. BTW, ViMark is an interface. Select method > getBuffer() and the result is > {code:java} > if(((Filemark)m).getBuffer()) > {code} > ViMark has a getBuffer method, the cast is bogus. The project is marked 1.8 > source. > I tried it after removing cachedir, still failed. A simple test case works. > I'll try to get a smaller case. -- This message was sent by Atlassian Jira (v8.3.4#803005) - To unsubscribe, e-mail: commits-unsubscr...@netbeans.apache.org For additional commands, e-mail: commits-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists