summaryrefslogtreecommitdiff
path: root/json/json.h
diff options
context:
space:
mode:
authorGlenn Smith <glenn@vector35.com>2023-09-01 14:23:06 -0400
committerGlenn Smith <glenn@vector35.com>2023-09-01 15:09:46 -0400
commit1882088834620730520694805954431773142869 (patch)
tree6c5b4e05aa6ff6bd0474da282705096945654a37 /json/json.h
parent3a2115bcdcfbca0432afad84f4877187f72514a2 (diff)
Make the json exception macro specifiable externally too
Thanks, windows
Diffstat (limited to 'json/json.h')
-rw-r--r--json/json.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/json/json.h b/json/json.h
index 399de6ca..8208038b 100644
--- a/json/json.h
+++ b/json/json.h
@@ -469,6 +469,7 @@ public:
#if !defined(JSON_IS_AMALGAMATION)
#include "forwards.h"
#endif // if !defined(JSON_IS_AMALGAMATION)
+#include <stdexcept>
#include <exception>
#include <string>
#include <vector>
@@ -502,11 +503,12 @@ public:
#pragma warning(disable : 4251)
#endif // if defined(JSONCPP_DISABLE_DLL_INTERFACE_WARNING)
+#ifndef JSONCPP_EXCEPTION
// XXX: BN: Use our exception class for extra details
#include "../exceptions.h"
#define JSONCPP_EXCEPTION ExceptionWithStackTrace
// #define JSONCPP_EXCEPTION std::runtime_error
-
+#endif
#pragma pack(push, 8)