Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:32902 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 18772 invoked by uid 1010); 21 Oct 2007 13:57:12 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 18757 invoked from network); 21 Oct 2007 13:57:12 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 21 Oct 2007 13:57:12 -0000 Authentication-Results: pb1.pair.com header.from=magnus@php.net; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=magnus@php.net; spf=unknown; sender-id=unknown Received-SPF: unknown (pb1.pair.com: domain php.net does not designate 83.150.147.20 as permitted sender) X-PHP-List-Original-Sender: magnus@php.net X-Host-Fingerprint: 83.150.147.20 novell.stoldgods.nu Received: from [83.150.147.20] ([83.150.147.20:57520] helo=novell.stoldgods.nu) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 15/B3-32256-7BA5B174 for ; Sun, 21 Oct 2007 09:57:12 -0400 Received: from novell (novell [10.0.2.1]) by novell.stoldgods.nu (Postfix) with ESMTP id 2415FB6 for ; Sun, 21 Oct 2007 15:59:30 +0200 (CEST) To: internals@lists.php.net Date: Sun, 21 Oct 2007 15:57:48 +0200 User-Agent: KMail/1.9.6 (enterprise 0.20070907.709405) MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-ID: <200710211557.48355.magnus@php.net> Subject: Dynamic class names and namespaces From: magnus@php.net (Magnus =?iso-8859-1?q?M=E4=E4tt=E4?=) Hello, Using dynamic class names works fine without namespaces, but doesn't work at all with namespaces. Take this simple example: Will produce the following message: Fatal error: Class 'test::test' not found in foo.php on line Y Now if Foo would have a static method and we want to use dynamic access for a static method, we get another error: Parse error: syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM in ... All tested with current 5.3 /Magnus -- Small things make base men proud. -- William Shakespeare, "Henry VI"