Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:56818 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 76448 invoked from network); 7 Dec 2011 02:29:47 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 7 Dec 2011 02:29:47 -0000 Authentication-Results: pb1.pair.com header.from=smalyshev@sugarcrm.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=smalyshev@sugarcrm.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain sugarcrm.com designates 207.97.245.173 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 207.97.245.173 smtp173.iad.emailsrvr.com Linux 2.6 Received: from [207.97.245.173] ([207.97.245.173:52273] helo=smtp173.iad.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 52/E4-40938-A9FCEDE4 for ; Tue, 06 Dec 2011 21:29:47 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp27.relay.iad1a.emailsrvr.com (SMTP Server) with ESMTP id DB8B1118560 for ; Tue, 6 Dec 2011 21:29:43 -0500 (EST) X-Virus-Scanned: OK Received: by smtp27.relay.iad1a.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id 928C4118555 for ; Tue, 6 Dec 2011 21:29:43 -0500 (EST) Message-ID: <4EDECF96.9000700@sugarcrm.com> Date: Tue, 06 Dec 2011 18:29:42 -0800 Organization: SugarCRM User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:8.0) Gecko/20111105 Thunderbird/8.0 MIME-Version: 1.0 CC: "internals@lists.php.net" References: <9570D903A3BECE4092E924C2985CE4853994C39F@MBX202.domain.local> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Re: Patch: getters/setters syntax Implementation From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! > I believe the attempt with the RFC was to mimic the syntax that C# > went with, the RFC is here: > https://wiki.php.net/rfc/propertygetsetsyntax Reading this RFC I notice it makes get/set keywords. This would lead to huge amount of breakage in existing code, so I strongly suggest to look for another way. For example, __get and __set... I'm also not a big fan of magic $value variable coming from nowhere and function syntax without function definition. What if you want a getter to return by-reference? Or setter to get parameter by reference? -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227