summaryrefslogtreecommitdiff
path: root/Zend/tests/bug34678.phpt
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@php.net>2005-10-03 09:12:19 +0000
committerDmitry Stogov <dmitry@php.net>2005-10-03 09:12:19 +0000
commit594fd87ca7f14d527147871d39247f376235254d (patch)
treead98f4d5e2d8bf9ce51c6e8d4bc75ebe0537e89c /Zend/tests/bug34678.phpt
parent728acc3785ec9ca6b2233ee8071805d139dda2bd (diff)
downloadphp-git-594fd87ca7f14d527147871d39247f376235254d.tar.gz
Fixed bug #34678 (__call(), is_callable() and static methods)
Diffstat (limited to 'Zend/tests/bug34678.phpt')
-rwxr-xr-xZend/tests/bug34678.phpt25
1 files changed, 25 insertions, 0 deletions
diff --git a/Zend/tests/bug34678.phpt b/Zend/tests/bug34678.phpt
new file mode 100755
index 0000000000..2a13201f26
--- /dev/null
+++ b/Zend/tests/bug34678.phpt
@@ -0,0 +1,25 @@
+--TEST--
+Bug #34678 (__call(), is_callable() and static methods)
+--FILE--
+<?php
+class A {
+ public function __call($m, $a) {
+ echo "__call\n";
+ }
+}
+
+class B extends A {
+ public static function foo() {
+ echo "foo\n";
+ }
+}
+
+if (is_callable(array('B', 'foo'))) {
+ call_user_func(array('B', 'foo'));
+}
+if (is_callable(array('A', 'foo'))) {
+ call_user_func(array('A', 'foo'));
+}
+?>
+--EXPECT--
+foo