xref: /PHP-8.1/Zend/tests/bug69420.phpt (revision f8d79582)
1--TEST--
2Bug #69420 (Invalid read in zend_std_get_method)
3--FILE--
4<?php
5
6trait T {
7    protected function test() {
8        echo "okey";
9    }
10}
11
12
13class A {
14    protected function test() {
15    }
16}
17
18class B extends A {
19    use T;
20    public function foo() {
21        $this->test();
22    }
23}
24
25
26$b = new B();
27$b->foo();
28?>
29--EXPECT--
30okey
31