mirror of
https://github.com/php/php-src.git
synced 2024-12-14 04:16:30 +08:00
24 lines
348 B
PHP
24 lines
348 B
PHP
--TEST--
|
|
use const and use function with the same alias
|
|
--FILE--
|
|
<?php
|
|
|
|
namespace {
|
|
const foo = 'foo.const';
|
|
function foo() {
|
|
return 'foo.function';
|
|
}
|
|
}
|
|
|
|
namespace x {
|
|
use const foo as bar;
|
|
use function foo as bar;
|
|
var_dump(bar);
|
|
var_dump(bar());
|
|
}
|
|
|
|
?>
|
|
--EXPECT--
|
|
string(9) "foo.const"
|
|
string(12) "foo.function"
|