1--TEST--
2Test ReflectionProperty class errors.
3--FILE--
4<?php
5
6class C {
7    public static $p;
8}
9
10var_dump(new ReflectionProperty());
11var_dump(new ReflectionProperty('C::p'));
12var_dump(new ReflectionProperty('C', 'p', 'x'));
13$rp = new ReflectionProperty('C', 'p');
14var_dump($rp->getName(1));
15var_dump($rp->isPrivate(1));
16var_dump($rp->isProtected(1));
17var_dump($rp->isPublic(1));
18var_dump($rp->isStatic(1));
19var_dump($rp->getModifiers(1));
20var_dump($rp->isDefault(1));
21
22?>
23--EXPECTF--
24Warning: ReflectionProperty::__construct() expects exactly 2 parameters, 0 given in %s on line %d
25object(ReflectionProperty)#%d (2) {
26  ["name"]=>
27  string(0) ""
28  ["class"]=>
29  string(0) ""
30}
31
32Warning: ReflectionProperty::__construct() expects exactly 2 parameters, 1 given in %s on line %d
33object(ReflectionProperty)#%d (2) {
34  ["name"]=>
35  string(0) ""
36  ["class"]=>
37  string(0) ""
38}
39
40Warning: ReflectionProperty::__construct() expects exactly 2 parameters, 3 given in %s on line %d
41object(ReflectionProperty)#%d (2) {
42  ["name"]=>
43  string(0) ""
44  ["class"]=>
45  string(0) ""
46}
47
48Warning: ReflectionProperty::getName() expects exactly 0 parameters, 1 given in %s on line %d
49NULL
50
51Warning: ReflectionProperty::isPrivate() expects exactly 0 parameters, 1 given in %s on line %d
52NULL
53
54Warning: ReflectionProperty::isProtected() expects exactly 0 parameters, 1 given in %s on line %d
55NULL
56
57Warning: ReflectionProperty::isPublic() expects exactly 0 parameters, 1 given in %s on line %d
58NULL
59
60Warning: ReflectionProperty::isStatic() expects exactly 0 parameters, 1 given in %s on line %d
61NULL
62
63Warning: ReflectionProperty::getModifiers() expects exactly 0 parameters, 1 given in %s on line %d
64NULL
65
66Warning: ReflectionProperty::isDefault() expects exactly 0 parameters, 1 given in %s on line %d
67NULL
68