Community
Participate
Working Groups
Example code: function doSomeStuff($header, $footer) { if (strlen ( $footer ) < 0) { $err= new Exception($header, $code); throw $err; } } Generate Element Comment for this function. Result: /** * Enter description here ... * @param unknown_type $header * @param unknown_type $footer */ As you can see there is no @throws line. Replace the code: $err= new Exception($header, $code); throw $err; with: throw new Exception($header, $code); The generated comment will be: /** * Enter description here ... * @param unknown_type $header * @param unknown_type $footer * @throws Exception */ So in case you use the class directly in the throw statement you get a @throws, otherwise (i.e. use variables) not.
Fixed.
[Petyo Tanchev] Tested on 2.2.1 SR1 Works as expected.