original_string: public function validate($element)
      {
          $docBlock = $element->getDocBlock();
          if (null === $docBlock) {
              throw new \UnexpectedValueException(
                  'A DocBlock should be present (and validated) before this validator can be applied'
              );
          }
  
          if ($docBlock->hasTag('return')) {
              $returnTag = current($docBlock->getTagsByName('return'));
              if ($returnTag->getType() == 'type') {
                  return new Error(LogLevel::WARNING, 'PPC:ERR-50017', $element->getLinenumber());
              }
          }
  
          return null;
      }
code: public function validate($element)
      {
          $docBlock = $element->getDocBlock();
          if (null === $docBlock) {
              throw new \UnexpectedValueException(
                  'A DocBlock should be present (and validated) before this validator can be applied'
              );
          }
  
          if ($docBlock->hasTag('return')) {
              $returnTag = current($docBlock->getTagsByName('return'));
              if ($returnTag->getType() == 'type') {
                  return new Error(LogLevel::WARNING, 'PPC:ERR-50017', $element->getLinenumber());
              }
          }
  
          return null;
      }
code_tokens: public function validate ( $ element ) { $ docBlock = $ element -> getDocBlock ( ) ; if ( null === $ docBlock ) { throw new \ UnexpectedValueException ( 'A DocBlock should be present (and validated) before this validator can be applied' ) ; } if ( $ docBlock -> hasTag ( 'return' ) ) { $ returnTag = current ( $ docBlock -> getTagsByName ( 'return' ) ) ; if ( $ returnTag -> getType ( ) == 'type' ) { return new Error ( LogLevel :: WARNING , 'PPC:ERR-50017' , $ element -> getLinenumber ( ) ) ; } } return null ; }
docstring: Validates whether the given Reflector's arguments match the business rules of phpDocumentor.
  
  @param BaseReflector $element
  
  @throws \UnexpectedValueException if no DocBlock is associated with the given Reflector.
  
  @return Error|null
docstring_tokens: Validates whether the given Reflector s arguments match the business rules of phpDocumentor .