Hi,

I can confirm this behavior for new JDK14 preview features records and
instanceof expression. Running IDE with JDK14 default does not suffice.
By the way. I only get the project (ant based) running if directly
execute run target of build-impl.xml. "Official" way results in

java.lang.UnsupportedClassVersionError: javaapplication1/JavaApplication1 
(class file version 57.65535) was compiled with preview features that are 
unsupported. This version of the Java Runtime only recognizes preview features 
for class file version 58.65535

Might be an ant integration issue with recompiling classes before
executing the java process. (Remove compile on save helps!)

Regards

Benjamin

On 01.02.2020 17:59, Miguel Cardoso Martins wrote:
> Hi Geertjan
>
> thanks for the info, didn't know that.
> I start NetBeans with jdk14 now, but still the java editor shows me a red
> line under the record declaration.
>
> Am Sa., 1. Feb. 2020 um 16:26 Uhr schrieb Geertjan Wielenga <
> geert...@apache.org>:
>
>> NetBeans itself needs to run on JDK 14.
>>
>> The javac from JDK 14 will be used for support for Records.
>>
>> The nb-javac support has not yet been updated for JDK 14, which you would
>> need to install for JDK 14 support when not running NetBeans itself on JDK
>> 14.
>>
>> Gj
>>
>> On Sat, Feb 1, 2020 at 4:18 PM Miguel Cardoso Martins <
>> miguelcardosomart...@gmail.com> wrote:
>>
>>> Hello all.
>>>
>>> I setup a maven project and enabled the preview features but  Netbeans is
>>> not recognizing the record keyword (see attachment).
>>> It compiles and runs without errors though.
>>>
>>> Netbeans itself is running on JDK13
>>> Application is configured to run with JDK14 and has source/compile/run
>>> language level also set to 14.
>>>
>>> Thanks
>>> Miguel
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: dev-unsubscr...@netbeans.apache.org
>>> For additional commands, e-mail: dev-h...@netbeans.apache.org
>>>
>>> For further information about the NetBeans mailing lists, visit:
>>> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>>
>>>

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to