• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  *          Copyright Andrey Semashev 2007 - 2015.
3  * Distributed under the Boost Software License, Version 1.0.
4  *    (See accompanying file LICENSE_1_0.txt or copy at
5  *          http://www.boost.org/LICENSE_1_0.txt)
6  */
7 
8 #include <boost/config/abi_prefix.hpp>
9 
10 #if !defined(BOOST_LOG_ENABLE_WARNINGS)
11 
12 #if defined(_MSC_VER)
13 
14 #pragma warning(push, 3)
15 // 'm_A' : class 'A' needs to have dll-interface to be used by clients of class 'B'
16 #pragma warning(disable: 4251)
17 // non dll-interface class 'A' used as base for dll-interface class 'B'
18 #pragma warning(disable: 4275)
19 // switch statement contains 'default' but no 'case' labels
20 #pragma warning(disable: 4065)
21 // 'this' : used in base member initializer list
22 #pragma warning(disable: 4355)
23 // 'int' : forcing value to bool 'true' or 'false' (performance warning)
24 #pragma warning(disable: 4800)
25 // unreferenced formal parameter
26 #pragma warning(disable: 4100)
27 // conditional expression is constant
28 #pragma warning(disable: 4127)
29 // default constructor could not be generated
30 #pragma warning(disable: 4510)
31 // copy constructor could not be generated
32 #pragma warning(disable: 4511)
33 // assignment operator could not be generated
34 #pragma warning(disable: 4512)
35 // struct 'A' can never be instantiated - user defined constructor required
36 #pragma warning(disable: 4610)
37 // function marked as __forceinline not inlined
38 #pragma warning(disable: 4714)
39 // decorated name length exceeded, name was truncated
40 #pragma warning(disable: 4503)
41 // declaration of 'A' hides previous local declaration
42 #pragma warning(disable: 4456)
43 // declaration of 'A' hides global declaration
44 #pragma warning(disable: 4459)
45 // 'X': This function or variable may be unsafe. Consider using Y instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
46 #pragma warning(disable: 4996)
47 
48 #elif defined(__GNUC__) && !(defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)) \
49     && (__GNUC__ * 100 + __GNUC_MINOR__) >= 406
50 
51 #pragma GCC diagnostic push
52 // 'var' defined but not used
53 #pragma GCC diagnostic ignored "-Wunused-variable"
54 // unused parameter 'arg'
55 #pragma GCC diagnostic ignored "-Wunused-parameter"
56 // missing initializer for member var
57 #pragma GCC diagnostic ignored "-Wmissing-field-initializers"
58 
59 #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 407
60 // typedef 'foo' locally defined but not used
61 #pragma GCC diagnostic ignored "-Wunused-local-typedefs"
62 #endif
63 
64 #endif
65 
66 #endif // !defined(BOOST_LOG_ENABLE_WARNINGS)
67