@ferrflow/wasm 6.1.1 → 7.0.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.
@@ -5,7 +5,7 @@ export function build_changelog_section(version: string, commits_json: string):
5
5
 
6
6
  export function compute_next_version(current: string, bump: string, strategy: string): string;
7
7
 
8
- export function determine_bump(message: string): string;
8
+ export function determine_bump(message: string, formats_json?: string | null): string;
9
9
 
10
10
  export function serialize_config(config_json: string, format: string): string;
11
11
 
@@ -71,24 +71,35 @@ export function compute_next_version(current, bump, strategy) {
71
71
 
72
72
  /**
73
73
  * @param {string} message
74
+ * @param {string | null} [formats_json]
74
75
  * @returns {string}
75
76
  */
76
- export function determine_bump(message) {
77
- let deferred2_0;
78
- let deferred2_1;
77
+ export function determine_bump(message, formats_json) {
78
+ let deferred4_0;
79
+ let deferred4_1;
79
80
  try {
80
81
  const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
81
82
  const ptr0 = passStringToWasm0(message, wasm.__wbindgen_export, wasm.__wbindgen_export2);
82
83
  const len0 = WASM_VECTOR_LEN;
83
- wasm.determine_bump(retptr, ptr0, len0);
84
+ var ptr1 = isLikeNone(formats_json) ? 0 : passStringToWasm0(formats_json, wasm.__wbindgen_export, wasm.__wbindgen_export2);
85
+ var len1 = WASM_VECTOR_LEN;
86
+ wasm.determine_bump(retptr, ptr0, len0, ptr1, len1);
84
87
  var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
85
88
  var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
86
- deferred2_0 = r0;
87
- deferred2_1 = r1;
88
- return getStringFromWasm0(r0, r1);
89
+ var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
90
+ var r3 = getDataViewMemory0().getInt32(retptr + 4 * 3, true);
91
+ var ptr3 = r0;
92
+ var len3 = r1;
93
+ if (r3) {
94
+ ptr3 = 0; len3 = 0;
95
+ throw takeObject(r2);
96
+ }
97
+ deferred4_0 = ptr3;
98
+ deferred4_1 = len3;
99
+ return getStringFromWasm0(ptr3, len3);
89
100
  } finally {
90
101
  wasm.__wbindgen_add_to_stack_pointer(16);
91
- wasm.__wbindgen_export3(deferred2_0, deferred2_1, 1);
102
+ wasm.__wbindgen_export3(deferred4_0, deferred4_1, 1);
92
103
  }
93
104
  }
94
105
 
@@ -221,6 +232,10 @@ heap.push(undefined, null, true, false);
221
232
 
222
233
  let heap_next = heap.length;
223
234
 
235
+ function isLikeNone(x) {
236
+ return x === undefined || x === null;
237
+ }
238
+
224
239
  function passStringToWasm0(arg, malloc, realloc) {
225
240
  if (realloc === undefined) {
226
241
  const buf = cachedTextEncoder.encode(arg);
Binary file
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@ferrflow/wasm",
3
3
  "type": "module",
4
4
  "description": "FerrFlow core functions compiled to WebAssembly",
5
- "version": "6.1.1",
5
+ "version": "7.0.0",
6
6
  "license": "MIT",
7
7
  "files": [
8
8
  "ferrflow_wasm_bg.wasm",