[wp-hackers] Proposal for a function commenting convention

Robin Adrianse robin.adr at gmail.com
Sat Oct 13 18:01:12 GMT 2007


PHPDoc, at least to me, seems to be the best option as it's rather
standardized and is both machine and human readable (well, reasonably so).

PHPDoc has a @since variable, which was made specifically for this purpose.

On 10/13/07, Ozh <ozh at planetozh.com> wrote:
>
> Hello there
>
> Again on the subject of "when the f*** was this function introduced?",
> I have a simple proposal for the future: why not simply add a comment
> stating in what version a particular function was implemented ?
>
> Something like, short version:
> /* do_stuff() : Does stuff. Added in WP 2.4-bleeding */
>
> Or for a PHPDoc version, we could use:
> /**
> * Does stuff
> * @return boolean
> * @version WP 2.4-bleeding
> */
>
> Or even a custom tag such as "@wordpress 2.4"
>
> I think this would, in the long run, really help casual plugin devs
> (as well as others probably, but I'm a casual plugin dev :)
>
> Thoughts ? (particularly from committers ?)
>
> Cheers,
>
> Ozh
> --
> http://FrenchFragFactory.net ~ Daily Quake News
> http://planetOzh.com ~ Blog and WordPress Stuff
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>


More information about the wp-hackers mailing list