xref: /PHP-5.4/Zend/tests/lsb_017.phpt (revision 166266df)
1--TEST--
2ZE2 Late Static Binding nested calls
3--FILE--
4<?php
5class A {
6	public static function test($x=null) {
7		if (!is_null($x)) {
8			echo "$x\n";
9		}
10		return get_called_class();
11	}
12}
13
14class B extends A {
15}
16class C extends A {
17}
18class D extends A {
19}
20
21echo A::test(B::test(C::test(D::test())))."\n";
22?>
23==DONE==
24--EXPECT--
25D
26C
27B
28A
29==DONE==
30