Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-07 Thread Will Fitch
I'm saying that when you define an accessor, the body of the get/set functionality is contained within get {} and set {}, just like C#. I'm referencing your suggestion to automatic backing fields. There's no need for the backup. Reflection for accessors should be treated the same as the rest.

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-07 Thread Rasmus Schultz
I have no opinion about how it gets implemented under the hood - I thought we were just discussing the syntax. I most likely don't know enough about the innards of PHP it carry on that discussion. But by userspace definitions, are you referring to the fact that getters and setters would compile do

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-07 Thread Will Fitch
The difference being *where* the functionality gets mapped. It's not about making something "look like something else", it's about requiring more userspace definitions. Functionality within get {} and set {} can (and should IMO) be implemented outside of userspace code. Whether that means ano

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-07 Thread Rasmus Schultz
> if we're attempting to get around __set/get, let's not replace them with more method implementations I don't understand this argument. Accessors are methods - making them look like something else won't change that fact. In C#, type-hinted properties with automatic getters/setters actually compi

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-06 Thread Will Fitch
On Dec 6, 2011, at 8:58 AM, Rasmus Schultz wrote: > On Tue, Dec 6, 2011 at 3:45 AM, Christian Kaps > wrote: > >> Hi, >> >> I also find this syntax confusing and I think it has a huge WTF factor. >> >> Some thoughts about the syntax: >> - At the first glance, it isn't clear which visibility th

RE: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-04 Thread Clint M Priest
rivate level or something.  I did not explore that possibility as of >> yet. >> >> I did add a couple of convenience functions that may already be available in >> some other form I was not aware of, such as strcatalloc or MAKE_ZNODE(). >> >> --Clint >> >>

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-04 Thread Felipe Pena
d not explore that possibility as of >> yet. >> >> I did add a couple of convenience functions that may already be available in >> some other form I was not aware of, such as strcatalloc or MAKE_ZNODE(). >> >> --Clint >> >> -Original Message- >

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-04 Thread Felipe Pena
e of, such as strcatalloc or MAKE_ZNODE(). > > --Clint > > -Original Message- > From: Pierre Joye [mailto:pierre@gmail.com] > Sent: Sunday, December 04, 2011 4:50 AM > To: Clint M Priest > Cc: internals@lists.php.net > Subject: Re: [PHP-DEV] Patch: getters/setters synta

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-04 Thread Pierre Joye
hi, Please attach the patch (and any future version) to the RFC and to https://bugs.php.net/bug.php?id=49526, so it won't be lost if your sever goes down. Thanks! -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP Internals - PHP Runtime Development Mailing List To

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-04 Thread Christian Kaps
_ZNODE(). --Clint -Original Message- From: Pierre Joye [mailto:pierre@gmail.com] Sent: Sunday, December 04, 2011 4:50 AM To: Clint M Priest Cc: internals@lists.php.net Subject: Re: [PHP-DEV] Patch: getters/setters syntax Implementation hi Clint! Thanks for your work so far! On Sun, D

RE: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-04 Thread Clint M Priest
ists.php.net Subject: Re: [PHP-DEV] Patch: getters/setters syntax Implementation hi Clint! Thanks for your work so far! On Sun, Dec 4, 2011 at 1:33 AM, Clint M Priest wrote: > What are the next steps to get this added to some future release? Let discuss the implementation and how it works, th

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-04 Thread Pierre Joye
hi Clint! Thanks for your work so far! On Sun, Dec 4, 2011 at 1:33 AM, Clint M Priest wrote: > What are the next steps to get this added to some future release? Let discuss the implementation and how it works, then you can move to the voting phase. There is no need to hurry as the next relea

Re: [PHP-DEV] Patch: getters/setters syntax Implementation

2011-12-04 Thread Hannes Magnusson
On Sun, Dec 4, 2011 at 01:33, Clint M Priest wrote: > Per RFC: https://wiki.php.net/rfc/propertygetsetsyntax > > > > Alright, getters/setters has been built.  This is my first patch to the php > core.  Here is what has been implemented: > > http://www.clintpriest.com/patches/accessors_v1.patch (p