summaryrefslogtreecommitdiff
path: root/Zend/tests/list_013.phpt
diff options
context:
space:
mode:
authorXinchen Hui <laruence@gmail.com>2016-06-14 14:02:34 +0800
committerXinchen Hui <laruence@gmail.com>2016-06-14 14:02:34 +0800
commit9c8e1c03b97fea34432ed8a91e8ddd9b9d20a649 (patch)
tree4a2ffbaadcd5d8c718cedd20d922e9f16ab473eb /Zend/tests/list_013.phpt
parent14e790a0753dce4dfaeff1b2d8f9800b519917c1 (diff)
downloadphp-git-9c8e1c03b97fea34432ed8a91e8ddd9b9d20a649.tar.gz
Only allow single comma in tail
Diffstat (limited to 'Zend/tests/list_013.phpt')
-rw-r--r--Zend/tests/list_013.phpt10
1 files changed, 10 insertions, 0 deletions
diff --git a/Zend/tests/list_013.phpt b/Zend/tests/list_013.phpt
new file mode 100644
index 0000000000..2869f5f423
--- /dev/null
+++ b/Zend/tests/list_013.phpt
@@ -0,0 +1,10 @@
+--TEST--
+Disallow tail empty elements in normal arrays
+--FILE--
+<?php
+
+var_dump([1, 2, ,]);
+
+?>
+--EXPECTF--
+Fatal error: Cannot use empty array elements in arrays in %s on line %d