diff options
author | Ondřej Surý <ondrej@sury.org> | 2013-10-27 20:38:12 +0100 |
---|---|---|
committer | Ondřej Surý <ondrej@sury.org> | 2013-10-27 20:38:12 +0100 |
commit | 749e5ad39dbac3f4f62be438367f8cdf90056815 (patch) | |
tree | ad0677df3bf44a6761380686e400ffd878585288 /Zend/tests/bug65579.phpt | |
parent | 4ed39205864f58ba7c368e4ae1362d8214469fd9 (diff) | |
download | php-749e5ad39dbac3f4f62be438367f8cdf90056815.tar.gz |
New upstream version 5.4.21upstream/5.4.21
Diffstat (limited to 'Zend/tests/bug65579.phpt')
-rw-r--r-- | Zend/tests/bug65579.phpt | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/Zend/tests/bug65579.phpt b/Zend/tests/bug65579.phpt new file mode 100644 index 000000000..25d74ed4f --- /dev/null +++ b/Zend/tests/bug65579.phpt @@ -0,0 +1,29 @@ +--TEST-- +Bug #65579 (Using traits with get_class_methods causes segfault) +--FILE-- +<?php +trait ParentTrait { + public function testMethod() { } +} + +trait ChildTrait { + use ParentTrait { + testMethod as testMethodFromParentTrait; + } + public function testMethod() { } +} + +class TestClass { + use ChildTrait; +} + +$obj = new TestClass(); +var_dump(get_class_methods($obj)); +?> +--EXPECT-- +array(2) { + [0]=> + string(10) "testMethod" + [1]=> + string(25) "testmethodfromparenttrait" +} |