Skip to content

Commit d7e3aca

Browse files
committed
Fix issue with global fallback when not in global space
1 parent e14a769 commit d7e3aca

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
--TEST--
2+
non-existent imported functions should not be looked up in the global table
3+
--FILE--
4+
<?php
5+
6+
namespace {
7+
function test() {
8+
echo "NO!";
9+
}
10+
}
11+
namespace foo {
12+
use function bar\test;
13+
test();
14+
}
15+
16+
?>
17+
--EXPECTF--
18+
Fatal error: Call to undefined function bar\test() in %s on line %d

0 commit comments

Comments
 (0)