original_string: protected function addError(\Exception $exception)
      {
          $this->errorList[$exception->getCode()] = [
              'message'   => $exception->getMessage(),
              'line'      => $exception->getLine(),
              'file'      => $exception->getFile(),
              'trace'     => $exception->getTraceAsString(),
          ];
          $this->hasErrors = true;
  
          return $this;
      }
code: protected function addError(\Exception $exception)
      {
          $this->errorList[$exception->getCode()] = [
              'message'   => $exception->getMessage(),
              'line'      => $exception->getLine(),
              'file'      => $exception->getFile(),
              'trace'     => $exception->getTraceAsString(),
          ];
          $this->hasErrors = true;
  
          return $this;
      }
code_tokens: protected function addError ( \ Exception $ exception ) { $ this -> errorList [ $ exception -> getCode ( ) ] = [ 'message' => $ exception -> getMessage ( ) , 'line' => $ exception -> getLine ( ) , 'file' => $ exception -> getFile ( ) , 'trace' => $ exception -> getTraceAsString ( ) , ] ; $ this -> hasErrors = true ; return $ this ; }
docstring: add new error to list
  
  @param \Exception $exception
  @return $this
docstring_tokens: add new error to list