private function addStackContext(Exception $exceptionRoot, array $context)
    {
        $exception = $exceptionRoot;

        do {
            $context = $this->processExceptionContext($exception, $context);
        }
        while ($exception = $exception->getPrevious());

        return $context;
    }