[gnome-builder] macros: add string literal length



commit 8c511654013c190a39ad88172395c34243da9dc5
Author: Christian Hergert <chergert redhat com>
Date:   Fri Dec 18 03:59:37 2015 -0800

    macros: add string literal length

 libide/ide-macros.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/libide/ide-macros.h b/libide/ide-macros.h
index 2226b04..1a907dc 100644
--- a/libide/ide-macros.h
+++ b/libide/ide-macros.h
@@ -46,6 +46,8 @@ G_BEGIN_DECLS
     } \
   } G_STMT_END
 
+#define IDE_LITERAL_LENGTH(s) ((sizeof s)-1)
+
 static inline gboolean
 ide_str_empty0 (const gchar *str)
 {


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