xitdb 0.6.0 → 0.7.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/dist/index.js CHANGED
@@ -178,17 +178,18 @@ class MaxShiftExceededException extends DatabaseException {
178
178
  class Uint {
179
179
  value;
180
180
  constructor(value) {
181
- if (value < 0) {
181
+ const bigintValue = BigInt(value);
182
+ if (bigintValue < 0n) {
182
183
  throw new Error("Uint must not be negative");
183
184
  }
184
- this.value = value;
185
+ this.value = bigintValue;
185
186
  }
186
187
  }
187
188
 
188
189
  class Int {
189
190
  value;
190
191
  constructor(value) {
191
- this.value = value;
192
+ this.value = BigInt(value);
192
193
  }
193
194
  }
194
195
 
@@ -1,12 +1,12 @@
1
1
  export interface WriteableData {
2
2
  }
3
3
  export declare class Uint implements WriteableData {
4
- readonly value: number;
5
- constructor(value: number);
4
+ readonly value: bigint;
5
+ constructor(value: number | bigint);
6
6
  }
7
7
  export declare class Int implements WriteableData {
8
- readonly value: number;
9
- constructor(value: number);
8
+ readonly value: bigint;
9
+ constructor(value: number | bigint);
10
10
  }
11
11
  export declare class Float implements WriteableData {
12
12
  readonly value: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xitdb",
3
- "version": "0.6.0",
3
+ "version": "0.7.0",
4
4
  "description": "An immutable database",
5
5
  "license": "MIT",
6
6
  "repository": {