You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@netbeans.apache.org by Miguel Cardoso Martins <mi...@gmail.com> on 2020/02/01 15:17:56 UTC

Apache NetBeans 11.3 beta2 not recognizing records

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

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Geertjan Wielenga <ge...@apache.org>.
Anyone having issues with this, please post what you see under Help | About
(or NetBeans | About NetBeans on Mac). Here's mine:

*Product Version:* Apache NetBeans IDE 11.3-beta2

*Java:* 14-ea; OpenJDK 64-Bit Server VM 14-ea+34-1452

*Runtime:* OpenJDK Runtime Environment 14-ea+34-1452

*System:* Mac OS X version 10.13.6 running on x86_64; UTF-8; en_NL (nb)



Thanks,


Gj



On Sat, Feb 1, 2020 at 7:59 PM Geertjan Wielenga <ge...@apache.org>
wrote:

> Can you try to reproduce with this:
>
> https://github.com/geertjanw/jdk14-preview-enabled
>
> Gj
>
> On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net>
> wrote:
>
>> 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 <ge...@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 <mi...@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-unsubscribe@netbeans.apache.org
>> For additional commands, e-mail: dev-help@netbeans.apache.org
>>
>> For further information about the NetBeans mailing lists, visit:https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>
>>

Re: Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Eric Bresie <eb...@gmail.com>.
Just curious...I thought the indication was this was around a preview feature. If so could this be a matter of enabling the feature with applicable pargumenta in compilation and/or runtime?

https://docs.oracle.com/en/java/javase/13/language/preview-language-and-vm-features.html

Eric Bresie
Ebresie@gmail.com
> On February 1, 2020 at 1:18:14 PM CST, Geertjan Wielenga <ge...@apache.org> wrote:
> Probably because you are using nb-javac without realizing it.
>
> In the Plugin Manager, look for it in the Installed tab and then uninstall it.
>
> Gj
>
>
> On Sat, Feb 1, 2020 at 8:17 PM Benjamin Graf <benjamin.graf@gmx.net (mailto:benjamin.graf@gmx.net)> wrote:
> >
> > Hi Geertjan,
> >
> >
> > still the same errors shown in editor:
> >
> >
> >
> >
> >
> >
> >
> >
> > Product Version: Apache NetBeans IDE 11.3-beta2
> >
> >
> > Java: 14; OpenJDK 64-Bit Server VM 14+33-202001311506
> >
> >
> > Runtime: OpenJDK Runtime Environment 14+33-202001311506
> >
> >
> > System: Windows 10 version 10.0 running on amd64; Cp1252; de_DE (nb)
> >
> >
> >
> > Regards
> >
> >
> > Benjamin
> >
> >
> >
> > On 01.02.2020 19:59, Geertjan Wielenga wrote:
> > > Can you try to reproduce with this: https://github.com/geertjanw/jdk14-preview-enabled Gj On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net> (mailto:benjamin.graf@gmx.net) wrote:
> > > > 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 <ge...@apache.org> (mailto:geertjan@
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 <mi...@gmail.com> (mailto:miguelcardosomartins@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-unsubscribe@netbeans.apache.org (mailto:dev-unsubscribe@netbeans.apache.org)For additional commands, e-mail: dev-help@netbeans.apache.org (mailto:dev-help@netbeans.
apache.org) For further information about the NetBeans mailing lists, visit:https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
> > >
> > >
> >
> >
>
>
>


Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Geertjan Wielenga <ge...@apache.org>.
On Sat, 1 Feb 2020 at 20:53, Miguel Cardoso Martins <
miguelcardosomartins@gmail.com> wrote:

> Indeed that is the solution.
> I had previously only deactivated the nb-javac plugin.
>
> But what if someone wants to have both the preview features and nb-javac
> benefits?



nb-javac does not support JDK 14 yet, though it will.

Gj




> A checkbox "enable-preview" in the project properties , that would patch
> the pom and bypass nb-javac would be helpful
>
>
>
> Am Sa., 1. Feb. 2020 um 20:32 Uhr schrieb Geertjan Wielenga <
> geertjan@apache.org>:
>
> > Excellent that you got it to work.
> >
> > Gj
> >
> > On Sat, 1 Feb 2020 at 20:30, Benjamin Graf <be...@gmx.net>
> wrote:
> >
> > > Good catch! :-) Uninstalling nb-javac works. I'm wondering why just
> > > deactivating does not solve it. Tried both scenarios.
> > >
> > > Benjamin
> > >
> > > On 01.02.2020 20:18, Geertjan Wielenga wrote:
> > > > Probably because you are using nb-javac without realizing it.
> > > >
> > > > In the Plugin Manager, look for it in the Installed tab and then
> > > uninstall
> > > > it.
> > > >
> > > > Gj
> > > >
> > > >
> > > > On Sat, Feb 1, 2020 at 8:17 PM Benjamin Graf <be...@gmx.net>
> > > wrote:
> > > >
> > > >> Hi Geertjan,
> > > >>
> > > >> still the same errors shown in editor:
> > > >>
> > > >> *Product Version:* Apache NetBeans IDE 11.3-beta2
> > > >>
> > > >> *Java:* 14; OpenJDK 64-Bit Server VM 14+33-202001311506
> > > >>
> > > >> *Runtime:* OpenJDK Runtime Environment 14+33-202001311506
> > > >>
> > > >> *System:* Windows 10 version 10.0 running on amd64; Cp1252; de_DE
> (nb)
> > > >>
> > > >> Regards
> > > >>
> > > >> Benjamin
> > > >> On 01.02.2020 19:59, Geertjan Wielenga wrote:
> > > >>
> > > >> Can you try to reproduce with this:
> > > >> https://github.com/geertjanw/jdk14-preview-enabled
> > > >>
> > > >> Gj
> > > >>
> > > >> On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <benjamin.graf@gmx.net
> >
> > <
> > > benjamin.graf@gmx.net> wrote:
> > > >>
> > > >>
> > > >> 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 <
> > > geertjan@apache.org> <ge...@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 <
> > > miguelcardosomartins@gmail.com> <mi...@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-unsubscribe@netbeans.apache.org
> > > >> For additional commands, e-mail: dev-help@netbeans.apache.org
> > > >>
> > > >> For further information about the NetBeans mailing lists, visit:
> > > https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
> > > >>
> > > >>
> > >
> > >
> >
>

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Benjamin Graf <be...@gmx.net>.
+1

On 01.02.2020 20:53, Miguel Cardoso Martins wrote:
> Indeed that is the solution.
> I had previously only deactivated the nb-javac plugin.
>
> But what if someone wants to have both the preview features and nb-javac
> benefits?
> A checkbox "enable-preview" in the project properties , that would patch
> the pom and bypass nb-javac would be helpful
>
>
>
> Am Sa., 1. Feb. 2020 um 20:32 Uhr schrieb Geertjan Wielenga <
> geertjan@apache.org>:
>
>> Excellent that you got it to work.
>>
>> Gj
>>
>> On Sat, 1 Feb 2020 at 20:30, Benjamin Graf <be...@gmx.net> wrote:
>>
>>> Good catch! :-) Uninstalling nb-javac works. I'm wondering why just
>>> deactivating does not solve it. Tried both scenarios.
>>>
>>> Benjamin
>>>
>>> On 01.02.2020 20:18, Geertjan Wielenga wrote:
>>>> Probably because you are using nb-javac without realizing it.
>>>>
>>>> In the Plugin Manager, look for it in the Installed tab and then
>>> uninstall
>>>> it.
>>>>
>>>> Gj
>>>>
>>>>
>>>> On Sat, Feb 1, 2020 at 8:17 PM Benjamin Graf <be...@gmx.net>
>>> wrote:
>>>>> Hi Geertjan,
>>>>>
>>>>> still the same errors shown in editor:
>>>>>
>>>>> *Product Version:* Apache NetBeans IDE 11.3-beta2
>>>>>
>>>>> *Java:* 14; OpenJDK 64-Bit Server VM 14+33-202001311506
>>>>>
>>>>> *Runtime:* OpenJDK Runtime Environment 14+33-202001311506
>>>>>
>>>>> *System:* Windows 10 version 10.0 running on amd64; Cp1252; de_DE (nb)
>>>>>
>>>>> Regards
>>>>>
>>>>> Benjamin
>>>>> On 01.02.2020 19:59, Geertjan Wielenga wrote:
>>>>>
>>>>> Can you try to reproduce with this:
>>>>> https://github.com/geertjanw/jdk14-preview-enabled
>>>>>
>>>>> Gj
>>>>>
>>>>> On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net>
>> <
>>> benjamin.graf@gmx.net> wrote:
>>>>>
>>>>> 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 <
>>> geertjan@apache.org> <ge...@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 <
>>> miguelcardosomartins@gmail.com> <mi...@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-unsubscribe@netbeans.apache.org
>>>>> For additional commands, e-mail: dev-help@netbeans.apache.org
>>>>>
>>>>> For further information about the NetBeans mailing lists, visit:
>>> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>>>>
>>>


Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Miguel Cardoso Martins <mi...@gmail.com>.
Indeed that is the solution.
I had previously only deactivated the nb-javac plugin.

But what if someone wants to have both the preview features and nb-javac
benefits?
A checkbox "enable-preview" in the project properties , that would patch
the pom and bypass nb-javac would be helpful



Am Sa., 1. Feb. 2020 um 20:32 Uhr schrieb Geertjan Wielenga <
geertjan@apache.org>:

> Excellent that you got it to work.
>
> Gj
>
> On Sat, 1 Feb 2020 at 20:30, Benjamin Graf <be...@gmx.net> wrote:
>
> > Good catch! :-) Uninstalling nb-javac works. I'm wondering why just
> > deactivating does not solve it. Tried both scenarios.
> >
> > Benjamin
> >
> > On 01.02.2020 20:18, Geertjan Wielenga wrote:
> > > Probably because you are using nb-javac without realizing it.
> > >
> > > In the Plugin Manager, look for it in the Installed tab and then
> > uninstall
> > > it.
> > >
> > > Gj
> > >
> > >
> > > On Sat, Feb 1, 2020 at 8:17 PM Benjamin Graf <be...@gmx.net>
> > wrote:
> > >
> > >> Hi Geertjan,
> > >>
> > >> still the same errors shown in editor:
> > >>
> > >> *Product Version:* Apache NetBeans IDE 11.3-beta2
> > >>
> > >> *Java:* 14; OpenJDK 64-Bit Server VM 14+33-202001311506
> > >>
> > >> *Runtime:* OpenJDK Runtime Environment 14+33-202001311506
> > >>
> > >> *System:* Windows 10 version 10.0 running on amd64; Cp1252; de_DE (nb)
> > >>
> > >> Regards
> > >>
> > >> Benjamin
> > >> On 01.02.2020 19:59, Geertjan Wielenga wrote:
> > >>
> > >> Can you try to reproduce with this:
> > >> https://github.com/geertjanw/jdk14-preview-enabled
> > >>
> > >> Gj
> > >>
> > >> On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net>
> <
> > benjamin.graf@gmx.net> wrote:
> > >>
> > >>
> > >> 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 <
> > geertjan@apache.org> <ge...@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 <
> > miguelcardosomartins@gmail.com> <mi...@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-unsubscribe@netbeans.apache.org
> > >> For additional commands, e-mail: dev-help@netbeans.apache.org
> > >>
> > >> For further information about the NetBeans mailing lists, visit:
> > https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
> > >>
> > >>
> >
> >
>

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Geertjan Wielenga <ge...@apache.org>.
Excellent that you got it to work.

Gj

On Sat, 1 Feb 2020 at 20:30, Benjamin Graf <be...@gmx.net> wrote:

> Good catch! :-) Uninstalling nb-javac works. I'm wondering why just
> deactivating does not solve it. Tried both scenarios.
>
> Benjamin
>
> On 01.02.2020 20:18, Geertjan Wielenga wrote:
> > Probably because you are using nb-javac without realizing it.
> >
> > In the Plugin Manager, look for it in the Installed tab and then
> uninstall
> > it.
> >
> > Gj
> >
> >
> > On Sat, Feb 1, 2020 at 8:17 PM Benjamin Graf <be...@gmx.net>
> wrote:
> >
> >> Hi Geertjan,
> >>
> >> still the same errors shown in editor:
> >>
> >> *Product Version:* Apache NetBeans IDE 11.3-beta2
> >>
> >> *Java:* 14; OpenJDK 64-Bit Server VM 14+33-202001311506
> >>
> >> *Runtime:* OpenJDK Runtime Environment 14+33-202001311506
> >>
> >> *System:* Windows 10 version 10.0 running on amd64; Cp1252; de_DE (nb)
> >>
> >> Regards
> >>
> >> Benjamin
> >> On 01.02.2020 19:59, Geertjan Wielenga wrote:
> >>
> >> Can you try to reproduce with this:
> >> https://github.com/geertjanw/jdk14-preview-enabled
> >>
> >> Gj
> >>
> >> On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net> <
> benjamin.graf@gmx.net> wrote:
> >>
> >>
> >> 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 <
> geertjan@apache.org> <ge...@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 <
> miguelcardosomartins@gmail.com> <mi...@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-unsubscribe@netbeans.apache.org
> >> For additional commands, e-mail: dev-help@netbeans.apache.org
> >>
> >> For further information about the NetBeans mailing lists, visit:
> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
> >>
> >>
>
>

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Benjamin Graf <be...@gmx.net>.
Good catch! :-) Uninstalling nb-javac works. I'm wondering why just
deactivating does not solve it. Tried both scenarios.

Benjamin

On 01.02.2020 20:18, Geertjan Wielenga wrote:
> Probably because you are using nb-javac without realizing it.
>
> In the Plugin Manager, look for it in the Installed tab and then uninstall
> it.
>
> Gj
>
>
> On Sat, Feb 1, 2020 at 8:17 PM Benjamin Graf <be...@gmx.net> wrote:
>
>> Hi Geertjan,
>>
>> still the same errors shown in editor:
>>
>> *Product Version:* Apache NetBeans IDE 11.3-beta2
>>
>> *Java:* 14; OpenJDK 64-Bit Server VM 14+33-202001311506
>>
>> *Runtime:* OpenJDK Runtime Environment 14+33-202001311506
>>
>> *System:* Windows 10 version 10.0 running on amd64; Cp1252; de_DE (nb)
>>
>> Regards
>>
>> Benjamin
>> On 01.02.2020 19:59, Geertjan Wielenga wrote:
>>
>> Can you try to reproduce with this:
>> https://github.com/geertjanw/jdk14-preview-enabled
>>
>> Gj
>>
>> On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net> <be...@gmx.net> wrote:
>>
>>
>> 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 <ge...@apache.org> <ge...@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 <mi...@gmail.com> <mi...@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-unsubscribe@netbeans.apache.org
>> For additional commands, e-mail: dev-help@netbeans.apache.org
>>
>> For further information about the NetBeans mailing lists, visit:https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>
>>


Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Geertjan Wielenga <ge...@apache.org>.
Probably because you are using nb-javac without realizing it.

In the Plugin Manager, look for it in the Installed tab and then uninstall
it.

Gj


On Sat, Feb 1, 2020 at 8:17 PM Benjamin Graf <be...@gmx.net> wrote:

> Hi Geertjan,
>
> still the same errors shown in editor:
>
> *Product Version:* Apache NetBeans IDE 11.3-beta2
>
> *Java:* 14; OpenJDK 64-Bit Server VM 14+33-202001311506
>
> *Runtime:* OpenJDK Runtime Environment 14+33-202001311506
>
> *System:* Windows 10 version 10.0 running on amd64; Cp1252; de_DE (nb)
>
> Regards
>
> Benjamin
> On 01.02.2020 19:59, Geertjan Wielenga wrote:
>
> Can you try to reproduce with this:
> https://github.com/geertjanw/jdk14-preview-enabled
>
> Gj
>
> On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net> <be...@gmx.net> wrote:
>
>
> 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 <ge...@apache.org> <ge...@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 <mi...@gmail.com> <mi...@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-unsubscribe@netbeans.apache.org
> For additional commands, e-mail: dev-help@netbeans.apache.org
>
> For further information about the NetBeans mailing lists, visit:https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>
>

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Benjamin Graf <be...@gmx.net>.
Hi Geertjan,

still the same errors shown in editor:

*Product Version:* Apache NetBeans IDE 11.3-beta2

*Java:* 14; OpenJDK 64-Bit Server VM 14+33-202001311506

*Runtime:* OpenJDK Runtime Environment 14+33-202001311506

*System:* Windows 10 version 10.0 running on amd64; Cp1252; de_DE (nb)

Regards

Benjamin

On 01.02.2020 19:59, Geertjan Wielenga wrote:
> Can you try to reproduce with this:
>
> https://github.com/geertjanw/jdk14-preview-enabled
>
> Gj
>
> On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net> wrote:
>
>> 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 <ge...@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 <mi...@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-unsubscribe@netbeans.apache.org
>> For additional commands, e-mail: dev-help@netbeans.apache.org
>>
>> For further information about the NetBeans mailing lists, visit:https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>
>>

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Geertjan Wielenga <ge...@apache.org>.
Can you try to reproduce with this:

https://github.com/geertjanw/jdk14-preview-enabled

Gj

On Sat, Feb 1, 2020 at 6:24 PM Benjamin Graf <be...@gmx.net> wrote:

> 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 <ge...@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 <mi...@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-unsubscribe@netbeans.apache.org
> For additional commands, e-mail: dev-help@netbeans.apache.org
>
> For further information about the NetBeans mailing lists, visit:https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>
>

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Benjamin Graf <be...@gmx.net>.
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 <
> geertjan@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 <
>> miguelcardosomartins@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-unsubscribe@netbeans.apache.org
>>> For additional commands, e-mail: dev-help@netbeans.apache.org
>>>
>>> For further information about the NetBeans mailing lists, visit:
>>> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>>
>>>

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Miguel Cardoso Martins <mi...@gmail.com>.
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 <
geertjan@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 <
> miguelcardosomartins@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-unsubscribe@netbeans.apache.org
> > For additional commands, e-mail: dev-help@netbeans.apache.org
> >
> > For further information about the NetBeans mailing lists, visit:
> > https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
> >
> >
>

Re: Apache NetBeans 11.3 beta2 not recognizing records

Posted by Geertjan Wielenga <ge...@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 <
miguelcardosomartins@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-unsubscribe@netbeans.apache.org
> For additional commands, e-mail: dev-help@netbeans.apache.org
>
> For further information about the NetBeans mailing lists, visit:
> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>
>