better-sqlite3-multiple-ciphers 11.0.0-beta.0 → 11.1.2

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.
@@ -31,9 +31,9 @@
31
31
 
32
32
  #define SQLITE3MC_VERSION_MAJOR 1
33
33
  #define SQLITE3MC_VERSION_MINOR 8
34
- #define SQLITE3MC_VERSION_RELEASE 5
34
+ #define SQLITE3MC_VERSION_RELEASE 6
35
35
  #define SQLITE3MC_VERSION_SUBRELEASE 0
36
- #define SQLITE3MC_VERSION_STRING "SQLite3 Multiple Ciphers 1.8.5"
36
+ #define SQLITE3MC_VERSION_STRING "SQLite3 Multiple Ciphers 1.8.6"
37
37
 
38
38
  #endif /* SQLITE3MC_VERSION_H_ */
39
39
  /*** End of #include "sqlite3mc_version.h" ***/
@@ -13543,7 +13543,7 @@ SQLITE_API int sqlite3_user_add(
13543
13543
  ** The sqlite3_user_change() interface can be used to change a users
13544
13544
  ** login credentials or admin privilege. Any user can change their own
13545
13545
  ** login credentials. Only an admin user can change another users login
13546
- ** credentials or admin privilege setting. No user may change their own
13546
+ ** credentials or admin privilege setting. No user may change their own
13547
13547
  ** admin privilege setting.
13548
13548
  */
13549
13549
  SQLITE_API int sqlite3_user_change(
@@ -13777,6 +13777,7 @@ extern "C" {
13777
13777
  #ifndef SQLITE_PRIVATE
13778
13778
  #define SQLITE_PRIVATE
13779
13779
  #endif
13780
+
13780
13781
  SQLITE_PRIVATE int sqlite3mcCheckVfs(const char* zVfs);
13781
13782
 
13782
13783
  SQLITE_API int sqlite3mc_vfs_create(const char* zVfsReal, int makeDefault);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "better-sqlite3-multiple-ciphers",
3
- "version": "11.0.0-beta.0",
3
+ "version": "11.1.2",
4
4
  "description": "better-sqlite3 with multiple-cipher encryption support",
5
5
  "homepage": "https://github.com/m4heshd/better-sqlite3-multiple-ciphers",
6
6
  "author": "Mahesh Bandara Wijerathna (m4heshd) <m4heshd@gmail.com>",
@@ -2,7 +2,7 @@
2
2
  //
3
3
 
4
4
  #include "better_sqlite3.hpp"
5
- #line 153 "./src/util/macros.lzz"
5
+ #line 150 "./src/util/macros.lzz"
6
6
  void SetPrototypeGetter(
7
7
  v8::Isolate* isolate,
8
8
  v8::Local<v8::External> data,
@@ -11,7 +11,7 @@ void SetPrototypeGetter(
11
11
  v8::AccessorGetterCallback func
12
12
  ) {
13
13
  v8::HandleScope scope(isolate);
14
-
14
+
15
15
  #if defined NODE_MODULE_VERSION && NODE_MODULE_VERSION < 121
16
16
  recv->InstanceTemplate()->SetAccessor(
17
17
  InternalizedFromLatin1(isolate, name),
@@ -30,7 +30,7 @@ void SetPrototypeGetter(
30
30
  );
31
31
  #endif
32
32
  }
33
- #line 183 "./src/util/macros.lzz"
33
+ #line 180 "./src/util/macros.lzz"
34
34
  #ifndef V8_COMPRESS_POINTERS_IN_SHARED_CAGE
35
35
  #define SAFE_NEW_BUFFER(env, data, length, finalizeCallback, finalizeHint) node::Buffer::New(env, data, length, finalizeCallback, finalizeHint)
36
36
  #else
@@ -103,33 +103,33 @@ namespace Data
103
103
  #line 70 "./src/util/data.lzz"
104
104
  static char const RAW = 3;
105
105
  }
106
- #line 37 "./src/util/macros.lzz"
106
+ #line 34 "./src/util/macros.lzz"
107
107
  void ThrowError (char const * message)
108
- #line 37 "./src/util/macros.lzz"
108
+ #line 34 "./src/util/macros.lzz"
109
109
  { v8 :: Isolate * isolate = v8 :: Isolate :: GetCurrent ( ) ; isolate->ThrowException(v8::Exception::Error(StringFromUtf8(isolate, message, -1)));
110
110
  }
111
- #line 38 "./src/util/macros.lzz"
111
+ #line 35 "./src/util/macros.lzz"
112
112
  void ThrowTypeError (char const * message)
113
- #line 38 "./src/util/macros.lzz"
113
+ #line 35 "./src/util/macros.lzz"
114
114
  { v8 :: Isolate * isolate = v8 :: Isolate :: GetCurrent ( ) ; isolate->ThrowException(v8::Exception::TypeError(StringFromUtf8(isolate, message, -1)));
115
115
  }
116
- #line 39 "./src/util/macros.lzz"
116
+ #line 36 "./src/util/macros.lzz"
117
117
  void ThrowRangeError (char const * message)
118
- #line 39 "./src/util/macros.lzz"
118
+ #line 36 "./src/util/macros.lzz"
119
119
  { v8 :: Isolate * isolate = v8 :: Isolate :: GetCurrent ( ) ; isolate->ThrowException(v8::Exception::RangeError(StringFromUtf8(isolate, message, -1)));
120
120
  }
121
- #line 105 "./src/util/macros.lzz"
121
+ #line 102 "./src/util/macros.lzz"
122
122
  v8::Local <v8::FunctionTemplate> NewConstructorTemplate (v8::Isolate * isolate, v8::Local <v8::External> data, v8::FunctionCallback func, char const * name)
123
- #line 110 "./src/util/macros.lzz"
123
+ #line 107 "./src/util/macros.lzz"
124
124
  {
125
125
  v8::Local<v8::FunctionTemplate> t = v8::FunctionTemplate::New(isolate, func, data);
126
126
  t->InstanceTemplate()->SetInternalFieldCount(1);
127
127
  t->SetClassName(InternalizedFromLatin1(isolate, name));
128
128
  return t;
129
129
  }
130
- #line 116 "./src/util/macros.lzz"
130
+ #line 113 "./src/util/macros.lzz"
131
131
  void SetPrototypeMethod (v8::Isolate * isolate, v8::Local <v8::External> data, v8::Local <v8::FunctionTemplate> recv, char const * name, v8::FunctionCallback func)
132
- #line 122 "./src/util/macros.lzz"
132
+ #line 119 "./src/util/macros.lzz"
133
133
  {
134
134
  v8::HandleScope scope(isolate);
135
135
  recv->PrototypeTemplate()->Set(
@@ -137,9 +137,9 @@ void SetPrototypeMethod (v8::Isolate * isolate, v8::Local <v8::External> data, v
137
137
  v8::FunctionTemplate::New(isolate, func, data, v8::Signature::New(isolate, recv))
138
138
  );
139
139
  }
140
- #line 129 "./src/util/macros.lzz"
140
+ #line 126 "./src/util/macros.lzz"
141
141
  void SetPrototypeSymbolMethod (v8::Isolate * isolate, v8::Local <v8::External> data, v8::Local <v8::FunctionTemplate> recv, v8::Local <v8::Symbol> symbol, v8::FunctionCallback func)
142
- #line 135 "./src/util/macros.lzz"
142
+ #line 132 "./src/util/macros.lzz"
143
143
  {
144
144
  v8::HandleScope scope(isolate);
145
145
  recv->PrototypeTemplate()->Set(
@@ -267,9 +267,9 @@ CS::CS (v8::Isolate * isolate)
267
267
  SetCode(isolate, SQLITE_OK_LOAD_PERMANENTLY, "SQLITE_OK_LOAD_PERMANENTLY");
268
268
  }
269
269
  #line 140 "./src/util/constants.lzz"
270
- void CS::SetString (v8::Isolate * isolate, CopyablePersistent <v8::String> & constant, char const * str)
270
+ void CS::SetString (v8::Isolate * isolate, v8::Global <v8::String> & constant, char const * str)
271
271
  #line 140 "./src/util/constants.lzz"
272
- {
272
+ {
273
273
  constant.Reset(isolate, InternalizedFromLatin1(isolate, str));
274
274
  }
275
275
  #line 144 "./src/util/constants.lzz"
@@ -2041,9 +2041,9 @@ bool Binder::Bind (v8::FunctionCallbackInfo <v8 :: Value> const & info, int argc
2041
2041
  }
2042
2042
  return success;
2043
2043
  }
2044
- #line 54 "./src/util/binder.lzz"
2044
+ #line 55 "./src/util/binder.lzz"
2045
2045
  void Binder::Fail (void (* Throw) (char const *), char const * message)
2046
- #line 54 "./src/util/binder.lzz"
2046
+ #line 55 "./src/util/binder.lzz"
2047
2047
  {
2048
2048
  assert(success == true);
2049
2049
  assert((Throw == NULL) == (message == NULL));
@@ -2051,16 +2051,16 @@ void Binder::Fail (void (* Throw) (char const *), char const * message)
2051
2051
  if (Throw) Throw(message);
2052
2052
  success = false;
2053
2053
  }
2054
- #line 62 "./src/util/binder.lzz"
2054
+ #line 63 "./src/util/binder.lzz"
2055
2055
  int Binder::NextAnonIndex ()
2056
- #line 62 "./src/util/binder.lzz"
2056
+ #line 63 "./src/util/binder.lzz"
2057
2057
  {
2058
2058
  while (sqlite3_bind_parameter_name(handle, ++anon_index) != NULL) {}
2059
2059
  return anon_index;
2060
2060
  }
2061
- #line 68 "./src/util/binder.lzz"
2061
+ #line 69 "./src/util/binder.lzz"
2062
2062
  void Binder::BindValue (v8::Isolate * isolate, v8::Local <v8::Value> value, int index)
2063
- #line 68 "./src/util/binder.lzz"
2063
+ #line 69 "./src/util/binder.lzz"
2064
2064
  {
2065
2065
  int status = Data::BindValueFromJS(isolate, handle, index, value);
2066
2066
  if (status != SQLITE_OK) {
@@ -2079,9 +2079,9 @@ void Binder::BindValue (v8::Isolate * isolate, v8::Local <v8::Value> value, int
2079
2079
  assert(false);
2080
2080
  }
2081
2081
  }
2082
- #line 89 "./src/util/binder.lzz"
2082
+ #line 90 "./src/util/binder.lzz"
2083
2083
  int Binder::BindArray (v8::Isolate * isolate, v8::Local <v8::Array> arr)
2084
- #line 89 "./src/util/binder.lzz"
2084
+ #line 90 "./src/util/binder.lzz"
2085
2085
  {
2086
2086
  v8 :: Local < v8 :: Context > ctx = isolate -> GetCurrentContext ( ) ;
2087
2087
  uint32_t length = arr->Length();
@@ -2103,9 +2103,9 @@ int Binder::BindArray (v8::Isolate * isolate, v8::Local <v8::Array> arr)
2103
2103
  }
2104
2104
  return len;
2105
2105
  }
2106
- #line 115 "./src/util/binder.lzz"
2106
+ #line 116 "./src/util/binder.lzz"
2107
2107
  int Binder::BindObject (v8::Isolate * isolate, v8::Local <v8::Object> obj, Statement * stmt)
2108
- #line 115 "./src/util/binder.lzz"
2108
+ #line 116 "./src/util/binder.lzz"
2109
2109
  {
2110
2110
  v8 :: Local < v8 :: Context > ctx = isolate -> GetCurrentContext ( ) ;
2111
2111
  BindMap* bind_map = stmt->GetBindMap(isolate);
@@ -2142,9 +2142,9 @@ int Binder::BindObject (v8::Isolate * isolate, v8::Local <v8::Object> obj, State
2142
2142
 
2143
2143
  return len;
2144
2144
  }
2145
- #line 159 "./src/util/binder.lzz"
2145
+ #line 160 "./src/util/binder.lzz"
2146
2146
  Binder::Result Binder::BindArgs (v8::FunctionCallbackInfo <v8 :: Value> const & info, int argc, Statement * stmt)
2147
- #line 159 "./src/util/binder.lzz"
2147
+ #line 160 "./src/util/binder.lzz"
2148
2148
  {
2149
2149
  v8 :: Isolate * isolate = info . GetIsolate ( ) ;
2150
2150
  int count = 0;
@@ -16,9 +16,7 @@
16
16
  #include <node.h>
17
17
  #include <node_object_wrap.h>
18
18
  #include <node_buffer.h>
19
- #line 31 "./src/util/macros.lzz"
20
- template <class T> using CopyablePersistent = v8::Persistent<T, v8::CopyablePersistentTraits<T>>;
21
- #line 144 "./src/util/macros.lzz"
19
+ #line 141 "./src/util/macros.lzz"
22
20
  void SetPrototypeGetter(
23
21
  v8::Isolate* isolate,
24
22
  v8::Local<v8::External> data,
@@ -37,29 +35,29 @@ v8::Local <v8::String> InternalizedFromUtf8 (v8::Isolate * isolate, char const *
37
35
  v8::Local <v8::Value> InternalizedFromUtf8OrNull (v8::Isolate * isolate, char const * data, int length);
38
36
  #line 26 "./src/util/macros.lzz"
39
37
  v8::Local <v8::String> InternalizedFromLatin1 (v8::Isolate * isolate, char const * str);
40
- #line 33 "./src/util/macros.lzz"
41
- void SetFrozen (v8::Isolate * isolate, v8::Local <v8::Context> ctx, v8::Local <v8::Object> obj, CopyablePersistent <v8::String> & key, v8::Local <v8::Value> value);
42
- #line 37 "./src/util/macros.lzz"
38
+ #line 30 "./src/util/macros.lzz"
39
+ void SetFrozen (v8::Isolate * isolate, v8::Local <v8::Context> ctx, v8::Local <v8::Object> obj, v8::Global <v8::String> & key, v8::Local <v8::Value> value);
40
+ #line 34 "./src/util/macros.lzz"
43
41
  void ThrowError (char const * message);
44
- #line 38 "./src/util/macros.lzz"
42
+ #line 35 "./src/util/macros.lzz"
45
43
  void ThrowTypeError (char const * message);
46
- #line 39 "./src/util/macros.lzz"
44
+ #line 36 "./src/util/macros.lzz"
47
45
  void ThrowRangeError (char const * message);
48
- #line 91 "./src/util/macros.lzz"
46
+ #line 88 "./src/util/macros.lzz"
49
47
  bool IS_SKIPPED (char c);
50
- #line 96 "./src/util/macros.lzz"
48
+ #line 93 "./src/util/macros.lzz"
51
49
  template <typename T>
52
- #line 96 "./src/util/macros.lzz"
50
+ #line 93 "./src/util/macros.lzz"
53
51
  T * ALLOC_ARRAY (size_t count);
54
- #line 101 "./src/util/macros.lzz"
52
+ #line 98 "./src/util/macros.lzz"
55
53
  template <typename T>
56
- #line 101 "./src/util/macros.lzz"
54
+ #line 98 "./src/util/macros.lzz"
57
55
  void FREE_ARRAY (T * array_pointer);
58
- #line 105 "./src/util/macros.lzz"
56
+ #line 102 "./src/util/macros.lzz"
59
57
  v8::Local <v8::FunctionTemplate> NewConstructorTemplate (v8::Isolate * isolate, v8::Local <v8::External> data, v8::FunctionCallback func, char const * name);
60
- #line 116 "./src/util/macros.lzz"
58
+ #line 113 "./src/util/macros.lzz"
61
59
  void SetPrototypeMethod (v8::Isolate * isolate, v8::Local <v8::External> data, v8::Local <v8::FunctionTemplate> recv, char const * name, v8::FunctionCallback func);
62
- #line 129 "./src/util/macros.lzz"
60
+ #line 126 "./src/util/macros.lzz"
63
61
  void SetPrototypeSymbolMethod (v8::Isolate * isolate, v8::Local <v8::External> data, v8::Local <v8::FunctionTemplate> recv, v8::Local <v8::Symbol> symbol, v8::FunctionCallback func);
64
62
  #line 1 "./src/util/constants.lzz"
65
63
  class CS
@@ -71,49 +69,49 @@ public:
71
69
  #line 10 "./src/util/constants.lzz"
72
70
  explicit CS (v8::Isolate * isolate);
73
71
  #line 119 "./src/util/constants.lzz"
74
- CopyablePersistent <v8::String> database;
72
+ v8::Global <v8::String> database;
75
73
  #line 120 "./src/util/constants.lzz"
76
- CopyablePersistent <v8::String> reader;
74
+ v8::Global <v8::String> reader;
77
75
  #line 121 "./src/util/constants.lzz"
78
- CopyablePersistent <v8::String> source;
76
+ v8::Global <v8::String> source;
79
77
  #line 122 "./src/util/constants.lzz"
80
- CopyablePersistent <v8::String> memory;
78
+ v8::Global <v8::String> memory;
81
79
  #line 123 "./src/util/constants.lzz"
82
- CopyablePersistent <v8::String> readonly;
80
+ v8::Global <v8::String> readonly;
83
81
  #line 124 "./src/util/constants.lzz"
84
- CopyablePersistent <v8::String> name;
82
+ v8::Global <v8::String> name;
85
83
  #line 125 "./src/util/constants.lzz"
86
- CopyablePersistent <v8::String> next;
84
+ v8::Global <v8::String> next;
87
85
  #line 126 "./src/util/constants.lzz"
88
- CopyablePersistent <v8::String> length;
86
+ v8::Global <v8::String> length;
89
87
  #line 127 "./src/util/constants.lzz"
90
- CopyablePersistent <v8::String> done;
88
+ v8::Global <v8::String> done;
91
89
  #line 128 "./src/util/constants.lzz"
92
- CopyablePersistent <v8::String> value;
90
+ v8::Global <v8::String> value;
93
91
  #line 129 "./src/util/constants.lzz"
94
- CopyablePersistent <v8::String> changes;
92
+ v8::Global <v8::String> changes;
95
93
  #line 130 "./src/util/constants.lzz"
96
- CopyablePersistent <v8::String> lastInsertRowid;
94
+ v8::Global <v8::String> lastInsertRowid;
97
95
  #line 131 "./src/util/constants.lzz"
98
- CopyablePersistent <v8::String> statement;
96
+ v8::Global <v8::String> statement;
99
97
  #line 132 "./src/util/constants.lzz"
100
- CopyablePersistent <v8::String> column;
98
+ v8::Global <v8::String> column;
101
99
  #line 133 "./src/util/constants.lzz"
102
- CopyablePersistent <v8::String> table;
100
+ v8::Global <v8::String> table;
103
101
  #line 134 "./src/util/constants.lzz"
104
- CopyablePersistent <v8::String> type;
102
+ v8::Global <v8::String> type;
105
103
  #line 135 "./src/util/constants.lzz"
106
- CopyablePersistent <v8::String> totalPages;
104
+ v8::Global <v8::String> totalPages;
107
105
  #line 136 "./src/util/constants.lzz"
108
- CopyablePersistent <v8::String> remainingPages;
106
+ v8::Global <v8::String> remainingPages;
109
107
  #line 138 "./src/util/constants.lzz"
110
108
  private:
111
109
  #line 140 "./src/util/constants.lzz"
112
- static void SetString (v8::Isolate * isolate, CopyablePersistent <v8::String> & constant, char const * str);
110
+ static void SetString (v8::Isolate * isolate, v8::Global <v8::String> & constant, char const * str);
113
111
  #line 144 "./src/util/constants.lzz"
114
112
  void SetCode (v8::Isolate * isolate, int code, char const * str);
115
113
  #line 150 "./src/util/constants.lzz"
116
- std::unordered_map <int, CopyablePersistent<v8::String> > codes;
114
+ std::unordered_map <int, v8::Global<v8::String> > codes;
117
115
  };
118
116
  #line 1 "./src/util/bind-map.lzz"
119
117
  class BindMap
@@ -138,7 +136,7 @@ public:
138
136
  #line 22 "./src/util/bind-map.lzz"
139
137
  explicit Pair (v8::Isolate * isolate, Pair * pair);
140
138
  #line 25 "./src/util/bind-map.lzz"
141
- CopyablePersistent <v8::String> const name;
139
+ v8::Global <v8::String> const name;
142
140
  #line 26 "./src/util/bind-map.lzz"
143
141
  int const index;
144
142
  };
@@ -309,7 +307,7 @@ private:
309
307
  #line 504 "./src/objects/database.lzz"
310
308
  Addon * const addon;
311
309
  #line 505 "./src/objects/database.lzz"
312
- CopyablePersistent <v8::Value> const logger;
310
+ v8::Global <v8::Value> const logger;
313
311
  #line 506 "./src/objects/database.lzz"
314
312
  std::set <Statement*, CompareStatement> stmts;
315
313
  #line 507 "./src/objects/database.lzz"
@@ -523,7 +521,7 @@ protected:
523
521
  #line 56 "./src/util/custom-function.lzz"
524
522
  v8::Isolate * const isolate;
525
523
  #line 57 "./src/util/custom-function.lzz"
526
- CopyablePersistent <v8::Function> const fn;
524
+ v8::Global <v8::Function> const fn;
527
525
  #line 58 "./src/util/custom-function.lzz"
528
526
  bool const safe_ints;
529
527
  };
@@ -545,7 +543,7 @@ public:
545
543
  #line 37 "./src/util/custom-aggregate.lzz"
546
544
  private:
547
545
  #line 39 "./src/util/custom-aggregate.lzz"
548
- static void xStepBase (sqlite3_context * invocation, int argc, sqlite3_value * * argv, CopyablePersistent <v8::Function> const CustomAggregate::* ptrtm);
546
+ static void xStepBase (sqlite3_context * invocation, int argc, sqlite3_value * * argv, v8::Global <v8::Function> const CustomAggregate::* ptrtm);
549
547
  #line 58 "./src/util/custom-aggregate.lzz"
550
548
  static void xValueBase (sqlite3_context * invocation, bool is_final);
551
549
  #line 82 "./src/util/custom-aggregate.lzz"
@@ -554,7 +552,7 @@ private:
554
552
  #line 82 "./src/util/custom-aggregate.lzz"
555
553
  public:
556
554
  #line 83 "./src/util/custom-aggregate.lzz"
557
- CopyablePersistent <v8::Value> value;
555
+ v8::Global <v8::Value> value;
558
556
  #line 84 "./src/util/custom-aggregate.lzz"
559
557
  bool initialized;
560
558
  #line 85 "./src/util/custom-aggregate.lzz"
@@ -571,11 +569,11 @@ private:
571
569
  #line 117 "./src/util/custom-aggregate.lzz"
572
570
  bool const invoke_start;
573
571
  #line 118 "./src/util/custom-aggregate.lzz"
574
- CopyablePersistent <v8::Function> const inverse;
572
+ v8::Global <v8::Function> const inverse;
575
573
  #line 119 "./src/util/custom-aggregate.lzz"
576
- CopyablePersistent <v8::Function> const result;
574
+ v8::Global <v8::Function> const result;
577
575
  #line 120 "./src/util/custom-aggregate.lzz"
578
- CopyablePersistent <v8::Value> const start;
576
+ v8::Global <v8::Value> const start;
579
577
  };
580
578
  #line 1 "./src/util/custom-table.lzz"
581
579
  class CustomTable
@@ -612,7 +610,7 @@ private:
612
610
  #line 103 "./src/util/custom-table.lzz"
613
611
  bool const safe_ints;
614
612
  #line 104 "./src/util/custom-table.lzz"
615
- CopyablePersistent <v8::Function> const generator;
613
+ v8::Global <v8::Function> const generator;
616
614
  #line 105 "./src/util/custom-table.lzz"
617
615
  std::vector <std::string> const parameter_names;
618
616
  };
@@ -630,11 +628,11 @@ private:
630
628
  #line 122 "./src/util/custom-table.lzz"
631
629
  sqlite3_vtab_cursor base;
632
630
  #line 123 "./src/util/custom-table.lzz"
633
- CopyablePersistent <v8::Object> iterator;
631
+ v8::Global <v8::Object> iterator;
634
632
  #line 124 "./src/util/custom-table.lzz"
635
- CopyablePersistent <v8::Function> next;
633
+ v8::Global <v8::Function> next;
636
634
  #line 125 "./src/util/custom-table.lzz"
637
- CopyablePersistent <v8::Array> row;
635
+ v8::Global <v8::Array> row;
638
636
  #line 126 "./src/util/custom-table.lzz"
639
637
  bool done;
640
638
  #line 127 "./src/util/custom-table.lzz"
@@ -689,7 +687,7 @@ private:
689
687
  #line 402 "./src/util/custom-table.lzz"
690
688
  std::string const name;
691
689
  #line 403 "./src/util/custom-table.lzz"
692
- CopyablePersistent <v8::Function> const factory;
690
+ v8::Global <v8::Function> const factory;
693
691
  };
694
692
  #line 65 "./src/util/data.lzz"
695
693
  namespace Data
@@ -764,25 +762,25 @@ private:
764
762
  #line 32 "./src/util/binder.lzz"
765
763
  bool bound_object;
766
764
  };
767
- #line 54 "./src/util/binder.lzz"
765
+ #line 55 "./src/util/binder.lzz"
768
766
  void Fail (void (* Throw) (char const *), char const * message);
769
- #line 62 "./src/util/binder.lzz"
767
+ #line 63 "./src/util/binder.lzz"
770
768
  int NextAnonIndex ();
771
- #line 68 "./src/util/binder.lzz"
769
+ #line 69 "./src/util/binder.lzz"
772
770
  void BindValue (v8::Isolate * isolate, v8::Local <v8::Value> value, int index);
773
- #line 89 "./src/util/binder.lzz"
771
+ #line 90 "./src/util/binder.lzz"
774
772
  int BindArray (v8::Isolate * isolate, v8::Local <v8::Array> arr);
775
- #line 115 "./src/util/binder.lzz"
773
+ #line 116 "./src/util/binder.lzz"
776
774
  int BindObject (v8::Isolate * isolate, v8::Local <v8::Object> obj, Statement * stmt);
777
- #line 159 "./src/util/binder.lzz"
775
+ #line 160 "./src/util/binder.lzz"
778
776
  Result BindArgs (v8::FunctionCallbackInfo <v8 :: Value> const & info, int argc, Statement * stmt);
779
- #line 199 "./src/util/binder.lzz"
780
- sqlite3_stmt * handle;
781
777
  #line 200 "./src/util/binder.lzz"
782
- int param_count;
778
+ sqlite3_stmt * handle;
783
779
  #line 201 "./src/util/binder.lzz"
784
- int anon_index;
780
+ int param_count;
785
781
  #line 202 "./src/util/binder.lzz"
782
+ int anon_index;
783
+ #line 203 "./src/util/binder.lzz"
786
784
  bool success;
787
785
  };
788
786
  #line 34 "./src/better_sqlite3.lzz"
@@ -797,13 +795,13 @@ struct Addon
797
795
  #line 52 "./src/better_sqlite3.lzz"
798
796
  sqlite3_uint64 NextId ();
799
797
  #line 56 "./src/better_sqlite3.lzz"
800
- CopyablePersistent <v8::Function> Statement;
798
+ v8::Global <v8::Function> Statement;
801
799
  #line 57 "./src/better_sqlite3.lzz"
802
- CopyablePersistent <v8::Function> StatementIterator;
800
+ v8::Global <v8::Function> StatementIterator;
803
801
  #line 58 "./src/better_sqlite3.lzz"
804
- CopyablePersistent <v8::Function> Backup;
802
+ v8::Global <v8::Function> Backup;
805
803
  #line 59 "./src/better_sqlite3.lzz"
806
- CopyablePersistent <v8::Function> SqliteError;
804
+ v8::Global <v8::Function> SqliteError;
807
805
  #line 60 "./src/better_sqlite3.lzz"
808
806
  v8::FunctionCallbackInfo <v8 :: Value> const * privileged_info;
809
807
  #line 61 "./src/better_sqlite3.lzz"
@@ -838,31 +836,31 @@ LZZ_INLINE v8::Local <v8::String> InternalizedFromLatin1 (v8::Isolate * isolate,
838
836
  {
839
837
  return v8::String::NewFromOneByte(isolate, reinterpret_cast<const uint8_t*>(str), v8::NewStringType::kInternalized).ToLocalChecked();
840
838
  }
841
- #line 33 "./src/util/macros.lzz"
842
- LZZ_INLINE void SetFrozen (v8::Isolate * isolate, v8::Local <v8::Context> ctx, v8::Local <v8::Object> obj, CopyablePersistent <v8::String> & key, v8::Local <v8::Value> value)
843
- #line 33 "./src/util/macros.lzz"
844
- {
839
+ #line 30 "./src/util/macros.lzz"
840
+ LZZ_INLINE void SetFrozen (v8::Isolate * isolate, v8::Local <v8::Context> ctx, v8::Local <v8::Object> obj, v8::Global <v8::String> & key, v8::Local <v8::Value> value)
841
+ #line 30 "./src/util/macros.lzz"
842
+ {
845
843
  obj->DefineOwnProperty(ctx, key.Get(isolate), value, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly)).FromJust();
846
844
  }
847
- #line 91 "./src/util/macros.lzz"
845
+ #line 88 "./src/util/macros.lzz"
848
846
  LZZ_INLINE bool IS_SKIPPED (char c)
849
- #line 91 "./src/util/macros.lzz"
847
+ #line 88 "./src/util/macros.lzz"
850
848
  {
851
849
  return c == ' ' || c == ';' || (c >= '\t' && c <= '\r');
852
850
  }
853
- #line 96 "./src/util/macros.lzz"
851
+ #line 93 "./src/util/macros.lzz"
854
852
  template <typename T>
855
- #line 96 "./src/util/macros.lzz"
853
+ #line 93 "./src/util/macros.lzz"
856
854
  LZZ_INLINE T * ALLOC_ARRAY (size_t count)
857
- #line 96 "./src/util/macros.lzz"
855
+ #line 93 "./src/util/macros.lzz"
858
856
  {
859
857
  return static_cast<T*>(::operator new[](count * sizeof(T)));
860
858
  }
861
- #line 101 "./src/util/macros.lzz"
859
+ #line 98 "./src/util/macros.lzz"
862
860
  template <typename T>
863
- #line 101 "./src/util/macros.lzz"
861
+ #line 98 "./src/util/macros.lzz"
864
862
  LZZ_INLINE void FREE_ARRAY (T * array_pointer)
865
- #line 101 "./src/util/macros.lzz"
863
+ #line 98 "./src/util/macros.lzz"
866
864
  {
867
865
  ::operator delete[](array_pointer);
868
866
  }
@@ -956,9 +954,9 @@ LZZ_INLINE bool Backup::Compare (Backup const * const a, Backup const * const b)
956
954
  return a->id < b->id;
957
955
  }
958
956
  #line 39 "./src/util/custom-aggregate.lzz"
959
- LZZ_INLINE void CustomAggregate::xStepBase (sqlite3_context * invocation, int argc, sqlite3_value * * argv, CopyablePersistent <v8::Function> const CustomAggregate::* ptrtm)
957
+ LZZ_INLINE void CustomAggregate::xStepBase (sqlite3_context * invocation, int argc, sqlite3_value * * argv, v8::Global <v8::Function> const CustomAggregate::* ptrtm)
960
958
  #line 39 "./src/util/custom-aggregate.lzz"
961
- {
959
+ {
962
960
  CustomAggregate * self = static_cast < CustomAggregate * > ( sqlite3_user_data ( invocation ) ) ; v8 :: Isolate * isolate = self -> isolate ; v8 :: HandleScope scope ( isolate ) ; Accumulator * acc = self -> GetAccumulator ( invocation ) ; if ( acc -> value . IsEmpty ( ) ) return ;
963
961
 
964
962
  v8::Local<v8::Value> args_fast[5];