summaryrefslogtreecommitdiffstats
path: root/talloc.h
diff options
context:
space:
mode:
authorStefano Pigozzi <stefano.pigozzi@gmail.com>2012-11-12 23:24:01 +0100
committerStefano Pigozzi <stefano.pigozzi@gmail.com>2012-11-13 22:19:18 +0100
commitbec630c34753f7fbbac8712661b596ff5a76b7c1 (patch)
tree633035ee2654d301ed9a13dd83f006b7cab173b5 /talloc.h
parent9203f06cf32a260f0ed4209eb744c58e0e6db47b (diff)
downloadmpv-bec630c34753f7fbbac8712661b596ff5a76b7c1.tar.bz2
mpv-bec630c34753f7fbbac8712661b596ff5a76b7c1.tar.xz
clang: fix all warnings except deprecations
Diffstat (limited to 'talloc.h')
-rw-r--r--talloc.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/talloc.h b/talloc.h
index 0581bd09c5..909ce80ecf 100644
--- a/talloc.h
+++ b/talloc.h
@@ -58,7 +58,10 @@ typedef void TALLOC_CTX;
/* try to make talloc_set_destructor() and talloc_steal() type safe,
if we have a recent gcc */
-#if (__GNUC__ >= 3)
+#if defined(__clang__) && defined(__llvm__)
+#define _TALLOC_TYPEOF(ptr) void *
+#define talloc_steal(ctx, ptr) _talloc_steal((ctx),(ptr))
+#elif (__GNUC__ >= 3)
#define _TALLOC_TYPEOF(ptr) __typeof__(ptr)
/* this extremely strange macro is to avoid some braindamaged warning
stupidity in gcc 4.1.x */