diff --git a/Application.php b/Application.php index e9d80d76d..d23871f5a 100644 --- a/Application.php +++ b/Application.php @@ -796,7 +796,7 @@ protected function doRenderException(\Exception $e, OutputInterface $output) } if (false !== strpos($message, "class@anonymous\0")) { - $message = preg_replace_callback('/class@anonymous\x00.*?\.php(?:0x?|:)[0-9a-fA-F]++/', function ($m) { + $message = preg_replace_callback('/class@anonymous\x00.*?\.php(?:0x?|:[0-9]++\$)[0-9a-fA-F]++/', function ($m) { return class_exists($m[0], false) ? get_parent_class($m[0]).'@anonymous' : $m[0]; }, $message); }