Skip to content

Commit 0c04bde

Browse files
committed
Merge 65318,65319 from ^/trunk
------------------------------------------------------------------------ r65318 | jhunold | 2010-09-06 10:43:06 +0200 (Mo, 06 Sep 2010) | 3 lines Suppress msvc warning 4251 about templates as base classes not having a dll-interface. Suppress msvc warning 4275 about base class std::logic_error not having a dll-interface. ------------------------------------------------------------------------ r65319 | jhunold | 2010-09-06 16:14:09 +0200 (Mo, 06 Sep 2010) | 2 lines Fix: windows does not have wait(), use own macros instead. ------------------------------------------------------------------------ [SVN r65326]
1 parent cd1b58a commit 0c04bde

File tree

6 files changed

+46
-1
lines changed

6 files changed

+46
-1
lines changed

include/boost/program_options/detail/cmdline.hpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,11 @@
2222
#include <string>
2323
#include <vector>
2424

25+
#if defined(BOOST_MSVC)
26+
# pragma warning (push)
27+
# pragma warning (disable:4251) // class 'std::vector<_Ty>' needs to have dll-interface to be used by clients of class 'boost::program_options::positional_options_description'
28+
#endif
29+
2530
namespace boost { namespace program_options { namespace detail {
2631

2732
/** Command line parser class. Main requirements were:
@@ -134,5 +139,9 @@ namespace boost { namespace program_options { namespace detail {
134139

135140
}}}
136141

142+
#if defined(BOOST_MSVC)
143+
# pragma warning (pop)
144+
#endif
145+
137146
#endif
138147

include/boost/program_options/errors.hpp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,11 @@
1313
#include <stdexcept>
1414
#include <vector>
1515

16-
16+
#if defined(BOOST_MSVC)
17+
# pragma warning (push)
18+
# pragma warning (disable:4275) // non dll-interface class 'std::logic_error' used as base for dll-interface class 'boost::program_options::error'
19+
# pragma warning (disable:4251) // class 'std::vector<_Ty>' needs to have dll-interface to be used by clients of class 'boost::program_options::ambiguous_option'
20+
#endif
1721

1822
namespace boost { namespace program_options {
1923

@@ -232,5 +236,8 @@ namespace boost { namespace program_options {
232236
};
233237
}}
234238

239+
#if defined(BOOST_MSVC)
240+
# pragma warning (pop)
241+
#endif
235242

236243
#endif

include/boost/program_options/options_description.hpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,12 @@
2525

2626
#include <iosfwd>
2727

28+
#if defined(BOOST_MSVC)
29+
# pragma warning (push)
30+
# pragma warning (disable:4251) // class 'boost::shared_ptr<T>' needs to have dll-interface to be used by clients of class 'boost::program_options::option_description'
31+
#endif
32+
33+
2834
/** Boost namespace */
2935
namespace boost {
3036
/** Namespace for the library. */
@@ -251,4 +257,8 @@ namespace program_options {
251257
};
252258
}}
253259

260+
#if defined(BOOST_MSVC)
261+
# pragma warning (pop)
262+
#endif
263+
254264
#endif

include/boost/program_options/parsers.hpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@
1717
#include <vector>
1818
#include <utility>
1919

20+
#if defined(BOOST_MSVC)
21+
# pragma warning (push)
22+
# pragma warning (disable:4251) // class 'std::vector<_Ty>' needs to have dll-interface to be used by clients of class 'boost::program_options::basic_parsed_options<wchar_t>'
23+
#endif
24+
2025
namespace boost { namespace program_options {
2126

2227
class options_description;

include/boost/program_options/positional_options.hpp

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@
1111
#include <vector>
1212
#include <string>
1313

14+
#if defined(BOOST_MSVC)
15+
# pragma warning (push)
16+
# pragma warning (disable:4251) // class 'std::vector<_Ty>' needs to have dll-interface to be used by clients of class 'boost::program_options::positional_options_description'
17+
#endif
18+
1419
namespace boost { namespace program_options {
1520

1621
/** Describes positional options.
@@ -61,5 +66,9 @@ namespace boost { namespace program_options {
6166

6267
}}
6368

69+
#if defined(BOOST_MSVC)
70+
# pragma warning (pop)
71+
#endif
72+
6473
#endif
6574

include/boost/program_options/variables_map.hpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@
1616
#include <map>
1717
#include <set>
1818

19+
#if defined(BOOST_MSVC)
20+
# pragma warning (push)
21+
# pragma warning (disable:4251) // 'boost::program_options::variable_value::v' : class 'boost::any' needs to have dll-interface to be used by clients of class 'boost::program_options::variable_value
22+
#endif
23+
1924
namespace boost { namespace program_options {
2025

2126
template<class charT>

0 commit comments

Comments
 (0)