duckdb 0.3.2-dev488.0 → 0.3.2-dev492.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "duckdb",
3
3
  "main": "./lib/duckdb.js",
4
- "version": "0.3.2-dev488.0",
4
+ "version": "0.3.2-dev492.0",
5
5
  "description": "DuckDB node.js API",
6
6
  "gypfile": true,
7
7
  "dependencies": {
package/src/duckdb.cpp CHANGED
@@ -11690,6 +11690,14 @@ const char *Exception::what() const noexcept {
11690
11690
  return exception_message_.c_str();
11691
11691
  }
11692
11692
 
11693
+ bool Exception::UncaughtException() {
11694
+ #if __cplusplus >= 201703L
11695
+ return std::uncaught_exceptions() > 0;
11696
+ #else
11697
+ return std::uncaught_exception();
11698
+ #endif
11699
+ }
11700
+
11693
11701
  string Exception::ConstructMessageRecursive(const string &msg, vector<ExceptionFormatValue> &values) {
11694
11702
  return ExceptionFormatValue::Format(msg, values);
11695
11703
  }
@@ -20653,7 +20661,7 @@ public:
20653
20661
 
20654
20662
  MiniZStreamWrapper::~MiniZStreamWrapper() {
20655
20663
  // avoid closing if destroyed during stack unwinding
20656
- if (std::uncaught_exception()) {
20664
+ if (Exception::UncaughtException()) {
20657
20665
  return;
20658
20666
  }
20659
20667
  try {
@@ -101581,7 +101589,7 @@ BaseAppender::~BaseAppender() {
101581
101589
  }
101582
101590
 
101583
101591
  void BaseAppender::Destructor() {
101584
- if (std::uncaught_exception()) {
101592
+ if (Exception::UncaughtException()) {
101585
101593
  return;
101586
101594
  }
101587
101595
  // flush any remaining chunks, but only if we are not cleaning up the appender as part of an exception stack unwind
@@ -103865,7 +103873,7 @@ ClientContext::ClientContext(shared_ptr<DatabaseInstance> database)
103865
103873
  }
103866
103874
 
103867
103875
  ClientContext::~ClientContext() {
103868
- if (std::uncaught_exception()) {
103876
+ if (Exception::UncaughtException()) {
103869
103877
  return;
103870
103878
  }
103871
103879
  // destroy the client context and rollback if there is an active transaction
@@ -105757,7 +105765,7 @@ DatabaseInstance::DatabaseInstance() {
105757
105765
  }
105758
105766
 
105759
105767
  DatabaseInstance::~DatabaseInstance() {
105760
- if (std::uncaught_exception()) {
105768
+ if (Exception::UncaughtException()) {
105761
105769
  return;
105762
105770
  }
105763
105771
 
package/src/duckdb.hpp CHANGED
@@ -10,8 +10,8 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
10
10
 
11
11
  #pragma once
12
12
  #define DUCKDB_AMALGAMATION 1
13
- #define DUCKDB_SOURCE_ID "5dec41339"
14
- #define DUCKDB_VERSION "0.3.2-dev488"
13
+ #define DUCKDB_SOURCE_ID "6d8e28328"
14
+ #define DUCKDB_VERSION "0.3.2-dev492"
15
15
  //===----------------------------------------------------------------------===//
16
16
  // DuckDB
17
17
  //
@@ -1299,6 +1299,8 @@ public:
1299
1299
  return ConstructMessageRecursive(msg, values, params...);
1300
1300
  }
1301
1301
 
1302
+ DUCKDB_API static bool UncaughtException();
1303
+
1302
1304
  private:
1303
1305
  string exception_message_;
1304
1306
  };