xref: /PHP-8.3/Zend/tests/declare_001.phpt (revision 74859783)
1--TEST--
2Testing declare statement with several type values
3--EXTENSIONS--
4mbstring
5--INI--
6zend.multibyte=1
7--FILE--
8<?php
9
10declare(encoding = 1);
11declare(encoding = 112313123213131232100);
12declare(encoding = 'utf-8');
13declare(encoding = M_PI);
14
15print 'DONE';
16
17?>
18--EXPECTF--
19Warning: Unsupported encoding [1] in %sdeclare_001.php on line %d
20
21Warning: Unsupported encoding [1.1231312321313E+20] in %sdeclare_001.php on line %d
22
23Fatal error: Encoding must be a literal in %s on line %d
24