Re: [RFC] Anonymous Classes
| From: | Florian Anderiasch | Date: | Tue, 24 Feb 2015 14:58:03 +0000 |
| Subject: | Re: [RFC] Anonymous Classes | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-83668@lists.php.net to get a copy of this message | ||
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.
~Florian