diff --git a/reference/errorfunc/functions/set-exception-handler.xml b/reference/errorfunc/functions/set-exception-handler.xml index 97eb7bfbd5..9ad5423368 100644 --- a/reference/errorfunc/functions/set-exception-handler.xml +++ b/reference/errorfunc/functions/set-exception-handler.xml @@ -32,7 +32,7 @@ Name of the function to be called when an uncaught exception occurs. This handler function needs to accept one parameter, which will be the exception object that - was thrown. This is the handler signature: + was thrown. This is the handler signature before PHP 7: @@ -40,6 +40,18 @@ Exceptionex + + Since PHP 7, most errors are reported by throwing Error + exceptions, which will be caught by the handler as well. Both Error + and Exception implements the Throwable interface. + This is the handler signature since PHP 7: + + + + voidhandler + Throwableex + + &null; may be passed instead, to reset this handler to its default state. @@ -76,6 +88,13 @@ + + 7.0.0 + + The type of parameter passed into exception_handler changed + from Exception to Throwable + + 5.5.0