X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/5c0d3668dd2b6852812502f33d64b1644c2b137a..3a4477a4241bcfbc9db541cf34cc75c1f1111b78:/apt-pkg/contrib/macros.h?ds=sidebyside diff --git a/apt-pkg/contrib/macros.h b/apt-pkg/contrib/macros.h index e53eb32df..9aeb77b81 100644 --- a/apt-pkg/contrib/macros.h +++ b/apt-pkg/contrib/macros.h @@ -76,4 +76,13 @@ #define __cold /* no cold marker */ #endif +#ifdef __GNUG__ +// Methods have a hidden this parameter that is visible to this attribute + #define __like_printf_1 __attribute__ ((format (printf, 2, 3))) + #define __like_printf_2 __attribute__ ((format (printf, 3, 4))) +#else + #define __like_printf_1 + #define __like_printf_2 +#endif + #endif