summaryrefslogtreecommitdiff
path: root/Zend/tests
diff options
context:
space:
mode:
authorMáté Kocsis <kocsismate@woohoolabs.com>2020-06-05 14:40:40 +0200
committerMáté Kocsis <kocsismate@woohoolabs.com>2020-06-06 09:23:34 +0200
commitaa9b0ccda88531f9bb3f2149db002c5fcaaa7b14 (patch)
tree280b5f373ee382cad61fc0c0abc575bcb6c8f544 /Zend/tests
parent170d63ec62ff61de0b4394099d2e14732d0392fb (diff)
downloadphp-git-aa9b0ccda88531f9bb3f2149db002c5fcaaa7b14.tar.gz
Add tests to check mismatching function signatures
Closes GH-5666
Diffstat (limited to 'Zend/tests')
-rw-r--r--Zend/tests/arginfo_zpp_mismatch.phpt31
1 files changed, 31 insertions, 0 deletions
diff --git a/Zend/tests/arginfo_zpp_mismatch.phpt b/Zend/tests/arginfo_zpp_mismatch.phpt
new file mode 100644
index 0000000000..9762dd5fce
--- /dev/null
+++ b/Zend/tests/arginfo_zpp_mismatch.phpt
@@ -0,0 +1,31 @@
+--TEST--
+Test that there is no arginfo/zpp mismatch
+--FILE--
+<?php
+
+foreach (get_defined_functions()["internal"] as $function) {
+ try {
+ @$function(null, null, null, null, null, null, null, null);
+ } catch (ArgumentCountError|Error) {
+ }
+}
+
+// var_dump() and debug_zval_dump() print all arguments
+?>
+--EXPECT--
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL
+NULL