File tree 3 files changed +11
-5
lines changed
3 files changed +11
-5
lines changed Original file line number Diff line number Diff line change 83
83
// managable and fixes a set of common hard-to-find bugs.
84
84
#if __cplusplus >= 201103L
85
85
# define JSONCPP_OVERRIDE override
86
- #elif defined(_MSC_VER) && _MSC_VER > 1600
86
+ # define JSONCPP_NOEXCEPT noexcept
87
+ #elif defined(_MSC_VER) && _MSC_VER > 1600 && _MSC_VER < 1900
87
88
# define JSONCPP_OVERRIDE override
89
+ # define JSONCPP_NOEXCEPT throw ()
90
+ #elif defined(_MSC_VER) && _MSC_VER >= 1900
91
+ # define JSONCPP_OVERRIDE override
92
+ # define JSONCPP_NOEXCEPT noexcept
88
93
#else
89
94
# define JSONCPP_OVERRIDE
95
+ # define JSONCPP_NOEXCEPT throw ()
90
96
#endif
91
97
92
98
#ifndef JSON_HAS_RVALUE_REFERENCES
Original file line number Diff line number Diff line change @@ -53,8 +53,8 @@ namespace Json {
53
53
class JSON_API Exception : public std::exception {
54
54
public:
55
55
Exception (JSONCPP_STRING const & msg);
56
- ~Exception () throw () JSONCPP_OVERRIDE;
57
- char const * what () const throw() JSONCPP_OVERRIDE;
56
+ ~Exception () JSONCPP_NOEXCEPT JSONCPP_OVERRIDE;
57
+ char const * what () const JSONCPP_NOEXCEPT JSONCPP_OVERRIDE;
58
58
protected:
59
59
JSONCPP_STRING msg_;
60
60
};
Original file line number Diff line number Diff line change @@ -193,9 +193,9 @@ namespace Json {
193
193
Exception::Exception (JSONCPP_STRING const & msg)
194
194
: msg_(msg)
195
195
{}
196
- Exception::~Exception () throw ()
196
+ Exception::~Exception () JSONCPP_NOEXCEPT
197
197
{}
198
- char const * Exception::what () const throw()
198
+ char const * Exception::what () const JSONCPP_NOEXCEPT
199
199
{
200
200
return msg_.c_str ();
201
201
}
You can’t perform that action at this time.
0 commit comments