Re: Revisiting default values

2021-07-01 Thread John Rose
> On Jul 1, 2021, at 5:48 AM, Brian Goetz wrote: > > >> >> Which reminds me: I think we should >> allow calls to methods on `this` inside a >> constructor. (Do we?) A clean way to >> statically exclude incomplete values of `this` >> would be to outlaw such self-calls until all >> final fie

Re: [External] : Re: Revisiting default values

2021-07-01 Thread Brian Goetz
I sincerely claim that your statement is in the same boat. You're speaking of what has /happened/ to be the case in Java, because reasons. However, I think the /concept/ of null is more basic; it is just "there is no instance here". Try to do instance stuff, blow up always, that's null.

Re: Revisiting default values

2021-07-01 Thread Brian Goetz
Which reminds me:  I think we should allow calls to methods on `this` inside a constructor.  (Do we?)  A clean way to statically exclude incomplete values of `this` would be to outlaw such self-calls until all final fields are definitely assigned.  The current language (for identity classes) c