summaryrefslogtreecommitdiff
path: root/include/linux/compiler-gcc4.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/compiler-gcc4.h')
-rw-r--r--include/linux/compiler-gcc4.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/compiler-gcc4.h b/include/linux/compiler-gcc4.h
index ab3af40a53c6..94dea3ffbfa1 100644
--- a/include/linux/compiler-gcc4.h
+++ b/include/linux/compiler-gcc4.h
@@ -51,3 +51,11 @@
#endif
#endif
+
+#if __GNUC_MINOR__ > 0
+#define __compiletime_object_size(obj) __builtin_object_size(obj, 0)
+#endif
+#if __GNUC_MINOR__ >= 4
+#define __compiletime_warning(message) __attribute__((warning(message)))
+#define __compiletime_error(message) __attribute__((error(message)))
+#endif