summaryrefslogtreecommitdiffstats
path: root/include/zix/attributes.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2022-10-23 12:58:06 -0400
committerDavid Robillard <d@drobilla.net>2022-10-23 13:42:13 -0400
commitf95a698b94069ed03f6a8f2d0f7eb089d66c91ef (patch)
tree92da0fe8ece8a1890bf23fe67a38eb95556d03d8 /include/zix/attributes.h
parente883ea50dd1154294e21e946e391dd38e04d6527 (diff)
downloadzix-f95a698b94069ed03f6a8f2d0f7eb089d66c91ef.tar.gz
zix-f95a698b94069ed03f6a8f2d0f7eb089d66c91ef.tar.bz2
zix-f95a698b94069ed03f6a8f2d0f7eb089d66c91ef.zip
Add string view API
Diffstat (limited to 'include/zix/attributes.h')
-rw-r--r--include/zix/attributes.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/zix/attributes.h b/include/zix/attributes.h
index 1fe1183..b076fa7 100644
--- a/include/zix/attributes.h
+++ b/include/zix/attributes.h
@@ -34,13 +34,15 @@
// GCC function attributes
#ifdef __GNUC__
+# define ZIX_ALWAYS_INLINE_FUNC __attribute__((always_inline))
# define ZIX_PURE_FUNC __attribute__((pure))
# define ZIX_CONST_FUNC __attribute__((const))
# define ZIX_MALLOC_FUNC __attribute__((malloc))
#else
-# define ZIX_PURE_FUNC ///< Only reads memory
-# define ZIX_CONST_FUNC ///< Only reads its parameters
-# define ZIX_MALLOC_FUNC ///< Allocates memory
+# define ZIX_ALWAYS_INLINE_FUNC ///< Should absolutely always be inlined
+# define ZIX_PURE_FUNC ///< Only reads memory
+# define ZIX_CONST_FUNC ///< Only reads its parameters
+# define ZIX_MALLOC_FUNC ///< Allocates memory
#endif
/// A pure function in the public API that only reads memory