xref: /PHP-7.0/Zend/tests/ns_086.phpt (revision 8d8f6552)
1--TEST--
2086: bracketed namespace with encoding
3--SKIPIF--
4<?php
5if (!extension_loaded("mbstring")) {
6  die("skip Requires mbstring extension");
7}
8?>
9--INI--
10zend.multibyte=1
11--FILE--
12<?php
13declare(encoding='utf-8');
14namespace foo {
15use \foo;
16class bar {
17	function __construct() {echo __METHOD__,"\n";}
18}
19new foo;
20new bar;
21}
22namespace {
23class foo {
24	function __construct() {echo __METHOD__,"\n";}
25}
26use foo\bar as foo1;
27new foo1;
28new foo;
29echo "===DONE===\n";
30}
31--EXPECT--
32foo::__construct
33foo\bar::__construct
34foo\bar::__construct
35foo::__construct
36===DONE===