original_string: public function addError($error)
      {
          if ($error instanceof self) {
              $this->errors = array_merge($this->errors, $error->errors);
          } else {
              $this->errors[] = $error;
          }
  
          return $this;
      }
code: public function addError($error)
      {
          if ($error instanceof self) {
              $this->errors = array_merge($this->errors, $error->errors);
          } else {
              $this->errors[] = $error;
          }
  
          return $this;
      }
code_tokens: public function addError ( $ error ) { if ( $ error instanceof self ) { $ this -> errors = array_merge ( $ this -> errors , $ error -> errors ) ; } else { $ this -> errors [ ] = $ error ; } return $ this ; }
docstring: Add an error that occurred when building this Definition.
  
  @param string|\Closure|self $error
  
  @return $this
docstring_tokens: Add an error that occurred when building this Definition .