Rewrite $a ?: $b to empty($a) ? $b : $a if $a is a variable

How does it not break BC? You have no idea what people might do with that notice in their custom error handlers. If you remove it, that code won't be triggered and the app will behave differently.