subsurface/core/ssrf.h
jan Iversen 6e253fa04f core/ssrf.h: add #pragma to avoid clang warning "-Wmissing-field-initializers"
Add a #pragma to avoid getting warning when a struct is only initialized
with one 0 and not one pr struct member

Signed-off-by: Jan Iversen <jani@apache.org>
2018-05-24 08:34:14 -07:00

22 lines
383 B
C

// SPDX-License-Identifier: GPL-2.0
#ifndef SSRF_H
#define SSRF_H
#ifdef __cplusplus
extern "C" {
#endif
#ifdef __clang__
// Clang has a bug on zero-initialization of C structs.
#pragma clang diagnostic ignored "-Wmissing-field-initializers"
#endif
#ifdef __cplusplus
}
#else
// Macro to be used for silencing unused parameters
#define UNUSED(x) (void)x
#endif
#endif // SSRF_H