X-Git-Url: https://sigrok.org/gitweb/?p=libsigrokdecode.git;a=blobdiff_plain;f=HACKING;h=82176e14c216b295d0e7cc46da250ce21ec410bb;hp=922415faac884416ebeb7756fcf632c49f9ea2dc;hb=c1f86f02a149f46609273e1bd5b42696d544727a;hpb=1859c4804d04b58ba15a316eb16035c6bbb611fe diff --git a/HACKING b/HACKING index 922415f..82176e1 100644 --- a/HACKING +++ b/HACKING @@ -74,10 +74,38 @@ Random notes should end with "_all", e.g. "_remove_all", "_get_all", and so on. Use "_remove_all" in favor of "_clear" for consistency. + +Doxygen +------- + - In Doxygen comments, put an empty line between the block of @param lines and the final @return line. The @param lines themselves (if there is more than one) are not separated by empty lines. + - Mark private functions (SRD_PRIV) with /** @private */, so that Doxygen + doesn't include them in the output. Functions that are "static" anyway + don't need to be marked like this. + + - Mark private variables/#defines with /** @cond PRIVATE */ and + /** @endcond */, so that Doxygen doesn't include them in the output. + Variables that are "static" don't need to be marked like this. + + - Mark all public API functions (SRD_API) with a @since tag which indicates + in which release the respective function was added. If the function has + existed before, but its API changed later, document this as well. + + Non-public functions (static ones, and those marked SRD_PRIV) don't need + to have @since markers. + + The @since tag should be the last one, i.e. it should come after @param, + @return, @see, and so on. + + Examples: + + @since 0.1.0 + + @since 0.1.1 (but the API changed in 0.2.0) + Protocol decoder guidelines ---------------------------