Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:25653 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 70278 invoked by uid 1010); 13 Sep 2006 08:45:38 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 70263 invoked from network); 13 Sep 2006 08:45:38 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 13 Sep 2006 08:45:38 -0000 Authentication-Results: pb1.pair.com header.from=messju@lammfellpuschen.de; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=messju@lammfellpuschen.de; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain lammfellpuschen.de from 62.134.144.8 cause and error) X-PHP-List-Original-Sender: messju@lammfellpuschen.de X-Host-Fingerprint: 62.134.144.8 mx02.webserv-it.de Linux 2.5 (sometimes 2.4) (4) Received: from [62.134.144.8] ([62.134.144.8:53103] helo=mx02.webserv-it.de) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id EF/A1-55513-035C7054 for ; Wed, 13 Sep 2006 04:45:37 -0400 Received: from localhost (p54818E80.dip0.t-ipconnect.de [84.129.142.128]) (authenticated bits=0) by mx02.webserv-it.de (8.12.11.20060308/8.12.11) with ESMTP id k8D8jH8a032105; Wed, 13 Sep 2006 10:45:18 +0200 Date: Wed, 13 Sep 2006 10:45:17 +0200 To: danhen@email.de Cc: internals@lists.php.net Message-ID: <20060913084517.GC19373@localhost.localdomain> Reply-To: messju mohr References: <533075092@web.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <533075092@web.de> User-Agent: Mutt/1.5.11 Subject: Re: [PHP-DEV] PHP5 extensions: using existing functionnames as method names From: messju@lammfellpuschen.de (messju mohr) On Wed, Sep 13, 2006 at 10:09:08AM +0200, danhen@email.de wrote: > Hi, > > i just was wondering how existing function names could be used as method names > in OO-Extensions for PHP5. I've looked through the SPL-source where this is done with > functions like current() and next() in the iterators, but I couldn't find a hint how to do this. > > Can someone give me a little hint what is needed to do that. you can use any function name as method name without a clash. you just cannot use language constructs that aren't real functions like "empty", "echo" or "require" as method names. this question better belongs to php-general, btw. > Many thanks in advance, > Daniel