Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:64588 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 54967 invoked from network); 6 Jan 2013 01:10:08 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 6 Jan 2013 01:10:08 -0000 Authentication-Results: pb1.pair.com smtp.mail=smalyshev@sugarcrm.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=smalyshev@sugarcrm.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain sugarcrm.com designates 173.203.6.147 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 173.203.6.147 smtp147.ord.emailsrvr.com Linux 2.6 Received: from [173.203.6.147] ([173.203.6.147:53301] helo=smtp147.ord.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E9/E1-62408-0FEC8E05 for ; Sat, 05 Jan 2013 20:10:08 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp27.relay.ord1a.emailsrvr.com (SMTP Server) with ESMTP id E1DCC2A8131; Sat, 5 Jan 2013 20:10:04 -0500 (EST) X-Virus-Scanned: OK Received: by smtp27.relay.ord1a.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id F04B72A8132; Sat, 5 Jan 2013 20:10:03 -0500 (EST) Message-ID: <50E8CEEB.4020506@sugarcrm.com> Date: Sat, 05 Jan 2013 17:10:03 -0800 Organization: SugarCRM User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: Clint Priest CC: Steve Clay , "internals@lists.php.net" References: <50E41BB6.4030901@zerocue.com> <50E4A43E.6030302@zerocue.com> <50E4B232.5000505@mrclay.org> <50E4BDDE.8050509@zerocue.com> <50E4D0BB.7060701@mrclay.org> <50E4FA09.7030001@zerocue.com> <50E529B6.1050903@sugarcrm.com> <50E593DF.9090004@mrclay.org> <50E60994.4000400@sugarcrm.com> <50E86BBB.2080104@mrclay.org> <50E8797C.7030203@zerocue.com> <50E8950C.1080102@mrclay.org> <50E8B922.4070104@zerocue.com> In-Reply-To: <50E8B922.4070104@zerocue.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [PHP-RFC] Property Accessors 1.2 for Final Review before Vote From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! > The first call to a getter would initiate the (calling) guard, any other > access outside of the getter from that point forward would return NULL, > but the access by the getter would return the property. How we implement that? Would we have each variable access check whether we are in the getter or not? We don't want to slow down regular property accesses... > It would stop the infinite loop, stop invalid access, the author could > see where they've gone wrong (a warning could be emitted even) and we Yes, I think we want to produce a notice or even warning there if we return NULL as this is clearly a bug in the code and should not happen in proper code. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227