Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Core/Node-API/Include/Shared/napi/napi.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@
#endif // NAPI_HAS_THREADS
#include <string>
#include <vector>
#ifdef NAPI_CPP_EXCEPTIONS
#include <exception>
Comment thread
SergioRZMasson marked this conversation as resolved.
#endif // NAPI_CPP_EXCEPTIONS

// VS2015 RTM has bugs with constexpr, so require min of VS2015 Update 3 (known
// good version)
Expand Down Expand Up @@ -1847,10 +1850,12 @@ class Error : public ObjectReference
static Error New(napi_env env, const char* message);
static Error New(napi_env env, const std::string& message);

#ifdef NAPI_CPP_EXCEPTIONS
// [BABYLON-NATIVE-ADDITION]
static Error New(napi_env env, const std::exception& exception);
// [BABYLON-NATIVE-ADDITION]
static Error New(napi_env env, const std::exception_ptr& exception_ptr);
#endif // NAPI_CPP_EXCEPTIONS

static NAPI_NO_RETURN void Fatal(const char* location, const char* message);

Expand Down