avl_tree: Remove dependency on compiler.h
authorEric Biggers <ebiggers3@gmail.com>
Sun, 30 Mar 2014 05:25:35 +0000 (00:25 -0500)
committerEric Biggers <ebiggers3@gmail.com>
Sun, 30 Mar 2014 05:28:38 +0000 (00:28 -0500)
include/wimlib/avl_tree.h

index 00fdd3e..da5bbd0 100644 (file)
 
 #include <stdbool.h>
 #include <stddef.h>
-#include <inttypes.h>          /* for uintptr_t */
-#include <wimlib/compiler.h>   /* for _always_inline_attribute. You can
-                                  instead define it below if you want.  */
+#include <inttypes.h> /* for uintptr_t */
 
-#define AVL_INLINE _always_inline_attribute
+#ifdef __GNUC__
+#  define AVL_INLINE inline __attribute__((always_inline))
+#else
+#  define AVL_INLINE inline
+#endif
 
 /* Node in an AVL tree.  Embed this in some other data structure.  */
 struct avl_tree_node {