On 04/08/2016 11:45, Yasuo Ohgaki wrote:
Invalid inputs that violate input validation rules should not happen
almost always because input validation is _not_ the same input
mistakes by normal users. e.g. typo, user send a little too long
password. These mistakes should be handled as input errors/mistakes,
not input validation error.
To me, "validation" absolutely means "checking if the user input the
right things".
What you're talking about sounds more like assertions, which would fit
with the "this must be OK else die" implication of exceptions.
Perhaps the functions could be called filter_assert_var_array() etc?
Or perhaps some other term, to make it clear that these functions are
not intended for the common task of "form validation".
Regards,
--
Rowan Collins
[IMSoP]
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php