[xdebug-dev] Bug 0000213: Dead code analysis doesn't take catches for throws into account

From: <xdebug-dev[@]lists.xdebug.org>
Date: Wed, 18 Oct 2006 20:46:52 +0200

The following bug has been CLOSED
======================================================================
http://bugs.xdebug.org/bug_view_page.php?bug_id=0000213
======================================================================
Reporter: derick
Handler:
======================================================================
Project: Xdebug
Bug ID: 213
Category: Usage problems
Reproducibility: always
Severity: trivial
Priority: normal
Status: closed
Operating System:
PHP Version: 5.1.6
Xdebug Version: 2.0.0rc2-dev
======================================================================
Date Submitted: 2006-10-18 16:44 CEST
Last Modified: 2006-10-18 20:46 CEST
======================================================================
Summary: Dead code analysis doesn't take catches for throws into account
Description:
<?php

try
{
    throw new Exception();
}
catch(Exception $e) {}
?>

produces the VLD codes:
number of ops: 13
line # op fetch ext operands
-------------------------------------------------------------------------------
   5 0 NOP
   7 1 EXT_STMT
         2 ZEND_FETCH_CLASS :0,
'Exception'
         3 EXT_FCALL_BEGIN
         4 NEW $1, :0
         5 DO_FCALL_BY_NAME 0 0
         6 EXT_FCALL_END
         7 ZEND_THROW $1
   9 8* ZEND_FETCH_CLASS :3,
'Exception'
         9* ZEND_CATCH null, 'e'
  11 10* EXT_STMT
        11* RETURN 1
        12* ZEND_HANDLE_EXCEPTION

======================================================================

----------------------------------------------------------------------
 derick - 2006-10-18 20:46 CEST
----------------------------------------------------------------------
Fixed in CVS.

Bug History
Date Modified Username Field Change
======================================================================
2006-10-18 16:44derick New Bug
2006-10-18 16:44derick Bug Monitored: derick
2006-10-18 20:46derick Bugnote Added: 0000478
2006-10-18 20:46derick Status new => closed
======================================================================
Received on Wed Oct 18 2006 - 20:46:53 BST

This archive was generated by hypermail 2.2.0 : Sun Jun 24 2018 - 04:00:03 BST