From:             [EMAIL PROTECTED]
Operating system: Windows XP Professional
PHP version:      5CVS-2003-01-27 (dev)
PHP Bug Type:     Zend Engine 2 problem
Bug description:  storing lambda functions into object properties

Try this, it simply let's my PHP crash:

class foo {

  public $newfunc;
  
  public function __construct() {
    $this->newfunc = create_function('$a,$b','print "ln($a) + ln($b) =
".log($a * $b);');
    call_user_func(array($this, $this->newfunc), 1, 2);
    //$this->$newfunc(1, 2);
  }
  
}

$f = new foo();

Ok, ok - this is really, well, weird code, however...



PHP:


PHP Version 5.0.0-dev

System Windows NT localhost 5.1 build 2600
Build Date Jan 26 2003 16:10:39
Server API CGI/FastCGI
Virtual Directory Support enabled
Configuration File (php.ini) Path E:\php\php.ini
PHP API 20020918
PHP Extension 20020429
Zend Extension 90021012
Debug Build no
Thread Safety enabled
Registered PHP Streams php, http, ftp, compress.zlib

Zend Engine v2.0.0-dev,
-- 
Edit bug report at http://bugs.php.net/?id=21909&edit=1
-- 
Try a CVS snapshot:         http://bugs.php.net/fix.php?id=21909&r=trysnapshot
Fixed in CVS:               http://bugs.php.net/fix.php?id=21909&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=21909&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=21909&r=needtrace
Try newer version:          http://bugs.php.net/fix.php?id=21909&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=21909&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=21909&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=21909&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=21909&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=21909&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=21909&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=21909&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=21909&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=21909&r=gnused

Reply via email to