blob: ce192292bbb80bb5bc192c81af0b58ec0b19032e (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
//===-- CompilerWarning.h ---------------------------------------*- C++ -*-===//
//
// The KLEE Symbolic Virtual Machine
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
#ifndef KLEE_INCLUDE_KLEE_SUPPORT_COMPILERWARNING_H
#define KLEE_INCLUDE_KLEE_SUPPORT_COMPILERWARNING_H
// Disables different warnings
#if defined(__GNUC__) || defined(__clang__)
#define ENABLE_PRAGMA(X) _Pragma(#X)
#define DISABLE_WARNING_PUSH ENABLE_PRAGMA(GCC diagnostic push)
#define DISABLE_WARNING_POP ENABLE_PRAGMA(GCC diagnostic pop)
#define DISABLE_WARNING(warningName) \
ENABLE_PRAGMA(GCC diagnostic ignored #warningName)
#define DISABLE_WARNING_DEPRECATED_DECLARATIONS \
DISABLE_WARNING(-Wdeprecated-declarations)
#else
#define DISABLE_WARNING_PUSH
#define DISABLE_WARNING_POP
#define DISABLE_WARNING(warningName)
#define DISABLE_WARNING_DEPRECATED_DECLARATIONS
#endif
#endif // KLEE_INCLUDE_KLEE_SUPPORT_COMPILERWARNING_H
|