mirror of
https://github.com/php/php-src.git
synced 2024-12-20 07:20:33 +08:00
ab304579ff
Previously array() was only forbidden on the outermost level.
12 lines
202 B
PHP
12 lines
202 B
PHP
--TEST--
|
|
Cannot destructure using array(), even if nested
|
|
--FILE--
|
|
<?php
|
|
|
|
[array($a)] = [array(42)];
|
|
var_dump($a);
|
|
|
|
?>
|
|
--EXPECTF--
|
|
Fatal error: Cannot assign to array(), use [] instead in %s on line %d
|