Welcome! Log In Create A New Profile

Advanced

[PHP-DEV] [RFC] Typed Properties

Posted by Nikita Popov 
shinji igarashi
Re: [PHP-DEV] [RFC] Typed Properties
July 05, 2018 05:10PM
https://marc.info/?l=php-internals&m=136093001212358&w=2
Maybe the opcache case in PHP5.5 is a precendent, I think.

2018年7月5日(木) 20:26 Christoph M. Becker <[email protected]>:

> On 05.07.2018 at 13:05, Björn Larsson wrote:
>
> > Den 2018-07-05 kl. 12:17, skrev Nikita Popov:
> >
> >> On Thu, Jul 5, 2018 at 11:09 AM, Björn Larsson
> >> <[email protected]>
> >> wrote:
> >>
> >>> Den 2018-06-21 kl. 20:41, skrev Sara Golemon:
> >>>
> >>> On Thu, Jun 21, 2018 at 12:57 PM, Dan Ackroyd <[email protected]>
> >>>> wrote:
> >>>>
> >>>>> On 21 June 2018 at 17:49, Stanislav Malyshev <[email protected]>
> >>>>> wrote:
> >>>>>
> >>>>>> I think it's better not
> >>>>>> to feel pressured by the deadline for 7.3
> >>>>>>
> >>>>> The deadline isn't a deadline - it's just the current consensus for
> >>>>> when we'd like to see 7.3 released.
> >>>>>
> >>>>> If people thought this RFC needed more time but would make PHP 7.3 a
> >>>>> lot better, would there be any harm in moving the 7.3 release back a
> >>>>> few weeks?
> >>>>>
> >>>>> Sure. I would *far* prefer that over jamming this in without any
> >>>> change in the GA date. We have to be careful about exactly when we
> >>>> push it to. The current GA date wasn't chosen arbitrarily, but with
> >>>> concern regarding the proximity to the holiday season.
> >>>
> >>> Any chance getting this into 7.3? I think it would be a
> >>> great addition. According to Marco Pivettas mail from
> >>> 26/6 it works flawlessly.
> >>>
> >>> Givven the current discussion about 8.0 it feels a bit
> >>> way off having this to wait for this feature until 2020.
> >>
> >> We have recently finished the last major change to the implementation
> >> (switching to https://wiki.php.net/rfc/typed_properties_v2#
> >> references_without_intrinsic_type -- the RFC still needs to be updated
> >> for
> >> this change). However, there is still quite a bit of refactoring and
> >> polish
> >> to be done. Unfortunately, we are running out of time. There are already
> >> less than two weeks until the currently planned feature freeze, before
> >> which the vote must be finished and the implementation merged. For such
> a
> >> major feature, I don't like the idea of rushing the vote to such a
> >> degree.
> >>
> >> As such, I think that this feature can only go into 7.3 if the release
> >> schedule is adjusted. Extending the schedule by another 2-week alpha
> >> cycle
> >> would be sufficient to land this proposal in PHP 7.3. Otherwise it will
> >> just have to wait a few years for the next applicable release (based on
> >> recent discussions, it's not entirely clear whether that would be PHP
> 7.4
> >> or 8.0).
> >
> > Sounds like the RMs for 7.3 need to weigh in on this.
> > For me I think it's worthwhile delaying two weeks, +1.
>
> Is there any precendent for postponing feature freeze during the (late)
> alpha stage?
>
> --
> Christoph M. Becker
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
Nikita Popov
Re: [PHP-DEV] [RFC] Typed Properties
July 05, 2018 05:30PM
On Thu, Jul 5, 2018 at 1:25 PM, Christoph M. Becker <[email protected]>
wrote:

> On 05.07.2018 at 13:05, Björn Larsson wrote:
>
> > Den 2018-07-05 kl. 12:17, skrev Nikita Popov:
> >
> >> On Thu, Jul 5, 2018 at 11:09 AM, Björn Larsson
> >> <[email protected]>
> >> wrote:
> >>
> >>> Den 2018-06-21 kl. 20:41, skrev Sara Golemon:
> >>>
> >>> On Thu, Jun 21, 2018 at 12:57 PM, Dan Ackroyd <[email protected]>
> >>>> wrote:
> >>>>
> >>>>> On 21 June 2018 at 17:49, Stanislav Malyshev <[email protected]>
> >>>>> wrote:
> >>>>>
> >>>>>> I think it's better not
> >>>>>> to feel pressured by the deadline for 7.3
> >>>>>>
> >>>>> The deadline isn't a deadline - it's just the current consensus for
> >>>>> when we'd like to see 7.3 released.
> >>>>>
> >>>>> If people thought this RFC needed more time but would make PHP 7.3 a
> >>>>> lot better, would there be any harm in moving the 7.3 release back a
> >>>>> few weeks?
> >>>>>
> >>>>> Sure. I would *far* prefer that over jamming this in without any
> >>>> change in the GA date. We have to be careful about exactly when we
> >>>> push it to. The current GA date wasn't chosen arbitrarily, but with
> >>>> concern regarding the proximity to the holiday season.
> >>>
> >>> Any chance getting this into 7.3? I think it would be a
> >>> great addition. According to Marco Pivettas mail from
> >>> 26/6 it works flawlessly.
> >>>
> >>> Givven the current discussion about 8.0 it feels a bit
> >>> way off having this to wait for this feature until 2020.
> >>
> >> We have recently finished the last major change to the implementation
> >> (switching to https://wiki.php.net/rfc/typed_properties_v2#
> >> references_without_intrinsic_type -- the RFC still needs to be updated
> >> for
> >> this change). However, there is still quite a bit of refactoring and
> >> polish
> >> to be done. Unfortunately, we are running out of time. There are already
> >> less than two weeks until the currently planned feature freeze, before
> >> which the vote must be finished and the implementation merged. For such
> a
> >> major feature, I don't like the idea of rushing the vote to such a
> >> degree.
> >>
> >> As such, I think that this feature can only go into 7.3 if the release
> >> schedule is adjusted. Extending the schedule by another 2-week alpha
> >> cycle
> >> would be sufficient to land this proposal in PHP 7.3. Otherwise it will
> >> just have to wait a few years for the next applicable release (based on
> >> recent discussions, it's not entirely clear whether that would be PHP
> 7.4
> >> or 8.0).
> >
> > Sounds like the RMs for 7.3 need to weigh in on this.
> > For me I think it's worthwhile delaying two weeks, +1.
>
> Is there any precendent for postponing feature freeze during the (late)
> alpha stage?
>

This was done for the PHP 7.1 release at pretty much the same time (before
the beta1 release it was decided to go with another alpha instead), for
much the same reasons (pending RFCs, though I don't remember the
specifics). See https://externals.io/message/94330 for the announcement
mail.

Nikita
Christoph M. Becker
Re: [PHP-DEV] [RFC] Typed Properties
July 05, 2018 05:40PM
On 05.07.2018 at 17:25, Nikita Popov wrote:

> On Thu, Jul 5, 2018 at 1:25 PM, Christoph M. Becker <[email protected]>
> wrote:
>
>> On 05.07.2018 at 13:05, Björn Larsson wrote:
>>
>>> Den 2018-07-05 kl. 12:17, skrev Nikita Popov:
>>>
>>>> As such, I think that this feature can only go into 7.3 if the release
>>>> schedule is adjusted. Extending the schedule by another 2-week alpha
>>>> cycle
>>>> would be sufficient to land this proposal in PHP 7.3. Otherwise it will
>>>> just have to wait a few years for the next applicable release (based on
>>>> recent discussions, it's not entirely clear whether that would be PHP
>> 7.4
>>>> or 8.0).
>>>
>>> Sounds like the RMs for 7.3 need to weigh in on this.
>>> For me I think it's worthwhile delaying two weeks, +1.
>>
>> Is there any precendent for postponing feature freeze during the (late)
>> alpha stage?
>
> This was done for the PHP 7.1 release at pretty much the same time (before
> the beta1 release it was decided to go with another alpha instead), for
> much the same reasons (pending RFCs, though I don't remember the
> specifics). See https://externals.io/message/94330 for the announcement
> mail.

Ah, thanks, Nikita! Considering this, I'm not against delaying beta1
for two weeks and having an alpha4, provided that we do not allow any
new (i.e. not yet under discussion) RFC to target 7.3.

Stas, what do you think?

--
Christoph M. Becker

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Sara Golemon
Re: [PHP-DEV] [RFC] Typed Properties
July 05, 2018 08:50PM
On Thu, Jul 5, 2018 at 11:37 AM, Christoph M. Becker <[email protected]> wrote:
>>> Is there any precendent for postponing feature freeze during the (late)
>>> alpha stage?
>>
>> This was done for the PHP 7.1 release at pretty much the same time (before
>> the beta1 release it was decided to go with another alpha instead), for
>> much the same reasons (pending RFCs, though I don't remember the
>> specifics). See https://externals.io/message/94330 for the announcement
>> mail.
>
> Ah, thanks, Nikita! Considering this, I'm not against delaying beta1
> for two weeks and having an alpha4, provided that we do not allow any
> new (i.e. not yet under discussion) RFC to target 7.3.
>
> Stas, what do you think?
>
It's up to a combination of [email protected] opinion, and RM best-judgement.
I for one, see no issue with pushing FF out (we can do an alpha4, even
an alpha5). On the other end we have the option of reducing the
number of RCs, or pushing GA by the same delay. FTR; I'd favor
pushing GA out over shortening the RC cycle, but I wouldn't lose sleep
if we wanted to keep the GA date where it is.

-Sara

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Sara Golemon
Re: [PHP-DEV] [RFC] Typed Properties
July 06, 2018 09:40PM
> It's up to a combination of [email protected] opinion, and RM best-judgement.
> I for one, see no issue with pushing FF out (we can do an alpha4, even
> an alpha5). On the other end we have the option of reducing the
> number of RCs, or pushing GA by the same delay. FTR; I'd favor
> pushing GA out over shortening the RC cycle, but I wouldn't lose sleep
> if we wanted to keep the GA date where it is.
>
Just want to be annoying about this since the currently scheduled fork
date for PHP-7.3 is 11 days off.
1/ Do we have *ANY* objections to additional alpha(s) to accommodate
Typed Props? (I would propose two additional alphas)
2/ Do we actually need to hold a formal vote? (If so, that vote should
start *now*)

Assuming the answer to both questions is 'No'. I'd like to propose the
7.3 RMs update https://wiki.php.net/todo/php73 to reflect a new
schedule with alpha4 and alpha5 and (provisionally) only four RCs to
maintain the same GA date, but that we should revisit the topic
sometime around the new RC2 date.

-Sara

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Christoph M. Becker
Re: [PHP-DEV] [RFC] Typed Properties
July 06, 2018 10:50PM
On 06.07.2018 at 21:35, Sara Golemon wrote:

>> It's up to a combination of [email protected] opinion, and RM best-judgement.
>> I for one, see no issue with pushing FF out (we can do an alpha4, even
>> an alpha5). On the other end we have the option of reducing the
>> number of RCs, or pushing GA by the same delay. FTR; I'd favor
>> pushing GA out over shortening the RC cycle, but I wouldn't lose sleep
>> if we wanted to keep the GA date where it is.
>
> Just want to be annoying about this since the currently scheduled fork
> date for PHP-7.3 is 11 days off.

Thanks, Sara! :)

> 1/ Do we have *ANY* objections to additional alpha(s) to accommodate
> Typed Props? (I would propose two additional alphas)
> 2/ Do we actually need to hold a formal vote? (If so, that vote should
> start *now*)

For me: no and no.

> Assuming the answer to both questions is 'No'. I'd like to propose the
> 7.3 RMs update https://wiki.php.net/todo/php73 to reflect a new
> schedule with alpha4 and alpha5 and (provisionally) only four RCs to
> maintain the same GA date, but that we should revisit the topic
> sometime around the new RC2 date.

Why should we have 2 additional alphas? In my opinion, a single
additional alpha is sufficient, and it is really important not to add
yet further features.

--
Christoph M. Becker

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Nicolas Grekas
Re: [PHP-DEV] [RFC] Typed Properties
July 06, 2018 11:00PM
Le jeu. 21 juin 2018 à 19:37, Nicolas Grekas <[email protected]>
a écrit :

> if ((new ReflectionReference($array[$key]))->getRefcount() > 2) { /* is
>> ref */ } else { /* not a ref */ }, for computing the allowed types you’d
>> intersect the types of the ReflectionProperties returned by
>> getReferencingProperties().
>>
>

I just realized that this interface would suffer from a significant
drawback: it would trigger COW when iterating over immutable arrays,
defeating the shared-memory optimization provided by OPcache.

An interface like new ReflectionReference($array, $key) would be free from
the issue. Combined with get_defined_vars() and the (array) operator for
objects, we can inspect any PHP data structure or scope also this way.

Nicolas

>
Björn Larsson
Re: [PHP-DEV] [RFC] Typed Properties
July 07, 2018 10:50AM
On 7/6/2018 9:35 PM, Sara Golemon wrote:
>> It's up to a combination of [email protected] opinion, and RM best-judgement.
>> I for one, see no issue with pushing FF out (we can do an alpha4, even
>> an alpha5). On the other end we have the option of reducing the
>> number of RCs, or pushing GA by the same delay. FTR; I'd favor
>> pushing GA out over shortening the RC cycle, but I wouldn't lose sleep
>> if we wanted to keep the GA date where it is.
>>
> Just want to be annoying about this since the currently scheduled fork
> date for PHP-7.3 is 11 days off.
> 1/ Do we have *ANY* objections to additional alpha(s) to accommodate
> Typed Props? (I would propose two additional alphas)
> 2/ Do we actually need to hold a formal vote? (If so, that vote should
> start *now*)

For me that's no and no.
>
> Assuming the answer to both questions is 'No'. I'd like to propose the
> 7.3 RMs update https://wiki.php.net/todo/php73 to reflect a new
> schedule with alpha4 and alpha5 and (provisionally) only four RCs to
> maintain the same GA date, but that we should revisit the topic
> sometime around the new RC2 date.

I leave this to the judgement of the RMs. I have no opinion myself,
besides I think it's a good idea to keep the GA date.

r//Björn Larsson

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Kalle Sommer Nielsen
Re: [PHP-DEV] [RFC] Typed Properties
July 07, 2018 11:00AM
Den lør. 7. jul. 2018 kl. 10.47 skrev Björn Larsson <[email protected]>:
> I leave this to the judgement of the RMs. I have no opinion myself,
> besides I think it's a good idea to keep the GA date.

I agree, and an additional few weeks will make the release date very
close to the holidays, I think late November/early December is the way
to go about this.

--
regards,

Kalle Sommer Nielsen
kalle@php.net

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Rowan Collins
Re: [PHP-DEV] [RFC] Typed Properties
July 07, 2018 07:10PM
On 06/07/2018 21:57, Nicolas Grekas wrote:
>
>> if ((new ReflectionReference($array[$key]))->getRefcount() > 2) {
> I just realized that this interface would suffer from a significant
> drawback: it would trigger COW when iterating over immutable arrays,
> defeating the shared-memory optimization provided by OPcache.

Any implementation of this that acts like a normal function /
constructor call is going to suffer from the same problems as
debug_zval_dump: passing a variable from one scope to another will
change the properties of that variable. If you accept the variable by
reference, you'll duplicate the data if it's part of a COW set (which
has nothing to do with OpCache by the way, it's been a core part of the
engine since at least 5.0); if you accept it by value, you'll duplicate
the data if it's part of a reference set. Either way, you're going to
change the refcount on the zval, hence the awkward 2 in Bob's example.

Previous discussions of that function concluded that the only "correct"
way to implement this would be as a language feature rather than a true
function - if the compiler issues a specific OpCode, it can pull the
zval straight out of the symbol table, without interfering with it.

Maybe the two concepts could be combined, and the language feature
generate a Reflection object? e.g.

$reflection = reflect_variable($var);
if ( $reflection->isReference() ) {
    $types = $reflection->getReferencedTypes();
}



> An interface like new ReflectionReference($array, $key) would be free from
> the issue. Combined with get_defined_vars() and the (array) operator for
> objects, we can inspect any PHP data structure or scope also this way.

Yuck. Even if this solves the issue of supporting both ref and non-ref
variables, you still end up having to compensate for the wrong refcount,
and the resultant code would be ugly as sin.

Regards,

--
Rowan Collins
[IMSoP]


--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Zeev Suraski
RE: [PHP-DEV] [RFC] Typed Properties
July 07, 2018 11:20PM
> -----Original Message-----
> From: php@golemon.com [mailto:[email protected]] On Behalf Of Sara
> Golemon
> Sent: Friday, July 6, 2018 10:36 PM
> To: Christoph M. Becker <[email protected]>
> Cc: Nikita Popov <[email protected]>; stas@php.net; Björn Larsson
> <[email protected]>; Dan Ackroyd <[email protected]asereality.com>;
> Stanislav Malyshev <[email protected]>; Marco Pivetta
> <[email protected]>; PHP internals <[email protected]>
> Subject: Re: [PHP-DEV] [RFC] Typed Properties
>
> Just want to be annoying about this since the currently scheduled fork date for
> PHP-7.3 is 11 days off.
> 1/ Do we have *ANY* objections to additional alpha(s) to accommodate Typed
> Props? (I would propose two additional alphas) 2/ Do we actually need to hold a
> formal vote? (If so, that vote should start *now*)

Sara,

I do see a couple of issues here.

First, it may be a personal thing, but I feel that the flexibility towards adding this is very contrasty with the inflexibility shown as we headed towards the PHP 7.0 feature freeze - inflexibility that resulted in a rushed (and IMHO wrong) decision regarding how to implement the non-strict types. For the record - as I said back then - I think that the right way is to be flexible - the dates are just dates, and are - in all honesty - not that important - it’s the severe inconsistency that bothers me.

Secondly, and somewhat related - typed properties isn't a small feature. It is, in fact, a pretty huge one. Making exceptions for a fairly minor feature or some extra deprecation is one thing. Making an exception for something as fundamental as that feels wrong.

Even though Nikita's proposal and implementation look pretty solid, something as fundamental as that should go through a substantial active discussion period (which didn't really happen here as it wasn't clear whether this was headed for an exceptional 7.3 addition or not) - and independently - should perhaps go hand-in-hand with fixing the flaws of the non-strict types - something we can do in PHP 8. If we do the latter, then perhaps, just perhaps, we can introduce it hand-in-hand with typed variables - and if we do, it will be sensible to do it at the same time and not in a gradual rollout. Personally, I think even independently of typed variables, typed properties feel like an 8.0 feature, not a 7.x feature.

Zeev
Sara Golemon
Re: [PHP-DEV] [RFC] Typed Properties
July 08, 2018 01:40AM
On Fri, Jul 6, 2018 at 4:46 PM, Christoph M. Becker <[email protected]> wrote:
> Why should we have 2 additional alphas? In my opinion, a single
> additional alpha is sufficient, and it is really important not to add
> yet further features.
>
Because in the best case scenario (with a single extra alpha), the RFC
is ready now, and the vote for it opens immediately. After two weeks,
we get a yes vote and we'll be right on the edge of ready for
FF/beta1. Adding that fifth alpha gives us breathing room for
something short of idealized circumstances.

On Sat, Jul 7, 2018 at 5:12 PM, Zeev Suraski <[email protected]> wrote:
> First, it may be a personal thing, but I feel that the flexibility towards adding
> this is very contrasty with the inflexibility shown as we headed towards the
> PHP 7.0 feature freeze - inflexibility that resulted in a rushed (and IMHO wrong)
> decision regarding how to implement the non-strict types.
>
Actually, I think Typed Props are being rushed as well, and I'm not
pleased with it, but I can also see the writing on the wall and want
to minimize the impact of that hurry (hence, pushing the timeline out
rather than having things land weeks into the beta cycle).

> For the record - as I said back then - I think that the right way is to be flexible -
> the dates are just dates, and are - in all honesty - not that important - it’s the severe
> inconsistency that bothers me.
>
I agree that dates are just dates, but blithely eroding the
pre-release cycle without pushing the GA date out isn't saying "dates
are dates", it's saying "RC testing doesn't matter". I just want 7.3
to get as much baking in time as earlier releases got.

> Secondly, and somewhat related - typed properties isn't a small feature.
> It is, in fact, a pretty huge one. Making exceptions for a fairly minor feature
> or some extra deprecation is one thing. Making an exception for something
> as fundamental as that feels wrong.
>
Agreed, and why I haven't decided on a "yes" vote. Again, I'm not
pushing for this feature, I'm pushing for our pre-release cycle
suffering as little damage as I can manage to protect it from.

> Even though Nikita's proposal and implementation look pretty solid,
> something as fundamental as that should go through a substantial
> active discussion period (which didn't really happen here as it wasn't
> clear whether this was headed for an exceptional 7.3 addition or not) -
>
I'm working on the assumption that Niki still plans to bring this to
vote. Perhaps he's decide it needs to wait and this whole discussion
of extra alphas is moot. That's why I sent an email about the
subject.

> and independently - should perhaps go hand-in-hand with fixing the
> flaws of the non-strict types - something we can do in PHP 8.
> If we do the latter, then perhaps, just perhaps, we can introduce it
> hand-in-hand with typed variables - and if we do, it will be sensible
> to do it at the same time and not in a gradual rollout.
>
And that's a decision we need to make, NOW. We need to know in the
next 10 days if we're going to move forward with a 7.3 that doesn't
contain TP, or if we're going to push out the betas until we can
solidify it. Waiting to make that decision is making a decision by
default (almost as bad as making the wrong decision).

> Personally, I think even independently of typed variables, typed properties feel like an 8.0 feature, not a 7.x feature.
>
I probably agree with you on that. (Again, still undecided).

-Sara

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Lester Caine
Re: [PHP-DEV] [RFC] Typed Properties
July 08, 2018 10:30AM
On 08/07/18 00:35, Sara Golemon wrote:
>> Personally, I think even independently of typed variables, typed properties feel like an 8.0 feature, not a 7.x feature.
>>
> I probably agree with you on that. (Again, still undecided).

The debate seems to assume that Typed Properties ARE a done deal even
without a vote? Personally I just feel all this is still going in the
wrong direction and trying to work out where to go next is still
detracting from getting new work done. In practice if I need 'typed'
anything, I need types that actually return an advantage, and
unrestricted 'int' and the like is NOT providing that!

--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk
Rainbow Digital Media - http://rainbowdigitalmedia.co.uk

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Marco Pivetta
Re: [PHP-DEV] [RFC] Typed Properties
July 08, 2018 10:30AM
Hi Lester,

Typed properties combined with value objects (quite widespread technique)
provide a decent level of safety at this point in time.

So far, there haven't been many nay-sayers to the patch: it's OK to vote
"no" if you don't understand or don't want the feature.

Greets,

Marco

On Sun, 8 Jul 2018, 10:19 Lester Caine, <[email protected]> wrote:

> On 08/07/18 00:35, Sara Golemon wrote:
> >> Personally, I think even independently of typed variables, typed
> properties feel like an 8.0 feature, not a 7.x feature.
> >>
> > I probably agree with you on that. (Again, still undecided).
>
> The debate seems to assume that Typed Properties ARE a done deal even
> without a vote? Personally I just feel all this is still going in the
> wrong direction and trying to work out where to go next is still
> detracting from getting new work done. In practice if I need 'typed'
> anything, I need types that actually return an advantage, and
> unrestricted 'int' and the like is NOT providing that!
>
> --
> Lester Caine - G8HFL
> -----------------------------
> Contact - http://lsces.co.uk/wiki/?page=contact
> L.S.Caine Electronic Services - http://lsces.co.uk
> EnquirySolve - http://enquirysolve.com/
> Model Engineers Digital Workshop - http://medw.co.uk
> Rainbow Digital Media - http://rainbowdigitalmedia.co.uk
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
Christoph M. Becker
Re: [PHP-DEV] [RFC] Typed Properties
July 08, 2018 06:30PM
On 08.07.2018 at 01:35, Sara Golemon wrote:

> On Fri, Jul 6, 2018 at 4:46 PM, Christoph M. Becker <[email protected]> wrote:
>
>> Why should we have 2 additional alphas? In my opinion, a single
>> additional alpha is sufficient, and it is really important not to add
>> yet further features.
>
> Because in the best case scenario (with a single extra alpha), the RFC
> is ready now, and the vote for it opens immediately. After two weeks,
> we get a yes vote and we'll be right on the edge of ready for
> FF/beta1. Adding that fifth alpha gives us breathing room for
> something short of idealized circumstances.

I see!

> On Sat, Jul 7, 2018 at 5:12 PM, Zeev Suraski <[email protected]> wrote:
>
>> and independently - should perhaps go hand-in-hand with fixing the
>> flaws of the non-strict types - something we can do in PHP 8.
>> If we do the latter, then perhaps, just perhaps, we can introduce it
>> hand-in-hand with typed variables - and if we do, it will be sensible
>> to do it at the same time and not in a gradual rollout.
>
> And that's a decision we need to make, NOW. We need to know in the
> next 10 days if we're going to move forward with a 7.3 that doesn't
> contain TP, or if we're going to push out the betas until we can
> solidify it. Waiting to make that decision is making a decision by
> default (almost as bad as making the wrong decision).

ACK! How should we make this decision? A vote in the Wiki? The full
RFC process is no option anymore.

--
Christoph M. Becker

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Björn Larsson
Re: [PHP-DEV] [RFC] Typed Properties
July 09, 2018 12:40PM
Den 2018-07-07 kl. 23:12, skrev Zeev Suraski:
>> -----Original Message-----
>> From:[email protected] [mailto:[email protected]] On Behalf Of Sara
>> Golemon
>> Sent: Friday, July 6, 2018 10:36 PM
>> To: Christoph M. Becker<[email protected]>
>> Cc: Nikita Popov<[email protected]>;[email protected]; Björn Larsson
>> <[email protected]>; Dan Ackroyd<[email protected]>;
>> Stanislav Malyshev<[email protected]>; Marco Pivetta
>> <[email protected]>; PHP internals<[email protected]>
>> Subject: Re: [PHP-DEV] [RFC] Typed Properties
>>
>> Just want to be annoying about this since the currently scheduled fork date for
>> PHP-7.3 is 11 days off.
>> 1/ Do we have *ANY* objections to additional alpha(s) to accommodate Typed
>> Props? (I would propose two additional alphas) 2/ Do we actually need to hold a
>> formal vote? (If so, that vote should start *now*)
> Sara,
>
> I do see a couple of issues here.
>
> First, it may be a personal thing, but I feel that the flexibility towards adding this is very contrasty with the inflexibility shown as we headed towards the PHP 7.0 feature freeze - inflexibility that resulted in a rushed (and IMHO wrong) decision regarding how to implement the non-strict types. For the record - as I said back then - I think that the right way is to be flexible - the dates are just dates, and are - in all honesty - not that important - it’s the severe inconsistency that bothers me.
>
> Secondly, and somewhat related - typed properties isn't a small feature. It is, in fact, a pretty huge one. Making exceptions for a fairly minor feature or some extra deprecation is one thing. Making an exception for something as fundamental as that feels wrong.
>
> Even though Nikita's proposal and implementation look pretty solid, something as fundamental as that should go through a substantial active discussion period (which didn't really happen here as it wasn't clear whether this was headed for an exceptional 7.3 addition or not) - and independently - should perhaps go hand-in-hand with fixing the flaws of the non-strict types - something we can do in PHP 8. If we do the latter, then perhaps, just perhaps, we can introduce it hand-in-hand with typed variables - and if we do, it will be sensible to do it at the same time and not in a gradual rollout. Personally, I think even independently of typed variables, typed properties feel like an 8.0 feature, not a 7.x feature.
>
> Zeev
>
>
You do have a point here about combining this with 8.0. I think it
then would be great if an RFC like the one for 7.0 shows up soon.
- https://wiki.php.net/rfc/php7timeline

If 8.0 drags on I think it's beneficial to have this feature earlier, like
now ;-)

I was a bit surprised myself that the discussion has not been so active.
On the other hand typed properties was up for discussion earlier and
much of the disadvantages has now been remedied in this proposal.
Given the high quality of this RFC and earlier discussions I personally
felt it was not so much to ponder about.

I can see some advantages with having this feature in a 7.x release:
- It leaves more space for doing other stuff in 8.0 given that core
  resources are scarce.
- It adds a lot of value to 7.3, which is not packed with features.

r//Björn Larsson
André Rømcke
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 07:30AM
On 7 Jul 2018, at 23:13, Zeev Suraski <[email protected]> wrote:

>> -----Original Message-----
>> From: php@golemon.com [mailto:[email protected]] On Behalf Of Sara
>> Golemon
>> Sent: Friday, July 6, 2018 10:36 PM
>> To: Christoph M. Becker <[email protected]>
>> Cc: Nikita Popov <[email protected]>; stas@php.net; Björn Larsson
>> <[email protected]>; Dan Ackroyd <[email protected]>;
>> Stanislav Malyshev <[email protected]>; Marco Pivetta
>> <[email protected]>; PHP internals <[email protected]>
>> Subject: Re: [PHP-DEV] [RFC] Typed Properties
>>
>> Just want to be annoying about this since the currently scheduled fork date for
>> PHP-7.3 is 11 days off.
>> 1/ Do we have *ANY* objections to additional alpha(s) to accommodate Typed
>> Props? (I would propose two additional alphas) 2/ Do we actually need to hold a
>> formal vote? (If so, that vote should start *now*)
>
> Sara,
>
> I do see a couple of issues here.
>
> First, it may be a personal thing, but I feel that the flexibility towards adding this is very contrasty with the inflexibility shown as we headed towards the PHP 7.0 feature freeze - inflexibility that resulted in a rushed (and IMHO wrong) decision regarding how to implement the non-strict types. For the record - as I said back then - I think that the right way is to be flexible - the dates are just dates, and are - in all honesty - not that important - it’s the severe inconsistency that bothers me.


Regardless of typed properties this sounds like something that should be tackled as an independent topic. (It could in theory, if accepted, be a new type flag introduced in 7.4 and made default in 8.0 that affect all type usage consistently.)


>
> Secondly, and somewhat related - typed properties isn't a small feature. It is, in fact, a pretty huge one. Making exceptions for a fairly minor feature or some extra deprecation is one thing. Making an exception for something as fundamental as that feels wrong.
>
> Even though Nikita's proposal and implementation look pretty solid, something as fundamental as that should go through a substantial active discussion period (which didn't really happen here as it wasn't clear whether this was headed for an exceptional 7.3 addition or not) - and independently - should perhaps go hand-in-hand with fixing the flaws of the non-strict types - something we can do in PHP 8. If we do the latter, then perhaps, just perhaps, we can introduce it hand-in-hand with typed variables - and if we do, it will be sensible to do it at the same time and not in a gradual rollout. Personally, I think even independently of typed variables, typed properties feel like an 8.0 feature, not a 7.x feature.


While I agree this is big, (from user land it’s fantastic), and should only go in if solid. It does contradict your argument the other day about being careful what to push into 8.0 scope as core resources are scarce.

So if we look at it from that perspective, then spreading the risk is essentially safer.
Marco Pivetta
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 11:30AM
It's been a few weeks since this has first landed here, and we're just
wasting time in relatively silly discussions at this point:

- As I said earlier, this patch has already been tested against some
extremely tricky scenarios, so from a userland perspective it is safe for
inclusion. If you don't have confidence in something related to it, please
write a test case and help out.
- can we get a yes/no from the RMs on whether we'll have the time window
to (potentially) get this voted and (*if* passed) merged? Shoot out a mail
with the decision, please. We could have a vote for which version to
include this in, if that's really such a big issue.
- can we split out discussions on 8.0 scope? Minor versions are indeed for
features. If PHP 8.0 lacks interesting/marketing features, that's a
different story.
- Nikita/Bob: can this be voted upon right after the RMs have taken a
decision? Anything blocking missing?
- Is the reference issue reported by Nicolas a blocker? Nicolas, can you
clarify here?




Marco Pivetta

http://twitter.com/Ocramius

http://ocramius.github.com/

On Tue, Jul 10, 2018 at 7:24 AM, André Rømcke <[email protected]> wrote:

> On 7 Jul 2018, at 23:13, Zeev Suraski <[email protected]> wrote:
>
> >> -----Original Message-----
> >> From: php@golemon.com [mailto:[email protected]] On Behalf Of Sara
> >> Golemon
> >> Sent: Friday, July 6, 2018 10:36 PM
> >> To: Christoph M. Becker <[email protected]>
> >> Cc: Nikita Popov <[email protected]>; stas@php.net; Björn Larsson
> >> <[email protected]>; Dan Ackroyd <[email protected]>;
> >> Stanislav Malyshev <[email protected]>; Marco Pivetta
> >> <[email protected]>; PHP internals <[email protected]>
> >> Subject: Re: [PHP-DEV] [RFC] Typed Properties
> >>
> >> Just want to be annoying about this since the currently scheduled fork
> date for
> >> PHP-7.3 is 11 days off.
> >> 1/ Do we have *ANY* objections to additional alpha(s) to accommodate
> Typed
> >> Props? (I would propose two additional alphas) 2/ Do we actually need
> to hold a
> >> formal vote? (If so, that vote should start *now*)
> >
> > Sara,
> >
> > I do see a couple of issues here.
> >
> > First, it may be a personal thing, but I feel that the flexibility
> towards adding this is very contrasty with the inflexibility shown as we
> headed towards the PHP 7.0 feature freeze - inflexibility that resulted in
> a rushed (and IMHO wrong) decision regarding how to implement the
> non-strict types. For the record - as I said back then - I think that the
> right way is to be flexible - the dates are just dates, and are - in all
> honesty - not that important - it’s the severe inconsistency that bothers
> me.
>
>
> Regardless of typed properties this sounds like something that should be
> tackled as an independent topic. (It could in theory, if accepted, be a new
> type flag introduced in 7.4 and made default in 8.0 that affect all type
> usage consistently.)
>
>
> >
> > Secondly, and somewhat related - typed properties isn't a small
> feature. It is, in fact, a pretty huge one. Making exceptions for a
> fairly minor feature or some extra deprecation is one thing. Making an
> exception for something as fundamental as that feels wrong.
> >
> > Even though Nikita's proposal and implementation look pretty solid,
> something as fundamental as that should go through a substantial active
> discussion period (which didn't really happen here as it wasn't clear
> whether this was headed for an exceptional 7.3 addition or not) - and
> independently - should perhaps go hand-in-hand with fixing the flaws of the
> non-strict types - something we can do in PHP 8. If we do the latter, then
> perhaps, just perhaps, we can introduce it hand-in-hand with typed
> variables - and if we do, it will be sensible to do it at the same time and
> not in a gradual rollout. Personally, I think even independently of typed
> variables, typed properties feel like an 8.0 feature, not a 7.x feature.
>
>
> While I agree this is big, (from user land it’s fantastic), and should
> only go in if solid. It does contradict your argument the other day about
> being careful what to push into 8.0 scope as core resources are scarce.
>
> So if we look at it from that perspective, then spreading the risk is
> essentially safer.
>
>
Nicolas Grekas
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 12:30PM
2018-07-10 11:18 GMT+02:00 Marco Pivetta <[email protected]>:

> It's been a few weeks since this has first landed here, and we're just
> wasting time in relatively silly discussions at this point:
>
> - As I said earlier, this patch has already been tested against some
> extremely tricky scenarios, so from a userland perspective it is safe for
> inclusion. If you don't have confidence in something related to it, please
> write a test case and help out.
> - can we get a yes/no from the RMs on whether we'll have the time window
> to (potentially) get this voted and (*if* passed) merged? Shoot out a mail
> with the decision, please. We could have a vote for which version to
> include this in, if that's really such a big issue.
> - can we split out discussions on 8.0 scope? Minor versions are indeed for
> features. If PHP 8.0 lacks interesting/marketing features, that's a
> different story.
> - Nikita/Bob: can this be voted upon right after the RMs have taken a
> decision? Anything blocking missing?
> - Is the reference issue reported by Nicolas a blocker? Nicolas, can you
> clarify here?
>

I'm definitely ith you on this one Marco, typed properties is something
userland asks since a long time and postponing it to 8.0 for "marketing"
reasons might be very frustrating (well, we'll deal with that if it happens
:) )

But technically, it feels almost ready.

The reference issue looks "easy" to fix(esp. when its not me doing it yes
;) ). It'd be better to have it at the same time, but I can wait the next
version as I don't want to be the one with a blocker here, and also because
I can write a "degraded mode" for now if that's the plan.

Nicolas
Marco Pivetta
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 12:30PM
On Tue, Jul 10, 2018 at 12:21 PM, Nicolas Grekas <
[email protected]> wrote:

> I'm definitely ith you on this one Marco, typed properties is something
> userland asks since a long time and postponing it to 8.0 for "marketing"
> reasons might be very frustrating (well, we'll deal with that if it happens
> :) )
>
> But technically, it feels almost ready.
>
> The reference issue looks "easy" to fix(esp. when its not me doing it yes
> ;) ). It'd be better to have it at the same time, but I can wait the next
> version as I don't want to be the one with a blocker here, and also because
> I can write a "degraded mode" for now if that's the plan.
>

The important bit is to not have functionality that blocks userland
scenarios that previously worked.
If the try-catch works, then we can surely roll with it.

Marco Pivetta

http://twitter.com/Ocramius

http://ocramius.github.com/
Nikita Popov
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 12:30PM
On Tue, Jul 10, 2018 at 11:18 AM, Marco Pivetta <[email protected]> wrote:

> It's been a few weeks since this has first landed here, and we're just
> wasting time in relatively silly discussions at this point:
>
> - As I said earlier, this patch has already been tested against some
> extremely tricky scenarios, so from a userland perspective it is safe for
> inclusion. If you don't have confidence in something related to it, please
> write a test case and help out.
>

Thanks a lot for your tests and feedback!


> - can we get a yes/no from the RMs on whether we'll have the time window
> to (potentially) get this voted and (*if* passed) merged? Shoot out a mail
> with the decision, please. We could have a vote for which version to
> include this in, if that's really such a big issue.
> - can we split out discussions on 8.0 scope? Minor versions are indeed for
> features. If PHP 8.0 lacks interesting/marketing features, that's a
> different story.
> - Nikita/Bob: can this be voted upon right after the RMs have taken a
> decision? Anything blocking missing?
>

I've just updated the RFC with the last major change (switch to the "no
intrinsic types" alternative for reference handling). Apart from some minor
tweaks (maybe add a bit more information on how the implementation works)
the RFC itself should be about ready for voting.

Even if the RMs decide that this cannot go into PHP 7.3, we'd still like to
start voting on this RFC soon (in the next few days).

- Is the reference issue reported by Nicolas a blocker? Nicolas, can you
> clarify here?
>

My plan for the reference reflection would be to write a separate RFC.
While typed properties make this more important, the feature itself is
really independent, and while we could slip it through as part of this RFC,
I think that this problem has a large enough design space that we should
discuss it separately.

Nikita
Zeev Suraski
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 12:40PM
On Tue, Jul 10, 2018 at 1:22 PM Nicolas Grekas <[email protected]>
wrote:

> 2018-07-10 11:18 GMT+02:00 Marco Pivetta <[email protected]>:
>
> > It's been a few weeks since this has first landed here, and we're just
> > wasting time in relatively silly discussions at this point:
> >
> > - As I said earlier, this patch has already been tested against some
> > extremely tricky scenarios, so from a userland perspective it is safe for
> > inclusion. If you don't have confidence in something related to it,
> please
> > write a test case and help out.
> > - can we get a yes/no from the RMs on whether we'll have the time window
> > to (potentially) get this voted and (*if* passed) merged? Shoot out a
> mail
> > with the decision, please. We could have a vote for which version to
> > include this in, if that's really such a big issue.
> > - can we split out discussions on 8.0 scope? Minor versions are indeed
> for
> > features. If PHP 8.0 lacks interesting/marketing features, that's a
> > different story.
> > - Nikita/Bob: can this be voted upon right after the RMs have taken a
> > decision? Anything blocking missing?
> > - Is the reference issue reported by Nicolas a blocker? Nicolas, can you
> > clarify here?
> >
>
> I'm definitely ith you on this one Marco, typed properties is something
> userland asks since a long time and postponing it to 8.0 for "marketing"
> reasons might be very frustrating (well, we'll deal with that if it happens
> :) )
>
>
For the sake of those who weren't reading the discussion on the other
thread - the reason I believe it shouldn't go into 7.3 as well as the
reasons why I think this should be discussed for 8.0 are hardly just
'marketing' reasons, although I absolutely do think that decisions like
this (which version a certain feature goes into) is not exclusively or even
primarily a technical decision.

The reasons I stated were:
"the little time we have left, the little concrete discussion that happened
so far as a result, the inconsistency of allowing such a vote to push out
feature freeze, the scope of this feature being a lot more suitable for a
major release, and our inability to fix/improve other related elements at
the same time"

I've also given several examples - some of them arguably quite bigger than
this proposal - where we sat on code for a very long time (multiple years
even) in order for it to be included in a major version, and not a minor
one (phpng, JIT, FFI) even though technically they could go into the next
available minor.

Zeev
Pedro Magalhães
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 01:10PM
On Tue, Jul 10, 2018 at 11:33 AM Zeev Suraski <[email protected]> wrote:

> I've also given several examples - some of them arguably quite bigger than
> this proposal - where we sat on code for a very long time (multiple years
> even) in order for it to be included in a major version, and not a minor
> one (phpng, JIT, FFI) even though technically they could go into the next
> available minor.
>

Hi,

I'm trying to understand this argument better but there is something I'm
missing. Why would a feature like JIT (which would be transparent to the
user AFAIK) need to wait for a major other than marketing reasons?
Sorry in advance for the slightly off-topic question.

Regards,
Pedro
Zeev Suraski
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 02:00PM
On Tue, Jul 10, 2018 at 2:06 PM Pedro Magalhães <[email protected]> wrote:

> On Tue, Jul 10, 2018 at 11:33 AM Zeev Suraski <[email protected]> wrote:
>
>> I've also given several examples - some of them arguably quite bigger than
>> this proposal - where we sat on code for a very long time (multiple years
>> even) in order for it to be included in a major version, and not a minor
>> one (phpng, JIT, FFI) even though technically they could go into the next
>> available minor.
>>
>
> Hi,
>
> I'm trying to understand this argument better but there is something I'm
> missing. Why would a feature like JIT (which would be transparent to the
> user AFAIK) need to wait for a major other than marketing reasons?
> Sorry in advance for the slightly off-topic question.
>

Major versions are in many respects "marketing" events. They're an
indicator that big changes have happened in the language, big enough to
warrant a change in the major version.
It's a relatively recent evolution that we decided to only make it possible
to break compatibility in major versions (and it's a very positive
evolution, without a doubt), but either way - compatibility breakage has
never been the motivating factor behind a major release. Major releases
enable compatibility breakage, not the other way around.
Major features have always gone into major releases (with one notable
exception - PHP 5.3, which many argue was a de-facto major release).

While 'marketing' always played a role in designating a certain version as
major - getting people more motivated to upgrade, bring positive vibes and
attention around the language, etc. (as was the case with 7.0) - since the
formal release process and the policy change to only allow compatibility
breakage in major versions - these compatibility breakages actually, to a
large degree, 'piggyback' on the major new features. To make it more real
- what would the migration to PHP 7 look like if it was all about the
compatibility breakages, and not the performance boosts or for that matter
- scalar type hints? Both of these (performance boosts and scalar type
hints) could easily go into 5.7 from a purely technical perspective.

Zeev
Nicolas Grekas
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 02:30PM
Le mar. 10 juil. 2018 à 14:56, Zeev Suraski <[email protected]> a écrit :

> On Tue, Jul 10, 2018 at 2:06 PM Pedro Magalhães <[email protected]> wrote:
>
>> On Tue, Jul 10, 2018 at 11:33 AM Zeev Suraski <[email protected]> wrote:
>>
>>> I've also given several examples - some of them arguably quite bigger
>>> than
>>> this proposal - where we sat on code for a very long time (multiple years
>>> even) in order for it to be included in a major version, and not a minor
>>> one (phpng, JIT, FFI) even though technically they could go into the next
>>> available minor.
>>>
>>
>> Hi,
>>
>> I'm trying to understand this argument better but there is something I'm
>> missing. Why would a feature like JIT (which would be transparent to the
>> user AFAIK) need to wait for a major other than marketing reasons?
>> Sorry in advance for the slightly off-topic question.
>>
>
> Major versions are in many respects "marketing" events. They're an
> indicator that big changes have happened in the language, big enough to
> warrant a change in the major version.
> It's a relatively recent evolution that we decided to only make it
> possible to break compatibility in major versions (and it's a very positive
> evolution, without a doubt), but either way - compatibility breakage has
> never been the motivating factor behind a major release. Major releases
> enable compatibility breakage, not the other way around.
> Major features have always gone into major releases (with one notable
> exception - PHP 5.3, which many argue was a de-facto major release).
>
> While 'marketing' always played a role in designating a certain version as
> major - getting people more motivated to upgrade, bring positive vibes and
> attention around the language, etc. (as was the case with 7.0) - since the
> formal release process and the policy change to only allow compatibility
> breakage in major versions - these compatibility breakages actually, to a
> large degree, 'piggyback' on the major new features. To make it more real
> - what would the migration to PHP 7 look like if it was all about the
> compatibility breakages, and not the performance boosts or for that matter
> - scalar type hints? Both of these (performance boosts and scalar type
> hints) could easily go into 5.7 from a purely technical perspective.
>
> Zeev
>


Just to clarify my previous statement: marketing is a good reason to bump a
major version. Doing so creates momentum after the release and motivation
before.

I just don't agree that typed properties are part of that. They are a
really natural and important feature, but not one that will allow anyone to
do anything new that wasn't possible before.
JIT and/or async are game changers. They don't play in the same category to
me.
Others might disagree of course, and I don't want to minimize their
importance nor the work of Nikita and Bob. Kudos to them actually.

Nicolas

>
Larry Garfield
Re: [PHP-DEV] [RFC] Typed Properties
July 10, 2018 09:20PM
On Tuesday, July 10, 2018 6:56:24 AM CDT Zeev Suraski wrote:
> On Tue, Jul 10, 2018 at 2:06 PM Pedro Magalhães <[email protected]> wrote:
> > On Tue, Jul 10, 2018 at 11:33 AM Zeev Suraski <[email protected]> wrote:
> >> I've also given several examples - some of them arguably quite bigger
> >> than
> >> this proposal - where we sat on code for a very long time (multiple years
> >> even) in order for it to be included in a major version, and not a minor
> >> one (phpng, JIT, FFI) even though technically they could go into the next
> >> available minor.
> >
> > Hi,
> >
> > I'm trying to understand this argument better but there is something I'm
> > missing. Why would a feature like JIT (which would be transparent to the
> > user AFAIK) need to wait for a major other than marketing reasons?
> > Sorry in advance for the slightly off-topic question.
>
> Major versions are in many respects "marketing" events. They're an
> indicator that big changes have happened in the language, big enough to
> warrant a change in the major version.
> It's a relatively recent evolution that we decided to only make it possible
> to break compatibility in major versions (and it's a very positive
> evolution, without a doubt), but either way - compatibility breakage has
> never been the motivating factor behind a major release. Major releases
> enable compatibility breakage, not the other way around.
> Major features have always gone into major releases (with one notable
> exception - PHP 5.3, which many argue was a de-facto major release).
>
> While 'marketing' always played a role in designating a certain version as
> major - getting people more motivated to upgrade, bring positive vibes and
> attention around the language, etc. (as was the case with 7.0) - since the
> formal release process and the policy change to only allow compatibility
> breakage in major versions - these compatibility breakages actually, to a
> large degree, 'piggyback' on the major new features. To make it more real
> - what would the migration to PHP 7 look like if it was all about the
> compatibility breakages, and not the performance boosts or for that matter
> - scalar type hints? Both of these (performance boosts and scalar type
> hints) could easily go into 5.7 from a purely technical perspective.
>
> Zeev

While the marketing angle is valid, Zeev, it seems predicated on the idea that
there won't be any other major new-and-cool features developed between now and
8.0. I'm reasonably confident that someone will find some user-facing
exciting thing to improve between now and 2020. I know some people have plans
they're already working on.

Conceptually, as Nicolas and you have both hinted at, PHP 7.x is the series
where "typing got real". From a user-facing/marketing perspective 7.x is all
about performance and typing. That's the through line. Including typed
properties in that makes logical sense, marketing-wise, and would be a fitting
capstone to the 7.x series in that regard.

That's true regardless of whether typed properties go into 7.3 or 7.4; if
given the timing they need to wait for 7.4 to have some extra polish done
that's entirely reasonable, IMO, and doesn't change the underlying point.

However, mixing "no new features in 7.4/8.0, just the engine changes" with "we
need a big showy thing in 8.0 to help sell it", er, feels like a
contradiction. It makes it sound more like "borrowing" a feature from 7.3
(typed properties) for 8.0 for purely marketing purposes, and then also
blocking any other features, so that we know 2 years out "the only interesting
thing in 8.x will be typed properties, because that was written when 8.x was
still just a twinkle in the eye but we sat on it". That feels very
disingenuous.

I am sure that's not your intent but those two statements together ("minimize
features for 8.0" and "save this feature for 8.0 for marketing") just don't
fit together in my mind in a nice way.

--Larry Garfield
Zeev Suraski
Re: [PHP-DEV] [RFC] Typed Properties
July 11, 2018 11:20AM
On Tue, Jul 10, 2018 at 10:19 PM Larry Garfield <[email protected]>
wrote:

> While the marketing angle is valid, Zeev, it seems predicated on the idea
> that
> there won't be any other major new-and-cool features developed between now
> and
> 8.0. I'm reasonably confident that someone will find some user-facing
> exciting thing to improve between now and 2020. I know some people have
> plans
> they're already working on.
>

We can agree to disagree, but effectively turning PHP into an
optionally-typed language - which Nikita's patch does a HUGE step towards
(IMHO a much bigger one than scalar type hints did at the time) is more or
less a singular event.
And no, I'm absolutely not encouraging us to come up with additional
language-changing features just for the sake of marketing - there's a world
of difference between timing the rollout schedule of what we intend to roll
out anyway, and adding extra bells and whistles just to make the new
version attractive.

Conceptually, as Nicolas and you have both hinted at, PHP 7.x is the series
> where "typing got real". From a user-facing/marketing perspective 7.x is
> all
> about performance and typing. That's the through line. Including typed
> properties in that makes logical sense, marketing-wise, and would be a
> fitting
> capstone to the 7.x series in that regard.
>

I didn't hint at that, at least not intentionally (I'd say 90-95% of the
feedback I've seen for PHP 7 was about performance, and 5-10% was pretty
much everything else, but that's beside the point).
What's on point is that new or improved capabilities are the draw into new
versions. The more (sensible!) of those you have, the better. Wasting our
'ammo' on the 7.x line at this point is, IMHO, a mistake. I guess I have
much higher levels of self control and patience - as this is precisely what
we're not going to do with the stuff we've been working on (JIT, FFI, and
phpng in the past).


> However, mixing "no new features in 7.4/8.0, just the engine changes" with
> "we
>
need a big showy thing in 8.0 to help sell it", er, feels like a
> contradiction.


Maybe it feels that way, but it really isn't. I'm not sure whether you've
had the luxury of contributing to the PHP engine, but working on two
simultaneous active branches with substantial data structure differences is
an unholy mess (it's also way, way worse than working on two branches of an
average PHP project). Even if all of the developers are focused on PHP 8
it's going to be a remarkably difficult feat to achieve. Throwing in
another parallel version that we'll need to work on at the same time is
shooting ourselves in the foot.

It makes it sound more like "borrowing" a feature from 7.3
> (typed properties) for 8.0 for purely marketing purposes, and then also
> blocking any other features, so that we know 2 years out "the only
> interesting
> thing in 8.x will be typed properties, because that was written when 8.x
> was
> still just a twinkle in the eye but we sat on it". That feels very
> disingenuous.
>

Please don't put words in my mouth and then call them disingenuous :)
I did not say we should 'block any other features'. In fact, in my
blueprint for PHP 8 - I said it's clear to me we're likely to see
additional ideas that will be proposed for PHP 8. It's an extra feature
release that will divide our resources that I'm arguing against.

My logic is quite simple:
1. Something as big as Typed Properties shouldn't be a last minute, rushed
RFC. Really - any RFC shouldn't - but in particular major language changes.
2. We should not have a 7.4 that divides our resources(*); Much like with
5.6 -> 7.0, we should focus on one feature version at a time.
3. We're better off saving Typed Properties for 8.0 as another draw - and
we can also make it better by that timeline (a comprehensive typing
solution, and not an incremental one).

I am sure that's not your intent but those two statements together
> ("minimize
> features for 8.0" and "save this feature for 8.0 for marketing") just
> don't
> fit together in my mind in a nice way.
>

Where did I say we should minimize features for 8.0?

Zeev
Christoph M. Becker
Re: [PHP-DEV] [RFC] Typed Properties
July 11, 2018 03:40PM
On 10.07.2018 at 12:26, Nikita Popov wrote:

> I've just updated the RFC with the last major change (switch to the "no
> intrinsic types" alternative for reference handling). Apart from some minor
> tweaks (maybe add a bit more information on how the implementation works)
> the RFC itself should be about ready for voting.
>
> Even if the RMs decide that this cannot go into PHP 7.3, we'd still like to
> start voting on this RFC soon (in the next few days).

After consulting with other release managers, I would ask you not to
target PHP 7.3, because we're already in alpha stage, the changes for
feature are quite comprehensive, and affect extensions in a subtle way[1]:

| The other are changes to reference assignments. These are not
| necessary to build against PHP 7.3, but are needed to ensure the
| behavior is fully correct.

[1] <https://wiki.php.net/rfc/typed_properties_v2#impact_on_extensions>;

--
Christoph M. Becker

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Levi Morrison
Re: [PHP-DEV] [RFC] Typed Properties
July 11, 2018 03:50PM
> My logic is quite simple:
> 1. Something as big as Typed Properties shouldn't be a last minute, rushed
> RFC. Really - any RFC shouldn't - but in particular major language changes.

I have seen this sentiment expressed elsewhere. I want to personally
affirm that Nikita and Bob have been working hard on this for a long
time. This is not a last minute change being rushed. They have been
quite thorough and have discovered and fixed many edge cases that I
suspect other authors would not have found or would have ignored. Yes,
it is being voted on in the narrow gap between first alphas and
feature freeze but that does not mean it is rushed.

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php
Marco Pivetta
Re: [PHP-DEV] [RFC] Typed Properties
July 11, 2018 04:00PM
On Wed, Jul 11, 2018 at 3:44 PM, Levi Morrison <[email protected]> wrote:

> > My logic is quite simple:
> > 1. Something as big as Typed Properties shouldn't be a last minute,
> rushed
> > RFC. Really - any RFC shouldn't - but in particular major language
> changes.
>
> I have seen this sentiment expressed elsewhere. I want to personally
> affirm that Nikita and Bob have been working hard on this for a long
> time. This is not a last minute change being rushed. They have been
> quite thorough and have discovered and fixed many edge cases that I
> suspect other authors would not have found or would have ignored. Yes,
> it is being voted on in the narrow gap between first alphas and
> feature freeze but that does not mean it is rushed.


Ack, and it is such a massive improvement that pushing it back now would
simply delay a very huge jump (forward) in ecosystem quality at large for
more than a year.

Bob and Nikita got it right, they made something well thought out, well
tested, and previously already discussed: give the vote a chance, add a
sub-vote for which version to target, if required.

Marco Pivetta

http://twitter.com/Ocramius

http://ocramius.github.com/
Sorry, only registered users may post in this forum.

Click here to login