For example to: preg_match
or when you use concatenation?
Answer to comments:
I can test for preg_match
or concatenation results, yes.
But there is a difference between:
PHP function with the signature: int f(string $parameter)
f
function gets it, orf
function get NULL even if signature expects string, so the function may throw exceptions or behave not as it would received an empty string.(I can't test this, because I can't write string
type for a parameter at function signature.)
It depends on the function you used for. Some may support null as parameter, some not. Some may throw notice, but dont forget that null may be converted to "" (empty string)