4 * This file is part of the Symfony package.
6 * (c) Fabien Potencier <fabien@symfony.com>
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
12 namespace Symfony\Component\Debug\Exception
;
15 * Fatal Throwable Error.
17 * @author Nicolas Grekas <p@tchwork.com>
19 class FatalThrowableError
extends FatalErrorException
21 public function __construct(\Throwable
$e)
23 if ($e instanceof \ParseError
) {
24 $message = 'Parse error: '.$e->getMessage();
26 } elseif ($e instanceof \TypeError
) {
27 $message = 'Type error: '.$e->getMessage();
28 $severity = E_RECOVERABLE_ERROR
;
30 $message = $e->getMessage();
34 \ErrorException
::__construct(
43 $this->setTrace($e->getTrace());