Consider following code:
class Test
{
/**
* Folder name.
*
* @var string
*/
protected $folderName;
protected function setUp()
{
parent::setUp();
if ( !strlen($this->folderName) ) {
throw new \RuntimeException('The $this->folderName must be specified before proceeding.');
}
}
}
The error about missing @throws tag is reported at class property DocBlock by mistake, because method doesn't have any DocBlock.
I think, that in case if DocBlock is totally missing we should not report any error or report it at function declaration keyword.