Re: [RFC] Anonymous Classes
| From: | Florian Anderiasch | Date: | Tue, 24 Feb 2015 15:59:13 +0000 |
| Subject: | Re: [RFC] Anonymous Classes | ||
| References: | 1 2 3 4 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-83673@lists.php.net to get a copy of this message | ||
On 02/24/2015 04:31 PM, Philip Sturgeon wrote:
> On Tue, Feb 24, 2015 at 9:58 AM, Florian Anderiasch <ml@anderiasch.de> wrote:
>> On 02/24/2015 03:29 PM, Dennis Birkholz wrote:
>>> Am 24.02.2015 um 14:52 schrieb Philip Sturgeon:
>>>> https://wiki.php.net/rfc/anonymous_classes
>>>
>>> I like the idea of having anonymous classes, it is very helpful during
>>> development to just try something out without having the burden of
>>> creating a new file and a complete class including namespace and use
>>> declarations, etc.
>>
>> I don't buy this argument. If your class loader or PSR prevents you from
>> temporarily adding a 2nd bogus class to the same file (not talking about
>> best practices here, obviously) then there's the culprit and it's
>> nothing the language needs to fix.
>>
>
> Your reply seems to assume that avoiding rules in a PSR is the only
> benefit of the RFC, which is weird when there is a whole RFC full of
> benefits of this RFC.
My reply was simply re: the quoted paragraph in the mail I directly
replied to, not yours. I simply think "trying something out" is not a
valid use case of anonymous classes.
I can generally like the RFC and still refute arguments in favor of it,
right? :)
~Florian