You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by "Thomas Zimmermann (JIRA)" <ji...@apache.org> on 2018/09/28 22:32:00 UTC

[jira] [Closed] (NETBEANS-431) Support variables in try-with-resources added in Java 9

     [ https://issues.apache.org/jira/browse/NETBEANS-431?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thomas Zimmermann closed NETBEANS-431.
--------------------------------------
       Resolution: Resolved
    Fix Version/s: 9.0

Just tried it with NetBeans 9.0, works perfectly. Really awesome! :)

> Support variables in try-with-resources added in Java 9
> -------------------------------------------------------
>
>                 Key: NETBEANS-431
>                 URL: https://issues.apache.org/jira/browse/NETBEANS-431
>             Project: NetBeans
>          Issue Type: Improvement
>          Components: java - Editor
>    Affects Versions: 9.0
>            Reporter: Thomas Zimmermann
>            Priority: Major
>             Fix For: 9.0
>
>         Attachments: variables-in-try-with-resources.zip
>
>
> Hi!
> I'm running Netbeans incubator-netbeans-release-218-on-20180220. Having this code in a Java 9 Maven project:
> {code:java}
> AutoCloseable closeable = Stream.of();
> try (closeable) {}
> {code}
> Right now leads to the following error in the editor:
> {noformat}
> variables in try-with-resources not supported in -source 1.8
>   (use -source 9 or higher to enable variables in try-with-resources){noformat}
> I attached a trivial project with this code for convenience.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists