tobyS / pdv

PHP Documentor for VIM - Generates PHP docblocks
161 stars 32 forks source link

@return tag support #27

Open rawaludin opened 8 years ago

rawaludin commented 8 years ago

Any plan to add @return tag on function template?

erickpatrick commented 7 years ago

Well, at least for PHP 7 has the return type declaration which can ease the process, right?

ianchanning commented 7 years ago

This has been already requested in #10. There's comments in there about the issues with adding it. Seems that it likely won't get fixed unless someone submits a PR

harmenjanssen commented 6 years ago

Note that it's still nice to have a tab-stop for the @return tag.
Replacing function.tpl with the following makes sure you can at least add the return type yourself:

/**
 * ${1:{{name}}}{{?func: vmustache#InitCounter("params", 1)}}
 *{{#parameters}}
 * @param  ${{{?func: vmustache#IncrementCounter("params")}}:{{type}}{{^type}}mixed{{/type}}} ${{name}}${{{?func: vmustache#IncrementCounter("params")}}}{{/parameters}}
 * @return ${{{?func: vmustache#IncrementCounter("params")}}:type}
 */