php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #59056 bcompiler can't compile php build-in classes
Submitted: 2010-02-01 11:14 UTC Modified: 2010-02-01 15:06 UTC
From: bugs at bilke dot org Assigned:
Status: Wont fix Package: bcompiler (PECL)
PHP Version: 5.2.10 OS: Ubuntu 9.10
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: bugs at bilke dot org
New email:
PHP Version: OS:

 

 [2010-02-01 11:14 UTC] bugs at bilke dot org
Description:
------------
Using the bcompiler_compile.php script, shipped with the bcompiler documentation it's not possible to compile classes which extends php build-in classes.

The script execution will fail with a seg fault.

Reproduce code:
---------------
<?php
class MyClass extends Exception {

}
?>

Actual result:
--------------
WRITING TO MyClass.php.phb
PARSE: ./MyClass.php
ADDED CLASS: MyClass
Array
(
    [0] => MyClass
)
COMPILE Exception extends '' 
Segmentation fault
Exit 139

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2010-02-01 15:06 UTC] val@php.net
Problem is obviously with bcompiler_compile.php, but it's kind of outdated (see bug #17039 for details).

The handling of user classes that extend built-in classes doesn't seem to have any issues, tested with the following:

<?php
class MyClass extends Exception {

}

  $f = fopen('bug-17040.phb', "w");
  bcompiler_write_header($f);
  bcompiler_write_class($f, 'MyClass');
  bcompiler_write_footer($f);
  fclose($f);
?>
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Dec 10 11:01:28 2024 UTC