public static function toThrowableTrace($ex)
    {
        $list = [];
        for ($stack = Throwable::getThrowableStack($ex); $stack !== null; $stack = $stack['prev'])
        {
            $list[] = Throwable::parseThrowableMessage($stack);
        }

        return array_reverse($list);
    }