[glib] Add single include guards to gvariant[type].h



commit 16c2f080497d1ed663237e725192c4f411f92f8f
Author: Ryan Lortie <desrt desrt ca>
Date:   Tue Jun 22 08:09:27 2010 -0400

    Add single include guards to gvariant[type].h

 glib/gvariant.h     |    4 ++++
 glib/gvarianttype.h |    4 ++++
 2 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/glib/gvariant.h b/glib/gvariant.h
index 24d9f40..aa270f6 100644
--- a/glib/gvariant.h
+++ b/glib/gvariant.h
@@ -20,6 +20,10 @@
  * Author: Ryan Lortie <desrt desrt ca>
  */
 
+#if defined(G_DISABLE_SINGLE_INCLUDES) && !defined (__GLIB_H_INSIDE__) && !defined (GLIB_COMPILATION)
+#error "Only <glib.h> can be included directly."
+#endif
+
 #ifndef __G_VARIANT_H__
 #define __G_VARIANT_H__
 
diff --git a/glib/gvarianttype.h b/glib/gvarianttype.h
index 1a477d6..2203ccb 100644
--- a/glib/gvarianttype.h
+++ b/glib/gvarianttype.h
@@ -20,6 +20,10 @@
  * Author: Ryan Lortie <desrt desrt ca>
  */
 
+#if defined(G_DISABLE_SINGLE_INCLUDES) && !defined (__GLIB_H_INSIDE__) && !defined (GLIB_COMPILATION)
+#error "Only <glib.h> can be included directly."
+#endif
+
 #ifndef __G_VARIANT_TYPE_H__
 #define __G_VARIANT_TYPE_H__
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]