[ https://issues.apache.org/jira/browse/NETBEANS-4018?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Don updated NETBEANS-4018: -------------------------- Priority: Trivial (was: Major) > incompatible type error - types are compatible > ---------------------------------------------- > > Key: NETBEANS-4018 > URL: https://issues.apache.org/jira/browse/NETBEANS-4018 > Project: NetBeans > Issue Type: Bug > Components: java - Compiler > Affects Versions: 11.3 > Environment: Mac OS Catalina, Netbeans 11.3 > Reporter: Don > Priority: Trivial > > Error "incompatible types - Object cannot be converted to HsOwnr" when in > fact it can and should be. > Example: > {color:#00875a}*public class HsHndlr {*{color} > {color:#00875a}*...*{color} > {color:#00875a} *public static ArrayList<HsOwnr> altrngHsOwnrs = > null;*{color} > {color:#00875a}*...*{color} > {color:#00875a} *static class HsOwnr {*{color} > {color:#00875a}*...*{color} > {color:#00875a} *}*{color} > {color:#00875a}*}* {color} > {color:#00875a}*public class AppCnvsMIA {*{color} > {color:#00875a}*...*{color} > {color:#00875a} *+for ( HsHndlr.HsOwnr altrngOwnr : HsHndlr.altrngHsOwnrs ) > {+*{color} > {color:#00875a}*...*{color} > {color:#00875a} *}*{color} > {color:#00875a}*}*{color} > The above give the error. But a compile (Clean and Build) is successful - no > errors in the compile and build. The error is removed when the following is > done. > {color:#ff8b00}*public class AppCnvsMIA {*{color} > {color:#ff8b00}*...*{color} > {color:#00875a}*// +for ( HsHndlr.HsOwnr altrngOwnr : HsHndlr.altrngHsOwnrs > ) {+*{color} > {color:#ff8b00} *ArrayList<HsHndlr.HsOwnr> localOwnrsList = > HsHndlr.altrngHsOwnrs;* > *for ( HsHndlr.HsOwnr altrngOwnr :* *localOwnrsList* *) {*{color} > {color:#ff8b00}*...*{color} > {color:#ff8b00} *}*{color} > {color:#ff8b00}*}*{color} > This error just cropped up within the last week or so, and I have made no > upgrades to the Netbeans environment in months. I think some "automatic" > update may have occurred, but I don't know how that could be. > -- 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