Commit 746a2a83 authored by KOSAKI Motohiro's avatar KOSAKI Motohiro Committed by Linus Torvalds

sparse: Undef __compiletime_{warning,error} if __CHECKER__ is defined

sparse can't parse warning and error attribute.  then they should be
hidden from sparse.
Signed-off-by: default avatarKOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Cc: Arjan van de Ven <arjan@infradead.org>
Cc: Dave Hansen <dave@linux.vnet.ibm.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 5bd7e6a3
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
#if __GNUC_MINOR__ > 0 #if __GNUC_MINOR__ > 0
#define __compiletime_object_size(obj) __builtin_object_size(obj, 0) #define __compiletime_object_size(obj) __builtin_object_size(obj, 0)
#endif #endif
#if __GNUC_MINOR__ >= 4 #if __GNUC_MINOR__ >= 4 && !defined(__CHECKER__)
#define __compiletime_warning(message) __attribute__((warning(message))) #define __compiletime_warning(message) __attribute__((warning(message)))
#define __compiletime_error(message) __attribute__((error(message))) #define __compiletime_error(message) __attribute__((error(message)))
#endif #endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment