Re: [RFC] Asymmetric Visibility, v2

From: Date: Fri, 31 May 2024 22:21:01 +0000
Subject: Re: [RFC] Asymmetric Visibility, v2
References: 1 2 3 4 5 6  Groups: php.internals 
Request: Send a blank email to internals+get-123482@lists.php.net to get a copy of this message
> Le 31 mai 2024 à 18:08, Larry Garfield <larry@garfieldtech.com> a écrit : > > So we feel the best way forward is to make the following changes: > > * private(set) implicitly means "final". (You can declare it explicitly if you want, > but it isn't necessary.) > * Make readonly incompatible with aviz again. > > Thoughts? After reflection, I don’t think that we need to make readonly incompatible with aviz, even with the current semantics of readonly (at least logically; no idea about implementationally): * legacy-readonly properties could keep their own peculiar private-overridable(set) if they want; * aviz-readonly properties have, by definition, one of public(set), protected(set) or private(set) marker; those will work regularly, including the implicit final attached to private(set); * a non-aviz readonly property could not be redeclared in a subclass as aviz-readonly, and vice versa. —Claude

« previous php.internals (#123482) next »