com php-src: Add test case for conflicting use and use function alias (stas): Zend/tests/use_function/conflicting_use_alias.p hpt

From: Date: Thu, 22 Aug 2013 13:51:26 +0000
Subject: com php-src: Add test case for conflicting use and use function alias (stas): Zend/tests/use_function/conflicting_use_alias.p hpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-74288@lists.php.net to get a copy of this message
Commit: 2dbbb8ae4b8f20f68c4d9f0f708d4391bbf49d07 Author: Igor Wiedler <igor@wiedler.ch> Wed, 21 Aug 2013 16:31:17 +0200 Parents: 4adf49eeaffc23cc6f4be53c2d89c720bd96d0c3 Branches: PHP-5.6 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=2dbbb8ae4b8f20f68c4d9f0f708d4391bbf49d07 Log: Add test case for conflicting use and use function alias (stas) Changed paths: A Zend/tests/use_function/conflicting_use_alias.phpt Diff: diff --git a/Zend/tests/use_function/conflicting_use_alias.phpt b/Zend/tests/use_function/conflicting_use_alias.phpt new file mode 100644 index 0000000..2870512 --- /dev/null +++ b/Zend/tests/use_function/conflicting_use_alias.phpt @@ -0,0 +1,20 @@ +--TEST-- +use and use function with the same alias +--FILE-- +<?php + +namespace { + function foo() { + return 'foo'; + } +} + +namespace x { + use foo as bar; + use function foo as bar; + var_dump(bar()); +} + +?> +--EXPECT-- +string(3) "foo"

« previous php.cvs (#74288) next »