Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:64564 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 14403 invoked from network); 5 Jan 2013 22:33:54 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 5 Jan 2013 22:33:54 -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 173.203.6.155 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 173.203.6.155 smtp155.ord.emailsrvr.com Linux 2.6 Received: from [173.203.6.155] ([173.203.6.155:59515] helo=smtp155.ord.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 83/89-62408-15AA8E05 for ; Sat, 05 Jan 2013 17:33:53 -0500 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp12.relay.ord1a.emailsrvr.com (SMTP Server) with ESMTP id BE3E22E0084; Sat, 5 Jan 2013 17:33:50 -0500 (EST) X-Virus-Scanned: OK Received: by smtp12.relay.ord1a.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id 6DC862E0081; Sat, 5 Jan 2013 17:33:50 -0500 (EST) Message-ID: <50E8AA4D.5090207@sugarcrm.com> Date: Sat, 05 Jan 2013 14:33:49 -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: Nikita Popov CC: PHP internals References: <19D80B01-BE88-4119-8A15-B631A96060E5@mrclay.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [RFC] Alternative typehinting syntax for accessors From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! >> typehints, i.e. allow NULL when NULL is specified as the default value. So >> `public DateTime $date;` would not allow an explicit NULL assignment, >> whereas `public DateTime $date = NULL;` would. I think this is way too much magic. This means default is no longer a default, but instead some obscure flag that somehow is carried over to the setter. I do not think redefining initialization as permitting nulls is a good idea, initialization and value set are two different things. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227