You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by "ARUNAVA SINHA (JIRA)" <ji...@apache.org> on 2019/04/24 06:48:00 UTC

[jira] [Created] (NETBEANS-2457) Error hint to fix the '--enable-preview' features in java project

ARUNAVA SINHA created NETBEANS-2457:
---------------------------------------

             Summary: Error hint to fix the '--enable-preview' features in java project
                 Key: NETBEANS-2457
                 URL: https://issues.apache.org/jira/browse/NETBEANS-2457
             Project: NetBeans
          Issue Type: Improvement
            Reporter: ARUNAVA SINHA
            Assignee: ARUNAVA SINHA
             Fix For: 12.0


Suppose we had used switch-expression in a Java Project (JDK-12)

e.g.,

int a = switch (num)

{      case 1 ->1;     default->2; };

It will show the below error:

switch expressions are a preview feature and are disabled by default.
 (use --enable-preview to enable switch expressions)

 

NetBeans doesn't provide the fix.

Manually need to add 'enable-preview" in project properties.



--
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