Re: Records are called „methods“ in JShell
Robert Field
robert.field at oracle.com
Wed Jul 15 03:07:23 UTC 2020
I have a theory, maybe the following can illuminate...
Couple more things to try:
/set feedback
/set format normal typeKind
And send us what it prints.
Also, after you have entered:
public record ConstExpr(Expr e) implements Expr{}
Type:
/type
and
/method
Separately, what do they print?
Oh, and if you want to try one more thing:
/set feedback verbose
public record ConstExpr(Expr e) implements Expr{}
Sorry, I don't have Windows, but I believe Jan has access.
-Robert
On 2020-07-14 18:35, Lingo Coder wrote:
> Thanks Robert,
>
>> „...Can you do:
>> jshell --full-version...“
>
> I did that. It says jshell 15-ea+31-1502 [1]
>
> What version of Windows are you other guys trying this in? I'm on
> Windows 7.
>
>> „...I'm guessing you may be using an older JDK...“
> As I show in [1] and in earlier screen recordings, I completely
> clear my $PATH to confirm that there is no other jshell.exe on
> the $PATH.
>
> I have not installed any JDKs with an installer or anything
> like that. For that reason, I rule out anything registry-related.
>
> I do have an early access release of 14-Valhalla
> build 14-valhalla+4-55 on my workstation. But, that was
> installed by simply unzipping the archive into a
> jdk-14.L.world.Build.14-valhalla+4-55 folder. More importantly,
> that build doesn't even have the records nor the sealed types
> features.
>
> I also have GA releases of OpenJDK 12 & 13 in their own folders.
> But again, not only are they isolated well out of the way of
> the $PATH I run jshell 15 in, they don't even have records and
> sealed types functionality.
>
> If _any_ other JDK were somehow in the $PATH, it would be
> surprising if records and sealed types even worked _at all_;
> let alone the misnaming as „methods“ issue Right? Please
> correct me if I'm wrong?
>
>
> [1] https://imgur.com/cMsAl5f
>
> -------- Original Message --------
> Subject: Re:_Records_are_called_„methods“_in_JSh ell
> From: Robert Field <robert.field at oracle.com>
> Date: Tue, July 14, 2020 3:57 pm
> To: kulla-dev at openjdk.java.net, jorn.vernee at oracle.com,
> plugins at lingocoder.com
>
> I'm guessing you may be using an older JDK. I get:
> jshell> public record ConstExpr(Expr e) implements Expr{}
> | created record ConstExpr
>
> jshell> /drop ConstExpr
> | dropped record ConstExpr
>
>
> Can you do:
> jshell --full-version
>
> Thanks,
> Robert
>
>
>
More information about the kulla-dev
mailing list