----- Original Message -----
> From: "Brian Goetz" <[email protected]>
> To: "Remi Forax" <[email protected]>
> Cc: "Kevin Bourrillion" <[email protected]>, "amber-spec-experts" 
> <[email protected]>
> Sent: Wednesday, September 28, 2022 11:23:47 PM
> Subject: Re: Paving the on-ramp

>> The other solution is to do something similar to the compact
>> constructor of a record, a compact main that have a syntax which is
>> not currently valid in Java.
> 
> An early iteration had something like that.  I liked it for about five
> minutes!  Then I started to dislike it, because (a) it was going to
> quickly become something that needs to be unlearned and (b) it was
> spending syntax on a very narrow use case, narrow in multiple ways.  And
> fixing (a) by generalizing to "compact methods" didn't feel like a win
> either; now it was just two ways to say the same thing.
> 
> Of all the concepts that it is worth asking users to internalize early,
> I think "methods as aggregations of statements" is it.  (Yes, in this
> version you still have to confront "void" and "()".)

That the main issue with main :)

It's the entry point so it's a special case but at the same time you do not 
want to spend a lot of effort to make it different from a method, so having a 
special syntax is too much.

And not making it a method by allowing to write statements without a method 
like in JavaScript does not work well because you can not write statements 
inside a class.

Rémi

Reply via email to