#33826 [Opn->Bgs]: constructor local method call
| From: | tony2001@php.net | Date: | Fri, 22 Jul 2005 16:57:03 +0000 |
| Subject: | #33826 [Opn->Bgs]: constructor local method call | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-82332@lists.php.net to get a copy of this message | ||
ID: 33826
Updated by: tony2001@php.net
Reported By: s_g_spencer at yahoo dot co dot uk
-Status: Open
+Status: Bogus
Bug Type: Scripting Engine problem
Operating System: debian linux 2.6.8
PHP Version: 5.0.4
New Comment:
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to
report
a bug at http://bugs.php.net/how-to-report.php
Previous Comments:
------------------------------------------------------------------------
[2005-07-22 18:52:02] s_g_spencer at yahoo dot co dot uk
Description:
------------
Cannot call local method from the classes constructor.
I might be wrong in thinking this is a problem. (long day)
Configure line :
./configure \
--with-apxs=/usr/bin/apxs \
--with-libxml-dir=/usr/lib \
--with-curl=/usr/lib \
--with-curlwrappers \
--with-mysql=/usr/lib \
--with-libxml-dir=/usr/lib \
--with-pear=/usr/lib/php \
--with-imap=/usr/include/imap-uw
Reproduce code:
---------------
class foo{
function __construct(){
bar();
}
function bar(){}
}
$example = new foo();
Expected result:
----------------
none. just no error.
Actual result:
--------------
Fatal error: Call to undefined function bar()
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=33826&edit=1