Re: [VOTE] Scalar Type Hints

From: Date: Thu, 05 Feb 2015 23:57:51 +0000
Subject: Re: [VOTE] Scalar Type Hints
References: 1 2 3  Groups: php.internals 
Request: Send a blank email to [email protected] to get a copy of this message
The folks who really want all this great strict typing should head over to
Oracle.com and download free open-source Java? I hear it's got a lot of
strict typing features in it. Only downside is that it'll take them 10x
longer to complete their projects. OK sorry. Had to say that :) I realize
it's not the same...

Andrea, while I don't agree with what you say I accept it. *But* exactly
for the reasons you state (the big divide) we should also have a weak type
hinting option to vote for in parallel. If you feel morally unable to do
that then I can copy your work and just have another RFC running in
parallel but I think that would do a disservice to the good work you've
done.

Andi


On Thu, Feb 5, 2015 at 3:47 PM, Andrea Faulds <[email protected]> wrote:

> Hi Andi,
>
> > On 5 Feb 2015, at 23:22, Andi Gutmans <[email protected]> wrote:
> >
> > I have to say I’m pretty disappointed at the opening of the vote.
> > We had a pretty good RFC (thank you) for weak type hinting which was
> aligned with the spirit of PHP and everyone was able to rally around it.
>
> This is far from true. Some people on internals were happy, but only some,
> and everywhere outside internals I looked, the reception was far more
> negative.
>
> > This has now been morphed into something very hard to swallow and IMO
> having such a declare(…) syntax will be ridiculed by the broader app dev
> community until the end of time…
>
> Nobody mocks Perl or JS for use strict.
>
> > But even that syntax aside (it’s only syntax after all), I think we lost
> the ability to reach consensus on something so important to everyone which
> we haven’t been able to come to agreement on for over 10 years. Finally it
> was there, in reach and you made a 180 degree turn.
>
> “Consensus” is exaggerated. There was no consensus and to claim there was
> is to ignore the reality that the PHP community is divided over this issue.
> I’d love to say that everyone loves weak type hints and if that version had
> passed we’d all be dancing around happy holding hands, but the reception
> was not uniformly positive, not even close, and that’s just on internals.
>
> > I think it’d be so much easier for us to implement weak type hinting.
> Have everyone rally around it. Be happy and then learn and see whether an
> additional mechanism is really necessary.
>
> Who’d be happy? I realise you and Zeev are big fans of weak types, as are
> many others, but there are also a lot of PHP developers who vehemently
> disagree with you.
>
> > We could even add an E_STRICT_TYPES error_reporting flag to help folks
> “debug” their code if they so wish to see if there are any hotspots in
> their code they may want to take a look at - again not necessarily an error
> but maybe a debugging tool.
>
> Global error handlers affect all code the interpreter runs, which is why
> we’ve looked down on them in recent times.
>
> > But net, net - why not just implement the thing everyone can agree on.
>
> Everyone doesn’t agree on it.
>
> If everyone did agree on it, v0.1 of the RFC would have been the one that
> went to vote.
>
> > Have something really good in the spirit of the PHP Language for PHP 7
> and learn how people leverage that… The reality is that for the majority of
> the Web community “1” coming in from HTTP should be accepted as a 1. Period.
>
> It’s very well and good you claiming that the “majority” agree, but this
> does not match my experiences. The PHP community is not a single,
> homogenous entity. It is very difficult to judge.
>
> > I voted “no” but I will vote “yes” for the competing RFC which is 80% of
> your RFC. Why are we not given that option??????
>
> Because I cannot in good conscience push through something in the name of
> “consensus” which does not even approach it.
>
> --
> Andrea Faulds
> http://ajf.me/
>
>
>
>
>


Thread (187 messages)

« previous php.internals (#81984) next »