Fallback mechanism not working on platform where TLS is unsupported
[urcu.git] / urcu / hlist.h
index e3b94ced234f61a721a52cef7a19fec543c63b5a..d7d5c87f1c28d1c3710ed1d1bb4a08f0751b3a55 100644 (file)
@@ -16,6 +16,8 @@
  * published by the Free  Software Foundation.
  */
 
+#include <stddef.h>
+
 struct cds_hlist_head
 {
        struct cds_hlist_node *next;
@@ -60,16 +62,16 @@ static inline void cds_hlist_del (struct cds_hlist_node *elem)
 
 #define cds_hlist_for_each_entry(entry, pos, head, member)                     \
        for (pos = (head)->next,                                        \
-                    entry = cds_hlist_entry(pos, typeof(*entry), member);      \
+                    entry = cds_hlist_entry(pos, __typeof__(*entry), member);  \
             pos != NULL;                                               \
             pos = pos->next,                                   \
-                    entry = cds_hlist_entry(pos, typeof(*entry), member))
+                    entry = cds_hlist_entry(pos, __typeof__(*entry), member))
 
 #define cds_hlist_for_each_entry_safe(entry, pos, p, head, member)             \
        for (pos = (head)->next,                                        \
-                    entry = cds_hlist_entry(pos, typeof(*entry), member);      \
+                    entry = cds_hlist_entry(pos, __typeof__(*entry), member);  \
             (pos != NULL) && ({ p = pos->next; 1;});                   \
             pos = p,                                                   \
-                    entry = cds_hlist_entry(pos, typeof(*entry), member))
+                    entry = cds_hlist_entry(pos, __typeof__(*entry), member))
 
 #endif /* _KCOMPAT_HLIST_H */
This page took 0.026673 seconds and 4 git commands to generate.