diff options
author | Yong Bakos <ybakos@humanoriented.com> | 2016-09-17 15:04:32 -0700 |
---|---|---|
committer | Pekka Paalanen <pekka.paalanen@collabora.co.uk> | 2016-10-18 12:58:39 +0300 |
commit | ae139d8b6bc36fdc657369ed25dc331df967e35e (patch) | |
tree | 01515584af450db802db11dfcaee3899a74c2789 | |
parent | a1ab2c03ae7471895f8d24f9186c5ac288545e7f (diff) |
util: Document GCC attributes
Add doxygen comment blocks so these annotations are documented in the html
documentation.
Signed-off-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
-rw-r--r-- | src/wayland-util.h | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/wayland-util.h b/src/wayland-util.h index 9b7a4b9..7b280d1 100644 --- a/src/wayland-util.h +++ b/src/wayland-util.h @@ -40,21 +40,28 @@ extern "C" { #endif -/* GCC visibility */ +/** Visibility attribute */ #if defined(__GNUC__) && __GNUC__ >= 4 #define WL_EXPORT __attribute__ ((visibility("default"))) #else #define WL_EXPORT #endif -/* Deprecated attribute */ +/** Deprecated attribute */ #if defined(__GNUC__) && __GNUC__ >= 4 #define WL_DEPRECATED __attribute__ ((deprecated)) #else #define WL_DEPRECATED #endif -/* Printf annotation */ +/** + * Printf-style argument attribute + * + * \param x Ordinality of the format string argument + * \param y Ordinality of the argument to check against the format string + * + * \sa https://gcc.gnu.org/onlinedocs/gcc-3.2.1/gcc/Function-Attributes.html + */ #if defined(__GNUC__) && __GNUC__ >= 4 #define WL_PRINTF(x, y) __attribute__((__format__(__printf__, x, y))) #else |