xref: /PHP-5.4/Zend/tests/ns_041.phpt (revision 7126de49)
1--TEST--
2041: Constants in namespace
3--FILE--
4<?php
5namespace test\ns1;
6
7const FOO = "ok\n";
8
9echo(FOO);
10echo(\test\ns1\FOO);
11echo(\test\ns1\FOO);
12echo(BAR);
13
14const BAR = "ok\n";
15
16--EXPECTF--
17ok
18ok
19ok
20
21Notice: Use of undefined constant BAR - assumed 'BAR' in %sns_041.php on line 9
22BAR
23