Most functions are defined as "NULL IN --> NULL OUT" for all of their arguments.
There are "null rejection" checks in the planner that depend on this property of functions to properly optimize some outer joins.
If this is how MySQL works, we should patch that part of the planner.