Add tests for broken function arguments

This commit is contained in:
Hannes Magnusson 2011-06-03 17:12:59 +00:00
parent 52e353e973
commit 2b22017e8f
2 changed files with 18 additions and 0 deletions

View file

@ -0,0 +1,9 @@
--TEST--
Argument parsing error #001
--FILE--
<?php
function foo($arg1 string) {}
?>
--EXPECTF--
Parse error: syntax error, unexpected T_STRING, expecting ')' in %sfunction_arguments.php on line %d

View file

@ -0,0 +1,9 @@
--TEST--
Argument parsing error #002
--FILE--
<?php
function foo($arg1/) {}
?>
--EXPECTF--
Parse error: syntax error, unexpected '/', expecting ')' in %sfunction_arguments_002.php on line %d