Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:68561 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 87236 invoked from network); 19 Aug 2013 01:32:13 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Aug 2013 01:32:13 -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 108.166.43.83 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 108.166.43.83 smtp83.ord1c.emailsrvr.com Linux 2.6 Received: from [108.166.43.83] ([108.166.43.83:47699] helo=smtp83.ord1c.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 23/E5-53655-B9571125 for ; Sun, 18 Aug 2013 21:32:12 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp3.relay.ord1c.emailsrvr.com (SMTP Server) with ESMTP id B72E25008B; Sun, 18 Aug 2013 21:32:09 -0400 (EDT) X-Virus-Scanned: OK Received: by smtp3.relay.ord1c.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id 5F11B500A4; Sun, 18 Aug 2013 21:32:09 -0400 (EDT) Message-ID: <52117598.2070404@sugarcrm.com> Date: Sun, 18 Aug 2013 18:32:08 -0700 Organization: SugarCRM User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:17.0) Gecko/20130801 Thunderbird/17.0.8 MIME-Version: 1.0 To: Igor Wiedler CC: "internals@lists.php.net" References: <60BF8DD5-FEEA-47D9-834F-6C7FDEF3B879@wiedler.ch> In-Reply-To: <60BF8DD5-FEEA-47D9-834F-6C7FDEF3B879@wiedler.ch> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [RFC] Importing namespaced functions From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! > RFC: https://wiki.php.net/rfc/use_function > Patch: https://github.com/php/php-src/pull/388 Looking at the patch: 1. use function bar as bar; does not produce any warning 2. use function x\foo as bar; function bar() { echo "OK!"; } Does not produce any warnings or errors, though it should be. 3. This code: namespace x; use foo as bar; use function foo as bar; bar(); Produces a crash. I would suggest this patch needs a bit more work on corner cases. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227