Declare ALL_ZERO in the common libsigrokdecode-internal.h header file.
The implementation and the comment on its motivation were taken from the
libsigrok implementation, slightly rephrased for improved readability.
#include <Python.h> /* First, so we avoid a _POSIX_C_SOURCE warning. */
#include "libsigrokdecode.h"
+/*
+ * Static definition of tables ending with an all-zero sentinel entry
+ * may raise warnings when compiling with -Wmissing-field-initializers.
+ * GCC suppresses the warning only with { 0 }, clang wants { } instead.
+ */
+#ifdef __clang__
+# define ALL_ZERO { }
+#else
+# define ALL_ZERO { 0 }
+#endif
+
enum {
SRD_TERM_ALWAYS_FALSE,
SRD_TERM_HIGH,