summaryrefslogtreecommitdiff
path: root/Zend/tests/bug70156.phpt
blob: 0d20b38181255897c017f7ba9ee826c3f1b84f23 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
--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  dummy->bar() called at [%sbug70156.php:%d]
#1  dummy->foo1() called at [%sbug70156.php:%d]
#2  dummy->__construct() called at [%sbug70156.php:%d]