Re: [RFC] Propety Accessors v1.1
| From: | Rasmus Schultz | Date: | Thu, 11 Oct 2012 01:28:15 +0000 |
| Subject: | Re: [RFC] Propety Accessors v1.1 | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-63332@lists.php.net to get a copy of this message | ||
Just a couple of quick remarks.
Clint wrote:
> I'm not even sure that automatic backing fields are even desired, I never
felt the need to have them in C# and the only reason they were included is
because they were a part of Dennis's original proposal.
Automatic backing fields are indeed necessary in C# for various technical
reasons none of which have any bearing on the PHP language - Nikita
explained this in another e-mail. So I vote for dropping automatic
auto-implemented accessors. In PHP, an auto-implemented accessor really
would be almost identical to a regular property anyhow.
I would also add that the double-underscore convention for the field-name
seems somewhat spooky to me - double-underscore is generally reserved for
PHP internal stuff... now suddenly these would be userland-fields. Seems
wrong.
Clint, I am sorry these issue were not surfaced earlier... I do seem to
recall sending a very long e-mail highlighting many of these issues a long
while back though (?) ... I only watch the list with half an eye, but I
usually speak up when I feel strongly about something. You're doing a great
job here! I hope you you will see it through - this would be a fantastic
feature which will make for better code architecture in so many ways.