blob: 9acdc1987b6741a2511f1e42f13d7cc60823b9bc (
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
38
39
40
41
42
43
44
|
--TEST--
Bug #64239 (ReflectionClass::getMethods() changed behavior)
--FILE--
<?php
class A {
use T2 { t2method as Bmethod; }
}
trait T2 {
public function t2method() {
}
}
class B extends A{
}
$obj = new ReflectionClass("B");
print_r($obj->getMethods());
print_r(($method = $obj->getMethod("Bmethod")));
var_dump($method->getName());
var_dump($method->getShortName());
?>
--EXPECT--
Array
(
[0] => ReflectionMethod Object
(
[name] => Bmethod
[class] => A
)
[1] => ReflectionMethod Object
(
[name] => t2method
[class] => A
)
)
ReflectionMethod Object
(
[name] => Bmethod
[class] => A
)
string(7) "Bmethod"
string(7) "Bmethod"
|