mirror of
https://github.com/php/php-src.git
synced 2024-09-22 10:27:25 +00:00
de6e401e05
This makes debug_print_backtrace() use the same formatting as exception backtraces. The only difference is that the final #{main} is omitted, because it wouldn't make sense for limited backtraces, and wasn't there previously either.
38 lines
516 B
PHP
38 lines
516 B
PHP
--TEST--
|
|
Bug #70156 (Segfault in zend_find_alias_name)
|
|
--FILE--
|
|
<?php
|
|
trait T1 {
|
|
protected function foo1()
|
|
{
|
|
$this->bar();
|
|
}
|
|
}
|
|
|
|
trait T2 {
|
|
protected function foo2()
|
|
{
|
|
debug_print_backtrace();
|
|
}
|
|
}
|
|
|
|
class dummy {
|
|
use T1 {
|
|
foo1 as private;
|
|
}
|
|
use T2 {
|
|
foo2 as bar;
|
|
}
|
|
public function __construct()
|
|
{
|
|
$this->foo1();
|
|
}
|
|
}
|
|
|
|
new dummy();
|
|
?>
|
|
--EXPECTF--
|
|
#0 %s(%d): dummy->bar()
|
|
#1 %s(%d): dummy->foo1()
|
|
#2 %s(%d): dummy->__construct()
|