Re: RFC: Property get/set syntax (added isset/unset and references)
| From: | Stas Malyshev | Date: | Tue, 24 Apr 2012 17:16:28 +0000 |
| Subject: | Re: RFC: Property get/set syntax (added isset/unset and references) | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-60287@lists.php.net to get a copy of this message | ||
Hi!
> public $dataArray {
>
> &get { return &$this->_dataArray; }
This is not correct. Please read:
http://php.net/manual/en/language.references.return.php
> These would also include automatic implementations which call the
> respective functions on the backing field. I could see only allowing
> isset/unset automatic implementations if get/set were also specified
> as automatic implementations.
Could you please explain what is the use of automatic implementations?
I.e., why won't you just have a variable?
--
Stanislav Malyshev, Software Architect
SugarCRM: http://www.sugarcrm.com/
(408)454-6900 ext. 227